(window["webpackJsonp"] = window["webpackJsonp"] || []).push([["ddr-ddr-module"],{

/***/ "./node_modules/css-loader/dist/cjs.js?!./node_modules/postcss-loader/src/index.js?!./node_modules/d3-flame-graph/dist/d3-flamegraph.css":
/*!*********************************************************************************************************************************************************!*\
  !*** ./node_modules/css-loader/dist/cjs.js??ref--12-1!./node_modules/postcss-loader/src??embedded!./node_modules/d3-flame-graph/dist/d3-flamegraph.css ***!
  \*********************************************************************************************************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {

// Imports
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../css-loader/dist/runtime/api.js */ "./node_modules/css-loader/dist/runtime/api.js");
exports = ___CSS_LOADER_API_IMPORT___(false);
// Module
exports.push([module.i, ".d3-flame-graph rect{stroke:#eee;fill-opacity:.8}.d3-flame-graph rect:hover{stroke:#474747;stroke-width:.5;cursor:pointer}.d3-flame-graph-label{white-space:nowrap;text-overflow:ellipsis;overflow:hidden;font-size:12px;font-family:Verdana;margin-left:4px;margin-right:4px;line-height:1.5;padding:0;font-weight:400;color:#000;text-align:left}.d3-flame-graph .fade{opacity:.6!important}.d3-flame-graph .title{font-size:20px;font-family:Verdana}.d3-flame-graph-tip{background-color:#000;border:none;border-radius:3px;padding:5px 10px;min-width:250px;text-align:left;color:#fff;z-index:10}\n", ""]);
// Exports
module.exports = exports;


/***/ }),

/***/ "./node_modules/css-loader/dist/runtime/api.js":
/*!*****************************************************!*\
  !*** ./node_modules/css-loader/dist/runtime/api.js ***!
  \*****************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


/*
  MIT License http://www.opensource.org/licenses/mit-license.php
  Author Tobias Koppers @sokra
*/
// css base code, injected by the css-loader
// eslint-disable-next-line func-names
module.exports = function (useSourceMap) {
  var list = []; // return the list of modules as css string

  list.toString = function toString() {
    return this.map(function (item) {
      var content = cssWithMappingToString(item, useSourceMap);

      if (item[2]) {
        return "@media ".concat(item[2], " {").concat(content, "}");
      }

      return content;
    }).join('');
  }; // import a list of modules into the list
  // eslint-disable-next-line func-names


  list.i = function (modules, mediaQuery, dedupe) {
    if (typeof modules === 'string') {
      // eslint-disable-next-line no-param-reassign
      modules = [[null, modules, '']];
    }

    var alreadyImportedModules = {};

    if (dedupe) {
      for (var i = 0; i < this.length; i++) {
        // eslint-disable-next-line prefer-destructuring
        var id = this[i][0];

        if (id != null) {
          alreadyImportedModules[id] = true;
        }
      }
    }

    for (var _i = 0; _i < modules.length; _i++) {
      var item = [].concat(modules[_i]);

      if (dedupe && alreadyImportedModules[item[0]]) {
        // eslint-disable-next-line no-continue
        continue;
      }

      if (mediaQuery) {
        if (!item[2]) {
          item[2] = mediaQuery;
        } else {
          item[2] = "".concat(mediaQuery, " and ").concat(item[2]);
        }
      }

      list.push(item);
    }
  };

  return list;
};

function cssWithMappingToString(item, useSourceMap) {
  var content = item[1] || ''; // eslint-disable-next-line prefer-destructuring

  var cssMapping = item[3];

  if (!cssMapping) {
    return content;
  }

  if (useSourceMap && typeof btoa === 'function') {
    var sourceMapping = toComment(cssMapping);
    var sourceURLs = cssMapping.sources.map(function (source) {
      return "/*# sourceURL=".concat(cssMapping.sourceRoot || '').concat(source, " */");
    });
    return [content].concat(sourceURLs).concat([sourceMapping]).join('\n');
  }

  return [content].join('\n');
} // Adapted from convert-source-map (MIT)


function toComment(sourceMap) {
  // eslint-disable-next-line no-undef
  var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));
  var data = "sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(base64);
  return "/*# ".concat(data, " */");
}

/***/ }),

/***/ "./node_modules/d3-flame-graph/dist/d3-flamegraph.css":
/*!************************************************************!*\
  !*** ./node_modules/d3-flame-graph/dist/d3-flamegraph.css ***!
  \************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {

var api = __webpack_require__(/*! ../../style-loader/dist/runtime/injectStylesIntoStyleTag.js */ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js");
            var content = __webpack_require__(/*! !../../css-loader/dist/cjs.js??ref--12-1!../../postcss-loader/src??embedded!./d3-flamegraph.css */ "./node_modules/css-loader/dist/cjs.js?!./node_modules/postcss-loader/src/index.js?!./node_modules/d3-flame-graph/dist/d3-flamegraph.css");

            content = content.__esModule ? content.default : content;

            if (typeof content === 'string') {
              content = [[module.i, content, '']];
            }

var options = {};

options.insert = "head";
options.singleton = false;

var update = api(content, options);

var exported = content.locals ? content.locals : {};



module.exports = exported;

/***/ }),

/***/ "./node_modules/d3-flame-graph/dist/d3-flamegraph.es.js":
/*!**************************************************************!*\
  !*** ./node_modules/d3-flame-graph/dist/d3-flamegraph.es.js ***!
  \**************************************************************/
/*! exports provided: colorMapper, default, tooltip */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "colorMapper", function() { return colorMapper; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return flamegraph; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "tooltip", function() { return tooltip; });
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var d3_format__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-format */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/index.js");
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var d3_hierarchy__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! d3-hierarchy */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/index.js");
/* harmony import */ var d3_scale__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! d3-scale */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/index.js");
/* harmony import */ var d3_ease__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! d3-ease */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/index.js");
/* harmony import */ var d3_transition__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! d3-transition */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/index.js");
/* harmony import */ var d3_dispatch__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! d3-dispatch */ "./node_modules/d3-flame-graph/node_modules/d3-dispatch/src/index.js");
/* harmony import */ var _d3_flamegraph_css__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./d3-flamegraph.css */ "./node_modules/d3-flame-graph/dist/d3-flamegraph.css");
/* harmony import */ var _d3_flamegraph_css__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_d3_flamegraph_css__WEBPACK_IMPORTED_MODULE_8__);








function generateHash(name) {
  const MAX_CHAR = 6;
  let hash = 0;
  let maxHash = 0;
  let weight = 1;
  const mod = 10;
  if (name) {
    for (let i = 0; i < name.length; i++) {
      if (i > MAX_CHAR) {
        break;
      }
      hash += weight * (name.charCodeAt(i) % mod);
      maxHash += weight * (mod - 1);
      weight *= 0.7;
    }
    if (maxHash > 0) {
      hash = hash / maxHash;
    }
  }
  return hash;
}
function generateColorVector(name) {
  let vector = 0;
  if (name) {
    const nameArr = name.split("`");
    if (nameArr.length > 1) {
      name = nameArr[nameArr.length - 1];
    }
    name = name.split("(")[0];
    vector = generateHash(name);
  }
  return vector;
}
function calculateColor(hue, vector) {
  let r;
  let g;
  let b;
  if (hue === "red") {
    r = 200 + Math.round(55 * vector);
    g = 50 + Math.round(80 * vector);
    b = g;
  } else if (hue === "orange") {
    r = 190 + Math.round(65 * vector);
    g = 90 + Math.round(65 * vector);
    b = 0;
  } else if (hue === "yellow") {
    r = 175 + Math.round(55 * vector);
    g = r;
    b = 50 + Math.round(20 * vector);
  } else if (hue === "green") {
    r = 50 + Math.round(60 * vector);
    g = 200 + Math.round(55 * vector);
    b = r;
  } else if (hue === "pastelgreen") {
    r = 163 + Math.round(75 * vector);
    g = 195 + Math.round(49 * vector);
    b = 72 + Math.round(149 * vector);
  } else if (hue === "blue") {
    r = 91 + Math.round(126 * vector);
    g = 156 + Math.round(76 * vector);
    b = 221 + Math.round(26 * vector);
  } else if (hue === "aqua") {
    r = 50 + Math.round(60 * vector);
    g = 165 + Math.round(55 * vector);
    b = g;
  } else if (hue === "cold") {
    r = 0 + Math.round(55 * (1 - vector));
    g = 0 + Math.round(230 * (1 - vector));
    b = 200 + Math.round(55 * vector);
  } else {
    r = 200 + Math.round(55 * vector);
    g = 0 + Math.round(230 * (1 - vector));
    b = 0 + Math.round(55 * (1 - vector));
  }
  return "rgb(" + r + "," + g + "," + b + ")";
}
function defaultLabel(d) {
  return d.data.name;
}
function defaultFlamegraphTooltip() {
  var rootElement = Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["select"])("body");
  var tooltip2 = null;
  var html = defaultLabel;
  var text = defaultLabel;
  var contentIsHTML = false;
  function tip() {
    tooltip2 = rootElement.append("div").style("display", "none").style("position", "absolute").style("opacity", 0).style("pointer-events", "none").attr("class", "d3-flame-graph-tip");
  }
  tip.show = function(event, d) {
    if (contentIsHTML) {
      tooltip2.html(html(d));
    } else {
      tooltip2.text(text(d));
    }
    var tipWidth = tooltip2.node().offsetWidth;
    var tipHeight = tooltip2.node().offsetHeight;
    var left = event.pageX + 5;
    var top = event.pageY + 5;
    if (left + tipWidth > window.innerWidth) {
      left = event.pageX - tipWidth - 5;
    }
    if (left < 0) {
      left = 5;
    }
    if (top + tipHeight > window.innerHeight) {
      top = event.pageY - tipHeight - 5;
    }
    if (top < 0) {
      top = 5;
    }
    tooltip2.style("display", "block").style("left", left + "px").style("top", top + "px").transition().duration(200).style("opacity", 1).style("pointer-events", "all");
    return tip;
  };
  tip.hide = function() {
    tooltip2.style("display", "none").transition().duration(200).style("opacity", 0).style("pointer-events", "none");
    return tip;
  };
  tip.text = function(_) {
    if (!arguments.length) return text;
    text = _;
    contentIsHTML = false;
    return tip;
  };
  tip.html = function(_) {
    if (!arguments.length) return html;
    html = _;
    contentIsHTML = true;
    return tip;
  };
  tip.destroy = function() {
    tooltip2.remove();
  };
  return tip;
}
const tooltip = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
  __proto__: null,
  defaultFlamegraphTooltip
}, Symbol.toStringTag, { value: "Module" }));
function pickHex(color1, color2, weight) {
  const w1 = weight;
  const w2 = 1 - w1;
  const rgb = [
    Math.round(color1[0] * w1 + color2[0] * w2),
    Math.round(color1[1] * w1 + color2[1] * w2),
    Math.round(color1[2] * w1 + color2[2] * w2)
  ];
  return rgb;
}
function allocationColorMapper(d, originalColor) {
  if (d.highlight) return originalColor;
  const self = d.data.value;
  const total = d.value;
  const color = pickHex([0, 255, 40], [196, 245, 233], self / total);
  return `rgb(${color.join()})`;
}
function offCpuColorMapper(d, originalColor) {
  if (d.highlight) return originalColor;
  const name = d.data.n || d.data.name;
  const vector = generateColorVector(name);
  const r = 0 + Math.round(55 * (1 - vector));
  const g = 0 + Math.round(230 * (1 - vector));
  const b = 200 + Math.round(55 * vector);
  return "rgb(" + r + "," + g + "," + b + ")";
}
function nodeJsColorMapper(d, originalColor) {
  let color = originalColor;
  const { v8_jit: v8JIT, javascript, optimized } = d.data.extras || {};
  if (v8JIT && !javascript) {
    color = "#dadada";
  }
  if (javascript) {
    let opt = (optimized || 0) / d.value;
    let r = 255;
    let g = 0;
    let b = 0;
    if (opt < 0.4) {
      opt = opt * 2.5;
      r = 240 - opt * 200;
    } else if (opt < 0.9) {
      opt = (opt - 0.4) * 2;
      r = 0;
      b = 200 - 200 * opt;
      g = 100 * opt;
    } else {
      opt = (opt - 0.9) * 10;
      r = 0;
      b = 0;
      g = 100 + 150 * opt;
    }
    color = `rgb(${r} , ${g}, ${b})`;
  }
  return color;
}
function differentialColorMapper(d, originalColor) {
  if (d.highlight) return originalColor;
  let r = 220;
  let g = 220;
  let b = 220;
  const delta = d.delta || d.data.d || d.data.delta;
  const unsignedDelta = Math.abs(delta);
  let value = d.value || d.data.v || d.data.value;
  if (value <= unsignedDelta) value = unsignedDelta;
  const vector = unsignedDelta / value;
  if (delta === value) {
    r = 255;
    g = 190;
    b = 90;
  } else if (delta > 0) {
    b = Math.round(235 * (1 - vector));
    g = b;
  } else if (delta < 0) {
    r = Math.round(235 * (1 - vector));
    g = r;
  }
  return "rgb(" + r + "," + g + "," + b + ")";
}
const colorMapper = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
  __proto__: null,
  allocationColorMapper,
  differentialColorMapper,
  nodeJsColorMapper,
  offCpuColorMapper
}, Symbol.toStringTag, { value: "Module" }));
function flamegraph() {
  let w = 960;
  let h = null;
  let c = 18;
  let selection = null;
  let tooltip2 = null;
  let title = "";
  let transitionDuration = 750;
  let transitionEase = d3_ease__WEBPACK_IMPORTED_MODULE_5__["easeCubic"];
  let sort = false;
  let inverted = false;
  let clickHandler = null;
  let hoverHandler = null;
  let minFrameSize = 0;
  let detailsElement = null;
  let searchDetails = null;
  let selfValue = false;
  let resetHeightOnZoom = false;
  let scrollOnZoom = false;
  let minHeight = null;
  let computeDelta = false;
  let colorHue = null;
  let getName = function(d) {
    return d.data.n || d.data.name;
  };
  let getValue = function(d) {
    if ("v" in d) {
      return d.v;
    } else {
      return d.value;
    }
  };
  let getChildren = function(d) {
    return d.c || d.children;
  };
  let getLibtype = function(d) {
    return d.data.l || d.data.libtype;
  };
  let getDelta = function(d) {
    if ("d" in d.data) {
      return d.data.d;
    } else {
      return d.data.delta;
    }
  };
  let searchHandler = function(searchResults, searchSum, totalValue) {
    searchDetails = () => {
      if (detailsElement) {
        detailsElement.textContent = "search: " + searchSum + " of " + totalValue + " total samples ( " + Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["format"])(".3f")(100 * (searchSum / totalValue), 3) + "%)";
      }
    };
    searchDetails();
  };
  const originalSearchHandler = searchHandler;
  let searchMatch = (d, term, ignoreCase = false) => {
    if (!term) {
      return false;
    }
    let label = getName(d);
    if (ignoreCase) {
      term = term.toLowerCase();
      label = label.toLowerCase();
    }
    const re = new RegExp(term);
    return typeof label !== "undefined" && label && label.match(re);
  };
  const originalSearchMatch = searchMatch;
  let detailsHandler = function(d) {
    if (detailsElement) {
      if (d) {
        detailsElement.textContent = d;
      } else {
        if (typeof searchDetails === "function") {
          searchDetails();
        } else {
          detailsElement.textContent = "";
        }
      }
    }
  };
  const originalDetailsHandler = detailsHandler;
  let labelHandler = function(d) {
    return getName(d) + " (" + Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["format"])(".3f")(100 * (d.x1 - d.x0), 3) + "%, " + getValue(d) + " samples)";
  };
  let colorMapper2 = function(d) {
    return d.highlight ? "#E600E6" : colorHash(getName(d), getLibtype(d));
  };
  const originalColorMapper = colorMapper2;
  function colorHash(name, libtype) {
    let hue = colorHue || "warm";
    if (!colorHue && !(typeof libtype === "undefined" || libtype === "")) {
      hue = "red";
      if (typeof name !== "undefined" && name && name.match(/::/)) {
        hue = "yellow";
      }
      if (libtype === "kernel") {
        hue = "orange";
      } else if (libtype === "jit") {
        hue = "green";
      } else if (libtype === "inlined") {
        hue = "aqua";
      }
    }
    const vector = generateColorVector(name);
    return calculateColor(hue, vector);
  }
  function show(d) {
    d.data.fade = false;
    d.data.hide = false;
    if (d.children) {
      d.children.forEach(show);
    }
  }
  function hideSiblings(node) {
    let child = node;
    let parent = child.parent;
    let children, i, sibling;
    while (parent) {
      children = parent.children;
      i = children.length;
      while (i--) {
        sibling = children[i];
        if (sibling !== child) {
          sibling.data.hide = true;
        }
      }
      child = parent;
      parent = child.parent;
    }
  }
  function fadeAncestors(d) {
    if (d.parent) {
      d.parent.data.fade = true;
      fadeAncestors(d.parent);
    }
  }
  function zoom(d, node) {
    if (tooltip2) tooltip2.hide();
    hideSiblings(d);
    show(d);
    fadeAncestors(d);
    update();
    if (scrollOnZoom) {
      const chartOffset = node.parentNode.offsetTop;
      const maxFrames = (window.innerHeight - chartOffset) / c;
      const frameOffset = (d.height - maxFrames + 10) * c;
      window.scrollTo({
        top: chartOffset + frameOffset,
        left: 0,
        behavior: "smooth"
      });
    }
    if (typeof clickHandler === "function") {
      clickHandler(d);
    }
  }
  function searchTree(d, term) {
    const results = [];
    let sum = 0;
    function searchInner(d2, foundParent) {
      let found = false;
      if (searchMatch(d2, term)) {
        d2.highlight = true;
        found = true;
        if (!foundParent) {
          sum += getValue(d2);
        }
        results.push(d2);
      } else {
        d2.highlight = false;
      }
      if (d2.children) {
        d2.children.forEach(function(child) {
          searchInner(child, foundParent || found);
        });
      }
    }
    searchInner(d, false);
    return [results, sum];
  }
  function findTree(d, id) {
    if (d.id === id) {
      return d;
    } else {
      const children = d.children;
      if (children) {
        for (let i = 0; i < children.length; i++) {
          const found = findTree(children[i], id);
          if (found) {
            return found;
          }
        }
      }
    }
  }
  function clear(d) {
    d.highlight = false;
    if (d.children) {
      d.children.forEach(function(child) {
        clear(child);
      });
    }
  }
  function doSort(a, b) {
    if (typeof sort === "function") {
      return sort(a, b);
    } else if (sort) {
      return Object(d3_array__WEBPACK_IMPORTED_MODULE_2__["ascending"])(getName(a), getName(b));
    }
  }
  const p = Object(d3_hierarchy__WEBPACK_IMPORTED_MODULE_3__["partition"])();
  function filterNodes(root) {
    let nodeList = root.descendants();
    if (minFrameSize > 0) {
      const kx = w / (root.x1 - root.x0);
      nodeList = nodeList.filter(function(el) {
        return (el.x1 - el.x0) * kx > minFrameSize;
      });
    }
    return nodeList;
  }
  function update() {
    selection.each(function(root) {
      const x = Object(d3_scale__WEBPACK_IMPORTED_MODULE_4__["scaleLinear"])().range([0, w]);
      const y = Object(d3_scale__WEBPACK_IMPORTED_MODULE_4__["scaleLinear"])().range([0, c]);
      if (sort) root.sort(doSort);
      reappraiseNode(root);
      p(root);
      const kx = w / (root.x1 - root.x0);
      function width(d) {
        return (d.x1 - d.x0) * kx;
      }
      const descendants = filterNodes(root);
      const svg = Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["select"])(this).select("svg");
      svg.attr("width", w);
      let g = svg.selectAll("g").data(descendants, function(d) {
        return d.id;
      });
      if (!h || resetHeightOnZoom) {
        let maxDepth = 0;
        for (let i = 0; i < descendants.length; ++i) {
          if (descendants[i].depth > maxDepth) {
            maxDepth = descendants[i].depth;
          }
        }
        h = (maxDepth + 3) * c;
        if (h < minHeight) h = minHeight;
        svg.attr("height", h);
      }
      g.transition().duration(transitionDuration).ease(transitionEase).attr("transform", function(d) {
        return "translate(" + x(d.x0) + "," + (inverted ? y(d.depth) : h - y(d.depth) - c) + ")";
      });
      g.select("rect").transition().duration(transitionDuration).ease(transitionEase).attr("width", width);
      const node = g.enter().append("svg:g").attr("transform", function(d) {
        return "translate(" + x(d.x0) + "," + (inverted ? y(d.depth) : h - y(d.depth) - c) + ")";
      });
      node.append("svg:rect").transition().delay(transitionDuration / 2).attr("width", width);
      if (!tooltip2) {
        node.append("svg:title");
      }
      node.append("foreignObject").append("xhtml:div");
      g = svg.selectAll("g").data(descendants, function(d) {
        return d.id;
      });
      g.attr("width", width).attr("height", function(_) {
        return c;
      }).attr("name", function(d) {
        return getName(d);
      }).attr("class", function(d) {
        return d.data.fade ? "frame fade" : "frame";
      });
      g.select("rect").attr("height", function(_) {
        return c;
      }).attr("fill", function(d) {
        return colorMapper2(d);
      });
      if (!tooltip2) {
        g.select("title").text(labelHandler);
      }
      g.select("foreignObject").attr("width", width).attr("height", function(_) {
        return c;
      }).style("pointer-events", "none").select("div").attr("class", "d3-flame-graph-label").style("display", function(d) {
        return width(d) < 35 ? "none" : "block";
      }).transition().delay(transitionDuration).text(getName);
      g.on("click", function(event, d) {
        zoom(d, this);
      });
      g.exit().remove();
      g.on("mouseover", function(event, d) {
        if (tooltip2) tooltip2.show(event, d);
        detailsHandler(labelHandler(d));
        if (typeof hoverHandler === "function") {
          hoverHandler(d);
        }
      }).on("mouseout", function() {
        if (tooltip2) tooltip2.hide();
        detailsHandler(null);
      });
    });
  }
  function merge(data, samples) {
    samples.forEach(function(sample) {
      const node = data.find(function(element) {
        return element.name === sample.name;
      });
      if (node) {
        node.value += sample.value;
        if (sample.children) {
          if (!node.children) {
            node.children = [];
          }
          merge(node.children, sample.children);
        }
      } else {
        data.push(sample);
      }
    });
  }
  function forEachNode(node, f) {
    f(node);
    let children = node.children;
    if (children) {
      const stack = [children];
      let count, child, grandChildren;
      while (stack.length) {
        children = stack.pop();
        count = children.length;
        while (count--) {
          child = children[count];
          f(child);
          grandChildren = child.children;
          if (grandChildren) {
            stack.push(grandChildren);
          }
        }
      }
    }
  }
  function adoptNode(node) {
    let id = 0;
    forEachNode(node, function(n) {
      n.id = id++;
    });
  }
  function reappraiseNode(root) {
    let node, children, grandChildren, childrenValue, i, j, child, childValue;
    const stack = [];
    const included = [];
    const excluded = [];
    const compoundValue = !selfValue;
    let item = root.data;
    if (item.hide) {
      root.value = 0;
      children = root.children;
      if (children) {
        excluded.push(children);
      }
    } else {
      root.value = item.fade ? 0 : getValue(item);
      stack.push(root);
    }
    while (node = stack.pop()) {
      children = node.children;
      if (children && (i = children.length)) {
        childrenValue = 0;
        while (i--) {
          child = children[i];
          item = child.data;
          if (item.hide) {
            child.value = 0;
            grandChildren = child.children;
            if (grandChildren) {
              excluded.push(grandChildren);
            }
            continue;
          }
          if (item.fade) {
            child.value = 0;
          } else {
            childValue = getValue(item);
            child.value = childValue;
            childrenValue += childValue;
          }
          stack.push(child);
        }
        if (compoundValue && node.value) {
          node.value -= childrenValue;
        }
        included.push(children);
      }
    }
    i = included.length;
    while (i--) {
      children = included[i];
      childrenValue = 0;
      j = children.length;
      while (j--) {
        childrenValue += children[j].value;
      }
      children[0].parent.value += childrenValue;
    }
    while (excluded.length) {
      children = excluded.pop();
      j = children.length;
      while (j--) {
        child = children[j];
        child.value = 0;
        grandChildren = child.children;
        if (grandChildren) {
          excluded.push(grandChildren);
        }
      }
    }
  }
  function processData() {
    selection.datum((data) => {
      if (data.constructor.name !== "Node") {
        const root = Object(d3_hierarchy__WEBPACK_IMPORTED_MODULE_3__["hierarchy"])(data, getChildren);
        adoptNode(root);
        reappraiseNode(root);
        root.originalValue = root.value;
        if (computeDelta) {
          root.eachAfter((node) => {
            let sum = getDelta(node);
            const children = node.children;
            let i = children && children.length;
            while (--i >= 0) sum += children[i].delta;
            node.delta = sum;
          });
        }
        return root;
      }
    });
  }
  function chart(s) {
    if (!arguments.length) {
      return chart;
    }
    selection = s;
    processData();
    selection.each(function(_) {
      if (Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["select"])(this).select("svg").size() === 0) {
        const svg = Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["select"])(this).append("svg:svg").attr("width", w).attr("class", "partition d3-flame-graph");
        if (h) {
          if (h < minHeight) h = minHeight;
          svg.attr("height", h);
        }
        svg.append("svg:text").attr("class", "title").attr("text-anchor", "middle").attr("y", "25").attr("x", w / 2).attr("fill", "#808080").text(title);
        if (tooltip2) svg.call(tooltip2);
      }
    });
    update();
  }
  chart.height = function(_) {
    if (!arguments.length) {
      return h;
    }
    h = _;
    return chart;
  };
  chart.minHeight = function(_) {
    if (!arguments.length) {
      return minHeight;
    }
    minHeight = _;
    return chart;
  };
  chart.width = function(_) {
    if (!arguments.length) {
      return w;
    }
    w = _;
    return chart;
  };
  chart.cellHeight = function(_) {
    if (!arguments.length) {
      return c;
    }
    c = _;
    return chart;
  };
  chart.tooltip = function(_) {
    if (!arguments.length) {
      return tooltip2;
    }
    if (typeof _ === "function") {
      tooltip2 = _;
    }
    return chart;
  };
  chart.title = function(_) {
    if (!arguments.length) {
      return title;
    }
    title = _;
    return chart;
  };
  chart.transitionDuration = function(_) {
    if (!arguments.length) {
      return transitionDuration;
    }
    transitionDuration = _;
    return chart;
  };
  chart.transitionEase = function(_) {
    if (!arguments.length) {
      return transitionEase;
    }
    transitionEase = _;
    return chart;
  };
  chart.sort = function(_) {
    if (!arguments.length) {
      return sort;
    }
    sort = _;
    return chart;
  };
  chart.inverted = function(_) {
    if (!arguments.length) {
      return inverted;
    }
    inverted = _;
    return chart;
  };
  chart.computeDelta = function(_) {
    if (!arguments.length) {
      return computeDelta;
    }
    computeDelta = _;
    return chart;
  };
  chart.setLabelHandler = function(_) {
    if (!arguments.length) {
      return labelHandler;
    }
    labelHandler = _;
    return chart;
  };
  chart.label = chart.setLabelHandler;
  chart.search = function(term) {
    const searchResults = [];
    let searchSum = 0;
    let totalValue = 0;
    selection.each(function(data) {
      const res = searchTree(data, term);
      searchResults.push(...res[0]);
      searchSum += res[1];
      totalValue += data.originalValue;
    });
    searchHandler(searchResults, searchSum, totalValue);
    update();
  };
  chart.findById = function(id) {
    if (typeof id === "undefined" || id === null) {
      return null;
    }
    let found = null;
    selection.each(function(data) {
      if (found === null) {
        found = findTree(data, id);
      }
    });
    return found;
  };
  chart.clear = function() {
    detailsHandler(null);
    selection.each(function(root) {
      clear(root);
      update();
    });
  };
  chart.zoomTo = function(d) {
    zoom(d, selection.node());
  };
  chart.resetZoom = function() {
    selection.each(function(root) {
      zoom(root, selection.node());
    });
  };
  chart.onClick = function(_) {
    if (!arguments.length) {
      return clickHandler;
    }
    clickHandler = _;
    return chart;
  };
  chart.onHover = function(_) {
    if (!arguments.length) {
      return hoverHandler;
    }
    hoverHandler = _;
    return chart;
  };
  chart.merge = function(data) {
    if (!selection) {
      return chart;
    }
    this.resetZoom();
    searchDetails = null;
    detailsHandler(null);
    selection.datum((root) => {
      merge([root.data], [data]);
      return root.data;
    });
    processData();
    update();
    return chart;
  };
  chart.update = function(data) {
    if (!selection) {
      return chart;
    }
    if (data) {
      selection.datum(data);
      processData();
    }
    update();
    return chart;
  };
  chart.destroy = function() {
    if (!selection) {
      return chart;
    }
    if (tooltip2) {
      tooltip2.hide();
      if (typeof tooltip2.destroy === "function") {
        tooltip2.destroy();
      }
    }
    selection.selectAll("svg").remove();
    return chart;
  };
  chart.setColorMapper = function(_) {
    if (!arguments.length) {
      colorMapper2 = originalColorMapper;
      return chart;
    }
    colorMapper2 = (d) => {
      const originalColor = originalColorMapper(d);
      return _(d, originalColor);
    };
    return chart;
  };
  chart.color = chart.setColorMapper;
  chart.setColorHue = function(_) {
    if (!arguments.length) {
      colorHue = null;
      return chart;
    }
    colorHue = _;
    return chart;
  };
  chart.minFrameSize = function(_) {
    if (!arguments.length) {
      return minFrameSize;
    }
    minFrameSize = _;
    return chart;
  };
  chart.setDetailsElement = function(_) {
    if (!arguments.length) {
      return detailsElement;
    }
    detailsElement = _;
    return chart;
  };
  chart.details = chart.setDetailsElement;
  chart.selfValue = function(_) {
    if (!arguments.length) {
      return selfValue;
    }
    selfValue = _;
    return chart;
  };
  chart.resetHeightOnZoom = function(_) {
    if (!arguments.length) {
      return resetHeightOnZoom;
    }
    resetHeightOnZoom = _;
    return chart;
  };
  chart.scrollOnZoom = function(_) {
    if (!arguments.length) {
      return scrollOnZoom;
    }
    scrollOnZoom = _;
    return chart;
  };
  chart.getName = function(_) {
    if (!arguments.length) {
      return getName;
    }
    getName = _;
    return chart;
  };
  chart.getValue = function(_) {
    if (!arguments.length) {
      return getValue;
    }
    getValue = _;
    return chart;
  };
  chart.getChildren = function(_) {
    if (!arguments.length) {
      return getChildren;
    }
    getChildren = _;
    return chart;
  };
  chart.getLibtype = function(_) {
    if (!arguments.length) {
      return getLibtype;
    }
    getLibtype = _;
    return chart;
  };
  chart.getDelta = function(_) {
    if (!arguments.length) {
      return getDelta;
    }
    getDelta = _;
    return chart;
  };
  chart.setSearchHandler = function(_) {
    if (!arguments.length) {
      searchHandler = originalSearchHandler;
      return chart;
    }
    searchHandler = _;
    return chart;
  };
  chart.setDetailsHandler = function(_) {
    if (!arguments.length) {
      detailsHandler = originalDetailsHandler;
      return chart;
    }
    detailsHandler = _;
    return chart;
  };
  chart.setSearchMatch = function(_) {
    if (!arguments.length) {
      searchMatch = originalSearchMatch;
      return chart;
    }
    searchMatch = _;
    return chart;
  };
  return chart;
}



/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/array.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/array.js ***!
  \************************************************************************/
/*! exports provided: slice, map */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "slice", function() { return slice; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "map", function() { return map; });
var array = Array.prototype;

var slice = array.slice;
var map = array.map;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return ascending; });
function ascending(a, b) {
  return a == null || b == null ? NaN : a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/bin.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/bin.js ***!
  \**********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return bin; });
/* harmony import */ var _array_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./array.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/array.js");
/* harmony import */ var _bisect_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./bisect.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/bisect.js");
/* harmony import */ var _constant_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constant.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/constant.js");
/* harmony import */ var _extent_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./extent.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/extent.js");
/* harmony import */ var _identity_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./identity.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/identity.js");
/* harmony import */ var _nice_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./nice.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/nice.js");
/* harmony import */ var _ticks_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./ticks.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ticks.js");
/* harmony import */ var _threshold_sturges_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./threshold/sturges.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/sturges.js");









function bin() {
  var value = _identity_js__WEBPACK_IMPORTED_MODULE_4__["default"],
      domain = _extent_js__WEBPACK_IMPORTED_MODULE_3__["default"],
      threshold = _threshold_sturges_js__WEBPACK_IMPORTED_MODULE_7__["default"];

  function histogram(data) {
    if (!Array.isArray(data)) data = Array.from(data);

    var i,
        n = data.length,
        x,
        step,
        values = new Array(n);

    for (i = 0; i < n; ++i) {
      values[i] = value(data[i], i, data);
    }

    var xz = domain(values),
        x0 = xz[0],
        x1 = xz[1],
        tz = threshold(values, x0, x1);

    // Convert number of thresholds into uniform thresholds, and nice the
    // default domain accordingly.
    if (!Array.isArray(tz)) {
      const max = x1, tn = +tz;
      if (domain === _extent_js__WEBPACK_IMPORTED_MODULE_3__["default"]) [x0, x1] = Object(_nice_js__WEBPACK_IMPORTED_MODULE_5__["default"])(x0, x1, tn);
      tz = Object(_ticks_js__WEBPACK_IMPORTED_MODULE_6__["default"])(x0, x1, tn);

      // If the domain is aligned with the first tick (which it will by
      // default), then we can use quantization rather than bisection to bin
      // values, which is substantially faster.
      if (tz[0] <= x0) step = Object(_ticks_js__WEBPACK_IMPORTED_MODULE_6__["tickIncrement"])(x0, x1, tn);

      // If the last threshold is coincident with the domain’s upper bound, the
      // last bin will be zero-width. If the default domain is used, and this
      // last threshold is coincident with the maximum input value, we can
      // extend the niced upper bound by one tick to ensure uniform bin widths;
      // otherwise, we simply remove the last threshold. Note that we don’t
      // coerce values or the domain to numbers, and thus must be careful to
      // compare order (>=) rather than strict equality (===)!
      if (tz[tz.length - 1] >= x1) {
        if (max >= x1 && domain === _extent_js__WEBPACK_IMPORTED_MODULE_3__["default"]) {
          const step = Object(_ticks_js__WEBPACK_IMPORTED_MODULE_6__["tickIncrement"])(x0, x1, tn);
          if (isFinite(step)) {
            if (step > 0) {
              x1 = (Math.floor(x1 / step) + 1) * step;
            } else if (step < 0) {
              x1 = (Math.ceil(x1 * -step) + 1) / -step;
            }
          }
        } else {
          tz.pop();
        }
      }
    }

    // Remove any thresholds outside the domain.
    // Be careful not to mutate an array owned by the user!
    var m = tz.length, a = 0, b = m;
    while (tz[a] <= x0) ++a;
    while (tz[b - 1] > x1) --b;
    if (a || b < m) tz = tz.slice(a, b), m = b - a;

    var bins = new Array(m + 1),
        bin;

    // Initialize bins.
    for (i = 0; i <= m; ++i) {
      bin = bins[i] = [];
      bin.x0 = i > 0 ? tz[i - 1] : x0;
      bin.x1 = i < m ? tz[i] : x1;
    }

    // Assign data to bins by value, ignoring any outside the domain.
    if (isFinite(step)) {
      if (step > 0) {
        for (i = 0; i < n; ++i) {
          if ((x = values[i]) != null && x0 <= x && x <= x1) {
            bins[Math.min(m, Math.floor((x - x0) / step))].push(data[i]);
          }
        }
      } else if (step < 0) {
        for (i = 0; i < n; ++i) {
          if ((x = values[i]) != null && x0 <= x && x <= x1) {
            const j = Math.floor((x0 - x) * step);
            bins[Math.min(m, j + (tz[j] <= x))].push(data[i]); // handle off-by-one due to rounding
          }
        }
      }
    } else {
      for (i = 0; i < n; ++i) {
        if ((x = values[i]) != null && x0 <= x && x <= x1) {
          bins[Object(_bisect_js__WEBPACK_IMPORTED_MODULE_1__["default"])(tz, x, 0, m)].push(data[i]);
        }
      }
    }

    return bins;
  }

  histogram.value = function(_) {
    return arguments.length ? (value = typeof _ === "function" ? _ : Object(_constant_js__WEBPACK_IMPORTED_MODULE_2__["default"])(_), histogram) : value;
  };

  histogram.domain = function(_) {
    return arguments.length ? (domain = typeof _ === "function" ? _ : Object(_constant_js__WEBPACK_IMPORTED_MODULE_2__["default"])([_[0], _[1]]), histogram) : domain;
  };

  histogram.thresholds = function(_) {
    return arguments.length ? (threshold = typeof _ === "function" ? _ : Object(_constant_js__WEBPACK_IMPORTED_MODULE_2__["default"])(Array.isArray(_) ? _array_js__WEBPACK_IMPORTED_MODULE_0__["slice"].call(_) : _), histogram) : threshold;
  };

  return histogram;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/bisect.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/bisect.js ***!
  \*************************************************************************/
/*! exports provided: bisectRight, bisectLeft, bisectCenter, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "bisectRight", function() { return bisectRight; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "bisectLeft", function() { return bisectLeft; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "bisectCenter", function() { return bisectCenter; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");
/* harmony import */ var _bisector_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./bisector.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/bisector.js");
/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./number.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/number.js");




const ascendingBisect = Object(_bisector_js__WEBPACK_IMPORTED_MODULE_1__["default"])(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"]);
const bisectRight = ascendingBisect.right;
const bisectLeft = ascendingBisect.left;
const bisectCenter = Object(_bisector_js__WEBPACK_IMPORTED_MODULE_1__["default"])(_number_js__WEBPACK_IMPORTED_MODULE_2__["default"]).center;
/* harmony default export */ __webpack_exports__["default"] = (bisectRight);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/bisector.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/bisector.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return bisector; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");
/* harmony import */ var _descending_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./descending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/descending.js");



function bisector(f) {
  let compare1, compare2, delta;

  // If an accessor is specified, promote it to a comparator. In this case we
  // can test whether the search value is (self-) comparable. We can’t do this
  // for a comparator (except for specific, known comparators) because we can’t
  // tell if the comparator is symmetric, and an asymmetric comparator can’t be
  // used to test whether a single value is comparable.
  if (f.length !== 2) {
    compare1 = _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"];
    compare2 = (d, x) => Object(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"])(f(d), x);
    delta = (d, x) => f(d) - x;
  } else {
    compare1 = f === _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"] || f === _descending_js__WEBPACK_IMPORTED_MODULE_1__["default"] ? f : zero;
    compare2 = f;
    delta = f;
  }

  function left(a, x, lo = 0, hi = a.length) {
    if (lo < hi) {
      if (compare1(x, x) !== 0) return hi;
      do {
        const mid = (lo + hi) >>> 1;
        if (compare2(a[mid], x) < 0) lo = mid + 1;
        else hi = mid;
      } while (lo < hi);
    }
    return lo;
  }

  function right(a, x, lo = 0, hi = a.length) {
    if (lo < hi) {
      if (compare1(x, x) !== 0) return hi;
      do {
        const mid = (lo + hi) >>> 1;
        if (compare2(a[mid], x) <= 0) lo = mid + 1;
        else hi = mid;
      } while (lo < hi);
    }
    return lo;
  }

  function center(a, x, lo = 0, hi = a.length) {
    const i = left(a, x, lo, hi - 1);
    return i > lo && delta(a[i - 1], x) > -delta(a[i], x) ? i - 1 : i;
  }

  return {left, center, right};
}

function zero() {
  return 0;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/blur.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/blur.js ***!
  \***********************************************************************/
/*! exports provided: blur, blur2, blurImage */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "blur", function() { return blur; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "blur2", function() { return blur2; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "blurImage", function() { return blurImage; });
function blur(values, r) {
  if (!((r = +r) >= 0)) throw new RangeError("invalid r");
  let length = values.length;
  if (!((length = Math.floor(length)) >= 0)) throw new RangeError("invalid length");
  if (!length || !r) return values;
  const blur = blurf(r);
  const temp = values.slice();
  blur(values, temp, 0, length, 1);
  blur(temp, values, 0, length, 1);
  blur(values, temp, 0, length, 1);
  return values;
}

const blur2 = Blur2(blurf);

const blurImage = Blur2(blurfImage);

function Blur2(blur) {
  return function(data, rx, ry = rx) {
    if (!((rx = +rx) >= 0)) throw new RangeError("invalid rx");
    if (!((ry = +ry) >= 0)) throw new RangeError("invalid ry");
    let {data: values, width, height} = data;
    if (!((width = Math.floor(width)) >= 0)) throw new RangeError("invalid width");
    if (!((height = Math.floor(height !== undefined ? height : values.length / width)) >= 0)) throw new RangeError("invalid height");
    if (!width || !height || (!rx && !ry)) return data;
    const blurx = rx && blur(rx);
    const blury = ry && blur(ry);
    const temp = values.slice();
    if (blurx && blury) {
      blurh(blurx, temp, values, width, height);
      blurh(blurx, values, temp, width, height);
      blurh(blurx, temp, values, width, height);
      blurv(blury, values, temp, width, height);
      blurv(blury, temp, values, width, height);
      blurv(blury, values, temp, width, height);
    } else if (blurx) {
      blurh(blurx, values, temp, width, height);
      blurh(blurx, temp, values, width, height);
      blurh(blurx, values, temp, width, height);
    } else if (blury) {
      blurv(blury, values, temp, width, height);
      blurv(blury, temp, values, width, height);
      blurv(blury, values, temp, width, height);
    }
    return data;
  };
}

function blurh(blur, T, S, w, h) {
  for (let y = 0, n = w * h; y < n;) {
    blur(T, S, y, y += w, 1);
  }
}

function blurv(blur, T, S, w, h) {
  for (let x = 0, n = w * h; x < w; ++x) {
    blur(T, S, x, x + n, w);
  }
}

function blurfImage(radius) {
  const blur = blurf(radius);
  return (T, S, start, stop, step) => {
    start <<= 2, stop <<= 2, step <<= 2;
    blur(T, S, start + 0, stop + 0, step);
    blur(T, S, start + 1, stop + 1, step);
    blur(T, S, start + 2, stop + 2, step);
    blur(T, S, start + 3, stop + 3, step);
  };
}

// Given a target array T, a source array S, sets each value T[i] to the average
// of {S[i - r], …, S[i], …, S[i + r]}, where r = ⌊radius⌋, start <= i < stop,
// for each i, i + step, i + 2 * step, etc., and where S[j] is clamped between
// S[start] (inclusive) and S[stop] (exclusive). If the given radius is not an
// integer, S[i - r - 1] and S[i + r + 1] are added to the sum, each weighted
// according to r - ⌊radius⌋.
function blurf(radius) {
  const radius0 = Math.floor(radius);
  if (radius0 === radius) return bluri(radius);
  const t = radius - radius0;
  const w = 2 * radius + 1;
  return (T, S, start, stop, step) => { // stop must be aligned!
    if (!((stop -= step) >= start)) return; // inclusive stop
    let sum = radius0 * S[start];
    const s0 = step * radius0;
    const s1 = s0 + step;
    for (let i = start, j = start + s0; i < j; i += step) {
      sum += S[Math.min(stop, i)];
    }
    for (let i = start, j = stop; i <= j; i += step) {
      sum += S[Math.min(stop, i + s0)];
      T[i] = (sum + t * (S[Math.max(start, i - s1)] + S[Math.min(stop, i + s1)])) / w;
      sum -= S[Math.max(start, i - s0)];
    }
  };
}

// Like blurf, but optimized for integer radius.
function bluri(radius) {
  const w = 2 * radius + 1;
  return (T, S, start, stop, step) => { // stop must be aligned!
    if (!((stop -= step) >= start)) return; // inclusive stop
    let sum = radius * S[start];
    const s = step * radius;
    for (let i = start, j = start + s; i < j; i += step) {
      sum += S[Math.min(stop, i)];
    }
    for (let i = start, j = stop; i <= j; i += step) {
      sum += S[Math.min(stop, i + s)];
      T[i] = sum / w;
      sum -= S[Math.max(start, i - s)];
    }
  };
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/constant.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/constant.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return constant; });
function constant(x) {
  return () => x;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/count.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/count.js ***!
  \************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return count; });
function count(values, valueof) {
  let count = 0;
  if (valueof === undefined) {
    for (let value of values) {
      if (value != null && (value = +value) >= value) {
        ++count;
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null && (value = +value) >= value) {
        ++count;
      }
    }
  }
  return count;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/cross.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/cross.js ***!
  \************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return cross; });
function length(array) {
  return array.length | 0;
}

function empty(length) {
  return !(length > 0);
}

function arrayify(values) {
  return typeof values !== "object" || "length" in values ? values : Array.from(values);
}

function reducer(reduce) {
  return values => reduce(...values);
}

function cross(...values) {
  const reduce = typeof values[values.length - 1] === "function" && reducer(values.pop());
  values = values.map(arrayify);
  const lengths = values.map(length);
  const j = values.length - 1;
  const index = new Array(j + 1).fill(0);
  const product = [];
  if (j < 0 || lengths.some(empty)) return product;
  while (true) {
    product.push(index.map((j, i) => values[i][j]));
    let i = j;
    while (++index[i] === lengths[i]) {
      if (i === 0) return reduce ? product.map(reduce) : product;
      index[i--] = 0;
    }
  }
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/cumsum.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/cumsum.js ***!
  \*************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return cumsum; });
function cumsum(values, valueof) {
  var sum = 0, index = 0;
  return Float64Array.from(values, valueof === undefined
    ? v => (sum += +v || 0)
    : v => (sum += +valueof(v, index++, values) || 0));
}

/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/descending.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/descending.js ***!
  \*****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return descending; });
function descending(a, b) {
  return a == null || b == null ? NaN
    : b < a ? -1
    : b > a ? 1
    : b >= a ? 0
    : NaN;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/deviation.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/deviation.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return deviation; });
/* harmony import */ var _variance_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./variance.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/variance.js");


function deviation(values, valueof) {
  const v = Object(_variance_js__WEBPACK_IMPORTED_MODULE_0__["default"])(values, valueof);
  return v ? Math.sqrt(v) : v;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/difference.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/difference.js ***!
  \*****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return difference; });
/* harmony import */ var internmap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! internmap */ "./node_modules/internmap/src/index.js");


function difference(values, ...others) {
  values = new internmap__WEBPACK_IMPORTED_MODULE_0__["InternSet"](values);
  for (const other of others) {
    for (const value of other) {
      values.delete(value);
    }
  }
  return values;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/disjoint.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/disjoint.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return disjoint; });
/* harmony import */ var internmap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! internmap */ "./node_modules/internmap/src/index.js");


function disjoint(values, other) {
  const iterator = other[Symbol.iterator](), set = new internmap__WEBPACK_IMPORTED_MODULE_0__["InternSet"]();
  for (const v of values) {
    if (set.has(v)) return false;
    let value, done;
    while (({value, done} = iterator.next())) {
      if (done) break;
      if (Object.is(v, value)) return false;
      set.add(value);
    }
  }
  return true;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/every.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/every.js ***!
  \************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return every; });
function every(values, test) {
  if (typeof test !== "function") throw new TypeError("test is not a function");
  let index = -1;
  for (const value of values) {
    if (!test(value, ++index, values)) {
      return false;
    }
  }
  return true;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/extent.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/extent.js ***!
  \*************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return extent; });
function extent(values, valueof) {
  let min;
  let max;
  if (valueof === undefined) {
    for (const value of values) {
      if (value != null) {
        if (min === undefined) {
          if (value >= value) min = max = value;
        } else {
          if (min > value) min = value;
          if (max < value) max = value;
        }
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null) {
        if (min === undefined) {
          if (value >= value) min = max = value;
        } else {
          if (min > value) min = value;
          if (max < value) max = value;
        }
      }
    }
  }
  return [min, max];
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/filter.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/filter.js ***!
  \*************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return filter; });
function filter(values, test) {
  if (typeof test !== "function") throw new TypeError("test is not a function");
  const array = [];
  let index = -1;
  for (const value of values) {
    if (test(value, ++index, values)) {
      array.push(value);
    }
  }
  return array;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/fsum.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/fsum.js ***!
  \***********************************************************************/
/*! exports provided: Adder, fsum, fcumsum */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Adder", function() { return Adder; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "fsum", function() { return fsum; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "fcumsum", function() { return fcumsum; });
// https://github.com/python/cpython/blob/a74eea238f5baba15797e2e8b570d153bc8690a7/Modules/mathmodule.c#L1423
class Adder {
  constructor() {
    this._partials = new Float64Array(32);
    this._n = 0;
  }
  add(x) {
    const p = this._partials;
    let i = 0;
    for (let j = 0; j < this._n && j < 32; j++) {
      const y = p[j],
        hi = x + y,
        lo = Math.abs(x) < Math.abs(y) ? x - (hi - y) : y - (hi - x);
      if (lo) p[i++] = lo;
      x = hi;
    }
    p[i] = x;
    this._n = i + 1;
    return this;
  }
  valueOf() {
    const p = this._partials;
    let n = this._n, x, y, lo, hi = 0;
    if (n > 0) {
      hi = p[--n];
      while (n > 0) {
        x = hi;
        y = p[--n];
        hi = x + y;
        lo = y - (hi - x);
        if (lo) break;
      }
      if (n > 0 && ((lo < 0 && p[n - 1] < 0) || (lo > 0 && p[n - 1] > 0))) {
        y = lo * 2;
        x = hi + y;
        if (y == x - hi) hi = x;
      }
    }
    return hi;
  }
}

function fsum(values, valueof) {
  const adder = new Adder();
  if (valueof === undefined) {
    for (let value of values) {
      if (value = +value) {
        adder.add(value);
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if (value = +valueof(value, ++index, values)) {
        adder.add(value);
      }
    }
  }
  return +adder;
}

function fcumsum(values, valueof) {
  const adder = new Adder();
  let index = -1;
  return Float64Array.from(values, valueof === undefined
      ? v => adder.add(+v || 0)
      : v => adder.add(+valueof(v, ++index, values) || 0)
  );
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/greatest.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/greatest.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return greatest; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");


function greatest(values, compare = _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"]) {
  let max;
  let defined = false;
  if (compare.length === 1) {
    let maxValue;
    for (const element of values) {
      const value = compare(element);
      if (defined
          ? Object(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"])(value, maxValue) > 0
          : Object(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"])(value, value) === 0) {
        max = element;
        maxValue = value;
        defined = true;
      }
    }
  } else {
    for (const value of values) {
      if (defined
          ? compare(value, max) > 0
          : compare(value, value) === 0) {
        max = value;
        defined = true;
      }
    }
  }
  return max;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/greatestIndex.js":
/*!********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/greatestIndex.js ***!
  \********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return greatestIndex; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");
/* harmony import */ var _maxIndex_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./maxIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/maxIndex.js");



function greatestIndex(values, compare = _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"]) {
  if (compare.length === 1) return Object(_maxIndex_js__WEBPACK_IMPORTED_MODULE_1__["default"])(values, compare);
  let maxValue;
  let max = -1;
  let index = -1;
  for (const value of values) {
    ++index;
    if (max < 0
        ? compare(value, value) === 0
        : compare(value, maxValue) > 0) {
      maxValue = value;
      max = index;
    }
  }
  return max;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/group.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/group.js ***!
  \************************************************************************/
/*! exports provided: default, groups, flatGroup, flatRollup, rollup, rollups, index, indexes */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return group; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "groups", function() { return groups; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "flatGroup", function() { return flatGroup; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "flatRollup", function() { return flatRollup; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rollup", function() { return rollup; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rollups", function() { return rollups; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "index", function() { return index; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "indexes", function() { return indexes; });
/* harmony import */ var internmap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! internmap */ "./node_modules/internmap/src/index.js");
/* harmony import */ var _identity_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./identity.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/identity.js");



function group(values, ...keys) {
  return nest(values, _identity_js__WEBPACK_IMPORTED_MODULE_1__["default"], _identity_js__WEBPACK_IMPORTED_MODULE_1__["default"], keys);
}

function groups(values, ...keys) {
  return nest(values, Array.from, _identity_js__WEBPACK_IMPORTED_MODULE_1__["default"], keys);
}

function flatten(groups, keys) {
  for (let i = 1, n = keys.length; i < n; ++i) {
    groups = groups.flatMap(g => g.pop().map(([key, value]) => [...g, key, value]));
  }
  return groups;
}

function flatGroup(values, ...keys) {
  return flatten(groups(values, ...keys), keys);
}

function flatRollup(values, reduce, ...keys) {
  return flatten(rollups(values, reduce, ...keys), keys);
}

function rollup(values, reduce, ...keys) {
  return nest(values, _identity_js__WEBPACK_IMPORTED_MODULE_1__["default"], reduce, keys);
}

function rollups(values, reduce, ...keys) {
  return nest(values, Array.from, reduce, keys);
}

function index(values, ...keys) {
  return nest(values, _identity_js__WEBPACK_IMPORTED_MODULE_1__["default"], unique, keys);
}

function indexes(values, ...keys) {
  return nest(values, Array.from, unique, keys);
}

function unique(values) {
  if (values.length !== 1) throw new Error("duplicate key");
  return values[0];
}

function nest(values, map, reduce, keys) {
  return (function regroup(values, i) {
    if (i >= keys.length) return reduce(values);
    const groups = new internmap__WEBPACK_IMPORTED_MODULE_0__["InternMap"]();
    const keyof = keys[i++];
    let index = -1;
    for (const value of values) {
      const key = keyof(value, ++index, values);
      const group = groups.get(key);
      if (group) group.push(value);
      else groups.set(key, [value]);
    }
    for (const [key, values] of groups) {
      groups.set(key, regroup(values, i));
    }
    return map(groups);
  })(values, 0);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/groupSort.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/groupSort.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return groupSort; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");
/* harmony import */ var _group_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./group.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/group.js");
/* harmony import */ var _sort_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./sort.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/sort.js");




function groupSort(values, reduce, key) {
  return (reduce.length !== 2
    ? Object(_sort_js__WEBPACK_IMPORTED_MODULE_2__["default"])(Object(_group_js__WEBPACK_IMPORTED_MODULE_1__["rollup"])(values, reduce, key), (([ak, av], [bk, bv]) => Object(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"])(av, bv) || Object(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"])(ak, bk)))
    : Object(_sort_js__WEBPACK_IMPORTED_MODULE_2__["default"])(Object(_group_js__WEBPACK_IMPORTED_MODULE_1__["default"])(values, key), (([ak, av], [bk, bv]) => reduce(av, bv) || Object(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"])(ak, bk))))
    .map(([key]) => key);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/identity.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/identity.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return identity; });
function identity(x) {
  return x;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js ***!
  \************************************************************************/
/*! exports provided: bisect, bisectRight, bisectLeft, bisectCenter, ascending, bisector, blur, blur2, blurImage, count, cross, cumsum, descending, deviation, extent, Adder, fsum, fcumsum, group, flatGroup, flatRollup, groups, index, indexes, rollup, rollups, groupSort, bin, histogram, thresholdFreedmanDiaconis, thresholdScott, thresholdSturges, max, maxIndex, mean, median, medianIndex, merge, min, minIndex, mode, nice, pairs, permute, quantile, quantileIndex, quantileSorted, quickselect, range, rank, least, leastIndex, greatest, greatestIndex, scan, shuffle, shuffler, sum, ticks, tickIncrement, tickStep, transpose, variance, zip, every, some, filter, map, reduce, reverse, sort, difference, disjoint, intersection, subset, superset, union, InternMap, InternSet */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _bisect_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./bisect.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/bisect.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "bisect", function() { return _bisect_js__WEBPACK_IMPORTED_MODULE_0__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "bisectRight", function() { return _bisect_js__WEBPACK_IMPORTED_MODULE_0__["bisectRight"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "bisectLeft", function() { return _bisect_js__WEBPACK_IMPORTED_MODULE_0__["bisectLeft"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "bisectCenter", function() { return _bisect_js__WEBPACK_IMPORTED_MODULE_0__["bisectCenter"]; });

/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "ascending", function() { return _ascending_js__WEBPACK_IMPORTED_MODULE_1__["default"]; });

/* harmony import */ var _bisector_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./bisector.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/bisector.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "bisector", function() { return _bisector_js__WEBPACK_IMPORTED_MODULE_2__["default"]; });

/* harmony import */ var _blur_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./blur.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/blur.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "blur", function() { return _blur_js__WEBPACK_IMPORTED_MODULE_3__["blur"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "blur2", function() { return _blur_js__WEBPACK_IMPORTED_MODULE_3__["blur2"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "blurImage", function() { return _blur_js__WEBPACK_IMPORTED_MODULE_3__["blurImage"]; });

/* harmony import */ var _count_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./count.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/count.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "count", function() { return _count_js__WEBPACK_IMPORTED_MODULE_4__["default"]; });

/* harmony import */ var _cross_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./cross.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/cross.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "cross", function() { return _cross_js__WEBPACK_IMPORTED_MODULE_5__["default"]; });

/* harmony import */ var _cumsum_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./cumsum.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/cumsum.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "cumsum", function() { return _cumsum_js__WEBPACK_IMPORTED_MODULE_6__["default"]; });

/* harmony import */ var _descending_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./descending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/descending.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "descending", function() { return _descending_js__WEBPACK_IMPORTED_MODULE_7__["default"]; });

/* harmony import */ var _deviation_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./deviation.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/deviation.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "deviation", function() { return _deviation_js__WEBPACK_IMPORTED_MODULE_8__["default"]; });

/* harmony import */ var _extent_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./extent.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/extent.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "extent", function() { return _extent_js__WEBPACK_IMPORTED_MODULE_9__["default"]; });

/* harmony import */ var _fsum_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./fsum.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/fsum.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "Adder", function() { return _fsum_js__WEBPACK_IMPORTED_MODULE_10__["Adder"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "fsum", function() { return _fsum_js__WEBPACK_IMPORTED_MODULE_10__["fsum"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "fcumsum", function() { return _fsum_js__WEBPACK_IMPORTED_MODULE_10__["fcumsum"]; });

/* harmony import */ var _group_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./group.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/group.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "group", function() { return _group_js__WEBPACK_IMPORTED_MODULE_11__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "flatGroup", function() { return _group_js__WEBPACK_IMPORTED_MODULE_11__["flatGroup"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "flatRollup", function() { return _group_js__WEBPACK_IMPORTED_MODULE_11__["flatRollup"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "groups", function() { return _group_js__WEBPACK_IMPORTED_MODULE_11__["groups"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "index", function() { return _group_js__WEBPACK_IMPORTED_MODULE_11__["index"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "indexes", function() { return _group_js__WEBPACK_IMPORTED_MODULE_11__["indexes"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "rollup", function() { return _group_js__WEBPACK_IMPORTED_MODULE_11__["rollup"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "rollups", function() { return _group_js__WEBPACK_IMPORTED_MODULE_11__["rollups"]; });

/* harmony import */ var _groupSort_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./groupSort.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/groupSort.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "groupSort", function() { return _groupSort_js__WEBPACK_IMPORTED_MODULE_12__["default"]; });

/* harmony import */ var _bin_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./bin.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/bin.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "bin", function() { return _bin_js__WEBPACK_IMPORTED_MODULE_13__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "histogram", function() { return _bin_js__WEBPACK_IMPORTED_MODULE_13__["default"]; });

/* harmony import */ var _threshold_freedmanDiaconis_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./threshold/freedmanDiaconis.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/freedmanDiaconis.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "thresholdFreedmanDiaconis", function() { return _threshold_freedmanDiaconis_js__WEBPACK_IMPORTED_MODULE_14__["default"]; });

/* harmony import */ var _threshold_scott_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./threshold/scott.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/scott.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "thresholdScott", function() { return _threshold_scott_js__WEBPACK_IMPORTED_MODULE_15__["default"]; });

/* harmony import */ var _threshold_sturges_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./threshold/sturges.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/sturges.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "thresholdSturges", function() { return _threshold_sturges_js__WEBPACK_IMPORTED_MODULE_16__["default"]; });

/* harmony import */ var _max_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./max.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/max.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "max", function() { return _max_js__WEBPACK_IMPORTED_MODULE_17__["default"]; });

/* harmony import */ var _maxIndex_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./maxIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/maxIndex.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "maxIndex", function() { return _maxIndex_js__WEBPACK_IMPORTED_MODULE_18__["default"]; });

/* harmony import */ var _mean_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./mean.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/mean.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "mean", function() { return _mean_js__WEBPACK_IMPORTED_MODULE_19__["default"]; });

/* harmony import */ var _median_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./median.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/median.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "median", function() { return _median_js__WEBPACK_IMPORTED_MODULE_20__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "medianIndex", function() { return _median_js__WEBPACK_IMPORTED_MODULE_20__["medianIndex"]; });

/* harmony import */ var _merge_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ./merge.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/merge.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "merge", function() { return _merge_js__WEBPACK_IMPORTED_MODULE_21__["default"]; });

/* harmony import */ var _min_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./min.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/min.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "min", function() { return _min_js__WEBPACK_IMPORTED_MODULE_22__["default"]; });

/* harmony import */ var _minIndex_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ./minIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/minIndex.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "minIndex", function() { return _minIndex_js__WEBPACK_IMPORTED_MODULE_23__["default"]; });

/* harmony import */ var _mode_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ./mode.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/mode.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "mode", function() { return _mode_js__WEBPACK_IMPORTED_MODULE_24__["default"]; });

/* harmony import */ var _nice_js__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ./nice.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/nice.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "nice", function() { return _nice_js__WEBPACK_IMPORTED_MODULE_25__["default"]; });

/* harmony import */ var _pairs_js__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ./pairs.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/pairs.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "pairs", function() { return _pairs_js__WEBPACK_IMPORTED_MODULE_26__["default"]; });

/* harmony import */ var _permute_js__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./permute.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/permute.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "permute", function() { return _permute_js__WEBPACK_IMPORTED_MODULE_27__["default"]; });

/* harmony import */ var _quantile_js__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ./quantile.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/quantile.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "quantile", function() { return _quantile_js__WEBPACK_IMPORTED_MODULE_28__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "quantileIndex", function() { return _quantile_js__WEBPACK_IMPORTED_MODULE_28__["quantileIndex"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "quantileSorted", function() { return _quantile_js__WEBPACK_IMPORTED_MODULE_28__["quantileSorted"]; });

/* harmony import */ var _quickselect_js__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ./quickselect.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/quickselect.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "quickselect", function() { return _quickselect_js__WEBPACK_IMPORTED_MODULE_29__["default"]; });

/* harmony import */ var _range_js__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ./range.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/range.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "range", function() { return _range_js__WEBPACK_IMPORTED_MODULE_30__["default"]; });

/* harmony import */ var _rank_js__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! ./rank.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/rank.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "rank", function() { return _rank_js__WEBPACK_IMPORTED_MODULE_31__["default"]; });

/* harmony import */ var _least_js__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ./least.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/least.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "least", function() { return _least_js__WEBPACK_IMPORTED_MODULE_32__["default"]; });

/* harmony import */ var _leastIndex_js__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! ./leastIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/leastIndex.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "leastIndex", function() { return _leastIndex_js__WEBPACK_IMPORTED_MODULE_33__["default"]; });

/* harmony import */ var _greatest_js__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(/*! ./greatest.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/greatest.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "greatest", function() { return _greatest_js__WEBPACK_IMPORTED_MODULE_34__["default"]; });

/* harmony import */ var _greatestIndex_js__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(/*! ./greatestIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/greatestIndex.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "greatestIndex", function() { return _greatestIndex_js__WEBPACK_IMPORTED_MODULE_35__["default"]; });

/* harmony import */ var _scan_js__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(/*! ./scan.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/scan.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scan", function() { return _scan_js__WEBPACK_IMPORTED_MODULE_36__["default"]; });

/* harmony import */ var _shuffle_js__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(/*! ./shuffle.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/shuffle.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "shuffle", function() { return _shuffle_js__WEBPACK_IMPORTED_MODULE_37__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "shuffler", function() { return _shuffle_js__WEBPACK_IMPORTED_MODULE_37__["shuffler"]; });

/* harmony import */ var _sum_js__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(/*! ./sum.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/sum.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "sum", function() { return _sum_js__WEBPACK_IMPORTED_MODULE_38__["default"]; });

/* harmony import */ var _ticks_js__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(/*! ./ticks.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ticks.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "ticks", function() { return _ticks_js__WEBPACK_IMPORTED_MODULE_39__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "tickIncrement", function() { return _ticks_js__WEBPACK_IMPORTED_MODULE_39__["tickIncrement"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "tickStep", function() { return _ticks_js__WEBPACK_IMPORTED_MODULE_39__["tickStep"]; });

/* harmony import */ var _transpose_js__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(/*! ./transpose.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/transpose.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "transpose", function() { return _transpose_js__WEBPACK_IMPORTED_MODULE_40__["default"]; });

/* harmony import */ var _variance_js__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(/*! ./variance.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/variance.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "variance", function() { return _variance_js__WEBPACK_IMPORTED_MODULE_41__["default"]; });

/* harmony import */ var _zip_js__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(/*! ./zip.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/zip.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "zip", function() { return _zip_js__WEBPACK_IMPORTED_MODULE_42__["default"]; });

/* harmony import */ var _every_js__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(/*! ./every.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/every.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "every", function() { return _every_js__WEBPACK_IMPORTED_MODULE_43__["default"]; });

/* harmony import */ var _some_js__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(/*! ./some.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/some.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "some", function() { return _some_js__WEBPACK_IMPORTED_MODULE_44__["default"]; });

/* harmony import */ var _filter_js__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(/*! ./filter.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/filter.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "filter", function() { return _filter_js__WEBPACK_IMPORTED_MODULE_45__["default"]; });

/* harmony import */ var _map_js__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(/*! ./map.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/map.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "map", function() { return _map_js__WEBPACK_IMPORTED_MODULE_46__["default"]; });

/* harmony import */ var _reduce_js__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(/*! ./reduce.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/reduce.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "reduce", function() { return _reduce_js__WEBPACK_IMPORTED_MODULE_47__["default"]; });

/* harmony import */ var _reverse_js__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(/*! ./reverse.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/reverse.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "reverse", function() { return _reverse_js__WEBPACK_IMPORTED_MODULE_48__["default"]; });

/* harmony import */ var _sort_js__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(/*! ./sort.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/sort.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "sort", function() { return _sort_js__WEBPACK_IMPORTED_MODULE_49__["default"]; });

/* harmony import */ var _difference_js__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(/*! ./difference.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/difference.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "difference", function() { return _difference_js__WEBPACK_IMPORTED_MODULE_50__["default"]; });

/* harmony import */ var _disjoint_js__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(/*! ./disjoint.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/disjoint.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "disjoint", function() { return _disjoint_js__WEBPACK_IMPORTED_MODULE_51__["default"]; });

/* harmony import */ var _intersection_js__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(/*! ./intersection.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/intersection.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "intersection", function() { return _intersection_js__WEBPACK_IMPORTED_MODULE_52__["default"]; });

/* harmony import */ var _subset_js__WEBPACK_IMPORTED_MODULE_53__ = __webpack_require__(/*! ./subset.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/subset.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "subset", function() { return _subset_js__WEBPACK_IMPORTED_MODULE_53__["default"]; });

/* harmony import */ var _superset_js__WEBPACK_IMPORTED_MODULE_54__ = __webpack_require__(/*! ./superset.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/superset.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "superset", function() { return _superset_js__WEBPACK_IMPORTED_MODULE_54__["default"]; });

/* harmony import */ var _union_js__WEBPACK_IMPORTED_MODULE_55__ = __webpack_require__(/*! ./union.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/union.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "union", function() { return _union_js__WEBPACK_IMPORTED_MODULE_55__["default"]; });

/* harmony import */ var internmap__WEBPACK_IMPORTED_MODULE_56__ = __webpack_require__(/*! internmap */ "./node_modules/internmap/src/index.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "InternMap", function() { return internmap__WEBPACK_IMPORTED_MODULE_56__["InternMap"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "InternSet", function() { return internmap__WEBPACK_IMPORTED_MODULE_56__["InternSet"]; });














 // Deprecated; use bin.






















 // Deprecated; use leastIndex.






















/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/intersection.js":
/*!*******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/intersection.js ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return intersection; });
/* harmony import */ var internmap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! internmap */ "./node_modules/internmap/src/index.js");


function intersection(values, ...others) {
  values = new internmap__WEBPACK_IMPORTED_MODULE_0__["InternSet"](values);
  others = others.map(set);
  out: for (const value of values) {
    for (const other of others) {
      if (!other.has(value)) {
        values.delete(value);
        continue out;
      }
    }
  }
  return values;
}

function set(values) {
  return values instanceof internmap__WEBPACK_IMPORTED_MODULE_0__["InternSet"] ? values : new internmap__WEBPACK_IMPORTED_MODULE_0__["InternSet"](values);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/least.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/least.js ***!
  \************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return least; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");


function least(values, compare = _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"]) {
  let min;
  let defined = false;
  if (compare.length === 1) {
    let minValue;
    for (const element of values) {
      const value = compare(element);
      if (defined
          ? Object(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"])(value, minValue) < 0
          : Object(_ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"])(value, value) === 0) {
        min = element;
        minValue = value;
        defined = true;
      }
    }
  } else {
    for (const value of values) {
      if (defined
          ? compare(value, min) < 0
          : compare(value, value) === 0) {
        min = value;
        defined = true;
      }
    }
  }
  return min;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/leastIndex.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/leastIndex.js ***!
  \*****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return leastIndex; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");
/* harmony import */ var _minIndex_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./minIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/minIndex.js");



function leastIndex(values, compare = _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"]) {
  if (compare.length === 1) return Object(_minIndex_js__WEBPACK_IMPORTED_MODULE_1__["default"])(values, compare);
  let minValue;
  let min = -1;
  let index = -1;
  for (const value of values) {
    ++index;
    if (min < 0
        ? compare(value, value) === 0
        : compare(value, minValue) < 0) {
      minValue = value;
      min = index;
    }
  }
  return min;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/map.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/map.js ***!
  \**********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return map; });
function map(values, mapper) {
  if (typeof values[Symbol.iterator] !== "function") throw new TypeError("values is not iterable");
  if (typeof mapper !== "function") throw new TypeError("mapper is not a function");
  return Array.from(values, (value, index) => mapper(value, index, values));
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/max.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/max.js ***!
  \**********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return max; });
function max(values, valueof) {
  let max;
  if (valueof === undefined) {
    for (const value of values) {
      if (value != null
          && (max < value || (max === undefined && value >= value))) {
        max = value;
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null
          && (max < value || (max === undefined && value >= value))) {
        max = value;
      }
    }
  }
  return max;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/maxIndex.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/maxIndex.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return maxIndex; });
function maxIndex(values, valueof) {
  let max;
  let maxIndex = -1;
  let index = -1;
  if (valueof === undefined) {
    for (const value of values) {
      ++index;
      if (value != null
          && (max < value || (max === undefined && value >= value))) {
        max = value, maxIndex = index;
      }
    }
  } else {
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null
          && (max < value || (max === undefined && value >= value))) {
        max = value, maxIndex = index;
      }
    }
  }
  return maxIndex;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/mean.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/mean.js ***!
  \***********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return mean; });
function mean(values, valueof) {
  let count = 0;
  let sum = 0;
  if (valueof === undefined) {
    for (let value of values) {
      if (value != null && (value = +value) >= value) {
        ++count, sum += value;
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null && (value = +value) >= value) {
        ++count, sum += value;
      }
    }
  }
  if (count) return sum / count;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/median.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/median.js ***!
  \*************************************************************************/
/*! exports provided: default, medianIndex */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return median; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "medianIndex", function() { return medianIndex; });
/* harmony import */ var _quantile_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./quantile.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/quantile.js");


function median(values, valueof) {
  return Object(_quantile_js__WEBPACK_IMPORTED_MODULE_0__["default"])(values, 0.5, valueof);
}

function medianIndex(values, valueof) {
  return Object(_quantile_js__WEBPACK_IMPORTED_MODULE_0__["quantileIndex"])(values, 0.5, valueof);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/merge.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/merge.js ***!
  \************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return merge; });
function* flatten(arrays) {
  for (const array of arrays) {
    yield* array;
  }
}

function merge(arrays) {
  return Array.from(flatten(arrays));
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/min.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/min.js ***!
  \**********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return min; });
function min(values, valueof) {
  let min;
  if (valueof === undefined) {
    for (const value of values) {
      if (value != null
          && (min > value || (min === undefined && value >= value))) {
        min = value;
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null
          && (min > value || (min === undefined && value >= value))) {
        min = value;
      }
    }
  }
  return min;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/minIndex.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/minIndex.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return minIndex; });
function minIndex(values, valueof) {
  let min;
  let minIndex = -1;
  let index = -1;
  if (valueof === undefined) {
    for (const value of values) {
      ++index;
      if (value != null
          && (min > value || (min === undefined && value >= value))) {
        min = value, minIndex = index;
      }
    }
  } else {
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null
          && (min > value || (min === undefined && value >= value))) {
        min = value, minIndex = index;
      }
    }
  }
  return minIndex;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/mode.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/mode.js ***!
  \***********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return mode; });
/* harmony import */ var internmap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! internmap */ "./node_modules/internmap/src/index.js");


function mode(values, valueof) {
  const counts = new internmap__WEBPACK_IMPORTED_MODULE_0__["InternMap"]();
  if (valueof === undefined) {
    for (let value of values) {
      if (value != null && value >= value) {
        counts.set(value, (counts.get(value) || 0) + 1);
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null && value >= value) {
        counts.set(value, (counts.get(value) || 0) + 1);
      }
    }
  }
  let modeValue;
  let modeCount = 0;
  for (const [value, count] of counts) {
    if (count > modeCount) {
      modeCount = count;
      modeValue = value;
    }
  }
  return modeValue;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/nice.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/nice.js ***!
  \***********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return nice; });
/* harmony import */ var _ticks_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ticks.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ticks.js");


function nice(start, stop, count) {
  let prestep;
  while (true) {
    const step = Object(_ticks_js__WEBPACK_IMPORTED_MODULE_0__["tickIncrement"])(start, stop, count);
    if (step === prestep || step === 0 || !isFinite(step)) {
      return [start, stop];
    } else if (step > 0) {
      start = Math.floor(start / step) * step;
      stop = Math.ceil(stop / step) * step;
    } else if (step < 0) {
      start = Math.ceil(start * step) / step;
      stop = Math.floor(stop * step) / step;
    }
    prestep = step;
  }
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/number.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/number.js ***!
  \*************************************************************************/
/*! exports provided: default, numbers */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return number; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "numbers", function() { return numbers; });
function number(x) {
  return x === null ? NaN : +x;
}

function* numbers(values, valueof) {
  if (valueof === undefined) {
    for (let value of values) {
      if (value != null && (value = +value) >= value) {
        yield value;
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null && (value = +value) >= value) {
        yield value;
      }
    }
  }
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/pairs.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/pairs.js ***!
  \************************************************************************/
/*! exports provided: default, pair */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return pairs; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "pair", function() { return pair; });
function pairs(values, pairof = pair) {
  const pairs = [];
  let previous;
  let first = false;
  for (const value of values) {
    if (first) pairs.push(pairof(previous, value));
    previous = value;
    first = true;
  }
  return pairs;
}

function pair(a, b) {
  return [a, b];
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/permute.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/permute.js ***!
  \**************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return permute; });
function permute(source, keys) {
  return Array.from(keys, key => source[key]);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/quantile.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/quantile.js ***!
  \***************************************************************************/
/*! exports provided: default, quantileSorted, quantileIndex */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return quantile; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "quantileSorted", function() { return quantileSorted; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "quantileIndex", function() { return quantileIndex; });
/* harmony import */ var _max_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./max.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/max.js");
/* harmony import */ var _maxIndex_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./maxIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/maxIndex.js");
/* harmony import */ var _min_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./min.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/min.js");
/* harmony import */ var _minIndex_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./minIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/minIndex.js");
/* harmony import */ var _quickselect_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./quickselect.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/quickselect.js");
/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./number.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/number.js");
/* harmony import */ var _sort_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./sort.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/sort.js");
/* harmony import */ var _greatest_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./greatest.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/greatest.js");









function quantile(values, p, valueof) {
  values = Float64Array.from(Object(_number_js__WEBPACK_IMPORTED_MODULE_5__["numbers"])(values, valueof));
  if (!(n = values.length) || isNaN(p = +p)) return;
  if (p <= 0 || n < 2) return Object(_min_js__WEBPACK_IMPORTED_MODULE_2__["default"])(values);
  if (p >= 1) return Object(_max_js__WEBPACK_IMPORTED_MODULE_0__["default"])(values);
  var n,
      i = (n - 1) * p,
      i0 = Math.floor(i),
      value0 = Object(_max_js__WEBPACK_IMPORTED_MODULE_0__["default"])(Object(_quickselect_js__WEBPACK_IMPORTED_MODULE_4__["default"])(values, i0).subarray(0, i0 + 1)),
      value1 = Object(_min_js__WEBPACK_IMPORTED_MODULE_2__["default"])(values.subarray(i0 + 1));
  return value0 + (value1 - value0) * (i - i0);
}

function quantileSorted(values, p, valueof = _number_js__WEBPACK_IMPORTED_MODULE_5__["default"]) {
  if (!(n = values.length) || isNaN(p = +p)) return;
  if (p <= 0 || n < 2) return +valueof(values[0], 0, values);
  if (p >= 1) return +valueof(values[n - 1], n - 1, values);
  var n,
      i = (n - 1) * p,
      i0 = Math.floor(i),
      value0 = +valueof(values[i0], i0, values),
      value1 = +valueof(values[i0 + 1], i0 + 1, values);
  return value0 + (value1 - value0) * (i - i0);
}

function quantileIndex(values, p, valueof = _number_js__WEBPACK_IMPORTED_MODULE_5__["default"]) {
  if (isNaN(p = +p)) return;
  numbers = Float64Array.from(values, (_, i) => Object(_number_js__WEBPACK_IMPORTED_MODULE_5__["default"])(valueof(values[i], i, values)));
  if (p <= 0) return Object(_minIndex_js__WEBPACK_IMPORTED_MODULE_3__["default"])(numbers);
  if (p >= 1) return Object(_maxIndex_js__WEBPACK_IMPORTED_MODULE_1__["default"])(numbers);
  var numbers,
      index = Uint32Array.from(values, (_, i) => i),
      j = numbers.length - 1,
      i = Math.floor(j * p);
  Object(_quickselect_js__WEBPACK_IMPORTED_MODULE_4__["default"])(index, i, 0, j, (i, j) => Object(_sort_js__WEBPACK_IMPORTED_MODULE_6__["ascendingDefined"])(numbers[i], numbers[j]));
  i = Object(_greatest_js__WEBPACK_IMPORTED_MODULE_7__["default"])(index.subarray(0, i + 1), (i) => numbers[i]);
  return i >= 0 ? i : -1;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/quickselect.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/quickselect.js ***!
  \******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return quickselect; });
/* harmony import */ var _sort_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./sort.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/sort.js");


// Based on https://github.com/mourner/quickselect
// ISC license, Copyright 2018 Vladimir Agafonkin.
function quickselect(array, k, left = 0, right = Infinity, compare) {
  k = Math.floor(k);
  left = Math.floor(Math.max(0, left));
  right = Math.floor(Math.min(array.length - 1, right));

  if (!(left <= k && k <= right)) return array;

  compare = compare === undefined ? _sort_js__WEBPACK_IMPORTED_MODULE_0__["ascendingDefined"] : Object(_sort_js__WEBPACK_IMPORTED_MODULE_0__["compareDefined"])(compare);

  while (right > left) {
    if (right - left > 600) {
      const n = right - left + 1;
      const m = k - left + 1;
      const z = Math.log(n);
      const s = 0.5 * Math.exp(2 * z / 3);
      const sd = 0.5 * Math.sqrt(z * s * (n - s) / n) * (m - n / 2 < 0 ? -1 : 1);
      const newLeft = Math.max(left, Math.floor(k - m * s / n + sd));
      const newRight = Math.min(right, Math.floor(k + (n - m) * s / n + sd));
      quickselect(array, k, newLeft, newRight, compare);
    }

    const t = array[k];
    let i = left;
    let j = right;

    swap(array, left, k);
    if (compare(array[right], t) > 0) swap(array, left, right);

    while (i < j) {
      swap(array, i, j), ++i, --j;
      while (compare(array[i], t) < 0) ++i;
      while (compare(array[j], t) > 0) --j;
    }

    if (compare(array[left], t) === 0) swap(array, left, j);
    else ++j, swap(array, j, right);

    if (j <= k) left = j + 1;
    if (k <= j) right = j - 1;
  }

  return array;
}

function swap(array, i, j) {
  const t = array[i];
  array[i] = array[j];
  array[j] = t;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/range.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/range.js ***!
  \************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return range; });
function range(start, stop, step) {
  start = +start, stop = +stop, step = (n = arguments.length) < 2 ? (stop = start, start = 0, 1) : n < 3 ? 1 : +step;

  var i = -1,
      n = Math.max(0, Math.ceil((stop - start) / step)) | 0,
      range = new Array(n);

  while (++i < n) {
    range[i] = start + i * step;
  }

  return range;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/rank.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/rank.js ***!
  \***********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return rank; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");
/* harmony import */ var _sort_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./sort.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/sort.js");



function rank(values, valueof = _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"]) {
  if (typeof values[Symbol.iterator] !== "function") throw new TypeError("values is not iterable");
  let V = Array.from(values);
  const R = new Float64Array(V.length);
  if (valueof.length !== 2) V = V.map(valueof), valueof = _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"];
  const compareIndex = (i, j) => valueof(V[i], V[j]);
  let k, r;
  values = Uint32Array.from(V, (_, i) => i);
  // Risky chaining due to Safari 14 https://github.com/d3/d3-array/issues/123
  values.sort(valueof === _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"] ? (i, j) => Object(_sort_js__WEBPACK_IMPORTED_MODULE_1__["ascendingDefined"])(V[i], V[j]) : Object(_sort_js__WEBPACK_IMPORTED_MODULE_1__["compareDefined"])(compareIndex));
  values.forEach((j, i) => {
      const c = compareIndex(j, k === undefined ? j : k);
      if (c >= 0) {
        if (k === undefined || c > 0) k = j, r = i;
        R[j] = r;
      } else {
        R[j] = NaN;
      }
    });
  return R;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/reduce.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/reduce.js ***!
  \*************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return reduce; });
function reduce(values, reducer, value) {
  if (typeof reducer !== "function") throw new TypeError("reducer is not a function");
  const iterator = values[Symbol.iterator]();
  let done, next, index = -1;
  if (arguments.length < 3) {
    ({done, value} = iterator.next());
    if (done) return;
    ++index;
  }
  while (({done, value: next} = iterator.next()), !done) {
    value = reducer(value, next, ++index, values);
  }
  return value;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/reverse.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/reverse.js ***!
  \**************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return reverse; });
function reverse(values) {
  if (typeof values[Symbol.iterator] !== "function") throw new TypeError("values is not iterable");
  return Array.from(values).reverse();
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/scan.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/scan.js ***!
  \***********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return scan; });
/* harmony import */ var _leastIndex_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./leastIndex.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/leastIndex.js");


function scan(values, compare) {
  const index = Object(_leastIndex_js__WEBPACK_IMPORTED_MODULE_0__["default"])(values, compare);
  return index < 0 ? undefined : index;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/shuffle.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/shuffle.js ***!
  \**************************************************************************/
/*! exports provided: default, shuffler */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "shuffler", function() { return shuffler; });
/* harmony default export */ __webpack_exports__["default"] = (shuffler(Math.random));

function shuffler(random) {
  return function shuffle(array, i0 = 0, i1 = array.length) {
    let m = i1 - (i0 = +i0);
    while (m) {
      const i = random() * m-- | 0, t = array[m + i0];
      array[m + i0] = array[i + i0];
      array[i + i0] = t;
    }
    return array;
  };
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/some.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/some.js ***!
  \***********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return some; });
function some(values, test) {
  if (typeof test !== "function") throw new TypeError("test is not a function");
  let index = -1;
  for (const value of values) {
    if (test(value, ++index, values)) {
      return true;
    }
  }
  return false;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/sort.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/sort.js ***!
  \***********************************************************************/
/*! exports provided: default, compareDefined, ascendingDefined */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return sort; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compareDefined", function() { return compareDefined; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ascendingDefined", function() { return ascendingDefined; });
/* harmony import */ var _ascending_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ascending.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ascending.js");
/* harmony import */ var _permute_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./permute.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/permute.js");



function sort(values, ...F) {
  if (typeof values[Symbol.iterator] !== "function") throw new TypeError("values is not iterable");
  values = Array.from(values);
  let [f] = F;
  if ((f && f.length !== 2) || F.length > 1) {
    const index = Uint32Array.from(values, (d, i) => i);
    if (F.length > 1) {
      F = F.map(f => values.map(f));
      index.sort((i, j) => {
        for (const f of F) {
          const c = ascendingDefined(f[i], f[j]);
          if (c) return c;
        }
      });
    } else {
      f = values.map(f);
      index.sort((i, j) => ascendingDefined(f[i], f[j]));
    }
    return Object(_permute_js__WEBPACK_IMPORTED_MODULE_1__["default"])(values, index);
  }
  return values.sort(compareDefined(f));
}

function compareDefined(compare = _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"]) {
  if (compare === _ascending_js__WEBPACK_IMPORTED_MODULE_0__["default"]) return ascendingDefined;
  if (typeof compare !== "function") throw new TypeError("compare is not a function");
  return (a, b) => {
    const x = compare(a, b);
    if (x || x === 0) return x;
    return (compare(b, b) === 0) - (compare(a, a) === 0);
  };
}

function ascendingDefined(a, b) {
  return (a == null || !(a >= a)) - (b == null || !(b >= b)) || (a < b ? -1 : a > b ? 1 : 0);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/subset.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/subset.js ***!
  \*************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return subset; });
/* harmony import */ var _superset_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./superset.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/superset.js");


function subset(values, other) {
  return Object(_superset_js__WEBPACK_IMPORTED_MODULE_0__["default"])(other, values);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/sum.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/sum.js ***!
  \**********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return sum; });
function sum(values, valueof) {
  let sum = 0;
  if (valueof === undefined) {
    for (let value of values) {
      if (value = +value) {
        sum += value;
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if (value = +valueof(value, ++index, values)) {
        sum += value;
      }
    }
  }
  return sum;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/superset.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/superset.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return superset; });
function superset(values, other) {
  const iterator = values[Symbol.iterator](), set = new Set();
  for (const o of other) {
    const io = intern(o);
    if (set.has(io)) continue;
    let value, done;
    while (({value, done} = iterator.next())) {
      if (done) return false;
      const ivalue = intern(value);
      set.add(ivalue);
      if (Object.is(io, ivalue)) break;
    }
  }
  return true;
}

function intern(value) {
  return value !== null && typeof value === "object" ? value.valueOf() : value;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/freedmanDiaconis.js":
/*!*********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/freedmanDiaconis.js ***!
  \*********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return thresholdFreedmanDiaconis; });
/* harmony import */ var _count_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../count.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/count.js");
/* harmony import */ var _quantile_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../quantile.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/quantile.js");



function thresholdFreedmanDiaconis(values, min, max) {
  const c = Object(_count_js__WEBPACK_IMPORTED_MODULE_0__["default"])(values), d = Object(_quantile_js__WEBPACK_IMPORTED_MODULE_1__["default"])(values, 0.75) - Object(_quantile_js__WEBPACK_IMPORTED_MODULE_1__["default"])(values, 0.25);
  return c && d ? Math.ceil((max - min) / (2 * d * Math.pow(c, -1 / 3))) : 1;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/scott.js":
/*!**********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/scott.js ***!
  \**********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return thresholdScott; });
/* harmony import */ var _count_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../count.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/count.js");
/* harmony import */ var _deviation_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../deviation.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/deviation.js");



function thresholdScott(values, min, max) {
  const c = Object(_count_js__WEBPACK_IMPORTED_MODULE_0__["default"])(values), d = Object(_deviation_js__WEBPACK_IMPORTED_MODULE_1__["default"])(values);
  return c && d ? Math.ceil((max - min) * Math.cbrt(c) / (3.49 * d)) : 1;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/sturges.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/threshold/sturges.js ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return thresholdSturges; });
/* harmony import */ var _count_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../count.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/count.js");


function thresholdSturges(values) {
  return Math.max(1, Math.ceil(Math.log(Object(_count_js__WEBPACK_IMPORTED_MODULE_0__["default"])(values)) / Math.LN2) + 1);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/ticks.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/ticks.js ***!
  \************************************************************************/
/*! exports provided: default, tickIncrement, tickStep */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return ticks; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "tickIncrement", function() { return tickIncrement; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "tickStep", function() { return tickStep; });
const e10 = Math.sqrt(50),
    e5 = Math.sqrt(10),
    e2 = Math.sqrt(2);

function tickSpec(start, stop, count) {
  const step = (stop - start) / Math.max(0, count),
      power = Math.floor(Math.log10(step)),
      error = step / Math.pow(10, power),
      factor = error >= e10 ? 10 : error >= e5 ? 5 : error >= e2 ? 2 : 1;
  let i1, i2, inc;
  if (power < 0) {
    inc = Math.pow(10, -power) / factor;
    i1 = Math.round(start * inc);
    i2 = Math.round(stop * inc);
    if (i1 / inc < start) ++i1;
    if (i2 / inc > stop) --i2;
    inc = -inc;
  } else {
    inc = Math.pow(10, power) * factor;
    i1 = Math.round(start / inc);
    i2 = Math.round(stop / inc);
    if (i1 * inc < start) ++i1;
    if (i2 * inc > stop) --i2;
  }
  if (i2 < i1 && 0.5 <= count && count < 2) return tickSpec(start, stop, count * 2);
  return [i1, i2, inc];
}

function ticks(start, stop, count) {
  stop = +stop, start = +start, count = +count;
  if (!(count > 0)) return [];
  if (start === stop) return [start];
  const reverse = stop < start, [i1, i2, inc] = reverse ? tickSpec(stop, start, count) : tickSpec(start, stop, count);
  if (!(i2 >= i1)) return [];
  const n = i2 - i1 + 1, ticks = new Array(n);
  if (reverse) {
    if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) / -inc;
    else for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) * inc;
  } else {
    if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) / -inc;
    else for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) * inc;
  }
  return ticks;
}

function tickIncrement(start, stop, count) {
  stop = +stop, start = +start, count = +count;
  return tickSpec(start, stop, count)[2];
}

function tickStep(start, stop, count) {
  stop = +stop, start = +start, count = +count;
  const reverse = stop < start, inc = reverse ? tickIncrement(stop, start, count) : tickIncrement(start, stop, count);
  return (reverse ? -1 : 1) * (inc < 0 ? 1 / -inc : inc);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/transpose.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/transpose.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return transpose; });
/* harmony import */ var _min_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./min.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/min.js");


function transpose(matrix) {
  if (!(n = matrix.length)) return [];
  for (var i = -1, m = Object(_min_js__WEBPACK_IMPORTED_MODULE_0__["default"])(matrix, length), transpose = new Array(m); ++i < m;) {
    for (var j = -1, n, row = transpose[i] = new Array(n); ++j < n;) {
      row[j] = matrix[j][i];
    }
  }
  return transpose;
}

function length(d) {
  return d.length;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/union.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/union.js ***!
  \************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return union; });
/* harmony import */ var internmap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! internmap */ "./node_modules/internmap/src/index.js");


function union(...others) {
  const set = new internmap__WEBPACK_IMPORTED_MODULE_0__["InternSet"]();
  for (const other of others) {
    for (const o of other) {
      set.add(o);
    }
  }
  return set;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/variance.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/variance.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return variance; });
function variance(values, valueof) {
  let count = 0;
  let delta;
  let mean = 0;
  let sum = 0;
  if (valueof === undefined) {
    for (let value of values) {
      if (value != null && (value = +value) >= value) {
        delta = value - mean;
        mean += delta / ++count;
        sum += delta * (value - mean);
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null && (value = +value) >= value) {
        delta = value - mean;
        mean += delta / ++count;
        sum += delta * (value - mean);
      }
    }
  }
  if (count > 1) return sum / (count - 1);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-array/src/zip.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-array/src/zip.js ***!
  \**********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return zip; });
/* harmony import */ var _transpose_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./transpose.js */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/transpose.js");


function zip() {
  return Object(_transpose_js__WEBPACK_IMPORTED_MODULE_0__["default"])(arguments);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-dispatch/src/dispatch.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-dispatch/src/dispatch.js ***!
  \******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
var noop = {value: () => {}};

function dispatch() {
  for (var i = 0, n = arguments.length, _ = {}, t; i < n; ++i) {
    if (!(t = arguments[i] + "") || (t in _) || /[\s.]/.test(t)) throw new Error("illegal type: " + t);
    _[t] = [];
  }
  return new Dispatch(_);
}

function Dispatch(_) {
  this._ = _;
}

function parseTypenames(typenames, types) {
  return typenames.trim().split(/^|\s+/).map(function(t) {
    var name = "", i = t.indexOf(".");
    if (i >= 0) name = t.slice(i + 1), t = t.slice(0, i);
    if (t && !types.hasOwnProperty(t)) throw new Error("unknown type: " + t);
    return {type: t, name: name};
  });
}

Dispatch.prototype = dispatch.prototype = {
  constructor: Dispatch,
  on: function(typename, callback) {
    var _ = this._,
        T = parseTypenames(typename + "", _),
        t,
        i = -1,
        n = T.length;

    // If no callback was specified, return the callback of the given type and name.
    if (arguments.length < 2) {
      while (++i < n) if ((t = (typename = T[i]).type) && (t = get(_[t], typename.name))) return t;
      return;
    }

    // If a type was specified, set the callback for the given type and name.
    // Otherwise, if a null callback was specified, remove callbacks of the given name.
    if (callback != null && typeof callback !== "function") throw new Error("invalid callback: " + callback);
    while (++i < n) {
      if (t = (typename = T[i]).type) _[t] = set(_[t], typename.name, callback);
      else if (callback == null) for (t in _) _[t] = set(_[t], typename.name, null);
    }

    return this;
  },
  copy: function() {
    var copy = {}, _ = this._;
    for (var t in _) copy[t] = _[t].slice();
    return new Dispatch(copy);
  },
  call: function(type, that) {
    if ((n = arguments.length - 2) > 0) for (var args = new Array(n), i = 0, n, t; i < n; ++i) args[i] = arguments[i + 2];
    if (!this._.hasOwnProperty(type)) throw new Error("unknown type: " + type);
    for (t = this._[type], i = 0, n = t.length; i < n; ++i) t[i].value.apply(that, args);
  },
  apply: function(type, that, args) {
    if (!this._.hasOwnProperty(type)) throw new Error("unknown type: " + type);
    for (var t = this._[type], i = 0, n = t.length; i < n; ++i) t[i].value.apply(that, args);
  }
};

function get(type, name) {
  for (var i = 0, n = type.length, c; i < n; ++i) {
    if ((c = type[i]).name === name) {
      return c.value;
    }
  }
}

function set(type, name, callback) {
  for (var i = 0, n = type.length; i < n; ++i) {
    if (type[i].name === name) {
      type[i] = noop, type = type.slice(0, i).concat(type.slice(i + 1));
      break;
    }
  }
  if (callback != null) type.push({name: name, value: callback});
  return type;
}

/* harmony default export */ __webpack_exports__["default"] = (dispatch);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-dispatch/src/index.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-dispatch/src/index.js ***!
  \***************************************************************************/
/*! exports provided: dispatch */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _dispatch_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dispatch.js */ "./node_modules/d3-flame-graph/node_modules/d3-dispatch/src/dispatch.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "dispatch", function() { return _dispatch_js__WEBPACK_IMPORTED_MODULE_0__["default"]; });




/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/back.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/back.js ***!
  \**********************************************************************/
/*! exports provided: backIn, backOut, backInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "backIn", function() { return backIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "backOut", function() { return backOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "backInOut", function() { return backInOut; });
var overshoot = 1.70158;

var backIn = (function custom(s) {
  s = +s;

  function backIn(t) {
    return (t = +t) * t * (s * (t - 1) + t);
  }

  backIn.overshoot = custom;

  return backIn;
})(overshoot);

var backOut = (function custom(s) {
  s = +s;

  function backOut(t) {
    return --t * t * ((t + 1) * s + t) + 1;
  }

  backOut.overshoot = custom;

  return backOut;
})(overshoot);

var backInOut = (function custom(s) {
  s = +s;

  function backInOut(t) {
    return ((t *= 2) < 1 ? t * t * ((s + 1) * t - s) : (t -= 2) * t * ((s + 1) * t + s) + 2) / 2;
  }

  backInOut.overshoot = custom;

  return backInOut;
})(overshoot);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/bounce.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/bounce.js ***!
  \************************************************************************/
/*! exports provided: bounceIn, bounceOut, bounceInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "bounceIn", function() { return bounceIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "bounceOut", function() { return bounceOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "bounceInOut", function() { return bounceInOut; });
var b1 = 4 / 11,
    b2 = 6 / 11,
    b3 = 8 / 11,
    b4 = 3 / 4,
    b5 = 9 / 11,
    b6 = 10 / 11,
    b7 = 15 / 16,
    b8 = 21 / 22,
    b9 = 63 / 64,
    b0 = 1 / b1 / b1;

function bounceIn(t) {
  return 1 - bounceOut(1 - t);
}

function bounceOut(t) {
  return (t = +t) < b1 ? b0 * t * t : t < b3 ? b0 * (t -= b2) * t + b4 : t < b6 ? b0 * (t -= b5) * t + b7 : b0 * (t -= b8) * t + b9;
}

function bounceInOut(t) {
  return ((t *= 2) <= 1 ? 1 - bounceOut(1 - t) : bounceOut(t - 1) + 1) / 2;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/circle.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/circle.js ***!
  \************************************************************************/
/*! exports provided: circleIn, circleOut, circleInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "circleIn", function() { return circleIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "circleOut", function() { return circleOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "circleInOut", function() { return circleInOut; });
function circleIn(t) {
  return 1 - Math.sqrt(1 - t * t);
}

function circleOut(t) {
  return Math.sqrt(1 - --t * t);
}

function circleInOut(t) {
  return ((t *= 2) <= 1 ? 1 - Math.sqrt(1 - t * t) : Math.sqrt(1 - (t -= 2) * t) + 1) / 2;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/cubic.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/cubic.js ***!
  \***********************************************************************/
/*! exports provided: cubicIn, cubicOut, cubicInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cubicIn", function() { return cubicIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cubicOut", function() { return cubicOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cubicInOut", function() { return cubicInOut; });
function cubicIn(t) {
  return t * t * t;
}

function cubicOut(t) {
  return --t * t * t + 1;
}

function cubicInOut(t) {
  return ((t *= 2) <= 1 ? t * t * t : (t -= 2) * t * t + 2) / 2;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/elastic.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/elastic.js ***!
  \*************************************************************************/
/*! exports provided: elasticIn, elasticOut, elasticInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "elasticIn", function() { return elasticIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "elasticOut", function() { return elasticOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "elasticInOut", function() { return elasticInOut; });
/* harmony import */ var _math_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./math.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/math.js");


var tau = 2 * Math.PI,
    amplitude = 1,
    period = 0.3;

var elasticIn = (function custom(a, p) {
  var s = Math.asin(1 / (a = Math.max(1, a))) * (p /= tau);

  function elasticIn(t) {
    return a * Object(_math_js__WEBPACK_IMPORTED_MODULE_0__["tpmt"])(-(--t)) * Math.sin((s - t) / p);
  }

  elasticIn.amplitude = function(a) { return custom(a, p * tau); };
  elasticIn.period = function(p) { return custom(a, p); };

  return elasticIn;
})(amplitude, period);

var elasticOut = (function custom(a, p) {
  var s = Math.asin(1 / (a = Math.max(1, a))) * (p /= tau);

  function elasticOut(t) {
    return 1 - a * Object(_math_js__WEBPACK_IMPORTED_MODULE_0__["tpmt"])(t = +t) * Math.sin((t + s) / p);
  }

  elasticOut.amplitude = function(a) { return custom(a, p * tau); };
  elasticOut.period = function(p) { return custom(a, p); };

  return elasticOut;
})(amplitude, period);

var elasticInOut = (function custom(a, p) {
  var s = Math.asin(1 / (a = Math.max(1, a))) * (p /= tau);

  function elasticInOut(t) {
    return ((t = t * 2 - 1) < 0
        ? a * Object(_math_js__WEBPACK_IMPORTED_MODULE_0__["tpmt"])(-t) * Math.sin((s - t) / p)
        : 2 - a * Object(_math_js__WEBPACK_IMPORTED_MODULE_0__["tpmt"])(t) * Math.sin((s + t) / p)) / 2;
  }

  elasticInOut.amplitude = function(a) { return custom(a, p * tau); };
  elasticInOut.period = function(p) { return custom(a, p); };

  return elasticInOut;
})(amplitude, period);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/exp.js":
/*!*********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/exp.js ***!
  \*********************************************************************/
/*! exports provided: expIn, expOut, expInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "expIn", function() { return expIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "expOut", function() { return expOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "expInOut", function() { return expInOut; });
/* harmony import */ var _math_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./math.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/math.js");


function expIn(t) {
  return Object(_math_js__WEBPACK_IMPORTED_MODULE_0__["tpmt"])(1 - +t);
}

function expOut(t) {
  return 1 - Object(_math_js__WEBPACK_IMPORTED_MODULE_0__["tpmt"])(t);
}

function expInOut(t) {
  return ((t *= 2) <= 1 ? Object(_math_js__WEBPACK_IMPORTED_MODULE_0__["tpmt"])(1 - t) : 2 - Object(_math_js__WEBPACK_IMPORTED_MODULE_0__["tpmt"])(t - 1)) / 2;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/index.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/index.js ***!
  \***********************************************************************/
/*! exports provided: easeLinear, easeQuad, easeQuadIn, easeQuadOut, easeQuadInOut, easeCubic, easeCubicIn, easeCubicOut, easeCubicInOut, easePoly, easePolyIn, easePolyOut, easePolyInOut, easeSin, easeSinIn, easeSinOut, easeSinInOut, easeExp, easeExpIn, easeExpOut, easeExpInOut, easeCircle, easeCircleIn, easeCircleOut, easeCircleInOut, easeBounce, easeBounceIn, easeBounceOut, easeBounceInOut, easeBack, easeBackIn, easeBackOut, easeBackInOut, easeElastic, easeElasticIn, easeElasticOut, easeElasticInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/linear.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeLinear", function() { return _linear_js__WEBPACK_IMPORTED_MODULE_0__["linear"]; });

/* harmony import */ var _quad_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./quad.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/quad.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeQuad", function() { return _quad_js__WEBPACK_IMPORTED_MODULE_1__["quadInOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeQuadIn", function() { return _quad_js__WEBPACK_IMPORTED_MODULE_1__["quadIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeQuadOut", function() { return _quad_js__WEBPACK_IMPORTED_MODULE_1__["quadOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeQuadInOut", function() { return _quad_js__WEBPACK_IMPORTED_MODULE_1__["quadInOut"]; });

/* harmony import */ var _cubic_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./cubic.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/cubic.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeCubic", function() { return _cubic_js__WEBPACK_IMPORTED_MODULE_2__["cubicInOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeCubicIn", function() { return _cubic_js__WEBPACK_IMPORTED_MODULE_2__["cubicIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeCubicOut", function() { return _cubic_js__WEBPACK_IMPORTED_MODULE_2__["cubicOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeCubicInOut", function() { return _cubic_js__WEBPACK_IMPORTED_MODULE_2__["cubicInOut"]; });

/* harmony import */ var _poly_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./poly.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/poly.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easePoly", function() { return _poly_js__WEBPACK_IMPORTED_MODULE_3__["polyInOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easePolyIn", function() { return _poly_js__WEBPACK_IMPORTED_MODULE_3__["polyIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easePolyOut", function() { return _poly_js__WEBPACK_IMPORTED_MODULE_3__["polyOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easePolyInOut", function() { return _poly_js__WEBPACK_IMPORTED_MODULE_3__["polyInOut"]; });

/* harmony import */ var _sin_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./sin.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/sin.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeSin", function() { return _sin_js__WEBPACK_IMPORTED_MODULE_4__["sinInOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeSinIn", function() { return _sin_js__WEBPACK_IMPORTED_MODULE_4__["sinIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeSinOut", function() { return _sin_js__WEBPACK_IMPORTED_MODULE_4__["sinOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeSinInOut", function() { return _sin_js__WEBPACK_IMPORTED_MODULE_4__["sinInOut"]; });

/* harmony import */ var _exp_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./exp.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/exp.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeExp", function() { return _exp_js__WEBPACK_IMPORTED_MODULE_5__["expInOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeExpIn", function() { return _exp_js__WEBPACK_IMPORTED_MODULE_5__["expIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeExpOut", function() { return _exp_js__WEBPACK_IMPORTED_MODULE_5__["expOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeExpInOut", function() { return _exp_js__WEBPACK_IMPORTED_MODULE_5__["expInOut"]; });

/* harmony import */ var _circle_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./circle.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/circle.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeCircle", function() { return _circle_js__WEBPACK_IMPORTED_MODULE_6__["circleInOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeCircleIn", function() { return _circle_js__WEBPACK_IMPORTED_MODULE_6__["circleIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeCircleOut", function() { return _circle_js__WEBPACK_IMPORTED_MODULE_6__["circleOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeCircleInOut", function() { return _circle_js__WEBPACK_IMPORTED_MODULE_6__["circleInOut"]; });

/* harmony import */ var _bounce_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./bounce.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/bounce.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeBounce", function() { return _bounce_js__WEBPACK_IMPORTED_MODULE_7__["bounceOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeBounceIn", function() { return _bounce_js__WEBPACK_IMPORTED_MODULE_7__["bounceIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeBounceOut", function() { return _bounce_js__WEBPACK_IMPORTED_MODULE_7__["bounceOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeBounceInOut", function() { return _bounce_js__WEBPACK_IMPORTED_MODULE_7__["bounceInOut"]; });

/* harmony import */ var _back_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./back.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/back.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeBack", function() { return _back_js__WEBPACK_IMPORTED_MODULE_8__["backInOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeBackIn", function() { return _back_js__WEBPACK_IMPORTED_MODULE_8__["backIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeBackOut", function() { return _back_js__WEBPACK_IMPORTED_MODULE_8__["backOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeBackInOut", function() { return _back_js__WEBPACK_IMPORTED_MODULE_8__["backInOut"]; });

/* harmony import */ var _elastic_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./elastic.js */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/elastic.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeElastic", function() { return _elastic_js__WEBPACK_IMPORTED_MODULE_9__["elasticOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeElasticIn", function() { return _elastic_js__WEBPACK_IMPORTED_MODULE_9__["elasticIn"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeElasticOut", function() { return _elastic_js__WEBPACK_IMPORTED_MODULE_9__["elasticOut"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "easeElasticInOut", function() { return _elastic_js__WEBPACK_IMPORTED_MODULE_9__["elasticInOut"]; });






















/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/linear.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/linear.js ***!
  \************************************************************************/
/*! exports provided: linear */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "linear", function() { return linear; });
const linear = t => +t;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/math.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/math.js ***!
  \**********************************************************************/
/*! exports provided: tpmt */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "tpmt", function() { return tpmt; });
// tpmt is two power minus ten times t scaled to [0,1]
function tpmt(x) {
  return (Math.pow(2, -10 * x) - 0.0009765625) * 1.0009775171065494;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/poly.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/poly.js ***!
  \**********************************************************************/
/*! exports provided: polyIn, polyOut, polyInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "polyIn", function() { return polyIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "polyOut", function() { return polyOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "polyInOut", function() { return polyInOut; });
var exponent = 3;

var polyIn = (function custom(e) {
  e = +e;

  function polyIn(t) {
    return Math.pow(t, e);
  }

  polyIn.exponent = custom;

  return polyIn;
})(exponent);

var polyOut = (function custom(e) {
  e = +e;

  function polyOut(t) {
    return 1 - Math.pow(1 - t, e);
  }

  polyOut.exponent = custom;

  return polyOut;
})(exponent);

var polyInOut = (function custom(e) {
  e = +e;

  function polyInOut(t) {
    return ((t *= 2) <= 1 ? Math.pow(t, e) : 2 - Math.pow(2 - t, e)) / 2;
  }

  polyInOut.exponent = custom;

  return polyInOut;
})(exponent);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/quad.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/quad.js ***!
  \**********************************************************************/
/*! exports provided: quadIn, quadOut, quadInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "quadIn", function() { return quadIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "quadOut", function() { return quadOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "quadInOut", function() { return quadInOut; });
function quadIn(t) {
  return t * t;
}

function quadOut(t) {
  return t * (2 - t);
}

function quadInOut(t) {
  return ((t *= 2) <= 1 ? t * t : --t * (2 - t) + 1) / 2;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/sin.js":
/*!*********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-ease/src/sin.js ***!
  \*********************************************************************/
/*! exports provided: sinIn, sinOut, sinInOut */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sinIn", function() { return sinIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sinOut", function() { return sinOut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sinInOut", function() { return sinInOut; });
var pi = Math.PI,
    halfPi = pi / 2;

function sinIn(t) {
  return (+t === 1) ? 1 : 1 - Math.cos(t * halfPi);
}

function sinOut(t) {
  return Math.sin(t * halfPi);
}

function sinInOut(t) {
  return (1 - Math.cos(pi * t)) / 2;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/defaultLocale.js":
/*!*********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/defaultLocale.js ***!
  \*********************************************************************************/
/*! exports provided: format, formatPrefix, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "format", function() { return format; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatPrefix", function() { return formatPrefix; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return defaultLocale; });
/* harmony import */ var _locale_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./locale.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/locale.js");


var locale;
var format;
var formatPrefix;

defaultLocale({
  thousands: ",",
  grouping: [3],
  currency: ["$", ""]
});

function defaultLocale(definition) {
  locale = Object(_locale_js__WEBPACK_IMPORTED_MODULE_0__["default"])(definition);
  format = locale.format;
  formatPrefix = locale.formatPrefix;
  return locale;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/exponent.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/exponent.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./formatDecimal.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatDecimal.js");


/* harmony default export */ __webpack_exports__["default"] = (function(x) {
  return x = Object(_formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__["formatDecimalParts"])(Math.abs(x)), x ? x[1] : NaN;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatDecimal.js":
/*!*********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/formatDecimal.js ***!
  \*********************************************************************************/
/*! exports provided: default, formatDecimalParts */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatDecimalParts", function() { return formatDecimalParts; });
/* harmony default export */ __webpack_exports__["default"] = (function(x) {
  return Math.abs(x = Math.round(x)) >= 1e21
      ? x.toLocaleString("en").replace(/,/g, "")
      : x.toString(10);
});

// Computes the decimal coefficient and exponent of the specified number x with
// significant digits p, where x is positive and p is in [1, 21] or undefined.
// For example, formatDecimalParts(1.23) returns ["123", 0].
function formatDecimalParts(x, p) {
  if (!isFinite(x) || x === 0) return null; // NaN, ±Infinity, ±0
  var i = (x = p ? x.toExponential(p - 1) : x.toExponential()).indexOf("e"), coefficient = x.slice(0, i);

  // The string returned by toExponential either has the form \d\.\d+e[-+]\d+
  // (e.g., 1.2e+3) or the form \de[-+]\d+ (e.g., 1e+3).
  return [
    coefficient.length > 1 ? coefficient[0] + coefficient.slice(2) : coefficient,
    +x.slice(i + 1)
  ];
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatGroup.js":
/*!*******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/formatGroup.js ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(grouping, thousands) {
  return function(value, width) {
    var i = value.length,
        t = [],
        j = 0,
        g = grouping[0],
        length = 0;

    while (i > 0 && g > 0) {
      if (length + g + 1 > width) g = Math.max(1, width - length);
      t.push(value.substring(i -= g, i + g));
      if ((length += g + 1) > width) break;
      g = grouping[j = (j + 1) % grouping.length];
    }

    return t.reverse().join(thousands);
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatNumerals.js":
/*!**********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/formatNumerals.js ***!
  \**********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(numerals) {
  return function(value) {
    return value.replace(/[0-9]/g, function(i) {
      return numerals[+i];
    });
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatPrefixAuto.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/formatPrefixAuto.js ***!
  \************************************************************************************/
/*! exports provided: prefixExponent, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "prefixExponent", function() { return prefixExponent; });
/* harmony import */ var _formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./formatDecimal.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatDecimal.js");


var prefixExponent;

/* harmony default export */ __webpack_exports__["default"] = (function(x, p) {
  var d = Object(_formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__["formatDecimalParts"])(x, p);
  if (!d) return prefixExponent = undefined, x.toPrecision(p);
  var coefficient = d[0],
      exponent = d[1],
      i = exponent - (prefixExponent = Math.max(-8, Math.min(8, Math.floor(exponent / 3))) * 3) + 1,
      n = coefficient.length;
  return i === n ? coefficient
      : i > n ? coefficient + new Array(i - n + 1).join("0")
      : i > 0 ? coefficient.slice(0, i) + "." + coefficient.slice(i)
      : "0." + new Array(1 - i).join("0") + Object(_formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__["formatDecimalParts"])(x, Math.max(0, p + i - 1))[0]; // less than 1y!
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatRounded.js":
/*!*********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/formatRounded.js ***!
  \*********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./formatDecimal.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatDecimal.js");


/* harmony default export */ __webpack_exports__["default"] = (function(x, p) {
  var d = Object(_formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__["formatDecimalParts"])(x, p);
  if (!d) return x + "";
  var coefficient = d[0],
      exponent = d[1];
  return exponent < 0 ? "0." + new Array(-exponent).join("0") + coefficient
      : coefficient.length > exponent + 1 ? coefficient.slice(0, exponent + 1) + "." + coefficient.slice(exponent + 1)
      : coefficient + new Array(exponent - coefficient.length + 2).join("0");
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatSpecifier.js":
/*!***********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/formatSpecifier.js ***!
  \***********************************************************************************/
/*! exports provided: default, FormatSpecifier */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return formatSpecifier; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormatSpecifier", function() { return FormatSpecifier; });
// [[fill]align][sign][symbol][0][width][,][.precision][~][type]
var re = /^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;

function formatSpecifier(specifier) {
  if (!(match = re.exec(specifier))) throw new Error("invalid format: " + specifier);
  var match;
  return new FormatSpecifier({
    fill: match[1],
    align: match[2],
    sign: match[3],
    symbol: match[4],
    zero: match[5],
    width: match[6],
    comma: match[7],
    precision: match[8] && match[8].slice(1),
    trim: match[9],
    type: match[10]
  });
}

formatSpecifier.prototype = FormatSpecifier.prototype; // instanceof

function FormatSpecifier(specifier) {
  this.fill = specifier.fill === undefined ? " " : specifier.fill + "";
  this.align = specifier.align === undefined ? ">" : specifier.align + "";
  this.sign = specifier.sign === undefined ? "-" : specifier.sign + "";
  this.symbol = specifier.symbol === undefined ? "" : specifier.symbol + "";
  this.zero = !!specifier.zero;
  this.width = specifier.width === undefined ? undefined : +specifier.width;
  this.comma = !!specifier.comma;
  this.precision = specifier.precision === undefined ? undefined : +specifier.precision;
  this.trim = !!specifier.trim;
  this.type = specifier.type === undefined ? "" : specifier.type + "";
}

FormatSpecifier.prototype.toString = function() {
  return this.fill
      + this.align
      + this.sign
      + this.symbol
      + (this.zero ? "0" : "")
      + (this.width === undefined ? "" : Math.max(1, this.width | 0))
      + (this.comma ? "," : "")
      + (this.precision === undefined ? "" : "." + Math.max(0, this.precision | 0))
      + (this.trim ? "~" : "")
      + this.type;
};


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatTrim.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/formatTrim.js ***!
  \******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
// Trims insignificant zeros, e.g., replaces 1.2000k with 1.2k.
/* harmony default export */ __webpack_exports__["default"] = (function(s) {
  out: for (var n = s.length, i = 1, i0 = -1, i1; i < n; ++i) {
    switch (s[i]) {
      case ".": i0 = i1 = i; break;
      case "0": if (i0 === 0) i0 = i; i1 = i; break;
      default: if (!+s[i]) break out; if (i0 > 0) i0 = 0; break;
    }
  }
  return i0 > 0 ? s.slice(0, i0) + s.slice(i1 + 1) : s;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatTypes.js":
/*!*******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/formatTypes.js ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./formatDecimal.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatDecimal.js");
/* harmony import */ var _formatPrefixAuto_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./formatPrefixAuto.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatPrefixAuto.js");
/* harmony import */ var _formatRounded_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./formatRounded.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatRounded.js");




/* harmony default export */ __webpack_exports__["default"] = ({
  "%": (x, p) => (x * 100).toFixed(p),
  "b": (x) => Math.round(x).toString(2),
  "c": (x) => x + "",
  "d": _formatDecimal_js__WEBPACK_IMPORTED_MODULE_0__["default"],
  "e": (x, p) => x.toExponential(p),
  "f": (x, p) => x.toFixed(p),
  "g": (x, p) => x.toPrecision(p),
  "o": (x) => Math.round(x).toString(8),
  "p": (x, p) => Object(_formatRounded_js__WEBPACK_IMPORTED_MODULE_2__["default"])(x * 100, p),
  "r": _formatRounded_js__WEBPACK_IMPORTED_MODULE_2__["default"],
  "s": _formatPrefixAuto_js__WEBPACK_IMPORTED_MODULE_1__["default"],
  "X": (x) => Math.round(x).toString(16).toUpperCase(),
  "x": (x) => Math.round(x).toString(16)
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/identity.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/identity.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(x) {
  return x;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/index.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/index.js ***!
  \*************************************************************************/
/*! exports provided: formatDefaultLocale, format, formatPrefix, formatLocale, formatSpecifier, FormatSpecifier, precisionFixed, precisionPrefix, precisionRound */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _defaultLocale_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./defaultLocale.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/defaultLocale.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "formatDefaultLocale", function() { return _defaultLocale_js__WEBPACK_IMPORTED_MODULE_0__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "format", function() { return _defaultLocale_js__WEBPACK_IMPORTED_MODULE_0__["format"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "formatPrefix", function() { return _defaultLocale_js__WEBPACK_IMPORTED_MODULE_0__["formatPrefix"]; });

/* harmony import */ var _locale_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./locale.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/locale.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "formatLocale", function() { return _locale_js__WEBPACK_IMPORTED_MODULE_1__["default"]; });

/* harmony import */ var _formatSpecifier_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./formatSpecifier.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatSpecifier.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "formatSpecifier", function() { return _formatSpecifier_js__WEBPACK_IMPORTED_MODULE_2__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "FormatSpecifier", function() { return _formatSpecifier_js__WEBPACK_IMPORTED_MODULE_2__["FormatSpecifier"]; });

/* harmony import */ var _precisionFixed_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./precisionFixed.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionFixed.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "precisionFixed", function() { return _precisionFixed_js__WEBPACK_IMPORTED_MODULE_3__["default"]; });

/* harmony import */ var _precisionPrefix_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./precisionPrefix.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionPrefix.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "precisionPrefix", function() { return _precisionPrefix_js__WEBPACK_IMPORTED_MODULE_4__["default"]; });

/* harmony import */ var _precisionRound_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./precisionRound.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionRound.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "precisionRound", function() { return _precisionRound_js__WEBPACK_IMPORTED_MODULE_5__["default"]; });









/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/locale.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/locale.js ***!
  \**************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _exponent_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./exponent.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/exponent.js");
/* harmony import */ var _formatGroup_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./formatGroup.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatGroup.js");
/* harmony import */ var _formatNumerals_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./formatNumerals.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatNumerals.js");
/* harmony import */ var _formatSpecifier_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./formatSpecifier.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatSpecifier.js");
/* harmony import */ var _formatTrim_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./formatTrim.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatTrim.js");
/* harmony import */ var _formatTypes_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./formatTypes.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatTypes.js");
/* harmony import */ var _formatPrefixAuto_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./formatPrefixAuto.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/formatPrefixAuto.js");
/* harmony import */ var _identity_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./identity.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/identity.js");









var map = Array.prototype.map,
    prefixes = ["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];

/* harmony default export */ __webpack_exports__["default"] = (function(locale) {
  var group = locale.grouping === undefined || locale.thousands === undefined ? _identity_js__WEBPACK_IMPORTED_MODULE_7__["default"] : Object(_formatGroup_js__WEBPACK_IMPORTED_MODULE_1__["default"])(map.call(locale.grouping, Number), locale.thousands + ""),
      currencyPrefix = locale.currency === undefined ? "" : locale.currency[0] + "",
      currencySuffix = locale.currency === undefined ? "" : locale.currency[1] + "",
      decimal = locale.decimal === undefined ? "." : locale.decimal + "",
      numerals = locale.numerals === undefined ? _identity_js__WEBPACK_IMPORTED_MODULE_7__["default"] : Object(_formatNumerals_js__WEBPACK_IMPORTED_MODULE_2__["default"])(map.call(locale.numerals, String)),
      percent = locale.percent === undefined ? "%" : locale.percent + "",
      minus = locale.minus === undefined ? "−" : locale.minus + "",
      nan = locale.nan === undefined ? "NaN" : locale.nan + "";

  function newFormat(specifier, options) {
    specifier = Object(_formatSpecifier_js__WEBPACK_IMPORTED_MODULE_3__["default"])(specifier);

    var fill = specifier.fill,
        align = specifier.align,
        sign = specifier.sign,
        symbol = specifier.symbol,
        zero = specifier.zero,
        width = specifier.width,
        comma = specifier.comma,
        precision = specifier.precision,
        trim = specifier.trim,
        type = specifier.type;

    // The "n" type is an alias for ",g".
    if (type === "n") comma = true, type = "g";

    // The "" type, and any invalid type, is an alias for ".12~g".
    else if (!_formatTypes_js__WEBPACK_IMPORTED_MODULE_5__["default"][type]) precision === undefined && (precision = 12), trim = true, type = "g";

    // If zero fill is specified, padding goes after sign and before digits.
    if (zero || (fill === "0" && align === "=")) zero = true, fill = "0", align = "=";

    // Compute the prefix and suffix.
    // For SI-prefix, the suffix is lazily computed.
    var prefix = (options && options.prefix !== undefined ? options.prefix : "") + (symbol === "$" ? currencyPrefix : symbol === "#" && /[boxX]/.test(type) ? "0" + type.toLowerCase() : ""),
        suffix = (symbol === "$" ? currencySuffix : /[%p]/.test(type) ? percent : "") + (options && options.suffix !== undefined ? options.suffix : "");

    // What format function should we use?
    // Is this an integer type?
    // Can this type generate exponential notation?
    var formatType = _formatTypes_js__WEBPACK_IMPORTED_MODULE_5__["default"][type],
        maybeSuffix = /[defgprs%]/.test(type);

    // Set the default precision if not specified,
    // or clamp the specified precision to the supported range.
    // For significant precision, it must be in [1, 21].
    // For fixed precision, it must be in [0, 20].
    precision = precision === undefined ? 6
        : /[gprs]/.test(type) ? Math.max(1, Math.min(21, precision))
        : Math.max(0, Math.min(20, precision));

    function format(value) {
      var valuePrefix = prefix,
          valueSuffix = suffix,
          i, n, c;

      if (type === "c") {
        valueSuffix = formatType(value) + valueSuffix;
        value = "";
      } else {
        value = +value;

        // Determine the sign. -0 is not less than 0, but 1 / -0 is!
        var valueNegative = value < 0 || 1 / value < 0;

        // Perform the initial formatting.
        value = isNaN(value) ? nan : formatType(Math.abs(value), precision);

        // Trim insignificant zeros.
        if (trim) value = Object(_formatTrim_js__WEBPACK_IMPORTED_MODULE_4__["default"])(value);

        // If a negative value rounds to zero after formatting, and no explicit positive sign is requested, hide the sign.
        if (valueNegative && +value === 0 && sign !== "+") valueNegative = false;

        // Compute the prefix and suffix.
        valuePrefix = (valueNegative ? (sign === "(" ? sign : minus) : sign === "-" || sign === "(" ? "" : sign) + valuePrefix;
        valueSuffix = (type === "s" && !isNaN(value) && _formatPrefixAuto_js__WEBPACK_IMPORTED_MODULE_6__["prefixExponent"] !== undefined ? prefixes[8 + _formatPrefixAuto_js__WEBPACK_IMPORTED_MODULE_6__["prefixExponent"] / 3] : "") + valueSuffix + (valueNegative && sign === "(" ? ")" : "");

        // Break the formatted value into the integer “value” part that can be
        // grouped, and fractional or exponential “suffix” part that is not.
        if (maybeSuffix) {
          i = -1, n = value.length;
          while (++i < n) {
            if (c = value.charCodeAt(i), 48 > c || c > 57) {
              valueSuffix = (c === 46 ? decimal + value.slice(i + 1) : value.slice(i)) + valueSuffix;
              value = value.slice(0, i);
              break;
            }
          }
        }
      }

      // If the fill character is not "0", grouping is applied before padding.
      if (comma && !zero) value = group(value, Infinity);

      // Compute the padding.
      var length = valuePrefix.length + value.length + valueSuffix.length,
          padding = length < width ? new Array(width - length + 1).join(fill) : "";

      // If the fill character is "0", grouping is applied after padding.
      if (comma && zero) value = group(padding + value, padding.length ? width - valueSuffix.length : Infinity), padding = "";

      // Reconstruct the final output based on the desired alignment.
      switch (align) {
        case "<": value = valuePrefix + value + valueSuffix + padding; break;
        case "=": value = valuePrefix + padding + value + valueSuffix; break;
        case "^": value = padding.slice(0, length = padding.length >> 1) + valuePrefix + value + valueSuffix + padding.slice(length); break;
        default: value = padding + valuePrefix + value + valueSuffix; break;
      }

      return numerals(value);
    }

    format.toString = function() {
      return specifier + "";
    };

    return format;
  }

  function formatPrefix(specifier, value) {
    var e = Math.max(-8, Math.min(8, Math.floor(Object(_exponent_js__WEBPACK_IMPORTED_MODULE_0__["default"])(value) / 3))) * 3,
        k = Math.pow(10, -e),
        f = newFormat((specifier = Object(_formatSpecifier_js__WEBPACK_IMPORTED_MODULE_3__["default"])(specifier), specifier.type = "f", specifier), {suffix: prefixes[8 + e / 3]});
    return function(value) {
      return f(k * value);
    };
  }

  return {
    format: newFormat,
    formatPrefix: formatPrefix
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionFixed.js":
/*!**********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionFixed.js ***!
  \**********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _exponent_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./exponent.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/exponent.js");


/* harmony default export */ __webpack_exports__["default"] = (function(step) {
  return Math.max(0, -Object(_exponent_js__WEBPACK_IMPORTED_MODULE_0__["default"])(Math.abs(step)));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionPrefix.js":
/*!***********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionPrefix.js ***!
  \***********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _exponent_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./exponent.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/exponent.js");


/* harmony default export */ __webpack_exports__["default"] = (function(step, value) {
  return Math.max(0, Math.max(-8, Math.min(8, Math.floor(Object(_exponent_js__WEBPACK_IMPORTED_MODULE_0__["default"])(value) / 3))) * 3 - Object(_exponent_js__WEBPACK_IMPORTED_MODULE_0__["default"])(Math.abs(step)));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionRound.js":
/*!**********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-format/src/precisionRound.js ***!
  \**********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _exponent_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./exponent.js */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/exponent.js");


/* harmony default export */ __webpack_exports__["default"] = (function(step, max) {
  step = Math.abs(step), max = Math.abs(max) - step;
  return Math.max(0, Object(_exponent_js__WEBPACK_IMPORTED_MODULE_0__["default"])(max) - Object(_exponent_js__WEBPACK_IMPORTED_MODULE_0__["default"])(step)) + 1;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/accessors.js":
/*!********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/accessors.js ***!
  \********************************************************************************/
/*! exports provided: optional, required */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "optional", function() { return optional; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "required", function() { return required; });
function optional(f) {
  return f == null ? null : required(f);
}

function required(f) {
  if (typeof f !== "function") throw new Error;
  return f;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/array.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/array.js ***!
  \****************************************************************************/
/*! exports provided: default, shuffle */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "shuffle", function() { return shuffle; });
/* harmony default export */ __webpack_exports__["default"] = (function(x) {
  return typeof x === "object" && "length" in x
    ? x // Array, TypedArray, NodeList, array-like
    : Array.from(x); // Map, Set, iterable, string, or anything else
});

function shuffle(array, random) {
  let m = array.length,
      t,
      i;

  while (m) {
    i = random() * m-- | 0;
    t = array[m];
    array[m] = array[i];
    array[i] = t;
  }

  return array;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/cluster.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/cluster.js ***!
  \******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function defaultSeparation(a, b) {
  return a.parent === b.parent ? 1 : 2;
}

function meanX(children) {
  return children.reduce(meanXReduce, 0) / children.length;
}

function meanXReduce(x, c) {
  return x + c.x;
}

function maxY(children) {
  return 1 + children.reduce(maxYReduce, 0);
}

function maxYReduce(y, c) {
  return Math.max(y, c.y);
}

function leafLeft(node) {
  var children;
  while (children = node.children) node = children[0];
  return node;
}

function leafRight(node) {
  var children;
  while (children = node.children) node = children[children.length - 1];
  return node;
}

/* harmony default export */ __webpack_exports__["default"] = (function() {
  var separation = defaultSeparation,
      dx = 1,
      dy = 1,
      nodeSize = false;

  function cluster(root) {
    var previousNode,
        x = 0;

    // First walk, computing the initial x & y values.
    root.eachAfter(function(node) {
      var children = node.children;
      if (children) {
        node.x = meanX(children);
        node.y = maxY(children);
      } else {
        node.x = previousNode ? x += separation(node, previousNode) : 0;
        node.y = 0;
        previousNode = node;
      }
    });

    var left = leafLeft(root),
        right = leafRight(root),
        x0 = left.x - separation(left, right) / 2,
        x1 = right.x + separation(right, left) / 2;

    // Second walk, normalizing x & y to the desired size.
    return root.eachAfter(nodeSize ? function(node) {
      node.x = (node.x - root.x) * dx;
      node.y = (root.y - node.y) * dy;
    } : function(node) {
      node.x = (node.x - x0) / (x1 - x0) * dx;
      node.y = (1 - (root.y ? node.y / root.y : 1)) * dy;
    });
  }

  cluster.separation = function(x) {
    return arguments.length ? (separation = x, cluster) : separation;
  };

  cluster.size = function(x) {
    return arguments.length ? (nodeSize = false, dx = +x[0], dy = +x[1], cluster) : (nodeSize ? null : [dx, dy]);
  };

  cluster.nodeSize = function(x) {
    return arguments.length ? (nodeSize = true, dx = +x[0], dy = +x[1], cluster) : (nodeSize ? [dx, dy] : null);
  };

  return cluster;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/constant.js":
/*!*******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/constant.js ***!
  \*******************************************************************************/
/*! exports provided: constantZero, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "constantZero", function() { return constantZero; });
function constantZero() {
  return 0;
}

/* harmony default export */ __webpack_exports__["default"] = (function(x) {
  return function() {
    return x;
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/ancestors.js":
/*!******************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/ancestors.js ***!
  \******************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {
  var node = this, nodes = [node];
  while (node = node.parent) {
    nodes.push(node);
  }
  return nodes;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/count.js":
/*!**************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/count.js ***!
  \**************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function count(node) {
  var sum = 0,
      children = node.children,
      i = children && children.length;
  if (!i) sum = 1;
  else while (--i >= 0) sum += children[i].value;
  node.value = sum;
}

/* harmony default export */ __webpack_exports__["default"] = (function() {
  return this.eachAfter(count);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/descendants.js":
/*!********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/descendants.js ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {
  return Array.from(this);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/each.js":
/*!*************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/each.js ***!
  \*************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(callback, that) {
  let index = -1;
  for (const node of this) {
    callback.call(that, node, ++index, this);
  }
  return this;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/eachAfter.js":
/*!******************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/eachAfter.js ***!
  \******************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(callback, that) {
  var node = this, nodes = [node], next = [], children, i, n, index = -1;
  while (node = nodes.pop()) {
    next.push(node);
    if (children = node.children) {
      for (i = 0, n = children.length; i < n; ++i) {
        nodes.push(children[i]);
      }
    }
  }
  while (node = next.pop()) {
    callback.call(that, node, ++index, this);
  }
  return this;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/eachBefore.js":
/*!*******************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/eachBefore.js ***!
  \*******************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(callback, that) {
  var node = this, nodes = [node], children, i, index = -1;
  while (node = nodes.pop()) {
    callback.call(that, node, ++index, this);
    if (children = node.children) {
      for (i = children.length - 1; i >= 0; --i) {
        nodes.push(children[i]);
      }
    }
  }
  return this;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/find.js":
/*!*************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/find.js ***!
  \*************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(callback, that) {
  let index = -1;
  for (const node of this) {
    if (callback.call(that, node, ++index, this)) {
      return node;
    }
  }
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/index.js":
/*!**************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/index.js ***!
  \**************************************************************************************/
/*! exports provided: default, computeHeight, Node */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return hierarchy; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "computeHeight", function() { return computeHeight; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Node", function() { return Node; });
/* harmony import */ var _count_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./count.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/count.js");
/* harmony import */ var _each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./each.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/each.js");
/* harmony import */ var _eachBefore_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./eachBefore.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/eachBefore.js");
/* harmony import */ var _eachAfter_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./eachAfter.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/eachAfter.js");
/* harmony import */ var _find_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./find.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/find.js");
/* harmony import */ var _sum_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./sum.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/sum.js");
/* harmony import */ var _sort_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./sort.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/sort.js");
/* harmony import */ var _path_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./path.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/path.js");
/* harmony import */ var _ancestors_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./ancestors.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/ancestors.js");
/* harmony import */ var _descendants_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./descendants.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/descendants.js");
/* harmony import */ var _leaves_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./leaves.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/leaves.js");
/* harmony import */ var _links_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./links.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/links.js");
/* harmony import */ var _iterator_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./iterator.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/iterator.js");














function hierarchy(data, children) {
  if (data instanceof Map) {
    data = [undefined, data];
    if (children === undefined) children = mapChildren;
  } else if (children === undefined) {
    children = objectChildren;
  }

  var root = new Node(data),
      node,
      nodes = [root],
      child,
      childs,
      i,
      n;

  while (node = nodes.pop()) {
    if ((childs = children(node.data)) && (n = (childs = Array.from(childs)).length)) {
      node.children = childs;
      for (i = n - 1; i >= 0; --i) {
        nodes.push(child = childs[i] = new Node(childs[i]));
        child.parent = node;
        child.depth = node.depth + 1;
      }
    }
  }

  return root.eachBefore(computeHeight);
}

function node_copy() {
  return hierarchy(this).eachBefore(copyData);
}

function objectChildren(d) {
  return d.children;
}

function mapChildren(d) {
  return Array.isArray(d) ? d[1] : null;
}

function copyData(node) {
  if (node.data.value !== undefined) node.value = node.data.value;
  node.data = node.data.data;
}

function computeHeight(node) {
  var height = 0;
  do node.height = height;
  while ((node = node.parent) && (node.height < ++height));
}

function Node(data) {
  this.data = data;
  this.depth =
  this.height = 0;
  this.parent = null;
}

Node.prototype = hierarchy.prototype = {
  constructor: Node,
  count: _count_js__WEBPACK_IMPORTED_MODULE_0__["default"],
  each: _each_js__WEBPACK_IMPORTED_MODULE_1__["default"],
  eachAfter: _eachAfter_js__WEBPACK_IMPORTED_MODULE_3__["default"],
  eachBefore: _eachBefore_js__WEBPACK_IMPORTED_MODULE_2__["default"],
  find: _find_js__WEBPACK_IMPORTED_MODULE_4__["default"],
  sum: _sum_js__WEBPACK_IMPORTED_MODULE_5__["default"],
  sort: _sort_js__WEBPACK_IMPORTED_MODULE_6__["default"],
  path: _path_js__WEBPACK_IMPORTED_MODULE_7__["default"],
  ancestors: _ancestors_js__WEBPACK_IMPORTED_MODULE_8__["default"],
  descendants: _descendants_js__WEBPACK_IMPORTED_MODULE_9__["default"],
  leaves: _leaves_js__WEBPACK_IMPORTED_MODULE_10__["default"],
  links: _links_js__WEBPACK_IMPORTED_MODULE_11__["default"],
  copy: node_copy,
  [Symbol.iterator]: _iterator_js__WEBPACK_IMPORTED_MODULE_12__["default"]
};


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/iterator.js":
/*!*****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/iterator.js ***!
  \*****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function*() {
  var node = this, current, next = [node], children, i, n;
  do {
    current = next.reverse(), next = [];
    while (node = current.pop()) {
      yield node;
      if (children = node.children) {
        for (i = 0, n = children.length; i < n; ++i) {
          next.push(children[i]);
        }
      }
    }
  } while (next.length);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/leaves.js":
/*!***************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/leaves.js ***!
  \***************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {
  var leaves = [];
  this.eachBefore(function(node) {
    if (!node.children) {
      leaves.push(node);
    }
  });
  return leaves;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/links.js":
/*!**************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/links.js ***!
  \**************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {
  var root = this, links = [];
  root.each(function(node) {
    if (node !== root) { // Don’t include the root’s parent, if any.
      links.push({source: node.parent, target: node});
    }
  });
  return links;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/path.js":
/*!*************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/path.js ***!
  \*************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(end) {
  var start = this,
      ancestor = leastCommonAncestor(start, end),
      nodes = [start];
  while (start !== ancestor) {
    start = start.parent;
    nodes.push(start);
  }
  var k = nodes.length;
  while (end !== ancestor) {
    nodes.splice(k, 0, end);
    end = end.parent;
  }
  return nodes;
});

function leastCommonAncestor(a, b) {
  if (a === b) return a;
  var aNodes = a.ancestors(),
      bNodes = b.ancestors(),
      c = null;
  a = aNodes.pop();
  b = bNodes.pop();
  while (a === b) {
    c = a;
    a = aNodes.pop();
    b = bNodes.pop();
  }
  return c;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/sort.js":
/*!*************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/sort.js ***!
  \*************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(compare) {
  return this.eachBefore(function(node) {
    if (node.children) {
      node.children.sort(compare);
    }
  });
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/sum.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/sum.js ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  return this.eachAfter(function(node) {
    var sum = +value(node.data) || 0,
        children = node.children,
        i = children && children.length;
    while (--i >= 0) sum += children[i].value;
    node.value = sum;
  });
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/index.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/index.js ***!
  \****************************************************************************/
/*! exports provided: cluster, hierarchy, Node, pack, packSiblings, packEnclose, partition, stratify, tree, treemap, treemapBinary, treemapDice, treemapSlice, treemapSliceDice, treemapSquarify, treemapResquarify */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _cluster_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./cluster.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/cluster.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "cluster", function() { return _cluster_js__WEBPACK_IMPORTED_MODULE_0__["default"]; });

/* harmony import */ var _hierarchy_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./hierarchy/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/index.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "hierarchy", function() { return _hierarchy_index_js__WEBPACK_IMPORTED_MODULE_1__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "Node", function() { return _hierarchy_index_js__WEBPACK_IMPORTED_MODULE_1__["Node"]; });

/* harmony import */ var _pack_index_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./pack/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/index.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "pack", function() { return _pack_index_js__WEBPACK_IMPORTED_MODULE_2__["default"]; });

/* harmony import */ var _pack_siblings_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./pack/siblings.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/siblings.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "packSiblings", function() { return _pack_siblings_js__WEBPACK_IMPORTED_MODULE_3__["default"]; });

/* harmony import */ var _pack_enclose_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./pack/enclose.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/enclose.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "packEnclose", function() { return _pack_enclose_js__WEBPACK_IMPORTED_MODULE_4__["default"]; });

/* harmony import */ var _partition_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./partition.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/partition.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "partition", function() { return _partition_js__WEBPACK_IMPORTED_MODULE_5__["default"]; });

/* harmony import */ var _stratify_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./stratify.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/stratify.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "stratify", function() { return _stratify_js__WEBPACK_IMPORTED_MODULE_6__["default"]; });

/* harmony import */ var _tree_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./tree.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/tree.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "tree", function() { return _tree_js__WEBPACK_IMPORTED_MODULE_7__["default"]; });

/* harmony import */ var _treemap_index_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./treemap/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/index.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "treemap", function() { return _treemap_index_js__WEBPACK_IMPORTED_MODULE_8__["default"]; });

/* harmony import */ var _treemap_binary_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./treemap/binary.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/binary.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "treemapBinary", function() { return _treemap_binary_js__WEBPACK_IMPORTED_MODULE_9__["default"]; });

/* harmony import */ var _treemap_dice_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./treemap/dice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/dice.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "treemapDice", function() { return _treemap_dice_js__WEBPACK_IMPORTED_MODULE_10__["default"]; });

/* harmony import */ var _treemap_slice_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./treemap/slice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/slice.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "treemapSlice", function() { return _treemap_slice_js__WEBPACK_IMPORTED_MODULE_11__["default"]; });

/* harmony import */ var _treemap_sliceDice_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./treemap/sliceDice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/sliceDice.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "treemapSliceDice", function() { return _treemap_sliceDice_js__WEBPACK_IMPORTED_MODULE_12__["default"]; });

/* harmony import */ var _treemap_squarify_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./treemap/squarify.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/squarify.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "treemapSquarify", function() { return _treemap_squarify_js__WEBPACK_IMPORTED_MODULE_13__["default"]; });

/* harmony import */ var _treemap_resquarify_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./treemap/resquarify.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/resquarify.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "treemapResquarify", function() { return _treemap_resquarify_js__WEBPACK_IMPORTED_MODULE_14__["default"]; });


















/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/lcg.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/lcg.js ***!
  \**************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
// https://en.wikipedia.org/wiki/Linear_congruential_generator#Parameters_in_common_use
const a = 1664525;
const c = 1013904223;
const m = 4294967296; // 2^32

/* harmony default export */ __webpack_exports__["default"] = (function() {
  let s = 1;
  return () => (s = (a * s + c) % m) / m;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/enclose.js":
/*!***********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/enclose.js ***!
  \***********************************************************************************/
/*! exports provided: default, packEncloseRandom */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "packEncloseRandom", function() { return packEncloseRandom; });
/* harmony import */ var _array_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../array.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/array.js");
/* harmony import */ var _lcg_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../lcg.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/lcg.js");



/* harmony default export */ __webpack_exports__["default"] = (function(circles) {
  return packEncloseRandom(circles, Object(_lcg_js__WEBPACK_IMPORTED_MODULE_1__["default"])());
});

function packEncloseRandom(circles, random) {
  var i = 0, n = (circles = Object(_array_js__WEBPACK_IMPORTED_MODULE_0__["shuffle"])(Array.from(circles), random)).length, B = [], p, e;

  while (i < n) {
    p = circles[i];
    if (e && enclosesWeak(e, p)) ++i;
    else e = encloseBasis(B = extendBasis(B, p)), i = 0;
  }

  return e;
}

function extendBasis(B, p) {
  var i, j;

  if (enclosesWeakAll(p, B)) return [p];

  // If we get here then B must have at least one element.
  for (i = 0; i < B.length; ++i) {
    if (enclosesNot(p, B[i])
        && enclosesWeakAll(encloseBasis2(B[i], p), B)) {
      return [B[i], p];
    }
  }

  // If we get here then B must have at least two elements.
  for (i = 0; i < B.length - 1; ++i) {
    for (j = i + 1; j < B.length; ++j) {
      if (enclosesNot(encloseBasis2(B[i], B[j]), p)
          && enclosesNot(encloseBasis2(B[i], p), B[j])
          && enclosesNot(encloseBasis2(B[j], p), B[i])
          && enclosesWeakAll(encloseBasis3(B[i], B[j], p), B)) {
        return [B[i], B[j], p];
      }
    }
  }

  // If we get here then something is very wrong.
  throw new Error;
}

function enclosesNot(a, b) {
  var dr = a.r - b.r, dx = b.x - a.x, dy = b.y - a.y;
  return dr < 0 || dr * dr < dx * dx + dy * dy;
}

function enclosesWeak(a, b) {
  var dr = a.r - b.r + Math.max(a.r, b.r, 1) * 1e-9, dx = b.x - a.x, dy = b.y - a.y;
  return dr > 0 && dr * dr > dx * dx + dy * dy;
}

function enclosesWeakAll(a, B) {
  for (var i = 0; i < B.length; ++i) {
    if (!enclosesWeak(a, B[i])) {
      return false;
    }
  }
  return true;
}

function encloseBasis(B) {
  switch (B.length) {
    case 1: return encloseBasis1(B[0]);
    case 2: return encloseBasis2(B[0], B[1]);
    case 3: return encloseBasis3(B[0], B[1], B[2]);
  }
}

function encloseBasis1(a) {
  return {
    x: a.x,
    y: a.y,
    r: a.r
  };
}

function encloseBasis2(a, b) {
  var x1 = a.x, y1 = a.y, r1 = a.r,
      x2 = b.x, y2 = b.y, r2 = b.r,
      x21 = x2 - x1, y21 = y2 - y1, r21 = r2 - r1,
      l = Math.sqrt(x21 * x21 + y21 * y21);
  return {
    x: (x1 + x2 + x21 / l * r21) / 2,
    y: (y1 + y2 + y21 / l * r21) / 2,
    r: (l + r1 + r2) / 2
  };
}

function encloseBasis3(a, b, c) {
  var x1 = a.x, y1 = a.y, r1 = a.r,
      x2 = b.x, y2 = b.y, r2 = b.r,
      x3 = c.x, y3 = c.y, r3 = c.r,
      a2 = x1 - x2,
      a3 = x1 - x3,
      b2 = y1 - y2,
      b3 = y1 - y3,
      c2 = r2 - r1,
      c3 = r3 - r1,
      d1 = x1 * x1 + y1 * y1 - r1 * r1,
      d2 = d1 - x2 * x2 - y2 * y2 + r2 * r2,
      d3 = d1 - x3 * x3 - y3 * y3 + r3 * r3,
      ab = a3 * b2 - a2 * b3,
      xa = (b2 * d3 - b3 * d2) / (ab * 2) - x1,
      xb = (b3 * c2 - b2 * c3) / ab,
      ya = (a3 * d2 - a2 * d3) / (ab * 2) - y1,
      yb = (a2 * c3 - a3 * c2) / ab,
      A = xb * xb + yb * yb - 1,
      B = 2 * (r1 + xa * xb + ya * yb),
      C = xa * xa + ya * ya - r1 * r1,
      r = -(Math.abs(A) > 1e-6 ? (B + Math.sqrt(B * B - 4 * A * C)) / (2 * A) : C / B);
  return {
    x: x1 + xa + xb * r,
    y: y1 + ya + yb * r,
    r: r
  };
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/index.js":
/*!*********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/index.js ***!
  \*********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _accessors_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../accessors.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/accessors.js");
/* harmony import */ var _constant_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../constant.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/constant.js");
/* harmony import */ var _lcg_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../lcg.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/lcg.js");
/* harmony import */ var _siblings_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./siblings.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/siblings.js");





function defaultRadius(d) {
  return Math.sqrt(d.value);
}

/* harmony default export */ __webpack_exports__["default"] = (function() {
  var radius = null,
      dx = 1,
      dy = 1,
      padding = _constant_js__WEBPACK_IMPORTED_MODULE_1__["constantZero"];

  function pack(root) {
    const random = Object(_lcg_js__WEBPACK_IMPORTED_MODULE_2__["default"])();
    root.x = dx / 2, root.y = dy / 2;
    if (radius) {
      root.eachBefore(radiusLeaf(radius))
          .eachAfter(packChildrenRandom(padding, 0.5, random))
          .eachBefore(translateChild(1));
    } else {
      root.eachBefore(radiusLeaf(defaultRadius))
          .eachAfter(packChildrenRandom(_constant_js__WEBPACK_IMPORTED_MODULE_1__["constantZero"], 1, random))
          .eachAfter(packChildrenRandom(padding, root.r / Math.min(dx, dy), random))
          .eachBefore(translateChild(Math.min(dx, dy) / (2 * root.r)));
    }
    return root;
  }

  pack.radius = function(x) {
    return arguments.length ? (radius = Object(_accessors_js__WEBPACK_IMPORTED_MODULE_0__["optional"])(x), pack) : radius;
  };

  pack.size = function(x) {
    return arguments.length ? (dx = +x[0], dy = +x[1], pack) : [dx, dy];
  };

  pack.padding = function(x) {
    return arguments.length ? (padding = typeof x === "function" ? x : Object(_constant_js__WEBPACK_IMPORTED_MODULE_1__["default"])(+x), pack) : padding;
  };

  return pack;
});

function radiusLeaf(radius) {
  return function(node) {
    if (!node.children) {
      node.r = Math.max(0, +radius(node) || 0);
    }
  };
}

function packChildrenRandom(padding, k, random) {
  return function(node) {
    if (children = node.children) {
      var children,
          i,
          n = children.length,
          r = padding(node) * k || 0,
          e;

      if (r) for (i = 0; i < n; ++i) children[i].r += r;
      e = Object(_siblings_js__WEBPACK_IMPORTED_MODULE_3__["packSiblingsRandom"])(children, random);
      if (r) for (i = 0; i < n; ++i) children[i].r -= r;
      node.r = e + r;
    }
  };
}

function translateChild(k) {
  return function(node) {
    var parent = node.parent;
    node.r *= k;
    if (parent) {
      node.x = parent.x + k * node.x;
      node.y = parent.y + k * node.y;
    }
  };
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/siblings.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/siblings.js ***!
  \************************************************************************************/
/*! exports provided: packSiblingsRandom, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "packSiblingsRandom", function() { return packSiblingsRandom; });
/* harmony import */ var _array_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../array.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/array.js");
/* harmony import */ var _lcg_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../lcg.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/lcg.js");
/* harmony import */ var _enclose_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./enclose.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/pack/enclose.js");




function place(b, a, c) {
  var dx = b.x - a.x, x, a2,
      dy = b.y - a.y, y, b2,
      d2 = dx * dx + dy * dy;
  if (d2) {
    a2 = a.r + c.r, a2 *= a2;
    b2 = b.r + c.r, b2 *= b2;
    if (a2 > b2) {
      x = (d2 + b2 - a2) / (2 * d2);
      y = Math.sqrt(Math.max(0, b2 / d2 - x * x));
      c.x = b.x - x * dx - y * dy;
      c.y = b.y - x * dy + y * dx;
    } else {
      x = (d2 + a2 - b2) / (2 * d2);
      y = Math.sqrt(Math.max(0, a2 / d2 - x * x));
      c.x = a.x + x * dx - y * dy;
      c.y = a.y + x * dy + y * dx;
    }
  } else {
    c.x = a.x + c.r;
    c.y = a.y;
  }
}

function intersects(a, b) {
  var dr = a.r + b.r - 1e-6, dx = b.x - a.x, dy = b.y - a.y;
  return dr > 0 && dr * dr > dx * dx + dy * dy;
}

function score(node) {
  var a = node._,
      b = node.next._,
      ab = a.r + b.r,
      dx = (a.x * b.r + b.x * a.r) / ab,
      dy = (a.y * b.r + b.y * a.r) / ab;
  return dx * dx + dy * dy;
}

function Node(circle) {
  this._ = circle;
  this.next = null;
  this.previous = null;
}

function packSiblingsRandom(circles, random) {
  if (!(n = (circles = Object(_array_js__WEBPACK_IMPORTED_MODULE_0__["default"])(circles)).length)) return 0;

  var a, b, c, n, aa, ca, i, j, k, sj, sk;

  // Place the first circle.
  a = circles[0], a.x = 0, a.y = 0;
  if (!(n > 1)) return a.r;

  // Place the second circle.
  b = circles[1], a.x = -b.r, b.x = a.r, b.y = 0;
  if (!(n > 2)) return a.r + b.r;

  // Place the third circle.
  place(b, a, c = circles[2]);

  // Initialize the front-chain using the first three circles a, b and c.
  a = new Node(a), b = new Node(b), c = new Node(c);
  a.next = c.previous = b;
  b.next = a.previous = c;
  c.next = b.previous = a;

  // Attempt to place each remaining circle…
  pack: for (i = 3; i < n; ++i) {
    place(a._, b._, c = circles[i]), c = new Node(c);

    // Find the closest intersecting circle on the front-chain, if any.
    // “Closeness” is determined by linear distance along the front-chain.
    // “Ahead” or “behind” is likewise determined by linear distance.
    j = b.next, k = a.previous, sj = b._.r, sk = a._.r;
    do {
      if (sj <= sk) {
        if (intersects(j._, c._)) {
          b = j, a.next = b, b.previous = a, --i;
          continue pack;
        }
        sj += j._.r, j = j.next;
      } else {
        if (intersects(k._, c._)) {
          a = k, a.next = b, b.previous = a, --i;
          continue pack;
        }
        sk += k._.r, k = k.previous;
      }
    } while (j !== k.next);

    // Success! Insert the new circle c between a and b.
    c.previous = a, c.next = b, a.next = b.previous = b = c;

    // Compute the new closest circle pair to the centroid.
    aa = score(a);
    while ((c = c.next) !== b) {
      if ((ca = score(c)) < aa) {
        a = c, aa = ca;
      }
    }
    b = a.next;
  }

  // Compute the enclosing circle of the front chain.
  a = [b._], c = b; while ((c = c.next) !== b) a.push(c._); c = Object(_enclose_js__WEBPACK_IMPORTED_MODULE_2__["packEncloseRandom"])(a, random);

  // Translate the circles to put the enclosing circle around the origin.
  for (i = 0; i < n; ++i) a = circles[i], a.x -= c.x, a.y -= c.y;

  return c.r;
}

/* harmony default export */ __webpack_exports__["default"] = (function(circles) {
  packSiblingsRandom(circles, Object(_lcg_js__WEBPACK_IMPORTED_MODULE_1__["default"])());
  return circles;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/partition.js":
/*!********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/partition.js ***!
  \********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _treemap_round_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./treemap/round.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/round.js");
/* harmony import */ var _treemap_dice_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./treemap/dice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/dice.js");



/* harmony default export */ __webpack_exports__["default"] = (function() {
  var dx = 1,
      dy = 1,
      padding = 0,
      round = false;

  function partition(root) {
    var n = root.height + 1;
    root.x0 =
    root.y0 = padding;
    root.x1 = dx;
    root.y1 = dy / n;
    root.eachBefore(positionNode(dy, n));
    if (round) root.eachBefore(_treemap_round_js__WEBPACK_IMPORTED_MODULE_0__["default"]);
    return root;
  }

  function positionNode(dy, n) {
    return function(node) {
      if (node.children) {
        Object(_treemap_dice_js__WEBPACK_IMPORTED_MODULE_1__["default"])(node, node.x0, dy * (node.depth + 1) / n, node.x1, dy * (node.depth + 2) / n);
      }
      var x0 = node.x0,
          y0 = node.y0,
          x1 = node.x1 - padding,
          y1 = node.y1 - padding;
      if (x1 < x0) x0 = x1 = (x0 + x1) / 2;
      if (y1 < y0) y0 = y1 = (y0 + y1) / 2;
      node.x0 = x0;
      node.y0 = y0;
      node.x1 = x1;
      node.y1 = y1;
    };
  }

  partition.round = function(x) {
    return arguments.length ? (round = !!x, partition) : round;
  };

  partition.size = function(x) {
    return arguments.length ? (dx = +x[0], dy = +x[1], partition) : [dx, dy];
  };

  partition.padding = function(x) {
    return arguments.length ? (padding = +x, partition) : padding;
  };

  return partition;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/stratify.js":
/*!*******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/stratify.js ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _accessors_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./accessors.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/accessors.js");
/* harmony import */ var _hierarchy_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./hierarchy/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/index.js");



var preroot = {depth: -1},
    ambiguous = {},
    imputed = {};

function defaultId(d) {
  return d.id;
}

function defaultParentId(d) {
  return d.parentId;
}

/* harmony default export */ __webpack_exports__["default"] = (function() {
  var id = defaultId,
      parentId = defaultParentId,
      path;

  function stratify(data) {
    var nodes = Array.from(data),
        currentId = id,
        currentParentId = parentId,
        n,
        d,
        i,
        root,
        parent,
        node,
        nodeId,
        nodeKey,
        nodeByKey = new Map;

    if (path != null) {
      const I = nodes.map((d, i) => normalize(path(d, i, data)));
      const P = I.map(parentof);
      const S = new Set(I).add("");
      for (const i of P) {
        if (!S.has(i)) {
          S.add(i);
          I.push(i);
          P.push(parentof(i));
          nodes.push(imputed);
        }
      }
      currentId = (_, i) => I[i];
      currentParentId = (_, i) => P[i];
    }

    for (i = 0, n = nodes.length; i < n; ++i) {
      d = nodes[i], node = nodes[i] = new _hierarchy_index_js__WEBPACK_IMPORTED_MODULE_1__["Node"](d);
      if ((nodeId = currentId(d, i, data)) != null && (nodeId += "")) {
        nodeKey = node.id = nodeId;
        nodeByKey.set(nodeKey, nodeByKey.has(nodeKey) ? ambiguous : node);
      }
      if ((nodeId = currentParentId(d, i, data)) != null && (nodeId += "")) {
        node.parent = nodeId;
      }
    }

    for (i = 0; i < n; ++i) {
      node = nodes[i];
      if (nodeId = node.parent) {
        parent = nodeByKey.get(nodeId);
        if (!parent) throw new Error("missing: " + nodeId);
        if (parent === ambiguous) throw new Error("ambiguous: " + nodeId);
        if (parent.children) parent.children.push(node);
        else parent.children = [node];
        node.parent = parent;
      } else {
        if (root) throw new Error("multiple roots");
        root = node;
      }
    }

    if (!root) throw new Error("no root");

    // When imputing internal nodes, only introduce roots if needed.
    // Then replace the imputed marker data with null.
    if (path != null) {
      while (root.data === imputed && root.children.length === 1) {
        root = root.children[0], --n;
      }
      for (let i = nodes.length - 1; i >= 0; --i) {
        node = nodes[i];
        if (node.data !== imputed) break;
        node.data = null;
      }
    }

    root.parent = preroot;
    root.eachBefore(function(node) { node.depth = node.parent.depth + 1; --n; }).eachBefore(_hierarchy_index_js__WEBPACK_IMPORTED_MODULE_1__["computeHeight"]);
    root.parent = null;
    if (n > 0) throw new Error("cycle");

    return root;
  }

  stratify.id = function(x) {
    return arguments.length ? (id = Object(_accessors_js__WEBPACK_IMPORTED_MODULE_0__["optional"])(x), stratify) : id;
  };

  stratify.parentId = function(x) {
    return arguments.length ? (parentId = Object(_accessors_js__WEBPACK_IMPORTED_MODULE_0__["optional"])(x), stratify) : parentId;
  };

  stratify.path = function(x) {
    return arguments.length ? (path = Object(_accessors_js__WEBPACK_IMPORTED_MODULE_0__["optional"])(x), stratify) : path;
  };

  return stratify;
});

// To normalize a path, we coerce to a string, strip the trailing slash if any
// (as long as the trailing slash is not immediately preceded by another slash),
// and add leading slash if missing.
function normalize(path) {
  path = `${path}`;
  let i = path.length;
  if (slash(path, i - 1) && !slash(path, i - 2)) path = path.slice(0, -1);
  return path[0] === "/" ? path : `/${path}`;
}

// Walk backwards to find the first slash that is not the leading slash, e.g.:
// "/foo/bar" ⇥ "/foo", "/foo" ⇥ "/", "/" ↦ "". (The root is special-cased
// because the id of the root must be a truthy value.)
function parentof(path) {
  let i = path.length;
  if (i < 2) return "";
  while (--i > 1) if (slash(path, i)) break;
  return path.slice(0, i);
}

// Slashes can be escaped; to determine whether a slash is a path delimiter, we
// count the number of preceding backslashes escaping the forward slash: an odd
// number indicates an escaped forward slash.
function slash(path, i) {
  if (path[i] === "/") {
    let k = 0;
    while (i > 0 && path[--i] === "\\") ++k;
    if ((k & 1) === 0) return true;
  }
  return false;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/tree.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/tree.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _hierarchy_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./hierarchy/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/hierarchy/index.js");


function defaultSeparation(a, b) {
  return a.parent === b.parent ? 1 : 2;
}

// function radialSeparation(a, b) {
//   return (a.parent === b.parent ? 1 : 2) / a.depth;
// }

// This function is used to traverse the left contour of a subtree (or
// subforest). It returns the successor of v on this contour. This successor is
// either given by the leftmost child of v or by the thread of v. The function
// returns null if and only if v is on the highest level of its subtree.
function nextLeft(v) {
  var children = v.children;
  return children ? children[0] : v.t;
}

// This function works analogously to nextLeft.
function nextRight(v) {
  var children = v.children;
  return children ? children[children.length - 1] : v.t;
}

// Shifts the current subtree rooted at w+. This is done by increasing
// prelim(w+) and mod(w+) by shift.
function moveSubtree(wm, wp, shift) {
  var change = shift / (wp.i - wm.i);
  wp.c -= change;
  wp.s += shift;
  wm.c += change;
  wp.z += shift;
  wp.m += shift;
}

// All other shifts, applied to the smaller subtrees between w- and w+, are
// performed by this function. To prepare the shifts, we have to adjust
// change(w+), shift(w+), and change(w-).
function executeShifts(v) {
  var shift = 0,
      change = 0,
      children = v.children,
      i = children.length,
      w;
  while (--i >= 0) {
    w = children[i];
    w.z += shift;
    w.m += shift;
    shift += w.s + (change += w.c);
  }
}

// If vi-’s ancestor is a sibling of v, returns vi-’s ancestor. Otherwise,
// returns the specified (default) ancestor.
function nextAncestor(vim, v, ancestor) {
  return vim.a.parent === v.parent ? vim.a : ancestor;
}

function TreeNode(node, i) {
  this._ = node;
  this.parent = null;
  this.children = null;
  this.A = null; // default ancestor
  this.a = this; // ancestor
  this.z = 0; // prelim
  this.m = 0; // mod
  this.c = 0; // change
  this.s = 0; // shift
  this.t = null; // thread
  this.i = i; // number
}

TreeNode.prototype = Object.create(_hierarchy_index_js__WEBPACK_IMPORTED_MODULE_0__["Node"].prototype);

function treeRoot(root) {
  var tree = new TreeNode(root, 0),
      node,
      nodes = [tree],
      child,
      children,
      i,
      n;

  while (node = nodes.pop()) {
    if (children = node._.children) {
      node.children = new Array(n = children.length);
      for (i = n - 1; i >= 0; --i) {
        nodes.push(child = node.children[i] = new TreeNode(children[i], i));
        child.parent = node;
      }
    }
  }

  (tree.parent = new TreeNode(null, 0)).children = [tree];
  return tree;
}

// Node-link tree diagram using the Reingold-Tilford "tidy" algorithm
/* harmony default export */ __webpack_exports__["default"] = (function() {
  var separation = defaultSeparation,
      dx = 1,
      dy = 1,
      nodeSize = null;

  function tree(root) {
    var t = treeRoot(root);

    // Compute the layout using Buchheim et al.’s algorithm.
    t.eachAfter(firstWalk), t.parent.m = -t.z;
    t.eachBefore(secondWalk);

    // If a fixed node size is specified, scale x and y.
    if (nodeSize) root.eachBefore(sizeNode);

    // If a fixed tree size is specified, scale x and y based on the extent.
    // Compute the left-most, right-most, and depth-most nodes for extents.
    else {
      var left = root,
          right = root,
          bottom = root;
      root.eachBefore(function(node) {
        if (node.x < left.x) left = node;
        if (node.x > right.x) right = node;
        if (node.depth > bottom.depth) bottom = node;
      });
      var s = left === right ? 1 : separation(left, right) / 2,
          tx = s - left.x,
          kx = dx / (right.x + s + tx),
          ky = dy / (bottom.depth || 1);
      root.eachBefore(function(node) {
        node.x = (node.x + tx) * kx;
        node.y = node.depth * ky;
      });
    }

    return root;
  }

  // Computes a preliminary x-coordinate for v. Before that, FIRST WALK is
  // applied recursively to the children of v, as well as the function
  // APPORTION. After spacing out the children by calling EXECUTE SHIFTS, the
  // node v is placed to the midpoint of its outermost children.
  function firstWalk(v) {
    var children = v.children,
        siblings = v.parent.children,
        w = v.i ? siblings[v.i - 1] : null;
    if (children) {
      executeShifts(v);
      var midpoint = (children[0].z + children[children.length - 1].z) / 2;
      if (w) {
        v.z = w.z + separation(v._, w._);
        v.m = v.z - midpoint;
      } else {
        v.z = midpoint;
      }
    } else if (w) {
      v.z = w.z + separation(v._, w._);
    }
    v.parent.A = apportion(v, w, v.parent.A || siblings[0]);
  }

  // Computes all real x-coordinates by summing up the modifiers recursively.
  function secondWalk(v) {
    v._.x = v.z + v.parent.m;
    v.m += v.parent.m;
  }

  // The core of the algorithm. Here, a new subtree is combined with the
  // previous subtrees. Threads are used to traverse the inside and outside
  // contours of the left and right subtree up to the highest common level. The
  // vertices used for the traversals are vi+, vi-, vo-, and vo+, where the
  // superscript o means outside and i means inside, the subscript - means left
  // subtree and + means right subtree. For summing up the modifiers along the
  // contour, we use respective variables si+, si-, so-, and so+. Whenever two
  // nodes of the inside contours conflict, we compute the left one of the
  // greatest uncommon ancestors using the function ANCESTOR and call MOVE
  // SUBTREE to shift the subtree and prepare the shifts of smaller subtrees.
  // Finally, we add a new thread (if necessary).
  function apportion(v, w, ancestor) {
    if (w) {
      var vip = v,
          vop = v,
          vim = w,
          vom = vip.parent.children[0],
          sip = vip.m,
          sop = vop.m,
          sim = vim.m,
          som = vom.m,
          shift;
      while (vim = nextRight(vim), vip = nextLeft(vip), vim && vip) {
        vom = nextLeft(vom);
        vop = nextRight(vop);
        vop.a = v;
        shift = vim.z + sim - vip.z - sip + separation(vim._, vip._);
        if (shift > 0) {
          moveSubtree(nextAncestor(vim, v, ancestor), v, shift);
          sip += shift;
          sop += shift;
        }
        sim += vim.m;
        sip += vip.m;
        som += vom.m;
        sop += vop.m;
      }
      if (vim && !nextRight(vop)) {
        vop.t = vim;
        vop.m += sim - sop;
      }
      if (vip && !nextLeft(vom)) {
        vom.t = vip;
        vom.m += sip - som;
        ancestor = v;
      }
    }
    return ancestor;
  }

  function sizeNode(node) {
    node.x *= dx;
    node.y = node.depth * dy;
  }

  tree.separation = function(x) {
    return arguments.length ? (separation = x, tree) : separation;
  };

  tree.size = function(x) {
    return arguments.length ? (nodeSize = false, dx = +x[0], dy = +x[1], tree) : (nodeSize ? null : [dx, dy]);
  };

  tree.nodeSize = function(x) {
    return arguments.length ? (nodeSize = true, dx = +x[0], dy = +x[1], tree) : (nodeSize ? [dx, dy] : null);
  };

  return tree;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/binary.js":
/*!*************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/binary.js ***!
  \*************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(parent, x0, y0, x1, y1) {
  var nodes = parent.children,
      i, n = nodes.length,
      sum, sums = new Array(n + 1);

  for (sums[0] = sum = i = 0; i < n; ++i) {
    sums[i + 1] = sum += nodes[i].value;
  }

  partition(0, n, parent.value, x0, y0, x1, y1);

  function partition(i, j, value, x0, y0, x1, y1) {
    if (i >= j - 1) {
      var node = nodes[i];
      node.x0 = x0, node.y0 = y0;
      node.x1 = x1, node.y1 = y1;
      return;
    }

    var valueOffset = sums[i],
        valueTarget = (value / 2) + valueOffset,
        k = i + 1,
        hi = j - 1;

    while (k < hi) {
      var mid = k + hi >>> 1;
      if (sums[mid] < valueTarget) k = mid + 1;
      else hi = mid;
    }

    if ((valueTarget - sums[k - 1]) < (sums[k] - valueTarget) && i + 1 < k) --k;

    var valueLeft = sums[k] - valueOffset,
        valueRight = value - valueLeft;

    if ((x1 - x0) > (y1 - y0)) {
      var xk = value ? (x0 * valueRight + x1 * valueLeft) / value : x1;
      partition(i, k, valueLeft, x0, y0, xk, y1);
      partition(k, j, valueRight, xk, y0, x1, y1);
    } else {
      var yk = value ? (y0 * valueRight + y1 * valueLeft) / value : y1;
      partition(i, k, valueLeft, x0, y0, x1, yk);
      partition(k, j, valueRight, x0, yk, x1, y1);
    }
  }
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/dice.js":
/*!***********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/dice.js ***!
  \***********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(parent, x0, y0, x1, y1) {
  var nodes = parent.children,
      node,
      i = -1,
      n = nodes.length,
      k = parent.value && (x1 - x0) / parent.value;

  while (++i < n) {
    node = nodes[i], node.y0 = y0, node.y1 = y1;
    node.x0 = x0, node.x1 = x0 += node.value * k;
  }
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/index.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/index.js ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _round_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./round.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/round.js");
/* harmony import */ var _squarify_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./squarify.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/squarify.js");
/* harmony import */ var _accessors_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../accessors.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/accessors.js");
/* harmony import */ var _constant_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../constant.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/constant.js");





/* harmony default export */ __webpack_exports__["default"] = (function() {
  var tile = _squarify_js__WEBPACK_IMPORTED_MODULE_1__["default"],
      round = false,
      dx = 1,
      dy = 1,
      paddingStack = [0],
      paddingInner = _constant_js__WEBPACK_IMPORTED_MODULE_3__["constantZero"],
      paddingTop = _constant_js__WEBPACK_IMPORTED_MODULE_3__["constantZero"],
      paddingRight = _constant_js__WEBPACK_IMPORTED_MODULE_3__["constantZero"],
      paddingBottom = _constant_js__WEBPACK_IMPORTED_MODULE_3__["constantZero"],
      paddingLeft = _constant_js__WEBPACK_IMPORTED_MODULE_3__["constantZero"];

  function treemap(root) {
    root.x0 =
    root.y0 = 0;
    root.x1 = dx;
    root.y1 = dy;
    root.eachBefore(positionNode);
    paddingStack = [0];
    if (round) root.eachBefore(_round_js__WEBPACK_IMPORTED_MODULE_0__["default"]);
    return root;
  }

  function positionNode(node) {
    var p = paddingStack[node.depth],
        x0 = node.x0 + p,
        y0 = node.y0 + p,
        x1 = node.x1 - p,
        y1 = node.y1 - p;
    if (x1 < x0) x0 = x1 = (x0 + x1) / 2;
    if (y1 < y0) y0 = y1 = (y0 + y1) / 2;
    node.x0 = x0;
    node.y0 = y0;
    node.x1 = x1;
    node.y1 = y1;
    if (node.children) {
      p = paddingStack[node.depth + 1] = paddingInner(node) / 2;
      x0 += paddingLeft(node) - p;
      y0 += paddingTop(node) - p;
      x1 -= paddingRight(node) - p;
      y1 -= paddingBottom(node) - p;
      if (x1 < x0) x0 = x1 = (x0 + x1) / 2;
      if (y1 < y0) y0 = y1 = (y0 + y1) / 2;
      tile(node, x0, y0, x1, y1);
    }
  }

  treemap.round = function(x) {
    return arguments.length ? (round = !!x, treemap) : round;
  };

  treemap.size = function(x) {
    return arguments.length ? (dx = +x[0], dy = +x[1], treemap) : [dx, dy];
  };

  treemap.tile = function(x) {
    return arguments.length ? (tile = Object(_accessors_js__WEBPACK_IMPORTED_MODULE_2__["required"])(x), treemap) : tile;
  };

  treemap.padding = function(x) {
    return arguments.length ? treemap.paddingInner(x).paddingOuter(x) : treemap.paddingInner();
  };

  treemap.paddingInner = function(x) {
    return arguments.length ? (paddingInner = typeof x === "function" ? x : Object(_constant_js__WEBPACK_IMPORTED_MODULE_3__["default"])(+x), treemap) : paddingInner;
  };

  treemap.paddingOuter = function(x) {
    return arguments.length ? treemap.paddingTop(x).paddingRight(x).paddingBottom(x).paddingLeft(x) : treemap.paddingTop();
  };

  treemap.paddingTop = function(x) {
    return arguments.length ? (paddingTop = typeof x === "function" ? x : Object(_constant_js__WEBPACK_IMPORTED_MODULE_3__["default"])(+x), treemap) : paddingTop;
  };

  treemap.paddingRight = function(x) {
    return arguments.length ? (paddingRight = typeof x === "function" ? x : Object(_constant_js__WEBPACK_IMPORTED_MODULE_3__["default"])(+x), treemap) : paddingRight;
  };

  treemap.paddingBottom = function(x) {
    return arguments.length ? (paddingBottom = typeof x === "function" ? x : Object(_constant_js__WEBPACK_IMPORTED_MODULE_3__["default"])(+x), treemap) : paddingBottom;
  };

  treemap.paddingLeft = function(x) {
    return arguments.length ? (paddingLeft = typeof x === "function" ? x : Object(_constant_js__WEBPACK_IMPORTED_MODULE_3__["default"])(+x), treemap) : paddingLeft;
  };

  return treemap;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/resquarify.js":
/*!*****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/resquarify.js ***!
  \*****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _dice_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/dice.js");
/* harmony import */ var _slice_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./slice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/slice.js");
/* harmony import */ var _squarify_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./squarify.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/squarify.js");




/* harmony default export */ __webpack_exports__["default"] = ((function custom(ratio) {

  function resquarify(parent, x0, y0, x1, y1) {
    if ((rows = parent._squarify) && (rows.ratio === ratio)) {
      var rows,
          row,
          nodes,
          i,
          j = -1,
          n,
          m = rows.length,
          value = parent.value;

      while (++j < m) {
        row = rows[j], nodes = row.children;
        for (i = row.value = 0, n = nodes.length; i < n; ++i) row.value += nodes[i].value;
        if (row.dice) Object(_dice_js__WEBPACK_IMPORTED_MODULE_0__["default"])(row, x0, y0, x1, value ? y0 += (y1 - y0) * row.value / value : y1);
        else Object(_slice_js__WEBPACK_IMPORTED_MODULE_1__["default"])(row, x0, y0, value ? x0 += (x1 - x0) * row.value / value : x1, y1);
        value -= row.value;
      }
    } else {
      parent._squarify = rows = Object(_squarify_js__WEBPACK_IMPORTED_MODULE_2__["squarifyRatio"])(ratio, parent, x0, y0, x1, y1);
      rows.ratio = ratio;
    }
  }

  resquarify.ratio = function(x) {
    return custom((x = +x) > 1 ? x : 1);
  };

  return resquarify;
})(_squarify_js__WEBPACK_IMPORTED_MODULE_2__["phi"]));


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/round.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/round.js ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(node) {
  node.x0 = Math.round(node.x0);
  node.y0 = Math.round(node.y0);
  node.x1 = Math.round(node.x1);
  node.y1 = Math.round(node.y1);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/slice.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/slice.js ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(parent, x0, y0, x1, y1) {
  var nodes = parent.children,
      node,
      i = -1,
      n = nodes.length,
      k = parent.value && (y1 - y0) / parent.value;

  while (++i < n) {
    node = nodes[i], node.x0 = x0, node.x1 = x1;
    node.y0 = y0, node.y1 = y0 += node.value * k;
  }
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/sliceDice.js":
/*!****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/sliceDice.js ***!
  \****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _dice_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/dice.js");
/* harmony import */ var _slice_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./slice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/slice.js");



/* harmony default export */ __webpack_exports__["default"] = (function(parent, x0, y0, x1, y1) {
  (parent.depth & 1 ? _slice_js__WEBPACK_IMPORTED_MODULE_1__["default"] : _dice_js__WEBPACK_IMPORTED_MODULE_0__["default"])(parent, x0, y0, x1, y1);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/squarify.js":
/*!***************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/squarify.js ***!
  \***************************************************************************************/
/*! exports provided: phi, squarifyRatio, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "phi", function() { return phi; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "squarifyRatio", function() { return squarifyRatio; });
/* harmony import */ var _dice_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/dice.js");
/* harmony import */ var _slice_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./slice.js */ "./node_modules/d3-flame-graph/node_modules/d3-hierarchy/src/treemap/slice.js");



var phi = (1 + Math.sqrt(5)) / 2;

function squarifyRatio(ratio, parent, x0, y0, x1, y1) {
  var rows = [],
      nodes = parent.children,
      row,
      nodeValue,
      i0 = 0,
      i1 = 0,
      n = nodes.length,
      dx, dy,
      value = parent.value,
      sumValue,
      minValue,
      maxValue,
      newRatio,
      minRatio,
      alpha,
      beta;

  while (i0 < n) {
    dx = x1 - x0, dy = y1 - y0;

    // Find the next non-empty node.
    do sumValue = nodes[i1++].value; while (!sumValue && i1 < n);
    minValue = maxValue = sumValue;
    alpha = Math.max(dy / dx, dx / dy) / (value * ratio);
    beta = sumValue * sumValue * alpha;
    minRatio = Math.max(maxValue / beta, beta / minValue);

    // Keep adding nodes while the aspect ratio maintains or improves.
    for (; i1 < n; ++i1) {
      sumValue += nodeValue = nodes[i1].value;
      if (nodeValue < minValue) minValue = nodeValue;
      if (nodeValue > maxValue) maxValue = nodeValue;
      beta = sumValue * sumValue * alpha;
      newRatio = Math.max(maxValue / beta, beta / minValue);
      if (newRatio > minRatio) { sumValue -= nodeValue; break; }
      minRatio = newRatio;
    }

    // Position and record the row orientation.
    rows.push(row = {value: sumValue, dice: dx < dy, children: nodes.slice(i0, i1)});
    if (row.dice) Object(_dice_js__WEBPACK_IMPORTED_MODULE_0__["default"])(row, x0, y0, x1, value ? y0 += dy * sumValue / value : y1);
    else Object(_slice_js__WEBPACK_IMPORTED_MODULE_1__["default"])(row, x0, y0, value ? x0 += dx * sumValue / value : x1, y1);
    value -= sumValue, i0 = i1;
  }

  return rows;
}

/* harmony default export */ __webpack_exports__["default"] = ((function custom(ratio) {

  function squarify(parent, x0, y0, x1, y1) {
    squarifyRatio(ratio, parent, x0, y0, x1, y1);
  }

  squarify.ratio = function(x) {
    return custom((x = +x) > 1 ? x : 1);
  };

  return squarify;
})(phi));


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/array.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/array.js ***!
  \******************************************************************************/
/*! exports provided: default, genericArray */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "genericArray", function() { return genericArray; });
/* harmony import */ var _value_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./value.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/value.js");
/* harmony import */ var _numberArray_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./numberArray.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/numberArray.js");



/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  return (Object(_numberArray_js__WEBPACK_IMPORTED_MODULE_1__["isNumberArray"])(b) ? _numberArray_js__WEBPACK_IMPORTED_MODULE_1__["default"] : genericArray)(a, b);
});

function genericArray(a, b) {
  var nb = b ? b.length : 0,
      na = a ? Math.min(nb, a.length) : 0,
      x = new Array(na),
      c = new Array(nb),
      i;

  for (i = 0; i < na; ++i) x[i] = Object(_value_js__WEBPACK_IMPORTED_MODULE_0__["default"])(a[i], b[i]);
  for (; i < nb; ++i) c[i] = b[i];

  return function(t) {
    for (i = 0; i < na; ++i) c[i] = x[i](t);
    return c;
  };
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basis.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basis.js ***!
  \******************************************************************************/
/*! exports provided: basis, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "basis", function() { return basis; });
function basis(t1, v0, v1, v2, v3) {
  var t2 = t1 * t1, t3 = t2 * t1;
  return ((1 - 3 * t1 + 3 * t2 - t3) * v0
      + (4 - 6 * t2 + 3 * t3) * v1
      + (1 + 3 * t1 + 3 * t2 - 3 * t3) * v2
      + t3 * v3) / 6;
}

/* harmony default export */ __webpack_exports__["default"] = (function(values) {
  var n = values.length - 1;
  return function(t) {
    var i = t <= 0 ? (t = 0) : t >= 1 ? (t = 1, n - 1) : Math.floor(t * n),
        v1 = values[i],
        v2 = values[i + 1],
        v0 = i > 0 ? values[i - 1] : 2 * v1 - v2,
        v3 = i < n - 1 ? values[i + 2] : 2 * v2 - v1;
    return basis((t - i / n) * n, v0, v1, v2, v3);
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basisClosed.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basisClosed.js ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _basis_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./basis.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basis.js");


/* harmony default export */ __webpack_exports__["default"] = (function(values) {
  var n = values.length;
  return function(t) {
    var i = Math.floor(((t %= 1) < 0 ? ++t : t) * n),
        v0 = values[(i + n - 1) % n],
        v1 = values[i % n],
        v2 = values[(i + 1) % n],
        v3 = values[(i + 2) % n];
    return Object(_basis_js__WEBPACK_IMPORTED_MODULE_0__["basis"])((t - i / n) * n, v0, v1, v2, v3);
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/color.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/color.js ***!
  \******************************************************************************/
/*! exports provided: hue, gamma, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "hue", function() { return hue; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "gamma", function() { return gamma; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return nogamma; });
/* harmony import */ var _constant_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./constant.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/constant.js");


function linear(a, d) {
  return function(t) {
    return a + t * d;
  };
}

function exponential(a, b, y) {
  return a = Math.pow(a, y), b = Math.pow(b, y) - a, y = 1 / y, function(t) {
    return Math.pow(a + t * b, y);
  };
}

function hue(a, b) {
  var d = b - a;
  return d ? linear(a, d > 180 || d < -180 ? d - 360 * Math.round(d / 360) : d) : Object(_constant_js__WEBPACK_IMPORTED_MODULE_0__["default"])(isNaN(a) ? b : a);
}

function gamma(y) {
  return (y = +y) === 1 ? nogamma : function(a, b) {
    return b - a ? exponential(a, b, y) : Object(_constant_js__WEBPACK_IMPORTED_MODULE_0__["default"])(isNaN(a) ? b : a);
  };
}

function nogamma(a, b) {
  var d = b - a;
  return d ? linear(a, d) : Object(_constant_js__WEBPACK_IMPORTED_MODULE_0__["default"])(isNaN(a) ? b : a);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/constant.js":
/*!*********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/constant.js ***!
  \*********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (x => () => x);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/cubehelix.js":
/*!**********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/cubehelix.js ***!
  \**********************************************************************************/
/*! exports provided: default, cubehelixLong */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cubehelixLong", function() { return cubehelixLong; });
/* harmony import */ var d3_color__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-color */ "./node_modules/d3-color/index.js");
/* harmony import */ var _color_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./color.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/color.js");



function cubehelix(hue) {
  return (function cubehelixGamma(y) {
    y = +y;

    function cubehelix(start, end) {
      var h = hue((start = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["cubehelix"])(start)).h, (end = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["cubehelix"])(end)).h),
          s = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.s, end.s),
          l = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.l, end.l),
          opacity = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.opacity, end.opacity);
      return function(t) {
        start.h = h(t);
        start.s = s(t);
        start.l = l(Math.pow(t, y));
        start.opacity = opacity(t);
        return start + "";
      };
    }

    cubehelix.gamma = cubehelixGamma;

    return cubehelix;
  })(1);
}

/* harmony default export */ __webpack_exports__["default"] = (cubehelix(_color_js__WEBPACK_IMPORTED_MODULE_1__["hue"]));
var cubehelixLong = cubehelix(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"]);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/date.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/date.js ***!
  \*****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  var d = new Date;
  return a = +a, b = +b, function(t) {
    return d.setTime(a * (1 - t) + b * t), d;
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/discrete.js":
/*!*********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/discrete.js ***!
  \*********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(range) {
  var n = range.length;
  return function(t) {
    return range[Math.max(0, Math.min(n - 1, Math.floor(t * n)))];
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hcl.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hcl.js ***!
  \****************************************************************************/
/*! exports provided: default, hclLong */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "hclLong", function() { return hclLong; });
/* harmony import */ var d3_color__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-color */ "./node_modules/d3-color/index.js");
/* harmony import */ var _color_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./color.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/color.js");



function hcl(hue) {
  return function(start, end) {
    var h = hue((start = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["hcl"])(start)).h, (end = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["hcl"])(end)).h),
        c = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.c, end.c),
        l = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.l, end.l),
        opacity = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.opacity, end.opacity);
    return function(t) {
      start.h = h(t);
      start.c = c(t);
      start.l = l(t);
      start.opacity = opacity(t);
      return start + "";
    };
  }
}

/* harmony default export */ __webpack_exports__["default"] = (hcl(_color_js__WEBPACK_IMPORTED_MODULE_1__["hue"]));
var hclLong = hcl(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"]);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hsl.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hsl.js ***!
  \****************************************************************************/
/*! exports provided: default, hslLong */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "hslLong", function() { return hslLong; });
/* harmony import */ var d3_color__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-color */ "./node_modules/d3-color/index.js");
/* harmony import */ var _color_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./color.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/color.js");



function hsl(hue) {
  return function(start, end) {
    var h = hue((start = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["hsl"])(start)).h, (end = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["hsl"])(end)).h),
        s = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.s, end.s),
        l = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.l, end.l),
        opacity = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.opacity, end.opacity);
    return function(t) {
      start.h = h(t);
      start.s = s(t);
      start.l = l(t);
      start.opacity = opacity(t);
      return start + "";
    };
  }
}

/* harmony default export */ __webpack_exports__["default"] = (hsl(_color_js__WEBPACK_IMPORTED_MODULE_1__["hue"]));
var hslLong = hsl(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"]);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hue.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hue.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _color_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./color.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/color.js");


/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  var i = Object(_color_js__WEBPACK_IMPORTED_MODULE_0__["hue"])(+a, +b);
  return function(t) {
    var x = i(t);
    return x - 360 * Math.floor(x / 360);
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/index.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/index.js ***!
  \******************************************************************************/
/*! exports provided: interpolate, interpolateArray, interpolateBasis, interpolateBasisClosed, interpolateDate, interpolateDiscrete, interpolateHue, interpolateNumber, interpolateNumberArray, interpolateObject, interpolateRound, interpolateString, interpolateTransformCss, interpolateTransformSvg, interpolateZoom, interpolateRgb, interpolateRgbBasis, interpolateRgbBasisClosed, interpolateHsl, interpolateHslLong, interpolateLab, interpolateHcl, interpolateHclLong, interpolateCubehelix, interpolateCubehelixLong, piecewise, quantize */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _value_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./value.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/value.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolate", function() { return _value_js__WEBPACK_IMPORTED_MODULE_0__["default"]; });

/* harmony import */ var _array_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./array.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/array.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateArray", function() { return _array_js__WEBPACK_IMPORTED_MODULE_1__["default"]; });

/* harmony import */ var _basis_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./basis.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basis.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateBasis", function() { return _basis_js__WEBPACK_IMPORTED_MODULE_2__["default"]; });

/* harmony import */ var _basisClosed_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./basisClosed.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basisClosed.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateBasisClosed", function() { return _basisClosed_js__WEBPACK_IMPORTED_MODULE_3__["default"]; });

/* harmony import */ var _date_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./date.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/date.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateDate", function() { return _date_js__WEBPACK_IMPORTED_MODULE_4__["default"]; });

/* harmony import */ var _discrete_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./discrete.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/discrete.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateDiscrete", function() { return _discrete_js__WEBPACK_IMPORTED_MODULE_5__["default"]; });

/* harmony import */ var _hue_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./hue.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hue.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateHue", function() { return _hue_js__WEBPACK_IMPORTED_MODULE_6__["default"]; });

/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./number.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/number.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateNumber", function() { return _number_js__WEBPACK_IMPORTED_MODULE_7__["default"]; });

/* harmony import */ var _numberArray_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./numberArray.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/numberArray.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateNumberArray", function() { return _numberArray_js__WEBPACK_IMPORTED_MODULE_8__["default"]; });

/* harmony import */ var _object_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./object.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/object.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateObject", function() { return _object_js__WEBPACK_IMPORTED_MODULE_9__["default"]; });

/* harmony import */ var _round_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./round.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/round.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateRound", function() { return _round_js__WEBPACK_IMPORTED_MODULE_10__["default"]; });

/* harmony import */ var _string_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./string.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/string.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateString", function() { return _string_js__WEBPACK_IMPORTED_MODULE_11__["default"]; });

/* harmony import */ var _transform_index_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./transform/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/index.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateTransformCss", function() { return _transform_index_js__WEBPACK_IMPORTED_MODULE_12__["interpolateTransformCss"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateTransformSvg", function() { return _transform_index_js__WEBPACK_IMPORTED_MODULE_12__["interpolateTransformSvg"]; });

/* harmony import */ var _zoom_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./zoom.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/zoom.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateZoom", function() { return _zoom_js__WEBPACK_IMPORTED_MODULE_13__["default"]; });

/* harmony import */ var _rgb_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./rgb.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/rgb.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateRgb", function() { return _rgb_js__WEBPACK_IMPORTED_MODULE_14__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateRgbBasis", function() { return _rgb_js__WEBPACK_IMPORTED_MODULE_14__["rgbBasis"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateRgbBasisClosed", function() { return _rgb_js__WEBPACK_IMPORTED_MODULE_14__["rgbBasisClosed"]; });

/* harmony import */ var _hsl_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./hsl.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hsl.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateHsl", function() { return _hsl_js__WEBPACK_IMPORTED_MODULE_15__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateHslLong", function() { return _hsl_js__WEBPACK_IMPORTED_MODULE_15__["hslLong"]; });

/* harmony import */ var _lab_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./lab.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/lab.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateLab", function() { return _lab_js__WEBPACK_IMPORTED_MODULE_16__["default"]; });

/* harmony import */ var _hcl_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./hcl.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/hcl.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateHcl", function() { return _hcl_js__WEBPACK_IMPORTED_MODULE_17__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateHclLong", function() { return _hcl_js__WEBPACK_IMPORTED_MODULE_17__["hclLong"]; });

/* harmony import */ var _cubehelix_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./cubehelix.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/cubehelix.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateCubehelix", function() { return _cubehelix_js__WEBPACK_IMPORTED_MODULE_18__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interpolateCubehelixLong", function() { return _cubehelix_js__WEBPACK_IMPORTED_MODULE_18__["cubehelixLong"]; });

/* harmony import */ var _piecewise_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./piecewise.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/piecewise.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "piecewise", function() { return _piecewise_js__WEBPACK_IMPORTED_MODULE_19__["default"]; });

/* harmony import */ var _quantize_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./quantize.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/quantize.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "quantize", function() { return _quantize_js__WEBPACK_IMPORTED_MODULE_20__["default"]; });
























/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/lab.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/lab.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return lab; });
/* harmony import */ var d3_color__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-color */ "./node_modules/d3-color/index.js");
/* harmony import */ var _color_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./color.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/color.js");



function lab(start, end) {
  var l = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])((start = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["lab"])(start)).l, (end = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["lab"])(end)).l),
      a = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.a, end.a),
      b = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.b, end.b),
      opacity = Object(_color_js__WEBPACK_IMPORTED_MODULE_1__["default"])(start.opacity, end.opacity);
  return function(t) {
    start.l = l(t);
    start.a = a(t);
    start.b = b(t);
    start.opacity = opacity(t);
    return start + "";
  };
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/number.js":
/*!*******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/number.js ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  return a = +a, b = +b, function(t) {
    return a * (1 - t) + b * t;
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/numberArray.js":
/*!************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/numberArray.js ***!
  \************************************************************************************/
/*! exports provided: default, isNumberArray */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isNumberArray", function() { return isNumberArray; });
/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  if (!b) b = [];
  var n = a ? Math.min(b.length, a.length) : 0,
      c = b.slice(),
      i;
  return function(t) {
    for (i = 0; i < n; ++i) c[i] = a[i] * (1 - t) + b[i] * t;
    return c;
  };
});

function isNumberArray(x) {
  return ArrayBuffer.isView(x) && !(x instanceof DataView);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/object.js":
/*!*******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/object.js ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _value_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./value.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/value.js");


/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  var i = {},
      c = {},
      k;

  if (a === null || typeof a !== "object") a = {};
  if (b === null || typeof b !== "object") b = {};

  for (k in b) {
    if (k in a) {
      i[k] = Object(_value_js__WEBPACK_IMPORTED_MODULE_0__["default"])(a[k], b[k]);
    } else {
      c[k] = b[k];
    }
  }

  return function(t) {
    for (k in i) c[k] = i[k](t);
    return c;
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/piecewise.js":
/*!**********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/piecewise.js ***!
  \**********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return piecewise; });
/* harmony import */ var _value_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./value.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/value.js");


function piecewise(interpolate, values) {
  if (values === undefined) values = interpolate, interpolate = _value_js__WEBPACK_IMPORTED_MODULE_0__["default"];
  var i = 0, n = values.length - 1, v = values[0], I = new Array(n < 0 ? 0 : n);
  while (i < n) I[i] = interpolate(v, v = values[++i]);
  return function(t) {
    var i = Math.max(0, Math.min(n - 1, Math.floor(t *= n)));
    return I[i](t - i);
  };
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/quantize.js":
/*!*********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/quantize.js ***!
  \*********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(interpolator, n) {
  var samples = new Array(n);
  for (var i = 0; i < n; ++i) samples[i] = interpolator(i / (n - 1));
  return samples;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/rgb.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/rgb.js ***!
  \****************************************************************************/
/*! exports provided: default, rgbBasis, rgbBasisClosed */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rgbBasis", function() { return rgbBasis; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "rgbBasisClosed", function() { return rgbBasisClosed; });
/* harmony import */ var d3_color__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-color */ "./node_modules/d3-color/index.js");
/* harmony import */ var _basis_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./basis.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basis.js");
/* harmony import */ var _basisClosed_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./basisClosed.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/basisClosed.js");
/* harmony import */ var _color_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./color.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/color.js");





/* harmony default export */ __webpack_exports__["default"] = ((function rgbGamma(y) {
  var color = Object(_color_js__WEBPACK_IMPORTED_MODULE_3__["gamma"])(y);

  function rgb(start, end) {
    var r = color((start = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["rgb"])(start)).r, (end = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["rgb"])(end)).r),
        g = color(start.g, end.g),
        b = color(start.b, end.b),
        opacity = Object(_color_js__WEBPACK_IMPORTED_MODULE_3__["default"])(start.opacity, end.opacity);
    return function(t) {
      start.r = r(t);
      start.g = g(t);
      start.b = b(t);
      start.opacity = opacity(t);
      return start + "";
    };
  }

  rgb.gamma = rgbGamma;

  return rgb;
})(1));

function rgbSpline(spline) {
  return function(colors) {
    var n = colors.length,
        r = new Array(n),
        g = new Array(n),
        b = new Array(n),
        i, color;
    for (i = 0; i < n; ++i) {
      color = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["rgb"])(colors[i]);
      r[i] = color.r || 0;
      g[i] = color.g || 0;
      b[i] = color.b || 0;
    }
    r = spline(r);
    g = spline(g);
    b = spline(b);
    color.opacity = 1;
    return function(t) {
      color.r = r(t);
      color.g = g(t);
      color.b = b(t);
      return color + "";
    };
  };
}

var rgbBasis = rgbSpline(_basis_js__WEBPACK_IMPORTED_MODULE_1__["default"]);
var rgbBasisClosed = rgbSpline(_basisClosed_js__WEBPACK_IMPORTED_MODULE_2__["default"]);


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/round.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/round.js ***!
  \******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  return a = +a, b = +b, function(t) {
    return Math.round(a * (1 - t) + b * t);
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/string.js":
/*!*******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/string.js ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./number.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/number.js");


var reA = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,
    reB = new RegExp(reA.source, "g");

function zero(b) {
  return function() {
    return b;
  };
}

function one(b) {
  return function(t) {
    return b(t) + "";
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  var bi = reA.lastIndex = reB.lastIndex = 0, // scan index for next number in b
      am, // current match in a
      bm, // current match in b
      bs, // string preceding current number in b, if any
      i = -1, // index in s
      s = [], // string constants and placeholders
      q = []; // number interpolators

  // Coerce inputs to strings.
  a = a + "", b = b + "";

  // Interpolate pairs of numbers in a & b.
  while ((am = reA.exec(a))
      && (bm = reB.exec(b))) {
    if ((bs = bm.index) > bi) { // a string precedes the next number in b
      bs = b.slice(bi, bs);
      if (s[i]) s[i] += bs; // coalesce with previous string
      else s[++i] = bs;
    }
    if ((am = am[0]) === (bm = bm[0])) { // numbers in a & b match
      if (s[i]) s[i] += bm; // coalesce with previous string
      else s[++i] = bm;
    } else { // interpolate non-matching numbers
      s[++i] = null;
      q.push({i: i, x: Object(_number_js__WEBPACK_IMPORTED_MODULE_0__["default"])(am, bm)});
    }
    bi = reB.lastIndex;
  }

  // Add remains of b.
  if (bi < b.length) {
    bs = b.slice(bi);
    if (s[i]) s[i] += bs; // coalesce with previous string
    else s[++i] = bs;
  }

  // Special optimization for only a single match.
  // Otherwise, interpolate each of the numbers and rejoin the string.
  return s.length < 2 ? (q[0]
      ? one(q[0].x)
      : zero(b))
      : (b = q.length, function(t) {
          for (var i = 0, o; i < b; ++i) s[(o = q[i]).i] = o.x(t);
          return s.join("");
        });
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/decompose.js":
/*!********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/decompose.js ***!
  \********************************************************************************************/
/*! exports provided: identity, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "identity", function() { return identity; });
var degrees = 180 / Math.PI;

var identity = {
  translateX: 0,
  translateY: 0,
  rotate: 0,
  skewX: 0,
  scaleX: 1,
  scaleY: 1
};

/* harmony default export */ __webpack_exports__["default"] = (function(a, b, c, d, e, f) {
  var scaleX, scaleY, skewX;
  if (scaleX = Math.sqrt(a * a + b * b)) a /= scaleX, b /= scaleX;
  if (skewX = a * c + b * d) c -= a * skewX, d -= b * skewX;
  if (scaleY = Math.sqrt(c * c + d * d)) c /= scaleY, d /= scaleY, skewX /= scaleY;
  if (a * d < b * c) a = -a, b = -b, skewX = -skewX, scaleX = -scaleX;
  return {
    translateX: e,
    translateY: f,
    rotate: Math.atan2(b, a) * degrees,
    skewX: Math.atan(skewX) * degrees,
    scaleX: scaleX,
    scaleY: scaleY
  };
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/index.js":
/*!****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/index.js ***!
  \****************************************************************************************/
/*! exports provided: interpolateTransformCss, interpolateTransformSvg */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "interpolateTransformCss", function() { return interpolateTransformCss; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "interpolateTransformSvg", function() { return interpolateTransformSvg; });
/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../number.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/number.js");
/* harmony import */ var _parse_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./parse.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/parse.js");



function interpolateTransform(parse, pxComma, pxParen, degParen) {

  function pop(s) {
    return s.length ? s.pop() + " " : "";
  }

  function translate(xa, ya, xb, yb, s, q) {
    if (xa !== xb || ya !== yb) {
      var i = s.push("translate(", null, pxComma, null, pxParen);
      q.push({i: i - 4, x: Object(_number_js__WEBPACK_IMPORTED_MODULE_0__["default"])(xa, xb)}, {i: i - 2, x: Object(_number_js__WEBPACK_IMPORTED_MODULE_0__["default"])(ya, yb)});
    } else if (xb || yb) {
      s.push("translate(" + xb + pxComma + yb + pxParen);
    }
  }

  function rotate(a, b, s, q) {
    if (a !== b) {
      if (a - b > 180) b += 360; else if (b - a > 180) a += 360; // shortest path
      q.push({i: s.push(pop(s) + "rotate(", null, degParen) - 2, x: Object(_number_js__WEBPACK_IMPORTED_MODULE_0__["default"])(a, b)});
    } else if (b) {
      s.push(pop(s) + "rotate(" + b + degParen);
    }
  }

  function skewX(a, b, s, q) {
    if (a !== b) {
      q.push({i: s.push(pop(s) + "skewX(", null, degParen) - 2, x: Object(_number_js__WEBPACK_IMPORTED_MODULE_0__["default"])(a, b)});
    } else if (b) {
      s.push(pop(s) + "skewX(" + b + degParen);
    }
  }

  function scale(xa, ya, xb, yb, s, q) {
    if (xa !== xb || ya !== yb) {
      var i = s.push(pop(s) + "scale(", null, ",", null, ")");
      q.push({i: i - 4, x: Object(_number_js__WEBPACK_IMPORTED_MODULE_0__["default"])(xa, xb)}, {i: i - 2, x: Object(_number_js__WEBPACK_IMPORTED_MODULE_0__["default"])(ya, yb)});
    } else if (xb !== 1 || yb !== 1) {
      s.push(pop(s) + "scale(" + xb + "," + yb + ")");
    }
  }

  return function(a, b) {
    var s = [], // string constants and placeholders
        q = []; // number interpolators
    a = parse(a), b = parse(b);
    translate(a.translateX, a.translateY, b.translateX, b.translateY, s, q);
    rotate(a.rotate, b.rotate, s, q);
    skewX(a.skewX, b.skewX, s, q);
    scale(a.scaleX, a.scaleY, b.scaleX, b.scaleY, s, q);
    a = b = null; // gc
    return function(t) {
      var i = -1, n = q.length, o;
      while (++i < n) s[(o = q[i]).i] = o.x(t);
      return s.join("");
    };
  };
}

var interpolateTransformCss = interpolateTransform(_parse_js__WEBPACK_IMPORTED_MODULE_1__["parseCss"], "px, ", "px)", "deg)");
var interpolateTransformSvg = interpolateTransform(_parse_js__WEBPACK_IMPORTED_MODULE_1__["parseSvg"], ", ", ")", ")");


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/parse.js":
/*!****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/parse.js ***!
  \****************************************************************************************/
/*! exports provided: parseCss, parseSvg */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "parseCss", function() { return parseCss; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "parseSvg", function() { return parseSvg; });
/* harmony import */ var _decompose_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./decompose.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/transform/decompose.js");


var svgNode;

/* eslint-disable no-undef */
function parseCss(value) {
  const m = new (typeof DOMMatrix === "function" ? DOMMatrix : WebKitCSSMatrix)(value + "");
  return m.isIdentity ? _decompose_js__WEBPACK_IMPORTED_MODULE_0__["identity"] : Object(_decompose_js__WEBPACK_IMPORTED_MODULE_0__["default"])(m.a, m.b, m.c, m.d, m.e, m.f);
}

function parseSvg(value) {
  if (value == null) return _decompose_js__WEBPACK_IMPORTED_MODULE_0__["identity"];
  if (!svgNode) svgNode = document.createElementNS("http://www.w3.org/2000/svg", "g");
  svgNode.setAttribute("transform", value);
  if (!(value = svgNode.transform.baseVal.consolidate())) return _decompose_js__WEBPACK_IMPORTED_MODULE_0__["identity"];
  value = value.matrix;
  return Object(_decompose_js__WEBPACK_IMPORTED_MODULE_0__["default"])(value.a, value.b, value.c, value.d, value.e, value.f);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/value.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/value.js ***!
  \******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_color__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-color */ "./node_modules/d3-color/index.js");
/* harmony import */ var _rgb_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./rgb.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/rgb.js");
/* harmony import */ var _array_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./array.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/array.js");
/* harmony import */ var _date_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./date.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/date.js");
/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./number.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/number.js");
/* harmony import */ var _object_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./object.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/object.js");
/* harmony import */ var _string_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./string.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/string.js");
/* harmony import */ var _constant_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./constant.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/constant.js");
/* harmony import */ var _numberArray_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./numberArray.js */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/numberArray.js");










/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  var t = typeof b, c;
  return b == null || t === "boolean" ? Object(_constant_js__WEBPACK_IMPORTED_MODULE_7__["default"])(b)
      : (t === "number" ? _number_js__WEBPACK_IMPORTED_MODULE_4__["default"]
      : t === "string" ? ((c = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["color"])(b)) ? (b = c, _rgb_js__WEBPACK_IMPORTED_MODULE_1__["default"]) : _string_js__WEBPACK_IMPORTED_MODULE_6__["default"])
      : b instanceof d3_color__WEBPACK_IMPORTED_MODULE_0__["color"] ? _rgb_js__WEBPACK_IMPORTED_MODULE_1__["default"]
      : b instanceof Date ? _date_js__WEBPACK_IMPORTED_MODULE_3__["default"]
      : Object(_numberArray_js__WEBPACK_IMPORTED_MODULE_8__["isNumberArray"])(b) ? _numberArray_js__WEBPACK_IMPORTED_MODULE_8__["default"]
      : Array.isArray(b) ? _array_js__WEBPACK_IMPORTED_MODULE_2__["genericArray"]
      : typeof b.valueOf !== "function" && typeof b.toString !== "function" || isNaN(b) ? _object_js__WEBPACK_IMPORTED_MODULE_5__["default"]
      : _number_js__WEBPACK_IMPORTED_MODULE_4__["default"])(a, b);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/zoom.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/zoom.js ***!
  \*****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
var epsilon2 = 1e-12;

function cosh(x) {
  return ((x = Math.exp(x)) + 1 / x) / 2;
}

function sinh(x) {
  return ((x = Math.exp(x)) - 1 / x) / 2;
}

function tanh(x) {
  return ((x = Math.exp(2 * x)) - 1) / (x + 1);
}

/* harmony default export */ __webpack_exports__["default"] = ((function zoomRho(rho, rho2, rho4) {

  // p0 = [ux0, uy0, w0]
  // p1 = [ux1, uy1, w1]
  function zoom(p0, p1) {
    var ux0 = p0[0], uy0 = p0[1], w0 = p0[2],
        ux1 = p1[0], uy1 = p1[1], w1 = p1[2],
        dx = ux1 - ux0,
        dy = uy1 - uy0,
        d2 = dx * dx + dy * dy,
        i,
        S;

    // Special case for u0 ≅ u1.
    if (d2 < epsilon2) {
      S = Math.log(w1 / w0) / rho;
      i = function(t) {
        return [
          ux0 + t * dx,
          uy0 + t * dy,
          w0 * Math.exp(rho * t * S)
        ];
      }
    }

    // General case.
    else {
      var d1 = Math.sqrt(d2),
          b0 = (w1 * w1 - w0 * w0 + rho4 * d2) / (2 * w0 * rho2 * d1),
          b1 = (w1 * w1 - w0 * w0 - rho4 * d2) / (2 * w1 * rho2 * d1),
          r0 = Math.log(Math.sqrt(b0 * b0 + 1) - b0),
          r1 = Math.log(Math.sqrt(b1 * b1 + 1) - b1);
      S = (r1 - r0) / rho;
      i = function(t) {
        var s = t * S,
            coshr0 = cosh(r0),
            u = w0 / (rho2 * d1) * (coshr0 * tanh(rho * s + r0) - sinh(r0));
        return [
          ux0 + u * dx,
          uy0 + u * dy,
          w0 * coshr0 / cosh(rho * s + r0)
        ];
      }
    }

    i.duration = S * 1000 * rho / Math.SQRT2;

    return i;
  }

  zoom.rho = function(_) {
    var _1 = Math.max(1e-3, +_), _2 = _1 * _1, _4 = _2 * _2;
    return zoomRho(_1, _2, _4);
  };

  return zoom;
})(Math.SQRT2, 2, 4));


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/band.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/band.js ***!
  \***********************************************************************/
/*! exports provided: default, point */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return band; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "point", function() { return point; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");
/* harmony import */ var _ordinal_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./ordinal.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/ordinal.js");




function band() {
  var scale = Object(_ordinal_js__WEBPACK_IMPORTED_MODULE_2__["default"])().unknown(undefined),
      domain = scale.domain,
      ordinalRange = scale.range,
      r0 = 0,
      r1 = 1,
      step,
      bandwidth,
      round = false,
      paddingInner = 0,
      paddingOuter = 0,
      align = 0.5;

  delete scale.unknown;

  function rescale() {
    var n = domain().length,
        reverse = r1 < r0,
        start = reverse ? r1 : r0,
        stop = reverse ? r0 : r1;
    step = (stop - start) / Math.max(1, n - paddingInner + paddingOuter * 2);
    if (round) step = Math.floor(step);
    start += (stop - start - step * (n - paddingInner)) * align;
    bandwidth = step * (1 - paddingInner);
    if (round) start = Math.round(start), bandwidth = Math.round(bandwidth);
    var values = Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["range"])(n).map(function(i) { return start + step * i; });
    return ordinalRange(reverse ? values.reverse() : values);
  }

  scale.domain = function(_) {
    return arguments.length ? (domain(_), rescale()) : domain();
  };

  scale.range = function(_) {
    return arguments.length ? ([r0, r1] = _, r0 = +r0, r1 = +r1, rescale()) : [r0, r1];
  };

  scale.rangeRound = function(_) {
    return [r0, r1] = _, r0 = +r0, r1 = +r1, round = true, rescale();
  };

  scale.bandwidth = function() {
    return bandwidth;
  };

  scale.step = function() {
    return step;
  };

  scale.round = function(_) {
    return arguments.length ? (round = !!_, rescale()) : round;
  };

  scale.padding = function(_) {
    return arguments.length ? (paddingInner = Math.min(1, paddingOuter = +_), rescale()) : paddingInner;
  };

  scale.paddingInner = function(_) {
    return arguments.length ? (paddingInner = Math.min(1, _), rescale()) : paddingInner;
  };

  scale.paddingOuter = function(_) {
    return arguments.length ? (paddingOuter = +_, rescale()) : paddingOuter;
  };

  scale.align = function(_) {
    return arguments.length ? (align = Math.max(0, Math.min(1, _)), rescale()) : align;
  };

  scale.copy = function() {
    return band(domain(), [r0, r1])
        .round(round)
        .paddingInner(paddingInner)
        .paddingOuter(paddingOuter)
        .align(align);
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_1__["initRange"].apply(rescale(), arguments);
}

function pointish(scale) {
  var copy = scale.copy;

  scale.padding = scale.paddingOuter;
  delete scale.paddingInner;
  delete scale.paddingOuter;

  scale.copy = function() {
    return pointish(copy());
  };

  return scale;
}

function point() {
  return pointish(band.apply(null, arguments).paddingInner(1));
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/constant.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/constant.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return constants; });
function constants(x) {
  return function() {
    return x;
  };
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js ***!
  \*****************************************************************************/
/*! exports provided: identity, copy, transformer, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "identity", function() { return identity; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "copy", function() { return copy; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "transformer", function() { return transformer; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return continuous; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var d3_interpolate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-interpolate */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/index.js");
/* harmony import */ var _constant_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constant.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/constant.js");
/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./number.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/number.js");





var unit = [0, 1];

function identity(x) {
  return x;
}

function normalize(a, b) {
  return (b -= (a = +a))
      ? function(x) { return (x - a) / b; }
      : Object(_constant_js__WEBPACK_IMPORTED_MODULE_2__["default"])(isNaN(b) ? NaN : 0.5);
}

function clamper(a, b) {
  var t;
  if (a > b) t = a, a = b, b = t;
  return function(x) { return Math.max(a, Math.min(b, x)); };
}

// normalize(a, b)(x) takes a domain value x in [a,b] and returns the corresponding parameter t in [0,1].
// interpolate(a, b)(t) takes a parameter t in [0,1] and returns the corresponding range value x in [a,b].
function bimap(domain, range, interpolate) {
  var d0 = domain[0], d1 = domain[1], r0 = range[0], r1 = range[1];
  if (d1 < d0) d0 = normalize(d1, d0), r0 = interpolate(r1, r0);
  else d0 = normalize(d0, d1), r0 = interpolate(r0, r1);
  return function(x) { return r0(d0(x)); };
}

function polymap(domain, range, interpolate) {
  var j = Math.min(domain.length, range.length) - 1,
      d = new Array(j),
      r = new Array(j),
      i = -1;

  // Reverse descending domains.
  if (domain[j] < domain[0]) {
    domain = domain.slice().reverse();
    range = range.slice().reverse();
  }

  while (++i < j) {
    d[i] = normalize(domain[i], domain[i + 1]);
    r[i] = interpolate(range[i], range[i + 1]);
  }

  return function(x) {
    var i = Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["bisect"])(domain, x, 1, j) - 1;
    return r[i](d[i](x));
  };
}

function copy(source, target) {
  return target
      .domain(source.domain())
      .range(source.range())
      .interpolate(source.interpolate())
      .clamp(source.clamp())
      .unknown(source.unknown());
}

function transformer() {
  var domain = unit,
      range = unit,
      interpolate = d3_interpolate__WEBPACK_IMPORTED_MODULE_1__["interpolate"],
      transform,
      untransform,
      unknown,
      clamp = identity,
      piecewise,
      output,
      input;

  function rescale() {
    var n = Math.min(domain.length, range.length);
    if (clamp !== identity) clamp = clamper(domain[0], domain[n - 1]);
    piecewise = n > 2 ? polymap : bimap;
    output = input = null;
    return scale;
  }

  function scale(x) {
    return x == null || isNaN(x = +x) ? unknown : (output || (output = piecewise(domain.map(transform), range, interpolate)))(transform(clamp(x)));
  }

  scale.invert = function(y) {
    return clamp(untransform((input || (input = piecewise(range, domain.map(transform), d3_interpolate__WEBPACK_IMPORTED_MODULE_1__["interpolateNumber"])))(y)));
  };

  scale.domain = function(_) {
    return arguments.length ? (domain = Array.from(_, _number_js__WEBPACK_IMPORTED_MODULE_3__["default"]), rescale()) : domain.slice();
  };

  scale.range = function(_) {
    return arguments.length ? (range = Array.from(_), rescale()) : range.slice();
  };

  scale.rangeRound = function(_) {
    return range = Array.from(_), interpolate = d3_interpolate__WEBPACK_IMPORTED_MODULE_1__["interpolateRound"], rescale();
  };

  scale.clamp = function(_) {
    return arguments.length ? (clamp = _ ? true : identity, rescale()) : clamp !== identity;
  };

  scale.interpolate = function(_) {
    return arguments.length ? (interpolate = _, rescale()) : interpolate;
  };

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : unknown;
  };

  return function(t, u) {
    transform = t, untransform = u;
    return rescale();
  };
}

function continuous() {
  return transformer()(identity, identity);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/diverging.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/diverging.js ***!
  \****************************************************************************/
/*! exports provided: default, divergingLog, divergingSymlog, divergingPow, divergingSqrt */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return diverging; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "divergingLog", function() { return divergingLog; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "divergingSymlog", function() { return divergingSymlog; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "divergingPow", function() { return divergingPow; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "divergingSqrt", function() { return divergingSqrt; });
/* harmony import */ var d3_interpolate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-interpolate */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/index.js");
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");
/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js");
/* harmony import */ var _log_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./log.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/log.js");
/* harmony import */ var _sequential_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./sequential.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/sequential.js");
/* harmony import */ var _symlog_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./symlog.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/symlog.js");
/* harmony import */ var _pow_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./pow.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/pow.js");









function transformer() {
  var x0 = 0,
      x1 = 0.5,
      x2 = 1,
      s = 1,
      t0,
      t1,
      t2,
      k10,
      k21,
      interpolator = _continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"],
      transform,
      clamp = false,
      unknown;

  function scale(x) {
    return isNaN(x = +x) ? unknown : (x = 0.5 + ((x = +transform(x)) - t1) * (s * x < s * t1 ? k10 : k21), interpolator(clamp ? Math.max(0, Math.min(1, x)) : x));
  }

  scale.domain = function(_) {
    return arguments.length ? ([x0, x1, x2] = _, t0 = transform(x0 = +x0), t1 = transform(x1 = +x1), t2 = transform(x2 = +x2), k10 = t0 === t1 ? 0 : 0.5 / (t1 - t0), k21 = t1 === t2 ? 0 : 0.5 / (t2 - t1), s = t1 < t0 ? -1 : 1, scale) : [x0, x1, x2];
  };

  scale.clamp = function(_) {
    return arguments.length ? (clamp = !!_, scale) : clamp;
  };

  scale.interpolator = function(_) {
    return arguments.length ? (interpolator = _, scale) : interpolator;
  };

  function range(interpolate) {
    return function(_) {
      var r0, r1, r2;
      return arguments.length ? ([r0, r1, r2] = _, interpolator = Object(d3_interpolate__WEBPACK_IMPORTED_MODULE_0__["piecewise"])(interpolate, [r0, r1, r2]), scale) : [interpolator(0), interpolator(0.5), interpolator(1)];
    };
  }

  scale.range = range(d3_interpolate__WEBPACK_IMPORTED_MODULE_0__["interpolate"]);

  scale.rangeRound = range(d3_interpolate__WEBPACK_IMPORTED_MODULE_0__["interpolateRound"]);

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : unknown;
  };

  return function(t) {
    transform = t, t0 = t(x0), t1 = t(x1), t2 = t(x2), k10 = t0 === t1 ? 0 : 0.5 / (t1 - t0), k21 = t1 === t2 ? 0 : 0.5 / (t2 - t1), s = t1 < t0 ? -1 : 1;
    return scale;
  };
}

function diverging() {
  var scale = Object(_linear_js__WEBPACK_IMPORTED_MODULE_3__["linearish"])(transformer()(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"]));

  scale.copy = function() {
    return Object(_sequential_js__WEBPACK_IMPORTED_MODULE_5__["copy"])(scale, diverging());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}

function divergingLog() {
  var scale = Object(_log_js__WEBPACK_IMPORTED_MODULE_4__["loggish"])(transformer()).domain([0.1, 1, 10]);

  scale.copy = function() {
    return Object(_sequential_js__WEBPACK_IMPORTED_MODULE_5__["copy"])(scale, divergingLog()).base(scale.base());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}

function divergingSymlog() {
  var scale = Object(_symlog_js__WEBPACK_IMPORTED_MODULE_6__["symlogish"])(transformer());

  scale.copy = function() {
    return Object(_sequential_js__WEBPACK_IMPORTED_MODULE_5__["copy"])(scale, divergingSymlog()).constant(scale.constant());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}

function divergingPow() {
  var scale = Object(_pow_js__WEBPACK_IMPORTED_MODULE_7__["powish"])(transformer());

  scale.copy = function() {
    return Object(_sequential_js__WEBPACK_IMPORTED_MODULE_5__["copy"])(scale, divergingPow()).exponent(scale.exponent());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}

function divergingSqrt() {
  return divergingPow.apply(null, arguments).exponent(0.5);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/identity.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/identity.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return identity; });
/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js");
/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./number.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/number.js");



function identity(domain) {
  var unknown;

  function scale(x) {
    return x == null || isNaN(x = +x) ? unknown : x;
  }

  scale.invert = scale;

  scale.domain = scale.range = function(_) {
    return arguments.length ? (domain = Array.from(_, _number_js__WEBPACK_IMPORTED_MODULE_1__["default"]), scale) : domain.slice();
  };

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : unknown;
  };

  scale.copy = function() {
    return identity(domain).unknown(unknown);
  };

  domain = arguments.length ? Array.from(domain, _number_js__WEBPACK_IMPORTED_MODULE_1__["default"]) : [0, 1];

  return Object(_linear_js__WEBPACK_IMPORTED_MODULE_0__["linearish"])(scale);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/index.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/index.js ***!
  \************************************************************************/
/*! exports provided: scaleBand, scalePoint, scaleIdentity, scaleLinear, scaleLog, scaleSymlog, scaleOrdinal, scaleImplicit, scalePow, scaleSqrt, scaleRadial, scaleQuantile, scaleQuantize, scaleThreshold, scaleTime, scaleUtc, scaleSequential, scaleSequentialLog, scaleSequentialPow, scaleSequentialSqrt, scaleSequentialSymlog, scaleSequentialQuantile, scaleDiverging, scaleDivergingLog, scaleDivergingPow, scaleDivergingSqrt, scaleDivergingSymlog, tickFormat */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _band_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./band.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/band.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleBand", function() { return _band_js__WEBPACK_IMPORTED_MODULE_0__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scalePoint", function() { return _band_js__WEBPACK_IMPORTED_MODULE_0__["point"]; });

/* harmony import */ var _identity_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./identity.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/identity.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleIdentity", function() { return _identity_js__WEBPACK_IMPORTED_MODULE_1__["default"]; });

/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleLinear", function() { return _linear_js__WEBPACK_IMPORTED_MODULE_2__["default"]; });

/* harmony import */ var _log_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./log.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/log.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleLog", function() { return _log_js__WEBPACK_IMPORTED_MODULE_3__["default"]; });

/* harmony import */ var _symlog_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./symlog.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/symlog.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleSymlog", function() { return _symlog_js__WEBPACK_IMPORTED_MODULE_4__["default"]; });

/* harmony import */ var _ordinal_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./ordinal.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/ordinal.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleOrdinal", function() { return _ordinal_js__WEBPACK_IMPORTED_MODULE_5__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleImplicit", function() { return _ordinal_js__WEBPACK_IMPORTED_MODULE_5__["implicit"]; });

/* harmony import */ var _pow_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./pow.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/pow.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scalePow", function() { return _pow_js__WEBPACK_IMPORTED_MODULE_6__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleSqrt", function() { return _pow_js__WEBPACK_IMPORTED_MODULE_6__["sqrt"]; });

/* harmony import */ var _radial_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./radial.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/radial.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleRadial", function() { return _radial_js__WEBPACK_IMPORTED_MODULE_7__["default"]; });

/* harmony import */ var _quantile_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./quantile.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/quantile.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleQuantile", function() { return _quantile_js__WEBPACK_IMPORTED_MODULE_8__["default"]; });

/* harmony import */ var _quantize_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./quantize.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/quantize.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleQuantize", function() { return _quantize_js__WEBPACK_IMPORTED_MODULE_9__["default"]; });

/* harmony import */ var _threshold_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./threshold.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/threshold.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleThreshold", function() { return _threshold_js__WEBPACK_IMPORTED_MODULE_10__["default"]; });

/* harmony import */ var _time_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./time.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/time.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleTime", function() { return _time_js__WEBPACK_IMPORTED_MODULE_11__["default"]; });

/* harmony import */ var _utcTime_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./utcTime.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/utcTime.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleUtc", function() { return _utcTime_js__WEBPACK_IMPORTED_MODULE_12__["default"]; });

/* harmony import */ var _sequential_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./sequential.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/sequential.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleSequential", function() { return _sequential_js__WEBPACK_IMPORTED_MODULE_13__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleSequentialLog", function() { return _sequential_js__WEBPACK_IMPORTED_MODULE_13__["sequentialLog"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleSequentialPow", function() { return _sequential_js__WEBPACK_IMPORTED_MODULE_13__["sequentialPow"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleSequentialSqrt", function() { return _sequential_js__WEBPACK_IMPORTED_MODULE_13__["sequentialSqrt"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleSequentialSymlog", function() { return _sequential_js__WEBPACK_IMPORTED_MODULE_13__["sequentialSymlog"]; });

/* harmony import */ var _sequentialQuantile_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./sequentialQuantile.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/sequentialQuantile.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleSequentialQuantile", function() { return _sequentialQuantile_js__WEBPACK_IMPORTED_MODULE_14__["default"]; });

/* harmony import */ var _diverging_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./diverging.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/diverging.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleDiverging", function() { return _diverging_js__WEBPACK_IMPORTED_MODULE_15__["default"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleDivergingLog", function() { return _diverging_js__WEBPACK_IMPORTED_MODULE_15__["divergingLog"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleDivergingPow", function() { return _diverging_js__WEBPACK_IMPORTED_MODULE_15__["divergingPow"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleDivergingSqrt", function() { return _diverging_js__WEBPACK_IMPORTED_MODULE_15__["divergingSqrt"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "scaleDivergingSymlog", function() { return _diverging_js__WEBPACK_IMPORTED_MODULE_15__["divergingSymlog"]; });

/* harmony import */ var _tickFormat_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./tickFormat.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/tickFormat.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "tickFormat", function() { return _tickFormat_js__WEBPACK_IMPORTED_MODULE_16__["default"]; });




































/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js ***!
  \***********************************************************************/
/*! exports provided: initRange, initInterpolator */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "initRange", function() { return initRange; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "initInterpolator", function() { return initInterpolator; });
function initRange(domain, range) {
  switch (arguments.length) {
    case 0: break;
    case 1: this.range(domain); break;
    default: this.range(range).domain(domain); break;
  }
  return this;
}

function initInterpolator(domain, interpolator) {
  switch (arguments.length) {
    case 0: break;
    case 1: {
      if (typeof domain === "function") this.interpolator(domain);
      else this.range(domain);
      break;
    }
    default: {
      this.domain(domain);
      if (typeof interpolator === "function") this.interpolator(interpolator);
      else this.range(interpolator);
      break;
    }
  }
  return this;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js ***!
  \*************************************************************************/
/*! exports provided: linearish, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "linearish", function() { return linearish; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return linear; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");
/* harmony import */ var _tickFormat_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./tickFormat.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/tickFormat.js");





function linearish(scale) {
  var domain = scale.domain;

  scale.ticks = function(count) {
    var d = domain();
    return Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["ticks"])(d[0], d[d.length - 1], count == null ? 10 : count);
  };

  scale.tickFormat = function(count, specifier) {
    var d = domain();
    return Object(_tickFormat_js__WEBPACK_IMPORTED_MODULE_3__["default"])(d[0], d[d.length - 1], count == null ? 10 : count, specifier);
  };

  scale.nice = function(count) {
    if (count == null) count = 10;

    var d = domain();
    var i0 = 0;
    var i1 = d.length - 1;
    var start = d[i0];
    var stop = d[i1];
    var prestep;
    var step;
    var maxIter = 10;

    if (stop < start) {
      step = start, start = stop, stop = step;
      step = i0, i0 = i1, i1 = step;
    }
    
    while (maxIter-- > 0) {
      step = Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["tickIncrement"])(start, stop, count);
      if (step === prestep) {
        d[i0] = start
        d[i1] = stop
        return domain(d);
      } else if (step > 0) {
        start = Math.floor(start / step) * step;
        stop = Math.ceil(stop / step) * step;
      } else if (step < 0) {
        start = Math.ceil(start * step) / step;
        stop = Math.floor(stop * step) / step;
      } else {
        break;
      }
      prestep = step;
    }

    return scale;
  };

  return scale;
}

function linear() {
  var scale = Object(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["default"])();

  scale.copy = function() {
    return Object(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["copy"])(scale, linear());
  };

  _init_js__WEBPACK_IMPORTED_MODULE_2__["initRange"].apply(scale, arguments);

  return linearish(scale);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/log.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/log.js ***!
  \**********************************************************************/
/*! exports provided: loggish, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "loggish", function() { return loggish; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return log; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var d3_format__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-format */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/index.js");
/* harmony import */ var _nice_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./nice.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/nice.js");
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");






function transformLog(x) {
  return Math.log(x);
}

function transformExp(x) {
  return Math.exp(x);
}

function transformLogn(x) {
  return -Math.log(-x);
}

function transformExpn(x) {
  return -Math.exp(-x);
}

function pow10(x) {
  return isFinite(x) ? +("1e" + x) : x < 0 ? 0 : x;
}

function powp(base) {
  return base === 10 ? pow10
      : base === Math.E ? Math.exp
      : x => Math.pow(base, x);
}

function logp(base) {
  return base === Math.E ? Math.log
      : base === 10 && Math.log10
      || base === 2 && Math.log2
      || (base = Math.log(base), x => Math.log(x) / base);
}

function reflect(f) {
  return (x, k) => -f(-x, k);
}

function loggish(transform) {
  const scale = transform(transformLog, transformExp);
  const domain = scale.domain;
  let base = 10;
  let logs;
  let pows;

  function rescale() {
    logs = logp(base), pows = powp(base);
    if (domain()[0] < 0) {
      logs = reflect(logs), pows = reflect(pows);
      transform(transformLogn, transformExpn);
    } else {
      transform(transformLog, transformExp);
    }
    return scale;
  }

  scale.base = function(_) {
    return arguments.length ? (base = +_, rescale()) : base;
  };

  scale.domain = function(_) {
    return arguments.length ? (domain(_), rescale()) : domain();
  };

  scale.ticks = count => {
    const d = domain();
    let u = d[0];
    let v = d[d.length - 1];
    const r = v < u;

    if (r) ([u, v] = [v, u]);

    let i = logs(u);
    let j = logs(v);
    let k;
    let t;
    const n = count == null ? 10 : +count;
    let z = [];

    if (!(base % 1) && j - i < n) {
      i = Math.floor(i), j = Math.ceil(j);
      if (u > 0) for (; i <= j; ++i) {
        for (k = 1; k < base; ++k) {
          t = i < 0 ? k / pows(-i) : k * pows(i);
          if (t < u) continue;
          if (t > v) break;
          z.push(t);
        }
      } else for (; i <= j; ++i) {
        for (k = base - 1; k >= 1; --k) {
          t = i > 0 ? k / pows(-i) : k * pows(i);
          if (t < u) continue;
          if (t > v) break;
          z.push(t);
        }
      }
      if (z.length * 2 < n) z = Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["ticks"])(u, v, n);
    } else {
      z = Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["ticks"])(i, j, Math.min(j - i, n)).map(pows);
    }
    return r ? z.reverse() : z;
  };

  scale.tickFormat = (count, specifier) => {
    if (count == null) count = 10;
    if (specifier == null) specifier = base === 10 ? "s" : ",";
    if (typeof specifier !== "function") {
      if (!(base % 1) && (specifier = Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["formatSpecifier"])(specifier)).precision == null) specifier.trim = true;
      specifier = Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["format"])(specifier);
    }
    if (count === Infinity) return specifier;
    const k = Math.max(1, base * count / scale.ticks().length); // TODO fast estimate?
    return d => {
      let i = d / pows(Math.round(logs(d)));
      if (i * base < base - 0.5) i *= base;
      return i <= k ? specifier(d) : "";
    };
  };

  scale.nice = () => {
    return domain(Object(_nice_js__WEBPACK_IMPORTED_MODULE_2__["default"])(domain(), {
      floor: x => pows(Math.floor(logs(x))),
      ceil: x => pows(Math.ceil(logs(x)))
    }));
  };

  return scale;
}

function log() {
  const scale = loggish(Object(_continuous_js__WEBPACK_IMPORTED_MODULE_3__["transformer"])()).domain([1, 10]);
  scale.copy = () => Object(_continuous_js__WEBPACK_IMPORTED_MODULE_3__["copy"])(scale, log()).base(scale.base());
  _init_js__WEBPACK_IMPORTED_MODULE_4__["initRange"].apply(scale, arguments);
  return scale;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/nice.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/nice.js ***!
  \***********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return nice; });
function nice(domain, interval) {
  domain = domain.slice();

  var i0 = 0,
      i1 = domain.length - 1,
      x0 = domain[i0],
      x1 = domain[i1],
      t;

  if (x1 < x0) {
    t = i0, i0 = i1, i1 = t;
    t = x0, x0 = x1, x1 = t;
  }

  domain[i0] = interval.floor(x0);
  domain[i1] = interval.ceil(x1);
  return domain;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/number.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/number.js ***!
  \*************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return number; });
function number(x) {
  return +x;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/ordinal.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/ordinal.js ***!
  \**************************************************************************/
/*! exports provided: implicit, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "implicit", function() { return implicit; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return ordinal; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");



const implicit = Symbol("implicit");

function ordinal() {
  var index = new d3_array__WEBPACK_IMPORTED_MODULE_0__["InternMap"](),
      domain = [],
      range = [],
      unknown = implicit;

  function scale(d) {
    let i = index.get(d);
    if (i === undefined) {
      if (unknown !== implicit) return unknown;
      index.set(d, i = domain.push(d) - 1);
    }
    return range[i % range.length];
  }

  scale.domain = function(_) {
    if (!arguments.length) return domain.slice();
    domain = [], index = new d3_array__WEBPACK_IMPORTED_MODULE_0__["InternMap"]();
    for (const value of _) {
      if (index.has(value)) continue;
      index.set(value, domain.push(value) - 1);
    }
    return scale;
  };

  scale.range = function(_) {
    return arguments.length ? (range = Array.from(_), scale) : range.slice();
  };

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : unknown;
  };

  scale.copy = function() {
    return ordinal(domain, range).unknown(unknown);
  };

  _init_js__WEBPACK_IMPORTED_MODULE_1__["initRange"].apply(scale, arguments);

  return scale;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/pow.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/pow.js ***!
  \**********************************************************************/
/*! exports provided: powish, default, sqrt */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "powish", function() { return powish; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return pow; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sqrt", function() { return sqrt; });
/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js");
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");




function transformPow(exponent) {
  return function(x) {
    return x < 0 ? -Math.pow(-x, exponent) : Math.pow(x, exponent);
  };
}

function transformSqrt(x) {
  return x < 0 ? -Math.sqrt(-x) : Math.sqrt(x);
}

function transformSquare(x) {
  return x < 0 ? -x * x : x * x;
}

function powish(transform) {
  var scale = transform(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"], _continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"]),
      exponent = 1;

  function rescale() {
    return exponent === 1 ? transform(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"], _continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"])
        : exponent === 0.5 ? transform(transformSqrt, transformSquare)
        : transform(transformPow(exponent), transformPow(1 / exponent));
  }

  scale.exponent = function(_) {
    return arguments.length ? (exponent = +_, rescale()) : exponent;
  };

  return Object(_linear_js__WEBPACK_IMPORTED_MODULE_0__["linearish"])(scale);
}

function pow() {
  var scale = powish(Object(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["transformer"])());

  scale.copy = function() {
    return Object(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["copy"])(scale, pow()).exponent(scale.exponent());
  };

  _init_js__WEBPACK_IMPORTED_MODULE_2__["initRange"].apply(scale, arguments);

  return scale;
}

function sqrt() {
  return pow.apply(null, arguments).exponent(0.5);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/quantile.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/quantile.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return quantile; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");



function quantile() {
  var domain = [],
      range = [],
      thresholds = [],
      unknown;

  function rescale() {
    var i = 0, n = Math.max(1, range.length);
    thresholds = new Array(n - 1);
    while (++i < n) thresholds[i - 1] = Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["quantileSorted"])(domain, i / n);
    return scale;
  }

  function scale(x) {
    return x == null || isNaN(x = +x) ? unknown : range[Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["bisect"])(thresholds, x)];
  }

  scale.invertExtent = function(y) {
    var i = range.indexOf(y);
    return i < 0 ? [NaN, NaN] : [
      i > 0 ? thresholds[i - 1] : domain[0],
      i < thresholds.length ? thresholds[i] : domain[domain.length - 1]
    ];
  };

  scale.domain = function(_) {
    if (!arguments.length) return domain.slice();
    domain = [];
    for (let d of _) if (d != null && !isNaN(d = +d)) domain.push(d);
    domain.sort(d3_array__WEBPACK_IMPORTED_MODULE_0__["ascending"]);
    return rescale();
  };

  scale.range = function(_) {
    return arguments.length ? (range = Array.from(_), rescale()) : range.slice();
  };

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : unknown;
  };

  scale.quantiles = function() {
    return thresholds.slice();
  };

  scale.copy = function() {
    return quantile()
        .domain(domain)
        .range(range)
        .unknown(unknown);
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_1__["initRange"].apply(scale, arguments);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/quantize.js":
/*!***************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/quantize.js ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return quantize; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");




function quantize() {
  var x0 = 0,
      x1 = 1,
      n = 1,
      domain = [0.5],
      range = [0, 1],
      unknown;

  function scale(x) {
    return x != null && x <= x ? range[Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["bisect"])(domain, x, 0, n)] : unknown;
  }

  function rescale() {
    var i = -1;
    domain = new Array(n);
    while (++i < n) domain[i] = ((i + 1) * x1 - (i - n) * x0) / (n + 1);
    return scale;
  }

  scale.domain = function(_) {
    return arguments.length ? ([x0, x1] = _, x0 = +x0, x1 = +x1, rescale()) : [x0, x1];
  };

  scale.range = function(_) {
    return arguments.length ? (n = (range = Array.from(_)).length - 1, rescale()) : range.slice();
  };

  scale.invertExtent = function(y) {
    var i = range.indexOf(y);
    return i < 0 ? [NaN, NaN]
        : i < 1 ? [x0, domain[0]]
        : i >= n ? [domain[n - 1], x1]
        : [domain[i - 1], domain[i]];
  };

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : scale;
  };

  scale.thresholds = function() {
    return domain.slice();
  };

  scale.copy = function() {
    return quantize()
        .domain([x0, x1])
        .range(range)
        .unknown(unknown);
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initRange"].apply(Object(_linear_js__WEBPACK_IMPORTED_MODULE_1__["linearish"])(scale), arguments);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/radial.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/radial.js ***!
  \*************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return radial; });
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");
/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js");
/* harmony import */ var _number_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./number.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/number.js");





function square(x) {
  return Math.sign(x) * x * x;
}

function unsquare(x) {
  return Math.sign(x) * Math.sqrt(Math.abs(x));
}

function radial() {
  var squared = Object(_continuous_js__WEBPACK_IMPORTED_MODULE_0__["default"])(),
      range = [0, 1],
      round = false,
      unknown;

  function scale(x) {
    var y = unsquare(squared(x));
    return isNaN(y) ? unknown : round ? Math.round(y) : y;
  }

  scale.invert = function(y) {
    return squared.invert(square(y));
  };

  scale.domain = function(_) {
    return arguments.length ? (squared.domain(_), scale) : squared.domain();
  };

  scale.range = function(_) {
    return arguments.length ? (squared.range((range = Array.from(_, _number_js__WEBPACK_IMPORTED_MODULE_3__["default"])).map(square)), scale) : range.slice();
  };

  scale.rangeRound = function(_) {
    return scale.range(_).round(true);
  };

  scale.round = function(_) {
    return arguments.length ? (round = !!_, scale) : round;
  };

  scale.clamp = function(_) {
    return arguments.length ? (squared.clamp(_), scale) : squared.clamp();
  };

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : unknown;
  };

  scale.copy = function() {
    return radial(squared.domain(), range)
        .round(round)
        .clamp(squared.clamp())
        .unknown(unknown);
  };

  _init_js__WEBPACK_IMPORTED_MODULE_1__["initRange"].apply(scale, arguments);

  return Object(_linear_js__WEBPACK_IMPORTED_MODULE_2__["linearish"])(scale);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/sequential.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/sequential.js ***!
  \*****************************************************************************/
/*! exports provided: copy, default, sequentialLog, sequentialSymlog, sequentialPow, sequentialSqrt */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "copy", function() { return copy; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return sequential; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sequentialLog", function() { return sequentialLog; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sequentialSymlog", function() { return sequentialSymlog; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sequentialPow", function() { return sequentialPow; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sequentialSqrt", function() { return sequentialSqrt; });
/* harmony import */ var d3_interpolate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-interpolate */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/index.js");
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");
/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js");
/* harmony import */ var _log_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./log.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/log.js");
/* harmony import */ var _symlog_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./symlog.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/symlog.js");
/* harmony import */ var _pow_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./pow.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/pow.js");








function transformer() {
  var x0 = 0,
      x1 = 1,
      t0,
      t1,
      k10,
      transform,
      interpolator = _continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"],
      clamp = false,
      unknown;

  function scale(x) {
    return x == null || isNaN(x = +x) ? unknown : interpolator(k10 === 0 ? 0.5 : (x = (transform(x) - t0) * k10, clamp ? Math.max(0, Math.min(1, x)) : x));
  }

  scale.domain = function(_) {
    return arguments.length ? ([x0, x1] = _, t0 = transform(x0 = +x0), t1 = transform(x1 = +x1), k10 = t0 === t1 ? 0 : 1 / (t1 - t0), scale) : [x0, x1];
  };

  scale.clamp = function(_) {
    return arguments.length ? (clamp = !!_, scale) : clamp;
  };

  scale.interpolator = function(_) {
    return arguments.length ? (interpolator = _, scale) : interpolator;
  };

  function range(interpolate) {
    return function(_) {
      var r0, r1;
      return arguments.length ? ([r0, r1] = _, interpolator = interpolate(r0, r1), scale) : [interpolator(0), interpolator(1)];
    };
  }

  scale.range = range(d3_interpolate__WEBPACK_IMPORTED_MODULE_0__["interpolate"]);

  scale.rangeRound = range(d3_interpolate__WEBPACK_IMPORTED_MODULE_0__["interpolateRound"]);

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : unknown;
  };

  return function(t) {
    transform = t, t0 = t(x0), t1 = t(x1), k10 = t0 === t1 ? 0 : 1 / (t1 - t0);
    return scale;
  };
}

function copy(source, target) {
  return target
      .domain(source.domain())
      .interpolator(source.interpolator())
      .clamp(source.clamp())
      .unknown(source.unknown());
}

function sequential() {
  var scale = Object(_linear_js__WEBPACK_IMPORTED_MODULE_3__["linearish"])(transformer()(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"]));

  scale.copy = function() {
    return copy(scale, sequential());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}

function sequentialLog() {
  var scale = Object(_log_js__WEBPACK_IMPORTED_MODULE_4__["loggish"])(transformer()).domain([1, 10]);

  scale.copy = function() {
    return copy(scale, sequentialLog()).base(scale.base());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}

function sequentialSymlog() {
  var scale = Object(_symlog_js__WEBPACK_IMPORTED_MODULE_5__["symlogish"])(transformer());

  scale.copy = function() {
    return copy(scale, sequentialSymlog()).constant(scale.constant());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}

function sequentialPow() {
  var scale = Object(_pow_js__WEBPACK_IMPORTED_MODULE_6__["powish"])(transformer());

  scale.copy = function() {
    return copy(scale, sequentialPow()).exponent(scale.exponent());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}

function sequentialSqrt() {
  return sequentialPow.apply(null, arguments).exponent(0.5);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/sequentialQuantile.js":
/*!*************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/sequentialQuantile.js ***!
  \*************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return sequentialQuantile; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");




function sequentialQuantile() {
  var domain = [],
      interpolator = _continuous_js__WEBPACK_IMPORTED_MODULE_1__["identity"];

  function scale(x) {
    if (x != null && !isNaN(x = +x)) return interpolator((Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["bisect"])(domain, x, 1) - 1) / (domain.length - 1));
  }

  scale.domain = function(_) {
    if (!arguments.length) return domain.slice();
    domain = [];
    for (let d of _) if (d != null && !isNaN(d = +d)) domain.push(d);
    domain.sort(d3_array__WEBPACK_IMPORTED_MODULE_0__["ascending"]);
    return scale;
  };

  scale.interpolator = function(_) {
    return arguments.length ? (interpolator = _, scale) : interpolator;
  };

  scale.range = function() {
    return domain.map((d, i) => interpolator(i / (domain.length - 1)));
  };

  scale.quantiles = function(n) {
    return Array.from({length: n + 1}, (_, i) => Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["quantile"])(domain, i / n));
  };

  scale.copy = function() {
    return sequentialQuantile(interpolator).domain(domain);
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initInterpolator"].apply(scale, arguments);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/symlog.js":
/*!*************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/symlog.js ***!
  \*************************************************************************/
/*! exports provided: symlogish, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "symlogish", function() { return symlogish; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return symlog; });
/* harmony import */ var _linear_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./linear.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/linear.js");
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");




function transformSymlog(c) {
  return function(x) {
    return Math.sign(x) * Math.log1p(Math.abs(x / c));
  };
}

function transformSymexp(c) {
  return function(x) {
    return Math.sign(x) * Math.expm1(Math.abs(x)) * c;
  };
}

function symlogish(transform) {
  var c = 1, scale = transform(transformSymlog(c), transformSymexp(c));

  scale.constant = function(_) {
    return arguments.length ? transform(transformSymlog(c = +_), transformSymexp(c)) : c;
  };

  return Object(_linear_js__WEBPACK_IMPORTED_MODULE_0__["linearish"])(scale);
}

function symlog() {
  var scale = symlogish(Object(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["transformer"])());

  scale.copy = function() {
    return Object(_continuous_js__WEBPACK_IMPORTED_MODULE_1__["copy"])(scale, symlog()).constant(scale.constant());
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_2__["initRange"].apply(scale, arguments);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/threshold.js":
/*!****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/threshold.js ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return threshold; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");



function threshold() {
  var domain = [0.5],
      range = [0, 1],
      unknown,
      n = 1;

  function scale(x) {
    return x != null && x <= x ? range[Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["bisect"])(domain, x, 0, n)] : unknown;
  }

  scale.domain = function(_) {
    return arguments.length ? (domain = Array.from(_), n = Math.min(domain.length, range.length - 1), scale) : domain.slice();
  };

  scale.range = function(_) {
    return arguments.length ? (range = Array.from(_), n = Math.min(domain.length, range.length - 1), scale) : range.slice();
  };

  scale.invertExtent = function(y) {
    var i = range.indexOf(y);
    return [domain[i - 1], domain[i]];
  };

  scale.unknown = function(_) {
    return arguments.length ? (unknown = _, scale) : unknown;
  };

  scale.copy = function() {
    return threshold()
        .domain(domain)
        .range(range)
        .unknown(unknown);
  };

  return _init_js__WEBPACK_IMPORTED_MODULE_1__["initRange"].apply(scale, arguments);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/tickFormat.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/tickFormat.js ***!
  \*****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return tickFormat; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var d3_format__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-format */ "./node_modules/d3-flame-graph/node_modules/d3-format/src/index.js");



function tickFormat(start, stop, count, specifier) {
  var step = Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["tickStep"])(start, stop, count),
      precision;
  specifier = Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["formatSpecifier"])(specifier == null ? ",f" : specifier);
  switch (specifier.type) {
    case "s": {
      var value = Math.max(Math.abs(start), Math.abs(stop));
      if (specifier.precision == null && !isNaN(precision = Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["precisionPrefix"])(step, value))) specifier.precision = precision;
      return Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["formatPrefix"])(specifier, value);
    }
    case "":
    case "e":
    case "g":
    case "p":
    case "r": {
      if (specifier.precision == null && !isNaN(precision = Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["precisionRound"])(step, Math.max(Math.abs(start), Math.abs(stop))))) specifier.precision = precision - (specifier.type === "e");
      break;
    }
    case "f":
    case "%": {
      if (specifier.precision == null && !isNaN(precision = Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["precisionFixed"])(step))) specifier.precision = precision - (specifier.type === "%") * 2;
      break;
    }
  }
  return Object(d3_format__WEBPACK_IMPORTED_MODULE_1__["format"])(specifier);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/time.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/time.js ***!
  \***********************************************************************/
/*! exports provided: calendar, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "calendar", function() { return calendar; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return time; });
/* harmony import */ var d3_time__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-time */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/index.js");
/* harmony import */ var d3_time_format__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-time-format */ "./node_modules/d3-time-format/src/index.js");
/* harmony import */ var _continuous_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./continuous.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/continuous.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");
/* harmony import */ var _nice_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./nice.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/nice.js");






function date(t) {
  return new Date(t);
}

function number(t) {
  return t instanceof Date ? +t : +new Date(+t);
}

function calendar(ticks, tickInterval, year, month, week, day, hour, minute, second, format) {
  var scale = Object(_continuous_js__WEBPACK_IMPORTED_MODULE_2__["default"])(),
      invert = scale.invert,
      domain = scale.domain;

  var formatMillisecond = format(".%L"),
      formatSecond = format(":%S"),
      formatMinute = format("%I:%M"),
      formatHour = format("%I %p"),
      formatDay = format("%a %d"),
      formatWeek = format("%b %d"),
      formatMonth = format("%B"),
      formatYear = format("%Y");

  function tickFormat(date) {
    return (second(date) < date ? formatMillisecond
        : minute(date) < date ? formatSecond
        : hour(date) < date ? formatMinute
        : day(date) < date ? formatHour
        : month(date) < date ? (week(date) < date ? formatDay : formatWeek)
        : year(date) < date ? formatMonth
        : formatYear)(date);
  }

  scale.invert = function(y) {
    return new Date(invert(y));
  };

  scale.domain = function(_) {
    return arguments.length ? domain(Array.from(_, number)) : domain().map(date);
  };

  scale.ticks = function(interval) {
    var d = domain();
    return ticks(d[0], d[d.length - 1], interval == null ? 10 : interval);
  };

  scale.tickFormat = function(count, specifier) {
    return specifier == null ? tickFormat : format(specifier);
  };

  scale.nice = function(interval) {
    var d = domain();
    if (!interval || typeof interval.range !== "function") interval = tickInterval(d[0], d[d.length - 1], interval == null ? 10 : interval);
    return interval ? domain(Object(_nice_js__WEBPACK_IMPORTED_MODULE_4__["default"])(d, interval)) : scale;
  };

  scale.copy = function() {
    return Object(_continuous_js__WEBPACK_IMPORTED_MODULE_2__["copy"])(scale, calendar(ticks, tickInterval, year, month, week, day, hour, minute, second, format));
  };

  return scale;
}

function time() {
  return _init_js__WEBPACK_IMPORTED_MODULE_3__["initRange"].apply(calendar(d3_time__WEBPACK_IMPORTED_MODULE_0__["timeTicks"], d3_time__WEBPACK_IMPORTED_MODULE_0__["timeTickInterval"], d3_time__WEBPACK_IMPORTED_MODULE_0__["timeYear"], d3_time__WEBPACK_IMPORTED_MODULE_0__["timeMonth"], d3_time__WEBPACK_IMPORTED_MODULE_0__["timeWeek"], d3_time__WEBPACK_IMPORTED_MODULE_0__["timeDay"], d3_time__WEBPACK_IMPORTED_MODULE_0__["timeHour"], d3_time__WEBPACK_IMPORTED_MODULE_0__["timeMinute"], d3_time__WEBPACK_IMPORTED_MODULE_0__["timeSecond"], d3_time_format__WEBPACK_IMPORTED_MODULE_1__["timeFormat"]).domain([new Date(2000, 0, 1), new Date(2000, 0, 2)]), arguments);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/utcTime.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-scale/src/utcTime.js ***!
  \**************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return utcTime; });
/* harmony import */ var d3_time__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-time */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/index.js");
/* harmony import */ var d3_time_format__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-time-format */ "./node_modules/d3-time-format/src/index.js");
/* harmony import */ var _time_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./time.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/time.js");
/* harmony import */ var _init_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./init.js */ "./node_modules/d3-flame-graph/node_modules/d3-scale/src/init.js");





function utcTime() {
  return _init_js__WEBPACK_IMPORTED_MODULE_3__["initRange"].apply(Object(_time_js__WEBPACK_IMPORTED_MODULE_2__["calendar"])(d3_time__WEBPACK_IMPORTED_MODULE_0__["utcTicks"], d3_time__WEBPACK_IMPORTED_MODULE_0__["utcTickInterval"], d3_time__WEBPACK_IMPORTED_MODULE_0__["utcYear"], d3_time__WEBPACK_IMPORTED_MODULE_0__["utcMonth"], d3_time__WEBPACK_IMPORTED_MODULE_0__["utcWeek"], d3_time__WEBPACK_IMPORTED_MODULE_0__["utcDay"], d3_time__WEBPACK_IMPORTED_MODULE_0__["utcHour"], d3_time__WEBPACK_IMPORTED_MODULE_0__["utcMinute"], d3_time__WEBPACK_IMPORTED_MODULE_0__["utcSecond"], d3_time_format__WEBPACK_IMPORTED_MODULE_1__["utcFormat"]).domain([Date.UTC(2000, 0, 1), Date.UTC(2000, 0, 2)]), arguments);
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/day.js":
/*!*********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/day.js ***!
  \*********************************************************************/
/*! exports provided: timeDay, timeDays, utcDay, utcDays, unixDay, unixDays */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeDay", function() { return timeDay; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeDays", function() { return timeDays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcDay", function() { return utcDay; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcDays", function() { return utcDays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "unixDay", function() { return unixDay; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "unixDays", function() { return unixDays; });
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");
/* harmony import */ var _duration_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./duration.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/duration.js");



const timeDay = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])(
  date => date.setHours(0, 0, 0, 0),
  (date, step) => date.setDate(date.getDate() + step),
  (start, end) => (end - start - (end.getTimezoneOffset() - start.getTimezoneOffset()) * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationDay"],
  date => date.getDate() - 1
);

const timeDays = timeDay.range;

const utcDay = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setUTCHours(0, 0, 0, 0);
}, (date, step) => {
  date.setUTCDate(date.getUTCDate() + step);
}, (start, end) => {
  return (end - start) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationDay"];
}, (date) => {
  return date.getUTCDate() - 1;
});

const utcDays = utcDay.range;

const unixDay = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setUTCHours(0, 0, 0, 0);
}, (date, step) => {
  date.setUTCDate(date.getUTCDate() + step);
}, (start, end) => {
  return (end - start) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationDay"];
}, (date) => {
  return Math.floor(date / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationDay"]);
});

const unixDays = unixDay.range;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/duration.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/duration.js ***!
  \**************************************************************************/
/*! exports provided: durationSecond, durationMinute, durationHour, durationDay, durationWeek, durationMonth, durationYear */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "durationSecond", function() { return durationSecond; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "durationMinute", function() { return durationMinute; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "durationHour", function() { return durationHour; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "durationDay", function() { return durationDay; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "durationWeek", function() { return durationWeek; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "durationMonth", function() { return durationMonth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "durationYear", function() { return durationYear; });
const durationSecond = 1000;
const durationMinute = durationSecond * 60;
const durationHour = durationMinute * 60;
const durationDay = durationHour * 24;
const durationWeek = durationDay * 7;
const durationMonth = durationDay * 30;
const durationYear = durationDay * 365;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/hour.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/hour.js ***!
  \**********************************************************************/
/*! exports provided: timeHour, timeHours, utcHour, utcHours */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeHour", function() { return timeHour; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeHours", function() { return timeHours; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcHour", function() { return utcHour; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcHours", function() { return utcHours; });
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");
/* harmony import */ var _duration_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./duration.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/duration.js");



const timeHour = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setTime(date - date.getMilliseconds() - date.getSeconds() * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationSecond"] - date.getMinutes() * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]);
}, (date, step) => {
  date.setTime(+date + step * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationHour"]);
}, (start, end) => {
  return (end - start) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationHour"];
}, (date) => {
  return date.getHours();
});

const timeHours = timeHour.range;

const utcHour = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setUTCMinutes(0, 0, 0);
}, (date, step) => {
  date.setTime(+date + step * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationHour"]);
}, (start, end) => {
  return (end - start) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationHour"];
}, (date) => {
  return date.getUTCHours();
});

const utcHours = utcHour.range;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/index.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/index.js ***!
  \***********************************************************************/
/*! exports provided: timeInterval, utcMillisecond, utcMilliseconds, timeMillisecond, timeMilliseconds, utcSecond, utcSeconds, timeSecond, timeSeconds, timeMinute, timeMinutes, utcMinute, utcMinutes, timeHour, timeHours, utcHour, utcHours, timeDay, timeDays, utcDay, utcDays, unixDay, unixDays, timeWeek, timeWeeks, timeSunday, timeSundays, timeMonday, timeMondays, timeTuesday, timeTuesdays, timeWednesday, timeWednesdays, timeThursday, timeThursdays, timeFriday, timeFridays, timeSaturday, timeSaturdays, utcWeek, utcWeeks, utcSunday, utcSundays, utcMonday, utcMondays, utcTuesday, utcTuesdays, utcWednesday, utcWednesdays, utcThursday, utcThursdays, utcFriday, utcFridays, utcSaturday, utcSaturdays, timeMonth, timeMonths, utcMonth, utcMonths, timeYear, timeYears, utcYear, utcYears, utcTicks, utcTickInterval, timeTicks, timeTickInterval */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeInterval", function() { return _interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"]; });

/* harmony import */ var _millisecond_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./millisecond.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/millisecond.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcMillisecond", function() { return _millisecond_js__WEBPACK_IMPORTED_MODULE_1__["millisecond"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcMilliseconds", function() { return _millisecond_js__WEBPACK_IMPORTED_MODULE_1__["milliseconds"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeMillisecond", function() { return _millisecond_js__WEBPACK_IMPORTED_MODULE_1__["millisecond"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeMilliseconds", function() { return _millisecond_js__WEBPACK_IMPORTED_MODULE_1__["milliseconds"]; });

/* harmony import */ var _second_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./second.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/second.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcSecond", function() { return _second_js__WEBPACK_IMPORTED_MODULE_2__["second"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcSeconds", function() { return _second_js__WEBPACK_IMPORTED_MODULE_2__["seconds"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeSecond", function() { return _second_js__WEBPACK_IMPORTED_MODULE_2__["second"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeSeconds", function() { return _second_js__WEBPACK_IMPORTED_MODULE_2__["seconds"]; });

/* harmony import */ var _minute_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./minute.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/minute.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeMinute", function() { return _minute_js__WEBPACK_IMPORTED_MODULE_3__["timeMinute"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeMinutes", function() { return _minute_js__WEBPACK_IMPORTED_MODULE_3__["timeMinutes"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcMinute", function() { return _minute_js__WEBPACK_IMPORTED_MODULE_3__["utcMinute"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcMinutes", function() { return _minute_js__WEBPACK_IMPORTED_MODULE_3__["utcMinutes"]; });

/* harmony import */ var _hour_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./hour.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/hour.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeHour", function() { return _hour_js__WEBPACK_IMPORTED_MODULE_4__["timeHour"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeHours", function() { return _hour_js__WEBPACK_IMPORTED_MODULE_4__["timeHours"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcHour", function() { return _hour_js__WEBPACK_IMPORTED_MODULE_4__["utcHour"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcHours", function() { return _hour_js__WEBPACK_IMPORTED_MODULE_4__["utcHours"]; });

/* harmony import */ var _day_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./day.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/day.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeDay", function() { return _day_js__WEBPACK_IMPORTED_MODULE_5__["timeDay"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeDays", function() { return _day_js__WEBPACK_IMPORTED_MODULE_5__["timeDays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcDay", function() { return _day_js__WEBPACK_IMPORTED_MODULE_5__["utcDay"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcDays", function() { return _day_js__WEBPACK_IMPORTED_MODULE_5__["utcDays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "unixDay", function() { return _day_js__WEBPACK_IMPORTED_MODULE_5__["unixDay"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "unixDays", function() { return _day_js__WEBPACK_IMPORTED_MODULE_5__["unixDays"]; });

/* harmony import */ var _week_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./week.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/week.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeWeek", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeSunday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeWeeks", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeSundays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeSunday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeSunday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeSundays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeSundays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeMonday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeMonday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeMondays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeMondays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeTuesday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeTuesday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeTuesdays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeTuesdays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeWednesday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeWednesday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeWednesdays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeWednesdays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeThursday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeThursday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeThursdays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeThursdays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeFriday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeFriday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeFridays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeFridays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeSaturday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeSaturday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeSaturdays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["timeSaturdays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcWeek", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcSunday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcWeeks", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcSundays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcSunday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcSunday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcSundays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcSundays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcMonday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcMonday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcMondays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcMondays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcTuesday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcTuesday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcTuesdays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcTuesdays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcWednesday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcWednesday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcWednesdays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcWednesdays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcThursday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcThursday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcThursdays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcThursdays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcFriday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcFriday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcFridays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcFridays"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcSaturday", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcSaturday"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcSaturdays", function() { return _week_js__WEBPACK_IMPORTED_MODULE_6__["utcSaturdays"]; });

/* harmony import */ var _month_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./month.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/month.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeMonth", function() { return _month_js__WEBPACK_IMPORTED_MODULE_7__["timeMonth"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeMonths", function() { return _month_js__WEBPACK_IMPORTED_MODULE_7__["timeMonths"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcMonth", function() { return _month_js__WEBPACK_IMPORTED_MODULE_7__["utcMonth"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcMonths", function() { return _month_js__WEBPACK_IMPORTED_MODULE_7__["utcMonths"]; });

/* harmony import */ var _year_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./year.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/year.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeYear", function() { return _year_js__WEBPACK_IMPORTED_MODULE_8__["timeYear"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeYears", function() { return _year_js__WEBPACK_IMPORTED_MODULE_8__["timeYears"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcYear", function() { return _year_js__WEBPACK_IMPORTED_MODULE_8__["utcYear"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcYears", function() { return _year_js__WEBPACK_IMPORTED_MODULE_8__["utcYears"]; });

/* harmony import */ var _ticks_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./ticks.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/ticks.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcTicks", function() { return _ticks_js__WEBPACK_IMPORTED_MODULE_9__["utcTicks"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "utcTickInterval", function() { return _ticks_js__WEBPACK_IMPORTED_MODULE_9__["utcTickInterval"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeTicks", function() { return _ticks_js__WEBPACK_IMPORTED_MODULE_9__["timeTicks"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeTickInterval", function() { return _ticks_js__WEBPACK_IMPORTED_MODULE_9__["timeTickInterval"]; });






















/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js":
/*!**************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js ***!
  \**************************************************************************/
/*! exports provided: timeInterval */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeInterval", function() { return timeInterval; });
const t0 = new Date, t1 = new Date;

function timeInterval(floori, offseti, count, field) {

  function interval(date) {
    return floori(date = arguments.length === 0 ? new Date : new Date(+date)), date;
  }

  interval.floor = (date) => {
    return floori(date = new Date(+date)), date;
  };

  interval.ceil = (date) => {
    return floori(date = new Date(date - 1)), offseti(date, 1), floori(date), date;
  };

  interval.round = (date) => {
    const d0 = interval(date), d1 = interval.ceil(date);
    return date - d0 < d1 - date ? d0 : d1;
  };

  interval.offset = (date, step) => {
    return offseti(date = new Date(+date), step == null ? 1 : Math.floor(step)), date;
  };

  interval.range = (start, stop, step) => {
    const range = [];
    start = interval.ceil(start);
    step = step == null ? 1 : Math.floor(step);
    if (!(start < stop) || !(step > 0)) return range; // also handles Invalid Date
    let previous;
    do range.push(previous = new Date(+start)), offseti(start, step), floori(start);
    while (previous < start && start < stop);
    return range;
  };

  interval.filter = (test) => {
    return timeInterval((date) => {
      if (date >= date) while (floori(date), !test(date)) date.setTime(date - 1);
    }, (date, step) => {
      if (date >= date) {
        if (step < 0) while (++step <= 0) {
          while (offseti(date, -1), !test(date)) {} // eslint-disable-line no-empty
        } else while (--step >= 0) {
          while (offseti(date, +1), !test(date)) {} // eslint-disable-line no-empty
        }
      }
    });
  };

  if (count) {
    interval.count = (start, end) => {
      t0.setTime(+start), t1.setTime(+end);
      floori(t0), floori(t1);
      return Math.floor(count(t0, t1));
    };

    interval.every = (step) => {
      step = Math.floor(step);
      return !isFinite(step) || !(step > 0) ? null
          : !(step > 1) ? interval
          : interval.filter(field
              ? (d) => field(d) % step === 0
              : (d) => interval.count(0, d) % step === 0);
    };
  }

  return interval;
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/millisecond.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/millisecond.js ***!
  \*****************************************************************************/
/*! exports provided: millisecond, milliseconds */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "millisecond", function() { return millisecond; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "milliseconds", function() { return milliseconds; });
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");


const millisecond = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])(() => {
  // noop
}, (date, step) => {
  date.setTime(+date + step);
}, (start, end) => {
  return end - start;
});

// An optimized implementation for this simple case.
millisecond.every = (k) => {
  k = Math.floor(k);
  if (!isFinite(k) || !(k > 0)) return null;
  if (!(k > 1)) return millisecond;
  return Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
    date.setTime(Math.floor(date / k) * k);
  }, (date, step) => {
    date.setTime(+date + step * k);
  }, (start, end) => {
    return (end - start) / k;
  });
};

const milliseconds = millisecond.range;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/minute.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/minute.js ***!
  \************************************************************************/
/*! exports provided: timeMinute, timeMinutes, utcMinute, utcMinutes */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeMinute", function() { return timeMinute; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeMinutes", function() { return timeMinutes; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcMinute", function() { return utcMinute; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcMinutes", function() { return utcMinutes; });
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");
/* harmony import */ var _duration_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./duration.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/duration.js");



const timeMinute = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setTime(date - date.getMilliseconds() - date.getSeconds() * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationSecond"]);
}, (date, step) => {
  date.setTime(+date + step * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]);
}, (start, end) => {
  return (end - start) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"];
}, (date) => {
  return date.getMinutes();
});

const timeMinutes = timeMinute.range;

const utcMinute = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setUTCSeconds(0, 0);
}, (date, step) => {
  date.setTime(+date + step * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]);
}, (start, end) => {
  return (end - start) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"];
}, (date) => {
  return date.getUTCMinutes();
});

const utcMinutes = utcMinute.range;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/month.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/month.js ***!
  \***********************************************************************/
/*! exports provided: timeMonth, timeMonths, utcMonth, utcMonths */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeMonth", function() { return timeMonth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeMonths", function() { return timeMonths; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcMonth", function() { return utcMonth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcMonths", function() { return utcMonths; });
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");


const timeMonth = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setDate(1);
  date.setHours(0, 0, 0, 0);
}, (date, step) => {
  date.setMonth(date.getMonth() + step);
}, (start, end) => {
  return end.getMonth() - start.getMonth() + (end.getFullYear() - start.getFullYear()) * 12;
}, (date) => {
  return date.getMonth();
});

const timeMonths = timeMonth.range;

const utcMonth = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setUTCDate(1);
  date.setUTCHours(0, 0, 0, 0);
}, (date, step) => {
  date.setUTCMonth(date.getUTCMonth() + step);
}, (start, end) => {
  return end.getUTCMonth() - start.getUTCMonth() + (end.getUTCFullYear() - start.getUTCFullYear()) * 12;
}, (date) => {
  return date.getUTCMonth();
});

const utcMonths = utcMonth.range;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/second.js":
/*!************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/second.js ***!
  \************************************************************************/
/*! exports provided: second, seconds */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "second", function() { return second; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "seconds", function() { return seconds; });
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");
/* harmony import */ var _duration_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./duration.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/duration.js");



const second = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setTime(date - date.getMilliseconds());
}, (date, step) => {
  date.setTime(+date + step * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationSecond"]);
}, (start, end) => {
  return (end - start) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationSecond"];
}, (date) => {
  return date.getUTCSeconds();
});

const seconds = second.range;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/ticks.js":
/*!***********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/ticks.js ***!
  \***********************************************************************/
/*! exports provided: utcTicks, utcTickInterval, timeTicks, timeTickInterval */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcTicks", function() { return utcTicks; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcTickInterval", function() { return utcTickInterval; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeTicks", function() { return timeTicks; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeTickInterval", function() { return timeTickInterval; });
/* harmony import */ var d3_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-array */ "./node_modules/d3-flame-graph/node_modules/d3-array/src/index.js");
/* harmony import */ var _duration_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./duration.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/duration.js");
/* harmony import */ var _millisecond_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./millisecond.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/millisecond.js");
/* harmony import */ var _second_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./second.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/second.js");
/* harmony import */ var _minute_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./minute.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/minute.js");
/* harmony import */ var _hour_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./hour.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/hour.js");
/* harmony import */ var _day_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./day.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/day.js");
/* harmony import */ var _week_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./week.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/week.js");
/* harmony import */ var _month_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./month.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/month.js");
/* harmony import */ var _year_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./year.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/year.js");











function ticker(year, month, week, day, hour, minute) {

  const tickIntervals = [
    [_second_js__WEBPACK_IMPORTED_MODULE_3__["second"],  1,      _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationSecond"]],
    [_second_js__WEBPACK_IMPORTED_MODULE_3__["second"],  5,  5 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationSecond"]],
    [_second_js__WEBPACK_IMPORTED_MODULE_3__["second"], 15, 15 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationSecond"]],
    [_second_js__WEBPACK_IMPORTED_MODULE_3__["second"], 30, 30 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationSecond"]],
    [minute,  1,      _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]],
    [minute,  5,  5 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]],
    [minute, 15, 15 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]],
    [minute, 30, 30 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]],
    [  hour,  1,      _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationHour"]  ],
    [  hour,  3,  3 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationHour"]  ],
    [  hour,  6,  6 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationHour"]  ],
    [  hour, 12, 12 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationHour"]  ],
    [   day,  1,      _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationDay"]   ],
    [   day,  2,  2 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationDay"]   ],
    [  week,  1,      _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationWeek"]  ],
    [ month,  1,      _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMonth"] ],
    [ month,  3,  3 * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMonth"] ],
    [  year,  1,      _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationYear"]  ]
  ];

  function ticks(start, stop, count) {
    const reverse = stop < start;
    if (reverse) [start, stop] = [stop, start];
    const interval = count && typeof count.range === "function" ? count : tickInterval(start, stop, count);
    const ticks = interval ? interval.range(start, +stop + 1) : []; // inclusive stop
    return reverse ? ticks.reverse() : ticks;
  }

  function tickInterval(start, stop, count) {
    const target = Math.abs(stop - start) / count;
    const i = Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["bisector"])(([,, step]) => step).right(tickIntervals, target);
    if (i === tickIntervals.length) return year.every(Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["tickStep"])(start / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationYear"], stop / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationYear"], count));
    if (i === 0) return _millisecond_js__WEBPACK_IMPORTED_MODULE_2__["millisecond"].every(Math.max(Object(d3_array__WEBPACK_IMPORTED_MODULE_0__["tickStep"])(start, stop, count), 1));
    const [t, step] = tickIntervals[target / tickIntervals[i - 1][2] < tickIntervals[i][2] / target ? i - 1 : i];
    return t.every(step);
  }

  return [ticks, tickInterval];
}

const [utcTicks, utcTickInterval] = ticker(_year_js__WEBPACK_IMPORTED_MODULE_9__["utcYear"], _month_js__WEBPACK_IMPORTED_MODULE_8__["utcMonth"], _week_js__WEBPACK_IMPORTED_MODULE_7__["utcSunday"], _day_js__WEBPACK_IMPORTED_MODULE_6__["unixDay"], _hour_js__WEBPACK_IMPORTED_MODULE_5__["utcHour"], _minute_js__WEBPACK_IMPORTED_MODULE_4__["utcMinute"]);
const [timeTicks, timeTickInterval] = ticker(_year_js__WEBPACK_IMPORTED_MODULE_9__["timeYear"], _month_js__WEBPACK_IMPORTED_MODULE_8__["timeMonth"], _week_js__WEBPACK_IMPORTED_MODULE_7__["timeSunday"], _day_js__WEBPACK_IMPORTED_MODULE_6__["timeDay"], _hour_js__WEBPACK_IMPORTED_MODULE_5__["timeHour"], _minute_js__WEBPACK_IMPORTED_MODULE_4__["timeMinute"]);




/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/week.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/week.js ***!
  \**********************************************************************/
/*! exports provided: timeSunday, timeMonday, timeTuesday, timeWednesday, timeThursday, timeFriday, timeSaturday, timeSundays, timeMondays, timeTuesdays, timeWednesdays, timeThursdays, timeFridays, timeSaturdays, utcSunday, utcMonday, utcTuesday, utcWednesday, utcThursday, utcFriday, utcSaturday, utcSundays, utcMondays, utcTuesdays, utcWednesdays, utcThursdays, utcFridays, utcSaturdays */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeSunday", function() { return timeSunday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeMonday", function() { return timeMonday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeTuesday", function() { return timeTuesday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeWednesday", function() { return timeWednesday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeThursday", function() { return timeThursday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeFriday", function() { return timeFriday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeSaturday", function() { return timeSaturday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeSundays", function() { return timeSundays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeMondays", function() { return timeMondays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeTuesdays", function() { return timeTuesdays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeWednesdays", function() { return timeWednesdays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeThursdays", function() { return timeThursdays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeFridays", function() { return timeFridays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeSaturdays", function() { return timeSaturdays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcSunday", function() { return utcSunday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcMonday", function() { return utcMonday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcTuesday", function() { return utcTuesday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcWednesday", function() { return utcWednesday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcThursday", function() { return utcThursday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcFriday", function() { return utcFriday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcSaturday", function() { return utcSaturday; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcSundays", function() { return utcSundays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcMondays", function() { return utcMondays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcTuesdays", function() { return utcTuesdays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcWednesdays", function() { return utcWednesdays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcThursdays", function() { return utcThursdays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcFridays", function() { return utcFridays; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcSaturdays", function() { return utcSaturdays; });
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");
/* harmony import */ var _duration_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./duration.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/duration.js");



function timeWeekday(i) {
  return Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
    date.setDate(date.getDate() - (date.getDay() + 7 - i) % 7);
    date.setHours(0, 0, 0, 0);
  }, (date, step) => {
    date.setDate(date.getDate() + step * 7);
  }, (start, end) => {
    return (end - start - (end.getTimezoneOffset() - start.getTimezoneOffset()) * _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationMinute"]) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationWeek"];
  });
}

const timeSunday = timeWeekday(0);
const timeMonday = timeWeekday(1);
const timeTuesday = timeWeekday(2);
const timeWednesday = timeWeekday(3);
const timeThursday = timeWeekday(4);
const timeFriday = timeWeekday(5);
const timeSaturday = timeWeekday(6);

const timeSundays = timeSunday.range;
const timeMondays = timeMonday.range;
const timeTuesdays = timeTuesday.range;
const timeWednesdays = timeWednesday.range;
const timeThursdays = timeThursday.range;
const timeFridays = timeFriday.range;
const timeSaturdays = timeSaturday.range;

function utcWeekday(i) {
  return Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
    date.setUTCDate(date.getUTCDate() - (date.getUTCDay() + 7 - i) % 7);
    date.setUTCHours(0, 0, 0, 0);
  }, (date, step) => {
    date.setUTCDate(date.getUTCDate() + step * 7);
  }, (start, end) => {
    return (end - start) / _duration_js__WEBPACK_IMPORTED_MODULE_1__["durationWeek"];
  });
}

const utcSunday = utcWeekday(0);
const utcMonday = utcWeekday(1);
const utcTuesday = utcWeekday(2);
const utcWednesday = utcWeekday(3);
const utcThursday = utcWeekday(4);
const utcFriday = utcWeekday(5);
const utcSaturday = utcWeekday(6);

const utcSundays = utcSunday.range;
const utcMondays = utcMonday.range;
const utcTuesdays = utcTuesday.range;
const utcWednesdays = utcWednesday.range;
const utcThursdays = utcThursday.range;
const utcFridays = utcFriday.range;
const utcSaturdays = utcSaturday.range;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-time/src/year.js":
/*!**********************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-time/src/year.js ***!
  \**********************************************************************/
/*! exports provided: timeYear, timeYears, utcYear, utcYears */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeYear", function() { return timeYear; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timeYears", function() { return timeYears; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcYear", function() { return utcYear; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "utcYears", function() { return utcYears; });
/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-flame-graph/node_modules/d3-time/src/interval.js");


const timeYear = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setMonth(0, 1);
  date.setHours(0, 0, 0, 0);
}, (date, step) => {
  date.setFullYear(date.getFullYear() + step);
}, (start, end) => {
  return end.getFullYear() - start.getFullYear();
}, (date) => {
  return date.getFullYear();
});

// An optimized implementation for this simple case.
timeYear.every = (k) => {
  return !isFinite(k = Math.floor(k)) || !(k > 0) ? null : Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
    date.setFullYear(Math.floor(date.getFullYear() / k) * k);
    date.setMonth(0, 1);
    date.setHours(0, 0, 0, 0);
  }, (date, step) => {
    date.setFullYear(date.getFullYear() + step * k);
  });
};

const timeYears = timeYear.range;

const utcYear = Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
  date.setUTCMonth(0, 1);
  date.setUTCHours(0, 0, 0, 0);
}, (date, step) => {
  date.setUTCFullYear(date.getUTCFullYear() + step);
}, (start, end) => {
  return end.getUTCFullYear() - start.getUTCFullYear();
}, (date) => {
  return date.getUTCFullYear();
});

// An optimized implementation for this simple case.
utcYear.every = (k) => {
  return !isFinite(k = Math.floor(k)) || !(k > 0) ? null : Object(_interval_js__WEBPACK_IMPORTED_MODULE_0__["timeInterval"])((date) => {
    date.setUTCFullYear(Math.floor(date.getUTCFullYear() / k) * k);
    date.setUTCMonth(0, 1);
    date.setUTCHours(0, 0, 0, 0);
  }, (date, step) => {
    date.setUTCFullYear(date.getUTCFullYear() + step * k);
  });
};

const utcYears = utcYear.range;


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/active.js":
/*!******************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/active.js ***!
  \******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _transition_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./transition/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js");
/* harmony import */ var _transition_schedule_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./transition/schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");



var root = [null];

/* harmony default export */ __webpack_exports__["default"] = (function(node, name) {
  var schedules = node.__transition,
      schedule,
      i;

  if (schedules) {
    name = name == null ? null : name + "";
    for (i in schedules) {
      if ((schedule = schedules[i]).state > _transition_schedule_js__WEBPACK_IMPORTED_MODULE_1__["SCHEDULED"] && schedule.name === name) {
        return new _transition_index_js__WEBPACK_IMPORTED_MODULE_0__["Transition"]([[node]], root, name, +i);
      }
    }
  }

  return null;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/index.js":
/*!*****************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/index.js ***!
  \*****************************************************************************/
/*! exports provided: transition, active, interrupt */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _selection_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./selection/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/index.js");
/* harmony import */ var _transition_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./transition/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "transition", function() { return _transition_index_js__WEBPACK_IMPORTED_MODULE_1__["default"]; });

/* harmony import */ var _active_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./active.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/active.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "active", function() { return _active_js__WEBPACK_IMPORTED_MODULE_2__["default"]; });

/* harmony import */ var _interrupt_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./interrupt.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/interrupt.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interrupt", function() { return _interrupt_js__WEBPACK_IMPORTED_MODULE_3__["default"]; });







/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/interrupt.js":
/*!*********************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/interrupt.js ***!
  \*********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _transition_schedule_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./transition/schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");


/* harmony default export */ __webpack_exports__["default"] = (function(node, name) {
  var schedules = node.__transition,
      schedule,
      active,
      empty = true,
      i;

  if (!schedules) return;

  name = name == null ? null : name + "";

  for (i in schedules) {
    if ((schedule = schedules[i]).name !== name) { empty = false; continue; }
    active = schedule.state > _transition_schedule_js__WEBPACK_IMPORTED_MODULE_0__["STARTING"] && schedule.state < _transition_schedule_js__WEBPACK_IMPORTED_MODULE_0__["ENDING"];
    schedule.state = _transition_schedule_js__WEBPACK_IMPORTED_MODULE_0__["ENDED"];
    schedule.timer.stop();
    schedule.on.call(active ? "interrupt" : "cancel", node, node.__data__, schedule.index, schedule.group);
    delete schedules[i];
  }

  if (empty) delete node.__transition;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/index.js":
/*!***************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/index.js ***!
  \***************************************************************************************/
/*! no exports provided */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var _interrupt_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./interrupt.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/interrupt.js");
/* harmony import */ var _transition_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./transition.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/transition.js");




d3_selection__WEBPACK_IMPORTED_MODULE_0__["selection"].prototype.interrupt = _interrupt_js__WEBPACK_IMPORTED_MODULE_1__["default"];
d3_selection__WEBPACK_IMPORTED_MODULE_0__["selection"].prototype.transition = _transition_js__WEBPACK_IMPORTED_MODULE_2__["default"];


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/interrupt.js":
/*!*******************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/interrupt.js ***!
  \*******************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _interrupt_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../interrupt.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/interrupt.js");


/* harmony default export */ __webpack_exports__["default"] = (function(name) {
  return this.each(function() {
    Object(_interrupt_js__WEBPACK_IMPORTED_MODULE_0__["default"])(this, name);
  });
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/transition.js":
/*!********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/selection/transition.js ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _transition_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../transition/index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js");
/* harmony import */ var _transition_schedule_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../transition/schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");
/* harmony import */ var d3_ease__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! d3-ease */ "./node_modules/d3-flame-graph/node_modules/d3-ease/src/index.js");
/* harmony import */ var d3_timer__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! d3-timer */ "./node_modules/d3-timer/src/index.js");





var defaultTiming = {
  time: null, // Set on use.
  delay: 0,
  duration: 250,
  ease: d3_ease__WEBPACK_IMPORTED_MODULE_2__["easeCubicInOut"]
};

function inherit(node, id) {
  var timing;
  while (!(timing = node.__transition) || !(timing = timing[id])) {
    if (!(node = node.parentNode)) {
      throw new Error(`transition ${id} not found`);
    }
  }
  return timing;
}

/* harmony default export */ __webpack_exports__["default"] = (function(name) {
  var id,
      timing;

  if (name instanceof _transition_index_js__WEBPACK_IMPORTED_MODULE_0__["Transition"]) {
    id = name._id, name = name._name;
  } else {
    id = Object(_transition_index_js__WEBPACK_IMPORTED_MODULE_0__["newId"])(), (timing = defaultTiming).time = Object(d3_timer__WEBPACK_IMPORTED_MODULE_3__["now"])(), name = name == null ? null : name + "";
  }

  for (var groups = this._groups, m = groups.length, j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {
      if (node = group[i]) {
        Object(_transition_schedule_js__WEBPACK_IMPORTED_MODULE_1__["default"])(node, name, id, i, group, timing || inherit(node, id));
      }
    }
  }

  return new _transition_index_js__WEBPACK_IMPORTED_MODULE_0__["Transition"](groups, this._parents, name, id);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/attr.js":
/*!***************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/attr.js ***!
  \***************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_interpolate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-interpolate */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/index.js");
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var _tween_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./tween.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/tween.js");
/* harmony import */ var _interpolate_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./interpolate.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/interpolate.js");





function attrRemove(name) {
  return function() {
    this.removeAttribute(name);
  };
}

function attrRemoveNS(fullname) {
  return function() {
    this.removeAttributeNS(fullname.space, fullname.local);
  };
}

function attrConstant(name, interpolate, value1) {
  var string00,
      string1 = value1 + "",
      interpolate0;
  return function() {
    var string0 = this.getAttribute(name);
    return string0 === string1 ? null
        : string0 === string00 ? interpolate0
        : interpolate0 = interpolate(string00 = string0, value1);
  };
}

function attrConstantNS(fullname, interpolate, value1) {
  var string00,
      string1 = value1 + "",
      interpolate0;
  return function() {
    var string0 = this.getAttributeNS(fullname.space, fullname.local);
    return string0 === string1 ? null
        : string0 === string00 ? interpolate0
        : interpolate0 = interpolate(string00 = string0, value1);
  };
}

function attrFunction(name, interpolate, value) {
  var string00,
      string10,
      interpolate0;
  return function() {
    var string0, value1 = value(this), string1;
    if (value1 == null) return void this.removeAttribute(name);
    string0 = this.getAttribute(name);
    string1 = value1 + "";
    return string0 === string1 ? null
        : string0 === string00 && string1 === string10 ? interpolate0
        : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));
  };
}

function attrFunctionNS(fullname, interpolate, value) {
  var string00,
      string10,
      interpolate0;
  return function() {
    var string0, value1 = value(this), string1;
    if (value1 == null) return void this.removeAttributeNS(fullname.space, fullname.local);
    string0 = this.getAttributeNS(fullname.space, fullname.local);
    string1 = value1 + "";
    return string0 === string1 ? null
        : string0 === string00 && string1 === string10 ? interpolate0
        : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value) {
  var fullname = Object(d3_selection__WEBPACK_IMPORTED_MODULE_1__["namespace"])(name), i = fullname === "transform" ? d3_interpolate__WEBPACK_IMPORTED_MODULE_0__["interpolateTransformSvg"] : _interpolate_js__WEBPACK_IMPORTED_MODULE_3__["default"];
  return this.attrTween(name, typeof value === "function"
      ? (fullname.local ? attrFunctionNS : attrFunction)(fullname, i, Object(_tween_js__WEBPACK_IMPORTED_MODULE_2__["tweenValue"])(this, "attr." + name, value))
      : value == null ? (fullname.local ? attrRemoveNS : attrRemove)(fullname)
      : (fullname.local ? attrConstantNS : attrConstant)(fullname, i, value));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/attrTween.js":
/*!********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/attrTween.js ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");


function attrInterpolate(name, i) {
  return function(t) {
    this.setAttribute(name, i.call(this, t));
  };
}

function attrInterpolateNS(fullname, i) {
  return function(t) {
    this.setAttributeNS(fullname.space, fullname.local, i.call(this, t));
  };
}

function attrTweenNS(fullname, value) {
  var t0, i0;
  function tween() {
    var i = value.apply(this, arguments);
    if (i !== i0) t0 = (i0 = i) && attrInterpolateNS(fullname, i);
    return t0;
  }
  tween._value = value;
  return tween;
}

function attrTween(name, value) {
  var t0, i0;
  function tween() {
    var i = value.apply(this, arguments);
    if (i !== i0) t0 = (i0 = i) && attrInterpolate(name, i);
    return t0;
  }
  tween._value = value;
  return tween;
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value) {
  var key = "attr." + name;
  if (arguments.length < 2) return (key = this.tween(key)) && key._value;
  if (value == null) return this.tween(key, null);
  if (typeof value !== "function") throw new Error;
  var fullname = Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["namespace"])(name);
  return this.tween(key, (fullname.local ? attrTweenNS : attrTween)(fullname, value));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/delay.js":
/*!****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/delay.js ***!
  \****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");


function delayFunction(id, value) {
  return function() {
    Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["init"])(this, id).delay = +value.apply(this, arguments);
  };
}

function delayConstant(id, value) {
  return value = +value, function() {
    Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["init"])(this, id).delay = value;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  var id = this._id;

  return arguments.length
      ? this.each((typeof value === "function"
          ? delayFunction
          : delayConstant)(id, value))
      : Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["get"])(this.node(), id).delay;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/duration.js":
/*!*******************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/duration.js ***!
  \*******************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");


function durationFunction(id, value) {
  return function() {
    Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"])(this, id).duration = +value.apply(this, arguments);
  };
}

function durationConstant(id, value) {
  return value = +value, function() {
    Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"])(this, id).duration = value;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  var id = this._id;

  return arguments.length
      ? this.each((typeof value === "function"
          ? durationFunction
          : durationConstant)(id, value))
      : Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["get"])(this.node(), id).duration;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/ease.js":
/*!***************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/ease.js ***!
  \***************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");


function easeConstant(id, value) {
  if (typeof value !== "function") throw new Error;
  return function() {
    Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"])(this, id).ease = value;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  var id = this._id;

  return arguments.length
      ? this.each(easeConstant(id, value))
      : Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["get"])(this.node(), id).ease;
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/easeVarying.js":
/*!**********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/easeVarying.js ***!
  \**********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");


function easeVarying(id, value) {
  return function() {
    var v = value.apply(this, arguments);
    if (typeof v !== "function") throw new Error;
    Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"])(this, id).ease = v;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  if (typeof value !== "function") throw new Error;
  return this.each(easeVarying(this._id, value));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/end.js":
/*!**************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/end.js ***!
  \**************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");


/* harmony default export */ __webpack_exports__["default"] = (function() {
  var on0, on1, that = this, id = that._id, size = that.size();
  return new Promise(function(resolve, reject) {
    var cancel = {value: reject},
        end = {value: function() { if (--size === 0) resolve(); }};

    that.each(function() {
      var schedule = Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"])(this, id),
          on = schedule.on;

      // If this node shared a dispatch with the previous node,
      // just assign the updated shared dispatch and we’re done!
      // Otherwise, copy-on-write.
      if (on !== on0) {
        on1 = (on0 = on).copy();
        on1._.cancel.push(cancel);
        on1._.interrupt.push(cancel);
        on1._.end.push(end);
      }

      schedule.on = on1;
    });

    // The selection was empty, resolve end immediately
    if (size === 0) resolve();
  });
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/filter.js":
/*!*****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/filter.js ***!
  \*****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js");



/* harmony default export */ __webpack_exports__["default"] = (function(match) {
  if (typeof match !== "function") match = Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["matcher"])(match);

  for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, subgroup = subgroups[j] = [], node, i = 0; i < n; ++i) {
      if ((node = group[i]) && match.call(node, node.__data__, i, group)) {
        subgroup.push(node);
      }
    }
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_1__["Transition"](subgroups, this._parents, this._name, this._id);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js":
/*!****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js ***!
  \****************************************************************************************/
/*! exports provided: Transition, default, newId */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Transition", function() { return Transition; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return transition; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "newId", function() { return newId; });
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var _attr_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./attr.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/attr.js");
/* harmony import */ var _attrTween_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./attrTween.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/attrTween.js");
/* harmony import */ var _delay_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./delay.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/delay.js");
/* harmony import */ var _duration_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./duration.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/duration.js");
/* harmony import */ var _ease_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./ease.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/ease.js");
/* harmony import */ var _easeVarying_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./easeVarying.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/easeVarying.js");
/* harmony import */ var _filter_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./filter.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/filter.js");
/* harmony import */ var _merge_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./merge.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/merge.js");
/* harmony import */ var _on_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./on.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/on.js");
/* harmony import */ var _remove_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./remove.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/remove.js");
/* harmony import */ var _select_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./select.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/select.js");
/* harmony import */ var _selectAll_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./selectAll.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/selectAll.js");
/* harmony import */ var _selection_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./selection.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/selection.js");
/* harmony import */ var _style_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./style.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/style.js");
/* harmony import */ var _styleTween_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./styleTween.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/styleTween.js");
/* harmony import */ var _text_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./text.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/text.js");
/* harmony import */ var _textTween_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./textTween.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/textTween.js");
/* harmony import */ var _transition_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./transition.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/transition.js");
/* harmony import */ var _tween_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./tween.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/tween.js");
/* harmony import */ var _end_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./end.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/end.js");






















var id = 0;

function Transition(groups, parents, name, id) {
  this._groups = groups;
  this._parents = parents;
  this._name = name;
  this._id = id;
}

function transition(name) {
  return Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["selection"])().transition(name);
}

function newId() {
  return ++id;
}

var selection_prototype = d3_selection__WEBPACK_IMPORTED_MODULE_0__["selection"].prototype;

Transition.prototype = transition.prototype = {
  constructor: Transition,
  select: _select_js__WEBPACK_IMPORTED_MODULE_11__["default"],
  selectAll: _selectAll_js__WEBPACK_IMPORTED_MODULE_12__["default"],
  selectChild: selection_prototype.selectChild,
  selectChildren: selection_prototype.selectChildren,
  filter: _filter_js__WEBPACK_IMPORTED_MODULE_7__["default"],
  merge: _merge_js__WEBPACK_IMPORTED_MODULE_8__["default"],
  selection: _selection_js__WEBPACK_IMPORTED_MODULE_13__["default"],
  transition: _transition_js__WEBPACK_IMPORTED_MODULE_18__["default"],
  call: selection_prototype.call,
  nodes: selection_prototype.nodes,
  node: selection_prototype.node,
  size: selection_prototype.size,
  empty: selection_prototype.empty,
  each: selection_prototype.each,
  on: _on_js__WEBPACK_IMPORTED_MODULE_9__["default"],
  attr: _attr_js__WEBPACK_IMPORTED_MODULE_1__["default"],
  attrTween: _attrTween_js__WEBPACK_IMPORTED_MODULE_2__["default"],
  style: _style_js__WEBPACK_IMPORTED_MODULE_14__["default"],
  styleTween: _styleTween_js__WEBPACK_IMPORTED_MODULE_15__["default"],
  text: _text_js__WEBPACK_IMPORTED_MODULE_16__["default"],
  textTween: _textTween_js__WEBPACK_IMPORTED_MODULE_17__["default"],
  remove: _remove_js__WEBPACK_IMPORTED_MODULE_10__["default"],
  tween: _tween_js__WEBPACK_IMPORTED_MODULE_19__["default"],
  delay: _delay_js__WEBPACK_IMPORTED_MODULE_3__["default"],
  duration: _duration_js__WEBPACK_IMPORTED_MODULE_4__["default"],
  ease: _ease_js__WEBPACK_IMPORTED_MODULE_5__["default"],
  easeVarying: _easeVarying_js__WEBPACK_IMPORTED_MODULE_6__["default"],
  end: _end_js__WEBPACK_IMPORTED_MODULE_20__["default"],
  [Symbol.iterator]: selection_prototype[Symbol.iterator]
};


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/interpolate.js":
/*!**********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/interpolate.js ***!
  \**********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_color__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-color */ "./node_modules/d3-color/index.js");
/* harmony import */ var d3_interpolate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-interpolate */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/index.js");



/* harmony default export */ __webpack_exports__["default"] = (function(a, b) {
  var c;
  return (typeof b === "number" ? d3_interpolate__WEBPACK_IMPORTED_MODULE_1__["interpolateNumber"]
      : b instanceof d3_color__WEBPACK_IMPORTED_MODULE_0__["color"] ? d3_interpolate__WEBPACK_IMPORTED_MODULE_1__["interpolateRgb"]
      : (c = Object(d3_color__WEBPACK_IMPORTED_MODULE_0__["color"])(b)) ? (b = c, d3_interpolate__WEBPACK_IMPORTED_MODULE_1__["interpolateRgb"])
      : d3_interpolate__WEBPACK_IMPORTED_MODULE_1__["interpolateString"])(a, b);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/merge.js":
/*!****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/merge.js ***!
  \****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js");


/* harmony default export */ __webpack_exports__["default"] = (function(transition) {
  if (transition._id !== this._id) throw new Error;

  for (var groups0 = this._groups, groups1 = transition._groups, m0 = groups0.length, m1 = groups1.length, m = Math.min(m0, m1), merges = new Array(m0), j = 0; j < m; ++j) {
    for (var group0 = groups0[j], group1 = groups1[j], n = group0.length, merge = merges[j] = new Array(n), node, i = 0; i < n; ++i) {
      if (node = group0[i] || group1[i]) {
        merge[i] = node;
      }
    }
  }

  for (; j < m0; ++j) {
    merges[j] = groups0[j];
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_0__["Transition"](merges, this._parents, this._name, this._id);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/on.js":
/*!*************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/on.js ***!
  \*************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");


function start(name) {
  return (name + "").trim().split(/^|\s+/).every(function(t) {
    var i = t.indexOf(".");
    if (i >= 0) t = t.slice(0, i);
    return !t || t === "start";
  });
}

function onFunction(id, name, listener) {
  var on0, on1, sit = start(name) ? _schedule_js__WEBPACK_IMPORTED_MODULE_0__["init"] : _schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"];
  return function() {
    var schedule = sit(this, id),
        on = schedule.on;

    // If this node shared a dispatch with the previous node,
    // just assign the updated shared dispatch and we’re done!
    // Otherwise, copy-on-write.
    if (on !== on0) (on1 = (on0 = on).copy()).on(name, listener);

    schedule.on = on1;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, listener) {
  var id = this._id;

  return arguments.length < 2
      ? Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["get"])(this.node(), id).on.on(name)
      : this.each(onFunction(id, name, listener));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/remove.js":
/*!*****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/remove.js ***!
  \*****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function removeFunction(id) {
  return function() {
    var parent = this.parentNode;
    for (var i in this.__transition) if (+i !== id) return;
    if (parent) parent.removeChild(this);
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function() {
  return this.on("end.remove", removeFunction(this._id));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js":
/*!*******************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js ***!
  \*******************************************************************************************/
/*! exports provided: CREATED, SCHEDULED, STARTING, STARTED, RUNNING, ENDING, ENDED, default, init, set, get */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CREATED", function() { return CREATED; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SCHEDULED", function() { return SCHEDULED; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "STARTING", function() { return STARTING; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "STARTED", function() { return STARTED; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "RUNNING", function() { return RUNNING; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ENDING", function() { return ENDING; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ENDED", function() { return ENDED; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "init", function() { return init; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "set", function() { return set; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "get", function() { return get; });
/* harmony import */ var d3_dispatch__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-dispatch */ "./node_modules/d3-flame-graph/node_modules/d3-dispatch/src/index.js");
/* harmony import */ var d3_timer__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-timer */ "./node_modules/d3-timer/src/index.js");



var emptyOn = Object(d3_dispatch__WEBPACK_IMPORTED_MODULE_0__["dispatch"])("start", "end", "cancel", "interrupt");
var emptyTween = [];

var CREATED = 0;
var SCHEDULED = 1;
var STARTING = 2;
var STARTED = 3;
var RUNNING = 4;
var ENDING = 5;
var ENDED = 6;

/* harmony default export */ __webpack_exports__["default"] = (function(node, name, id, index, group, timing) {
  var schedules = node.__transition;
  if (!schedules) node.__transition = {};
  else if (id in schedules) return;
  create(node, id, {
    name: name,
    index: index, // For context during callback.
    group: group, // For context during callback.
    on: emptyOn,
    tween: emptyTween,
    time: timing.time,
    delay: timing.delay,
    duration: timing.duration,
    ease: timing.ease,
    timer: null,
    state: CREATED
  });
});

function init(node, id) {
  var schedule = get(node, id);
  if (schedule.state > CREATED) throw new Error("too late; already scheduled");
  return schedule;
}

function set(node, id) {
  var schedule = get(node, id);
  if (schedule.state > STARTED) throw new Error("too late; already running");
  return schedule;
}

function get(node, id) {
  var schedule = node.__transition;
  if (!schedule || !(schedule = schedule[id])) throw new Error("transition not found");
  return schedule;
}

function create(node, id, self) {
  var schedules = node.__transition,
      tween;

  // Initialize the self timer when the transition is created.
  // Note the actual delay is not known until the first callback!
  schedules[id] = self;
  self.timer = Object(d3_timer__WEBPACK_IMPORTED_MODULE_1__["timer"])(schedule, 0, self.time);

  function schedule(elapsed) {
    self.state = SCHEDULED;
    self.timer.restart(start, self.delay, self.time);

    // If the elapsed delay is less than our first sleep, start immediately.
    if (self.delay <= elapsed) start(elapsed - self.delay);
  }

  function start(elapsed) {
    var i, j, n, o;

    // If the state is not SCHEDULED, then we previously errored on start.
    if (self.state !== SCHEDULED) return stop();

    for (i in schedules) {
      o = schedules[i];
      if (o.name !== self.name) continue;

      // While this element already has a starting transition during this frame,
      // defer starting an interrupting transition until that transition has a
      // chance to tick (and possibly end); see d3/d3-transition#54!
      if (o.state === STARTED) return Object(d3_timer__WEBPACK_IMPORTED_MODULE_1__["timeout"])(start);

      // Interrupt the active transition, if any.
      if (o.state === RUNNING) {
        o.state = ENDED;
        o.timer.stop();
        o.on.call("interrupt", node, node.__data__, o.index, o.group);
        delete schedules[i];
      }

      // Cancel any pre-empted transitions.
      else if (+i < id) {
        o.state = ENDED;
        o.timer.stop();
        o.on.call("cancel", node, node.__data__, o.index, o.group);
        delete schedules[i];
      }
    }

    // Defer the first tick to end of the current frame; see d3/d3#1576.
    // Note the transition may be canceled after start and before the first tick!
    // Note this must be scheduled before the start event; see d3/d3-transition#16!
    // Assuming this is successful, subsequent callbacks go straight to tick.
    Object(d3_timer__WEBPACK_IMPORTED_MODULE_1__["timeout"])(function() {
      if (self.state === STARTED) {
        self.state = RUNNING;
        self.timer.restart(tick, self.delay, self.time);
        tick(elapsed);
      }
    });

    // Dispatch the start event.
    // Note this must be done before the tween are initialized.
    self.state = STARTING;
    self.on.call("start", node, node.__data__, self.index, self.group);
    if (self.state !== STARTING) return; // interrupted
    self.state = STARTED;

    // Initialize the tween, deleting null tween.
    tween = new Array(n = self.tween.length);
    for (i = 0, j = -1; i < n; ++i) {
      if (o = self.tween[i].value.call(node, node.__data__, self.index, self.group)) {
        tween[++j] = o;
      }
    }
    tween.length = j + 1;
  }

  function tick(elapsed) {
    var t = elapsed < self.duration ? self.ease.call(null, elapsed / self.duration) : (self.timer.restart(stop), self.state = ENDING, 1),
        i = -1,
        n = tween.length;

    while (++i < n) {
      tween[i].call(node, t);
    }

    // Dispatch the end event.
    if (self.state === ENDING) {
      self.on.call("end", node, node.__data__, self.index, self.group);
      stop();
    }
  }

  function stop() {
    self.state = ENDED;
    self.timer.stop();
    delete schedules[id];
    for (var i in schedules) return; // eslint-disable-line no-unused-vars
    delete node.__transition;
  }
}


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/select.js":
/*!*****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/select.js ***!
  \*****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js");
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");




/* harmony default export */ __webpack_exports__["default"] = (function(select) {
  var name = this._name,
      id = this._id;

  if (typeof select !== "function") select = Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["selector"])(select);

  for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, subgroup = subgroups[j] = new Array(n), node, subnode, i = 0; i < n; ++i) {
      if ((node = group[i]) && (subnode = select.call(node, node.__data__, i, group))) {
        if ("__data__" in node) subnode.__data__ = node.__data__;
        subgroup[i] = subnode;
        Object(_schedule_js__WEBPACK_IMPORTED_MODULE_2__["default"])(subgroup[i], name, id, i, subgroup, Object(_schedule_js__WEBPACK_IMPORTED_MODULE_2__["get"])(node, id));
      }
    }
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_1__["Transition"](subgroups, this._parents, name, id);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/selectAll.js":
/*!********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/selectAll.js ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js");
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");




/* harmony default export */ __webpack_exports__["default"] = (function(select) {
  var name = this._name,
      id = this._id;

  if (typeof select !== "function") select = Object(d3_selection__WEBPACK_IMPORTED_MODULE_0__["selectorAll"])(select);

  for (var groups = this._groups, m = groups.length, subgroups = [], parents = [], j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {
      if (node = group[i]) {
        for (var children = select.call(node, node.__data__, i, group), child, inherit = Object(_schedule_js__WEBPACK_IMPORTED_MODULE_2__["get"])(node, id), k = 0, l = children.length; k < l; ++k) {
          if (child = children[k]) {
            Object(_schedule_js__WEBPACK_IMPORTED_MODULE_2__["default"])(child, name, id, k, children, inherit);
          }
        }
        subgroups.push(children);
        parents.push(node);
      }
    }
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_1__["Transition"](subgroups, parents, name, id);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/selection.js":
/*!********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/selection.js ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");


var Selection = d3_selection__WEBPACK_IMPORTED_MODULE_0__["selection"].prototype.constructor;

/* harmony default export */ __webpack_exports__["default"] = (function() {
  return new Selection(this._groups, this._parents);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/style.js":
/*!****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/style.js ***!
  \****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var d3_interpolate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! d3-interpolate */ "./node_modules/d3-flame-graph/node_modules/d3-interpolate/src/index.js");
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");
/* harmony import */ var _tween_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./tween.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/tween.js");
/* harmony import */ var _interpolate_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./interpolate.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/interpolate.js");






function styleNull(name, interpolate) {
  var string00,
      string10,
      interpolate0;
  return function() {
    var string0 = Object(d3_selection__WEBPACK_IMPORTED_MODULE_1__["style"])(this, name),
        string1 = (this.style.removeProperty(name), Object(d3_selection__WEBPACK_IMPORTED_MODULE_1__["style"])(this, name));
    return string0 === string1 ? null
        : string0 === string00 && string1 === string10 ? interpolate0
        : interpolate0 = interpolate(string00 = string0, string10 = string1);
  };
}

function styleRemove(name) {
  return function() {
    this.style.removeProperty(name);
  };
}

function styleConstant(name, interpolate, value1) {
  var string00,
      string1 = value1 + "",
      interpolate0;
  return function() {
    var string0 = Object(d3_selection__WEBPACK_IMPORTED_MODULE_1__["style"])(this, name);
    return string0 === string1 ? null
        : string0 === string00 ? interpolate0
        : interpolate0 = interpolate(string00 = string0, value1);
  };
}

function styleFunction(name, interpolate, value) {
  var string00,
      string10,
      interpolate0;
  return function() {
    var string0 = Object(d3_selection__WEBPACK_IMPORTED_MODULE_1__["style"])(this, name),
        value1 = value(this),
        string1 = value1 + "";
    if (value1 == null) string1 = value1 = (this.style.removeProperty(name), Object(d3_selection__WEBPACK_IMPORTED_MODULE_1__["style"])(this, name));
    return string0 === string1 ? null
        : string0 === string00 && string1 === string10 ? interpolate0
        : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));
  };
}

function styleMaybeRemove(id, name) {
  var on0, on1, listener0, key = "style." + name, event = "end." + key, remove;
  return function() {
    var schedule = Object(_schedule_js__WEBPACK_IMPORTED_MODULE_2__["set"])(this, id),
        on = schedule.on,
        listener = schedule.value[key] == null ? remove || (remove = styleRemove(name)) : undefined;

    // If this node shared a dispatch with the previous node,
    // just assign the updated shared dispatch and we’re done!
    // Otherwise, copy-on-write.
    if (on !== on0 || listener0 !== listener) (on1 = (on0 = on).copy()).on(event, listener0 = listener);

    schedule.on = on1;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value, priority) {
  var i = (name += "") === "transform" ? d3_interpolate__WEBPACK_IMPORTED_MODULE_0__["interpolateTransformCss"] : _interpolate_js__WEBPACK_IMPORTED_MODULE_4__["default"];
  return value == null ? this
      .styleTween(name, styleNull(name, i))
      .on("end.style." + name, styleRemove(name))
    : typeof value === "function" ? this
      .styleTween(name, styleFunction(name, i, Object(_tween_js__WEBPACK_IMPORTED_MODULE_3__["tweenValue"])(this, "style." + name, value)))
      .each(styleMaybeRemove(this._id, name))
    : this
      .styleTween(name, styleConstant(name, i, value), priority)
      .on("end.style." + name, null);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/styleTween.js":
/*!*********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/styleTween.js ***!
  \*********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function styleInterpolate(name, i, priority) {
  return function(t) {
    this.style.setProperty(name, i.call(this, t), priority);
  };
}

function styleTween(name, value, priority) {
  var t, i0;
  function tween() {
    var i = value.apply(this, arguments);
    if (i !== i0) t = (i0 = i) && styleInterpolate(name, i, priority);
    return t;
  }
  tween._value = value;
  return tween;
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value, priority) {
  var key = "style." + (name += "");
  if (arguments.length < 2) return (key = this.tween(key)) && key._value;
  if (value == null) return this.tween(key, null);
  if (typeof value !== "function") throw new Error;
  return this.tween(key, styleTween(name, value, priority == null ? "" : priority));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/text.js":
/*!***************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/text.js ***!
  \***************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _tween_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./tween.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/tween.js");


function textConstant(value) {
  return function() {
    this.textContent = value;
  };
}

function textFunction(value) {
  return function() {
    var value1 = value(this);
    this.textContent = value1 == null ? "" : value1;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  return this.tween("text", typeof value === "function"
      ? textFunction(Object(_tween_js__WEBPACK_IMPORTED_MODULE_0__["tweenValue"])(this, "text", value))
      : textConstant(value == null ? "" : value + ""));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/textTween.js":
/*!********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/textTween.js ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function textInterpolate(i) {
  return function(t) {
    this.textContent = i.call(this, t);
  };
}

function textTween(value) {
  var t0, i0;
  function tween() {
    var i = value.apply(this, arguments);
    if (i !== i0) t0 = (i0 = i) && textInterpolate(i);
    return t0;
  }
  tween._value = value;
  return tween;
}

/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  var key = "text";
  if (arguments.length < 1) return (key = this.tween(key)) && key._value;
  if (value == null) return this.tween(key, null);
  if (typeof value !== "function") throw new Error;
  return this.tween(key, textTween(value));
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/transition.js":
/*!*********************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/transition.js ***!
  \*********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/index.js");
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");



/* harmony default export */ __webpack_exports__["default"] = (function() {
  var name = this._name,
      id0 = this._id,
      id1 = Object(_index_js__WEBPACK_IMPORTED_MODULE_0__["newId"])();

  for (var groups = this._groups, m = groups.length, j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {
      if (node = group[i]) {
        var inherit = Object(_schedule_js__WEBPACK_IMPORTED_MODULE_1__["get"])(node, id0);
        Object(_schedule_js__WEBPACK_IMPORTED_MODULE_1__["default"])(node, name, id1, i, group, {
          time: inherit.time + inherit.delay + inherit.duration,
          delay: 0,
          duration: inherit.duration,
          ease: inherit.ease
        });
      }
    }
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_0__["Transition"](groups, this._parents, name, id1);
});


/***/ }),

/***/ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/tween.js":
/*!****************************************************************************************!*\
  !*** ./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/tween.js ***!
  \****************************************************************************************/
/*! exports provided: default, tweenValue */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "tweenValue", function() { return tweenValue; });
/* harmony import */ var _schedule_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./schedule.js */ "./node_modules/d3-flame-graph/node_modules/d3-transition/src/transition/schedule.js");


function tweenRemove(id, name) {
  var tween0, tween1;
  return function() {
    var schedule = Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"])(this, id),
        tween = schedule.tween;

    // If this node shared tween with the previous node,
    // just assign the updated shared tween and we’re done!
    // Otherwise, copy-on-write.
    if (tween !== tween0) {
      tween1 = tween0 = tween;
      for (var i = 0, n = tween1.length; i < n; ++i) {
        if (tween1[i].name === name) {
          tween1 = tween1.slice();
          tween1.splice(i, 1);
          break;
        }
      }
    }

    schedule.tween = tween1;
  };
}

function tweenFunction(id, name, value) {
  var tween0, tween1;
  if (typeof value !== "function") throw new Error;
  return function() {
    var schedule = Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"])(this, id),
        tween = schedule.tween;

    // If this node shared tween with the previous node,
    // just assign the updated shared tween and we’re done!
    // Otherwise, copy-on-write.
    if (tween !== tween0) {
      tween1 = (tween0 = tween).slice();
      for (var t = {name: name, value: value}, i = 0, n = tween1.length; i < n; ++i) {
        if (tween1[i].name === name) {
          tween1[i] = t;
          break;
        }
      }
      if (i === n) tween1.push(t);
    }

    schedule.tween = tween1;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value) {
  var id = this._id;

  name += "";

  if (arguments.length < 2) {
    var tween = Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["get"])(this.node(), id).tween;
    for (var i = 0, n = tween.length, t; i < n; ++i) {
      if ((t = tween[i]).name === name) {
        return t.value;
      }
    }
    return null;
  }

  return this.each((value == null ? tweenRemove : tweenFunction)(id, name, value));
});

function tweenValue(transition, name, value) {
  var id = transition._id;

  transition.each(function() {
    var schedule = Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["set"])(this, id);
    (schedule.value || (schedule.value = {}))[name] = value.apply(this, arguments);
  });

  return function(node) {
    return Object(_schedule_js__WEBPACK_IMPORTED_MODULE_0__["get"])(node, id).value[name];
  };
}


/***/ }),

/***/ "./node_modules/d3-selection/src/array.js":
/*!************************************************!*\
  !*** ./node_modules/d3-selection/src/array.js ***!
  \************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return array; });
// Given something array like (or null), returns something that is strictly an
// array. This is used to ensure that array-like objects passed to d3.selectAll
// or selection.selectAll are converted into proper arrays when creating a
// selection; we don’t ever want to create a selection backed by a live
// HTMLCollection or NodeList. However, note that selection.selectAll will use a
// static NodeList as a group, since it safely derived from querySelectorAll.
function array(x) {
  return x == null ? [] : Array.isArray(x) ? x : Array.from(x);
}


/***/ }),

/***/ "./node_modules/d3-selection/src/constant.js":
/*!***************************************************!*\
  !*** ./node_modules/d3-selection/src/constant.js ***!
  \***************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(x) {
  return function() {
    return x;
  };
});


/***/ }),

/***/ "./node_modules/d3-selection/src/create.js":
/*!*************************************************!*\
  !*** ./node_modules/d3-selection/src/create.js ***!
  \*************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _creator_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./creator.js */ "./node_modules/d3-selection/src/creator.js");
/* harmony import */ var _select_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./select.js */ "./node_modules/d3-selection/src/select.js");



/* harmony default export */ __webpack_exports__["default"] = (function(name) {
  return Object(_select_js__WEBPACK_IMPORTED_MODULE_1__["default"])(Object(_creator_js__WEBPACK_IMPORTED_MODULE_0__["default"])(name).call(document.documentElement));
});


/***/ }),

/***/ "./node_modules/d3-selection/src/creator.js":
/*!**************************************************!*\
  !*** ./node_modules/d3-selection/src/creator.js ***!
  \**************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _namespace_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./namespace.js */ "./node_modules/d3-selection/src/namespace.js");
/* harmony import */ var _namespaces_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./namespaces.js */ "./node_modules/d3-selection/src/namespaces.js");



function creatorInherit(name) {
  return function() {
    var document = this.ownerDocument,
        uri = this.namespaceURI;
    return uri === _namespaces_js__WEBPACK_IMPORTED_MODULE_1__["xhtml"] && document.documentElement.namespaceURI === _namespaces_js__WEBPACK_IMPORTED_MODULE_1__["xhtml"]
        ? document.createElement(name)
        : document.createElementNS(uri, name);
  };
}

function creatorFixed(fullname) {
  return function() {
    return this.ownerDocument.createElementNS(fullname.space, fullname.local);
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name) {
  var fullname = Object(_namespace_js__WEBPACK_IMPORTED_MODULE_0__["default"])(name);
  return (fullname.local
      ? creatorFixed
      : creatorInherit)(fullname);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/index.js":
/*!************************************************!*\
  !*** ./node_modules/d3-selection/src/index.js ***!
  \************************************************/
/*! exports provided: create, creator, local, matcher, namespace, namespaces, pointer, pointers, select, selectAll, selection, selector, selectorAll, style, window */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _create_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./create.js */ "./node_modules/d3-selection/src/create.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "create", function() { return _create_js__WEBPACK_IMPORTED_MODULE_0__["default"]; });

/* harmony import */ var _creator_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./creator.js */ "./node_modules/d3-selection/src/creator.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "creator", function() { return _creator_js__WEBPACK_IMPORTED_MODULE_1__["default"]; });

/* harmony import */ var _local_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./local.js */ "./node_modules/d3-selection/src/local.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "local", function() { return _local_js__WEBPACK_IMPORTED_MODULE_2__["default"]; });

/* harmony import */ var _matcher_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./matcher.js */ "./node_modules/d3-selection/src/matcher.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "matcher", function() { return _matcher_js__WEBPACK_IMPORTED_MODULE_3__["default"]; });

/* harmony import */ var _namespace_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./namespace.js */ "./node_modules/d3-selection/src/namespace.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "namespace", function() { return _namespace_js__WEBPACK_IMPORTED_MODULE_4__["default"]; });

/* harmony import */ var _namespaces_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./namespaces.js */ "./node_modules/d3-selection/src/namespaces.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "namespaces", function() { return _namespaces_js__WEBPACK_IMPORTED_MODULE_5__["default"]; });

/* harmony import */ var _pointer_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./pointer.js */ "./node_modules/d3-selection/src/pointer.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "pointer", function() { return _pointer_js__WEBPACK_IMPORTED_MODULE_6__["default"]; });

/* harmony import */ var _pointers_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./pointers.js */ "./node_modules/d3-selection/src/pointers.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "pointers", function() { return _pointers_js__WEBPACK_IMPORTED_MODULE_7__["default"]; });

/* harmony import */ var _select_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./select.js */ "./node_modules/d3-selection/src/select.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "select", function() { return _select_js__WEBPACK_IMPORTED_MODULE_8__["default"]; });

/* harmony import */ var _selectAll_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./selectAll.js */ "./node_modules/d3-selection/src/selectAll.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "selectAll", function() { return _selectAll_js__WEBPACK_IMPORTED_MODULE_9__["default"]; });

/* harmony import */ var _selection_index_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./selection/index.js */ "./node_modules/d3-selection/src/selection/index.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "selection", function() { return _selection_index_js__WEBPACK_IMPORTED_MODULE_10__["default"]; });

/* harmony import */ var _selector_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./selector.js */ "./node_modules/d3-selection/src/selector.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "selector", function() { return _selector_js__WEBPACK_IMPORTED_MODULE_11__["default"]; });

/* harmony import */ var _selectorAll_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./selectorAll.js */ "./node_modules/d3-selection/src/selectorAll.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "selectorAll", function() { return _selectorAll_js__WEBPACK_IMPORTED_MODULE_12__["default"]; });

/* harmony import */ var _selection_style_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./selection/style.js */ "./node_modules/d3-selection/src/selection/style.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "style", function() { return _selection_style_js__WEBPACK_IMPORTED_MODULE_13__["styleValue"]; });

/* harmony import */ var _window_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./window.js */ "./node_modules/d3-selection/src/window.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "window", function() { return _window_js__WEBPACK_IMPORTED_MODULE_14__["default"]; });


















/***/ }),

/***/ "./node_modules/d3-selection/src/local.js":
/*!************************************************!*\
  !*** ./node_modules/d3-selection/src/local.js ***!
  \************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return local; });
var nextId = 0;

function local() {
  return new Local;
}

function Local() {
  this._ = "@" + (++nextId).toString(36);
}

Local.prototype = local.prototype = {
  constructor: Local,
  get: function(node) {
    var id = this._;
    while (!(id in node)) if (!(node = node.parentNode)) return;
    return node[id];
  },
  set: function(node, value) {
    return node[this._] = value;
  },
  remove: function(node) {
    return this._ in node && delete node[this._];
  },
  toString: function() {
    return this._;
  }
};


/***/ }),

/***/ "./node_modules/d3-selection/src/matcher.js":
/*!**************************************************!*\
  !*** ./node_modules/d3-selection/src/matcher.js ***!
  \**************************************************/
/*! exports provided: default, childMatcher */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "childMatcher", function() { return childMatcher; });
/* harmony default export */ __webpack_exports__["default"] = (function(selector) {
  return function() {
    return this.matches(selector);
  };
});

function childMatcher(selector) {
  return function(node) {
    return node.matches(selector);
  };
}



/***/ }),

/***/ "./node_modules/d3-selection/src/namespace.js":
/*!****************************************************!*\
  !*** ./node_modules/d3-selection/src/namespace.js ***!
  \****************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _namespaces_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./namespaces.js */ "./node_modules/d3-selection/src/namespaces.js");


/* harmony default export */ __webpack_exports__["default"] = (function(name) {
  var prefix = name += "", i = prefix.indexOf(":");
  if (i >= 0 && (prefix = name.slice(0, i)) !== "xmlns") name = name.slice(i + 1);
  return _namespaces_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProperty(prefix) ? {space: _namespaces_js__WEBPACK_IMPORTED_MODULE_0__["default"][prefix], local: name} : name; // eslint-disable-line no-prototype-builtins
});


/***/ }),

/***/ "./node_modules/d3-selection/src/namespaces.js":
/*!*****************************************************!*\
  !*** ./node_modules/d3-selection/src/namespaces.js ***!
  \*****************************************************/
/*! exports provided: xhtml, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "xhtml", function() { return xhtml; });
var xhtml = "http://www.w3.org/1999/xhtml";

/* harmony default export */ __webpack_exports__["default"] = ({
  svg: "http://www.w3.org/2000/svg",
  xhtml: xhtml,
  xlink: "http://www.w3.org/1999/xlink",
  xml: "http://www.w3.org/XML/1998/namespace",
  xmlns: "http://www.w3.org/2000/xmlns/"
});


/***/ }),

/***/ "./node_modules/d3-selection/src/pointer.js":
/*!**************************************************!*\
  !*** ./node_modules/d3-selection/src/pointer.js ***!
  \**************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _sourceEvent_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./sourceEvent.js */ "./node_modules/d3-selection/src/sourceEvent.js");


/* harmony default export */ __webpack_exports__["default"] = (function(event, node) {
  event = Object(_sourceEvent_js__WEBPACK_IMPORTED_MODULE_0__["default"])(event);
  if (node === undefined) node = event.currentTarget;
  if (node) {
    var svg = node.ownerSVGElement || node;
    if (svg.createSVGPoint) {
      var point = svg.createSVGPoint();
      point.x = event.clientX, point.y = event.clientY;
      point = point.matrixTransform(node.getScreenCTM().inverse());
      return [point.x, point.y];
    }
    if (node.getBoundingClientRect) {
      var rect = node.getBoundingClientRect();
      return [event.clientX - rect.left - node.clientLeft, event.clientY - rect.top - node.clientTop];
    }
  }
  return [event.pageX, event.pageY];
});


/***/ }),

/***/ "./node_modules/d3-selection/src/pointers.js":
/*!***************************************************!*\
  !*** ./node_modules/d3-selection/src/pointers.js ***!
  \***************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _pointer_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./pointer.js */ "./node_modules/d3-selection/src/pointer.js");
/* harmony import */ var _sourceEvent_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./sourceEvent.js */ "./node_modules/d3-selection/src/sourceEvent.js");



/* harmony default export */ __webpack_exports__["default"] = (function(events, node) {
  if (events.target) { // i.e., instanceof Event, not TouchList or iterable
    events = Object(_sourceEvent_js__WEBPACK_IMPORTED_MODULE_1__["default"])(events);
    if (node === undefined) node = events.currentTarget;
    events = events.touches || [events];
  }
  return Array.from(events, event => Object(_pointer_js__WEBPACK_IMPORTED_MODULE_0__["default"])(event, node));
});


/***/ }),

/***/ "./node_modules/d3-selection/src/select.js":
/*!*************************************************!*\
  !*** ./node_modules/d3-selection/src/select.js ***!
  \*************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _selection_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./selection/index.js */ "./node_modules/d3-selection/src/selection/index.js");


/* harmony default export */ __webpack_exports__["default"] = (function(selector) {
  return typeof selector === "string"
      ? new _selection_index_js__WEBPACK_IMPORTED_MODULE_0__["Selection"]([[document.querySelector(selector)]], [document.documentElement])
      : new _selection_index_js__WEBPACK_IMPORTED_MODULE_0__["Selection"]([[selector]], _selection_index_js__WEBPACK_IMPORTED_MODULE_0__["root"]);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selectAll.js":
/*!****************************************************!*\
  !*** ./node_modules/d3-selection/src/selectAll.js ***!
  \****************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _array_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./array.js */ "./node_modules/d3-selection/src/array.js");
/* harmony import */ var _selection_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./selection/index.js */ "./node_modules/d3-selection/src/selection/index.js");



/* harmony default export */ __webpack_exports__["default"] = (function(selector) {
  return typeof selector === "string"
      ? new _selection_index_js__WEBPACK_IMPORTED_MODULE_1__["Selection"]([document.querySelectorAll(selector)], [document.documentElement])
      : new _selection_index_js__WEBPACK_IMPORTED_MODULE_1__["Selection"]([Object(_array_js__WEBPACK_IMPORTED_MODULE_0__["default"])(selector)], _selection_index_js__WEBPACK_IMPORTED_MODULE_1__["root"]);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/append.js":
/*!***********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/append.js ***!
  \***********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _creator_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../creator.js */ "./node_modules/d3-selection/src/creator.js");


/* harmony default export */ __webpack_exports__["default"] = (function(name) {
  var create = typeof name === "function" ? name : Object(_creator_js__WEBPACK_IMPORTED_MODULE_0__["default"])(name);
  return this.select(function() {
    return this.appendChild(create.apply(this, arguments));
  });
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/attr.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/attr.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _namespace_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../namespace.js */ "./node_modules/d3-selection/src/namespace.js");


function attrRemove(name) {
  return function() {
    this.removeAttribute(name);
  };
}

function attrRemoveNS(fullname) {
  return function() {
    this.removeAttributeNS(fullname.space, fullname.local);
  };
}

function attrConstant(name, value) {
  return function() {
    this.setAttribute(name, value);
  };
}

function attrConstantNS(fullname, value) {
  return function() {
    this.setAttributeNS(fullname.space, fullname.local, value);
  };
}

function attrFunction(name, value) {
  return function() {
    var v = value.apply(this, arguments);
    if (v == null) this.removeAttribute(name);
    else this.setAttribute(name, v);
  };
}

function attrFunctionNS(fullname, value) {
  return function() {
    var v = value.apply(this, arguments);
    if (v == null) this.removeAttributeNS(fullname.space, fullname.local);
    else this.setAttributeNS(fullname.space, fullname.local, v);
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value) {
  var fullname = Object(_namespace_js__WEBPACK_IMPORTED_MODULE_0__["default"])(name);

  if (arguments.length < 2) {
    var node = this.node();
    return fullname.local
        ? node.getAttributeNS(fullname.space, fullname.local)
        : node.getAttribute(fullname);
  }

  return this.each((value == null
      ? (fullname.local ? attrRemoveNS : attrRemove) : (typeof value === "function"
      ? (fullname.local ? attrFunctionNS : attrFunction)
      : (fullname.local ? attrConstantNS : attrConstant)))(fullname, value));
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/call.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/call.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {
  var callback = arguments[0];
  arguments[0] = this;
  callback.apply(null, arguments);
  return this;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/classed.js":
/*!************************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/classed.js ***!
  \************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function classArray(string) {
  return string.trim().split(/^|\s+/);
}

function classList(node) {
  return node.classList || new ClassList(node);
}

function ClassList(node) {
  this._node = node;
  this._names = classArray(node.getAttribute("class") || "");
}

ClassList.prototype = {
  add: function(name) {
    var i = this._names.indexOf(name);
    if (i < 0) {
      this._names.push(name);
      this._node.setAttribute("class", this._names.join(" "));
    }
  },
  remove: function(name) {
    var i = this._names.indexOf(name);
    if (i >= 0) {
      this._names.splice(i, 1);
      this._node.setAttribute("class", this._names.join(" "));
    }
  },
  contains: function(name) {
    return this._names.indexOf(name) >= 0;
  }
};

function classedAdd(node, names) {
  var list = classList(node), i = -1, n = names.length;
  while (++i < n) list.add(names[i]);
}

function classedRemove(node, names) {
  var list = classList(node), i = -1, n = names.length;
  while (++i < n) list.remove(names[i]);
}

function classedTrue(names) {
  return function() {
    classedAdd(this, names);
  };
}

function classedFalse(names) {
  return function() {
    classedRemove(this, names);
  };
}

function classedFunction(names, value) {
  return function() {
    (value.apply(this, arguments) ? classedAdd : classedRemove)(this, names);
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value) {
  var names = classArray(name + "");

  if (arguments.length < 2) {
    var list = classList(this.node()), i = -1, n = names.length;
    while (++i < n) if (!list.contains(names[i])) return false;
    return true;
  }

  return this.each((typeof value === "function"
      ? classedFunction : value
      ? classedTrue
      : classedFalse)(names, value));
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/clone.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/clone.js ***!
  \**********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function selection_cloneShallow() {
  var clone = this.cloneNode(false), parent = this.parentNode;
  return parent ? parent.insertBefore(clone, this.nextSibling) : clone;
}

function selection_cloneDeep() {
  var clone = this.cloneNode(true), parent = this.parentNode;
  return parent ? parent.insertBefore(clone, this.nextSibling) : clone;
}

/* harmony default export */ __webpack_exports__["default"] = (function(deep) {
  return this.select(deep ? selection_cloneDeep : selection_cloneShallow);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/data.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/data.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-selection/src/selection/index.js");
/* harmony import */ var _enter_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./enter.js */ "./node_modules/d3-selection/src/selection/enter.js");
/* harmony import */ var _constant_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../constant.js */ "./node_modules/d3-selection/src/constant.js");




function bindIndex(parent, group, enter, update, exit, data) {
  var i = 0,
      node,
      groupLength = group.length,
      dataLength = data.length;

  // Put any non-null nodes that fit into update.
  // Put any null nodes into enter.
  // Put any remaining data into enter.
  for (; i < dataLength; ++i) {
    if (node = group[i]) {
      node.__data__ = data[i];
      update[i] = node;
    } else {
      enter[i] = new _enter_js__WEBPACK_IMPORTED_MODULE_1__["EnterNode"](parent, data[i]);
    }
  }

  // Put any non-null nodes that don’t fit into exit.
  for (; i < groupLength; ++i) {
    if (node = group[i]) {
      exit[i] = node;
    }
  }
}

function bindKey(parent, group, enter, update, exit, data, key) {
  var i,
      node,
      nodeByKeyValue = new Map,
      groupLength = group.length,
      dataLength = data.length,
      keyValues = new Array(groupLength),
      keyValue;

  // Compute the key for each node.
  // If multiple nodes have the same key, the duplicates are added to exit.
  for (i = 0; i < groupLength; ++i) {
    if (node = group[i]) {
      keyValues[i] = keyValue = key.call(node, node.__data__, i, group) + "";
      if (nodeByKeyValue.has(keyValue)) {
        exit[i] = node;
      } else {
        nodeByKeyValue.set(keyValue, node);
      }
    }
  }

  // Compute the key for each datum.
  // If there a node associated with this key, join and add it to update.
  // If there is not (or the key is a duplicate), add it to enter.
  for (i = 0; i < dataLength; ++i) {
    keyValue = key.call(parent, data[i], i, data) + "";
    if (node = nodeByKeyValue.get(keyValue)) {
      update[i] = node;
      node.__data__ = data[i];
      nodeByKeyValue.delete(keyValue);
    } else {
      enter[i] = new _enter_js__WEBPACK_IMPORTED_MODULE_1__["EnterNode"](parent, data[i]);
    }
  }

  // Add any remaining nodes that were not bound to data to exit.
  for (i = 0; i < groupLength; ++i) {
    if ((node = group[i]) && (nodeByKeyValue.get(keyValues[i]) === node)) {
      exit[i] = node;
    }
  }
}

function datum(node) {
  return node.__data__;
}

/* harmony default export */ __webpack_exports__["default"] = (function(value, key) {
  if (!arguments.length) return Array.from(this, datum);

  var bind = key ? bindKey : bindIndex,
      parents = this._parents,
      groups = this._groups;

  if (typeof value !== "function") value = Object(_constant_js__WEBPACK_IMPORTED_MODULE_2__["default"])(value);

  for (var m = groups.length, update = new Array(m), enter = new Array(m), exit = new Array(m), j = 0; j < m; ++j) {
    var parent = parents[j],
        group = groups[j],
        groupLength = group.length,
        data = arraylike(value.call(parent, parent && parent.__data__, j, parents)),
        dataLength = data.length,
        enterGroup = enter[j] = new Array(dataLength),
        updateGroup = update[j] = new Array(dataLength),
        exitGroup = exit[j] = new Array(groupLength);

    bind(parent, group, enterGroup, updateGroup, exitGroup, data, key);

    // Now connect the enter nodes to their following update node, such that
    // appendChild can insert the materialized enter node before this node,
    // rather than at the end of the parent node.
    for (var i0 = 0, i1 = 0, previous, next; i0 < dataLength; ++i0) {
      if (previous = enterGroup[i0]) {
        if (i0 >= i1) i1 = i0 + 1;
        while (!(next = updateGroup[i1]) && ++i1 < dataLength);
        previous._next = next || null;
      }
    }
  }

  update = new _index_js__WEBPACK_IMPORTED_MODULE_0__["Selection"](update, parents);
  update._enter = enter;
  update._exit = exit;
  return update;
});

// Given some data, this returns an array-like view of it: an object that
// exposes a length property and allows numeric indexing. Note that unlike
// selectAll, this isn’t worried about “live” collections because the resulting
// array will only be used briefly while data is being bound. (It is possible to
// cause the data to change while iterating by using a key function, but please
// don’t; we’d rather avoid a gratuitous copy.)
function arraylike(data) {
  return typeof data === "object" && "length" in data
    ? data // Array, TypedArray, NodeList, array-like
    : Array.from(data); // Map, Set, iterable, string, or anything else
}


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/datum.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/datum.js ***!
  \**********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  return arguments.length
      ? this.property("__data__", value)
      : this.node().__data__;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/dispatch.js":
/*!*************************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/dispatch.js ***!
  \*************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _window_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../window.js */ "./node_modules/d3-selection/src/window.js");


function dispatchEvent(node, type, params) {
  var window = Object(_window_js__WEBPACK_IMPORTED_MODULE_0__["default"])(node),
      event = window.CustomEvent;

  if (typeof event === "function") {
    event = new event(type, params);
  } else {
    event = window.document.createEvent("Event");
    if (params) event.initEvent(type, params.bubbles, params.cancelable), event.detail = params.detail;
    else event.initEvent(type, false, false);
  }

  node.dispatchEvent(event);
}

function dispatchConstant(type, params) {
  return function() {
    return dispatchEvent(this, type, params);
  };
}

function dispatchFunction(type, params) {
  return function() {
    return dispatchEvent(this, type, params.apply(this, arguments));
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(type, params) {
  return this.each((typeof params === "function"
      ? dispatchFunction
      : dispatchConstant)(type, params));
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/each.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/each.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(callback) {

  for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {
    for (var group = groups[j], i = 0, n = group.length, node; i < n; ++i) {
      if (node = group[i]) callback.call(node, node.__data__, i, group);
    }
  }

  return this;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/empty.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/empty.js ***!
  \**********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {
  return !this.node();
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/enter.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/enter.js ***!
  \**********************************************************/
/*! exports provided: default, EnterNode */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "EnterNode", function() { return EnterNode; });
/* harmony import */ var _sparse_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./sparse.js */ "./node_modules/d3-selection/src/selection/sparse.js");
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-selection/src/selection/index.js");



/* harmony default export */ __webpack_exports__["default"] = (function() {
  return new _index_js__WEBPACK_IMPORTED_MODULE_1__["Selection"](this._enter || this._groups.map(_sparse_js__WEBPACK_IMPORTED_MODULE_0__["default"]), this._parents);
});

function EnterNode(parent, datum) {
  this.ownerDocument = parent.ownerDocument;
  this.namespaceURI = parent.namespaceURI;
  this._next = null;
  this._parent = parent;
  this.__data__ = datum;
}

EnterNode.prototype = {
  constructor: EnterNode,
  appendChild: function(child) { return this._parent.insertBefore(child, this._next); },
  insertBefore: function(child, next) { return this._parent.insertBefore(child, next); },
  querySelector: function(selector) { return this._parent.querySelector(selector); },
  querySelectorAll: function(selector) { return this._parent.querySelectorAll(selector); }
};


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/exit.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/exit.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _sparse_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./sparse.js */ "./node_modules/d3-selection/src/selection/sparse.js");
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-selection/src/selection/index.js");



/* harmony default export */ __webpack_exports__["default"] = (function() {
  return new _index_js__WEBPACK_IMPORTED_MODULE_1__["Selection"](this._exit || this._groups.map(_sparse_js__WEBPACK_IMPORTED_MODULE_0__["default"]), this._parents);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/filter.js":
/*!***********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/filter.js ***!
  \***********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-selection/src/selection/index.js");
/* harmony import */ var _matcher_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../matcher.js */ "./node_modules/d3-selection/src/matcher.js");



/* harmony default export */ __webpack_exports__["default"] = (function(match) {
  if (typeof match !== "function") match = Object(_matcher_js__WEBPACK_IMPORTED_MODULE_1__["default"])(match);

  for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, subgroup = subgroups[j] = [], node, i = 0; i < n; ++i) {
      if ((node = group[i]) && match.call(node, node.__data__, i, group)) {
        subgroup.push(node);
      }
    }
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_0__["Selection"](subgroups, this._parents);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/html.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/html.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function htmlRemove() {
  this.innerHTML = "";
}

function htmlConstant(value) {
  return function() {
    this.innerHTML = value;
  };
}

function htmlFunction(value) {
  return function() {
    var v = value.apply(this, arguments);
    this.innerHTML = v == null ? "" : v;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  return arguments.length
      ? this.each(value == null
          ? htmlRemove : (typeof value === "function"
          ? htmlFunction
          : htmlConstant)(value))
      : this.node().innerHTML;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/index.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/index.js ***!
  \**********************************************************/
/*! exports provided: root, Selection, default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "root", function() { return root; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Selection", function() { return Selection; });
/* harmony import */ var _select_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./select.js */ "./node_modules/d3-selection/src/selection/select.js");
/* harmony import */ var _selectAll_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./selectAll.js */ "./node_modules/d3-selection/src/selection/selectAll.js");
/* harmony import */ var _selectChild_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./selectChild.js */ "./node_modules/d3-selection/src/selection/selectChild.js");
/* harmony import */ var _selectChildren_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./selectChildren.js */ "./node_modules/d3-selection/src/selection/selectChildren.js");
/* harmony import */ var _filter_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./filter.js */ "./node_modules/d3-selection/src/selection/filter.js");
/* harmony import */ var _data_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./data.js */ "./node_modules/d3-selection/src/selection/data.js");
/* harmony import */ var _enter_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./enter.js */ "./node_modules/d3-selection/src/selection/enter.js");
/* harmony import */ var _exit_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./exit.js */ "./node_modules/d3-selection/src/selection/exit.js");
/* harmony import */ var _join_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./join.js */ "./node_modules/d3-selection/src/selection/join.js");
/* harmony import */ var _merge_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./merge.js */ "./node_modules/d3-selection/src/selection/merge.js");
/* harmony import */ var _order_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./order.js */ "./node_modules/d3-selection/src/selection/order.js");
/* harmony import */ var _sort_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./sort.js */ "./node_modules/d3-selection/src/selection/sort.js");
/* harmony import */ var _call_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./call.js */ "./node_modules/d3-selection/src/selection/call.js");
/* harmony import */ var _nodes_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./nodes.js */ "./node_modules/d3-selection/src/selection/nodes.js");
/* harmony import */ var _node_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./node.js */ "./node_modules/d3-selection/src/selection/node.js");
/* harmony import */ var _size_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./size.js */ "./node_modules/d3-selection/src/selection/size.js");
/* harmony import */ var _empty_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./empty.js */ "./node_modules/d3-selection/src/selection/empty.js");
/* harmony import */ var _each_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./each.js */ "./node_modules/d3-selection/src/selection/each.js");
/* harmony import */ var _attr_js__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./attr.js */ "./node_modules/d3-selection/src/selection/attr.js");
/* harmony import */ var _style_js__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./style.js */ "./node_modules/d3-selection/src/selection/style.js");
/* harmony import */ var _property_js__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./property.js */ "./node_modules/d3-selection/src/selection/property.js");
/* harmony import */ var _classed_js__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ./classed.js */ "./node_modules/d3-selection/src/selection/classed.js");
/* harmony import */ var _text_js__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./text.js */ "./node_modules/d3-selection/src/selection/text.js");
/* harmony import */ var _html_js__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ./html.js */ "./node_modules/d3-selection/src/selection/html.js");
/* harmony import */ var _raise_js__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ./raise.js */ "./node_modules/d3-selection/src/selection/raise.js");
/* harmony import */ var _lower_js__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ./lower.js */ "./node_modules/d3-selection/src/selection/lower.js");
/* harmony import */ var _append_js__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ./append.js */ "./node_modules/d3-selection/src/selection/append.js");
/* harmony import */ var _insert_js__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./insert.js */ "./node_modules/d3-selection/src/selection/insert.js");
/* harmony import */ var _remove_js__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ./remove.js */ "./node_modules/d3-selection/src/selection/remove.js");
/* harmony import */ var _clone_js__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ./clone.js */ "./node_modules/d3-selection/src/selection/clone.js");
/* harmony import */ var _datum_js__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ./datum.js */ "./node_modules/d3-selection/src/selection/datum.js");
/* harmony import */ var _on_js__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! ./on.js */ "./node_modules/d3-selection/src/selection/on.js");
/* harmony import */ var _dispatch_js__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ./dispatch.js */ "./node_modules/d3-selection/src/selection/dispatch.js");
/* harmony import */ var _iterator_js__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! ./iterator.js */ "./node_modules/d3-selection/src/selection/iterator.js");



































var root = [null];

function Selection(groups, parents) {
  this._groups = groups;
  this._parents = parents;
}

function selection() {
  return new Selection([[document.documentElement]], root);
}

function selection_selection() {
  return this;
}

Selection.prototype = selection.prototype = {
  constructor: Selection,
  select: _select_js__WEBPACK_IMPORTED_MODULE_0__["default"],
  selectAll: _selectAll_js__WEBPACK_IMPORTED_MODULE_1__["default"],
  selectChild: _selectChild_js__WEBPACK_IMPORTED_MODULE_2__["default"],
  selectChildren: _selectChildren_js__WEBPACK_IMPORTED_MODULE_3__["default"],
  filter: _filter_js__WEBPACK_IMPORTED_MODULE_4__["default"],
  data: _data_js__WEBPACK_IMPORTED_MODULE_5__["default"],
  enter: _enter_js__WEBPACK_IMPORTED_MODULE_6__["default"],
  exit: _exit_js__WEBPACK_IMPORTED_MODULE_7__["default"],
  join: _join_js__WEBPACK_IMPORTED_MODULE_8__["default"],
  merge: _merge_js__WEBPACK_IMPORTED_MODULE_9__["default"],
  selection: selection_selection,
  order: _order_js__WEBPACK_IMPORTED_MODULE_10__["default"],
  sort: _sort_js__WEBPACK_IMPORTED_MODULE_11__["default"],
  call: _call_js__WEBPACK_IMPORTED_MODULE_12__["default"],
  nodes: _nodes_js__WEBPACK_IMPORTED_MODULE_13__["default"],
  node: _node_js__WEBPACK_IMPORTED_MODULE_14__["default"],
  size: _size_js__WEBPACK_IMPORTED_MODULE_15__["default"],
  empty: _empty_js__WEBPACK_IMPORTED_MODULE_16__["default"],
  each: _each_js__WEBPACK_IMPORTED_MODULE_17__["default"],
  attr: _attr_js__WEBPACK_IMPORTED_MODULE_18__["default"],
  style: _style_js__WEBPACK_IMPORTED_MODULE_19__["default"],
  property: _property_js__WEBPACK_IMPORTED_MODULE_20__["default"],
  classed: _classed_js__WEBPACK_IMPORTED_MODULE_21__["default"],
  text: _text_js__WEBPACK_IMPORTED_MODULE_22__["default"],
  html: _html_js__WEBPACK_IMPORTED_MODULE_23__["default"],
  raise: _raise_js__WEBPACK_IMPORTED_MODULE_24__["default"],
  lower: _lower_js__WEBPACK_IMPORTED_MODULE_25__["default"],
  append: _append_js__WEBPACK_IMPORTED_MODULE_26__["default"],
  insert: _insert_js__WEBPACK_IMPORTED_MODULE_27__["default"],
  remove: _remove_js__WEBPACK_IMPORTED_MODULE_28__["default"],
  clone: _clone_js__WEBPACK_IMPORTED_MODULE_29__["default"],
  datum: _datum_js__WEBPACK_IMPORTED_MODULE_30__["default"],
  on: _on_js__WEBPACK_IMPORTED_MODULE_31__["default"],
  dispatch: _dispatch_js__WEBPACK_IMPORTED_MODULE_32__["default"],
  [Symbol.iterator]: _iterator_js__WEBPACK_IMPORTED_MODULE_33__["default"]
};

/* harmony default export */ __webpack_exports__["default"] = (selection);


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/insert.js":
/*!***********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/insert.js ***!
  \***********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _creator_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../creator.js */ "./node_modules/d3-selection/src/creator.js");
/* harmony import */ var _selector_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../selector.js */ "./node_modules/d3-selection/src/selector.js");



function constantNull() {
  return null;
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, before) {
  var create = typeof name === "function" ? name : Object(_creator_js__WEBPACK_IMPORTED_MODULE_0__["default"])(name),
      select = before == null ? constantNull : typeof before === "function" ? before : Object(_selector_js__WEBPACK_IMPORTED_MODULE_1__["default"])(before);
  return this.select(function() {
    return this.insertBefore(create.apply(this, arguments), select.apply(this, arguments) || null);
  });
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/iterator.js":
/*!*************************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/iterator.js ***!
  \*************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function*() {
  for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {
    for (var group = groups[j], i = 0, n = group.length, node; i < n; ++i) {
      if (node = group[i]) yield node;
    }
  }
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/join.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/join.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(onenter, onupdate, onexit) {
  var enter = this.enter(), update = this, exit = this.exit();
  if (typeof onenter === "function") {
    enter = onenter(enter);
    if (enter) enter = enter.selection();
  } else {
    enter = enter.append(onenter + "");
  }
  if (onupdate != null) {
    update = onupdate(update);
    if (update) update = update.selection();
  }
  if (onexit == null) exit.remove(); else onexit(exit);
  return enter && update ? enter.merge(update).order() : update;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/lower.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/lower.js ***!
  \**********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function lower() {
  if (this.previousSibling) this.parentNode.insertBefore(this, this.parentNode.firstChild);
}

/* harmony default export */ __webpack_exports__["default"] = (function() {
  return this.each(lower);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/merge.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/merge.js ***!
  \**********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-selection/src/selection/index.js");


/* harmony default export */ __webpack_exports__["default"] = (function(context) {
  var selection = context.selection ? context.selection() : context;

  for (var groups0 = this._groups, groups1 = selection._groups, m0 = groups0.length, m1 = groups1.length, m = Math.min(m0, m1), merges = new Array(m0), j = 0; j < m; ++j) {
    for (var group0 = groups0[j], group1 = groups1[j], n = group0.length, merge = merges[j] = new Array(n), node, i = 0; i < n; ++i) {
      if (node = group0[i] || group1[i]) {
        merge[i] = node;
      }
    }
  }

  for (; j < m0; ++j) {
    merges[j] = groups0[j];
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_0__["Selection"](merges, this._parents);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/node.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/node.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {

  for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {
    for (var group = groups[j], i = 0, n = group.length; i < n; ++i) {
      var node = group[i];
      if (node) return node;
    }
  }

  return null;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/nodes.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/nodes.js ***!
  \**********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {
  return Array.from(this);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/on.js":
/*!*******************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/on.js ***!
  \*******************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function contextListener(listener) {
  return function(event) {
    listener.call(this, event, this.__data__);
  };
}

function parseTypenames(typenames) {
  return typenames.trim().split(/^|\s+/).map(function(t) {
    var name = "", i = t.indexOf(".");
    if (i >= 0) name = t.slice(i + 1), t = t.slice(0, i);
    return {type: t, name: name};
  });
}

function onRemove(typename) {
  return function() {
    var on = this.__on;
    if (!on) return;
    for (var j = 0, i = -1, m = on.length, o; j < m; ++j) {
      if (o = on[j], (!typename.type || o.type === typename.type) && o.name === typename.name) {
        this.removeEventListener(o.type, o.listener, o.options);
      } else {
        on[++i] = o;
      }
    }
    if (++i) on.length = i;
    else delete this.__on;
  };
}

function onAdd(typename, value, options) {
  return function() {
    var on = this.__on, o, listener = contextListener(value);
    if (on) for (var j = 0, m = on.length; j < m; ++j) {
      if ((o = on[j]).type === typename.type && o.name === typename.name) {
        this.removeEventListener(o.type, o.listener, o.options);
        this.addEventListener(o.type, o.listener = listener, o.options = options);
        o.value = value;
        return;
      }
    }
    this.addEventListener(typename.type, listener, options);
    o = {type: typename.type, name: typename.name, value: value, listener: listener, options: options};
    if (!on) this.__on = [o];
    else on.push(o);
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(typename, value, options) {
  var typenames = parseTypenames(typename + ""), i, n = typenames.length, t;

  if (arguments.length < 2) {
    var on = this.node().__on;
    if (on) for (var j = 0, m = on.length, o; j < m; ++j) {
      for (i = 0, o = on[j]; i < n; ++i) {
        if ((t = typenames[i]).type === o.type && t.name === o.name) {
          return o.value;
        }
      }
    }
    return;
  }

  on = value ? onAdd : onRemove;
  for (i = 0; i < n; ++i) this.each(on(typenames[i], value, options));
  return this;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/order.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/order.js ***!
  \**********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {

  for (var groups = this._groups, j = -1, m = groups.length; ++j < m;) {
    for (var group = groups[j], i = group.length - 1, next = group[i], node; --i >= 0;) {
      if (node = group[i]) {
        if (next && node.compareDocumentPosition(next) ^ 4) next.parentNode.insertBefore(node, next);
        next = node;
      }
    }
  }

  return this;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/property.js":
/*!*************************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/property.js ***!
  \*************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function propertyRemove(name) {
  return function() {
    delete this[name];
  };
}

function propertyConstant(name, value) {
  return function() {
    this[name] = value;
  };
}

function propertyFunction(name, value) {
  return function() {
    var v = value.apply(this, arguments);
    if (v == null) delete this[name];
    else this[name] = v;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value) {
  return arguments.length > 1
      ? this.each((value == null
          ? propertyRemove : typeof value === "function"
          ? propertyFunction
          : propertyConstant)(name, value))
      : this.node()[name];
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/raise.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/raise.js ***!
  \**********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function raise() {
  if (this.nextSibling) this.parentNode.appendChild(this);
}

/* harmony default export */ __webpack_exports__["default"] = (function() {
  return this.each(raise);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/remove.js":
/*!***********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/remove.js ***!
  \***********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function remove() {
  var parent = this.parentNode;
  if (parent) parent.removeChild(this);
}

/* harmony default export */ __webpack_exports__["default"] = (function() {
  return this.each(remove);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/select.js":
/*!***********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/select.js ***!
  \***********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-selection/src/selection/index.js");
/* harmony import */ var _selector_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../selector.js */ "./node_modules/d3-selection/src/selector.js");



/* harmony default export */ __webpack_exports__["default"] = (function(select) {
  if (typeof select !== "function") select = Object(_selector_js__WEBPACK_IMPORTED_MODULE_1__["default"])(select);

  for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, subgroup = subgroups[j] = new Array(n), node, subnode, i = 0; i < n; ++i) {
      if ((node = group[i]) && (subnode = select.call(node, node.__data__, i, group))) {
        if ("__data__" in node) subnode.__data__ = node.__data__;
        subgroup[i] = subnode;
      }
    }
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_0__["Selection"](subgroups, this._parents);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/selectAll.js":
/*!**************************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/selectAll.js ***!
  \**************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-selection/src/selection/index.js");
/* harmony import */ var _array_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../array.js */ "./node_modules/d3-selection/src/array.js");
/* harmony import */ var _selectorAll_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../selectorAll.js */ "./node_modules/d3-selection/src/selectorAll.js");




function arrayAll(select) {
  return function() {
    return Object(_array_js__WEBPACK_IMPORTED_MODULE_1__["default"])(select.apply(this, arguments));
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(select) {
  if (typeof select === "function") select = arrayAll(select);
  else select = Object(_selectorAll_js__WEBPACK_IMPORTED_MODULE_2__["default"])(select);

  for (var groups = this._groups, m = groups.length, subgroups = [], parents = [], j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {
      if (node = group[i]) {
        subgroups.push(select.call(node, node.__data__, i, group));
        parents.push(node);
      }
    }
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_0__["Selection"](subgroups, parents);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/selectChild.js":
/*!****************************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/selectChild.js ***!
  \****************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _matcher_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../matcher.js */ "./node_modules/d3-selection/src/matcher.js");


var find = Array.prototype.find;

function childFind(match) {
  return function() {
    return find.call(this.children, match);
  };
}

function childFirst() {
  return this.firstElementChild;
}

/* harmony default export */ __webpack_exports__["default"] = (function(match) {
  return this.select(match == null ? childFirst
      : childFind(typeof match === "function" ? match : Object(_matcher_js__WEBPACK_IMPORTED_MODULE_0__["childMatcher"])(match)));
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/selectChildren.js":
/*!*******************************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/selectChildren.js ***!
  \*******************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _matcher_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../matcher.js */ "./node_modules/d3-selection/src/matcher.js");


var filter = Array.prototype.filter;

function children() {
  return Array.from(this.children);
}

function childrenFilter(match) {
  return function() {
    return filter.call(this.children, match);
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(match) {
  return this.selectAll(match == null ? children
      : childrenFilter(typeof match === "function" ? match : Object(_matcher_js__WEBPACK_IMPORTED_MODULE_0__["childMatcher"])(match)));
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/size.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/size.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function() {
  let size = 0;
  for (const node of this) ++size; // eslint-disable-line no-unused-vars
  return size;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/sort.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/sort.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.js */ "./node_modules/d3-selection/src/selection/index.js");


/* harmony default export */ __webpack_exports__["default"] = (function(compare) {
  if (!compare) compare = ascending;

  function compareNode(a, b) {
    return a && b ? compare(a.__data__, b.__data__) : !a - !b;
  }

  for (var groups = this._groups, m = groups.length, sortgroups = new Array(m), j = 0; j < m; ++j) {
    for (var group = groups[j], n = group.length, sortgroup = sortgroups[j] = new Array(n), node, i = 0; i < n; ++i) {
      if (node = group[i]) {
        sortgroup[i] = node;
      }
    }
    sortgroup.sort(compareNode);
  }

  return new _index_js__WEBPACK_IMPORTED_MODULE_0__["Selection"](sortgroups, this._parents).order();
});

function ascending(a, b) {
  return a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN;
}


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/sparse.js":
/*!***********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/sparse.js ***!
  \***********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(update) {
  return new Array(update.length);
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/style.js":
/*!**********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/style.js ***!
  \**********************************************************/
/*! exports provided: default, styleValue */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "styleValue", function() { return styleValue; });
/* harmony import */ var _window_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../window.js */ "./node_modules/d3-selection/src/window.js");


function styleRemove(name) {
  return function() {
    this.style.removeProperty(name);
  };
}

function styleConstant(name, value, priority) {
  return function() {
    this.style.setProperty(name, value, priority);
  };
}

function styleFunction(name, value, priority) {
  return function() {
    var v = value.apply(this, arguments);
    if (v == null) this.style.removeProperty(name);
    else this.style.setProperty(name, v, priority);
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(name, value, priority) {
  return arguments.length > 1
      ? this.each((value == null
            ? styleRemove : typeof value === "function"
            ? styleFunction
            : styleConstant)(name, value, priority == null ? "" : priority))
      : styleValue(this.node(), name);
});

function styleValue(node, name) {
  return node.style.getPropertyValue(name)
      || Object(_window_js__WEBPACK_IMPORTED_MODULE_0__["default"])(node).getComputedStyle(node, null).getPropertyValue(name);
}


/***/ }),

/***/ "./node_modules/d3-selection/src/selection/text.js":
/*!*********************************************************!*\
  !*** ./node_modules/d3-selection/src/selection/text.js ***!
  \*********************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function textRemove() {
  this.textContent = "";
}

function textConstant(value) {
  return function() {
    this.textContent = value;
  };
}

function textFunction(value) {
  return function() {
    var v = value.apply(this, arguments);
    this.textContent = v == null ? "" : v;
  };
}

/* harmony default export */ __webpack_exports__["default"] = (function(value) {
  return arguments.length
      ? this.each(value == null
          ? textRemove : (typeof value === "function"
          ? textFunction
          : textConstant)(value))
      : this.node().textContent;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selector.js":
/*!***************************************************!*\
  !*** ./node_modules/d3-selection/src/selector.js ***!
  \***************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function none() {}

/* harmony default export */ __webpack_exports__["default"] = (function(selector) {
  return selector == null ? none : function() {
    return this.querySelector(selector);
  };
});


/***/ }),

/***/ "./node_modules/d3-selection/src/selectorAll.js":
/*!******************************************************!*\
  !*** ./node_modules/d3-selection/src/selectorAll.js ***!
  \******************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
function empty() {
  return [];
}

/* harmony default export */ __webpack_exports__["default"] = (function(selector) {
  return selector == null ? empty : function() {
    return this.querySelectorAll(selector);
  };
});


/***/ }),

/***/ "./node_modules/d3-selection/src/sourceEvent.js":
/*!******************************************************!*\
  !*** ./node_modules/d3-selection/src/sourceEvent.js ***!
  \******************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(event) {
  let sourceEvent;
  while (sourceEvent = event.sourceEvent) event = sourceEvent;
  return event;
});


/***/ }),

/***/ "./node_modules/d3-selection/src/window.js":
/*!*************************************************!*\
  !*** ./node_modules/d3-selection/src/window.js ***!
  \*************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (function(node) {
  return (node.ownerDocument && node.ownerDocument.defaultView) // node is a Node
      || (node.document && node) // node is a Window
      || node.defaultView; // node is a Document
});


/***/ }),

/***/ "./node_modules/d3-timer/src/index.js":
/*!********************************************!*\
  !*** ./node_modules/d3-timer/src/index.js ***!
  \********************************************/
/*! exports provided: now, timer, timerFlush, timeout, interval */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _timer_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./timer.js */ "./node_modules/d3-timer/src/timer.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "now", function() { return _timer_js__WEBPACK_IMPORTED_MODULE_0__["now"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timer", function() { return _timer_js__WEBPACK_IMPORTED_MODULE_0__["timer"]; });

/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timerFlush", function() { return _timer_js__WEBPACK_IMPORTED_MODULE_0__["timerFlush"]; });

/* harmony import */ var _timeout_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./timeout.js */ "./node_modules/d3-timer/src/timeout.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "timeout", function() { return _timeout_js__WEBPACK_IMPORTED_MODULE_1__["default"]; });

/* harmony import */ var _interval_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./interval.js */ "./node_modules/d3-timer/src/interval.js");
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "interval", function() { return _interval_js__WEBPACK_IMPORTED_MODULE_2__["default"]; });








/***/ }),

/***/ "./node_modules/d3-timer/src/interval.js":
/*!***********************************************!*\
  !*** ./node_modules/d3-timer/src/interval.js ***!
  \***********************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _timer_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./timer.js */ "./node_modules/d3-timer/src/timer.js");


/* harmony default export */ __webpack_exports__["default"] = (function(callback, delay, time) {
  var t = new _timer_js__WEBPACK_IMPORTED_MODULE_0__["Timer"], total = delay;
  if (delay == null) return t.restart(callback, delay, time), t;
  delay = +delay, time = time == null ? Object(_timer_js__WEBPACK_IMPORTED_MODULE_0__["now"])() : +time;
  t.restart(function tick(elapsed) {
    elapsed += total;
    t.restart(tick, total += delay, time);
    callback(elapsed);
  }, delay, time);
  return t;
});


/***/ }),

/***/ "./node_modules/d3-timer/src/timeout.js":
/*!**********************************************!*\
  !*** ./node_modules/d3-timer/src/timeout.js ***!
  \**********************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _timer_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./timer.js */ "./node_modules/d3-timer/src/timer.js");


/* harmony default export */ __webpack_exports__["default"] = (function(callback, delay, time) {
  var t = new _timer_js__WEBPACK_IMPORTED_MODULE_0__["Timer"];
  delay = delay == null ? 0 : +delay;
  t.restart(function(elapsed) {
    t.stop();
    callback(elapsed + delay);
  }, delay, time);
  return t;
});


/***/ }),

/***/ "./node_modules/d3-timer/src/timer.js":
/*!********************************************!*\
  !*** ./node_modules/d3-timer/src/timer.js ***!
  \********************************************/
/*! exports provided: now, Timer, timer, timerFlush */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "now", function() { return now; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Timer", function() { return Timer; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timer", function() { return timer; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "timerFlush", function() { return timerFlush; });
var frame = 0, // is an animation frame pending?
    timeout = 0, // is a timeout pending?
    interval = 0, // are any timers active?
    pokeDelay = 1000, // how frequently we check for clock skew
    taskHead,
    taskTail,
    clockLast = 0,
    clockNow = 0,
    clockSkew = 0,
    clock = typeof performance === "object" && performance.now ? performance : Date,
    setFrame = typeof window === "object" && window.requestAnimationFrame ? window.requestAnimationFrame.bind(window) : function(f) { setTimeout(f, 17); };

function now() {
  return clockNow || (setFrame(clearNow), clockNow = clock.now() + clockSkew);
}

function clearNow() {
  clockNow = 0;
}

function Timer() {
  this._call =
  this._time =
  this._next = null;
}

Timer.prototype = timer.prototype = {
  constructor: Timer,
  restart: function(callback, delay, time) {
    if (typeof callback !== "function") throw new TypeError("callback is not a function");
    time = (time == null ? now() : +time) + (delay == null ? 0 : +delay);
    if (!this._next && taskTail !== this) {
      if (taskTail) taskTail._next = this;
      else taskHead = this;
      taskTail = this;
    }
    this._call = callback;
    this._time = time;
    sleep();
  },
  stop: function() {
    if (this._call) {
      this._call = null;
      this._time = Infinity;
      sleep();
    }
  }
};

function timer(callback, delay, time) {
  var t = new Timer;
  t.restart(callback, delay, time);
  return t;
}

function timerFlush() {
  now(); // Get the current time, if not already set.
  ++frame; // Pretend we’ve set an alarm, if we haven’t already.
  var t = taskHead, e;
  while (t) {
    if ((e = clockNow - t._time) >= 0) t._call.call(null, e);
    t = t._next;
  }
  --frame;
}

function wake() {
  clockNow = (clockLast = clock.now()) + clockSkew;
  frame = timeout = 0;
  try {
    timerFlush();
  } finally {
    frame = 0;
    nap();
    clockNow = 0;
  }
}

function poke() {
  var now = clock.now(), delay = now - clockLast;
  if (delay > pokeDelay) clockSkew -= delay, clockLast = now;
}

function nap() {
  var t0, t1 = taskHead, t2, time = Infinity;
  while (t1) {
    if (t1._call) {
      if (time > t1._time) time = t1._time;
      t0 = t1, t1 = t1._next;
    } else {
      t2 = t1._next, t1._next = null;
      t1 = t0 ? t0._next = t2 : taskHead = t2;
    }
  }
  taskTail = t0;
  sleep(time);
}

function sleep(time) {
  if (frame) return; // Soonest alarm already set, or will be.
  if (timeout) timeout = clearTimeout(timeout);
  var delay = time - clockNow; // Strictly less than if we recomputed clockNow.
  if (delay > 24) {
    if (time < Infinity) timeout = setTimeout(wake, time - clock.now() - clockSkew);
    if (interval) interval = clearInterval(interval);
  } else {
    if (!interval) clockLast = clock.now(), interval = setInterval(poke, pokeDelay);
    frame = 1, setFrame(wake);
  }
}


/***/ }),

/***/ "./node_modules/highcharts/modules/gantt.js":
/*!**************************************************!*\
  !*** ./node_modules/highcharts/modules/gantt.js ***!
  \**************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {

var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*
 Highcharts Gantt JS v8.2.2 (2020-10-22)

 Gantt series

 (c) 2016-2019 Lars A. V. Cabrera

 License: www.highcharts.com/license
*/
(function(b){ true&&module.exports?(b["default"]=b,module.exports=b): true?!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js")], __WEBPACK_AMD_DEFINE_RESULT__ = (function(I){b(I);b.Highcharts=I;return b}).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)):undefined})(function(b){function I(b,z,A,w){b.hasOwnProperty(z)||(b[z]=w.apply(null,A))}b=b?b._modules:{};I(b,"Gantt/Tree.js",[b["Core/Utilities.js"]],function(b){var z=b.extend,A=b.isNumber,w=b.pick,y=function(b,v){var c=b.reduce(function(c,
u){var x=w(u.parent,"");"undefined"===typeof c[x]&&(c[x]=[]);c[x].push(u);return c},{});Object.keys(c).forEach(function(r,u){var x=c[r];""!==r&&-1===v.indexOf(r)&&(x.forEach(function(c){u[""].push(c)}),delete u[r])});return c},p=function(b,v,c,r,u,x){var n=0,q=0,D=x&&x.after,e=x&&x.before;v={data:r,depth:c-1,id:b,level:c,parent:v};var m,h;"function"===typeof e&&e(v,x);e=(u[b]||[]).map(function(a){var g=p(a.id,b,c+1,a,u,x),d=a.start;a=!0===a.milestone?d:a.end;m=!A(m)||d<m?d:m;h=!A(h)||a>h?a:h;n=n+
1+g.descendants;q=Math.max(g.height+1,q);return g});r&&(r.start=w(r.start,m),r.end=w(r.end,h));z(v,{children:e,descendants:n,height:q});"function"===typeof D&&D(v,x);return v};return{getListOfParents:y,getNode:p,getTree:function(b,v){var c=b.map(function(c){return c.id});b=y(b,c);return p("",null,1,null,b,v)}}});I(b,"Core/Axis/TreeGridTick.js",[b["Core/Utilities.js"]],function(b){var z=b.addEvent,A=b.defined,w=b.isObject,y=b.isNumber,p=b.pick,E=b.wrap,v;(function(c){function r(){this.treeGrid||(this.treeGrid=
new D(this))}function u(e,m){e=e.treeGrid;var h=!e.labelIcon,a=m.renderer,g=m.xy,d=m.options,t=d.width,l=d.height,f=g.x-t/2-d.padding;g=g.y-l/2;var G=m.collapsed?90:180,J=m.show&&y(g),B=e.labelIcon;B||(e.labelIcon=B=a.path(a.symbols[d.type](d.x,d.y,t,l)).addClass("highcharts-label-icon").add(m.group));J||B.attr({y:-9999});a.styledMode||B.attr({"stroke-width":1,fill:p(m.color,"#666666")}).css({cursor:"pointer",stroke:d.lineColor,strokeWidth:d.lineWidth});B[h?"attr":"animate"]({translateX:f,translateY:g,
rotation:G})}function x(e,m,h,a,g,d,t,l,f){var G=p(this.options&&this.options.labels,d);d=this.pos;var J=this.axis,B="treegrid"===J.options.type;e=e.apply(this,[m,h,a,g,G,t,l,f]);B&&(m=G&&w(G.symbol,!0)?G.symbol:{},G=G&&y(G.indentation)?G.indentation:0,d=(d=(J=J.treeGrid.mapOfPosToGridNode)&&J[d])&&d.depth||1,e.x+=m.width+2*m.padding+(d-1)*G);return e}function n(e){var m=this,h=m.pos,a=m.axis,g=m.label,d=a.treeGrid.mapOfPosToGridNode,t=a.options,l=p(m.options&&m.options.labels,t&&t.labels),f=l&&w(l.symbol,
!0)?l.symbol:{},G=(d=d&&d[h])&&d.depth;t="treegrid"===t.type;var J=-1<a.tickPositions.indexOf(h);h=a.chart.styledMode;t&&d&&g&&g.element&&g.addClass("highcharts-treegrid-node-level-"+G);e.apply(m,Array.prototype.slice.call(arguments,1));t&&g&&g.element&&d&&d.descendants&&0<d.descendants&&(a=a.treeGrid.isCollapsed(d),u(m,{color:!h&&g.styles&&g.styles.color||"",collapsed:a,group:g.parentGroup,options:f,renderer:g.renderer,show:J,xy:g.xy}),f="highcharts-treegrid-node-"+(a?"expanded":"collapsed"),g.addClass("highcharts-treegrid-node-"+
(a?"collapsed":"expanded")).removeClass(f),h||g.css({cursor:"pointer"}),[g,m.treeGrid.labelIcon].forEach(function(a){a&&!a.attachedTreeGridEvents&&(z(a.element,"mouseover",function(){g.addClass("highcharts-treegrid-node-active");g.renderer.styledMode||g.css({textDecoration:"underline"})}),z(a.element,"mouseout",function(){var a=A(l.style)?l.style:{};g.removeClass("highcharts-treegrid-node-active");g.renderer.styledMode||g.css({textDecoration:a.textDecoration})}),z(a.element,"click",function(){m.treeGrid.toggleCollapse()}),
a.attachedTreeGridEvents=!0)}))}var q=!1;c.compose=function(e){q||(z(e,"init",r),E(e.prototype,"getLabelPosition",x),E(e.prototype,"renderLabel",n),e.prototype.collapse=function(e){this.treeGrid.collapse(e)},e.prototype.expand=function(e){this.treeGrid.expand(e)},e.prototype.toggleCollapse=function(e){this.treeGrid.toggleCollapse(e)},q=!0)};var D=function(){function e(e){this.tick=e}e.prototype.collapse=function(e){var h=this.tick,a=h.axis,g=a.brokenAxis;g&&a.treeGrid.mapOfPosToGridNode&&(h=a.treeGrid.collapse(a.treeGrid.mapOfPosToGridNode[h.pos]),
g.setBreaks(h,p(e,!0)))};e.prototype.expand=function(e){var h=this.tick,a=h.axis,g=a.brokenAxis;g&&a.treeGrid.mapOfPosToGridNode&&(h=a.treeGrid.expand(a.treeGrid.mapOfPosToGridNode[h.pos]),g.setBreaks(h,p(e,!0)))};e.prototype.toggleCollapse=function(e){var h=this.tick,a=h.axis,g=a.brokenAxis;g&&a.treeGrid.mapOfPosToGridNode&&(h=a.treeGrid.toggleCollapse(a.treeGrid.mapOfPosToGridNode[h.pos]),g.setBreaks(h,p(e,!0)))};return e}();c.Additions=D})(v||(v={}));return v});I(b,"Mixins/TreeSeries.js",[b["Core/Color/Color.js"],
b["Core/Utilities.js"]],function(b,z){var A=z.extend,w=z.isArray,y=z.isNumber,p=z.isObject,E=z.merge,v=z.pick;return{getColor:function(c,r){var u=r.index,x=r.mapOptionsToLevel,n=r.parentColor,q=r.parentColorIndex,D=r.series,e=r.colors,m=r.siblings,h=D.points,a=D.chart.options.chart,g;if(c){h=h[c.i];c=x[c.level]||{};if(x=h&&c.colorByPoint){var d=h.index%(e?e.length:a.colorCount);var t=e&&e[d]}if(!D.chart.styledMode){e=h&&h.options.color;a=c&&c.color;if(g=n)g=(g=c&&c.colorVariation)&&"brightness"===
g.key?b.parse(n).brighten(u/m*g.to).get():n;g=v(e,a,t,g,D.color)}var l=v(h&&h.options.colorIndex,c&&c.colorIndex,d,q,r.colorIndex)}return{color:g,colorIndex:l}},getLevelOptions:function(c){var r=null;if(p(c)){r={};var u=y(c.from)?c.from:1;var x=c.levels;var n={};var q=p(c.defaults)?c.defaults:{};w(x)&&(n=x.reduce(function(c,e){if(p(e)&&y(e.level)){var m=E({},e);var h="boolean"===typeof m.levelIsConstant?m.levelIsConstant:q.levelIsConstant;delete m.levelIsConstant;delete m.level;e=e.level+(h?0:u-1);
p(c[e])?A(c[e],m):c[e]=m}return c},{}));x=y(c.to)?c.to:1;for(c=0;c<=x;c++)r[c]=E({},q,p(n[c])?n[c]:{})}return r},setTreeValues:function x(r,u){var n=u.before,q=u.idRoot,D=u.mapIdToNode[q],e=u.points[r.i],m=e&&e.options||{},h=0,a=[];A(r,{levelDynamic:r.level-(("boolean"===typeof u.levelIsConstant?u.levelIsConstant:1)?0:D.level),name:v(e&&e.name,""),visible:q===r.id||("boolean"===typeof u.visible?u.visible:!1)});"function"===typeof n&&(r=n(r,u));r.children.forEach(function(g,d){var t=A({},u);A(t,{index:d,
siblings:r.children.length,visible:r.visible});g=x(g,t);a.push(g);g.visible&&(h+=g.val)});r.visible=0<h||r.visible;n=v(m.value,h);A(r,{children:a,childrenTotal:h,isLeaf:r.visible&&!h,val:n});return r},updateRootId:function(r){if(p(r)){var u=p(r.options)?r.options:{};u=v(r.rootNode,u.rootId,"");p(r.userOptions)&&(r.userOptions.rootId=u);r.rootNode=u}return u}}});I(b,"Core/Axis/GridAxis.js",[b["Core/Axis/Axis.js"],b["Core/Globals.js"],b["Core/Options.js"],b["Core/Axis/Tick.js"],b["Core/Utilities.js"]],
function(b,z,A,w,y){var p=y.addEvent,E=y.defined,v=y.erase,c=y.find,r=y.isArray,u=y.isNumber,x=y.merge,n=y.pick,q=y.timeUnits,D=y.wrap;A=z.Chart;var e=function(a){var g=a.options;g.labels||(g.labels={});g.labels.align=n(g.labels.align,"center");a.categories||(g.showLastLabel=!1);a.labelRotation=0;g.labels.rotation=0};"";b.prototype.getMaxLabelDimensions=function(a,g){var d={width:0,height:0};g.forEach(function(g){g=a[g];if(y.isObject(g,!0)){var l=y.isObject(g.label,!0)?g.label:{};g=l.getBBox?l.getBBox().height:
0;l.textStr&&!u(l.textPxLength)&&(l.textPxLength=l.getBBox().width);var f=u(l.textPxLength)?Math.round(l.textPxLength):0;l.textStr&&(f=Math.round(l.getBBox().width));d.height=Math.max(g,d.height);d.width=Math.max(f,d.width)}});return d};z.dateFormats.W=function(a){a=new this.Date(a);var g=(this.get("Day",a)+6)%7,d=new this.Date(a.valueOf());this.set("Date",d,this.get("Date",a)-g+3);g=new this.Date(this.get("FullYear",d),0,1);4!==this.get("Day",g)&&(this.set("Month",a,0),this.set("Date",a,1+(11-this.get("Day",
g))%7));return(1+Math.floor((d.valueOf()-g.valueOf())/6048E5)).toString()};z.dateFormats.E=function(a){return this.dateFormat("%a",a,!0).charAt(0)};p(A,"afterSetChartSize",function(){this.axes.forEach(function(a){(a.grid&&a.grid.columns||[]).forEach(function(a){a.setAxisSize();a.setAxisTranslation()})})});p(w,"afterGetLabelPosition",function(a){var g=this.label,d=this.axis,t=d.reversed,l=d.chart,f=d.options.grid||{},e=d.options.labels,J=e.align,B=h.Side[d.side],c=a.tickmarkOffset,m=d.tickPositions,
H=this.pos-c;m=u(m[a.index+1])?m[a.index+1]-c:d.max+c;var k=d.tickSize("tick");c=k?k[0]:0;k=k?k[1]/2:0;if(!0===f.enabled){if("top"===B){f=d.top+d.offset;var C=f-c}else"bottom"===B?(C=l.chartHeight-d.bottom+d.offset,f=C+c):(f=d.top+d.len-d.translate(t?m:H),C=d.top+d.len-d.translate(t?H:m));"right"===B?(B=l.chartWidth-d.right+d.offset,t=B+c):"left"===B?(t=d.left+d.offset,B=t-c):(B=Math.round(d.left+d.translate(t?m:H))-k,t=Math.round(d.left+d.translate(t?H:m))-k);this.slotWidth=t-B;a.pos.x="left"===
J?B:"right"===J?t:B+(t-B)/2;a.pos.y=C+(f-C)/2;l=l.renderer.fontMetrics(e.style.fontSize,g.element);g=g.getBBox().height;e.useHTML?a.pos.y+=l.b+-(g/2):(g=Math.round(g/l.h),a.pos.y+=(l.b-(l.h-l.f))/2+-((g-1)*l.h/2));a.pos.x+=d.horiz&&e.x||0}});var m=function(){function a(a){this.axis=a}a.prototype.isOuterAxis=function(){var a=this.axis,d=a.grid.columnIndex,t=a.linkedParent&&a.linkedParent.grid.columns||a.grid.columns,l=d?a.linkedParent:a,f=-1,e=0;a.chart[a.coll].forEach(function(g,d){g.side!==a.side||
g.options.isInternal||(e=d,g===l&&(f=d))});return e===f&&(u(d)?t.length===d:!0)};a.prototype.renderBorder=function(a){var d=this.axis,g=d.chart.renderer,l=d.options;a=g.path(a).addClass("highcharts-axis-line").add(d.axisBorder);g.styledMode||a.attr({stroke:l.lineColor,"stroke-width":l.lineWidth,zIndex:7});return a};return a}(),h=function(){function a(){}a.compose=function(g){b.keepProps.push("grid");D(g.prototype,"unsquish",a.wrapUnsquish);p(g,"init",a.onInit);p(g,"afterGetOffset",a.onAfterGetOffset);
p(g,"afterGetTitlePosition",a.onAfterGetTitlePosition);p(g,"afterInit",a.onAfterInit);p(g,"afterRender",a.onAfterRender);p(g,"afterSetAxisTranslation",a.onAfterSetAxisTranslation);p(g,"afterSetOptions",a.onAfterSetOptions);p(g,"afterSetOptions",a.onAfterSetOptions2);p(g,"afterSetScale",a.onAfterSetScale);p(g,"afterTickSize",a.onAfterTickSize);p(g,"trimTicks",a.onTrimTicks);p(g,"destroy",a.onDestroy)};a.onAfterGetOffset=function(){var a=this.grid;(a&&a.columns||[]).forEach(function(a){a.getOffset()})};
a.onAfterGetTitlePosition=function(g){if(!0===(this.options.grid||{}).enabled){var d=this.axisTitle,t=this.height,l=this.horiz,f=this.left,e=this.offset,h=this.opposite,B=this.options.title,c=void 0===B?{}:B;B=this.top;var m=this.width,H=this.tickSize(),k=d&&d.getBBox().width,C=c.x||0,F=c.y||0,P=n(c.margin,l?5:10);d=this.chart.renderer.fontMetrics(c.style&&c.style.fontSize,d).f;H=(l?B+t:f)+(l?1:-1)*(h?-1:1)*(H?H[0]/2:0)+(this.side===a.Side.bottom?d:0);g.titlePosition.x=l?f-k/2-P+C:H+(h?m:0)+e+C;g.titlePosition.y=
l?H-(h?t:0)+(h?d:-d)/2+e+F:B-P+F}};a.onAfterInit=function(){var a=this.chart,d=this.options.grid;d=void 0===d?{}:d;var t=this.userOptions;d.enabled&&(e(this),D(this,"labelFormatter",function(a){var d=this.axis,g=this.value,l=d.tickPositions,f=(d.isLinked?d.linkedParent:d).series[0],k=g===l[0];l=g===l[l.length-1];var C=f&&c(f.options.data,function(k){return k[d.isXAxis?"x":"y"]===g});if(C&&f.is("gantt")){var F=x(C);z.seriesTypes.gantt.prototype.setGanttPointAliases(F)}this.isFirst=k;this.isLast=l;
this.point=F;return a.call(this)}));if(d.columns)for(var l=this.grid.columns=[],f=this.grid.columnIndex=0;++f<d.columns.length;){var h=x(t,d.columns[d.columns.length-f-1],{linkedTo:0,type:"category",scrollbar:{enabled:!1}});delete h.grid.columns;h=new b(this.chart,h);h.grid.isColumn=!0;h.grid.columnIndex=f;v(a.axes,h);v(a[this.coll],h);l.push(h)}};a.onAfterRender=function(){var g,d=this.grid,t=this.options;if(!0===(t.grid||{}).enabled){this.maxLabelDimensions=this.getMaxLabelDimensions(this.ticks,
this.tickPositions);this.rightWall&&this.rightWall.destroy();if(this.grid&&this.grid.isOuterAxis()&&this.axisLine&&(t=t.lineWidth)){t=this.getLinePath(t);var l=t[0],f=t[1],e=((this.tickSize("tick")||[1])[0]-1)*(this.side===a.Side.top||this.side===a.Side.left?-1:1);"M"===l[0]&&"L"===f[0]&&(this.horiz?(l[2]+=e,f[2]+=e):(l[1]+=e,f[1]+=e));!this.horiz&&this.chart.marginRight&&(l=[l,["L",this.left,l[2]]],e=["L",this.chart.chartWidth-this.chart.marginRight,this.toPixels(this.max+this.tickmarkOffset)],f=
[["M",f[1],this.toPixels(this.max+this.tickmarkOffset)],e],this.grid.upperBorder||0===this.min%1||(this.grid.upperBorder=this.grid.renderBorder(l)),this.grid.upperBorder&&this.grid.upperBorder.animate({d:l}),this.grid.lowerBorder||0===this.max%1||(this.grid.lowerBorder=this.grid.renderBorder(f)),this.grid.lowerBorder&&this.grid.lowerBorder.animate({d:f}));this.grid.axisLineExtra?this.grid.axisLineExtra.animate({d:t}):this.grid.axisLineExtra=this.grid.renderBorder(t);this.axisLine[this.showAxis?"show":
"hide"](!0)}(d&&d.columns||[]).forEach(function(a){a.render()});!this.horiz&&this.chart.hasRendered&&(this.scrollbar||(null===(g=this.linkedParent)||void 0===g?0:g.scrollbar))&&(g=this.max,d=this.tickmarkOffset,t=this.tickPositions[this.tickPositions.length-1],f=this.tickPositions[0],this.min-f>d?this.ticks[f].label.hide():this.ticks[f].label.show(),t-g>d?this.ticks[t].label.hide():this.ticks[t].label.show(),t-g<d&&0<t-g&&this.ticks[t].isLast?this.ticks[t].mark.hide():this.ticks[t-1].mark.show())}};
a.onAfterSetAxisTranslation=function(){var a,d=this.tickPositions&&this.tickPositions.info,e=this.options,l=e.grid||{},f=this.userOptions.labels||{};this.horiz?(!0===l.enabled&&this.series.forEach(function(a){a.options.pointRange=0}),d&&e.dateTimeLabelFormats&&e.labels&&!E(f.align)&&(!1===e.dateTimeLabelFormats[d.unitName].range||1<d.count)&&(e.labels.align="left",E(f.x)||(e.labels.x=3))):"treegrid"!==this.options.type&&(null===(a=this.grid)||void 0===a?0:a.columns)&&(this.minPointOffset=this.tickInterval)};
a.onAfterSetOptions=function(a){var d=this.options;a=a.userOptions;var g=d&&y.isObject(d.grid,!0)?d.grid:{};if(!0===g.enabled){var l=x(!0,{className:"highcharts-grid-axis "+(a.className||""),dateTimeLabelFormats:{hour:{list:["%H:%M","%H"]},day:{list:["%A, %e. %B","%a, %e. %b","%E"]},week:{list:["Week %W","W%W"]},month:{list:["%B","%b","%o"]}},grid:{borderWidth:1},labels:{padding:2,style:{fontSize:"13px"}},margin:0,title:{text:null,reserveSpace:!1,rotation:0},units:[["millisecond",[1,10,100]],["second",
[1,10]],["minute",[1,5,15]],["hour",[1,6]],["day",[1]],["week",[1]],["month",[1]],["year",null]]},a);"xAxis"===this.coll&&(E(a.linkedTo)&&!E(a.tickPixelInterval)&&(l.tickPixelInterval=350),E(a.tickPixelInterval)||!E(a.linkedTo)||E(a.tickPositioner)||E(a.tickInterval)||(l.tickPositioner=function(a,d){var g=this.linkedParent&&this.linkedParent.tickPositions&&this.linkedParent.tickPositions.info;if(g){var f,e=l.units;for(f=0;f<e.length;f++)if(e[f][0]===g.unitName){var t=f;break}if(e[t+1]){var H=e[t+
1][0];var k=(e[t+1][1]||[1])[0]}else"year"===g.unitName&&(H="year",k=10*g.count);g=q[H];this.tickInterval=g*k;return this.getTimeTicks({unitRange:g,count:k,unitName:H},a,d,this.options.startOfWeek)}}));x(!0,this.options,l);this.horiz&&(d.minPadding=n(a.minPadding,0),d.maxPadding=n(a.maxPadding,0));u(d.grid.borderWidth)&&(d.tickWidth=d.lineWidth=g.borderWidth)}};a.onAfterSetOptions2=function(a){a=(a=a.userOptions)&&a.grid||{};var d=a.columns;a.enabled&&d&&x(!0,this.options,d[d.length-1])};a.onAfterSetScale=
function(){(this.grid.columns||[]).forEach(function(a){a.setScale()})};a.onAfterTickSize=function(a){var d=b.defaultLeftAxisOptions,g=this.horiz,l=this.maxLabelDimensions,f=this.options.grid;f=void 0===f?{}:f;f.enabled&&l&&(d=2*Math.abs(d.labels.x),g=g?f.cellHeight||d+l.height:d+l.width,r(a.tickSize)?a.tickSize[0]=g:a.tickSize=[g,0])};a.onDestroy=function(a){var d=this.grid;(d.columns||[]).forEach(function(d){d.destroy(a.keepEvents)});d.columns=void 0};a.onInit=function(a){a=a.userOptions||{};var d=
a.grid||{};d.enabled&&E(d.borderColor)&&(a.tickColor=a.lineColor=d.borderColor);this.grid||(this.grid=new m(this))};a.onTrimTicks=function(){var a=this.options,d=this.categories,e=this.tickPositions,l=e[0],f=e[e.length-1],h=this.linkedParent&&this.linkedParent.min||this.min,c=this.linkedParent&&this.linkedParent.max||this.max,B=this.tickInterval;!0!==(a.grid||{}).enabled||d||!this.horiz&&!this.isLinked||(l<h&&l+B>h&&!a.startOnTick&&(e[0]=h),f>c&&f-B<c&&!a.endOnTick&&(e[e.length-1]=c))};a.wrapUnsquish=
function(a){var d=this.options.grid;return!0===(void 0===d?{}:d).enabled&&this.categories?this.tickInterval:a.apply(this,Array.prototype.slice.call(arguments,1))};return a}();(function(a){a=a.Side||(a.Side={});a[a.top=0]="top";a[a.right=1]="right";a[a.bottom=2]="bottom";a[a.left=3]="left"})(h||(h={}));h.compose(b);return h});I(b,"Core/Axis/BrokenAxis.js",[b["Core/Axis/Axis.js"],b["Series/LineSeries.js"],b["Extensions/Stacking.js"],b["Core/Utilities.js"]],function(b,z,A,w){var y=w.addEvent,p=w.find,
E=w.fireEvent,v=w.isArray,c=w.isNumber,r=w.pick,u=function(){function c(c){this.hasBreaks=!1;this.axis=c}c.isInBreak=function(c,q){var D=c.repeat||Infinity,e=c.from,m=c.to-c.from;q=q>=e?(q-e)%D:D-(e-q)%D;return c.inclusive?q<=m:q<m&&0!==q};c.lin2Val=function(n){var q=this.brokenAxis;q=q&&q.breakArray;if(!q)return n;var D;for(D=0;D<q.length;D++){var e=q[D];if(e.from>=n)break;else e.to<n?n+=e.len:c.isInBreak(e,n)&&(n+=e.len)}return n};c.val2Lin=function(n){var q=this.brokenAxis;q=q&&q.breakArray;if(!q)return n;
var D=n,e;for(e=0;e<q.length;e++){var m=q[e];if(m.to<=n)D-=m.len;else if(m.from>=n)break;else if(c.isInBreak(m,n)){D-=n-m.from;break}}return D};c.prototype.findBreakAt=function(c,q){return p(q,function(q){return q.from<c&&c<q.to})};c.prototype.isInAnyBreak=function(n,q){var D=this.axis,e=D.options.breaks,m=e&&e.length,h;if(m){for(;m--;)if(c.isInBreak(e[m],n)){var a=!0;h||(h=r(e[m].showPoints,!D.isXAxis))}var g=a&&q?a&&!h:a}return g};c.prototype.setBreaks=function(n,q){var D=this,e=D.axis,m=v(n)&&
!!n.length;e.isDirty=D.hasBreaks!==m;D.hasBreaks=m;e.options.breaks=e.userOptions.breaks=n;e.forceRedraw=!0;e.series.forEach(function(e){e.isDirty=!0});m||e.val2lin!==c.val2Lin||(delete e.val2lin,delete e.lin2val);m&&(e.userOptions.ordinal=!1,e.lin2val=c.lin2Val,e.val2lin=c.val2Lin,e.setExtremes=function(e,a,g,d,c){if(D.hasBreaks){for(var l,f=this.options.breaks;l=D.findBreakAt(e,f);)e=l.to;for(;l=D.findBreakAt(a,f);)a=l.from;a<e&&(a=e)}b.prototype.setExtremes.call(this,e,a,g,d,c)},e.setAxisTranslation=
function(h){b.prototype.setAxisTranslation.call(this,h);D.unitLength=null;if(D.hasBreaks){h=e.options.breaks||[];var a=[],g=[],d=0,t,l=e.userMin||e.min,f=e.userMax||e.max,m=r(e.pointRangePadding,0),J;h.forEach(function(a){t=a.repeat||Infinity;c.isInBreak(a,l)&&(l+=a.to%t-l%t);c.isInBreak(a,f)&&(f-=f%t-a.from%t)});h.forEach(function(d){q=d.from;for(t=d.repeat||Infinity;q-t>l;)q-=t;for(;q<l;)q+=t;for(J=q;J<f;J+=t)a.push({value:J,move:"in"}),a.push({value:J+(d.to-d.from),move:"out",size:d.breakSize})});
a.sort(function(a,d){return a.value===d.value?("in"===a.move?0:1)-("in"===d.move?0:1):a.value-d.value});var B=0;var q=l;a.forEach(function(a){B+="in"===a.move?1:-1;1===B&&"in"===a.move&&(q=a.value);0===B&&(g.push({from:q,to:a.value,len:a.value-q-(a.size||0)}),d+=a.value-q-(a.size||0))});e.breakArray=D.breakArray=g;D.unitLength=f-l-d+m;E(e,"afterBreaks");e.staticScale?e.transA=e.staticScale:D.unitLength&&(e.transA*=(f-e.min+m)/D.unitLength);m&&(e.minPixelPadding=e.transA*e.minPointOffset);e.min=l;
e.max=f}});r(q,!0)&&e.chart.redraw()};return c}();w=function(){function x(){}x.compose=function(n,q){n.keepProps.push("brokenAxis");var D=z.prototype;D.drawBreaks=function(e,m){var h=this,a=h.points,g,d,t,l;if(e&&e.brokenAxis&&e.brokenAxis.hasBreaks){var f=e.brokenAxis;m.forEach(function(m){g=f&&f.breakArray||[];d=e.isXAxis?e.min:r(h.options.threshold,e.min);a.forEach(function(a){l=r(a["stack"+m.toUpperCase()],a[m]);g.forEach(function(f){if(c(d)&&c(l)){t=!1;if(d<f.from&&l>f.to||d>f.from&&l<f.from)t=
"pointBreak";else if(d<f.from&&l>f.from&&l<f.to||d>f.from&&l>f.to&&l<f.from)t="pointInBreak";t&&E(e,t,{point:a,brk:f})}})})})}};D.gappedPath=function(){var e=this.currentDataGrouping,c=e&&e.gapSize;e=this.options.gapSize;var h=this.points.slice(),a=h.length-1,g=this.yAxis,d;if(e&&0<a)for("value"!==this.options.gapUnit&&(e*=this.basePointRange),c&&c>e&&c>=this.basePointRange&&(e=c),d=void 0;a--;)d&&!1!==d.visible||(d=h[a+1]),c=h[a],!1!==d.visible&&!1!==c.visible&&(d.x-c.x>e&&(d=(c.x+d.x)/2,h.splice(a+
1,0,{isNull:!0,x:d}),g.stacking&&this.options.stacking&&(d=g.stacking.stacks[this.stackKey][d]=new A(g,g.options.stackLabels,!1,d,this.stack),d.total=0)),d=c);return this.getGraphPath(h)};y(n,"init",function(){this.brokenAxis||(this.brokenAxis=new u(this))});y(n,"afterInit",function(){"undefined"!==typeof this.brokenAxis&&this.brokenAxis.setBreaks(this.options.breaks,!1)});y(n,"afterSetTickPositions",function(){var e=this.brokenAxis;if(e&&e.hasBreaks){var c=this.tickPositions,h=this.tickPositions.info,
a=[],g;for(g=0;g<c.length;g++)e.isInAnyBreak(c[g])||a.push(c[g]);this.tickPositions=a;this.tickPositions.info=h}});y(n,"afterSetOptions",function(){this.brokenAxis&&this.brokenAxis.hasBreaks&&(this.options.ordinal=!1)});y(q,"afterGeneratePoints",function(){var e=this.options.connectNulls,c=this.points,h=this.xAxis,a=this.yAxis;if(this.isDirty)for(var g=c.length;g--;){var d=c[g],t=!(null===d.y&&!1===e)&&(h&&h.brokenAxis&&h.brokenAxis.isInAnyBreak(d.x,!0)||a&&a.brokenAxis&&a.brokenAxis.isInAnyBreak(d.y,
!0));d.visible=t?!1:!1!==d.options.visible}});y(q,"afterRender",function(){this.drawBreaks(this.xAxis,["x"]);this.drawBreaks(this.yAxis,r(this.pointArrayMap,["y"]))})};return x}();w.compose(b,z);return w});I(b,"Core/Axis/TreeGridAxis.js",[b["Core/Globals.js"],b["Core/Axis/Axis.js"],b["Core/Axis/Tick.js"],b["Gantt/Tree.js"],b["Core/Axis/TreeGridTick.js"],b["Mixins/TreeSeries.js"],b["Core/Utilities.js"]],function(b,z,A,w,y,p,E){var v=p.getLevelOptions,c=E.addEvent,r=E.find,u=E.fireEvent,x=E.isArray,
n=E.isNumber,q=E.isObject,D=E.isString,e=E.merge,m=E.pick,h=E.wrap,a;(function(a){function d(a,k){var d=a.collapseStart||0;a=a.collapseEnd||0;a>=k&&(d-=.5);return{from:d,to:a,showPoints:!1}}function g(a,k,d){var f=[],l=[],C={},e={},g=-1,c="boolean"===typeof k?k:!1;a=w.getTree(a,{after:function(a){a=e[a.pos];var k=0,d=0;a.children.forEach(function(a){d+=(a.descendants||0)+1;k=Math.max((a.height||0)+1,k)});a.descendants=d;a.height=k;a.collapsed&&l.push(a)},before:function(a){var k=q(a.data,!0)?a.data:
{},d=D(k.name)?k.name:"",l=C[a.parent];l=q(l,!0)?e[l.pos]:null;var F=function(a){return a.name===d},t;c&&q(l,!0)&&(t=r(l.children,F))?(F=t.pos,t.nodes.push(a)):F=g++;e[F]||(e[F]=t={depth:l?l.depth+1:0,name:d,id:k.id,nodes:[a],children:[],pos:F},-1!==F&&f.push(d),q(l,!0)&&l.children.push(t));D(a.id)&&(C[a.id]=a);t&&!0===k.collapsed&&(t.collapsed=!0);a.pos=F}});e=function(a,k){var d=function(a,l,f){var C=l+(-1===l?0:k-1),e=(C-l)/2,g=l+e;a.nodes.forEach(function(a){var k=a.data;q(k,!0)&&(k.y=l+(k.seriesIndex||
0),delete k.seriesIndex);a.pos=g});f[g]=a;a.pos=g;a.tickmarkOffset=e+.5;a.collapseStart=C+.5;a.children.forEach(function(a){d(a,C+1,f);C=(a.collapseEnd||0)-.5});a.collapseEnd=C+.5;return f};return d(a["-1"],-1,{})}(e,d);return{categories:f,mapOfIdToNode:C,mapOfPosToGridNode:e,collapsedNodes:l,tree:a}}function l(a){a.target.axes.filter(function(a){return"treegrid"===a.options.type}).forEach(function(k){var d=k.options||{},l=d.labels,f=d.uniqueNames,c=0;d=d.max;if(!k.treeGrid.mapOfPosToGridNode||k.series.some(function(a){return!a.hasRendered||
a.isDirtyData||a.isDirty})){var t=k.series.reduce(function(a,k){k.visible&&((k.options.data||[]).forEach(function(d){k.options.keys&&k.options.keys.length&&(d=k.pointClass.prototype.optionsToObject.call({series:k},d),b.seriesTypes.gantt.prototype.setGanttPointAliases(d));q(d,!0)&&(d.seriesIndex=c,a.push(d))}),!0===f&&c++);return a},[]);if(d&&t.length<d)for(var h=t.length;h<=d;h++)t.push({name:h+"\u200b"});d=g(t,f||!1,!0===f?c:1);k.categories=d.categories;k.treeGrid.mapOfPosToGridNode=d.mapOfPosToGridNode;
k.hasNames=!0;k.treeGrid.tree=d.tree;k.series.forEach(function(a){var k=(a.options.data||[]).map(function(k){x(k)&&a.options.keys&&a.options.keys.length&&t.forEach(function(a){0<=k.indexOf(a.x)&&0<=k.indexOf(a.x2)&&(k=a)});return q(k,!0)?e(k):k});a.visible&&a.setData(k,!1)});k.treeGrid.mapOptionsToLevel=v({defaults:l,from:1,levels:l&&l.levels,to:k.treeGrid.tree&&k.treeGrid.tree.height});"beforeRender"===a.type&&(k.treeGrid.collapsedNodes=d.collapsedNodes)}})}function f(a,k){var d=this.treeGrid.mapOptionsToLevel||
{},l=this.ticks,f=l[k],e;if("treegrid"===this.options.type&&this.treeGrid.mapOfPosToGridNode){var g=this.treeGrid.mapOfPosToGridNode[k];(d=d[g.depth])&&(e={labels:d});f?(f.parameters.category=g.name,f.options=e,f.addLabel()):l[k]=new A(this,k,void 0,void 0,{category:g.name,tickmarkOffset:g.tickmarkOffset,options:e})}else a.apply(this,Array.prototype.slice.call(arguments,1))}function G(a){var k=this.options;k=(k=k&&k.labels)&&n(k.indentation)?k.indentation:0;var d=a.apply(this,Array.prototype.slice.call(arguments,
1));if("treegrid"===this.options.type&&this.treeGrid.mapOfPosToGridNode){var l=this.treeGrid.mapOfPosToGridNode[-1].height||0;d.width+=k*(l-1)}return d}function J(a,k,d){var f=this,C="treegrid"===d.type;f.treeGrid||(f.treeGrid=new p(f));C&&(c(k,"beforeRender",l),c(k,"beforeRedraw",l),c(k,"addSeries",function(a){a.options.data&&(a=g(a.options.data,d.uniqueNames||!1,1),f.treeGrid.collapsedNodes=(f.treeGrid.collapsedNodes||[]).concat(a.collapsedNodes))}),c(f,"foundExtremes",function(){f.treeGrid.collapsedNodes&&
f.treeGrid.collapsedNodes.forEach(function(a){var k=f.treeGrid.collapse(a);f.brokenAxis&&(f.brokenAxis.setBreaks(k,!1),f.treeGrid.collapsedNodes&&(f.treeGrid.collapsedNodes=f.treeGrid.collapsedNodes.filter(function(k){return a.collapseStart!==k.collapseStart||a.collapseEnd!==k.collapseEnd})))})}),c(f,"afterBreaks",function(){var a;"yAxis"===f.coll&&!f.staticScale&&(null===(a=f.chart.options.chart)||void 0===a?0:a.height)&&(f.isDirty=!0)}),d=e({grid:{enabled:!0},labels:{align:"left",levels:[{level:void 0},
{level:1,style:{fontWeight:"bold"}}],symbol:{type:"triangle",x:-5,y:-5,height:10,width:10,padding:5}},uniqueNames:!1},d,{reversed:!0,grid:{columns:void 0}}));a.apply(f,[k,d]);C&&(f.hasNames=!0,f.options.showLastLabel=!0)}function B(a){var k=this.options;"treegrid"===k.type?(this.min=m(this.userMin,k.min,this.dataMin),this.max=m(this.userMax,k.max,this.dataMax),u(this,"foundExtremes"),this.setAxisTranslation(!0),this.tickmarkOffset=.5,this.tickInterval=1,this.tickPositions=this.treeGrid.mapOfPosToGridNode?
this.treeGrid.getTickPositions():[]):a.apply(this,Array.prototype.slice.call(arguments,1))}var M=!1;a.compose=function(a){M||(h(a.prototype,"generateTick",f),h(a.prototype,"getMaxLabelDimensions",G),h(a.prototype,"init",J),h(a.prototype,"setTickInterval",B),y.compose(A),M=!0)};var p=function(){function a(a){this.axis=a}a.prototype.setCollapsedStatus=function(a){var k=this.axis,d=k.chart;k.series.forEach(function(k){var f=k.options.data;if(a.id&&f){var l=d.get(a.id);k=f[k.data.indexOf(l)];l&&k&&(l.collapsed=
a.collapsed,k.collapsed=a.collapsed)}})};a.prototype.collapse=function(a){var k=this.axis,f=k.options.breaks||[],l=d(a,k.max);f.push(l);a.collapsed=!0;k.treeGrid.setCollapsedStatus(a);return f};a.prototype.expand=function(a){var k=this.axis,f=k.options.breaks||[],l=d(a,k.max);a.collapsed=!1;k.treeGrid.setCollapsedStatus(a);return f.reduce(function(a,k){k.to===l.to&&k.from===l.from||a.push(k);return a},[])};a.prototype.getTickPositions=function(){var a=this.axis,d=Math.floor(a.min/a.tickInterval)*
a.tickInterval,f=Math.ceil(a.max/a.tickInterval)*a.tickInterval;return Object.keys(a.treeGrid.mapOfPosToGridNode||{}).reduce(function(k,l){l=+l;!(l>=d&&l<=f)||a.brokenAxis&&a.brokenAxis.isInAnyBreak(l)||k.push(l);return k},[])};a.prototype.isCollapsed=function(a){var k=this.axis,f=k.options.breaks||[],l=d(a,k.max);return f.some(function(a){return a.from===l.from&&a.to===l.to})};a.prototype.toggleCollapse=function(a){return this.isCollapsed(a)?this.expand(a):this.collapse(a)};return a}();a.Additions=
p})(a||(a={}));z.prototype.utils={getNode:w.getNode};a.compose(z);return a});I(b,"Extensions/CurrentDateIndication.js",[b["Core/Axis/Axis.js"],b["Core/Utilities.js"],b["Core/Axis/PlotLineOrBand.js"]],function(b,z,A){var w=z.addEvent,y=z.merge;z=z.wrap;var p={currentDateIndicator:!0,color:"#ccd6eb",width:2,label:{format:"%a, %b %d %Y, %H:%M",formatter:function(b,v){return this.axis.chart.time.dateFormat(v,b)},rotation:0,style:{fontSize:"10px"}}};w(b,"afterSetOptions",function(){var b=this.options,
v=b.currentDateIndicator;v&&(v="object"===typeof v?y(p,v):y(p),v.value=new Date,b.plotLines||(b.plotLines=[]),b.plotLines.push(v))});w(A,"render",function(){this.label&&this.label.attr({text:this.getLabelText(this.options.label)})});z(A.prototype,"getLabelText",function(b,v){var c=this.options;return c.currentDateIndicator&&c.label&&"function"===typeof c.label.formatter?(c.value=new Date,c.label.formatter.call(this,c.value,c.label.format)):b.call(this,v)})});I(b,"Extensions/StaticScale.js",[b["Core/Axis/Axis.js"],
b["Core/Chart/Chart.js"],b["Core/Utilities.js"]],function(b,z,A){var w=A.addEvent,y=A.defined,p=A.isNumber,E=A.pick;w(b,"afterSetOptions",function(){var b=this.chart.options&&this.chart.options.chart;!this.horiz&&p(this.options.staticScale)&&(!b.height||b.scrollablePlotArea&&b.scrollablePlotArea.minHeight)&&(this.staticScale=this.options.staticScale)});z.prototype.adjustHeight=function(){"adjustHeight"!==this.redrawTrigger&&((this.axes||[]).forEach(function(b){var c=b.chart,r=!!c.initiatedScale&&
c.options.animation,u=b.options.staticScale;if(b.staticScale&&y(b.min)){var x=E(b.brokenAxis&&b.brokenAxis.unitLength,b.max+b.tickInterval-b.min)*u;x=Math.max(x,u);u=x-c.plotHeight;1<=Math.abs(u)&&(c.plotHeight=x,c.redrawTrigger="adjustHeight",c.setSize(void 0,c.chartHeight+u,r));b.series.forEach(function(b){(b=b.sharedClipKey&&c[b.sharedClipKey])&&b.attr({height:c.plotHeight})})}}),this.initiatedScale=!0);this.redrawTrigger=null};w(z,"render",z.prototype.adjustHeight)});I(b,"Extensions/ArrowSymbols.js",
[b["Core/Renderer/SVG/SVGRenderer.js"]],function(b){b.prototype.symbols.arrow=function(b,A,w,y){return[["M",b,A+y/2],["L",b+w,A],["L",b,A+y/2],["L",b+w,A+y]]};b.prototype.symbols["arrow-half"]=function(z,A,w,y){return b.prototype.symbols.arrow(z,A,w/2,y)};b.prototype.symbols["triangle-left"]=function(b,A,w,y){return[["M",b+w,A],["L",b,A+y/2],["L",b+w,A+y],["Z"]]};b.prototype.symbols["arrow-filled"]=b.prototype.symbols["triangle-left"];b.prototype.symbols["triangle-left-half"]=function(z,A,w,y){return b.prototype.symbols["triangle-left"](z,
A,w/2,y)};b.prototype.symbols["arrow-filled-half"]=b.prototype.symbols["triangle-left-half"]});I(b,"Gantt/Connection.js",[b["Core/Globals.js"],b["Core/Options.js"],b["Core/Series/Point.js"],b["Core/Utilities.js"]],function(b,z,A,w){function y(c){var b=c.shapeArgs;return b?{xMin:b.x,xMax:b.x+b.width,yMin:b.y,yMax:b.y+b.height}:(b=c.graphic&&c.graphic.getBBox())?{xMin:c.plotX-b.width/2,xMax:c.plotX+b.width/2,yMin:c.plotY-b.height/2,yMax:c.plotY+b.height/2}:null}"";var p=w.defined,E=w.error,v=w.extend,
c=w.merge,r=w.objectEach,u=b.deg2rad,x=Math.max,n=Math.min;v(z.defaultOptions,{connectors:{type:"straight",lineWidth:1,marker:{enabled:!1,align:"center",verticalAlign:"middle",inside:!1,lineWidth:1},startMarker:{symbol:"diamond"},endMarker:{symbol:"arrow-filled"}}});z=function(){function b(c,e,b){this.toPoint=this.pathfinder=this.graphics=this.fromPoint=this.chart=void 0;this.init(c,e,b)}b.prototype.init=function(c,e,b){this.fromPoint=c;this.toPoint=e;this.options=b;this.chart=c.series.chart;this.pathfinder=
this.chart.pathfinder};b.prototype.renderPath=function(c,e,b){var h=this.chart,a=h.styledMode,g=h.pathfinder,d=!h.options.chart.forExport&&!1!==b,t=this.graphics&&this.graphics.path;g.group||(g.group=h.renderer.g().addClass("highcharts-pathfinder-group").attr({zIndex:-1}).add(h.seriesGroup));g.group.translate(h.plotLeft,h.plotTop);t&&t.renderer||(t=h.renderer.path().add(g.group),a||t.attr({opacity:0}));t.attr(e);c={d:c};a||(c.opacity=1);t[d?"animate":"attr"](c,b);this.graphics=this.graphics||{};this.graphics.path=
t};b.prototype.addMarker=function(c,e,b){var h=this.fromPoint.series.chart,a=h.pathfinder;h=h.renderer;var g="start"===c?this.fromPoint:this.toPoint,d=g.getPathfinderAnchorPoint(e);if(e.enabled&&((b="start"===c?b[1]:b[b.length-2])&&"M"===b[0]||"L"===b[0])){b={x:b[1],y:b[2]};b=g.getRadiansToVector(b,d);d=g.getMarkerVector(b,e.radius,d);b=-b/u;if(e.width&&e.height){var t=e.width;var l=e.height}else t=l=2*e.radius;this.graphics=this.graphics||{};d={x:d.x-t/2,y:d.y-l/2,width:t,height:l,rotation:b,rotationOriginX:d.x,
rotationOriginY:d.y};this.graphics[c]?this.graphics[c].animate(d):(this.graphics[c]=h.symbol(e.symbol).addClass("highcharts-point-connecting-path-"+c+"-marker").attr(d).add(a.group),h.styledMode||this.graphics[c].attr({fill:e.color||this.fromPoint.color,stroke:e.lineColor,"stroke-width":e.lineWidth,opacity:0}).animate({opacity:1},g.series.options.animation))}};b.prototype.getPath=function(b){var e=this.pathfinder,m=this.chart,h=e.algorithms[b.type],a=e.chartObstacles;if("function"!==typeof h)return E('"'+
b.type+'" is not a Pathfinder algorithm.'),{path:[],obstacles:[]};h.requiresObstacles&&!a&&(a=e.chartObstacles=e.getChartObstacles(b),m.options.connectors.algorithmMargin=b.algorithmMargin,e.chartObstacleMetrics=e.getObstacleMetrics(a));return h(this.fromPoint.getPathfinderAnchorPoint(b.startMarker),this.toPoint.getPathfinderAnchorPoint(b.endMarker),c({chartObstacles:a,lineObstacles:e.lineObstacles||[],obstacleMetrics:e.chartObstacleMetrics,hardBounds:{xMin:0,xMax:m.plotWidth,yMin:0,yMax:m.plotHeight},
obstacleOptions:{margin:b.algorithmMargin},startDirectionX:e.getAlgorithmStartDirection(b.startMarker)},b))};b.prototype.render=function(){var b=this.fromPoint,e=b.series,m=e.chart,h=m.pathfinder,a=c(m.options.connectors,e.options.connectors,b.options.connectors,this.options),g={};m.styledMode||(g.stroke=a.lineColor||b.color,g["stroke-width"]=a.lineWidth,a.dashStyle&&(g.dashstyle=a.dashStyle));g["class"]="highcharts-point-connecting-path highcharts-color-"+b.colorIndex;a=c(g,a);p(a.marker.radius)||
(a.marker.radius=n(x(Math.ceil((a.algorithmMargin||8)/2)-1,1),5));b=this.getPath(a);m=b.path;b.obstacles&&(h.lineObstacles=h.lineObstacles||[],h.lineObstacles=h.lineObstacles.concat(b.obstacles));this.renderPath(m,g,e.options.animation);this.addMarker("start",c(a.marker,a.startMarker),m);this.addMarker("end",c(a.marker,a.endMarker),m)};b.prototype.destroy=function(){this.graphics&&(r(this.graphics,function(c){c.destroy()}),delete this.graphics)};return b}();b.Connection=z;v(A.prototype,{getPathfinderAnchorPoint:function(c){var b=
y(this);switch(c.align){case "right":var e="xMax";break;case "left":e="xMin"}switch(c.verticalAlign){case "top":var m="yMin";break;case "bottom":m="yMax"}return{x:e?b[e]:(b.xMin+b.xMax)/2,y:m?b[m]:(b.yMin+b.yMax)/2}},getRadiansToVector:function(c,b){var e;p(b)||(e=y(this))&&(b={x:(e.xMin+e.xMax)/2,y:(e.yMin+e.yMax)/2});return Math.atan2(b.y-c.y,c.x-b.x)},getMarkerVector:function(c,b,e){var m=2*Math.PI,h=y(this),a=h.xMax-h.xMin,g=h.yMax-h.yMin,d=Math.atan2(g,a),t=!1;a/=2;var l=g/2,f=h.xMin+a;h=h.yMin+
l;for(var G=f,J=h,B={},u=1,n=1;c<-Math.PI;)c+=m;for(;c>Math.PI;)c-=m;m=Math.tan(c);c>-d&&c<=d?(n=-1,t=!0):c>d&&c<=Math.PI-d?n=-1:c>Math.PI-d||c<=-(Math.PI-d)?(u=-1,t=!0):u=-1;t?(G+=u*a,J+=n*a*m):(G+=g/(2*m)*u,J+=n*l);e.x!==f&&(G=e.x);e.y!==h&&(J=e.y);B.x=G+b*Math.cos(c);B.y=J-b*Math.sin(c);return B}});return z});I(b,"Gantt/PathfinderAlgorithms.js",[b["Core/Utilities.js"]],function(b){function z(c,b,n){n=n||0;var u=c.length-1;b-=1e-7;for(var x,e;n<=u;)if(x=u+n>>1,e=b-c[x].xMin,0<e)n=x+1;else if(0>
e)u=x-1;else return x;return 0<n?n-1:0}function A(c,b){for(var u=z(c,b.x+1)+1;u--;){var q;if(q=c[u].xMax>=b.x)q=c[u],q=b.x<=q.xMax&&b.x>=q.xMin&&b.y<=q.yMax&&b.y>=q.yMin;if(q)return u}return-1}function w(c){var b=[];if(c.length){b.push(["M",c[0].start.x,c[0].start.y]);for(var u=0;u<c.length;++u)b.push(["L",c[u].end.x,c[u].end.y])}return b}function y(b,x){b.yMin=c(b.yMin,x.yMin);b.yMax=v(b.yMax,x.yMax);b.xMin=c(b.xMin,x.xMin);b.xMax=v(b.xMax,x.xMax)}var p=b.extend,E=b.pick,v=Math.min,c=Math.max,r=
Math.abs;b=p(function(c,b,n){function q(a,d,f,c,b){a={x:a.x,y:a.y};a[d]=f[c||d]+(b||0);return a}function u(a,d,f){var c=r(d[f]-a[f+"Min"])>r(d[f]-a[f+"Max"]);return q(d,f,a,f+(c?"Max":"Min"),c?1:-1)}var e=[],m=E(n.startDirectionX,r(b.x-c.x)>r(b.y-c.y))?"x":"y",h=n.chartObstacles,a=A(h,c);n=A(h,b);if(-1<n){var g=h[n];n=u(g,b,m);g={start:n,end:b};var d=n}else d=b;-1<a&&(h=h[a],n=u(h,c,m),e.push({start:c,end:n}),n[m]>=c[m]===n[m]>=d[m]&&(m="y"===m?"x":"y",b=c[m]<b[m],e.push({start:n,end:q(n,m,h,m+(b?
"Max":"Min"),b?1:-1)}),m="y"===m?"x":"y"));c=e.length?e[e.length-1].end:c;n=q(c,m,d);e.push({start:c,end:n});m=q(n,"y"===m?"x":"y",d);e.push({start:n,end:m});e.push(g);return{path:w(e),obstacles:e}},{requiresObstacles:!0});return{fastAvoid:p(function(b,x,n){function q(a,k,d){var f,c=a.x<k.x?1:-1;if(a.x<k.x){var l=a;var b=k}else l=k,b=a;if(a.y<k.y){var e=a;var g=k}else e=k,g=a;for(f=0>c?v(z(B,b.x),B.length-1):0;B[f]&&(0<c&&B[f].xMin<=b.x||0>c&&B[f].xMax>=l.x);){if(B[f].xMin<=b.x&&B[f].xMax>=l.x&&B[f].yMin<=
g.y&&B[f].yMax>=e.y)return d?{y:a.y,x:a.x<k.x?B[f].xMin-1:B[f].xMax+1,obstacle:B[f]}:{x:a.x,y:a.y<k.y?B[f].yMin-1:B[f].yMax+1,obstacle:B[f]};f+=c}return k}function u(a,k,d,f,c){var l=c.soft,b=c.hard,e=f?"x":"y",g={x:k.x,y:k.y},C={x:k.x,y:k.y};c=a[e+"Max"]>=l[e+"Max"];l=a[e+"Min"]<=l[e+"Min"];var t=a[e+"Max"]>=b[e+"Max"];b=a[e+"Min"]<=b[e+"Min"];var h=r(a[e+"Min"]-k[e]),F=r(a[e+"Max"]-k[e]);d=10>r(h-F)?k[e]<d[e]:F<h;C[e]=a[e+"Min"];g[e]=a[e+"Max"];a=q(k,C,f)[e]!==C[e];k=q(k,g,f)[e]!==g[e];d=a?k?d:
!0:k?!1:d;d=l?c?d:!0:c?!1:d;return b?t?d:!0:t?!1:d}function e(a,k,b){if(a.x===k.x&&a.y===k.y)return[];var g=b?"x":"y",C=n.obstacleOptions.margin;var t={soft:{xMin:l,xMax:f,yMin:G,yMax:J},hard:n.hardBounds};var h=A(B,a);if(-1<h){h=B[h];t=u(h,a,k,b,t);y(h,n.hardBounds);var m=b?{y:a.y,x:h[t?"xMax":"xMin"]+(t?1:-1)}:{x:a.x,y:h[t?"yMax":"yMin"]+(t?1:-1)};var H=A(B,m);-1<H&&(H=B[H],y(H,n.hardBounds),m[g]=t?c(h[g+"Max"]-C+1,(H[g+"Min"]+h[g+"Max"])/2):v(h[g+"Min"]+C-1,(H[g+"Max"]+h[g+"Min"])/2),a.x===m.x&&
a.y===m.y?(d&&(m[g]=t?c(h[g+"Max"],H[g+"Max"])+1:v(h[g+"Min"],H[g+"Min"])-1),d=!d):d=!1);a=[{start:a,end:m}]}else g=q(a,{x:b?k.x:a.x,y:b?a.y:k.y},b),a=[{start:a,end:{x:g.x,y:g.y}}],g[b?"x":"y"]!==k[b?"x":"y"]&&(t=u(g.obstacle,g,k,!b,t),y(g.obstacle,n.hardBounds),t={x:b?g.x:g.obstacle[t?"xMax":"xMin"]+(t?1:-1),y:b?g.obstacle[t?"yMax":"yMin"]+(t?1:-1):g.y},b=!b,a=a.concat(e({x:g.x,y:g.y},t,b)));return a=a.concat(e(a[a.length-1].end,k,!b))}function m(a,k,d){var f=v(a.xMax-k.x,k.x-a.xMin)<v(a.yMax-k.y,
k.y-a.yMin);d=u(a,k,d,f,{soft:n.hardBounds,hard:n.hardBounds});return f?{y:k.y,x:a[d?"xMax":"xMin"]+(d?1:-1)}:{x:k.x,y:a[d?"yMax":"yMin"]+(d?1:-1)}}var h=E(n.startDirectionX,r(x.x-b.x)>r(x.y-b.y)),a=h?"x":"y",g=[],d=!1,t=n.obstacleMetrics,l=v(b.x,x.x)-t.maxWidth-10,f=c(b.x,x.x)+t.maxWidth+10,G=v(b.y,x.y)-t.maxHeight-10,J=c(b.y,x.y)+t.maxHeight+10,B=n.chartObstacles;var M=z(B,l);t=z(B,f);B=B.slice(M,t+1);if(-1<(t=A(B,x))){var p=m(B[t],x,b);g.push({end:x,start:p});x=p}for(;-1<(t=A(B,x));)M=0>x[a]-b[a],
p={x:x.x,y:x.y},p[a]=B[t][M?a+"Max":a+"Min"]+(M?1:-1),g.push({end:x,start:p}),x=p;b=e(b,x,h);b=b.concat(g.reverse());return{path:w(b),obstacles:b}},{requiresObstacles:!0}),straight:function(c,b){return{path:[["M",c.x,c.y],["L",b.x,b.y]],obstacles:[{start:c,end:b}]}},simpleConnect:b}});I(b,"Gantt/Pathfinder.js",[b["Gantt/Connection.js"],b["Core/Chart/Chart.js"],b["Core/Globals.js"],b["Core/Options.js"],b["Core/Series/Point.js"],b["Core/Utilities.js"],b["Gantt/PathfinderAlgorithms.js"]],function(b,
z,A,w,y,p,E){function v(a){var d=a.shapeArgs;return d?{xMin:d.x,xMax:d.x+d.width,yMin:d.y,yMax:d.y+d.height}:(d=a.graphic&&a.graphic.getBBox())?{xMin:a.plotX-d.width/2,xMax:a.plotX+d.width/2,yMin:a.plotY-d.height/2,yMax:a.plotY+d.height/2}:null}function c(d){for(var c=d.length,b=0,f,g,m=[],B=function(d,f,c){c=e(c,10);var k=d.yMax+c>f.yMin-c&&d.yMin-c<f.yMax+c,b=d.xMax+c>f.xMin-c&&d.xMin-c<f.xMax+c,l=k?d.xMin>f.xMax?d.xMin-f.xMax:f.xMin-d.xMax:Infinity,g=b?d.yMin>f.yMax?d.yMin-f.yMax:f.yMin-d.yMax:
Infinity;return b&&k?c?B(d,f,Math.floor(c/2)):Infinity:a(l,g)};b<c;++b)for(f=b+1;f<c;++f)g=B(d[b],d[f]),80>g&&m.push(g);m.push(80);return h(Math.floor(m.sort(function(a,d){return a-d})[Math.floor(m.length/10)]/2-1),1)}function r(a){if(a.options.pathfinder||a.series.reduce(function(a,d){d.options&&D(!0,d.options.connectors=d.options.connectors||{},d.options.pathfinder);return a||d.options&&d.options.pathfinder},!1))D(!0,a.options.connectors=a.options.connectors||{},a.options.pathfinder),n('WARNING: Pathfinder options have been renamed. Use "chart.connectors" or "series.connectors" instead.')}
"";var u=p.addEvent,x=p.defined,n=p.error,q=p.extend,D=p.merge,e=p.pick,m=p.splat,h=Math.max,a=Math.min;q(w.defaultOptions,{connectors:{type:"straight",lineWidth:1,marker:{enabled:!1,align:"center",verticalAlign:"middle",inside:!1,lineWidth:1},startMarker:{symbol:"diamond"},endMarker:{symbol:"arrow-filled"}}});var g=function(){function a(a){this.lineObstacles=this.group=this.connections=this.chartObstacleMetrics=this.chartObstacles=this.chart=void 0;this.init(a)}a.prototype.init=function(a){this.chart=
a;this.connections=[];u(a,"redraw",function(){this.pathfinder.update()})};a.prototype.update=function(a){var d=this.chart,f=this,c=f.connections;f.connections=[];d.series.forEach(function(a){a.visible&&!a.options.isInternal&&a.points.forEach(function(a){var k=a.options;k&&k.dependency&&(k.connect=k.dependency);var c;k=a.options&&a.options.connect&&m(a.options.connect);a.visible&&!1!==a.isInside&&k&&k.forEach(function(k){c=d.get("string"===typeof k?k:k.to);c instanceof y&&c.series.visible&&c.visible&&
!1!==c.isInside&&f.connections.push(new b(a,c,"string"===typeof k?{}:k))})})});for(var g=0,e,h,t=c.length,n=f.connections.length;g<t;++g){h=!1;for(e=0;e<n;++e)if(c[g].fromPoint===f.connections[e].fromPoint&&c[g].toPoint===f.connections[e].toPoint){f.connections[e].graphics=c[g].graphics;h=!0;break}h||c[g].destroy()}delete this.chartObstacles;delete this.lineObstacles;f.renderConnections(a)};a.prototype.renderConnections=function(a){a?this.chart.series.forEach(function(a){var d=function(){var d=a.chart.pathfinder;
(d&&d.connections||[]).forEach(function(d){d.fromPoint&&d.fromPoint.series===a&&d.render()});a.pathfinderRemoveRenderEvent&&(a.pathfinderRemoveRenderEvent(),delete a.pathfinderRemoveRenderEvent)};!1===a.options.animation?d():a.pathfinderRemoveRenderEvent=u(a,"afterAnimate",d)}):this.connections.forEach(function(a){a.render()})};a.prototype.getChartObstacles=function(a){for(var d=[],f=this.chart.series,b=e(a.algorithmMargin,0),g,h=0,t=f.length;h<t;++h)if(f[h].visible&&!f[h].options.isInternal)for(var m=
0,n=f[h].points.length,k;m<n;++m)k=f[h].points[m],k.visible&&(k=v(k))&&d.push({xMin:k.xMin-b,xMax:k.xMax+b,yMin:k.yMin-b,yMax:k.yMax+b});d=d.sort(function(a,d){return a.xMin-d.xMin});x(a.algorithmMargin)||(g=a.algorithmMargin=c(d),d.forEach(function(a){a.xMin-=g;a.xMax+=g;a.yMin-=g;a.yMax+=g}));return d};a.prototype.getObstacleMetrics=function(a){for(var d=0,c=0,b,g,e=a.length;e--;)b=a[e].xMax-a[e].xMin,g=a[e].yMax-a[e].yMin,d<b&&(d=b),c<g&&(c=g);return{maxHeight:c,maxWidth:d}};a.prototype.getAlgorithmStartDirection=
function(a){var d="top"!==a.verticalAlign&&"bottom"!==a.verticalAlign;return"left"!==a.align&&"right"!==a.align?d?void 0:!1:d?!0:void 0};return a}();g.prototype.algorithms=E;A.Pathfinder=g;q(y.prototype,{getPathfinderAnchorPoint:function(a){var d=v(this);switch(a.align){case "right":var c="xMax";break;case "left":c="xMin"}switch(a.verticalAlign){case "top":var f="yMin";break;case "bottom":f="yMax"}return{x:c?d[c]:(d.xMin+d.xMax)/2,y:f?d[f]:(d.yMin+d.yMax)/2}},getRadiansToVector:function(a,c){var d;
x(c)||(d=v(this))&&(c={x:(d.xMin+d.xMax)/2,y:(d.yMin+d.yMax)/2});return Math.atan2(c.y-a.y,a.x-c.x)},getMarkerVector:function(a,c,b){var d=2*Math.PI,g=v(this),e=g.xMax-g.xMin,l=g.yMax-g.yMin,h=Math.atan2(l,e),t=!1;e/=2;var m=l/2,k=g.xMin+e;g=g.yMin+m;for(var C=k,F=g,n={},q=1,r=1;a<-Math.PI;)a+=d;for(;a>Math.PI;)a-=d;d=Math.tan(a);a>-h&&a<=h?(r=-1,t=!0):a>h&&a<=Math.PI-h?r=-1:a>Math.PI-h||a<=-(Math.PI-h)?(q=-1,t=!0):q=-1;t?(C+=q*e,F+=r*e*d):(C+=l/(2*d)*q,F+=r*m);b.x!==k&&(C=b.x);b.y!==g&&(F=b.y);n.x=
C+c*Math.cos(a);n.y=F-c*Math.sin(a);return n}});z.prototype.callbacks.push(function(a){!1!==a.options.connectors.enabled&&(r(a),this.pathfinder=new g(this),this.pathfinder.update(!0))});return g});I(b,"Series/XRangeSeries.js",[b["Core/Axis/Axis.js"],b["Core/Series/Series.js"],b["Core/Globals.js"],b["Core/Color/Color.js"],b["Core/Series/Point.js"],b["Core/Utilities.js"]],function(b,z,A,w,y,p){var E=w.parse;w=p.addEvent;var v=p.clamp,c=p.correctFloat,r=p.defined,u=p.find,x=p.isNumber,n=p.isObject,q=
p.merge,D=p.pick,e=A.Series,m=z.seriesTypes,h=m.column;z.seriesType("xrange","column",{colorByPoint:!0,dataLabels:{formatter:function(){var a=this.point.partialFill;n(a)&&(a=a.amount);if(x(a)&&0<a)return c(100*a)+"%"},inside:!0,verticalAlign:"middle"},tooltip:{headerFormat:'<span style="font-size: 10px">{point.x} - {point.x2}</span><br/>',pointFormat:'<span style="color:{point.color}">\u25cf</span> {series.name}: <b>{point.yCategory}</b><br/>'},borderRadius:3,pointRange:0},{type:"xrange",parallelArrays:["x",
"x2","y"],requireSorting:!1,animate:m.line.prototype.animate,cropShoulder:1,getExtremesFromAll:!0,autoIncrement:A.noop,buildKDTree:A.noop,init:function(){m.column.prototype.init.apply(this,arguments);this.options.stacking=void 0},getColumnMetrics:function(){function a(){c.series.forEach(function(a){var d=a.xAxis;a.xAxis=a.yAxis;a.yAxis=d})}var c=this.chart;a();var d=h.prototype.getColumnMetrics.call(this);a();return d},cropData:function(a,c,d,b){c=e.prototype.cropData.call(this,this.x2Data,c,d,b);
c.xData=a.slice(c.start,c.end);return c},findPointIndex:function(a){var c=this.cropped,d=this.cropStart,b=this.points,e=a.id;if(e)var f=(f=u(b,function(a){return a.id===e}))?f.index:void 0;"undefined"===typeof f&&(f=(f=u(b,function(d){return d.x===a.x&&d.x2===a.x2&&!d.touched}))?f.index:void 0);c&&x(f)&&x(d)&&f>=d&&(f-=d);return f},translatePoint:function(a){var c=this.xAxis,d=this.yAxis,b=this.columnMetrics,e=this.options,f=e.minPointLength||0,h=a.plotX,m=D(a.x2,a.x+(a.len||0)),B=c.translate(m,0,
0,0,1);m=Math.abs(B-h);var u=this.chart.inverted,p=D(e.borderWidth,1)%2/2,H=b.offset,k=Math.round(b.width);f&&(f-=m,0>f&&(f=0),h-=f/2,B+=f/2);h=Math.max(h,-10);B=v(B,-10,c.len+10);r(a.options.pointWidth)&&(H-=(Math.ceil(a.options.pointWidth)-k)/2,k=Math.ceil(a.options.pointWidth));e.pointPlacement&&x(a.plotY)&&d.categories&&(a.plotY=d.translate(a.y,0,1,0,1,e.pointPlacement));a.shapeArgs={x:Math.floor(Math.min(h,B))+p,y:Math.floor(a.plotY+H)+p,width:Math.round(Math.abs(B-h)),height:k,r:this.options.borderRadius};
e=a.shapeArgs.x;f=e+a.shapeArgs.width;0>e||f>c.len?(e=v(e,0,c.len),f=v(f,0,c.len),B=f-e,a.dlBox=q(a.shapeArgs,{x:e,width:f-e,centerX:B?B/2:null})):a.dlBox=null;e=a.tooltipPos;f=u?1:0;B=u?0:1;b=this.columnMetrics?this.columnMetrics.offset:-b.width/2;e[f]=v(e[f]+m/2*(c.reversed?-1:1)*(u?-1:1),0,c.len-1);e[B]=v(e[B]+(u?-1:1)*b,0,d.len-1);if(b=a.partialFill)n(b)&&(b=b.amount),x(b)||(b=0),d=a.shapeArgs,a.partShapeArgs={x:d.x,y:d.y,width:d.width,height:d.height,r:this.options.borderRadius},h=Math.max(Math.round(m*
b+a.plotX-h),0),a.clipRectArgs={x:c.reversed?d.x+m-h:d.x,y:d.y,width:h,height:d.height}},translate:function(){h.prototype.translate.apply(this,arguments);this.points.forEach(function(a){this.translatePoint(a)},this)},drawPoint:function(a,c){var d=this.options,b=this.chart.renderer,e=a.graphic,f=a.shapeType,g=a.shapeArgs,h=a.partShapeArgs,m=a.clipRectArgs,r=a.partialFill,u=d.stacking&&!d.borderRadius,H=a.state,k=d.states[H||"normal"]||{},C="undefined"===typeof H?"attr":c;H=this.pointAttribs(a,H);k=
D(this.chart.options.chart.animation,k.animation);if(a.isNull||!1===a.visible)e&&(a.graphic=e.destroy());else{if(e)e.rect[c](g);else a.graphic=e=b.g("point").addClass(a.getClassName()).add(a.group||this.group),e.rect=b[f](q(g)).addClass(a.getClassName()).addClass("highcharts-partfill-original").add(e);h&&(e.partRect?(e.partRect[c](q(h)),e.partialClipRect[c](q(m))):(e.partialClipRect=b.clipRect(m.x,m.y,m.width,m.height),e.partRect=b[f](h).addClass("highcharts-partfill-overlay").add(e).clip(e.partialClipRect)));
this.chart.styledMode||(e.rect[c](H,k).shadow(d.shadow,null,u),h&&(n(r)||(r={}),n(d.partialFill)&&(r=q(d.partialFill,r)),a=r.fill||E(H.fill).brighten(-.3).get()||E(a.color||this.color).brighten(-.3).get(),H.fill=a,e.partRect[C](H,k).shadow(d.shadow,null,u)))}},drawPoints:function(){var a=this,c=a.getAnimationVerb();a.points.forEach(function(d){a.drawPoint(d,c)})},getAnimationVerb:function(){return this.chart.pointCount<(this.options.animationLimit||250)?"animate":"attr"}},{resolveColor:function(){var a=
this.series;if(a.options.colorByPoint&&!this.options.color){var c=a.options.colors||a.chart.options.colors;var d=this.y%(c?c.length:a.chart.options.chart.colorCount);c=c&&c[d];a.chart.styledMode||(this.color=c);this.options.colorIndex||(this.colorIndex=d)}else this.color||(this.color=a.color)},init:function(){y.prototype.init.apply(this,arguments);this.y||(this.y=0);return this},setState:function(){y.prototype.setState.apply(this,arguments);this.series.drawPoint(this,this.series.getAnimationVerb())},
getLabelConfig:function(){var a=y.prototype.getLabelConfig.call(this),c=this.series.yAxis.categories;a.x2=this.x2;a.yCategory=this.yCategory=c&&c[this.y];return a},tooltipDateKeys:["x","x2"],isValid:function(){return"number"===typeof this.x&&"number"===typeof this.x2}});w(b,"afterGetSeriesExtremes",function(){var a=this.series,c;if(this.isXAxis){var d=D(this.dataMax,-Number.MAX_VALUE);a.forEach(function(a){a.x2Data&&a.x2Data.forEach(function(a){a>d&&(d=a,c=!0)})});c&&(this.dataMax=d)}});""});I(b,
"Series/GanttSeries.js",[b["Core/Series/Series.js"],b["Core/Globals.js"],b["Core/Options.js"],b["Core/Utilities.js"]],function(b,z,A,w){var y=w.isNumber;A=w.merge;var p=w.pick,E=w.splat,v=b.seriesTypes.xrange;b.seriesType("gantt","xrange",{grouping:!1,dataLabels:{enabled:!0},tooltip:{headerFormat:'<span style="font-size: 10px">{series.name}</span><br/>',pointFormat:null,pointFormatter:function(){var c=this.series,b=c.chart.tooltip,u=c.xAxis,x=c.tooltipOptions.dateTimeLabelFormats,n=u.options.startOfWeek,
q=c.tooltipOptions,p=q.xDateFormat,e=this.options.milestone,m="<b>"+(this.name||this.yCategory)+"</b>";if(q.pointFormat)return this.tooltipFormatter(q.pointFormat);p||(p=E(b.getDateFormat(u.closestPointRange,this.start,n,x))[0]);b=c.chart.time.dateFormat(p,this.start);c=c.chart.time.dateFormat(p,this.end);m+="<br/>";return e?m+(b+"<br/>"):m+("Start: "+b+"<br/>End: ")+(c+"<br/>")}},connectors:{type:"simpleConnect",animation:{reversed:!0},startMarker:{enabled:!0,symbol:"arrow-filled",radius:4,fill:"#fa0",
align:"left"},endMarker:{enabled:!1,align:"right"}}},{pointArrayMap:["start","end","y"],keyboardMoveVertical:!1,translatePoint:function(c){v.prototype.translatePoint.call(this,c);if(c.options.milestone){var b=c.shapeArgs;var u=b.height;c.shapeArgs={x:b.x-u/2,y:b.y,width:u,height:u}}},drawPoint:function(c,b){var u=this.options,r=this.chart.renderer,n=c.shapeArgs,q=c.plotY,p=c.graphic,e=c.selected&&"select",m=u.stacking&&!u.borderRadius;if(c.options.milestone)if(y(q)&&null!==c.y&&!1!==c.visible){n=
r.symbols.diamond(n.x,n.y,n.width,n.height);if(p)p[b]({d:n});else c.graphic=r.path(n).addClass(c.getClassName(),!0).add(c.group||this.group);this.chart.styledMode||c.graphic.attr(this.pointAttribs(c,e)).shadow(u.shadow,null,m)}else p&&(c.graphic=p.destroy());else v.prototype.drawPoint.call(this,c,b)},setData:z.Series.prototype.setData,setGanttPointAliases:function(c){function b(b,r){"undefined"!==typeof r&&(c[b]=r)}b("x",p(c.start,c.x));b("x2",p(c.end,c.x2));b("partialFill",p(c.completed,c.partialFill))}},
A(v.prototype.pointClass.prototype,{applyOptions:function(c,b){c=v.prototype.pointClass.prototype.applyOptions.call(this,c,b);z.seriesTypes.gantt.prototype.setGanttPointAliases(c);return c},isValid:function(){return("number"===typeof this.start||"number"===typeof this.x)&&("number"===typeof this.end||"number"===typeof this.x2||this.milestone)}}));""});I(b,"Core/Chart/GanttChart.js",[b["Core/Chart/Chart.js"],b["Core/Globals.js"],b["Core/Utilities.js"]],function(b,z,A){var w=A.getOptions,y=A.isArray,
p=A.merge,E=A.splat;z.ganttChart=function(v,c,r){var u="string"===typeof v||v.nodeName,x=c.series,n=w(),q,z=c;c=arguments[u?1:0];y(c.xAxis)||(c.xAxis=[c.xAxis||{},{}]);c.xAxis=c.xAxis.map(function(c,b){1===b&&(q=0);return p(n.xAxis,{grid:{enabled:!0},opposite:!0,linkedTo:q},c,{type:"datetime"})});c.yAxis=E(c.yAxis||{}).map(function(c){return p(n.yAxis,{grid:{enabled:!0},staticScale:50,reversed:!0,type:c.categories?c.type:"treegrid"},c)});c.series=null;c=p(!0,{chart:{type:"gantt"},title:{text:null},
legend:{enabled:!1},navigator:{series:{type:"gantt"},yAxis:{type:"category"}}},c,{isGantt:!0});c.series=z.series=x;return u?new b(v,c,r):new b(c,c)}});I(b,"Core/Axis/ScrollbarAxis.js",[b["Core/Globals.js"],b["Core/Utilities.js"]],function(b,z){var A=z.addEvent,w=z.defined,y=z.pick;return function(){function p(){}p.compose=function(p,v){A(p,"afterInit",function(){var c=this;c.options&&c.options.scrollbar&&c.options.scrollbar.enabled&&(c.options.scrollbar.vertical=!c.horiz,c.options.startOnTick=c.options.endOnTick=
!1,c.scrollbar=new v(c.chart.renderer,c.options.scrollbar,c.chart),A(c.scrollbar,"changed",function(r){var u=y(c.options&&c.options.min,c.min),p=y(c.options&&c.options.max,c.max),n=w(c.dataMin)?Math.min(u,c.min,c.dataMin):u,q=(w(c.dataMax)?Math.max(p,c.max,c.dataMax):p)-n;w(u)&&w(p)&&(c.horiz&&!c.reversed||!c.horiz&&c.reversed?(u=n+q*this.to,n+=q*this.from):(u=n+q*(1-this.from),n+=q*(1-this.to)),y(this.options.liveRedraw,b.svg&&!b.isTouchDevice&&!this.chart.isBoosting)||"mouseup"===r.DOMType||!w(r.DOMType)?
c.setExtremes(n,u,!0,"mousemove"!==r.DOMType,r):this.setRange(this.from,this.to))}))});A(p,"afterRender",function(){var c=Math.min(y(this.options.min,this.min),this.min,y(this.dataMin,this.min)),b=Math.max(y(this.options.max,this.max),this.max,y(this.dataMax,this.max)),u=this.scrollbar,p=this.axisTitleMargin+(this.titleOffset||0),n=this.chart.scrollbarsOffsets,q=this.options.margin||0;u&&(this.horiz?(this.opposite||(n[1]+=p),u.position(this.left,this.top+this.height+2+n[1]-(this.opposite?q:0),this.width,
this.height),this.opposite||(n[1]+=q),p=1):(this.opposite&&(n[0]+=p),u.position(this.left+this.width+2+n[0]-(this.opposite?0:q),this.top,this.width,this.height),this.opposite&&(n[0]+=q),p=0),n[p]+=u.size+u.options.margin,isNaN(c)||isNaN(b)||!w(this.min)||!w(this.max)||this.min===this.max?u.setRange(0,1):(n=(this.min-c)/(b-c),c=(this.max-c)/(b-c),this.horiz&&!this.reversed||!this.horiz&&this.reversed?u.setRange(n,c):u.setRange(1-c,1-n)))});A(p,"afterGetOffset",function(){var c=this.horiz?2:1,b=this.scrollbar;
b&&(this.chart.scrollbarsOffsets=[0,0],this.chart.axisOffset[c]+=b.size+b.options.margin)})};return p}()});I(b,"Core/Scrollbar.js",[b["Core/Axis/Axis.js"],b["Core/Globals.js"],b["Core/Axis/ScrollbarAxis.js"],b["Core/Utilities.js"],b["Core/Options.js"]],function(b,z,A,w,y){var p=w.addEvent,E=w.correctFloat,v=w.defined,c=w.destroyObjectProperties,r=w.fireEvent,u=w.merge,x=w.pick,n=w.removeEvent;w=y.defaultOptions;var q=z.hasTouch,D=z.isTouchDevice,e=z.swapXY=function(c,b){b&&c.forEach(function(a){for(var c=
a.length,d,b=0;b<c;b+=2)d=a[b+1],"number"===typeof d&&(a[b+1]=a[b+2],a[b+2]=d)});return c};y=function(){function b(b,a,c){this._events=[];this.from=this.chartY=this.chartX=0;this.scrollbar=this.group=void 0;this.scrollbarButtons=[];this.scrollbarGroup=void 0;this.scrollbarLeft=0;this.scrollbarRifles=void 0;this.scrollbarStrokeWidth=1;this.to=this.size=this.scrollbarTop=0;this.track=void 0;this.trackBorderWidth=1;this.userOptions={};this.y=this.x=0;this.chart=c;this.options=a;this.renderer=c.renderer;
this.init(b,a,c)}b.prototype.addEvents=function(){var b=this.options.inverted?[1,0]:[0,1],a=this.scrollbarButtons,c=this.scrollbarGroup.element,d=this.track.element,e=this.mouseDownHandler.bind(this),l=this.mouseMoveHandler.bind(this),f=this.mouseUpHandler.bind(this);b=[[a[b[0]].element,"click",this.buttonToMinClick.bind(this)],[a[b[1]].element,"click",this.buttonToMaxClick.bind(this)],[d,"click",this.trackClick.bind(this)],[c,"mousedown",e],[c.ownerDocument,"mousemove",l],[c.ownerDocument,"mouseup",
f]];q&&b.push([c,"touchstart",e],[c.ownerDocument,"touchmove",l],[c.ownerDocument,"touchend",f]);b.forEach(function(a){p.apply(null,a)});this._events=b};b.prototype.buttonToMaxClick=function(b){var a=(this.to-this.from)*x(this.options.step,.2);this.updatePosition(this.from+a,this.to+a);r(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:b})};b.prototype.buttonToMinClick=function(b){var a=E(this.to-this.from)*x(this.options.step,.2);this.updatePosition(E(this.from-a),E(this.to-
a));r(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:b})};b.prototype.cursorToScrollbarPosition=function(b){var a=this.options;a=a.minWidth>this.calculatedWidth?a.minWidth:0;return{chartX:(b.chartX-this.x-this.xOffset)/(this.barWidth-a),chartY:(b.chartY-this.y-this.yOffset)/(this.barWidth-a)}};b.prototype.destroy=function(){var b=this.chart.scroller;this.removeEvents();["track","scrollbarRifles","scrollbar","scrollbarGroup","group"].forEach(function(a){this[a]&&this[a].destroy&&
(this[a]=this[a].destroy())},this);b&&this===b.scrollbar&&(b.scrollbar=null,c(b.scrollbarButtons))};b.prototype.drawScrollbarButton=function(b){var a=this.renderer,c=this.scrollbarButtons,d=this.options,h=this.size;var l=a.g().add(this.group);c.push(l);l=a.rect().addClass("highcharts-scrollbar-button").add(l);this.chart.styledMode||l.attr({stroke:d.buttonBorderColor,"stroke-width":d.buttonBorderWidth,fill:d.buttonBackgroundColor});l.attr(l.crisp({x:-.5,y:-.5,width:h+1,height:h+1,r:d.buttonBorderRadius},
l.strokeWidth()));l=a.path(e([["M",h/2+(b?-1:1),h/2-3],["L",h/2+(b?-1:1),h/2+3],["L",h/2+(b?2:-2),h/2]],d.vertical)).addClass("highcharts-scrollbar-arrow").add(c[b]);this.chart.styledMode||l.attr({fill:d.buttonArrowColor})};b.prototype.init=function(c,a,e){this.scrollbarButtons=[];this.renderer=c;this.userOptions=a;this.options=u(b.defaultOptions,a);this.chart=e;this.size=x(this.options.size,this.options.height);a.enabled&&(this.render(),this.addEvents())};b.prototype.mouseDownHandler=function(b){b=
this.chart.pointer.normalize(b);b=this.cursorToScrollbarPosition(b);this.chartX=b.chartX;this.chartY=b.chartY;this.initPositions=[this.from,this.to];this.grabbedCenter=!0};b.prototype.mouseMoveHandler=function(b){var a=this.chart.pointer.normalize(b),c=this.options.vertical?"chartY":"chartX",d=this.initPositions||[];!this.grabbedCenter||b.touches&&0===b.touches[0][c]||(a=this.cursorToScrollbarPosition(a)[c],c=this[c],c=a-c,this.hasDragged=!0,this.updatePosition(d[0]+c,d[1]+c),this.hasDragged&&r(this,
"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMType:b.type,DOMEvent:b}))};b.prototype.mouseUpHandler=function(b){this.hasDragged&&r(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMType:b.type,DOMEvent:b});this.grabbedCenter=this.hasDragged=this.chartX=this.chartY=null};b.prototype.position=function(b,a,c,d){var e=this.options.vertical,g=0,f=this.rendered?"animate":"attr";this.x=b;this.y=a+this.trackBorderWidth;this.width=c;this.xOffset=this.height=d;this.yOffset=g;e?
(this.width=this.yOffset=c=g=this.size,this.xOffset=a=0,this.barWidth=d-2*c,this.x=b+=this.options.margin):(this.height=this.xOffset=d=a=this.size,this.barWidth=c-2*d,this.y+=this.options.margin);this.group[f]({translateX:b,translateY:this.y});this.track[f]({width:c,height:d});this.scrollbarButtons[1][f]({translateX:e?0:c-a,translateY:e?d-g:0})};b.prototype.removeEvents=function(){this._events.forEach(function(b){n.apply(null,b)});this._events.length=0};b.prototype.render=function(){var b=this.renderer,
a=this.options,c=this.size,d=this.chart.styledMode,m;this.group=m=b.g("scrollbar").attr({zIndex:a.zIndex,translateY:-99999}).add();this.track=b.rect().addClass("highcharts-scrollbar-track").attr({x:0,r:a.trackBorderRadius||0,height:c,width:c}).add(m);d||this.track.attr({fill:a.trackBackgroundColor,stroke:a.trackBorderColor,"stroke-width":a.trackBorderWidth});this.trackBorderWidth=this.track.strokeWidth();this.track.attr({y:-this.trackBorderWidth%2/2});this.scrollbarGroup=b.g().add(m);this.scrollbar=
b.rect().addClass("highcharts-scrollbar-thumb").attr({height:c,width:c,r:a.barBorderRadius||0}).add(this.scrollbarGroup);this.scrollbarRifles=b.path(e([["M",-3,c/4],["L",-3,2*c/3],["M",0,c/4],["L",0,2*c/3],["M",3,c/4],["L",3,2*c/3]],a.vertical)).addClass("highcharts-scrollbar-rifles").add(this.scrollbarGroup);d||(this.scrollbar.attr({fill:a.barBackgroundColor,stroke:a.barBorderColor,"stroke-width":a.barBorderWidth}),this.scrollbarRifles.attr({stroke:a.rifleColor,"stroke-width":1}));this.scrollbarStrokeWidth=
this.scrollbar.strokeWidth();this.scrollbarGroup.translate(-this.scrollbarStrokeWidth%2/2,-this.scrollbarStrokeWidth%2/2);this.drawScrollbarButton(0);this.drawScrollbarButton(1)};b.prototype.setRange=function(b,a){var c=this.options,d=c.vertical,e=c.minWidth,l=this.barWidth,f,h=!this.rendered||this.hasDragged||this.chart.navigator&&this.chart.navigator.hasDragged?"attr":"animate";if(v(l)){b=Math.max(b,0);var m=Math.ceil(l*b);this.calculatedWidth=f=E(l*Math.min(a,1)-m);f<e&&(m=(l-e+f)*b,f=e);e=Math.floor(m+
this.xOffset+this.yOffset);l=f/2-.5;this.from=b;this.to=a;d?(this.scrollbarGroup[h]({translateY:e}),this.scrollbar[h]({height:f}),this.scrollbarRifles[h]({translateY:l}),this.scrollbarTop=e,this.scrollbarLeft=0):(this.scrollbarGroup[h]({translateX:e}),this.scrollbar[h]({width:f}),this.scrollbarRifles[h]({translateX:l}),this.scrollbarLeft=e,this.scrollbarTop=0);12>=f?this.scrollbarRifles.hide():this.scrollbarRifles.show(!0);!1===c.showFull&&(0>=b&&1<=a?this.group.hide():this.group.show());this.rendered=
!0}};b.prototype.trackClick=function(b){var a=this.chart.pointer.normalize(b),c=this.to-this.from,d=this.y+this.scrollbarTop,e=this.x+this.scrollbarLeft;this.options.vertical&&a.chartY>d||!this.options.vertical&&a.chartX>e?this.updatePosition(this.from+c,this.to+c):this.updatePosition(this.from-c,this.to-c);r(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:b})};b.prototype.update=function(b){this.destroy();this.init(this.chart.renderer,u(!0,this.options,b),this.chart)};b.prototype.updatePosition=
function(b,a){1<a&&(b=E(1-E(a-b)),a=1);0>b&&(a=E(a-b),b=0);this.from=b;this.to=a};b.defaultOptions={height:D?20:14,barBorderRadius:0,buttonBorderRadius:0,liveRedraw:void 0,margin:10,minWidth:6,step:.2,zIndex:3,barBackgroundColor:"#cccccc",barBorderWidth:1,barBorderColor:"#cccccc",buttonArrowColor:"#333333",buttonBackgroundColor:"#e6e6e6",buttonBorderColor:"#cccccc",buttonBorderWidth:1,rifleColor:"#333333",trackBackgroundColor:"#f2f2f2",trackBorderColor:"#f2f2f2",trackBorderWidth:1};return b}();z.Scrollbar||
(w.scrollbar=u(!0,y.defaultOptions,w.scrollbar),z.Scrollbar=y,A.compose(b,y));return z.Scrollbar});I(b,"Extensions/RangeSelector.js",[b["Core/Axis/Axis.js"],b["Core/Chart/Chart.js"],b["Core/Globals.js"],b["Core/Options.js"],b["Core/Renderer/SVG/SVGElement.js"],b["Core/Utilities.js"]],function(b,z,A,w,y,p){var E=w.defaultOptions,v=p.addEvent,c=p.createElement,r=p.css,u=p.defined,x=p.destroyObjectProperties,n=p.discardElement,q=p.extend,D=p.fireEvent,e=p.isNumber,m=p.merge,h=p.objectEach,a=p.pick,g=
p.pInt,d=p.splat;q(E,{rangeSelector:{verticalAlign:"top",buttonTheme:{width:28,height:18,padding:2,zIndex:7},floating:!1,x:0,y:0,height:void 0,inputPosition:{align:"right",x:0,y:0},buttonPosition:{align:"left",x:0,y:0},labelStyle:{color:"#666666"}}});E.lang=m(E.lang,{rangeSelectorZoom:"Zoom",rangeSelectorFrom:"From",rangeSelectorTo:"To"});var t=function(){function l(a){this.buttons=void 0;this.buttonOptions=l.prototype.defaultButtons;this.options=void 0;this.chart=a;this.init(a)}l.prototype.clickButton=
function(c,g){var f=this.chart,l=this.buttonOptions[c],h=f.xAxis[0],m=f.scroller&&f.scroller.getUnionExtremes()||h||{},n=m.dataMin,k=m.dataMax,C=h&&Math.round(Math.min(h.max,a(k,h.max))),F=l.type;m=l._range;var q,t=l.dataGrouping;if(null!==n&&null!==k){f.fixedRange=m;t&&(this.forcedDataGrouping=!0,b.prototype.setDataGrouping.call(h||{chart:this.chart},t,!1),this.frozenStates=l.preserveDataGrouping);if("month"===F||"year"===F)if(h){F={range:l,max:C,chart:f,dataMin:n,dataMax:k};var p=h.minFromRange.call(F);
e(F.newMax)&&(C=F.newMax)}else m=l;else if(m)p=Math.max(C-m,n),C=Math.min(p+m,k);else if("ytd"===F)if(h)"undefined"===typeof k&&(n=Number.MAX_VALUE,k=Number.MIN_VALUE,f.series.forEach(function(a){a=a.xData;n=Math.min(a[0],n);k=Math.max(a[a.length-1],k)}),g=!1),C=this.getYTDExtremes(k,n,f.time.useUTC),p=q=C.min,C=C.max;else{this.deferredYTDClick=c;return}else"all"===F&&h&&(p=n,C=k);u(p)&&(p+=l._offsetMin);u(C)&&(C+=l._offsetMax);this.setSelected(c);if(h)h.setExtremes(p,C,a(g,1),null,{trigger:"rangeSelectorButton",
rangeSelectorButton:l});else{var r=d(f.options.xAxis)[0];var S=r.range;r.range=m;var G=r.min;r.min=q;v(f,"load",function(){r.range=S;r.min=G})}}};l.prototype.setSelected=function(a){this.selected=this.options.selected=a};l.prototype.init=function(a){var b=this,c=a.options.rangeSelector,d=c.buttons||b.defaultButtons.slice(),e=c.selected,f=function(){var a=b.minInput,c=b.maxInput;a&&a.blur&&D(a,"blur");c&&c.blur&&D(c,"blur")};b.chart=a;b.options=c;b.buttons=[];b.buttonOptions=d;this.unMouseDown=v(a.container,
"mousedown",f);this.unResize=v(a,"resize",f);d.forEach(b.computeButtonRange);"undefined"!==typeof e&&d[e]&&this.clickButton(e,!1);v(a,"load",function(){a.xAxis&&a.xAxis[0]&&v(a.xAxis[0],"setExtremes",function(c){this.max-this.min!==a.fixedRange&&"rangeSelectorButton"!==c.trigger&&"updatedData"!==c.trigger&&b.forcedDataGrouping&&!b.frozenStates&&this.setDataGrouping(!1,!1)})})};l.prototype.updateButtonStates=function(){var a=this,b=this.chart,c=b.xAxis[0],d=Math.round(c.max-c.min),g=!c.hasVisibleSeries,
l=b.scroller&&b.scroller.getUnionExtremes()||c,h=l.dataMin,k=l.dataMax;b=a.getYTDExtremes(k,h,b.time.useUTC);var C=b.min,m=b.max,n=a.selected,q=e(n),t=a.options.allButtonsEnabled,u=a.buttons;a.buttonOptions.forEach(function(b,e){var f=b._range,l=b.type,F=b.count||1,B=u[e],p=0,r=b._offsetMax-b._offsetMin;b=e===n;var H=f>k-h,J=f<c.minRange,P=!1,x=!1;f=f===d;("month"===l||"year"===l)&&d+36E5>=864E5*{month:28,year:365}[l]*F-r&&d-36E5<=864E5*{month:31,year:366}[l]*F+r?f=!0:"ytd"===l?(f=m-C+r===d,P=!b):
"all"===l&&(f=c.max-c.min>=k-h,x=!b&&q&&f);l=!t&&(H||J||x||g);F=b&&f||f&&!q&&!P||b&&a.frozenStates;l?p=3:F&&(q=!0,p=2);B.state!==p&&(B.setState(p),0===p&&n===e&&a.setSelected(null))})};l.prototype.computeButtonRange=function(b){var c=b.type,d=b.count||1,e={millisecond:1,second:1E3,minute:6E4,hour:36E5,day:864E5,week:6048E5};if(e[c])b._range=e[c]*d;else if("month"===c||"year"===c)b._range=864E5*{month:30,year:365}[c]*d;b._offsetMin=a(b.offsetMin,0);b._offsetMax=a(b.offsetMax,0);b._range+=b._offsetMax-
b._offsetMin};l.prototype.setInputValue=function(a,b){var c=this.chart.options.rangeSelector,d=this.chart.time,e=this[a+"Input"];u(b)&&(e.previousValue=e.HCTime,e.HCTime=b);e.value=d.dateFormat(c.inputEditDateFormat||"%Y-%m-%d",e.HCTime);this[a+"DateBox"].attr({text:d.dateFormat(c.inputDateFormat||"%b %e, %Y",e.HCTime)})};l.prototype.showInput=function(a){var b=this.inputGroup,c=this[a+"DateBox"];r(this[a+"Input"],{left:b.translateX+c.x+"px",top:b.translateY+"px",width:c.width-2+"px",height:c.height-
2+"px",border:"2px solid silver"})};l.prototype.hideInput=function(a){r(this[a+"Input"],{border:0,width:"1px",height:"1px"});this.setInputValue(a)};l.prototype.defaultInputDateParser=function(a,b){var c=new Date;return A.isSafari?Date.parse(a.split(" ").join("T")):b?Date.parse(a+"Z"):Date.parse(a)-6E4*c.getTimezoneOffset()};l.prototype.drawInput=function(a){function b(){var a=F.value,b=f.xAxis[0];var c=f.scroller&&f.scroller.xAxis?f.scroller.xAxis:b;var k=c.dataMin,l=c.dataMax;c=(n.inputDateParser||
u)(a,f.time.useUTC);c!==F.previousValue&&(F.previousValue=c,e(c)||(c=a.split("-"),c=Date.UTC(g(c[0]),g(c[1])-1,g(c[2]))),e(c)&&(f.time.useUTC||(c+=6E4*(new Date).getTimezoneOffset()),C?c>d.maxInput.HCTime?c=void 0:c<k&&(c=k):c<d.minInput.HCTime?c=void 0:c>l&&(c=l),"undefined"!==typeof c&&b.setExtremes(C?c:b.min,C?b.max:c,void 0,void 0,{trigger:"rangeSelectorInput"})))}var d=this,f=d.chart,l=f.renderer.style||{},h=f.renderer,n=f.options.rangeSelector,k=d.div,C="min"===a,F,t,p=this.inputGroup,u=this.defaultInputDateParser;
this[a+"Label"]=t=h.label(E.lang[C?"rangeSelectorFrom":"rangeSelectorTo"],this.inputGroup.offset).addClass("highcharts-range-label").attr({padding:2}).add(p);p.offset+=t.width+5;this[a+"DateBox"]=h=h.label("",p.offset).addClass("highcharts-range-input").attr({padding:2,width:n.inputBoxWidth||90,height:n.inputBoxHeight||17,"text-align":"center"}).on("click",function(){d.showInput(a);d[a+"Input"].focus()});f.styledMode||h.attr({stroke:n.inputBoxBorderColor||"#cccccc","stroke-width":1});h.add(p);p.offset+=
h.width+(C?10:0);this[a+"Input"]=F=c("input",{name:a,className:"highcharts-range-selector",type:"text"},{top:f.plotTop+"px"},k);f.styledMode||(t.css(m(l,n.labelStyle)),h.css(m({color:"#333333"},l,n.inputStyle)),r(F,q({position:"absolute",border:0,width:"1px",height:"1px",padding:0,textAlign:"center",fontSize:l.fontSize,fontFamily:l.fontFamily,top:"-9999em"},n.inputStyle)));F.onfocus=function(){d.showInput(a)};F.onblur=function(){F===A.doc.activeElement&&b();d.hideInput(a);F.blur()};F.onchange=b;F.onkeypress=
function(a){13===a.keyCode&&b()}};l.prototype.getPosition=function(){var a=this.chart,b=a.options.rangeSelector;a="top"===b.verticalAlign?a.plotTop-a.axisOffset[0]:0;return{buttonTop:a+b.buttonPosition.y,inputTop:a+b.inputPosition.y-10}};l.prototype.getYTDExtremes=function(a,b,c){var d=this.chart.time,e=new d.Date(a),f=d.get("FullYear",e);c=c?d.Date.UTC(f,0,1):+new d.Date(f,0,1);b=Math.max(b||0,c);e=e.getTime();return{max:Math.min(a||e,e),min:b}};l.prototype.render=function(b,d){var e=this,f=e.chart,
l=f.renderer,g=f.container,h=f.options,k=h.exporting&&!1!==h.exporting.enabled&&h.navigation&&h.navigation.buttonOptions,C=E.lang,m=e.div,n=h.rangeSelector,q=a(h.chart.style&&h.chart.style.zIndex,0)+1;h=n.floating;var t=e.buttons;m=e.inputGroup;var p=n.buttonTheme,u=n.buttonPosition,r=n.inputPosition,x=n.inputEnabled,y=p&&p.states,v=f.plotLeft,w=e.buttonGroup,z,A=e.options.verticalAlign,D=f.legend,G=D&&D.options,I=u.y,O=r.y,K=f.hasLoaded,Q=K?"animate":"attr",N=0,L=0;if(!1!==n.enabled){e.rendered||
(e.group=z=l.g("range-selector-group").attr({zIndex:7}).add(),e.buttonGroup=w=l.g("range-selector-buttons").add(z),e.zoomText=l.text(C.rangeSelectorZoom,0,15).add(w),f.styledMode||(e.zoomText.css(n.labelStyle),p["stroke-width"]=a(p["stroke-width"],0)),e.buttonOptions.forEach(function(a,b){t[b]=l.button(a.text,0,0,function(c){var d=a.events&&a.events.click,k;d&&(k=d.call(a,c));!1!==k&&e.clickButton(b);e.isActive=!0},p,y&&y.hover,y&&y.select,y&&y.disabled).attr({"text-align":"center"}).add(w)}),!1!==
x&&(e.div=m=c("div",null,{position:"relative",height:0,zIndex:q}),g.parentNode.insertBefore(m,g),e.inputGroup=m=l.g("input-group").add(z),m.offset=0,e.drawInput("min"),e.drawInput("max")));e.zoomText[Q]({x:a(v+u.x,v)});var R=a(v+u.x,v)+e.zoomText.getBBox().width+5;e.buttonOptions.forEach(function(b,c){t[c][Q]({x:R});R+=t[c].width+a(n.buttonSpacing,5)});v=f.plotLeft-f.spacing[3];e.updateButtonStates();k&&this.titleCollision(f)&&"top"===A&&"right"===u.align&&u.y+w.getBBox().height-12<(k.y||0)+k.height&&
(N=-40);g=u.x-f.spacing[3];"right"===u.align?g+=N-v:"center"===u.align&&(g-=v/2);w.align({y:u.y,width:w.getBBox().width,align:u.align,x:g},!0,f.spacingBox);e.group.placed=K;e.buttonGroup.placed=K;!1!==x&&(N=k&&this.titleCollision(f)&&"top"===A&&"right"===r.align&&r.y-m.getBBox().height-12<(k.y||0)+k.height+f.spacing[0]?-40:0,"left"===r.align?g=v:"right"===r.align&&(g=-Math.max(f.axisOffset[1],-N)),m.align({y:r.y,width:m.getBBox().width,align:r.align,x:r.x+g-2},!0,f.spacingBox),k=m.alignAttr.translateX+
m.alignOptions.x-N+m.getBBox().x+2,g=m.alignOptions.width,C=w.alignAttr.translateX+w.getBBox().x,v=w.getBBox().width+20,(r.align===u.align||C+v>k&&k+g>C&&I<O+m.getBBox().height)&&m.attr({translateX:m.alignAttr.translateX+(f.axisOffset[1]>=-N?0:-N),translateY:m.alignAttr.translateY+w.getBBox().height+10}),e.setInputValue("min",b),e.setInputValue("max",d),e.inputGroup.placed=K);e.group.align({verticalAlign:A},!0,f.spacingBox);b=e.group.getBBox().height+20;d=e.group.alignAttr.translateY;"bottom"===A&&
(D=G&&"bottom"===G.verticalAlign&&G.enabled&&!G.floating?D.legendHeight+a(G.margin,10):0,b=b+D-20,L=d-b-(h?0:n.y)-(f.titleOffset?f.titleOffset[2]:0)-10);if("top"===A)h&&(L=0),f.titleOffset&&f.titleOffset[0]&&(L=f.titleOffset[0]),L+=f.margin[0]-f.spacing[0]||0;else if("middle"===A)if(O===I)L=0>O?d+void 0:d;else if(O||I)L=0>O||0>I?L-Math.min(O,I):d-b+NaN;e.group.translate(n.x,n.y+Math.floor(L));!1!==x&&(e.minInput.style.marginTop=e.group.translateY+"px",e.maxInput.style.marginTop=e.group.translateY+
"px");e.rendered=!0}};l.prototype.getHeight=function(){var a=this.options,b=this.group,c=a.y,d=a.buttonPosition.y,e=a.inputPosition.y;if(a.height)return a.height;a=b?b.getBBox(!0).height+13+c:0;b=Math.min(e,d);if(0>e&&0>d||0<e&&0<d)a+=Math.abs(b);return a};l.prototype.titleCollision=function(a){return!(a.options.title.text||a.options.subtitle.text)};l.prototype.update=function(a){var b=this.chart;m(!0,b.options.rangeSelector,a);this.destroy();this.init(b);b.rangeSelector.render()};l.prototype.destroy=
function(){var a=this,b=a.minInput,c=a.maxInput;a.unMouseDown();a.unResize();x(a.buttons);b&&(b.onfocus=b.onblur=b.onchange=null);c&&(c.onfocus=c.onblur=c.onchange=null);h(a,function(b,c){b&&"chart"!==c&&(b instanceof y?b.destroy():b instanceof window.HTMLElement&&n(b));b!==l.prototype[c]&&(a[c]=null)},this)};return l}();t.prototype.defaultButtons=[{type:"month",count:1,text:"1m"},{type:"month",count:3,text:"3m"},{type:"month",count:6,text:"6m"},{type:"ytd",text:"YTD"},{type:"year",count:1,text:"1y"},
{type:"all",text:"All"}];b.prototype.minFromRange=function(){var b=this.range,c=b.type,d=this.max,g=this.chart.time,h=function(a,b){var d="year"===c?"FullYear":"Month",e=new g.Date(a),k=g.get(d,e);g.set(d,e,k+b);k===g.get(d,e)&&g.set("Date",e,0);return e.getTime()-a};if(e(b)){var m=d-b;var n=b}else m=d+h(d,-b.count),this.chart&&(this.chart.fixedRange=d-m);var q=a(this.dataMin,Number.MIN_VALUE);e(m)||(m=q);m<=q&&(m=q,"undefined"===typeof n&&(n=h(m,b.count)),this.newMax=Math.min(m+n,this.dataMax));
e(d)||(m=void 0);return m};A.RangeSelector||(v(z,"afterGetContainer",function(){this.options.rangeSelector.enabled&&(this.rangeSelector=new t(this))}),v(z,"beforeRender",function(){var a=this.axes,b=this.rangeSelector;b&&(e(b.deferredYTDClick)&&(b.clickButton(b.deferredYTDClick),delete b.deferredYTDClick),a.forEach(function(a){a.updateNames();a.setScale()}),this.getAxisMargins(),b.render(),a=b.options.verticalAlign,b.options.floating||("bottom"===a?this.extraBottomMargin=!0:"middle"!==a&&(this.extraTopMargin=
!0)))}),v(z,"update",function(a){var b=a.options.rangeSelector;a=this.rangeSelector;var c=this.extraBottomMargin,d=this.extraTopMargin;b&&b.enabled&&!u(a)&&(this.options.rangeSelector.enabled=!0,this.rangeSelector=new t(this));this.extraTopMargin=this.extraBottomMargin=!1;a&&(a.render(),b=b&&b.verticalAlign||a.options&&a.options.verticalAlign,a.options.floating||("bottom"===b?this.extraBottomMargin=!0:"middle"!==b&&(this.extraTopMargin=!0)),this.extraBottomMargin!==c||this.extraTopMargin!==d)&&(this.isDirtyBox=
!0)}),v(z,"render",function(){var a=this.rangeSelector;a&&!a.options.floating&&(a.render(),a=a.options.verticalAlign,"bottom"===a?this.extraBottomMargin=!0:"middle"!==a&&(this.extraTopMargin=!0))}),v(z,"getMargins",function(){var a=this.rangeSelector;a&&(a=a.getHeight(),this.extraTopMargin&&(this.plotTop+=a),this.extraBottomMargin&&(this.marginBottom+=a))}),z.prototype.callbacks.push(function(a){function b(){c=a.xAxis[0].getExtremes();g=a.legend;l=null===d||void 0===d?void 0:d.options.verticalAlign;
e(c.min)&&d.render(c.min,c.max);d&&g.display&&"top"===l&&l===g.options.verticalAlign&&(h=m(a.spacingBox),h.y="vertical"===g.options.layout?a.plotTop:h.y+d.getHeight(),g.group.placed=!1,g.align(h))}var c,d=a.rangeSelector,g,h,l;if(d){var n=v(a.xAxis[0],"afterSetExtremes",function(a){d.render(a.min,a.max)});var k=v(a,"redraw",b);b()}v(a,"destroy",function(){d&&(k(),n())})}),A.RangeSelector=t);return A.RangeSelector});I(b,"Core/Axis/NavigatorAxis.js",[b["Core/Globals.js"],b["Core/Utilities.js"]],function(b,
z){var A=b.isTouchDevice,w=z.addEvent,y=z.correctFloat,p=z.defined,E=z.isNumber,v=z.pick,c=function(){function b(b){this.axis=b}b.prototype.destroy=function(){this.axis=void 0};b.prototype.toFixedRange=function(b,c,n,q){var r=this.axis,e=r.chart;e=e&&e.fixedRange;var m=(r.pointRange||0)/2;b=v(n,r.translate(b,!0,!r.horiz));c=v(q,r.translate(c,!0,!r.horiz));r=e&&(c-b)/e;p(n)||(b=y(b+m));p(q)||(c=y(c-m));.7<r&&1.3>r&&(q?b=c-e:c=b+e);E(b)&&E(c)||(b=c=void 0);return{min:b,max:c}};return b}();return function(){function b(){}
b.compose=function(b){b.keepProps.push("navigatorAxis");w(b,"init",function(){this.navigatorAxis||(this.navigatorAxis=new c(this))});w(b,"zoom",function(b){var c=this.chart.options,q=c.navigator,r=this.navigatorAxis,e=c.chart.pinchType,m=c.rangeSelector;c=c.chart.zoomType;this.isXAxis&&(q&&q.enabled||m&&m.enabled)&&("y"===c?b.zoomed=!1:(!A&&"xy"===c||A&&"xy"===e)&&this.options.range&&(q=r.previousZoom,p(b.newMin)?r.previousZoom=[this.min,this.max]:q&&(b.newMin=q[0],b.newMax=q[1],r.previousZoom=void 0)));
"undefined"!==typeof b.zoomed&&b.preventDefault()})};b.AdditionsClass=c;return b}()});I(b,"Core/Navigator.js",[b["Core/Axis/Axis.js"],b["Core/Series/Series.js"],b["Core/Chart/Chart.js"],b["Core/Color/Color.js"],b["Core/Globals.js"],b["Series/LineSeries.js"],b["Core/Axis/NavigatorAxis.js"],b["Core/Options.js"],b["Core/Scrollbar.js"],b["Core/Utilities.js"]],function(b,z,A,w,y,p,E,v,c,r){w=w.parse;var u=y.hasTouch,x=y.isTouchDevice,n=v.defaultOptions,q=r.addEvent,D=r.clamp,e=r.correctFloat,m=r.defined,
h=r.destroyObjectProperties,a=r.erase,g=r.extend,d=r.find,t=r.isArray,l=r.isNumber,f=r.merge,G=r.pick,J=r.removeEvent,B=r.splat,I=function(a){for(var b=[],c=1;c<arguments.length;c++)b[c-1]=arguments[c];b=[].filter.call(b,l);if(b.length)return Math[a].apply(0,b)};z="undefined"===typeof z.seriesTypes.areaspline?"line":"areaspline";g(n,{navigator:{height:40,margin:25,maskInside:!0,handles:{width:7,height:15,symbols:["navigator-handle","navigator-handle"],enabled:!0,lineWidth:1,backgroundColor:"#f2f2f2",
borderColor:"#999999"},maskFill:w("#6685c2").setOpacity(.3).get(),outlineColor:"#cccccc",outlineWidth:1,series:{type:z,fillOpacity:.05,lineWidth:1,compare:null,dataGrouping:{approximation:"average",enabled:!0,groupPixelWidth:2,smoothed:!0,units:[["millisecond",[1,2,5,10,20,25,50,100,200,500]],["second",[1,2,5,10,15,30]],["minute",[1,2,5,10,15,30]],["hour",[1,2,3,4,6,8,12]],["day",[1,2,3,4]],["week",[1,2,3]],["month",[1,3,6]],["year",null]]},dataLabels:{enabled:!1,zIndex:2},id:"highcharts-navigator-series",
className:"highcharts-navigator-series",lineColor:null,marker:{enabled:!1},threshold:null},xAxis:{overscroll:0,className:"highcharts-navigator-xaxis",tickLength:0,lineWidth:0,gridLineColor:"#e6e6e6",gridLineWidth:1,tickPixelInterval:200,labels:{align:"left",style:{color:"#999999"},x:3,y:-4},crosshair:!1},yAxis:{className:"highcharts-navigator-yaxis",gridLineWidth:0,startOnTick:!1,endOnTick:!1,minPadding:.1,maxPadding:.1,labels:{enabled:!1},crosshair:!1,title:{text:null},tickLength:0,tickWidth:0}}});
y.Renderer.prototype.symbols["navigator-handle"]=function(a,b,c,d,e){a=(e&&e.width||0)/2;b=Math.round(a/3)+.5;e=e&&e.height||0;return[["M",-a-1,.5],["L",a,.5],["L",a,e+.5],["L",-a-1,e+.5],["L",-a-1,.5],["M",-b,4],["L",-b,e-3],["M",b-1,4],["L",b-1,e-3]]};var K=function(){function p(a){this.zoomedMin=this.zoomedMax=this.yAxis=this.xAxis=this.top=this.size=this.shades=this.rendered=this.range=this.outlineHeight=this.outline=this.opposite=this.navigatorSize=this.navigatorSeries=this.navigatorOptions=
this.navigatorGroup=this.navigatorEnabled=this.left=this.height=this.handles=this.chart=this.baseSeries=void 0;this.init(a)}p.prototype.drawHandle=function(a,b,c,d){var e=this.navigatorOptions.handles.height;this.handles[b][d](c?{translateX:Math.round(this.left+this.height/2),translateY:Math.round(this.top+parseInt(a,10)+.5-e)}:{translateX:Math.round(this.left+parseInt(a,10)),translateY:Math.round(this.top+this.height/2-e/2-1)})};p.prototype.drawOutline=function(a,b,c,d){var e=this.navigatorOptions.maskInside,
k=this.outline.strokeWidth(),f=k/2,g=k%2/2;k=this.outlineHeight;var h=this.scrollbarHeight||0,l=this.size,m=this.left-h,C=this.top;c?(m-=f,c=C+b+g,b=C+a+g,g=[["M",m+k,C-h-g],["L",m+k,c],["L",m,c],["L",m,b],["L",m+k,b],["L",m+k,C+l+h]],e&&g.push(["M",m+k,c-f],["L",m+k,b+f])):(a+=m+h-g,b+=m+h-g,C+=f,g=[["M",m,C],["L",a,C],["L",a,C+k],["L",b,C+k],["L",b,C],["L",m+l+2*h,C]],e&&g.push(["M",a-f,C],["L",b+f,C]));this.outline[d]({d:g})};p.prototype.drawMasks=function(a,b,c,d){var e=this.left,k=this.top,f=
this.height;if(c){var g=[e,e,e];var h=[k,k+a,k+b];var l=[f,f,f];var m=[a,b-a,this.size-b]}else g=[e,e+a,e+b],h=[k,k,k],l=[a,b-a,this.size-b],m=[f,f,f];this.shades.forEach(function(a,b){a[d]({x:g[b],y:h[b],width:l[b],height:m[b]})})};p.prototype.renderElements=function(){var a=this,b=a.navigatorOptions,c=b.maskInside,d=a.chart,e=d.renderer,f,g={cursor:d.inverted?"ns-resize":"ew-resize"};a.navigatorGroup=f=e.g("navigator").attr({zIndex:8,visibility:"hidden"}).add();[!c,c,!c].forEach(function(c,k){a.shades[k]=
e.rect().addClass("highcharts-navigator-mask"+(1===k?"-inside":"-outside")).add(f);d.styledMode||a.shades[k].attr({fill:c?b.maskFill:"rgba(0,0,0,0)"}).css(1===k&&g)});a.outline=e.path().addClass("highcharts-navigator-outline").add(f);d.styledMode||a.outline.attr({"stroke-width":b.outlineWidth,stroke:b.outlineColor});b.handles.enabled&&[0,1].forEach(function(c){b.handles.inverted=d.inverted;a.handles[c]=e.symbol(b.handles.symbols[c],-b.handles.width/2-1,0,b.handles.width,b.handles.height,b.handles);
a.handles[c].attr({zIndex:7-c}).addClass("highcharts-navigator-handle highcharts-navigator-handle-"+["left","right"][c]).add(f);if(!d.styledMode){var k=b.handles;a.handles[c].attr({fill:k.backgroundColor,stroke:k.borderColor,"stroke-width":k.lineWidth}).css(g)}})};p.prototype.update=function(a){(this.series||[]).forEach(function(a){a.baseSeries&&delete a.baseSeries.navigatorSeries});this.destroy();f(!0,this.chart.options.navigator,this.options,a);this.init(this.chart)};p.prototype.render=function(a,
b,c,d){var k=this.chart,f=this.scrollbarHeight,g,h=this.xAxis,n=h.pointRange||0;var C=h.navigatorAxis.fake?k.xAxis[0]:h;var p=this.navigatorEnabled,q,t=this.rendered;var r=k.inverted;var u=k.xAxis[0].minRange,F=k.xAxis[0].options.maxRange;if(!this.hasDragged||m(c)){a=e(a-n/2);b=e(b+n/2);if(!l(a)||!l(b))if(t)c=0,d=G(h.width,C.width);else return;this.left=G(h.left,k.plotLeft+f+(r?k.plotWidth:0));this.size=q=g=G(h.len,(r?k.plotHeight:k.plotWidth)-2*f);k=r?f:g+2*f;c=G(c,h.toPixels(a,!0));d=G(d,h.toPixels(b,
!0));l(c)&&Infinity!==Math.abs(c)||(c=0,d=k);a=h.toValue(c,!0);b=h.toValue(d,!0);var v=Math.abs(e(b-a));v<u?this.grabbedLeft?c=h.toPixels(b-u-n,!0):this.grabbedRight&&(d=h.toPixels(a+u+n,!0)):m(F)&&e(v-n)>F&&(this.grabbedLeft?c=h.toPixels(b-F-n,!0):this.grabbedRight&&(d=h.toPixels(a+F+n,!0)));this.zoomedMax=D(Math.max(c,d),0,q);this.zoomedMin=D(this.fixedWidth?this.zoomedMax-this.fixedWidth:Math.min(c,d),0,q);this.range=this.zoomedMax-this.zoomedMin;q=Math.round(this.zoomedMax);c=Math.round(this.zoomedMin);
p&&(this.navigatorGroup.attr({visibility:"visible"}),t=t&&!this.hasDragged?"animate":"attr",this.drawMasks(c,q,r,t),this.drawOutline(c,q,r,t),this.navigatorOptions.handles.enabled&&(this.drawHandle(c,0,r,t),this.drawHandle(q,1,r,t)));this.scrollbar&&(r?(r=this.top-f,C=this.left-f+(p||!C.opposite?0:(C.titleOffset||0)+C.axisTitleMargin),f=g+2*f):(r=this.top+(p?this.height:-f),C=this.left-f),this.scrollbar.position(C,r,k,f),this.scrollbar.setRange(this.zoomedMin/(g||1),this.zoomedMax/(g||1)));this.rendered=
!0}};p.prototype.addMouseEvents=function(){var a=this,b=a.chart,c=b.container,d=[],e,f;a.mouseMoveHandler=e=function(b){a.onMouseMove(b)};a.mouseUpHandler=f=function(b){a.onMouseUp(b)};d=a.getPartsEvents("mousedown");d.push(q(b.renderTo,"mousemove",e),q(c.ownerDocument,"mouseup",f));u&&(d.push(q(b.renderTo,"touchmove",e),q(c.ownerDocument,"touchend",f)),d.concat(a.getPartsEvents("touchstart")));a.eventsToUnbind=d;a.series&&a.series[0]&&d.push(q(a.series[0].xAxis,"foundExtremes",function(){b.navigator.modifyNavigatorAxisExtremes()}))};
p.prototype.getPartsEvents=function(a){var b=this,c=[];["shades","handles"].forEach(function(d){b[d].forEach(function(e,k){c.push(q(e.element,a,function(a){b[d+"Mousedown"](a,k)}))})});return c};p.prototype.shadesMousedown=function(a,b){a=this.chart.pointer.normalize(a);var c=this.chart,d=this.xAxis,e=this.zoomedMin,k=this.left,f=this.size,g=this.range,h=a.chartX;c.inverted&&(h=a.chartY,k=this.top);if(1===b)this.grabbedCenter=h,this.fixedWidth=g,this.dragOffset=h-e;else{a=h-k-g/2;if(0===b)a=Math.max(0,
a);else if(2===b&&a+g>=f)if(a=f-g,this.reversedExtremes){a-=g;var l=this.getUnionExtremes().dataMin}else var n=this.getUnionExtremes().dataMax;a!==e&&(this.fixedWidth=g,b=d.navigatorAxis.toFixedRange(a,a+g,l,n),m(b.min)&&c.xAxis[0].setExtremes(Math.min(b.min,b.max),Math.max(b.min,b.max),!0,null,{trigger:"navigator"}))}};p.prototype.handlesMousedown=function(a,b){this.chart.pointer.normalize(a);a=this.chart;var c=a.xAxis[0],d=this.reversedExtremes;0===b?(this.grabbedLeft=!0,this.otherHandlePos=this.zoomedMax,
this.fixedExtreme=d?c.min:c.max):(this.grabbedRight=!0,this.otherHandlePos=this.zoomedMin,this.fixedExtreme=d?c.max:c.min);a.fixedRange=null};p.prototype.onMouseMove=function(a){var b=this,c=b.chart,d=b.left,e=b.navigatorSize,k=b.range,f=b.dragOffset,g=c.inverted;a.touches&&0===a.touches[0].pageX||(a=c.pointer.normalize(a),c=a.chartX,g&&(d=b.top,c=a.chartY),b.grabbedLeft?(b.hasDragged=!0,b.render(0,0,c-d,b.otherHandlePos)):b.grabbedRight?(b.hasDragged=!0,b.render(0,0,b.otherHandlePos,c-d)):b.grabbedCenter&&
(b.hasDragged=!0,c<f?c=f:c>e+f-k&&(c=e+f-k),b.render(0,0,c-f,c-f+k)),b.hasDragged&&b.scrollbar&&G(b.scrollbar.options.liveRedraw,y.svg&&!x&&!this.chart.isBoosting)&&(a.DOMType=a.type,setTimeout(function(){b.onMouseUp(a)},0)))};p.prototype.onMouseUp=function(a){var b=this.chart,c=this.xAxis,d=this.scrollbar,e=a.DOMEvent||a,k=b.inverted,f=this.rendered&&!this.hasDragged?"animate":"attr";if(this.hasDragged&&(!d||!d.hasDragged)||"scrollbar"===a.trigger){d=this.getUnionExtremes();if(this.zoomedMin===this.otherHandlePos)var g=
this.fixedExtreme;else if(this.zoomedMax===this.otherHandlePos)var h=this.fixedExtreme;this.zoomedMax===this.size&&(h=this.reversedExtremes?d.dataMin:d.dataMax);0===this.zoomedMin&&(g=this.reversedExtremes?d.dataMax:d.dataMin);c=c.navigatorAxis.toFixedRange(this.zoomedMin,this.zoomedMax,g,h);m(c.min)&&b.xAxis[0].setExtremes(Math.min(c.min,c.max),Math.max(c.min,c.max),!0,this.hasDragged?!1:null,{trigger:"navigator",triggerOp:"navigator-drag",DOMEvent:e})}"mousemove"!==a.DOMType&&"touchmove"!==a.DOMType&&
(this.grabbedLeft=this.grabbedRight=this.grabbedCenter=this.fixedWidth=this.fixedExtreme=this.otherHandlePos=this.hasDragged=this.dragOffset=null);this.navigatorEnabled&&l(this.zoomedMin)&&l(this.zoomedMax)&&(b=Math.round(this.zoomedMin),a=Math.round(this.zoomedMax),this.shades&&this.drawMasks(b,a,k,f),this.outline&&this.drawOutline(b,a,k,f),this.navigatorOptions.handles.enabled&&Object.keys(this.handles).length===this.handles.length&&(this.drawHandle(b,0,k,f),this.drawHandle(a,1,k,f)))};p.prototype.removeEvents=
function(){this.eventsToUnbind&&(this.eventsToUnbind.forEach(function(a){a()}),this.eventsToUnbind=void 0);this.removeBaseSeriesEvents()};p.prototype.removeBaseSeriesEvents=function(){var a=this.baseSeries||[];this.navigatorEnabled&&a[0]&&(!1!==this.navigatorOptions.adaptToUpdatedData&&a.forEach(function(a){J(a,"updatedData",this.updatedDataHandler)},this),a[0].xAxis&&J(a[0].xAxis,"foundExtremes",this.modifyBaseAxisExtremes))};p.prototype.init=function(a){var d=a.options,e=d.navigator,k=e.enabled,
g=d.scrollbar,h=g.enabled;d=k?e.height:0;var l=h?g.height:0;this.handles=[];this.shades=[];this.chart=a;this.setBaseSeries();this.height=d;this.scrollbarHeight=l;this.scrollbarEnabled=h;this.navigatorEnabled=k;this.navigatorOptions=e;this.scrollbarOptions=g;this.outlineHeight=d+l;this.opposite=G(e.opposite,!(k||!a.inverted));var m=this;k=m.baseSeries;g=a.xAxis.length;h=a.yAxis.length;var n=k&&k[0]&&k[0].xAxis||a.xAxis[0]||{options:{}};a.isDirtyBox=!0;m.navigatorEnabled?(m.xAxis=new b(a,f({breaks:n.options.breaks,
ordinal:n.options.ordinal},e.xAxis,{id:"navigator-x-axis",yAxis:"navigator-y-axis",isX:!0,type:"datetime",index:g,isInternal:!0,offset:0,keepOrdinalPadding:!0,startOnTick:!1,endOnTick:!1,minPadding:0,maxPadding:0,zoomEnabled:!1},a.inverted?{offsets:[l,0,-l,0],width:d}:{offsets:[0,-l,0,l],height:d})),m.yAxis=new b(a,f(e.yAxis,{id:"navigator-y-axis",alignTicks:!1,offset:0,index:h,isInternal:!0,reversed:G(e.yAxis&&e.yAxis.reversed,a.yAxis[0]&&a.yAxis[0].reversed,!1),zoomEnabled:!1},a.inverted?{width:d}:
{height:d})),k||e.series.data?m.updateNavigatorSeries(!1):0===a.series.length&&(m.unbindRedraw=q(a,"beforeRedraw",function(){0<a.series.length&&!m.series&&(m.setBaseSeries(),m.unbindRedraw())})),m.reversedExtremes=a.inverted&&!m.xAxis.reversed||!a.inverted&&m.xAxis.reversed,m.renderElements(),m.addMouseEvents()):(m.xAxis={chart:a,navigatorAxis:{fake:!0},translate:function(b,c){var d=a.xAxis[0],e=d.getExtremes(),f=d.len-2*l,k=I("min",d.options.min,e.dataMin);d=I("max",d.options.max,e.dataMax)-k;return c?
b*d/f+k:f*(b-k)/d},toPixels:function(a){return this.translate(a)},toValue:function(a){return this.translate(a,!0)}},m.xAxis.navigatorAxis.axis=m.xAxis,m.xAxis.navigatorAxis.toFixedRange=E.AdditionsClass.prototype.toFixedRange.bind(m.xAxis.navigatorAxis));a.options.scrollbar.enabled&&(a.scrollbar=m.scrollbar=new c(a.renderer,f(a.options.scrollbar,{margin:m.navigatorEnabled?0:10,vertical:a.inverted}),a),q(m.scrollbar,"changed",function(b){var c=m.size,d=c*this.to;c*=this.from;m.hasDragged=m.scrollbar.hasDragged;
m.render(0,0,c,d);(a.options.scrollbar.liveRedraw||"mousemove"!==b.DOMType&&"touchmove"!==b.DOMType)&&setTimeout(function(){m.onMouseUp(b)})}));m.addBaseSeriesEvents();m.addChartEvents()};p.prototype.getUnionExtremes=function(a){var b=this.chart.xAxis[0],c=this.xAxis,d=c.options,e=b.options,f;a&&null===b.dataMin||(f={dataMin:G(d&&d.min,I("min",e.min,b.dataMin,c.dataMin,c.min)),dataMax:G(d&&d.max,I("max",e.max,b.dataMax,c.dataMax,c.max))});return f};p.prototype.setBaseSeries=function(a,b){var c=this.chart,
e=this.baseSeries=[];a=a||c.options&&c.options.navigator.baseSeries||(c.series.length?d(c.series,function(a){return!a.options.isInternal}).index:0);(c.series||[]).forEach(function(b,c){b.options.isInternal||!b.options.showInNavigator&&(c!==a&&b.options.id!==a||!1===b.options.showInNavigator)||e.push(b)});this.xAxis&&!this.xAxis.navigatorAxis.fake&&this.updateNavigatorSeries(!0,b)};p.prototype.updateNavigatorSeries=function(a,b){var c=this,d=c.chart,e=c.baseSeries,k,h,l=c.navigatorOptions.series,m,
p={enableMouseTracking:!1,index:null,linkedTo:null,group:"nav",padXAxis:!1,xAxis:"navigator-x-axis",yAxis:"navigator-y-axis",showInLegend:!1,stacking:void 0,isInternal:!0,states:{inactive:{opacity:1}}},q=c.series=(c.series||[]).filter(function(a){var b=a.baseSeries;return 0>e.indexOf(b)?(b&&(J(b,"updatedData",c.updatedDataHandler),delete b.navigatorSeries),a.chart&&a.destroy(),!1):!0});e&&e.length&&e.forEach(function(a){var r=a.navigatorSeries,u=g({color:a.color,visible:a.visible},t(l)?n.navigator.series:
l);r&&!1===c.navigatorOptions.adaptToUpdatedData||(p.name="Navigator "+e.length,k=a.options||{},m=k.navigatorOptions||{},h=f(k,p,u,m),h.pointRange=G(u.pointRange,m.pointRange,n.plotOptions[h.type||"line"].pointRange),u=m.data||u.data,c.hasNavigatorData=c.hasNavigatorData||!!u,h.data=u||k.data&&k.data.slice(0),r&&r.options?r.update(h,b):(a.navigatorSeries=d.initSeries(h),a.navigatorSeries.baseSeries=a,q.push(a.navigatorSeries)))});if(l.data&&(!e||!e.length)||t(l))c.hasNavigatorData=!1,l=B(l),l.forEach(function(a,
b){p.name="Navigator "+(q.length+1);h=f(n.navigator.series,{color:d.series[b]&&!d.series[b].options.isInternal&&d.series[b].color||d.options.colors[b]||d.options.colors[0]},p,a);h.data=a.data;h.data&&(c.hasNavigatorData=!0,q.push(d.initSeries(h)))});a&&this.addBaseSeriesEvents()};p.prototype.addBaseSeriesEvents=function(){var b=this,c=b.baseSeries||[];c[0]&&c[0].xAxis&&q(c[0].xAxis,"foundExtremes",this.modifyBaseAxisExtremes);c.forEach(function(c){q(c,"show",function(){this.navigatorSeries&&this.navigatorSeries.setVisible(!0,
!1)});q(c,"hide",function(){this.navigatorSeries&&this.navigatorSeries.setVisible(!1,!1)});!1!==this.navigatorOptions.adaptToUpdatedData&&c.xAxis&&q(c,"updatedData",this.updatedDataHandler);q(c,"remove",function(){this.navigatorSeries&&(a(b.series,this.navigatorSeries),m(this.navigatorSeries.options)&&this.navigatorSeries.remove(!1),delete this.navigatorSeries)})},this)};p.prototype.getBaseSeriesMin=function(a){return this.baseSeries.reduce(function(a,b){return Math.min(a,b.xData?b.xData[0]:a)},a)};
p.prototype.modifyNavigatorAxisExtremes=function(){var a=this.xAxis,b;"undefined"!==typeof a.getExtremes&&(!(b=this.getUnionExtremes(!0))||b.dataMin===a.min&&b.dataMax===a.max||(a.min=b.dataMin,a.max=b.dataMax))};p.prototype.modifyBaseAxisExtremes=function(){var a=this.chart.navigator,b=this.getExtremes(),c=b.dataMin,d=b.dataMax;b=b.max-b.min;var e=a.stickToMin,f=a.stickToMax,g=G(this.options.overscroll,0),h=a.series&&a.series[0],m=!!this.setExtremes;if(!this.eventArgs||"rangeSelectorButton"!==this.eventArgs.trigger){if(e){var n=
c;var p=n+b}f&&(p=d+g,e||(n=Math.max(c,p-b,a.getBaseSeriesMin(h&&h.xData?h.xData[0]:-Number.MAX_VALUE))));m&&(e||f)&&l(n)&&(this.min=this.userMin=n,this.max=this.userMax=p)}a.stickToMin=a.stickToMax=null};p.prototype.updatedDataHandler=function(){var a=this.chart.navigator,b=this.navigatorSeries,c=a.getBaseSeriesMin(this.xData[0]);a.stickToMax=a.reversedExtremes?0===Math.round(a.zoomedMin):Math.round(a.zoomedMax)>=Math.round(a.size);a.stickToMin=l(this.xAxis.min)&&this.xAxis.min<=c&&(!this.chart.fixedRange||
!a.stickToMax);b&&!a.hasNavigatorData&&(b.options.pointStart=this.xData[0],b.setData(this.options.data,!1,null,!1))};p.prototype.addChartEvents=function(){this.eventsToUnbind||(this.eventsToUnbind=[]);this.eventsToUnbind.push(q(this.chart,"redraw",function(){var a=this.navigator,b=a&&(a.baseSeries&&a.baseSeries[0]&&a.baseSeries[0].xAxis||this.xAxis[0]);b&&a.render(b.min,b.max)}),q(this.chart,"getMargins",function(){var a=this.navigator,b=a.opposite?"plotTop":"marginBottom";this.inverted&&(b=a.opposite?
"marginRight":"plotLeft");this[b]=(this[b]||0)+(a.navigatorEnabled||!this.inverted?a.outlineHeight:0)+a.navigatorOptions.margin}))};p.prototype.destroy=function(){this.removeEvents();this.xAxis&&(a(this.chart.xAxis,this.xAxis),a(this.chart.axes,this.xAxis));this.yAxis&&(a(this.chart.yAxis,this.yAxis),a(this.chart.axes,this.yAxis));(this.series||[]).forEach(function(a){a.destroy&&a.destroy()});"series xAxis yAxis shades outline scrollbarTrack scrollbarRifles scrollbarGroup scrollbar navigatorGroup rendered".split(" ").forEach(function(a){this[a]&&
this[a].destroy&&this[a].destroy();this[a]=null},this);[this.handles].forEach(function(a){h(a)},this)};return p}();y.Navigator||(y.Navigator=K,E.compose(b),q(A,"beforeShowResetZoom",function(){var a=this.options,b=a.navigator,c=a.rangeSelector;if((b&&b.enabled||c&&c.enabled)&&(!x&&"x"===a.chart.zoomType||x&&"x"===a.chart.pinchType))return!1}),q(A,"beforeRender",function(){var a=this.options;if(a.navigator.enabled||a.scrollbar.enabled)this.scroller=this.navigator=new K(this)}),q(A,"afterSetChartSize",
function(){var a=this.legend,b=this.navigator;if(b){var c=a&&a.options;var d=b.xAxis;var e=b.yAxis;var f=b.scrollbarHeight;this.inverted?(b.left=b.opposite?this.chartWidth-f-b.height:this.spacing[3]+f,b.top=this.plotTop+f):(b.left=this.plotLeft+f,b.top=b.navigatorOptions.top||this.chartHeight-b.height-f-this.spacing[2]-(this.rangeSelector&&this.extraBottomMargin?this.rangeSelector.getHeight():0)-(c&&"bottom"===c.verticalAlign&&"proximate"!==c.layout&&c.enabled&&!c.floating?a.legendHeight+G(c.margin,
10):0)-(this.titleOffset?this.titleOffset[2]:0));d&&e&&(this.inverted?d.options.left=e.options.left=b.left:d.options.top=e.options.top=b.top,d.setAxisSize(),e.setAxisSize())}}),q(A,"update",function(a){var b=a.options.navigator||{},c=a.options.scrollbar||{};this.navigator||this.scroller||!b.enabled&&!c.enabled||(f(!0,this.options.navigator,b),f(!0,this.options.scrollbar,c),delete a.options.navigator,delete a.options.scrollbar)}),q(A,"afterUpdate",function(a){this.navigator||this.scroller||!this.options.navigator.enabled&&
!this.options.scrollbar.enabled||(this.scroller=this.navigator=new K(this),G(a.redraw,!0)&&this.redraw(a.animation))}),q(A,"afterAddSeries",function(){this.navigator&&this.navigator.setBaseSeries(null,!1)}),q(p,"afterUpdate",function(){this.chart.navigator&&!this.options.isInternal&&this.chart.navigator.setBaseSeries(null,!1)}),A.prototype.callbacks.push(function(a){var b=a.navigator;b&&a.xAxis[0]&&(a=a.xAxis[0].getExtremes(),b.render(a.min,a.max))}));y.Navigator=K;return y.Navigator});I(b,"masters/modules/gantt.src.js",
[],function(){})});
//# sourceMappingURL=gantt.js.map

/***/ }),

/***/ "./node_modules/internmap/src/index.js":
/*!*********************************************!*\
  !*** ./node_modules/internmap/src/index.js ***!
  \*********************************************/
/*! exports provided: InternMap, InternSet */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InternMap", function() { return InternMap; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InternSet", function() { return InternSet; });
class InternMap extends Map {
  constructor(entries, key = keyof) {
    super();
    Object.defineProperties(this, {_intern: {value: new Map()}, _key: {value: key}});
    if (entries != null) for (const [key, value] of entries) this.set(key, value);
  }
  get(key) {
    return super.get(intern_get(this, key));
  }
  has(key) {
    return super.has(intern_get(this, key));
  }
  set(key, value) {
    return super.set(intern_set(this, key), value);
  }
  delete(key) {
    return super.delete(intern_delete(this, key));
  }
}

class InternSet extends Set {
  constructor(values, key = keyof) {
    super();
    Object.defineProperties(this, {_intern: {value: new Map()}, _key: {value: key}});
    if (values != null) for (const value of values) this.add(value);
  }
  has(value) {
    return super.has(intern_get(this, value));
  }
  add(value) {
    return super.add(intern_set(this, value));
  }
  delete(value) {
    return super.delete(intern_delete(this, value));
  }
}

function intern_get({_intern, _key}, value) {
  const key = _key(value);
  return _intern.has(key) ? _intern.get(key) : value;
}

function intern_set({_intern, _key}, value) {
  const key = _key(value);
  if (_intern.has(key)) return _intern.get(key);
  _intern.set(key, value);
  return value;
}

function intern_delete({_intern, _key}, value) {
  const key = _key(value);
  if (_intern.has(key)) {
    value = _intern.get(key);
    _intern.delete(key);
  }
  return value;
}

function keyof(value) {
  return value !== null && typeof value === "object" ? value.valueOf() : value;
}


/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.html":
/*!*******************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.html ***!
  \*******************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid p-align-center p-justify-between py-5\">\n  <div class=\"ui-toolbar-group-left\" style=\"text-align: left\">\n    <div *ngIf=\"showWarning\">\n      <label>\n        <b>Showing for top {{commonService.formatter(maxFlowPath)}} Slowest Flowpath(s).To see more or less apply filter\n          Settings.</b>\n      </label>\n    </div>\n  </div>\n</div>\n\n<cav-table [value]=\"actualAggIPInfo\" [headerRelativePath]=\"relativePathForAGG\" [scrollable]=\"true\" [responsive]=\"true\"\n  (clickButtonEvent)=\"clickButtonEvent($event)\" scrollHeight=\"calc(100vh - 240px)\"\n  [paginator]=\"showPagination\"></cav-table>\n\n<p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '60vw'}\"\n  header=\"Integration Points Individual Info {{ipName}}\" [(visible)]=\"showIndIPInfo\" style=\"word-break: break-all\"\n  [draggable]=\"false\" [resizable]=\"false\" modal=\"modal\" [resizable]=false autoAlign=\"true\">\n  <div>\n    <cav-table [value]=\"indIPInfo\" [headerRelativePath]=\"relativePathForINDPopup\" [scrollable]=\"true\"\n      (clickButtonEvent)=\"onRowSelectEvent($event)\" [responsive]=\"true\"\n      scrollHeight=\"calc(100vh - 240px)\" [paginator]=\"showPaginationIP\" [selection]=\"selectedRowInfo\"></cav-table>\n    <div class=\"ui-dialog-footer\">\n      <div class=\"left-content\">\n        {{fullQueryName}}\n      </div>\n      <div class=\"right-content\">\n        <i class=\"icons8 icons8-copy font-18 mr-3\" label=\"Copy Query\" (click)=\"copytext(fullQueryName)\"\n          [title]=\"tooltipText\"></i>\n      </div>\n    </div>\n  </div>\n</p-dialog>\n<p-dialog class=\"secondary-dialog\" [style]=\"{width: '25vw'}\" [(visible)]=\"isIPByRespTime\" [responsive]='true'\n  [resizable]='false' [positionTop]='140'>\n  <p-header>Integration Point By Response Time</p-header>\n  <div>\n    <span style=\"text-align:center\">IP Response Time(ms) >=</span>\n    <span> <input id=\"input\" (keypress)=\"validateQty($event)\" type=\"text\" size=\"5\" pInputText [(ngModel)]=\"responseTime\"\n        style='float:right'> </span>\n  </div>\n  <p-footer>\n    <div class=\"p-grid p-justify-end sevbtn py-12\">\n      <button pButton type=\"button\" (click)=\"isIPByRespTime=false\" label=\"Cancel\"\n        class=\"ui-button-rounded ui-button-secondary\"></button>\n      <button pButton type=\"button\" (click)=\"openFPByIntegrationReport(resData, 'FPByResTime')\" label=\"Apply\"\n        class=\"ui-button-rounded\"></button>\n    </div>\n  </p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/db-group-by/db-group-by.component.html":
/*!*******************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/db-group-by/db-group-by.component.html ***!
  \*******************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n<div class=\"ddr-box\">\n    <div class=\"ddr-toolbar\">\n        <div class=\"p-grid p-justify-between p-align-center ui-table-header\">\n            <div>\n                <span title=\"{{completeTier}}\">{{filterTierName}}</span>\n                <span title=\"{{completeServer}}\">{{filterServerName}}</span>\n                <span title=\"{{completeInstance}}\">{{filterInstanceName}}</span>\n                <span title=\"{{CompleteURL}}\">{{urlStr}}</span>\n                <span title=\"{{completeGroupBy}}\">{{filterGroupByStr}}</span>\n                <span title=\"{{completeOrderBy}}\">{{filterOrderByStr}}</span>\n                <label class=\"headerInfo\">{{headerInfo}}</label>\n            </div>\n        </div>\n    </div>\n    <div class=\"ddruiscroll\" style=\"overflow:auto; height: calc(100vh - 150px);\">\n        <p-accordion class=\"ddr-accordion\">\n            <p-accordionTab [selected]='false' header=\"{{totalQueryCount}}\">\n                <div class='ui-g' style=\"overflow:auto\">\n                    <p-card class='ui-g-6'>\n                        <div class=\"ddr-graphpanel\" *ngIf=\"showChartForBT == true\">\n                            <highcharts-chart [options]=\"btOptions\" (click)=\"clickHandlerBTCount($event)\"\n                                [Highcharts]=\"highcharts\" style=\"width:  100%; height: 100%; display: block;\">\n                            </highcharts-chart>\n                        </div>\n                        <div *ngIf=\"showChartForBT == false\" style=\"text-align:center;\">No Pie Chart found based on\n                            current Filter Settings.</div>\n                    </p-card>\n                    <p-card class='ui-g-6'>\n                        <div class=\"ddr-graphpanel\" *ngIf=\"showChartForRespTime == true\">\n                            <highcharts-chart [options]=\"respOptions\" (click)=\"clickHandlerResponseTime($event)\"\n                                [Highcharts]=\"highcharts\" style=\"width:  100%; height: 100%; display: block;\">\n                            </highcharts-chart>\n                        </div>\n                        <div *ngIf=\"showChartForRespTime == false\" style=\"text-align:center;\">No Response Time Pie Chart\n                            found based on current Filter Settings.</div>\n                    </p-card>\n                </div>\n            </p-accordionTab>\n        </p-accordion>\n        <p-accordion class=\"ddr-accordion dynamic-column-width-acc\">\n            <p-accordionTab [selected]='true' header=\"{{headerName}}\">\n                <div class='ui-g' style=\"overflow:auto\">\n                    <cav-table [value]=\"dbQueryData\" [tableConfig]=\"tableConfig\" [headers]=\"colsForDbGroupByBT\"\n                        [columns]=\"colsForDbGroupByBT\" [scrollable]=\"true\" [responsive]=\"true\" [paginator]=\"showPagination\" [lazy]=\"true\"\n                        (clickButtonEvent)=\"clickButtonEvent($event)\" scrollHeight=\"calc(100vh - 365px)\" [rows]=\"rows\"\n                        [first]=\"first\" [rowsPerPageOptions]=\"[50,100,200,400]\" (onLazyLoad)=\"paginate($event)\"></cav-table>\n                </div>\n            </p-accordionTab>\n        </p-accordion>\n    </div>\n</div>\n<p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '45vw'}\" [(visible)]=\"isCancelQuery\" modal=\"modal\"\n    [resizable]='false' [responsive]=\"true\">\n    <p-header>\n        <i class=\"icons8 icons8-info\" style=\"color:red\"></i>\n        <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n    </p-header>\n    <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n    <footer>\n        <div class=\"p-grid p-justify-end sevbtn py-12\">\n            <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n                class=\"ui-button-rounded ui-button-secondary mx-3\"></button>\n            <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded mx-3\"></button>\n        </div>\n    </footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/db-report/db-report.component.html":
/*!***************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/db-report/db-report.component.html ***!
  \***************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n\n<div class=\"ddr-box\">\n    <!-- COMMON TOOLBAR -->\n    <div class=\"ddr-toolbar\">\n        <div class=\"p-grid p-justify-between p-align-center ui-table-header\">\n            <div class=\"w-80-p\">\n                <span>{{headerInfo}}</span>\n            </div>\n        </div>\n    </div>\n\n    <!-- COMMON BOX SCROLLLBAR -->\n    <div class=\"ddruiscroll\" style=\"overflow-y:auto; height: calc(100vh - 133px); overflow-x:hidden\">\n        <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n            <p-accordionTab header=\"{{tableHeader}}\" [selected]=\"true\">\n                <div class='ui-g'>\n                    <div class='ui-g-4'>\n                        <div class=\"ddr-graphpanel\" *ngIf=\"showChart == true\">\n                            <highcharts-chart [options]=\"options\" (click)=\"clickHandler($event)\" [Highcharts]=\"highcharts\"\n                                style=\"width:  100%; height: 100%; display: block;\">\n                            </highcharts-chart>\n                        </div>\n                        <div *ngIf=\"showChart == false\" style=\"text-align:center;margin-top: 35px\">No Pie Chart found\n                            based on current Filter Settings.</div>\n                    </div>\n                    <div class='ui-g-8'>\n                        <cav-table [value]=\"queryInfo\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" [responsive]=\"true\"\n                            scrollHeight=\"calc(100vh - 240px)\" [totalRecords]=\"totalCount\" [first]=\"first\" [rows]=\"rows\"\n                            [lazyLoadingProcessBar]=\"loading\" (onLazyLoad)=\"loadDbReportPagination($event)\"\n                            (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>\n                    </div>\n                </div>\n            </p-accordionTab>\n\n        </p-accordion>\n        <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n            <p-accordionTab header=\"Query\" [selected]=\"true\">\n                <div>\n                    <textarea pInputTextarea rows=\"5\" class=\"ui-inputtext ui-corner-all ui-state-default ui-widget\" style=\"width:100%;resize:none;\"\n                        readonly>{{fullQueryName}}</textarea>\n                </div>\n            </p-accordionTab>\n        </p-accordion>\n    </div>\n</div>\n<p-dialog class=\"secondary-dialog\" [style]=\"{width: '45vw'}\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'\n    [responsive]=\"true\">\n    <p-header>\n        <i class=\"icons8 icons8-info\" style=\"color:red\"></i>\n        <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n    </p-header>\n    <span style=\"font-size:14px;\">{{this.commonService.cancelationMessage}} </span>\n    <p-footer>\n        <div class=\"p-grid p-justify-end sevbtn py-12\">\n            <button pButton type=\"button\" label=\"Cancel\"(click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"  class=\"ui-button-rounded ui-button-secondary\"></button>\n            <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n        </div>\n    </p-footer>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.html":
/*!***************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.html ***!
  \***************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"ddr-box\">\n    <div id=\"flowmap-box\">\n            <div>\n                    <!-- <label ><b>Filter criteria : </b></label>-->\n                    <div id='filterAgg' class='for-filter'></div>\n                </div>\n        <div class=\"ddr-jtk-demo-canvas ddr-jtk-surface canvas-wide flowchart-demo jtk-surface-nopan\" style=\"position: relative\" id=\"canvas\">\n          <div style=\"width:100%;height: 500px;\">\n            <div class=\"window node\" [ngStyle]=\"{'top':'110px','background':'#bdef84', 'padding':' 15px 0 0 2px'}\" id=\"root\">\n                <strong>Entry</strong>\n                <br/>\n                <br/>\n            </div>\n            <div *ngFor=\"let col of dataToDraw,let i = index\">\n                <!-- <p-contextMenu id='contextmenu' #contextRef *ngIf=\"(col.instanceType == 'java'||col.instanceType == 'dotNet'||col.instanceType == 'NodeJS') && (col?.exceptionCount == 0 || col?.exceptionCount == undefined)\" [style]=\"{'width':'150px', 'position': 'fixed'}\"  [target]=\"nodediv\" [model]=\"ContextMenuItems\"></p-contextMenu>        -->\n                <!-- <p-contextMenu id='contextmenu' #contextRef  *ngIf=\"(col.instanceType == 'java'||col.instanceType == 'dotNet'||col.instanceType == 'NodeJS') && (col?.exceptionCount > 0)\" [style]=\"{'width':'150px', 'position': 'fixed'}\"  [target]=\"nodediv\" [model]=\"ContextMenuItemsForExceeption\" ></p-contextMenu>        -->\n                <div id='{{col.id}}' #nodediv class='node window' [ngStyle]=\"{'top': col.top, 'left': col.left }\" >\n                    <!--<div class=\"tooltipfornodes\"><strong><img (mouseover)=\"Showtooltip(col)\" (mouseleave)=\"removeTooltip(col)\" src=\"src/images/{{col.icon}}\"></strong>\n       <div [innerHTML]=\"tooltipForNodes\" class=\"tooltiptextfornodes\"></div>\n        </div>-->\n                    <a class='tooltips'>\n                        <img src=\"./assets/images/{{col.icon}}\" class=\"nodeImage\" style='width:32px; padding: 4px;'>\n                        <!-- <span [ngStyle]=\"{'margin-top': '25px' }\">\n                            <div [innerHTML]=\"tooltipForNodes\"></div>\n                        </span> -->\n                    </a>\n                    <div class='nodeRight'>\n                        <div class='nodeHeading'>{{(col.displayName)}} </div>\n                        <div class=\"nodeBottom\"></div>\n                    </div>\n                </div>\n            </div>\n        </div>\n        </div>\n    </div>\n</div>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.html":
/*!***************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.html ***!
  \***************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid p-align-center p-justify-between\">\r\n    <div class=\"w-100-p\">\r\n        <p-breadcrumb [home]=\"routeToHome\" [model]=\"objDdrBreadcrumbs\"> </p-breadcrumb>\r\n    </div>\r\n    <!-- <div title=\"Test run Number\"style=\"cursor:pointer;margin-top: 2px;margin-right: 15px;font-size: 15px;\">\r\n        TR {{testRunVisible}}\r\n    </div> -->\r\n    </div>\r\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.html":
/*!*********************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.html ***!
  \*********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"flowmap-box\" id=\"flowmap-box\" [ngStyle]=\"{'height': screenHeight + 67 +'px'}\" style=\"overflow:auto\">\n  <div class=\"ddr-toolbar\">\n  <div class=\"p-grid p-justify-between p-align-center ui-table-header\">\n      <div>\n        <span id=\"filters\" [innerHTML]=\"headerFilter\"></span>\n        <span id=\"customFilter\" title=\"{{tierToolTip}}\">{{tierFilter}}</span>\n        </div>\n        <div>\n          <span>\n            <label class=\"ddr-timeLabel\" style='cursor:pointer' (click)=\"openTimeFilter()\">{{timeLabel}}</label>\n          </span>\n        </div>\n    </div>\n   \n  </div>\n  <div class=\"mb-2\">\n  <p-accordion class=\"accordHeader\" [multiple]='true'>\n    <p-accordionTab header=\"BT Trend Summary\" [selected]=\"true\">\n      <p-toolbar>\n        <div class=\"p-8\" style=\"float:right;\">\n          <i *ngIf=\"urlParam.btName == ''\" style='cursor:pointer' class=\"las-filter-solid\" title=\"Filter\" aria-hidden=\"true\"\n            (click)='displayFilter()'></i>\n        </div>\n      </p-toolbar>\n      \n      <cav-table [value]=\"ipData\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" [responsive]=\"true\"\n        scrollHeight=\"calc(100vh - 240px)\" [paginator]=\"ipData && ipData.length>10\"\n        (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>\n\n      <div *ngIf='showPagination'>\n        <div> Total Records : {{totalCount.toLocaleString()}} </div>\n      </div>\n    </p-accordionTab>\n  </p-accordion>\n  </div>\n  <div class='ddr-bt-trend-div' *ngIf=\"urlParam.btCategory  == 'extbt' && graphTab == true\">\n    <p-checkbox class=\"ml-5\" name=\"groupname\" binary=true (onChange)=\"changeCompare()\" [(ngModel)]=\"selectedValues\"></p-checkbox>\n    <span class='selectedBtCheckbox mx-6'>Compare for selected {{timePeriodForCompare}} with previous </span>\n    <span>\n      <p-dropdown [style]=\"{'width':'100px'}\"  [options]=\"timeCompareList\" [disabled]='isTotalTestRun'\n        [(ngModel)]=\"selectedCompareTime\" placeholder=\"Select\"></p-dropdown>\n      <button pButton type=\"button\" class=\"ui-button-rounded mx-10\" label=\"Apply\" [disabled]='isTotalTestRun' (click)=\"getCompareData()\"></button>\n    </span>\n    <span *ngIf=\"showCompare\">\n      Time Period:&nbsp;&nbsp;{{compareAppliedStrattime}} To {{compareAppliedEndtime}}</span>\n  </div>\n  <p-accordion *ngIf=\"showBtGraphs\" class=\"accordHeader\" (onOpen)=\"onTabOpen($event)\" (onClose)=\"onTabClose($event)\"\n    [multiple]='true'>\n    <p-accordionTab [selected]=\"graphTab\">\n      <p-header>{{BtStatHeader}}</p-header>\n      <div>\n        <div style=\"border : 1px solid grey;height:250px\">\n          <div class=\"ui-g-12\">\n            <div class=\"ui-g-3\" style=\"width:24%\">\n              <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options1\"></highcharts-chart>\n            </div>\n            <div class=\"ui-g-3\" style=\"width:24%\">\n              <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options2\"></highcharts-chart>\n            </div>\n            <div class=\"ui-g-3\" style=\"width:24%\">\n              <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options3\"></highcharts-chart>\n            </div>\n            <div class=\"ui-g-3\" style=\"width:28%\">\n              <div id='piechartid'></div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </p-accordionTab>\n  </p-accordion>\n</div>\n<p-dialog class=\"secondary-dialog\" appendTo=\"body\" [modal]=\"true\"  [style]=\"{width: '530px'}\" [(visible)]=\"displayBtStatsDialog\" [resizable]=\"false\" [responsive]=\"true\">\n  <p-header>\n    <span>BT Category Stats</span>\n    <span *ngIf=\"popupHealthIcon == 'normal.png'\">\n      <img src=\"assets/images/normal.png\" aria-hidden=\"true\" title=\"Normal\">\n    </span>\n    <span *ngIf=\"popupHealthIcon == 'greenup.png'\">\n      <img src=\"assets/images/greenup.png\" aria-hidden=\"true\" title=\"Major\"> \n    </span>\n    <span *ngIf=\"popupHealthIcon== 'reddown.png'\">\n      <img src=\"assets/images/reddown.png\" aria-hidden=\"true\" title=\"Critical\">\n    </span>\n  </p-header>\n  <div id='filter'></div>\n  <div class=\"p-grid loader-container vertical-container h-50-vh\" *ngIf=\"loading1\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n  </div>\n  <div class=\"ui-g-12\">\n    <div id='pieTable'></div>\n  </div>\n</p-dialog>\n<p-dialog [modal]=\"true\" header=\"Transaction Filters\" [(visible)]=\"displayFilterDialog\" [responsive]=\"true\" [resizable]=\"false\"\n  [style]=\"{width: '500px'}\">\n  <div class=\"p-grid p-align-center\">\n    <div class=\"p-col-fixed\">Show Top</div>\n    <div class=\"p-col-fixed width-60 ml-5\">\n      <p-dropdown [options]=\"_limits\" [style]=\"{'min-width':'100%'}\" \n        appendTo='body' [(ngModel)]=\"_limit\"></p-dropdown>\n    </div>\n    <div class=\"p-col-fixed\">Business Transactions by</div>\n    <div class=\"p-col\">\n      <p-dropdown [options]=\"_colsOptions\" [style]=\"{'min-width':'100%'}\" \n        appendTo='body' [(ngModel)]=\"_selectedColumn\"></p-dropdown>\n    </div>\n  </div>\n  <div class=\"p-grid p-align-center\">\n    <div class=\"p-col-fixed\">Show only Transactions containing</div>\n    <div class=\"p-col-4\">\n      <input type=\"text\" class=\"w-100-p\" pInputText [(ngModel)]=\"_txPattern\" />\n    </div>\n    <div class=\"p-col-fixed\">in name.</div>\n    <i class=\"icons8 icons8-info mx-6\" title=\"Special characters such as '.', ',', '+', '*', '?', '^', '$', '(', ')', '[', ']', '{', '}', '|', and '' have special meanings in regular expressions. If you want to use these characters as literal characters in your regular expression pattern, you need to escape them by adding a backslash ('\\') before the character\"></i>\n  </div>\n  <p-footer >\n    <button pButton type=\"button\" class=\"ui-button-rounded ui-button-secondary\" label=\"Reset\" (click)=\"setDefaultFilters()\"></button>\n    <button pButton type=\"button\" class=\"ui-button-rounded\" label=\"Apply\" (click)=\"applyFilter()\"></button>\n  </p-footer>\n</p-dialog>\n<p-dialog styleClass=\"secondary-dialog\" header=\"Apply Time Period\" appendTo=\"body\" [(visible)]=\"display\"\n  [style]=\"{width: '550px'}\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n  <div class=\"p-grid \" *ngIf=\"display\">\n    <span class=\"p-grid w-100-p p-align-center\">\n      <span class=\"p-col-2\">\n        <label>Time Period </label>\n      </span>\n      <span class=\"p-col-10\">\n        <p-dropdown  [options]=\"timeFilterOptions\" appendTo=\"body\"\n          [(ngModel)]=\"selectedValue\" [style]=\"{'min-width':'100%'}\" (onChange)=\"openDateFilter($event)\"\n          placeholder={{timeLabel}}></p-dropdown>\n      </span>\n    </span>\n    <div class=\"p-grid p-align-center\">\n      <ng-container *ngIf=\"eventDayFilter\">\n        <div class=\"p-col-2\">\n          Select Day\n        </div>\n            <div class=\"p-col-5\">\n              <p-dropdown #eventDay [options]=\"_eventDaysList\" appendTo=\"body\" [(ngModel)]=\"_selectedEventDay\"\n                (onChange)=\"dateAjaxCall(eventDay.selectedOption.value, eventYear.selectedOption.value)\">\n              </p-dropdown>\n            </div>\n\n            <div class=\"p-col-5\">\n              <p-dropdown #eventYear [options]=\"_yearList\" appendTo=\"body\" [(ngModel)]=\"_selectedEventDayYear\"\n                (onChange)=\"dateAjaxCall(eventDay.selectedOption.value, eventYear.selectedOption.value)\">\n              </p-dropdown>\n            </div>\n          </ng-container>\n      \n      <ng-container *ngIf=\"commonFilter || customFilterDisplay\">\n        <div class=\"p-col-2\">\n          From\n        </div>\n        \n          <div class='p-col-5'>\n            <p-calendar [disabled]=\"_disabled\" inputStyleClass=\"w-100-p\" readonlyInput=\"true\" appendTo=\"body\"\n              dateFormat=\"mm/dd/yy\" [monthNavigator]=\"true\" [yearNavigator]=\"true\" yearRange=\"1970:2030\"\n              [(ngModel)]=\"startDate\"></p-calendar>\n          </div>\n          <div class='p-col-5 p-align-center p-grid p-nogutter'>\n            <div class=\"p-col\">\n              <input pInputText type='text' class=\"w-100-p\" title='HH' [(ngModel)]=\"startHours\" placeholder='HH'\n                autocomplete='off' (keypress)='valEnteredKeyN($event);' tabindex='1' maxlength='2'>\n            </div>\n            <div class=\"p-col-fixed font-weight-700 px-6\">:</div>\n            <div class=\"p-col\">\n              <input pInputText class=\"w-100-p\" type='text' title='MM' (keypress)='valEnteredKeyN($event);'\n                [(ngModel)]=\"startMinutes\" placeholder='MM' autocomplete='off' tabindex='1' maxlength='2'>\n            </div>\n            <div  class=\"p-col-fixed font-weight-700 px-6\">:</div>\n            <div class=\"p-col\">\n              <input class=\"w-100-p\" class=\"w-100-p\" pInputText type='text' title='SS'\n                (keypress)='valEnteredKeyN($event);' [(ngModel)]=\"startSeconds\" placeholder='SS' autocomplete='off'\n                tabindex='1' maxlength='2'>\n            </div>\n          </div>\n        \n\n        <div class=\"p-col-2\">\n          To\n        </div>\n          <div class='p-col-5'>\n            <p-calendar [disabled]=\"_disabled\" inputStyleClass=\"w-100-p\" readonlyInput=\"true\" appendTo=\"body\"\n              dateFormat=\"mm/dd/yy\" [monthNavigator]=\"true\" [yearNavigator]=\"true\" yearRange=\"1970:2030\"\n              [(ngModel)]=\"endDate\"></p-calendar>\n          </div>\n          <div class='p-col-5 p-align-center p-grid p-nogutter'>\n            <div class=\"p-col\">\n              <input pInputText type='text' class=\"w-100-p\" title='HH' [(ngModel)]=\"endHours\" placeholder='HH'\n                autocomplete='off' (keypress)='valEnteredKeyN($event);' tabindex='1' maxlength='2'>\n            </div>\n            <div  class=\"p-col-fixed font-weight-700 px-6\">:</div>\n            <div class=\"p-col\">\n              <input pInputText class=\"w-100-p\" type='text' title='MM' (keypress)='valEnteredKeyN($event);'\n                [(ngModel)]=\"endMinutes\" placeholder='MM' autocomplete='off' tabindex='1' maxlength='2'>\n            </div>\n            <div  class=\"p-col-fixed font-weight-700 px-6\">:</div>\n            <div class=\"p-col\">\n              <input class=\"w-100-p\" class=\"w-100-p\" pInputText type='text' title='SS'\n                (keypress)='valEnteredKeyN($event);' [(ngModel)]=\"endSeconds\" placeholder='SS' autocomplete='off'\n                tabindex='1' maxlength='2'>\n            </div>\n          </div>\n        \n      </ng-container>\n    </div>\n  </div>\n  <p-footer>\n    <div class=\"p-grid p-align-center p-justify-end \">\n      <button pButton type=\"button\" label=\"Submit\" (click)=\"submitFilterValue()\" class=\"ui-button-rounded\"></button>\n    </div>\n  </p-footer>\n</p-dialog>\n\n<p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '900px'}\" header=\"Dynamic Diagnostics Configuration\" [resizable]=\"false\"\n  *ngIf=\"showAutoInstrPopUp\" [(visible)]=\"showAutoInstrPopUp\" modal=\"modal\" responsive=\"true\">\n  <app-dynamic-diagnostics (resultAfterStart)=\"startInstrumentation($event)\" (closeAIDDGui)=\"closeAIDDDialog($event)\"\n    [passAIDDSettings]=\"argsForAIDDSetting\"></app-dynamic-diagnostics>\n</p-dialog>\n<p-dialog class=\"scenmodal\" header=\"Apply Time Period\" [(visible)]=\"showCustomDialogforCompare\" [modal]=\"true\"  [style]=\"{width: '500px'}\"\n  height=\"auto\" [resizable]=\"false\" [responsive]=\"true\" positionTop=\"153\">\n\n    <div class=\"p-grid p-align-center\">\n      <div class='p-col-2'>\n        From\n      </div>\n      <div class='ui-g-5'>\n        <p-calendar readonlyInput=\"true\" appendTo=\"body\" dateFormat=\"mm/dd/yy\" [monthNavigator]=\"true\"\n          [yearNavigator]=\"true\" yearRange=\"1970:2030\" [(ngModel)]=\"startCDate\"></p-calendar>\n      </div>\n    <div class='p-col-5 p-align-center p-grid'>\n      <input pInputText type='text' title='HH' [(ngModel)]=\"startCHours\" (keypress)='valEnteredKeyN($event);'\n        placeholder='HH' autocomplete='off' tabindex='1' class=\"width-45 mx-2\" maxlength='2'>:\n      <input pInputText type='text' title='MM' [(ngModel)]=\"startCMinutes\" (keypress)='valEnteredKeyN($event);'\n        placeholder='MM' autocomplete='off' tabindex='1' class=\"width-45 mx-2\" maxlength='2'>:\n      <input pInputText type='text' title='SS' (keypress)='valEnteredKeyN($event);' [(ngModel)]=\"startCSeconds\"\n        placeholder='SS' autocomplete='off' tabindex='1' class=\"width-45 mx-2\" maxlength='2'>\n    </div>\n  </div>\n\n  <div class=\"p-grid p-align-center\">\n      <div class='ui-g-2'>\n        To\n      </div>\n      <div class='ui-g-5'>\n        <p-calendar readonlyInput=\"true\" appendTo=\"body\" dateFormat=\"mm/dd/yy\" [monthNavigator]=\"true\"\n          [yearNavigator]=\"true\" yearRange=\"1970:2030\" [(ngModel)]=\"endCDate\"></p-calendar>\n      </div>\n    <div class='p-col-5 p-align-center p-grid'>\n      <input pInputText type='text' title='HH' [(ngModel)]=\"endCHours\" placeholder='HH' autocomplete='off'\n        (keypress)='valEnteredKeyN($event);' tabindex='1' class=\"width-45 mx-2\" maxlength='2'>:\n        <input pInputText type='text' title='MM' (keypress)='valEnteredKeyN($event);' [(ngModel)]=\"endCMinutes\"\n        placeholder='MM' autocomplete='off' tabindex='1' class=\"width-45 mx-2\" maxlength='2'>:\n        <input pInputText type='text' title='SS' (keypress)='valEnteredKeyN($event);' [(ngModel)]=\"endCSeconds\"\n        placeholder='SS' autocomplete='off' tabindex='1' class=\"width-45 mx-2\" maxlength='2'>\n    </div>\n  </div>\n  <p-footer>\n    <button pButton type=\"button\" label=\"Apply\" (click)=\"getSpecifiedData()\"></button>\n  </p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.html":
/*!***************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.html ***!
  \***************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("\n<highcharts-chart [Highcharts] = \"highcharts\" [options] = \"options\"></highcharts-chart>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.html":
/*!*************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.html ***!
  \*************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n<div class=\"h-90-vh page-container compare-flowpath-page\">\n\n  <p-panel styleClass=\"mb-10\" header=\"Compared Flowpath\">\n\n    <cav-table [value]=\"compareFPInfo2\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" [responsive]=\"true\"\n      scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n\n  </p-panel>\n  <p-tabView class=\"ddr-tabs scrollDiv\" (onChange)=\"handleChange($event)\">\n    <p-tabPanel header=\"Method Timing\">\n      <ng-container *ngIf=\"showMT\">\n        <app-ddr-compare-methodtiming [compareFPInfo]=\"compareFPInfo\"></app-ddr-compare-methodtiming>\n      </ng-container>\n    </p-tabPanel>\n    <p-tabPanel header=\"DB Request\">\n      <ng-container *ngIf=\"showDB\">\n        <app-ddr-compare-queries [value]=\"compareFPInfo\"></app-ddr-compare-queries>\n      </ng-container>\n    </p-tabPanel>\n\n    <p-tabPanel header=\"Method Calling Tree\">\n      <div *ngIf=\"showMCT\" class=\"ui-g\" style=\"overflow-y:auto; height: calc(100vh - 290px); overflow-x:hidden\">\n        <div class=\"ui-g-6\">\n          <div class=\"ddr-toolbar mb-4\">\n            <div class=\"ui-table-header\">\n              FP1: {{compareFP1}}\n            </div>\n          </div>\n          <methodcallingtree [value]=\"compareFPInfo[0]\"></methodcallingtree>\n        </div>\n        <div class=\"ui-g-6\">\n          <div class=\"ddr-toolbar mb-4\">\n            <div class=\"ui-table-header\">\n              FP2: {{compareFP2}}\n            </div>\n          </div>\n          <methodcallingtree [value]=\"compareFPInfo[1]\"></methodcallingtree>\n        </div>\n      </div>\n    </p-tabPanel>\n    <p-tabPanel header=\"Hotspot\">\n      <div *ngIf=\"showHotspot\" class=\"ui-g\" style=\"overflow-y:auto; height: calc(100vh - 290px); overflow-x:hidden\">\n        <div class=\"ui-g-6\">\n          <div class=\"ddr-toolbar mb-4\">\n            <div class=\"ui-table-header\">\n              FP1: {{compareFP1}}\n            </div>\n          </div>\n          <app-hotspot [value]=\"compareFPInfo[0]\"></app-hotspot>\n        </div>\n        <div class=\"ui-g-6\">\n          <div class=\"ddr-toolbar mb-4\">\n            <div class=\"ui-table-header\">\n              FP2: {{compareFP2}}\n            </div>\n          </div>\n          <app-hotspot [value]=\"compareFPInfo[1]\"></app-hotspot>\n        </div>\n      </div>\n    </p-tabPanel>\n    <p-tabPanel header=\"Exception\">\n      <div *ngIf=\"showExceptions\" class=\"ui-g\" style=\"overflow-y:auto; height: calc(100vh - 290px); overflow-x:hidden\">\n        <div class=\"ui-g-6\">\n          <div class=\"ddr-toolbar mb-4\">\n            <div class=\"ui-table-header\">\n              FP1: {{compareFP1}}\n            </div>\n          </div>\n          <exception-report [value]=\"compareFPInfo[0]\"></exception-report>\n        </div>\n        <div class=\"ui-g-6\">\n          <div class=\"ddr-toolbar mb-4\">\n            <div class=\"ui-table-header\">\n              FP2: {{compareFP2}}\n            </div>\n          </div>\n          <exception-report [value]=\"compareFPInfo[1]\"></exception-report>\n        </div>\n      </div>\n    </p-tabPanel>\n  </p-tabView>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.html":
/*!*********************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.html ***!
  \*********************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n\n<p-sidebar [(visible)]=\"commonServices.graphInSideBarForMT\" position=\"right\" [modal]=\"false\" [style]=\"{'width':'700px'}\"\n    [showCloseIcon]=\"false\" appendTo=\"body\">\n    <div class=\"helpHeader p-grid p-align-center w-100-p\">\n        <div class=\"p-col mln-15 elipseText\" matTooltip=\"Query : {{Completefqm}}\">\n            Compared Method Stat - FQM :{{fqmstr}}</div>\n        <div class=\"p-col-fixed mrn-15\">\n            <button pButton class=\"btn-icon btn-white\" title=\"Close\" icon=\"icons8 icons8-delete font-20\"\n                (click)=\"commonServices.graphInSideBarForMT = false\"></button>\n        </div>\n    </div>\n    <div class=\"p-grid p-align-center p-col-12\">\n        <p-card class=\"p-col-6\">\n            <highcharts-chart [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n                [options]=\"options3\"></highcharts-chart>\n        </p-card>\n        <p-card class=\"p-col-6\">\n            <highcharts-chart [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n                [options]=\"options1\"></highcharts-chart>\n        </p-card>\n        <p-card class=\"p-col-6\">\n            <highcharts-chart [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n                [options]=\"options\"></highcharts-chart>\n        </p-card>\n\n    </div>\n</p-sidebar>\n\n<cav-table [value]=\"MTObjArr\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" [responsive]=\"true\"\n    scrollHeight=\"calc(100vh - 470px)\" (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.html":
/*!***********************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.html ***!
  \***********************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<p-sidebar [(visible)]=\"commonServices.graphInSideBarForDB\" position=\"right\" [modal]=\"false\" [style]=\"{'width':'700px'}\"\n  [showCloseIcon]=\"false\" appendTo=\"body\">\n  <div class=\"helpHeader p-grid p-align-center w-100-p\">\n    <div class=\"p-col mln-15 elipseText\" matTooltip=\"Query : {{Completequery}}\">\n      Compared Query Stat- Query :{{queryName}}</div>\n    <div class=\"p-col-fixed mrn-15\">\n      <button pButton class=\"btn-icon btn-white\" title=\"Close\" icon=\"icons8 icons8-delete font-20\"\n        (click)=\"commonServices.graphInSideBarForDB = false\"></button>\n    </div>\n  </div>\n  <div class=\"p-grid p-align-center p-col-12\">\n    <p-card class=\"p-col-6\">\n      <highcharts-chart [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n        [options]=\"options\"></highcharts-chart>\n    </p-card>\n    <p-card class=\"p-col-6\">\n      <highcharts-chart [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n        [options]=\"options1\"></highcharts-chart>\n    </p-card>\n    <p-card class=\"p-col-6\">\n      <highcharts-chart [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n        [options]=\"options2\"></highcharts-chart>\n    </p-card>\n    <p-card class=\"p-col-6\">\n      <highcharts-chart [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n        [options]=\"options3\"></highcharts-chart>\n    </p-card>\n  </div>\n</p-sidebar>\n\n<cav-table [value]=\"queryObjArr\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" [responsive]=\"true\"\n  scrollHeight=\"calc(100vh - 470px)\" (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.html":
/*!*****************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.html ***!
  \*****************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div id='sessionContent' [class.single-session]='flowpathData.length == 1'[class.multiple-session]='flowpathData.length > 1'>\n    <div class=\"jarviswidget jarviswidget-color-grey jarviswidget-sortable\" role=\"widget\">\n        <div class=\"jar-widget-contant mt-2\">\n            <div class=\"right-button\">\n                <button pButton icon=\"cav log-monitoring\" class=\"btn-icon mx-3\" tooltipPosition=\"left\"\n                    placeholder=\"Left\" (click)=\"openNetForest()\" pTooltip=\"Log Monitoring\"></button>\n                <button pButton icon=\"cav fusion-monitor\" class=\"btn-icon mx-3\" tooltipPosition=\"left\"\n                    placeholder=\"Left\" (click)=\"openNVFromND()\" pTooltip=\"UX Monitoring\"></button>\n                <!-- <button pButton icon=\"cav application\" class=\"btn-icon mx-3\" tooltipPosition=\"left\" placeholder=\"Left\"   (click)=\"openED()\"\n                           pTooltip=\"Open ED\"></button> -->\n                <!-- <img *ngIf=\"flowpathData.flowpathtype >= 32\" src=\"./assets/images/Flagged_flowpath.png\" style=\"height:15px; width:16px;cursor:pointer;vertical-align: bottom;margin-right: 5px;\" title=\"Flagged Flowpath Messages\" (click)=\"openErrorMsg()\"> -->\n                <i *ngIf=\"flowpathData.flowpathtype >= 32\" class=\"las-font-awesome-flag btn-icon mx-3\"\n                    style=\"height:15px; width:16px;cursor:pointer;\" title=\"Flagged Flowpath Messages\"\n                    (click)=\"openErrorMsg()\"></i>\n\n                <!-- <button pButton icon=\"icons8 icons8-delete\" tooltipPosition=\"left\" placeholder=\"Left\"  aria-hidden='true' (click)='closeSession()' class=\"btn-icon mx-3\"\n             pTooltip=\"Close Session\"></button> -->\n            </div>\n\n            <div class=\"helpButton\">\n                <ng-container *ngIf=\"index == 0\">\n                    <app-help [helpFileName]=\"'MethodCallDetail'\" [helpTitle]=\"'Method Call Detail'\"\n                        [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n                <ng-container *ngIf=\"index == 1\">\n                    <app-help [helpFileName]=\"'HotSpot'\" [helpTitle]=\"'HotSpot'\" [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n                <ng-container *ngIf=\"index == 2\">\n                    <app-help [helpFileName]=\"'DBQueriesReport'\" [helpTitle]=\"'DB Queries Report'\"\n                        [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n                <ng-container *ngIf=\"index == 3\">\n                    <app-help [helpFileName]=\"'HTTPReports'\" [helpTitle]=\"'HTTP Reports'\"\n                        [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n                <ng-container *ngIf=\"index == 4\">\n                    <app-help [helpFileName]=\"'ExceptionSummaryReport'\" [helpTitle]=\"'Exception Summary Report'\"\n                        [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n                <ng-container *ngIf=\"index == 5\">\n                    <app-help [helpFileName]=\"'methodTiming'\" [helpTitle]=\"'Method Timing'\"\n                        [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n                <ng-container *ngIf=\"index == 6\">\n                    <app-help [helpFileName]=\"'IPSummary'\" [helpTitle]=\"'IP Summary'\" [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n                <ng-container *ngIf=\"index == 7\">\n                    <app-help [helpFileName]=\"'TransactionFlowmap'\" [helpTitle]=\"'Transaction Flowmap'\"\n                        [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n                <ng-container *ngIf=\"index == 8\">\n                    <app-help [helpFileName]=\"'SequenceDiagram'\" [helpTitle]=\"'Sequence Diagram'\"\n                        [helpFolder]=\"'ddr'\"></app-help>\n                </ng-container>\n            </div>\n\n            <div>\n                <p-tabView class=\"ddr-tabs\" (onChange)=\"changeTab($event)\">\n                    <p-tabPanel header=\"Method Call Details\" [selected]=\"index == 0\">\n                        <!-- Non-OTEL mode -->\n                        <methodcallingtree *ngIf=\"!otelMode && index == 0\" [columnData]=\"flowpathData\">\n                        </methodcallingtree>\n\n                        <!-- OTEL mode -->\n                        <p-tabView *ngIf=\"otelMode && index == 0\" [activeIndex]=\"methodCallTabIndex\" (onChange)=\"changeMethodCallTab($event)\">\n                            <p-tabPanel header=\"Waterfall\" [selected]=\"methodCallTabIndex == 0\">\n                                <app-method-call-info *ngIf=\"methodCallTabIndex == 0\" [columnData]=\"flowpathData\">\n                                </app-method-call-info>\n                            </p-tabPanel>\n\n                            <p-tabPanel header=\"Flame Graph\" [selected]=\"methodCallTabIndex == 1\">\n                                <app-trace-flamegraph *ngIf=\"methodCallTabIndex == 1\" [columnData]=\"flowpathData\">\n                                </app-trace-flamegraph>\n                            </p-tabPanel>\n                        </p-tabView>\n                    </p-tabPanel>\n                    <p-tabPanel header=\"HotSpot\" [selected]=\"index == 1\">\n                        <app-hotspot *ngIf=\"index == 1\" [columnData]=\"flowpathData\"></app-hotspot>\n                    </p-tabPanel>\n                    <p-tabPanel header=\"DB Queries\" [selected]=\"index == 2\">\n                        <!-- <app-queries *ngIf=\"index == 2\" [columnData]=\"flowpathData\"></app-queries> -->\n                        <app-fp-to-db-component *ngIf=\"index == 2\" [columnData]=\"flowpathData\"></app-fp-to-db-component>\n                    </p-tabPanel>\n                    <p-tabPanel header=\"HTTP Report\" [selected]=\"index == 3\">\n                        <http-req-resp *ngIf=\"index == 3\" [columnData]=\"flowpathData\"></http-req-resp>\n                    </p-tabPanel>\n                    <p-tabPanel header=\"Exception\" [selected]=\"index == 4\">\n                        <exception-report *ngIf=\"index == 4\" [columnData]=\"flowpathData\" [showLink]=\"showLink\"\n                            (toggleWindow)=\"closeExcpReport($event)\"></exception-report>\n                    </p-tabPanel>\n                    <p-tabPanel header=\"Method Timing\" [selected]=\"index == 5\">\n                        <methodtiming *ngIf=\"index == 5\" [columnData]=\"flowpathData\"></methodtiming>\n                    </p-tabPanel>\n                    <p-tabPanel header=\"IP Summary\" [selected]=\"index == 6\">\n                        <app-ip-summary *ngIf=\"index == 6\" [columnData]=\"flowpathData\"></app-ip-summary>\n                    </p-tabPanel>\n                    <p-tabPanel header=\"End to End Tx Flowmap\" [selected]=\"index == 7\">\n                        <!-- Non OTEL mode -->\n                        <div *ngIf=\"!otelMode\">\n                            <div class=\"p-grid loader-container vertical-container h-100-vh\"\n                                *ngIf=\"commonService.loaderForDdr\">\n                                <div class=\"p-col p-col-align-center text-center\">\n                                    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span\n                                            class=\"font-25\">Loading</span></div>\n                                </div>\n                            </div>\n                            <app-transaction-flowmap *ngIf=\"index == 7\"></app-transaction-flowmap>\n                        </div>\n                        <!-- OTEL mode -->\n                        <app-transaction-service-map *ngIf=\"otelMode && index == 7\" [columnData]=\"flowpathData\">\n                        </app-transaction-service-map>\n                        <!-- <iframe #trxFrame style=\"width: 100%; height: calc(100vh - 155px);\" [src]=\"urlSafe\"></iframe> -->\n                    </p-tabPanel>\n                    <!-- <p-tabPanel header=\"Sequence Diagram\" [selected]=\"index == 8\">\n                             <sequence-diagram *ngIf=\"index == 8\" [columnData]=\"flowpathData\"></sequence-diagram>\n                         </p-tabPanel> -->\n\n                </p-tabView>\n            </div>\n\n        </div>\n    </div>\n</div>\n<p-dialog class=\"scenmodal\" header=\"FP Type Details\" width='410' [modal]=\"true\" appendTo=\"body\" [(visible)]=\"fptypeFlag\"\n    [resizable]=\"false\">\n    <div class=\"modalPopUp\">\n        <table cellspacing=\"3\" cellpadding=\"0\" border=\"2\" style=\"margin:0px 0px 0px 0px;width:365px;\">\n            <tr style=\"width:100px;height:30px\" valign=\"center\" align=\"center\">\n                <th>Message Code</th>\n                <th>Message</th>\n            </tr>\n            <tr *ngFor=\"let errorbit of errormsgObj \" style=\"width:100px;height:30px\" valign=\"center\" align=\"center\">\n                <td>{{errorbit.errorbit}}</td>\n                <td>{{errorbit.errmsg}}</td>\n            </tr>\n        </table>\n    </div>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.html":
/*!*******************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.html ***!
  \*******************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<p-toolbar class=\"ui-secondary-toolbar\">\r\n  <div class=\"p-grid p-justify-between p-align-center pl-5 pr-5\">\r\n    <!-- <a routerLink=\"/home/dashboard\"> -->\r\n      <i class=\"icons8 icons8-left toolbar-icon-color\" (click)=\"back()\"  style=\"cursor: pointer;\"></i>\r\n    <!-- </a> -->\r\n    <div class=\"p-col ui-toolbar-text\">{{commonService.currentReport}}</div>\r\n    <app-help *ngIf=\"isShowHelp\" [helpFileName]=\"subModuleName\"  [helpTitle]=\"commonService.currentReport\" [helpFolder]=\"'ns-ddr'\"></app-help>\r\n  </div>\r\n</p-toolbar>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.html":
/*!***********************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.html ***!
  \***********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid p-align-center p-justify-end\">\r\n<div class=\"paginatorCount\" *ngIf=\"(totalCount >= offset+limit)\"> {{offset+1}} - {{offset+limit}} of {{totalCount}} </div>\r\n<div *ngIf=\"totalCount >= 1 && (totalCount < offset+limit)\" class=\"paginatorCount\"> {{offset+1}} - {{totalCount}} of {{totalCount}}</div>\r\n<div *ngIf=\"((totalCount >= offset+limit) || totalCount > 50) && !nvFlag\">\r\n<p-paginator class=\"paginatorfix\" [rows]=\"commonService.rowspaerpage\" [totalRecords]=\"totalCount\" [rowsPerPageOptions]=\"[50,100,200,400]\" pageLinkSize=\"3\"\r\n    (onPageChange)=\"paginate($event)\"></p-paginator></div>\r\n<div *ngIf=\"((totalCount >= offset+limit) || totalCount > 50) && nvFlag\" id=\"tnv\">\r\n<p-paginator class=\"paginatorfix\" [rows]=\"commonService.rowspaerpage\" [(first)]=\"first\" [totalRecords]=\"totalCount\" [rowsPerPageOptions]=\"[50,100,200,400]\" pageLinkSize=\"2\"\r\n    (onPageChange)=\"paginate($event)\"></p-paginator></div>\r\n</div>\r\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.html":
/*!*****************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.html ***!
  \*****************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"graphDiv1 border-4\">\n    <highcharts-chart [Highcharts] = \"highcharts\" [options]=\"options\" \n      (load)=\"saveChart($event.context)\">\n    </highcharts-chart>\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.html":
/*!*********************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.html ***!
  \*********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--  **********  Report TYpe ***************  -->\n<as-split direction=\"horizontal\">\n  <as-split-area [size]=\"25\" minSize=\"20\">\n<div  style=\"overflow-x:hidden;\" class=\"sidedbar-accordion\">\n  <div class=\"overflow bottom-border border-3 pb-6\">\n  <div class='ui-g'>\n    <div class=\"p-nogutter1 p-grid p-align-center w-100-p\">\n      <div class=\"p-col-fixed width-140\">\n        <ng-container *ngIf=\"showReportField;  else ns_reports\">\n          Report \n        </ng-container>\n        <ng-template #ns_reports>\n          <span>{{this.commonServices.currentReport}}</span>\n        </ng-template>\n      </div>\n    <div class=\"p-col\">\n        <p-dropdown [disabled]=\"this.showNSFilter\" [options] = \"reportList\" [style]=\"{'min-width':'100%'} \"  [(ngModel)] = \"this.commonServices.currentReport\" (onChange)= \"changeReport()\" appendTo = \"body\"></p-dropdown>\n      </div>\n    \n\n      <!-- ************************ apply button *********** -->\n\n    </div>\n    <div  class=\"p-col-12 text-danger\"  *ngIf='selectAnyCheckBoxFlag'>{{showAnyCheckBoxErrorMessage}}</div>\n      \n    <div *ngIf = 'enableMultiDC && !this.showNSFilter' class=\"p-nogutter1 p-grid p-align-center w-100-p\">\n      <div class=\"p-col-fixed width-140\">\n    \n    <p-checkbox label = \"Multi DC \" binary=true (onChange) = 'isMultiDcEnable()'  [(ngModel)] = \"isMultiDC\"></p-checkbox>\n    </div>\n    <div class=\"p-col\">\n    \n    <p-dropdown [options] = 'dcList' class=\"w-100-p\"  [style] = \"{'min-width' :'100%'}\" placeholder=\"Select\" [disabled] = \"!isMultiDC\" [(ngModel)] = \"this.selectedDC\" (onChange) = 'changeMultiDC()'></p-dropdown>\n      \n    </div>\n         <div class=\"p-col-12 text-danger\"  *ngIf='selectIsMultiDCCheckFlag'>{{showCheckBoxErrorMessage}}</div>\n    </div>\n\n\n\n\n    <!--  **********  Time Filter ***************  -->\n    <div class=\"p-nogutter1 p-grid p-align-center w-100-p\">\n      <div class=\"p-col-fixed width-140\">\n        <p-checkbox value=\"val1\" label=\"Time Filter\" binary=true (onChange)=\"timeOptions()\" [(ngModel)]=\"timeFilter\"></p-checkbox>\n      </div>\n      <div class=\"p-col\">\n        <p-dropdown appendTo=\"body\" [options]=\"standardTime\"  (onChange)=\"fetchMetadata('phaseList')\"scrollHeight=\"188px\" [disabled]=\"!timeFilter\" [(ngModel)]=\"selectedTime\" [style]=\"{'min-width':'100%'}\" [panelStyle]=\"{maxWidth:'126px'}\" placeholder=\"Select\"></p-dropdown>\n      </div>\n\n      \n          <div class=\"p-col\" *ngIf=\"selectedTime=='Specified Phase'\" style=\"margin-left: 140px;\">\n            <p-dropdown [options]=\"phaseTime\" scrollHeight=\"188px\"   [(ngModel)]=\"selectedPhase\" [style]=\"{'min-width':'100%'}\" placeholder=\"Select\"></p-dropdown>\n        </div>\n    </div>\n\n     <div class=\"p-col-12 text-danger\" *ngIf='selectCheckBoxFlag'>{{showCheckBoxErrorMessage}}</div>\n     <ng-container *ngIf=\"this.selectedTime == 'Custom Time'\">\n    <div class=\"p-nogutter1 p-grid p-align-center w-100-p\">\n     \n      <div class=\"p-col-fixed width-140\"> From</div>\n      <div class=\"p-col\">   \n        <p-calendar inputStyleClass=\"w-100-p\" [showSeconds] = \"true\" [showIcon]=\"true\" (onInput)=\"onStrDate($event)\" dateFormat=\"mm/dd/yy\" (onSelect)=\"onStrDate($event)\" [monthNavigator]=\"true\"\n          [yearNavigator]=\"true\" yearRange=\"1970:2030\" [showTime]=\"true\" [(ngModel)]=\"strDate\" placeholder=\"mm/dd/yy hh:mm:ss\" appendTo=\"body\"> </p-calendar>\n        </div>\n    </div>\n    <div class=\"p-nogutter1 p-grid p-align-center w-100-p\">\n        <div class=\"p-col-fixed width-140\">To</div>\n      <div class=\"p-col\"> \n        <p-calendar inputStyleClass=\"w-100-p\" [showSeconds] = \"true\" [showIcon]=\"true\" (onInput)=\"onEndDate($event)\"  dateFormat=\"mm/dd/yy\" (onSelect)=\"onEndDate($event)\" [monthNavigator]=\"true\"\n          [yearNavigator]=\"true\" yearRange=\"1970:2030\" [showTime]=\"true\" [(ngModel)]=\"endDate\" placeholder=\"mm/dd/yy hh:mm:ss\" appendTo=\"body\"></p-calendar>\n        </div>\n      \n      <div  class=\"p-col-12 text-danger\"  *ngIf='customTimeError'>{{customTimeErrorMessage}}</div>\n      <div  class=\"p-col-12 text-danger\"  *ngIf='showStartTimeError'>{{customStartTimeError}}</div>\n      <div  class=\"p-col-12 text-danger\"  *ngIf='showEndTimeError'>{{customEndTimeError}}</div>\n      </div>\n     </ng-container>\n      <!-- change kardio bhai yae bhi test wali condition pljj\n    <div class ='p-col-12' style=\"height:100px\">\n    <div class ='p-col-4'>{{this.commonServices.currentReport}} Response \n    </div>\n    <div class ='p-col-4'>\n        <p-dropdown [options]=\"ResponseTime\" scrollHeight=\"188px\"  [(ngModel)]=\"selectedResponse\" [style]=\"{'width':'125px'}\"  onchange=\"changeResponseTime()\"></p-dropdown>\n    </div>\n      <div class='p-col-4'>   \n      <input type=\"text\" value='1000' [(ngModel)]=\"responseValue\" >\n    </div>\n    </div> -->\n\n\n       <!--  **********  Response Time Filter for NS ***************  -->\n          <div class='p-nogutter1 p-grid p-align-center w-100-p' *ngIf=\"this.showNSFilter\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" binary=true label=\"Response\" (onChange)=\"responseCheck()\"\n                [(ngModel)]=\"checkedResponseTime\"></p-checkbox>\n            </div>\n            <div class=\"p-col-fixed\">\n              <p-dropdown [options]=\"resCompareOptions\" (onChange)=\"responseEqualCase()\" placeholder=\"\" scrollHeight=\"100px\"\n                [disabled]=\"!checkedResponseTime\" [style]=\"{'min-width':'100px'}\" [(ngModel)]=\"resSelectedCompareOption\"\n                ></p-dropdown>\n            </div>\n            <div class=\"p-col\">\n              <input type=\"text\" class=\"w-100-p\" pInputText (keypress)=\"onlyNumberKey($event)\" size=\"5\" value=\"1000\"\n                [disabled]=\"!checkedResponseTime\" [(ngModel)]=\"responseTime\" placeholder=\"ms\">\n            </div>\n            <ng-container *ngIf=\"showingEqualResponseBox == true\">\n              <div class=\"p-col-fixed\">+/-</div>\n              <div class=\"p-col\">\n                <input (keypress)=\"onlyNumberKey($event)\" pInputText class=\"w-100-p\" type=\"text\" size=\"2\" value=\"0\"\n                  [disabled]=\"!checkedResponseTime\" [(ngModel)]=\"resVariance\" placeholder=\"ms\">\n              </div>\n            </ng-container>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectResponseCheckBoxFlag1'>{{showInputFieldErrorMessage}}</div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectResponseCheckBoxFlag'>{{showInputFieldErrorMessage}}</div>\n          </div>\n\n    <!--  ********** Group by and order by filters ***************  -->\n\n\n      <p-accordion *ngIf=\"showGroupBy()\">\n        <p-accordionTab header=\"Group By and Order By\" [selected]=\"true\">\n          <div class=\"p-nogutter1 p-grid p-align-center\">\n            <div class='p-col-fixed width-140'>\n              <p-checkbox value=\"val1\" label=\"GroupBy\" binary=true (onChange)=\"getGroupBy()\" [(ngModel)]=\"checkGroup\" [disabled]=\"enableGroupBy()\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-multiSelect appendTo=\"body\" defaultLabel=\"Select\" [options]=\"groupBy\"  maxSelectedLabels=\"1\" [disabled]=\"!checkGroup\" (onChange)=\"getOrderBy()\" [style]=\"{'min-width':'100%'}\"\n                [(ngModel)]=\"selectedGroupBy\" [panelStyle]=\"{maxWidth:'100px'}\"></p-multiSelect>\n            </div>\n            <div  class =\"p-col-12 text-danger\"  *ngIf='selectGroupByCheckBoxFlag'>{{showCheckBoxErrorMessage}}</div>  \n          </div>\n          <div class=\"p-nogutter1 p-grid p-align-center\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"OrderBy\" binary=true [disabled]=\"enableOrderBy()\" (onChange)=\"getOrderBy()\" [(ngModel)]=\"checkOrder\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-multiSelect appendTo=\"body\" [options]=\"orderBy\" defaultLabel=\"Select\"  maxSelectedLabels=\"1\" [disabled]=\"!checkOrder\" [style]=\"{'min-width':'100%'}\" [(ngModel)]=\"selectedOrderBy\" [panelStyle]=\"{maxWidth:'100px'}\"></p-multiSelect>\n            </div>\n            <div  class=\"p-col-12 text-danger\"  *ngIf='selectOrderByCheckBoxFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n\n    <!--  ********** Common filters ***************  -->\n    <p-accordion>\n      <p-accordionTab header=\"Common Filters \" [selected]=\"true\" *ngIf=\"showCommonFilters\">\n\n\n        <!--  **********  Tier Filter **************-->\n        <div class=\"p-grid p-align-center p-nogutter1\">\n          <div class=\"p-col-fixed width-140\">\n            <p-checkbox value=\"val1\" label=\"Tier\" binary=true (onChange)=\"fetchMetadata('tier')\" [(ngModel)]=\"selectedTier\"></p-checkbox>\n          </div>\n          <div class=\"p-col\">\n            <p-multiSelect appendTo=\"body\" class = \"ddr-multiselect-all ddr-link\" defaultLabel=\"Select\"  [options]=\"tierList\" maxSelectedLabels=\"1\" [filter]=true [style]=\"{'min-width':'100%'}\"  (onChange)=\"setDefaultServerAppFilter()\" [disabled]=\"!selectedTier\"\n              [(ngModel)]=\"tierName\" [panelStyle]=\"{maxWidth:'120px'}\" ></p-multiSelect>\n          </div>\n          <div class=\"p-col-12 text-danger\"  *ngIf='selectTierFlag'>{{showCheckBoxErrorMessage}}</div>\n        </div>\n        <!--  **********  Server Filter ***************  -->\n        <div class=\"p-grid p-align-center p-nogutter1\">\n          <div class=\"p-col-fixed width-140\">\n            <p-checkbox value=\"val2\" label=\"Server\" binary=true [disabled]=\"!(this.selectedTier == true  && this.tierName.length > 0)\" (onChange)=\"fetchMetadata('server')\" [(ngModel)]=\"selectedServer\"></p-checkbox>\n          </div>\n          <div class=\"p-col\">\n            <p-multiSelect appendTo=\"body\" class = \"ddr-multiselect-all ddr-link\"  defaultLabel=\"Select\" [options]=\"serverList\" maxSelectedLabels=\"1\" [filter]=true [style]=\"{'min-width':'100%'}\"  (onChange)=\"setDefaultAppFilter()\" [disabled]=\"!selectedServer\"\n              [(ngModel)]=\"serverName\" [panelStyle]=\"{maxWidth:'140px'}\" ></p-multiSelect>\n          </div>\n          <div class=\"p-col-12 text-danger\" *ngIf='selectServerFlag'>{{showCheckBoxErrorMessage}}</div>\n        </div>\n\n        <!--  **********  App Filter ***************  -->\n        <div class=\"p-grid p-align-center p-nogutter1\">\n          <div class=\"p-col-fixed width-140\">\n            <p-checkbox value=\"val3\" label=\"Instance\" binary=true [disabled]=\"!(this.selectedServer == true && this.serverName.length > 0)\" (onChange)=\"fetchMetadata('app')\" [(ngModel)]=\"selectedApp\"></p-checkbox>\n          </div>\n          <div class=\"p-col\">\n            <p-multiSelect  appendTo=\"body\" class = \"ddr-multiselect-all ddr-link\"  defaultLabel=\"Select\" [options]=\"appList\" maxSelectedLabels=\"1\" [style]=\"{'min-width':'100%'}\"  (onChange)=\"appFilter()\" [filter]=true [disabled]=\"!selectedApp\" [(ngModel)]=\"appName\" [panelStyle]=\"{maxWidth:'140px'}\" ></p-multiSelect>\n          </div>\n          <div class=\"p-col-12 text-danger\"  *ngIf='selectAppFlag'>{{showCheckBoxErrorMessage}}</div>\n        </div>\n\n        <!--  **********  Flowpath instance Filter **************-->\n        <div *ngIf=\"this.commonServices.currentReport != 'Hotspot' && this.commonServices.currentReport != 'DB Report' && this.commonServices.currentReport != 'Exception'  && this.commonServices.currentReport != 'FlowpathGroupBy' && this.commonServices.currentReport != 'DBGroupBy' \" class='p-grid p-align-center p-nogutter1'>\n          <div class=\"p-col-fixed width-140\">\n            <p-checkbox value=\"val1\" class=\"font-11\" label=\"Flowpath Instance\" binary=true (onChange)=\"fpInstanceInfo()\" [(ngModel)]=\"selectedFP\"></p-checkbox>\n          </div>\n          <div class=\"p-col\">\n            <input type=\"text\" pInputText class=\"w-100-p\" (keypress)=\"onlyNumberKeyAndComma($event)\" value=\"0\" [disabled]=\"!selectedFP\" [(ngModel)]=\"fpInstance\">\n          </div>\n          <div class=\"p-col-12 text-danger\"  *ngIf='selectfpInstanceFlag'>{{showInputFieldErrorMessage}}</div>\n        </div>\n\n\n        <!--  **********  Buisness Transaction (url) Filter **************-->\n        <div *ngIf=\"this.checkedUrl == false && this.commonServices.currentReport != 'Exception' && this.commonServices.currentReport != 'Hotspot' \" class=\"p-grid p-align-center p-nogutter1\">\n\n            <div class=\"p-col-fixed width-140\">\n                <p-checkbox value=\"val5\" title=\"Business Transaction\" label=\"BT\" binary=true (onChange)=\"fetchMetadata('businessTransaction')\" [(ngModel)]=\"checkedBuisnessTransaction\"></p-checkbox>\n             \n              <div *ngIf=\"checkedBuisnessTransaction\">\n                <span class=\"las-arrow-left-solid\" title=\"Previous BT\" *ngIf=\"prev\" (click)=\"previous()\"></span>\n                <span class=\"las-arrow-right-solid\" title=\"Next (1000 or lesser BTs)\" *ngIf=\"nxt\" (click)=\"next()\"></span>\n              </div>\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown  appendTo=\"body\" dropdownIcon=\"icons8 icons8-expand-arrow\" scrollHeight=\"140px\"  [filter]=true   [options]=\"BTOptions\"  [style]=\"{'min-width':'100%'}\" [(ngModel)]=\"selectedBuisnessTransaction\"\n              [disabled]=\"!checkedBuisnessTransaction\" placeholder=\"Select\"></p-dropdown>\n    \n            <div class=\"p-col-12 text-danger\" *ngIf='selectBTFlag'>{{showCheckBoxErrorMessage}}</div>\n        </div>\n      </div>\n      <div  class=\"p-grid p-align-center p-nogutter1\">\n      <div class=\"p-col\" *ngIf=\"checkedBuisnessTransaction\" style=\"margin-left: 140px;\">\n        ( {{this.btOffset + 1}} - {{this.btEndValue}} of {{this.btCount}} )\n      </div>\n      </div>\n\n          <!--  ********** BT Category*****************  -->\n          <div *ngIf=\"this.commonServices.currentReport != 'Hotspot' && this.commonServices.currentReport != 'Exception' && this.commonServices.currentReport != 'IP Summary'\" class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"BT Category\" binary=true (onChange)=\"btcheck()\" [(ngModel)]=\"selectedBT\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown appendTo=\"body\"   [options]=\"BTCategory\" [filter]=true [(ngModel)]=\"selectedBTCategory\" [disabled]=\"!selectedBT\" [style]=\"{'min-width':'100%'}\"\n                placeholder=\"Select \" [panelStyle]=\"{maxWidth:'125px'}\"></p-dropdown>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectBTCategoryFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n\n           <!--  ********** Integration points*****************  -->\n          <div *ngIf=\"this.commonServices.currentReport == 'IP Summary' \" class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"Integration point\" binary=true (onChange)=\"fetchMetadata('integrationPoint')\" [(ngModel)]=\"selectedIP\">\n              </p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-multiSelect class=\"ddr-multiselect-all ddr-link\" defaultLabel=\"Select\" [options]=\"IntegrationPoint\"\n                maxSelectedLabels=\"1\" [filter]=true [style]=\"{'min-width':'100%'}\" [disabled]=\"!selectedIP\"\n                [(ngModel)]=\"selectedIntegrationPoint\" [panelStyle]=\"{maxWidth:'140px'}\"></p-multiSelect>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectIntegrationPointFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n      </p-accordionTab>\n    </p-accordion>\n\n    <!-- ***********Tags Filter ************* -->\n<span *ngIf=\"this.commonServices.currentReport == 'Flowpath'\" class=\"w-100-p\">\n  <app-common-tag #commonTag ></app-common-tag>\n</span>\n\n    <!--  ********** *************** Flowpaths Filter ***************  -->\n    <div *ngIf=\"this.commonServices.currentReport == 'Flowpath'\" class=\"w-100-p\">\n      <p-accordion>\n        <p-accordionTab header=\"Flowpath Filter\" [selected]=\"true\">\n          <!--  **********  Response Time Filter ND***************  -->\n\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" binary=true label=\"Processing Time\" (onChange)=\"responseCheck()\" [(ngModel)]=\"checkedResponseTime\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown [options]=\"resCompareOptions\"  (onChange)=\"responseEqualCase()\" placeholder=\"\" scrollHeight=\"100px\" [disabled]=\"!checkedResponseTime\"\n                [(ngModel)]=\"resSelectedCompareOption\" [style]=\"{'min-width':'100%'}\"></p-dropdown>\n            </div>\n            <div class=\"p-col\">\n                <input type=\"text\" pInputText class=\"w-100-p\" (keypress)=\"onlyNumberKey($event)\" value=\"0\" [disabled]=\"!checkedResponseTime\" [(ngModel)]=\"responseTime\" placeholder=\"ms\">\n            </div>\n          \n            <ng-container class=\"p-col-3 p-offset-9\" *ngIf=\"showingEqualResponseBox == true\">\n              <div class=\"p-col-fixed\"> +/-</div>\n              <div class=\"p-col-fixed\">\n                <input pInputText (keypress)=\"onlyNumberKey($event)\" type=\"text\" size=\"2\"\n                  value=\"0\" [disabled]=\"!checkedResponseTime\" [(ngModel)]=\"resVariance\" placeholder=\"ms\"></div>\n            </ng-container>\n           <div class=\"p-col-12 text-danger\" *ngIf='selectResponseCheckBoxFlag1'>{{showInputFieldErrorMessage}}</div>\n            \n           \n            <div class=\"p-col-12 text-danger\" *ngIf='selectResponseCheckBoxFlag'>{{showInputFieldErrorMessage}}</div>\n          </div>\n          \n          \n    \n          <!--  **********  Method Count Filter ***************  -->\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"Methods (>=)\" (onChange)=\"methodCheck()\" binary=true [(ngModel)]=\"checkedMethodCount\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <input type=\"text\" pInputText class=\"w-100-p\" (keypress)=\"onlyNumberKey($event)\" value=\"0\" [disabled]=\"!checkedMethodCount\" [(ngModel)]=\"minMethods\">\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedminMethodsFlag'>{{showInputFieldErrorMessage}}</div>\n          </div>\n\n          <!--  ********** Correlation ID *****************  -->\n\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"Corr ID \" (onChange)=\"corelationcheck()\" binary=true [(ngModel)]=\"checkedCorrId\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <input type=\"text\" pInputText class=\"w-100-p\" value=\"0\" [disabled]=\"!checkedCorrId\" [(ngModel)]=\"corrId\">\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown   [options]=\"corrIdModeOptions\" [disabled]=\"!checkedCorrId\" [(ngModel)]=\"selectedCorrIdMode\" [style]=\"{'min-width':'100%'}\"\n              placeholder=\"Select\"></p-dropdown>\n            </div>\n\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedCorrIdModeFlag1'>{{showInputFieldErrorMessage}}</div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedCorrIdModeFlag'>{{showInputFieldErrorMessage}}</div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedCorrIdModeFlag2'>{{showCheckBoxErrorMessage}}</div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedCorrIdModeFlag'>{{showCheckBoxErrorMessage}}</div>\n            </div>\n\n            <div class=\"p-grid p-align-center p-nogutter1\">\n              <div class=\"p-col-fixed width-140\">\n                <p-checkbox value='val1' label='Order By' binary=true (onChange)='fpOrderCheck()' [(ngModel)]=\"fpOrderByCheck\"></p-checkbox>\n              </div>\n              <div class=\"p-col\">\n                <p-dropdown  [style]=\"{'min-width':'100%'}\" [options]='fpOrderByOptions' [disabled]='!fpOrderByCheck' [(ngModel)]='selectedFpOrderBy' placeholder='Select'></p-dropdown>\n              </div>\n                <div class=\"p-col-12 text-danger\" *ngIf='selectedFpOrderByFlag'>{{showInputFieldErrorMessage}}</div>\n            </div>\n          <!--  **********  Dynamic logging Filter ***************  -->\n\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-12\">\n              <p-checkbox value=\"val1\" label=\"Dynamic logging\" (onChange)=\"DLCheck()\" binary=true [(ngModel)]=\"checkDLFlag\"></p-checkbox>\n            </div>\n\n            <div class=\"p-col-12\">\n              <p-checkbox value=\"val1\" label=\"Req/Resp\" (onChange)=\"ReqRespCheck()\" binary=true [(ngModel)]=\"checkReqRespFlag\"></p-checkbox>\n            </div>\n          </div>\n\n          <!--  **********  Request/response Filter ***************  -->\n            </p-accordionTab>\n      </p-accordion>\n    </div>\n    <!--  ********** DB request Filters*****************  -->\n    <div *ngIf=\"this.commonServices.currentReport == 'DB Report'\" class=\"w-100-p\">\n      <p-accordion>\n        <p-accordionTab header=\"DB Query Filter\" [selected]=\"true\">\n          <!-- <div class='p-col-12 side-bar-height' >\n            <div class=\"p-col-6\">\n              <p-checkbox value=\"val1\" label=\"Query Type\" binary=true [(ngModel)]=\"selectedQuery\"></p-checkbox>\n            </div>\n            <div class=\"p-col-3\">\n              <input type=\"text\" size=\"4\" value=\"0\" [disabled]=\"!selectedQuery\" [(ngModel)]=\"queryText\">\n            </div>\n            <div class='p-col-3'>\n              <p-dropdown [options]=\"queryTypeOptions\" [(ngModel)]=\"selectedQueryType\" [disabled]=\"!selectedQuery\" [style]=\"{'width':'70px'}\"\n                placeholder=\"choose\"></p-dropdown>\n            </div>\n          </div> -->\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n               <p-checkbox value=\"val1\" label=\"Top N Queries for Pie Charts\" (onChange)=\"checkTopNQuery()\" binary=true [(ngModel)]=\"checkNQueryforPie\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <input type=\"text\" class=\"w-100-p\" pInputText (keypress)=\"onlyNumberKey($event)\" size=\"7\" value=\"0\" [disabled]=\"!checkNQueryforPie\" [(ngModel)]=\"selectedTopNQuery\">\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectCheckNQuerryFlag'>{{showInputFieldErrorMessage}}</div>\n          </div>\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox label='Order By' binary=true (onChange)='dbOrderBy()' [(ngModel)]='dbOrderByCheck'></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown [style]=\"{'min-width':'100%'}\"   [options]='dbOrderByOptions' [(ngModel)]='selectedDbOrderBy' [disabled]='!dbOrderByCheck' placeholder='Select'></p-dropdown>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectDBOrderByCheckFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n          </p-accordionTab>\n          </p-accordion>\n    </div>\n\n     <!--  ********** Method Timing Filters*****************  -->\n    <div *ngIf=\"this.commonServices.currentReport == 'Method Timing'\" class=\"w-100-p\">\n      <p-accordion>\n        <p-accordionTab header='Method Timing Filter' [selected]='true'>\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"Top N Entities for Pie Charts\" title='Top N Method(s) or Class or Package(s)' (onChange)=\"checkTopNEntity()\" binary=true [(ngModel)]=\"checkNEntityforPie\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <input type=\"text\" pInputText (keypress)=\"onlyNumberKey($event)\" class=\"w-100-p\" value=\"0\" [disabled]=\"!checkNEntityforPie\" [(ngModel)]=\"selectedTopNEntity\">\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedTopNEntityFlag'>{{showInputFieldErrorMessage}}</div>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n\n    <!--  ********** Exception Filters*****************  -->\n    <div *ngIf=\"this.commonServices.currentReport == 'Exception'\" class=\"w-100-p\">\n      <p-accordion>\n        <p-accordionTab header=\"Exception Filter\" [selected]=\"true\">\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class='p-col-fixed width-140'>\n              <p-checkbox value=\"val1\" label=\"Exception Class\" binary=true (onChange)=\"fetchMetadata('exceptionclassname')\" [(ngModel)]=\"selectedExceptionClass\"></p-checkbox>\n            </div>\n\n            <div class=\"p-col\">\n              <p-dropdown appendTo=\"body\"  [filter]=true [options]=\"exceptionClassOptions\" [(ngModel)]=\"selectedException\" [disabled]=\"!selectedExceptionClass\" placeholder=\"Select\" [style]=\"{'min-width':'100%'}\" ></p-dropdown>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectExceptionClassFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n         \n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class='p-col-fixed width-140'>\n              <p-checkbox value=\"val1\" label=\"Throwing Class\" binary=true (onChange)=\"fetchMetadata('exceptionthrowingclassname')\" [(ngModel)]=\"selectedThrowingClass\"></p-checkbox>\n            </div>\n\n            <div class=\"p-col\">\n              <p-dropdown appendTo=\"body\"  [filter]=true [options]=\"throwingClassOptions\" [(ngModel)]=\"selectedExceptionThrowingClass\" [disabled]=\"!selectedThrowingClass\"\n                placeholder=\"Select \" [style]=\"{'min-width':'100%'}\"></p-dropdown>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedExceptionThrowingClassFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n        \n\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class='p-col-fixed width-140'>\n              <p-checkbox value=\"val1\" label=\"Throwing Method\" binary=true (onChange)=\"fetchMetadata('exceptionthrowingmethodname')\" [(ngModel)]=\"selectedThrowingMethod\"></p-checkbox>\n            </div>\n\n            <div class=\"p-col\">\n              <p-dropdown appendTo=\"body\"  class=\"dropup\" [filter]=true [options]=\"throwingMethodOptions\" [(ngModel)]=\"selectedExceptionThrowingMethod\" [disabled]=\"!selectedThrowingMethod\"\n                placeholder=\"Select \" [style]=\"{'min-width':'100%'}\"></p-dropdown>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedExceptionThrowingMethodFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class='p-col-fixed width-140'>\n              <p-checkbox value=\"val1\" label=\"Cause\" binary=true (onChange)=\"fetchMetadata('exceptioncause')\" [(ngModel)]=\"selectedExceptionCause\"></p-checkbox>\n            </div>\n\n            <div class=\"p-col\">\n              <p-dropdown appendTo=\"body\"  [filter]=true [options]=\"exceptionCauseOptions\" [(ngModel)]=\"selectedExceptionCauseType\" [disabled]=\"!selectedExceptionCause\"\n                placeholder=\"Select \" [style]=\"{'min-width':'100%'}\"></p-dropdown>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedExceptionCauseTypeFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class='p-col-fixed width-140'>\n              <p-checkbox value=\"val1\" label=\"Exception Message\" binary=true (onChange)=\"fetchMetadata('exceptionmsg')\" [(ngModel)]=\"selectedExceptionMessage\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown appendTo=\"body\"  [filter]=true [options]=\"exceptionMessageOptions\" [(ngModel)]=\"selectedExceptionMessageType\" [disabled]=\"!selectedExceptionMessage\"\n                placeholder=\"Select\" [style]=\"{'min-width':'100%'}\"></p-dropdown>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedExceptionMessageTypeFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class='p-col-fixed width-140'>\n              <p-checkbox value=\"val1\" label=\"Stack Trace (Containing)\" (onChange)=\"stackTraceInfo()\" binary=true [(ngModel)]=\"selectedStackTrace\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <input type=\"text\" pInputText class=\"w-100-p\" value=\"0\" [disabled]=\"!selectedStackTrace\" [(ngModel)]=\"selectedStack\">\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectedStackFlag'>{{showInputFieldErrorMessage}}</div>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n\n    <!--  ********** URL status*****************  -->\n    <div *ngIf=\"this.showNSFilter && this.commonServices.currentReport != 'Hotspot' && this.commonServices.currentReport != 'IP Summary'\" class=\"w-100-p\">\n      <p-accordion>\n        <p-accordionTab header=\"Request Status\" [selected]=\"true\">\n          <div class=\"p-nogutter1 p-grid p-align-center\">\n            <div class=\"p-col-4\">\n              <p-radioButton name=\"group1\" value=\"-2\" (click)=urlRadioButton() label=\"All\" [(ngModel)]=\"selectedUrlStatus\" inputId=\"opt1\"></p-radioButton>\n            </div>\n\n            <div class=\"p-col-4\">\n              <p-radioButton name=\"group1\" value=\"0\" (click)=urlRadioButton() label=\"All Success\" [(ngModel)]=\"selectedUrlStatus\" inputId=\"opt2\"></p-radioButton>\n            </div>\n\n            <div class=\"p-col-4\">\n              <p-radioButton name=\"group1\" value=\"-1\" (click)=urlRadioButton() label=\"All Failures\" [(ngModel)]=\"selectedUrlStatus\" inputId=\"opt3\"></p-radioButton>\n            </div>\n\n            <div class=\"p-col-5\">\n              <p-radioButton name=\"group1\" value=\"4\" (click)=\"fetchMetadata('errorcodes')\" label=\"Failure Types\" [(ngModel)]=\"selectedUrlStatus\" inputId=\"opt4\"></p-radioButton>\n            </div>\n\n            <div class=\"p-col-7\" *ngIf=\"failure\">\n              <p-multiSelect appendTo=\"body\"  [options]=\"failureTypes\" scrollHeight=\"100px\" maxSelectedLabels=\"1\" [style]=\"{'min-width':'100%'}\" [(ngModel)]=\"selectedFailureId\"></p-multiSelect>\n            </div>\n\n            <div  class=\"p-col-12 text-danger\" *ngIf='selectFailureTypeFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n\n    <!-- ***********************NV Filters **************** -->\n    <div *ngIf=\"this.commonServices.currentReport == 'Flowpath' && this.commonServices.NVUrl != 'NA' \" class=\"w-100-p\">\n        <p-accordion >\n          <p-accordionTab header=\"NV Filters\" [selected]=\"false\">\n              <div class=\"p-grid p-align-center p-nogutter1\">\n                  <div class=\"p-col-fixed width-140\">\n                    <p-checkbox value=\"val1\" label=\"ND Session Id\" binary=true (onChange)=\"nvFilters('ndSessionID')\" [(ngModel)]=\"isCheckedSessionId\"></p-checkbox>\n                  </div>\n                  <div class=\"p-col\">\n                    <input (keypress)=\"onlyNumberKeyAndComma($event)\" pInputText class=\"w-100-p\" type=\"text\" size=\"14\" value=\"0\" [disabled]=\"!isCheckedSessionId\" [(ngModel)]=\"ndSessionId\">\n                  </div>\n                    <div class=\"p-col-12 text-danger\" *ngIf='ndSessionIdFlag'>{{showInputFieldErrorMessage}}</div>\n                </div>\n  \n                <div class=\"p-grid p-align-center p-nogutter1\">\n                    <div class=\"p-col-fixed width-140\">\n                      <p-checkbox value=\"val1\" label=\"NV Page Id\" binary=true (onChange)=\"nvFilters('nvPageID')\" [(ngModel)]=\"isCheckedPageId\"></p-checkbox>\n                    </div>\n                    <div class=\"p-col\">\n                      <input (keypress)=\"onlyNumberKeyAndComma($event)\" pInputText class=\"w-100-p\" type=\"text\" size=\"14\" value=\"0\" [disabled]=\"!isCheckedPageId\" [(ngModel)]=\"nvPageId\">\n                    </div>\n                    <div class=\"p-col-12 text-danger\" *ngIf='nvPageIdFlag'>{{showInputFieldErrorMessage}}</div>\n                  </div>\n                  \n                  <div *ngIf=\"this.commonServices.checkNVSessionId == '1'\" class=\"p-grid p-align-center p-nogutter1\">\n                      <div class=\"p-col-fixed width-140\">\n                        <p-checkbox value=\"val1\" label=\"NV Session Id\" binary=true (onChange)=\"nvFilters('nvSessionID')\" [(ngModel)]=\"isCheckedNVSessionID\"></p-checkbox>\n                      </div>\n                      <div class=\"p-col\">\n                        <input (keypress)=\"onlyNumberKeyAndComma($event)\" type=\"text\" size=\"14\" value=\"0\" [disabled]=\"!isCheckedNVSessionID\" [(ngModel)]=\"nvSessionId\">\n                      </div>\n                        <div class=\"p-col-12 text-danger\" *ngIf='nvSessionIdFlag'>{{showInputFieldErrorMessage}}</div>\n                    </div>\n  \n           </p-accordionTab>\n          </p-accordion>\n      </div>\n\n    <!-- ************************NS Filters ***************** -->\n    <div *ngIf=\"this.showNSFilter && this.commonServices.currentReport != 'Hotspot' && this.commonServices.currentReport != 'Exception'\" class=\"w-100-p\">\n      <p-accordion>\n        <p-accordionTab header=\"Script Filters\" [selected]=\"true\">\n         \n          <div class=\"p-align-center p-grid p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"Script\" binary=true [(ngModel)]=\"checkedScript\" (onChange)=\"validateScriptCheck()\" [disabled]=\"enableScript()\"></p-checkbox>\n            </div>\n\n            <div class=\"p-col\">\n              <p-dropdown  appendTo=\"body\"  [filter]=true [options]=\"scriptOptions\" [(ngModel)]=\"selectedScript\" [disabled]=\"!checkedScript\" placeholder=\"select\"\n              (onChange)=\"validateScriptCheck('change')\" [style]=\"{'min-width':'100%'}\"></p-dropdown>\n            </div>\n            <div class=\"p-col-12 text-danger\" *ngIf='selectScriptCheckBoxFlag'>{{showCheckBoxErrorMessage}}</div>\n          </div>\n\n        <div class=\"p-align-center p-grid p-nogutter1\">\n          <div class=\"p-col-fixed width-140\">\n            <p-checkbox value=\"val1\" label=\"Transaction\" binary=true [(ngModel)]=\"checkedTransaction\"\n              (onChange)=\"validateTransactionCheck()\" [disabled]=\"!checkBoxTransaction\" title={{hintTransaction}}></p-checkbox>\n          </div>\n          <div class=\"p-col\">\n            <p-dropdown appendTo=\"body\" [filter]=true [options]=\"transactionOptions\" [(ngModel)]=\"selectedTransaction\"\n              [disabled]=\"!checkedTransaction\" placeholder=\"select\" [style]=\"{'min-width':'100%'}\"></p-dropdown>\n          </div>\n          <div class=\"p-col-fixed\" *ngIf=\"showTransactionPagination\">\n            <span class=\"las-arrow-left-solid\" title=\"Previous BT\" style=\"margin-right: 5px\" *ngIf=\"true\"\n              (click)=\"previous()\"></span>\n            lalalalalal\n            <span class=\"las-arrow-right-solid\" title=\"Next (1000 or lesser BTs)\" *ngIf=\"true\" (click)=\"next()\"></span>\n          </div>\n          <div  class=\"p-col-12 text-danger\" *ngIf='selectTransactionCheckBoxFlag'>{{showCheckBoxErrorMessage}}</div>\n        </div>\n\n<div class=\"p-align-center p-grid p-nogutter1\">\n  <div class=\"p-col-fixed width-140\">\n    <p-checkbox value=\"val1\" label=\"Page\" binary=true [(ngModel)]=\"checkedPage\" (onChange)=\"validatePageCheck()\"\n      [disabled]=\"!checkBoxPage\" title={{hintPage}}></p-checkbox>\n  </div>\n  <div class=\"p-col\">\n    <p-dropdown appendTo=\"body\" styleClass=\"ns-url-dropdown\" [filter]=true [options]=\"pageOptions\"\n      [(ngModel)]=\"selectedPage\" [disabled]=\"!checkedPage\" placeholder=\"select\" (onChange)=\"validatePageCheck('change')\"\n      [style]=\"{'min-width':'100%'}\" [panelStyle]=\"{maxWidth:'245px'}\"></p-dropdown>\n  </div>\n  <div class=\"p-col-fixed\" *ngIf=\"showPagePagination\">\n    <span class=\"las-arrow-left-solid\" title=\"Previous BT\" *ngIf=\"true\" (click)=\"previous()\"></span>\n    <span class=\"las-arrow-right-solid\" title=\"Next (1000 or lesser BTs)\" *ngIf=\"true\" (click)=\"next()\"></span>\n  </div>\n  <div class=\"p-col-12\" *ngIf=\"showPagePagination\">\n    <span class=\"las-arrow-left-solid\" title=\"Previous BT\" *ngIf=\"true\" (click)=\"previous()\"></span>\n    <span class=\"las-arrow-right-solid\" title=\"Next (1000 or lesser BTs)\" *ngIf=\"true\" (click)=\"next()\"></span>\n  </div>\n  <div class=\"p-col-12 text-danger\" *ngIf='selectPageCheckBoxFlag'>{{showCheckBoxErrorMessage}}</div>\n</div>\n\n         \n<div class='p-nogutter1 p-grid p-align-center'\n  *ngIf=\"(this.checkedBuisnessTransaction == false || this.commonServices.currentReport == 'Exception')\">\n  <div class=\"p-col-fixed width-140\">\n    <p-checkbox value=\"val1\" label=\"URL\" binary=true [(ngModel)]=\"checkedUrl\" (onChange)=\"validateUrlCheck()\"\n      [disabled]=\"!checkBoxUrl\" title={{hintUrl}}></p-checkbox>\n    <span *ngIf=\"URLInfoLoading\" class=\"icons8 icons8-spinner spin\"></span>\n  </div>\n\n  <div class=\"p-col\"\n    *ngIf=\"(this.checkedBuisnessTransaction == false || this.commonServices.currentReport == 'Exception') \">\n    <p-dropdown appendTo=\"body\" [filter]=true [options]=\"urlOptions\" [(ngModel)]=\"selectedUrl\" (onChange)=\"checkInfo()\"\n      [disabled]=\"!checkedUrl\" placeholder=\"select\" [style]=\"{'min-width':'100%'}\"\n      [panelStyle]=\"{maxWidth:'245px'}\"></p-dropdown>\n  </div>\n</div>\n\n<div class='p-nogutter1 p-grid p-align-center'>\n  <div class=\"p-col-12\" *ngIf=\"showUrlPagination\">\n    <span class=\"las-arrow-left-solid\" title=\"Previous Url\" (click)=\"previousFilter('url')\" *ngIf=nxtUrl></span>\n    ( {{this.urlOffset + 1}} - {{this.urlEndValue}} of {{this.urlFilterCount}} )\n    <span class=\"las-arrow-right-solid\" title=\"Next (100 or lesser Url)\" (click)=\"nextFilterData('url')\"\n      *ngIf=prevUrl></span>\n  </div>\n  <div class=\"p-col-12 text-danger\" *ngIf='selectUrlCheckBoxFlag'>{{showCheckBoxErrorMessage}}</div>\n</div>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n\n    <!-- ************************Other NS Filters ***************** -->\n    \n    <div *ngIf=\"this.showLAB && this.showNSFilter && this.commonServices.currentReport != 'Hotspot' && this.commonServices.currentReport != 'Exception'\"  class=\"w-100-p\">\n      <p-accordion>\n        <p-accordionTab header=\"User Filters\" [selected]=\"true\">\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"Location \" binary=true [(ngModel)]=\"checkedLocation\" (onChange)=\"fetchMetadata('location')\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown [filter]=true [options]=\"locationOptions\"  [(ngModel)]=\"selectedLocation\" [style]=\"{'width':'125px'}\" [disabled]=\"!checkedLocation\"\n                placeholder=\"select\"></p-dropdown>\n            </div>\n          </div>\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"Browser\" binary=true [(ngModel)]=\"checkedBrowser\" (onChange)=\"fetchMetadata('browser')\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown [filter]=true [options]=\"browserOptions\"  [(ngModel)]=\"selectedBrowser\" [style]=\"{'width':'125px'}\" [disabled]=\"!checkedBrowser\"\n                placeholder=\"select\"></p-dropdown>\n            </div>\n          </div>\n          <div class=\"p-grid p-align-center p-nogutter1\">\n            <div class=\"p-col-fixed width-140\">\n              <p-checkbox value=\"val1\" label=\"Access\" binary=true [(ngModel)]=\"checkedAccess\" (onChange)=\"fetchMetadata('access')\"></p-checkbox>\n            </div>\n            <div class=\"p-col\">\n              <p-dropdown [filter]=true [options]=\"accessOptions\"  [(ngModel)]=\"selectedAccess\" [style]=\"{'width':'125px'}\" [disabled]=\"!checkedAccess\"\n                placeholder=\"select\"></p-dropdown>\n            </div>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n  </div>\n</div>\n    <div class=\"p-col-12 text-right\">\n      <button pButton type=\"button\" label=\"Apply\" (click)=\"onApply()\" class=\"mx-3\"></button>\n      <button pButton type=\"button\" label=\"Reset\" (click)=\"Reset()\" class=\"btn-secondary-outline\"></button>\n    </div>\n</div>\n  </as-split-area>\n<as-split-area [size]=\"75\" (click)=\"Reset()\">\n</as-split-area>\n</as-split>\n\n\n<p-dialog header=\"Exception Filters Message \" [(visible)]=\"exceptionPopup\" [style]=\"{'width':'200px'}\">\n  <div>Can not apply exception filters which are applied in group By options at same time.\n    You either have to uncheck in group by filters OR uncheck the exception filters . \n  </div> \n<p-footer class=\"p-grid p-justify-end\">\n<button type=\"button\" pButton class=\"ui-button-secondary\" label=\"Close\" (click)=\"exceptionPopup=false\"></button>\n</p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.html":
/*!***********************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.html ***!
  \***********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<aside id=\"left-panel\" (mouseenter)=\"changeStyle($event)\" (mouseleave)=\"changeStyle($event)\"\n  [class.hidden-menu]=\"hide == true\" [class.show-menu]=\"hide == false\">\n  <nav>\n    <div class=\"scrollSideView\">\n      <ng-container *ngIf=\"!otelMode\">\n        <div class=\"ddr-side-view-div\" *ngFor=\"let val of flowpathData; let i = index\" (click)=\"rowClick(val)\"\n          [class.ddr-active-flowpath]=\"selectedData.flowpathInstance == flowpathData[i].flowpathInstance\">\n          <div class=\"sideLine\" pTooltip=\"BT Type: {{val.btCatagory}}\"\n            [style.background-color]=\"val.btCatagory == 'Very Slow' ? '#f8c136' : val.btCatagory == 'Slow' ? '#f0f514' : val.btCatagory == 'Normal' ? '#35ff05' : '#ff0000'\">\n          </div>\n\n          <div class=\"column\">\n            <div class=\"childflex\">\n              <label pTooltip=\"BT Name: {{val.urlName}}\" class=\"w-40-p elipseText pr-10\">\n                {{formatter(val.urlName)}}\n              </label>\n              <label class=\"w-40-p elipseText pr-10\"\n                pTooltip=\"Start Time: {{ sessionService.convertTimestampIntoFormattedString(ConverIntoNumber(val.startTimeInMs)) }}\">\n                {{sessionService.convertTimestampIntoFormattedString(ConverIntoNumber(val.startTimeInMs))}}\n              </label>\n              <label class=\"w-20-p elipseText pr-10\"\n                pTooltip=\"Response Time: {{val.selfResponseTime}}ms.&#10;CPU Time: {{val.btCpuTime}}ms.&#10;Wait Time: {{val.waitTime}}ms.&#10;Sync Time: {{val.syncTime}}ms.&#10;IO Time: {{val.iotime}}ms.&#10;Suspension Time: {{val.suspensiontime}}ms.\">\n                {{val.selfResponseTime}}\n              </label>\n            </div>\n\n            <div class=\"childflex\">\n              <label class=\"w-40-p elipseText pr-10\" pTooltip=\"Tier: {{val.tierName}}\">\n                {{formatterTSA(val.tierName)}}\n              </label>\n              <label class=\"w-40-p elipseText pr-10\" pTooltip=\"Server: {{val.serverName}}\">\n                {{formatterTSA(val.serverName)}}\n              </label>\n              <label class=\"w-20-p elipseText pr-10\" pTooltip=\"Instance: {{val.appName}}\">\n                {{formatterTSA(val.appName)}}\n              </label>\n            </div>\n\n            <div class=\"childflex\">\n              <ng-container *ngIf=\"val.methodsCount && val.methodsCount != 0\">\n                <div class=\"w-40-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-globe btn-icon mr-3\" pTooltip=\"Method Count(s): {{val.methodsCount}}\"></i>\n                  <span>\n                    {{val.methodsCount}}\n                  </span>\n                </div>\n              </ng-container>\n\n              <ng-container *ngIf=\"val.callOutCount && val.callOutCount != 0\">\n                <div class=\"w-40-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-incoming-call btn-icon mr-3\" pTooltip=\"CallOut(s): {{val.callOutCount}}\"></i>\n                  <span>\n                    {{val.callOutCount}}\n                  </span>\n                </div>\n              </ng-container>\n\n              <ng-container *ngIf=\"val.coherenceCallOut && val.coherenceCallOut != 0\">\n                <div class=\"w-20-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-copyright btn-icon mr-3\"\n                    pTooltip=\"Coherence CallOut(s): {{val.coherenceCallOut}}\"></i>\n                  <span>\n                    {{val.coherenceCallOut}}\n                  </span>\n                </div>\n              </ng-container>\n\n              <ng-container *ngIf=\"val.jmsCallOut && val.jmsCallOut != 0\">\n                <div class=\"w-20-p elipseText pr-10\">\n                  <img src='./assets/images/jmsImg.png' style=\"height:16px\"\n                    pTooltip=\"JMS CallOut(s): {{val.jmsCallOut}}\" />\n                  <span>\n                    {{val.jmsCallOut}}\n                  </span>\n                </div>\n              </ng-container>\n              <ng-container *ngIf=\"val.dbCallCounts && val.dbCallCounts != 0\">\n                <div class=\"w-20-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-database btn-icon mr-3\" pTooltip=\"Total Queries: {{val.dbCallCounts}}\"></i>\n                  <span>\n                    {{val.dbCallCounts}}\n                  </span>\n                </div>\n              </ng-container>\n\n              <ng-container *ngIf=\"val.totalError && val.totalError != 0\">\n                <div class=\"w-40-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-error btn-icon mr-3\" *ngIf=\"val.totalError != 0\"\n                    pTooltip=\"Exception(s): {{val.totalError}}\"></i>\n                  <span>\n                    {{val.totalError}}\n                  </span>\n                </div>\n              </ng-container>\n              <ng-container *ngIf=\"val.flowpathtype && val.flowpathtype >=32\">\n                <div class=\"w-20-p elipseText pr-10\">\n                  <i class=\"las-font-awesome-flag btn-icon mr-3\" pTooltip=\"Flagged Flowpath\"></i>\n                  <span></span>\n                </div>\n              </ng-container>\n\n              <ng-container>\n                <div class=\"w-60-p elipseText pr-10 p-grid p-align-center\"\n                  pTooltip=\"Flowpath Instance: {{val.flowpathInstance}}\">\n                  <i class=\"icons8 icons8-shuffle btn-icon mr-3\"></i>\n                  <span>\n                    {{val.flowpathInstance}}\n                  </span>\n                </div>\n              </ng-container>\n            </div>\n          </div>\n\n          <div class=\"label\">\n            <label pTooltip=\"Status Code: {{val.statusCode}}\"\n              [style.color]=\"val.statusCode >= 200 && val.statusCode < 300 ? '#3c9227' : val.statusCode >= 300 && val.statusCode < 400 ? '#f8c136' : val.statusCode >= 400  ? '#ff0505' : 'black'\">\n              {{val.statusCode}}\n            </label>\n            <div class=\"statusIcons\">\n              <span *ngIf=\"(val.traceRequest == '1')\">\n                <i class='cav http-data' title=\"Trace Request\" style=\"font-size: 16px;cursor:pointer;\"></i>\n              </span>\n              <span *ngIf=\"(val.traceRequest == '2')\">\n                <img src=\"./assets/images/dl.png\" title='Dynamic Logging'\n                  style=\"width:16px;height:16px;cursor:pointer;\" />\n              </span>\n              <span *ngIf=\"(val.traceRequest == '3')\">\n                <i class='cav http-data' title=\"Trace Request\" style=\"font-size: 16px;cursor:pointer;\"></i>\n                <img src=\"./assets/images/dl.png\" title='Dynamic Logging'\n                  style=\"width:16px;height:16px;cursor:pointer;\" />\n              </span>\n              <span *ngIf=\"(val.traceRequest == '4')\">\n                <i class='cav nethavok' title=\"Havoc\" style=\"font-size: 16px;cursor:pointer;\"></i>\n              </span>\n              <span *ngIf=\"(val.traceRequest == '5')\">\n                <i class='cav http-data' title=\"Trace Request\" style=\"font-size: 16px;cursor:pointer;\"></i>\n                <i class='cav nethavok' title=\"Havoc\" style=\"font-size: 16px;cursor:pointer;\"></i>\n              </span>\n              <span *ngIf=\"(val.traceRequest == '6')\">\n                <img src=\"./assets/images/dl.png\" title='Dynamic Logging'\n                  style=\"width:16px;height:16px;cursor:pointer;\" />\n                <i class='cav nethavok' title=\"Havoc\" style=\"font-size: 16px;cursor:pointer;\"></i>\n              </span>\n              <span *ngIf=\"(val.traceRequest == '7')\">\n                <i class='cav http-data' title=\"Trace Request\" style=\"font-size: 16px;cursor:pointer;\"></i>\n                <img src=\"./assets/images/dl.png\" title='Dynamic Logging'\n                  style=\"width:16px;height:16px;cursor:pointer;\" />\n                <i class='cav nethavok' title=\"Havoc\" style=\"margin-right :10px;font-size: 16px;cursor:pointer;\"></i>\n              </span>\n            </div>\n          </div>\n        </div>\n      </ng-container>\n      <ng-container *ngIf=\"otelMode\">\n        <div class=\"ddr-side-view-div\" *ngFor=\"let val of flowpathData; let i = index\" (click)=\"rowClick(val)\"\n          [class.ddr-active-flowpath]=\"selectedData.TraceId == flowpathData[i].TraceId\">\n\n          <div class=\"column\">\n            <div class=\"childflex\">\n              <label pTooltip=\"BT Name: {{val.urlName}}\" class=\"w-40-p elipseText pr-10\">\n                {{formatter(val.urlName)}}\n              </label>\n              <label class=\"w-40-p elipseText pr-10\"\n                pTooltip=\"Start Time: {{ sessionService.convertTimestampIntoFormattedString(ConverIntoNumber(val.startTimeInMs)) }}\">\n                {{sessionService.convertTimestampIntoFormattedString(ConverIntoNumber(val.startTimeInMs))}}\n              </label>\n              <label class=\"w-20-p elipseText pr-10\" pTooltip=\"Response Time: {{val.selfResponseTime.toFixed(3)}}ms.\">\n                {{val.selfResponseTime.toFixed(3)}}\n              </label>\n            </div>\n\n            <div class=\"childflex\">\n              <label class=\"w-40-p elipseText pr-10\" pTooltip=\"Tier: {{val.tierName}}\">\n                {{formatterTSA(val.tierName)}}\n              </label>\n              <label class=\"w-40-p elipseText pr-10\" pTooltip=\"Server: {{val.serverName}}\">\n                {{formatterTSA(val.serverName)}}\n              </label>\n              <label class=\"w-20-p elipseText pr-10\" pTooltip=\"Instance: {{val.appName}}\">\n                {{formatterTSA(val.appName)}}\n              </label>\n            </div>\n\n            <div class=\"childflex\">\n              <ng-container *ngIf=\"val.methodsCount && val.methodsCount != 0\">\n                <div class=\"w-40-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-globe btn-icon mr-3\" pTooltip=\"Method Count(s): {{val.methodsCount}}\"></i>\n                  <span>\n                    {{val.methodsCount}}\n                  </span>\n                </div>\n              </ng-container>\n\n              <ng-container *ngIf=\"val.callOutCount && val.callOutCount != 0\">\n                <div class=\"w-40-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-incoming-call btn-icon mr-3\" pTooltip=\"CallOut(s): {{val.callOutCount}}\"></i>\n                  <span>\n                    {{val.callOutCount}}\n                  </span>\n                </div>\n              </ng-container>\n\n              <ng-container *ngIf=\"val.coherenceCallOut && val.coherenceCallOut != 0\">\n                <div class=\"w-20-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-copyright btn-icon mr-3\"\n                    pTooltip=\"Coherence CallOut(s): {{val.coherenceCallOut}}\"></i>\n                  <span>\n                    {{val.coherenceCallOut}}\n                  </span>\n                </div>\n              </ng-container>\n\n              <ng-container *ngIf=\"val.jmsCallOut && val.jmsCallOut != 0\">\n                <div class=\"w-20-p elipseText pr-10\">\n                  <img src='./assets/images/jmsImg.png' style=\"height:16px\"\n                    pTooltip=\"JMS CallOut(s): {{val.jmsCallOut}}\" />\n                  <span>\n                    {{val.jmsCallOut}}\n                  </span>\n                </div>\n              </ng-container>\n              <ng-container *ngIf=\"val.dbCallCounts && val.dbCallCounts != 0\">\n                <div class=\"w-20-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-database btn-icon mr-3\" pTooltip=\"Total Queries: {{val.dbCallCounts}}\"></i>\n                  <span>\n                    {{val.dbCallCounts}}\n                  </span>\n                </div>\n              </ng-container>\n\n              <ng-container *ngIf=\"val.totalError && val.totalError != 0\">\n                <div class=\"w-40-p elipseText pr-10\">\n                  <i class=\"icons8 icons8-error btn-icon mr-3\" *ngIf=\"val.totalError != 0\"\n                    pTooltip=\"Exception(s): {{val.totalError}}\"></i>\n                  <span>\n                    {{val.totalError}}\n                  </span>\n                </div>\n              </ng-container>\n              <ng-container *ngIf=\"val.flowpathtype && val.flowpathtype >=32\">\n                <div class=\"w-20-p elipseText pr-10\">\n                  <i class=\"las-font-awesome-flag btn-icon mr-3\" pTooltip=\"Flagged Flowpath\"></i>\n                  <span></span>\n                </div>\n              </ng-container>\n\n              <ng-container>\n                <div class=\"w-60-p elipseText pr-10 p-grid p-align-center\" pTooltip=\"Trace Id: {{val.TraceId}}\">\n                  <i class=\"icons8 icons8-shuffle btn-icon mr-3\"></i>\n                  <span>\n                    {{val.TraceId}}\n                  </span>\n                </div>\n              </ng-container>\n            </div>\n          </div>\n\n          <div class=\"label\">\n            <label pTooltip=\"Status Code: {{val.statusCode}}\"\n              [style.color]=\"val.statusCode >= 200 && val.statusCode < 300 ? '#3c9227' : val.statusCode >= 300 && val.statusCode < 400 ? '#f8c136' : val.statusCode >= 400  ? '#ff0505' : 'black'\">\n              {{val.statusCode}}\n            </label>\n          </div>\n        </div>\n      </ng-container>\n    </div>\n  </nav>\n</aside>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.html":
/*!*************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.html ***!
  \*************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"ddr-toolbar\">\n  <button pButton (click)=\"showHide()\" class=\"btn-icon\" title=\"{{buttonValueTootip}}\" >\n    <i class=\"{{buttonValue}}\" ></i>\n  </button>\n\n  <button pButton *ngIf=\"sortButtonHide\" class=\"btn-icon\" (click)=\"openPopUp()\" title=\"Sort\"\n    icon=\"icons8 icons8-up-down-arrow\"></button>\n</div>\n    <div class=\"p-grid  w-100-p\">\n      <div *ngIf=\"sideViewToggler\" class=\"p-col-3 ddr-side-view-bg\" >\n        <app-ddr-side-view [selectedData]=\"commonService.currentRowData\" [index]=\"commonService.index\"\n          [order]=\"commonService.order\" [sortField]=\"commonService.sortField\" [flowpathData]=\"commonService.flowpathData\"\n          (flowpathSelected)=\"selectedRowData($event)\"></app-ddr-side-view>\n      </div>\n      <div [ngClass]=\" sideViewToggler ? 'p-col-9': 'p-col-12' \"  style=\"padding:0;\">\n        <app-ddr-details-view [column]=\"commonService.column\" (indexValue)=\"setIndex($event)\"\n         [flowpathData]=\"commonService.currentRowData\"></app-ddr-details-view>\n      </div>\n    </div>\n\n  <p-dialog class=\"secondary-dialog\" [style]=\"{width: '40vw', height: '50vh'}\" header=\"Sort\" [(visible)]=\"openSortPopUp\" modal=\"modal\" [resizable]='false'\n  [responsive]=\"true\">\n\n  <div *ngIf=\"openSortPopUp\">\n    <ng-container *ngFor=\"let val of sortOptions\">\n      <span class=\"ui-g-6\">\n        <p-radioButton value={{val.value}} name=\"group1\" label={{val.label}} [(ngModel)]=\"commonService.sortField\">\n        </p-radioButton>\n        <ng-container *ngIf=\"sortFieldName == val.value && sortingOrder == 'desc'\">\n          <i class=\"fa fa-sort-desc\" aria-hidden=\"true\"></i>\n        </ng-container>\n        <ng-container *ngIf=\"sortFieldName == val.value && sortingOrder == 'asc'\">\n          <i class=\"fa fa-sort-asc\" aria-hidden=\"true\"></i>\n        </ng-container>\n      </span>\n    </ng-container>\n  </div>\n  <p-footer>\n    <div class=\"p-grid p-align-center p-justify-center py-5\">\n    <button pButton type=\"button\" label=\"Ascending\" (click)=\"commonService.order='1';sortingOrder='asc';openSortPopUp=false\" class=\"ui-button-rounded ui-button-secondary\"></button>\n    <button pButton type=\"button\" label=\"Descending\" (click)=\"commonService.order='-1';sortingOrder='desc';openSortPopUp=false\" class=\"ui-button-rounded ui-button-secondary\"></button>\n    <button pButton type=\"button\" label=\"Close\" (click)=\"openSortPopUp=false;commonService.order='';sortingOrder=''\" class=\"ui-button-rounded ui-button-secondary\"></button>\n  </div>\n  </p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.html":
/*!***********************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.html ***!
  \***********************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"ddr-box\">\n    <div id=\"flowmap-box\" class=\"flowmap-box\">\n        <p-toolbar class=\"ui-primary-toolbar\" styleClass=\"p-8\">\n            <div class=\"font-weight-600\">Aggregate Transaction Flowmap</div>\n        </p-toolbar>\n        <div>\n\t<div class=\"p-grid p-align-center p-8 border-all border-5\">\n            <span id='filterTier'></span>\n      </div>\n        </div>\n        <div class=\"ddrk-jtk-demo-canvas canvas-wide flowchart-demo ddr-jtk-surface jtk-surface-nopan\" style=\"position: relative\" id=\"canvas\">\n            <span class=\"screen\">\n            <span style='float:right' *ngIf='aggFlowmapService.rootFpMiss'>\n                   <img src='./assets/images/warning.png' height='18' style=\"cursor: pointer;margin-right:7px\"  (click)='showWarningMessgae()'/>\n                 </span></span>\n            <div class=\"window node\" [ngStyle]=\"{'top':'110px','left':'2pxpx','background':'#bdef84', 'padding':' 15px 0 0 2px','margin-left':'4px'}\" id=\"root\">\n                <strong>Entry</strong>\n                <br/>\n                <br/>\n            </div>\n            <div *ngFor=\"let col of dataToDraw,let i = index\">\n\n                <div *ngIf=\"col.ovalClass\" id='{{col.id}}' #nodediv [ngClass]=\"{'tierNode': col.tierClass, 'window': true, 'oval': col.ovalClass}\"\n                    [ngStyle]=\"{'top': col.top, 'left': col.left }\"(mouseover)=\"ShowtooltiponHover(col)\"\n                    (mouseleave)=\"removeTooltip(col)\" title=\"{{tooltipForNodes}}\">\n\n\n                    <a><img src=\"./assets/images/{{col.icon}}\" class=\"nodeImage\"><span  [ngStyle]=\"{'margin-top': '25px' }\"></span></a>\n                    <div class='nodeRight'>\n                        <div class='nodeHeading'>{{trimTextForLarge(col.displayName)}} </div>\n                        <div class=\"nodeBottom\"></div>\n                      </div>\n\n                </div>\n                <div *ngIf=\"col.tierClass\" id='{{col.id}}' #nodediv [ngClass]=\"{'tierNode': col.tierClass, 'window': true, 'oval': col.ovalClass}\"\n                    [ngStyle]=\"{'top': col.top, 'left': col.left }\"(mouseover)=\"ShowtooltiponHover(col)\"\n                    (mouseleave)=\"removeTooltip(col)\"  (mousedown)=\"getNodeDataforRouting($event,col)\"  title=\"{{tooltipForNodes}}\">\n\n\n                    <a><img src=\"./assets/images/{{col.icon}}\" class=\"tierimage\"><span  [ngStyle]=\"{'margin-top': '25px' }\"></span></a>\n                    <div class=\"tierName\" >{{trimTextForLarge(col.tN)}}</div>\n\n                </div>\n            </div>\n            <p-contextMenu id='contextmenu' #contextRef  [style]=\"{'width':'188px', 'position': 'absolute'}\"   [model]=\"mainContextMenu\"></p-contextMenu>\n        </div>\n    </div>\n</div>\n<canvas id=\"canvasforDownload\" style=\"background-color: white; display:none;\" width=\"1400\" height=\"1040\"> </canvas>\n<a id='trans' style='display:none;'></a>\n<p-dialog class=\"scenmodal  Ddr-popup-footer\" [(visible)]=\"waningPopup\" [responsive]='true' [resizable]='false'\n    [positionTop]='150' width=\"350\" [style]=\"{'height':'100px'}\">\n    <p-header> <img src='./assets/images/warning.png' style=\"cursor: pointer;height:18px\"\n            (click)='showWarningMessgae()' /> <span style='font-size: 14px'> Warning</span></p-header>\n    <b><span style='font-size: 13px'> - One or more root flowpaths are not captured.</span></b>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.html":
/*!*******************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.html ***!
  \*******************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"ddr-box\">\n  <div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"CommonServices.loaderForDdr\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n  </div>\n    <!-- COMMON TOOLBAR -->\n        <div class=\"ddr-toolbar\">\n   <!-- <p-toolbar>\n        <div class=\"reportInfo\">\n            <label class=\"headerInfo\"><b>{{strTitle}}</b></label>\n          </div>\n      </p-toolbar>-->\n      <div class=\"p-grid p-justify-between p-align-center ui-table-header\">\n  <div>\n         <!-- <label ><b>Filter criteria : </b></label>-->\n          <div id='forFilter' class='for-filter'></div>\n  </div>\n  <div>\n      <!-- fa fa-search-plus (removed)-->\n      <!-- <button type=\"button\" pButton icon=\"icons8 icons8-zoom-in font-18 mr-2\" (click)=\"openAutoInstDialog()\"title=\"Click to start Dynamic Diagnostics\"></button>\n      <button pButton type=\"button\" *ngIf='showSelfLoop'  title='View Expanded mode' icon='fa fa-arrows-alt'  style ='height:16px;width:16px;' (click)='showTransactionData()'></button>\n      <button pButton type=\"button\" *ngIf='!showSelfLoop' title='View ThreadMerge mode' icon='fa fa-compress'  style ='height:16px;width:16px;' (click)='showTransactionData()'></button> -->\n      <button pButton icon=\"icons8 icons8-zoom-in\" tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)=\"openAutoInstDialog()\"\n      pTooltip=\"Click to start Dynamic Diagnostics\"></button>\n      <button pButton icon=\"icon='icons8 icons8-expand mtn-11 font-16\" *ngIf='showSelfLoop' tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)='showTransactionData()'\n      pTooltip=\"View Expanded mode\"></button>\n      <button pButton icon=\"icons8 icons8-compress\" *ngIf='!showSelfLoop' tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)='showTransactionData()'\n      pTooltip=\"View ThreadMerge mode\"></button>\n     <!-- <span  [style]=\"{'margin-left':'88%'}\">\n        <img src='images/SequenceIcon.png' style=\"cursor: pointer\" title='View Flowpath Details' (click)=\"isFromMain = true;openMethodCallingTree(dataOfFlowpathROw)\"/>\n      </span>\n      <span [style]=\"{'margin-left':'89%'}\">\n        <img src='images/MethodTiming.png' style=\"cursor: pointer\" title='View Method Timing Report' (click)=\"isFromMain = true;openMethodTimingReport(dataOfFlowpathROw)\"/>\n      </span>\n      <span [style]=\"{'margin-left':'90%'}\">\n        <img src='images/hotspot.png' style=\"cursor: pointer\" title='View HotSpot Report' (click)=\"isFromMain = true;openHotspotReport(dataOfFlowpathROw)\"/>\n      </span>\n      <span  [style]=\"{'margin-left':'91%'}\">\n        <img src='images/queryIcon.png' style=\"cursor: pointer\" title='View DB Request Report' (click)=\"isFromMain = true;openDBReports(dataOfFlowpathROw)\"/>\n      </span> -->\n  </div>\n </div>\n </div>\n <div class=\"flowmap-box\" id=\"flowmap-box\">\n  <div *ngIf=\"!showSelfLoop\">\n    <div class=\"ddrt-jtk-demo-canvas canvas-wide flowchart-demo ddrt-jtk-surface jtk-surface-nopan\" style=\"position: relative\" id=\"canvas\">\n <span style=\"width:100%;float:right;\">\n <!-- <button pButton type=\"button\" id='dwnldbtn1'  icon=\"icons8 icons8-download-2 mr-3\" style='float:right;height:18px;width:18px;margin-left:2px;margin-top:2px' title=\"Download with node information\"  (click)=\"downloadReport('directDownload','')\"></button>\n   <button pButton type=\"button\"  id='dwnldbtn2' icon=\"icons8 icons8-download-2 mr-3\" style='float:right;height:18px;width:18px;margin-top:2px' title=\"Download without node information\"  (click)=\"downloadReport('directDownload','lessDetail')\"></button> -->\n   <i class=\"icons8 icons8-download font-17 mr-3\"  id='dwnldbtn1' style='float:right;height:18px;width:18px;margin-left:2px;margin-top:1px; color:#154771;' title=\"Download with node information\"  (click)=\"downloadReport('directDownload','')\"></i>\n  <i class=\"icons8 icons8-download-2 mr-3\"  id='dwnldbtn2' style='float:right;height:18px;width:18px;margin-top:2px; color:#154771' title=\"Download without node information\"  (click)=\"downloadReport('directDownload','lessDetail')\"></i>\n   <span *ngIf='flowmapData.isRootFpMissing'  style='float:right;margin-right:2px' ><span style='font-weight:500'>View Actual Flowmap : </span>  <p-inputSwitch onLabel=\"Yes\" [style]=\"{'top':'4px'}\" offLabel=\"No\" [(ngModel)]=\"flowmapData.showOrigFlowmap\"  (onChange)=\"handleChange($event)\"></p-inputSwitch></span>\n <span style='float:right' *ngIf='flowmapData.isFPMissCase  || flowmapData.isRootFpMissing'>\n        <img src='./assets/images/warning.png' height='18' style=\"cursor: pointer; margin-right:6px\"  (click)='showWarningMessgae()'/>\n      </span>\n    </span>\n\n    \n<div class=\"window node\" [ngStyle]=\"{'top':'110px','background':'#bdef84', 'padding':' 15px 0 0 2px','margin-left':'4px'}\" id=\"root\"><strong>Entry</strong><br/><br/></div>\n      <div *ngFor=\"let col of dataToDraw,let i = index\">\n        <!-- <p-contextMenu id='contextmenu' #contextRef  *ngIf=\"(col.instanceType == 'java'||col.instanceType == 'dotNet'||col.instanceType == 'NodeJS') && (col?.exceptionCount == 0 || col?.exceptionCount == undefined)\" [style]=\"{'width':'147px', 'position': 'fixed'}\"  [target]=\"nodediv\" [model]=\"ContextMenuItems\"></p-contextMenu>        -->\n        <!-- <p-contextMenu id='contextmenu' #contextRef  *ngIf=\"(col.instanceType == 'java'||col.instanceType == 'dotNet'||col.instanceType == 'NodeJS') && (col?.exceptionCount > 0)\" [style]=\"{'width':'147px', 'position': 'fixed'}\"  [target]=\"nodediv\" [model]=\"ContextMenuItemsForExceeption\" ></p-contextMenu>        -->\n        <div id='{{col.id}}' #nodediv  class='node window' [ngStyle]=\"{'top': col.top + 40+'px', 'left': col.left + 'px'}\" (mouseover)=\"ShowtooltiponHover(col)\"\n          (mouseleave)=\"removeTooltip(col)\" (dblclick)=\"showDialogTable(col)\" (mousedown)=\"getNodeDataforRouting($event,col)\">\n          <!--<div class=\"tooltipfornodes\"><strong><img (mouseover)=\"Showtooltip(col)\" (mouseleave)=\"removeTooltip(col)\" src=\"src/images/{{col.icon}}\"></strong>\n     <div [innerHTML]=\"tooltipForNodes\" class=\"tooltiptextfornodes\"></div>\n      </div>-->\n          <a class='tooltips'><img src='./assets/images/{{col.icon}}' class=\"nodeImage\"  style='padding: 4px;'><span  [ngStyle]=\"{'margin-top': '25px' }\"> <div [innerHTML]=\"tooltipForNodes\"></div></span></a>\n          <div class='nodeRight'>\n           <div class='nodeHeading' *ngIf=\"col.tierName == '-'\">{{trimTextForLarge(col.mappedAppName)}} </div>\n           <div class='nodeHeading' *ngIf=\"col.tierName != '-'\"> {{col.serverName}} : {{col.mappedAppName}}</div>\n           <div class=\"nodeBottom\"></div>\n          </div>\n        </div>\n      </div>\n    </div>\n  </div> \n\n <p-contextMenu id='contextmenu' #contextRef  [style]=\"{'width':'147px', 'position': 'absolute'}\"   [model]=\"mainContextMenu\"></p-contextMenu>       \n<div *ngIf=\"reCreateDiv\">\n  <div *ngIf=\"showSelfLoop\">\n    <div class=\"ddrt-jtk-demo-canvas canvas-wide flowchart-demo ddrt-jtk-surface jtk-surface-nopan\" style=\"position: relative\" id=\"canvas\">\n <span style=\"width:100%;float:right;\">\n <!-- <button pButton type=\"button\" id='dwnldbtn1'  icon=\"icons8 icons8-download-2 mr-3\" style='float:right;height:18px;width:18px;margin-left:2px;margin-top:2px' title=\"Download with node information\"  (click)=\"downloadReport('directDownload','')\"></button>\n   <button pButton type=\"button\"  id='dwnldbtn2' icon=\"icons8 icons8-download-2 mr-3\" style='float:right;height:18px;width:18px;margin-top:2px' title=\"Download without node information\"  (click)=\"downloadReport('directDownload','lessDetail')\"></button> -->\n  <i class=\"icons8 icons8-download font-17 mr-3\"  id='dwnldbtn1' style='float:right;height:18px;width:18px;margin-left:2px;margin-top:1px; color:#154771;' title=\"Download with node information\"  (click)=\"downloadReport('directDownload','')\"></i>\n  <i class=\"icons8 icons8-download-2 mr-3\"  id='dwnldbtn2' style='float:right;height:18px;width:18px;margin-top:2px; color:#154771' title=\"Download without node information\"  (click)=\"downloadReport('directDownload','lessDetail')\"></i>\n   <span *ngIf='flowmapData.isRootFpMissing'  style='float:right;margin-right:2px' ><span style='font-weight:500'>View Actual Flowmap : </span>  <p-inputSwitch onLabel=\"Yes\" [style]=\"{'top':'4px'}\" offLabel=\"No\" [(ngModel)]=\"flowmapData.showOrigFlowmap\"  (onChange)=\"handleChange($event)\"></p-inputSwitch></span>\n <span style='float:right' *ngIf='flowmapData.isFPMissCase  || flowmapData.isRootFpMissing'>\n        <img src='./assets/images/warning.png' height='18' style=\"cursor: pointer; margin-right:6px\"  (click)='showWarningMessgae()'/>\n      </span></span>\n      <div class=\"window node\" [ngStyle]=\"{'top':'110px','background':'#bdef84', 'padding':' 15px 0 0 2px','margin-left':'4px'}\" id=\"root\"><strong>Entry</strong><br/><br/></div>\n      <div *ngFor=\"let col of selfLoppedDataToDrawToView,let i = index\">\n        <!-- <p-contextMenu id='contextmenu' #contextRef *ngIf=\"(col.instanceType == 'java'||col.instanceType == 'dotNet'||col.instanceType == 'NodeJS') && (col?.exceptionCount == 0 || col?.exceptionCount == undefined)\" [style]=\"{'width':'150px', 'position': 'fixed'}\"  [target]=\"nodediv\" [model]=\"ContextMenuItems\"></p-contextMenu>        -->\n        <!-- <p-contextMenu id='contextmenu' #contextRef  *ngIf=\"(col.instanceType == 'java'||col.instanceType == 'dotNet'||col.instanceType == 'NodeJS') && (col?.exceptionCount > 0)\" [style]=\"{'width':'150px', 'position': 'fixed'}\"  [target]=\"nodediv\" [model]=\"ContextMenuItemsForExceeption\" ></p-contextMenu>        -->\n        <div id='{{col.id}}' #nodediv class='node window' [ngStyle]=\"{'top': col.top + 40+'px', 'left': col.left + 'px'}\" (mouseover)=\"ShowtooltiponHover(col)\"\n          (mouseleave)=\"removeTooltip(col)\" (dblclick)=\"showDialogTable(col)\" (mousedown)=\"getNodeDataforRouting($event,col)\">\n          <!--<div class=\"tooltipfornodes\"><strong><img (mouseover)=\"Showtooltip(col)\" (mouseleave)=\"removeTooltip(col)\" src=\"src/images/{{col.icon}}\"></strong>\n     <div [innerHTML]=\"tooltipForNodes\" class=\"tooltiptextfornodes\"></div>\n      </div>-->\n          <a class='tooltips'><img src='./assets/images/{{col.icon}}' class=\"nodeImage\"  style='padding: 4px;'><span  [ngStyle]=\"{'margin-top': '25px' }\"> <div [innerHTML]=\"tooltipForNodes\"></div></span></a>\n          <div class='nodeRight'>\n           <div class='nodeHeading' *ngIf=\"col.tierName == '-'\">{{trimTextForLarge(col.mappedAppName)}} </div>\n           <div class='nodeHeading' *ngIf=\"col.tierName != '-'\"> {{col.serverName}} : {{col.mappedAppName}}</div>\n           <div class=\"nodeBottom\"></div>\n          </div>\n        </div>\n      </div>\n    </div>\n  </div> \n</div>\n  \n\n</div>\n</div>\n\n \n\n\n\n  <p-dialog  class=\"secondary-dialog foterDialog\" [style]=\"{width: '96vw', 'max-height':'500px'}\"  [modal]=\"true\" [(visible)]=\"tableDialogDisplay\" [responsive]='true' [resizable]='false' [positionTop]='140' minHeight='200'>\n    <p-header>\n      {{popupTitle}}\n\n\n\n\n    </p-header>\n\n \n<div style=\"width:100%; height:22px; margin-top:-6px;\">\n <div class=\"ui-toolbar-group-right\">\n       <span  title=\"Download as Word Report\">\n           <!-- <i class = 'icon ddrui-icon-word'  style=' cursor:pointer' (click)='downloadReportForAgg(\"word\")' ></i> -->\n           <i class = 'icons8 icons8-doc font-18 mx-4'  style=' cursor:pointer' (click)='downloadReportForAgg(\"word\")' ></i>\n       </span>\n       <span  title=\"Download as Excel Report\">\n            <!-- <i class = 'icon ddrui-icon-excel'  style=' cursor:pointer' (click)='downloadReportForAgg(\"excel\")' ></i> -->\n            <i class = 'icons8 icons8-spreadsheet-file font-18 mx-4'  style=' cursor:pointer' (click)='downloadReportForAgg(\"excel\")' ></i>\n       </span>\n       <span title=\"Download as PDF Report\">\n          <!-- <i class = 'icon ddrui-icon-pdf'  style=' cursor:pointer' (click)='downloadReportForAgg(\"pdf\")' ></i> -->\n          <i class = 'icons8 icons8-pdf-2 font-18 mx-4'  style=' cursor:pointer' (click)='downloadReportForAgg(\"pdf\")' ></i>\n       </span>\n       </div>\n</div>\n\n    \n\n    <div>{{popupFilter}}</div>\n<div>\n\n  <p-table class=\"scen-table all-tables\" *ngIf=\"tableDialogDisplay\" scrollable='true' [resizableColumns]=\"true\" scrollHeight = '350px' [value]=\"transactionTableArray\" sortField={{sortField}} sortOrder=\"-1\">\n    <ng-template pTemplate=\"header\">\n      <tr>\n            <th pResizableColumn *ngFor=\"let col of col\" [style]=\"{'width': col.Width + 'px'}\">\n                {{col.header}}\n            </th>\n      </tr>\n    </ng-template>\n    <ng-template pTemplate=\"body\" let-rowData>\n      <tr>\n          <td *ngFor=\"let col of col\" [style]=\"{'width': col.Width + 'px','text-align':col.colAlignment}\">\n            <div *ngIf=\"(!col.action) && (col.field == 'URL' || col.field == 'Query')\" class=\"textWrap\"><span [title]=\"rowData[col.field]\" (click)=\"onRowClick($event, rowData)\">{{ rowData[col.field] }} </span></div>\n            <div *ngIf=\"col.action\">\n              <span  [style]=\"{'margin-right':'5px'}\">\n              <img src='/UnifiedDashboard/assets/images/SequenceIcon.png' style=\"cursor: pointer\" title='View Method call Details' (click)=\"isFromMain = false;openMethodCallingTree(rowData,false)\"/>\n              </span>\n              <span [style]=\"{'margin-right':'5px'}\">\n              <img src='/UnifiedDashboard/assets/images/MethodTiming.png' style=\"cursor: pointer\" title='View Method Timing Report' (click)=\"isFromMain = false;openMethodTimingReport(rowData)\"/>\n              </span>\n              <span [style]=\"{'margin-right':'5px'}\">\n              <img src='/UnifiedDashboard/assets/images/hotspot.png' style=\"cursor: pointer\" title='View HotSpot Report' (click)=\"isFromMain = false;openHotspotReport(rowData)\"/>\n              </span>\n              <span  [style]=\"{'margin-right':'5px'}\">\n              <img src='/UnifiedDashboard/assets/images/queryIcon1.png' style=\"cursor: pointer\" title='View DB Request Report' (click)=\"isFromMain = false;openDBReports(rowData)\"/>\n              </span>\n              <span  [style]=\"{'margin-right':'5px'}\">\n              <!-- <i class=\"icon-http-data\"  style=\"cursor: pointer; font-size: 16px\" title='View Request/Response Body' (click)=\"openReqRespData(rowData)\"></i> -->\n              <img src='/UnifiedDashboard/assets/images/view-response-body.png' style=\"cursor: pointer; width:16px;\" title='View Request/Response Body' (click)=\"openReqRespData(rowData)\">\n              </span>\n              <span [style]=\"{'margin-right':'5px'}\">\n                <img src='/UnifiedDashboard/assets/images/view-request-body.png' style=\"cursor: pointer;width:16px;\" title='View CallOut Body' (click)=\"openReqRespDataForCallOut(rowData)\">\n             </span>\n            </div>\n             <div *ngIf=\"(col.field == 'errorCount')\">\n              <span  *ngIf='rowData[col.field] != 0 ' style=\"color:blue;cursor: pointer ;\" title=\"View Exception Report\" (click)=\"openExceptionReport(rowData)\"> {{ rowData[col.field] }} </span>\n              <span  *ngIf='rowData[col.field]  == 0 '> {{ rowData[col.field] }} </span>\n             </div>\n             <div *ngIf=\"!(col.action || col.field == 'URL' || col.field == 'Query' || col.field == 'errorCount')\"><span>{{ rowData[col.field] }} </span></div>\n          </td>\n      </tr>\n    </ng-template>\n  </p-table>\n    <!-- <p-dataTable class=\"scen-table\" *ngIf=\"tableDialogDisplay\" (onRowClick)='onRowClick($event)' scrollable='true' scrollHeight = '350px' [value]=\"transactionTableArray\" sortField={{sortField}} sortOrder=\"-1\">\n       <p-column *ngFor=\"let col of col\"  [sortable]=\"col.sortable\" [sortable]=\"true\" (sortFunction)=\"sortColumnsOnCustom($event,transactionTableArray)\" [style]=\"{'width': col.Width + 'px','text-align':col.colAlignment}\" [field]='col.field'\n         [header]='col.header'>\n         <ng-template *ngIf=\"(!col.action) && (col.field == 'URL' || col.field == 'Query')\" let-col let-rowData=\"rowData\" pTemplate=\"body\">\n          <div class=\"textWrap\"><span [title]=\"rowData[col.field]\">{{ rowData[col.field] }} </span></div>\n         </ng-template>\n         <ng-template *ngIf=\"col.action\" let-col let-rowData=\"rowData\" pTemplate=\"body\">\n           <span  [style]=\"{'margin-right':'5px'}\">\n           <img src='images/SequenceIcon.png' style=\"cursor: pointer\" title='View Method call Details' (click)=\"isFromMain = false;openMethodCallingTree(rowData,false)\"/>\n           </span>\n           <span [style]=\"{'margin-right':'5px'}\">\n           <img src='images/MethodTiming.png' style=\"cursor: pointer\" title='View Method Timing Report' (click)=\"isFromMain = false;openMethodTimingReport(rowData)\"/>\n           </span>\n           <span [style]=\"{'margin-right':'5px'}\">\n           <img src='images/hotspot.png' style=\"cursor: pointer\" title='View HotSpot Report' (click)=\"isFromMain = false;openHotspotReport(rowData)\"/>\n           </span>\n           <span  [style]=\"{'margin-right':'5px'}\">\n           <img src='images/queryIcon.png' style=\"cursor: pointer\" title='View DB Request Report' (click)=\"isFromMain = false;openDBReports(rowData)\"/>\n           </span>\n           <span  [style]=\"{'margin-right':'5px'}\">\n           <i class=\"icon-http-data\"  style=\"cursor: pointer; font-size: 16px\" title='View Request/Response Body' (click)=\"openReqRespData(rowData)\"></i>\n           </span>\n           <span [style]=\"{'margin-right':'5px'}\">\n            <img src='images/HttpIcon.png' style=\"cursor: pointer; font-size: 16px\" title='View CallOut Body' (click)=\"openReqRespDataForCallOut(rowData)\">\n          </span>\n         </ng-template>\n         <ng-template *ngIf=\"(col.field == 'errorCount')\" let-col let-rowData=\"rowData\" pTemplate=\"body\">\n          <span *ngIf='rowData[col.field] != 0 ' style=\"color:blue;cursor: pointer ;\" title=\"View Exception Report\" (click)=\"openExceptionReport(rowData)\"> {{ rowData[col.field] }} </span>\n          <span  *ngIf='rowData[col.field]  == 0 '> {{ rowData[col.field] }} </span>\n        </ng-template>\n       </p-column>\n    </p-dataTable> -->\n</div>\n \n\n  <!-- <p-toolbar *ngIf=\"showClipboard\">\n    <label style=\"float:right\" class=\"icon ddrui-icon-copy-link\" cbContent=\"popupFooter\" ngxClipboard title=\"Copy Query\"  (cbOnSuccess)=showNotification()></label>\n    </p-toolbar> -->\n    \n      <!-- <div *ngIf=\"true\"> -->\n\n  \n<div class=\"query-row border-4 mt-10\">\n  <div class=\"p-grid p-align-center p-justify-between\">\n    <div class=\"p-col\">{{popupFooter}} </div>\n    <div *ngIf=\"showClipboard\" class=\"p-col-fixed width-40\">\n      <button type=\"button\" pButton icon=\"icons8 icons8-copy\" class=\"btn-icon\" [cdkCopyToClipboard]=\"popupFooter\"\n        title=\"Copy Query\" (cbOnSuccess)=showNotification()></button>\n    </div>\n  </div>\n</div>\n      <div *ngIf=\"!paramLoad && showDbParam && dbPerm\">\n        <p-table [columns]=\"colsDbParam\" [resizableColumns]=\"true\" [reorderableColumns]=\"true\" class=\"scen-table all-tables\"\n          [value]=\"dbParamInfo\" [rows]=\"5\" [paginator]=\"dbParamInfo?.length > 5\">\n          <ng-template pTemplate=\"colgroup\" let-columns>\n            <colgroup>\n              <ng-container>\n                <col class=\"w-75-p\">\n                <col class=\"w-25-p\">\n              </ng-container>\n            </colgroup>\n          </ng-template>\n          <ng-template pTemplate=\"header\">\n            <tr>\n              <ng-container *ngFor=\"let col of colsDbParam\">\n                <th style=\"text-overflow: inherit; white-space:normal;\" [pSortableColumn]=\"col.field\" pResizableColumn\n                  pReorderableColumn>\n                  <span>{{col.header}}\n                    <p-sortIcon [field]=\"col.field\" ariaLabel=\"Activate to sort\"\n                      ariaLabelDesc=\"Activate to sort in descending order\" ariaLabelAsc=\"Activate to sort in ascending order\">\n                    </p-sortIcon>\n                  </span>\n                </th>\n              </ng-container>\n            </tr>\n          </ng-template>\n          <ng-template pTemplate=\"body\" let-node>\n            <tr>\n              <ng-container *ngFor=\"let col of colsDbParam\">\n                <td>\n                  <span *ngIf=\"col.field === 'QueryParameter'\">\n                    {{(node[col.field])}}\n                  </span>\n                  <span *ngIf=\"col.field === 'ResponseTime'\" class=\"right\">\n                    {{(node[col.field])}}\n                  </span>\n                </td>\n              </ng-container>\n            </tr>\n          </ng-template>\n          <ng-template pTemplate=\"emptymessage\" let-columns>\n            <tr>\n              <td [attr.colspan]=\"2\" class=\"text-center\">\n                <span>No Records Found</span>\n              </td>\n            </tr>\n          </ng-template>\n        </p-table>\n      </div>\n  </p-dialog>\n\n  <p-dialog  class=\"secondary-dialog foterDialog\" [style]=\"{width: '50vw'}\" [(visible)]=\"displayTFMPopUp\"  [responsive]='true' [resizable]='false' [positionTop]='140' minHeight='200' [style]=\"{'max-height':'500px'}\">\n    <p-header>HotSpot Thread Details</p-header>\n     <div>\n       <table  width=\"500\"  height=\"150\"   cellspacing=\"0\" >\n          <tbody>\n             <tr><td style=\"border: 0px solid grey;font-size:10pt;text-align:center;\">No Hotspots found based on current Filter Settings.</td></tr>\n          </tbody> \n       </table>\n      </div>\n    </p-dialog>\n\n    <p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '65vw'}\" [responsive]='true'  [(visible)]=\"tableDialogDisplay1\" [resizable]='false'  height='tabularViewPopUpHeight' >\n      <p-header>\n          {{headerForSRG}}\n        </p-header>\n        <div style=\"width: 1271px;height: 20px;\">\n          <span style=\"float: right;\">\n            <img src='./assets/images/all-graph.png' style=\"cursor: pointer\" title='View All Graphs in Mulitple Frames' (click)=\"openAllGraphs()\"/>\n          </span>\n          <span style=\"float: right;\">\n            <img src='./assets/images/combined-graph.png' style=\"cursor: pointer\" title='View All Graphs in one Frame' (click)=\"openSingleGraph('', 'merge')\"/>\n          </span>\n          <span class= \"btn\" (click)=\"openSamplePopUp()\">Set Samples</span>\n        </div>\n        <div style=\"overflow:auto\">\n        <p-table class=\"scen-table all-tables\" *ngIf=\"tableDialogDisplay1\" scrollable='true' scrollHeight = '300px' [value]=\"graphTableArray\" [resizableColumns]=\"true\"\n        [style]= \"{'width':'1280px', 'height': '240px'}\" sortField={{sortField}} sortOrder=\"-1\" >\n        <ng-template pTemplate=\"header\">\n          <tr>\n            <th pResizableColumn>Graph Name</th>\n            <th pResizableColumn>Min</th>\n            <th pResizableColumn>Max</th>\n            <th pResizableColumn>Avg</th>\n            <th pResizableColumn>Std-Dev</th>\n            <th pResizableColumn>Last</th>\n            <th pResizableColumn>Samples</th>\n          </tr>\n        </ng-template>\n        <ng-template pTemplate=\"body\" let-node>\n          <tr>\n            <td><span class =\"ddr-table-left\" (click)=\"openSingleGraph(node, 'single')\">{{node['graphName']}}></span> </td>\n            <td>node.min</td>\n            <td>node.max</td>\n            <td>node.avg</td>\n            <td>node.stdev</td>\n            <td>node.last</td>\n            <td>node.count</td>\n          </tr>\n        </ng-template>\n        </p-table>\n        <!-- <p-dataTable class=\"scen-table\" *ngIf=\"tableDialogDisplay1\" scrollable='true' scrollHeight = '350px' [value]=\"graphTableArray\" \n        [style]= \"{'width':'1280px', 'height': '240px'}\" sortField={{sortField}} sortOrder=\"-1\">\n            <p-column field=\"graphName\" header=\"Graph Name\" [sortable]=\"true\" [style]=\"{'text-align':'left', 'width': '37%'}\">\n              <ng-template let-col let-node=\"rowData\" pTemplate=\"body\">\n                <span class =\"ddr-table-left\" (click)=\"openSingleGraph(node, 'single')\">{{node[col.field]}}></span> \n              </ng-template>\n            </p-column>\n            <p-column field=\"min\" header=\"Min\" [sortable]=\"true\" [style]=\"{'text-align':'right'}\"></p-column>\n            <p-column field=\"max\" header=\"Max\" [sortable]=\"true\" [style]=\"{'text-align':'right'}\"></p-column>\n            <p-column field=\"avg\" header=\"Avg\" [sortable]=\"true\" [style]=\"{'text-align':'right'}\"></p-column>\n            <p-column field=\"stdev\" header=\"Std-Dev\" [sortable]=\"true\" [style]=\"{'text-align':'right'}\"></p-column>\n            <p-column field=\"last\" header=\"Last\" [sortable]=\"true\" [style]=\"{'text-align':'right'}\"></p-column>\n            <p-column field=\"count\" header=\"Samples\" [sortable]=\"true\" [style]=\"{'text-align':'right'}\"></p-column>\n        </p-dataTable> -->\n      </div>\n    </p-dialog>\n\n    <p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '50vw'}\" [responsive]='true'  [(visible)]=\"singleMergeGraph\" [positionTop]='10' [resizable]='false' height='550' >\n      <p-header>\n          {{headerForSRG}}\n        </p-header>\n        <!-- <div>\n        <highcharts-chart [Highcharts] = \"highcharts\" [options]=\"options\"></highcharts-chart>\n      </div> -->\n    </p-dialog>\n\n    <p-dialog  class=\"secondary-dialog foterDialog\" [style]=\"{width: '65vw'}\" [(visible)]=\"displayShowRelatedGraph\"  (onHide)=\"onhideDialog($event)\" [responsive]='true' [resizable]='false' [positionTop]='10' height='600' >\n      <p-header>{{headerForSRG}}</p-header>\n      <div style=\"display: flex;flex-wrap: wrap;\">\n      <div style=\"width: 50%;float: left;text-align: right;box-sizing: border-box;padding: .5em;display: block;font-size: 15px;\">{{graphMessage}}</div>\n      <div style=\"width: 50%;float: left;box-sizing: border-box;padding: .5em;display: block;font-size: 11px;\">\n          <span id=\"next\" class=\"pre_next\">NEXT</span>\n          <span id=\"prev\" class=\"pre_next\">PREV</span>\n      </div>\n      </div>\n      <div id=\"firstDiv\" style=\"width: 1305px; height: 600px\">  \n         <app-ddr-show-related-graph *ngFor=\"let item of grapghData\" [graphValue]= \"item\" [json]=\"graphJson\"></app-ddr-show-related-graph>\n      </div>\n      <div id=\"secondDiv\" style=\"width: 1305px; height: 600px\">  \n        <app-ddr-show-related-graph *ngFor=\"let item of graphData\" [graphValue]= \"item\" [json]=\"graphJson\"></app-ddr-show-related-graph>\n      </div>\n    </p-dialog>\n\n    <p-dialog  class=\"secondary-dialog foterDialog\" [style]=\"{width: '50vw'}\" [(visible)]=\"displaySamplePopup\"  [responsive]='true' [resizable]='false' [positionTop]='20' height='161' >\n        <p-header>Set Request Start/End Samples</p-header>\n        <div class='ui-g'>\n          <div class='ui-g-6'>\n            <span style='margin-right:13px'>Start Samples:</span>\n            </div>\n            <div class='ui-g-6'>\n            <input type=\"number\" min=0 style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"startSample\" />\n          </div>\n          </div>\n          <div class='ui-g'>\n            <div class='ui-g-6'>\n              <span style='margin-right:13px'>End Samples:</span>\n              </div>\n              <div class='ui-g-6'>\n              <input type=\"number\" min=0  style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"endSample\" />\n            </div>\n            </div>\n            <p-footer>\n              <div style=\"text-align: center\">\n                <button pButton type=\"button\" label=\"Apply\" (click)=\"applySamplePopUp()\"></button>\n                <button pButton type=\"button\" label=\"Reset\" (click)=\"applyDefaultValue()\"></button>\n                <button pButton type=\"button\" label=\"Cancel\" (click)=\"displaySamplePopup =false\"></button>\n               </div>      \n           </p-footer>\n    </p-dialog>\n\n    \n    <canvas id=\"canvasforDownload\" style=\"background-color: white; display:none;\" width=\"1400\" height=\"1040\"> </canvas>\n    <a id='trans' style='display:none;'></a>\n\n     <!-- <p-dialog  class=\"scenmodal  Ddr-popup-footer\" [(visible)]=\"waningPopup\"  [responsive]='true' [resizable]='false' [positionTop]='140' width=\"500\"  [style]=\"{'height':'400px'}\"> -->\n      <p-dialog  class=\"secondary-dialog foterDialog\" [(visible)]=\"waningPopup\"  [responsive]='true' [resizable]='false' [positionTop]='140' width=\"500\">\n      <p-header> <img src='./assets/images/warning.png' style=\"cursor: pointer; height:18px;\"  (click)='showWarningMessgae()'/> <span style='font-size: 14px'> Warning</span></p-header>\n       <b><span *ngIf=\"flowmapData.isRootFpMissing\" style='font-size: 13px'>- Root Flowpath is missing</span></b>\n      <br>\n      <b><span  style='font-size: 13px'> -   One or more flow paths are not captured in the path shown by Red arrow(s).</span></b>\n     </p-dialog>\n\n     <p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{'width': '900px'}\" header=\"Dynamic Diagnostics Configuration\" [resizable]=\"false\" *ngIf=\"showAutoInstrPopUp\" [(visible)]=\"showAutoInstrPopUp\" modal=\"modal\">\n        <app-dynamic-diagnostics (resultAfterStart)=\"startInstrumentation($event)\" (closeAIDDGui)=\"closeAIDDDialog($event)\" [passAIDDSettings]=\"argsForAIDDSetting\"></app-dynamic-diagnostics>\n     </p-dialog>\n     <p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '50vw'}\" [style]=\"{'margin-left':'35px', 'margin-top':'46px'}\" header=\"Http Report\" [(visible)]=\"httpDialog\" [resizable]=false [modal]=\"true\" autoAlign=\"true\">\n      <div style=\"overflow: auto; height: 400px; width:600px\">\n          <p-accordion class=\"ddr-accordion\"  [multiple]=\"true\">\n           <p-accordionTab header=\"Http Request Body\">\n             <pre style=\"white-space: pre-wrap; word-break: break-word; outline: none;\">{{httpRequestArrBody}}</pre>  \n          </p-accordionTab>\n         </p-accordion>\n         <p-accordion class=\"ddr-accordion\"  [multiple]=\"true\">\n          <p-accordionTab header=\"Http Response Body\">\n            <pre style=\"white-space: pre-wrap; word-break: break-word; outline: none;\">{{httpResponseArrBody}}</pre>  \n         </p-accordionTab>\n        </p-accordion>\n      </div>\n   </p-dialog>\n   <p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{'margin-left':'35px', 'margin-top':'46px'}\" header=\"CallOut Body\" [(visible)]=\"httpDialogTable\" [resizable]=false [modal]=\"true\" autoAlign=\"true\">\n    <div style=\"overflow-x: fixed; overflow-y: auto; height: 200px; width: 800px\">\n        <p-table [columns]=\"cols1\" [value]=\"httpRequestArrBody1\" [style]=\"{'width':'400px','float':'left'}\" [scrollable]=\"true\" scrollHeight=\"260px\">\n                        <ng-template pTemplate=\"header\" let-columns>\n                            <tr>\n                                <th *ngFor=\"let col of columns\">\n                                    {{col.header}}\n                                </th>\n                            </tr>\n                        </ng-template>\n                        <ng-template pTemplate=\"body\" let-node let-columns=\"columns\">\n                            <tr>\n                                <td *ngFor=\"let col of columns\">\n                                    {{node[col.field]}}...\n                                    <span class=\"primary-text ui-toolbar-group-right\" style=\"text-decoration-line: underline; cursor: pointer; margin-left: 5px;\" (click)=\"onShowMore($event)\">Show More...</span>\n                                </td>\n                            </tr>\n                        </ng-template>\n                    </p-table>\n                  \n        <p-table [columns]=\"cols2\" [value]=\"httpResponseArrBody1\" [style]=\"{'width':'400px', 'float':'right'}\">\n            <ng-template pTemplate=\"header\" let-columns>\n                <tr>\n                    <th *ngFor=\"let col of columns\">\n                        {{col.header}}\n                    </th>\n                </tr>\n            </ng-template>\n            <ng-template pTemplate=\"body\"  let-node let-columns=\"columns\" >\n                <tr>\n                    <td *ngFor=\"let col of columns\">\n                        {{node[col.field]}}...\n                        <span class=\"primary-text ui-toolbar-group-right\" style=\"text-decoration-line: underline; cursor: pointer; margin-left: 5px;\" (click)=\"onShowMore1($event)\">Show More...</span>\n                    </td>\n                </tr>\n            </ng-template>\n        </p-table>         \n      </div>              \n </p-dialog>\n<p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{'margin-left':'35px', 'margin-top':'46px'}\" header=\"Request Body\" [(visible)]=\"showmore\" [resizable]=false [modal]=\"true\" autoAlign=\"true\">\n  <div style=\"overflow: auto; height: 300px; width: 400px;\">\n   <pre style=\"white-space: pre-wrap; word-break: break-word; outline: none;\">{{httpRequestArrBody2}}\n   </pre>\n  </div>\n</p-dialog>\n<p-dialog class=\"secondary-dialog foterDialog\"[style]=\"{'margin-left':'35px', 'margin-top':'46px'}\" header=\"Response Body\" [(visible)]=\"showmore1\" [resizable]=false [modal]=\"true\" autoAlign=\"true\">\n  <div style=\"overflow: auto; height: 300px; width:400px\">\n      <pre style=\"white-space: pre-wrap; word-break: break-word; outline: none;\">{{httpResponseArrBody2}}\n      </pre>\n  </div>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/exception-report/exception-report.component.html":
/*!*****************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/exception-report/exception-report.component.html ***!
  \*****************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div>\n    <div class=\"ddr-box\">\n        <div class=\"ddr-toolbar\">\n            <div class=\"p-grid p-align-center p-justify-between ui-table-header\">\n                <div class=\"w-80-p\">\n                    <span title=\"{{completeTier}}\">{{filterTierName}}</span>\n                    <span title=\"{{completeServer}}\">{{filterServerName}}</span>\n                    <span title=\"{{completeInstance}}\">{{filterInstanceName}}</span>\n                    <span title=\"{{completeGroupBy}}\">{{filterGroupByStr}}</span>\n                    <span title=\"{{completeOrderBy}}\">{{filterOrderByStr}}</span>\n                    <span>{{headerInfo}}</span>\n                    <span title=\"{{CompleteURL}}\">{{URLstr}}</span>\n                </div>\n            </div>\n        </div>\n\n        <!-- COMMON BOX SCROLLLBAR -->\n        <div class=\"ddruiscroll\" [ngStyle]=\"{'height': screenHeight+'px'}\" style=\"overflow:auto;\">\n            <div class=\"p-6\">\n                <p-accordion class=\"ddr-accordion\">\n                    <p-accordionTab header=\"Exception Stats\" [selected]=\"false\">\n                        <div class=\"ui-g\">\n                            <p-card class=\"ui-g-6\">\n                                <div class=\"ddr-graphpanel\" *ngIf=\"showChart == true\">\n                                    <highcharts-chart [Highcharts]=\"highcharts\"\n                                        style=\"width: 100%; display: block; overflow: hidden;\" [options]=\"options\"\n                                        (click)=\"clickHandler($event)\"></highcharts-chart>\n                                </div>\n                                <div *ngIf=\"showChart == false\" style=\"text-align:center;\">No Pie Chart found based on\n                                    current Filter Settings.</div>\n                            </p-card>\n                            <p-card class=\"ui-g-6\">\n                                <div class=\"ddr-graphpanel\" *ngIf=\"showChart == true\">\n                                    <highcharts-chart [Highcharts]=\"highcharts\"\n                                        style=\"width: 100%; display: block; overflow: hidden;\" [options]=\"options1\">\n                                    </highcharts-chart>\n                                </div>\n                                <div *ngIf=\"showChart == false\" style=\"text-align:center;\">No Excpetion Time Graph found\n                                    based on current Filter Settings.</div>\n                            </p-card>\n                        </div>\n                    </p-accordionTab>\n                </p-accordion>\n                <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n                    <p-accordionTab [selected]=\"true\">\n                        <p-header>\n                            Aggregate Exception(s) {{aggHeaderInfo}}\n                        </p-header>\n                        <div>\n                            <cav-table [value]=\"filteredAggregateExceptionInfo\" [tableConfig]=\"tableConfigAgg\" [headers]=\"colsForAggException\"\n                                [columns]=\"colsForAggException\" [scrollable]=\"true\" [responsive]=\"true\" scrollHeight=\"calc(100vh - 240px)\"\n                                [paginator]=\"true\" [lazy]=\"true\" [rows]=\"rows\" [first]=\"first\" [rowsPerPageOptions]=\"[10,20,30,40]\"\n                                [rowSelection]=\"filteredAggregateExceptionInfo[0]\" (onLazyLoad)=\"paginateAgg($event)\"\n                                (clickButtonEvent)=\"clickButtonEventAggExcepction($event)\"></cav-table>\n                        </div>\n                    </p-accordionTab>\n                </p-accordion>\n                <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n                    <p-accordionTab header=\"Exception(s) {{tableHeader}}\" [selected]=\"true\">\n                        <div>\n                            <cav-table [value]=\"exceptionInfo\" [headerRelativePath]=\"relativePathForException\" [scrollable]=\"true\"\n                                [responsive]=\"true\" [totalRecords]=\"totalCount\" [first]=\"firstException\" [rows]=\"rowsException\"\n                                scrollHeight=\"calc(100vh - 240px)\" (onLazyLoad)=\"loadExceptionPagination($event)\"\n                                (clickButtonEvent)=\"clickButtonEventExcepction($event)\"></cav-table>\n                        </div>\n                    </p-accordionTab>\n\n                    <p-dialog class=\"foterDialog\" header=\"Getting Source Code...\" [(visible)]=\"loader\" appendTo=\"body\"\n                        modal=\"modal\" [style]=\"{'width':'300px'}\" [closable]=\"false\">\n                        <div class=\"my-20\" *ngIf=\"loader\">\n                            <p-progressBar [value]=\"value\"></p-progressBar>\n                        </div>\n                        <p-footer class=\"p-grid p-justify-end\">\n                            <button type=\"button\" pButton (click)=\"loader=false\" label=\"Close\"\n                                class=\"ui-button-secondary\"></button>\n                        </p-footer>\n                    </p-dialog>\n\n                    <div class=\"p-grid p-nogutter\">\n                        <div class=\"p-col\">\n                            <p-accordionTab header=\"Stack Trace {{ stackTraceHeader ? '&nbsp;[' + stackTraceHeader + ']' : '' }}\" [selected]=\"true\">\n                                <p-header> Stack Trace <label\n                                        title=\"{{stackTraceHeaderTooltip}}\">{{ stackTraceHeader ? '&nbsp;[' + stackTraceHeader + ']' : '' }}\n                                    </label></p-header>\n                                <cav-table [value]=\"stackObj\" [headerRelativePath]=\"relativePathForStackTrace\"\n                                        [scrollable]=\"true\" [responsive]=\"true\"\n                                        (clickButtonEvent)=\"clickButtonEventStackTrace($event)\"scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n\n                            </p-accordionTab>\n                        </div>\n                        <div class=\"ui-g-6\" *ngIf=\"showCode\">\n                            <div class=\"source-code\">\n                                <div class=\"p-grid p-justify-start p-align-center\">\n                                    <div class=\"w-100-p\">\n                                        <div>\n                                            <div class=\"exception-panel\">\n                                                <button type=\"button\" pButton class=\"butPosition btn-icon\"\n                                                    icon=\"pi pi-times\" (click)=\"showCode = false;\"\n                                                    pTooltip=\"Close Source Code\"></button>\n                                                <p-tabView styleClass=\"txt-trnf-none\">\n                                                    <p-tabPanel\n                                                        header=\"Source Code{{stackTraceHeaderInfo | ellipsis: 20}}\"\n                                                        tooltip=\"Source Code{{stackTraceHeaderInfo}}\"\n                                                        tooltipPosition=\"bottom\">\n                                                        <div class=\"p-grid p-justify-end p-align-center\">\n                                                            <div class=\"imageIcon\">\n                                                                <button pButton icon=\"icons8-copy\"\n                                                                    *ngIf=\"showDownloadSourceCodeIcon\" class=\"btn-icon\"\n                                                                    (click)=\"copySourceCode(methodBody)\"\n                                                                    pTooltip=\"Copy Source Code\"></button>\n\n                                                                <button pButton icon=\"icons8-download\"\n                                                                    *ngIf=\"showDownloadSourceCodeIcon\" class=\"btn-icon\"\n                                                                    (click)=\"downLoadSourceCode(1)\"\n                                                                    pTooltip=\"Download Method Body\"></button>\n\n                                                                <button pButton icon=\"icons8-download-2\"\n                                                                    *ngIf=\"showDownloadSourceCodeIcon\" class=\"btn-icon\"\n                                                                    (click)=\"downLoadSourceCode(2)\"\n                                                                    pTooltip=\"Download Class File\"></button>\n                                                            </div>\n                                                        </div>\n                                                        <div class=\"monaco-editor-container\">\n                                                            <ngx-monaco-editor\n                                                            [options]=\"monacoEditorOptions\"\n                                                            [(ngModel)]=\"monacoEditorContent\"\n                                                            (onInit)=\"onMonacoEditorInit($event)\"\n                                                            style=\"height:400px; width:100%;\">\n                                                        </ngx-monaco-editor>\n                                                        </div>\n                                                    </p-tabPanel>\n                                                    <p-tabPanel header=\"Logs({{totalLogs}})\">\n                                                        <cav-table [value]=\"lastNLogJson\" [headerRelativePath]=\"relativePathForLastNLog\"\n                                                        [scrollable]=\"true\" [responsive]=\"true\"\n                                                        scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n                                                    </p-tabPanel>\n                                                </p-tabView>\n                                            </div>\n                                        </div>\n                                    </div>\n                                </div>\n                            </div>\n\n                            <div *ngIf=\"showCode\" class=\"w-100-p mt-15\">\n                                <div class=\"p-grid p-justify-start p-align-center\">\n                                    <div class=\"w-100-p\">\n                                        <div>\n                                            <div class=\"exception-panel\">\n                                                <p-tabView styleClass=\"txt-trnf-none\">\n                                                    <p-tabPanel header=\"View Recorded Variables\">\n                                                        <p-accordion>\n                                                            <p-accordionTab\n                                                                header=\"Class Variables  (Total: {{toalClassVars}})\"\n                                                                style=\"overflow: scroll;white-space: break-spaces;\">\n                                                                <div *ngIf=\"toalClassVars>0; else elseBlockClass\">\n                                                                    <cav-table [value]=\"classVarArgsJson\" [headerRelativePath]=\"relativePathForClassVar\"\n                                                                 [scrollable]=\"true\" [responsive]=\"true\" \n                                        scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n\n                                                                </div>\n                                                                <ng-template #elseBlockClass>\n                                                                    Class variable is not\n                                                                    present\n                                                                </ng-template>\n                                                            </p-accordionTab>\n                                                            <p-accordionTab\n                                                                style=\"overflow: scroll;white-space: break-spaces;\"\n                                                                header=\"Method Arguments (Total: {{totalMethodVars}})\">\n                                                                <div *ngIf=\"totalMethodVars>0; else elseBlockMethod\">\n                                                                    <cav-table [value]=\"methodVarArgsJson\" [headerRelativePath]=\"relativePathForMethodVar\"                                                                    [scrollable]=\"true\" [responsive]=\"true\" \n                                                                      scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n\n                                                                </div>\n                                                                <ng-template #elseBlockMethod>\n                                                                    Method argument is not\n                                                                    present\n                                                                </ng-template>\n                                                            </p-accordionTab>\n                                                            <p-accordionTab\n                                                                style=\"overflow: scroll;white-space: break-spaces;\"\n                                                                header=\"Local Variables (Total: {{totalLocalVars}})\">\n                                                                <div *ngIf=\"totalLocalVars>0; else elseBlockLocal\">\n                                                                    <cav-table [value]=\"localVarArgsJson\" [headerRelativePath]=\"relativePathForLocalVar\" [scrollable]=\"true\" [responsive]=\"true\" \n                                                                  scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n\n                                                                </div>\n                                                                <ng-template #elseBlockLocal>\n                                                                    Local variable is not\n                                                                    present\n                                                                </ng-template>\n                                                            </p-accordionTab>\n                                                            <p-accordionTab\n                                                                style=\"overflow: scroll;white-space: break-spaces;\"\n                                                                header=\"Thread Local Variables (Total: {{totalThreadVars}})\">\n                                                                <div *ngIf=\"totalThreadVars>0; else elseBlockThread\">\n                                                                    <cav-table [value]=\"ThreadLocalVarArgsJson\" [headerRelativePath]=\"relativePathForThreadLocal\" [scrollable]=\"true\" [responsive]=\"true\"\n                                                                    scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n                            \n                                                                </div>\n                                                                <ng-template #elseBlockThread>\n                                                                    Thread Local variable is not\n                                                                    present\n                                                                </ng-template>\n                                                            </p-accordionTab>\n                                                        </p-accordion>\n                                                    </p-tabPanel>\n                                                </p-tabView>\n                                            </div>\n                                        </div>\n                                    </div>\n                                </div>\n                            </div>\n                        </div>\n                        <!-- -------------end dataSourceCode---------------- -->\n\n                        <p-dialog class=\"secondary-dialog foterDialog\" *ngIf=\"showInsideObjPopup\"\n                            header={{headerInsideObj}} [(visible)]=\"showInsideObjPopup\" responsive=\"true\"\n                            showEffect=\"fade\">\n\n                            <div class=\"modalPopUp\">\n                                <div *ngIf=\"totalIndex!= '-1' && totalIndex!= '-101'\"\n                                    style=\"color:#154771; font-size:13px;font-weight:bold;\">Array Size: {{totalIndex}}\n                                </div>\n                                <div style=\"color:#154771; font-size:14px;font-weight:bold; text-align:center;padding-top: 8px;\"\n                                    *ngIf=\"totalIndex == '-101'\"> No data available</div>\n                                <br>\n                                <div *ngFor=\"let key of dataKey\">\n                                    <div *ngIf=\"key!= -1\">\n                                        <div style=\"color:#154771; font-size:13px;\">Index = {{key}}</div>\n                                    </div>\n\n                                    <table *ngIf=\"totalIndex!= '-101'\">\n                                        <thead>\n                                            <tr>\n                                                <th>Name</th>\n                                                <th>Value</th>\n                                                <th>Type</th>\n                                            </tr>\n                                        </thead>\n                                        <tbody>\n                                            <tr *ngFor=\"let rowData of insideObjVariable.data[key]\">\n                                                <td>{{rowData.name}} </td>\n                                                <td\n                                                    title=\"{{showToolTipForValueLength(rowData.type,rowData.valueLength)}}\">\n                                                    {{rowData.val}} </td>\n                                                <td>{{rowData.type}} </td>\n                                            </tr>\n                                        <tbody>\n                                    </table>\n                                    <br />\n                                </div>\n\n                            </div>\n\n                        </p-dialog>\n\n                    </div>\n                </p-accordion>\n    </div>\n</div>\n<p-dialog class=\"secondary-dialog\" [style]=\"{width: '50vw'}\" [(visible)]=\"isCancelQuery\" modal=\"modal\"\n    [resizable]='false' [responsive]=\"true\" height=\"120\">\n    <p-header>\n        <i class=\"icons8 icons8-info\" style=\"color:red\"></i>\n        <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n    </p-header>\n    <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n    <p-footer>\n        <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n            class=\"ui-button-rounded ui-button-secondary\"></button>\n        <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" label=\"Wait\"\n            class=\"ui-button-rounded\"></button>\n    </p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.html":
/*!*******************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.html ***!
  \*******************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"ddruiscroll\" style=\"overflow:auto; height: calc(100vh - 70px);\">\n  <div class=\"ddr-box\">\n    <!-- COMMON TOOLBAR -->\n    <div class=\"ddr-toolbar\">\n      <div class=\"p-grid p-justify-between p-align-center ui-table-header\">\n        <div>\n          <span>{{filterCriteria}}</span>\n          <div *ngIf=\"showWarning\" class=\"p-grid p-align-center my-4\">\n            <i class=\"icons8 icons8-error font-16 mx-3\"></i>\n            <label>\n              <b>Showing for top 10000 Flowpath(s).</b>\n            </label>\n          </div>\n        </div>\n        <div>\n          <label style=\"margin-right: 10px;\">\n            <b>Number of Pattern</b>\n          </label>\n          <label>\n            <input type=\"text\" pInputText value=\"5\" (keypress)=\"onlyNumberKey($event)\" [(ngModel)]=\"noOfpattern\"\n              style=\"height: 26px;width:40px; margin-left: 4px; margin-right: 5px;\">\n          </label>\n          <label>\n            <button pButton type=\"button\" label=\"Apply\" (click)=\"applyPattern()\" class=\"ui-button-rounded ui-button-secondary mx-5\"></button>\n          </label>\n          </div>\n      </div>\n    \n      <!-- DDR UI SCROLL -->\n      <div class=\"ddruiscroll\" style=\"overflow:auto; height: calc(100vh -125px);\">\n        <div class=\"ui-g-12\">\n          <div style=\"overflow:auto\">\n            <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n              <p-accordionTab header=\"Pattern Stats\" [selected]=\"false\">\n                <div class=\"ui-g\">\n                  <p-card class=\"ui-g-6\">\n                    <div class=\"ddr-graphpanel\">\n                      <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\" style=\"width: 100%; height: 100%; display: block;\">\n                      </highcharts-chart>\n                    </div>\n                  </p-card>\n\n                  <p-card class=\"ui-g-6\">\n                    <div class=\"ddr-graphpanel\">\n                      <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options1\" style=\"width:  100%; height: 100%; display: block;\">>\n                      </highcharts-chart>\n                    </div>\n                  </p-card>\n                </div>\n              </p-accordionTab>\n              <p-accordionTab header=\"Flowpath Signature\" [selected]=\"true\">\n                <div style=\"overflow:auto\">\n                  <cav-table [value]=\"signatureData\" [headerRelativePath]=\"signatureHeaderRelativePath\" [scrollable]=\"true\"\n                    [responsive]=\"true\"  scrollHeight=\"calc(100vh - 180px)\"\n                    (clickButtonEvent)=\"clickEventOnSignatureTable($event)\"></cav-table>\n                </div>\n              </p-accordionTab>\n\n              <p-accordionTab header=\"Pattern Summary {{patternHeader}}\" [selected]=\"true\">\n                <div>\n                  <cav-table [value]=\"patternData\" [headerRelativePath]=\"patternHeaderRelativePath\"\n                    [scrollable]=\"true\" [responsive]=\"true\" scrollHeight=\"calc(100vh - 180px)\"\n                    (clickButtonEvent)=\"clickEventOnPatternTable($event)\"></cav-table>\n                </div>\n              </p-accordionTab>\n              <p-accordionTab header=\"Top Methods (Total Self Time(ms) and Count per Flowpath)\" [selected]=\"true\">\n                <div>\n                  <cav-table [tableConfig]=\"tableConfigForTopMethods\" [value]=\"topMethodData\" [headers]=\"colsForTopMethods\"  [scrollable]=\"true\" [responsive]=\"true\" scrollHeight=\"calc(100vh - 100px)\"\n                  ></cav-table>\n                </div>\n              </p-accordionTab>\n            </p-accordion>\n          </div>\n        </div>\n      </div>\n    </div>\n  </div>\n  <p-dialog class=\"scenmodal  Ddr-popup-footer\" [(visible)]=\"displayPopUp\" [responsive]='true' [resizable]='false'\n    [positionTop]='140' width=\"500\" minHeight='300' [style]=\"{'max-height':'500px'}\">\n    <p-header>{{infoHeader}}</p-header>\n    <div>\n      <table width=\"500\" height=\"150\" cellspacing=\"0\">\n        <tbody>\n          <tr>\n            <td style=\"border: 0px solid grey;font-size:10pt;text-align:center;\">{{strInfoMessage}}.</td>\n          </tr>\n        </tbody>\n      </table>\n    </div>\n  </p-dialog>\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.html":
/*!*******************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.html ***!
  \*******************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n\n<div class=\"ddr-box\">\n    <div class=\"ddr-toolbar\">\n        <div class=\"p-grid p-justify-between p-align-center ui-table-header\">\n            <div>\n                <span title=\"{{completeTier}}\">{{filterTierName}}</span>\n                <span title=\"{{completeServer}}\">{{filterServerName}}</span>\n                <span title=\"{{completeInstance}}\">{{filterInstanceName}}</span>\n                <span title=\"{{CompleteURL}}\">{{URLstr}}</span>\n                <span title=\"{{completeGroupBy}}\">{{filterGroupByStr}}</span>\n                <span title=\"{{completeOrderBy}}\">{{filterOrderByStr}}</span>\n                <label class=\"headerInfo\">{{headerInfo}}</label>\n            </div>\n        </div>\n\n    </div>\n    <div class=\"ddruiscroll overflow\" style=\"height: calc(100vh - 155px); overflow-x: hidden;\">\n        <p-accordion class=\"ddr-accordion\">\n            <p-accordionTab [selected]='false' header=\"Flowpath Stats\">\n                <div class='ui-g'>\n                    <div *ngIf=\"showBarChart == true\" class=\"my-graph\">\n                        <highcharts-chart [Highcharts]=\"highcharts\" (click)=\"clickHandler($event)\"\n                            [options]=\"chartOptions\"></highcharts-chart>\n                    </div>\n                    <div *ngIf=\"showBarChart == false\" style=\"text-align:center;\">No Bar Chart found based on current\n                        Filter Settings.</div>\n                </div>\n            </p-accordionTab>\n        </p-accordion>\n        <p-accordion class=\"ddr-accordion dynamic-column-width-acc\">\n            <p-accordionTab [selected]='true' header=\"Flowpath Summary\">\n                <div style=\"overflow:unset\">\n                    <cav-table [value]=\"flowpathData\" [tableConfig]=\"tableConfig\" [headers]=\"colsForFpGroupByBT\"\n                        [columns]=\"colsForFpGroupByBT\" [scrollable]=\"true\" [responsive]=\"true\" [paginator]=\"true\" [lazy]=\"true\"\n                        (clickButtonEvent)=\"clickButtonEvent($event)\" scrollHeight=\"calc(100vh - 365px)\" [rows]=\"rows\"\n                        [first]=\"first\" [rowsPerPageOptions]=\"[50,100,200,400]\" (onLazyLoad)=\"paginate($event)\"></cav-table>\n                </div>\n            </p-accordionTab>\n        </p-accordion>\n    </div>\n</div>\n<p-dialog class=\"secondary-dialog\" [style]=\"{width: '45vw'}\" [(visible)]=\"isCancelQuery\" modal=\"modal\"\n    [resizable]='false' [responsive]=\"true\" height=\"120\" width=\"600\">\n    <p-header>\n        <i class=\"icons8 icons8-help\" style=\"color:red\"></i>\n        <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n    </p-header>\n    <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n    <p-footer>\n        <div class=\"p-grid p-justify-end sevbtn py-12\">\n            <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n                class=\"ui-button-rounded ui-button-secondary\"></button>\n            <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n        </div>\n    </p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath/flowpath.component.html":
/*!*************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath/flowpath.component.html ***!
  \*************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!-- COMMON TOOLBAR -->\n<div class=\"p-grid p-align-center p-justify-between ui-table-header\" style=\"word-break: break-all\">\n  <div class=\"w-100-p\">\n    <span>{{filtercriteria}}</span>\n  </div>\n</div>\n\n<div class=\"ddruiscroll\">\n  <div>\n    <div class=\"px-10\">\n      <p-menu #menuRef [popup]=\"true\" styleClass=\"widget-menu\" [model]=\"menuItems\" [showTransitionOptions]=\"'0ms'\"\n        [hideTransitionOptions]=\"'0ms'\" appendTo=\"body\"></p-menu>\n\n      <cav-table [value]=\"flowpathData\" [headerRelativePath]=\"relativePath\" [selection]=\"selectedRowInfo\"\n        [totalRecords]=\"fpTotalCount\" [responsive]=\"true\" (onLazyLoad)=\"loadFlowPathPagination($event)\"\n        (clickButtonEvent)=\"clickButtonEvent($event)\" [scrollable]=\"true\" scrollHeight=\"calc(100vh - 235px)\" [first]=\"first\"\n        [lazyLoadingProcessBar]=\"loading\" [rows]=\"rows\">\n      </cav-table>\n    </div>\n  </div>\n</div>\n<p-toast [style]=\"{top: '40px'}\" key=\"add-notification\"></p-toast>\n\n<p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '900px'}\" header=\"Dynamic Diagnostics Configuration\"\n  [resizable]=\"false\" *ngIf=\"showAutoInstrPopUp\" [(visible)]=\"showAutoInstrPopUp\" modal=\"modal\" responsive=\"true\">\n  <app-dynamic-diagnostics (resultAfterStart)=\"startInstrumentaion($event)\" (closeAIDDGui)=\"closeAIDDDialog($event)\"\n    [passAIDDSettings]=\"argsForAIDDSetting\"></app-dynamic-diagnostics>\n</p-dialog>\n\n<p-dialog class=\"secondary-dialog foterDialog\" header=\"FP Type Details\" [style]=\"{width: '50vw'}\" [modal]=\"true\"\n  [(visible)]=\"fptypeErrorFlag\" [resizable]=\"false\">\n  <div class=\"modalPopUp\">\n    <table cellspacing=\"3\" cellpadding=\"0\" border=\"2\" style=\"margin:0px 0px 0px 0px;width:365px;\">\n      <tr style=\"width:100px;height:30px\" valign=\"center\" align=\"center\">\n        <th>Message Code</th>\n        <th> Message</th>\n      </tr>\n      <tr *ngFor=\"let errorbit of errormsgObj \" style=\"width:100px;height:30px\" valign=\"center\" align=\"center\">\n        <td>{{errorbit.errorbit}}</td>\n        <td>{{errorbit.errmsg}}</td>\n      </tr>\n    </table>\n  </div>\n</p-dialog>\n\n<p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '40vw'}\" header=\"Clear Cached Data\"\n  [(visible)]=\"deleteCachedFlag\" modal=\"modal\" [resizable]='false' [responsive]=\"true\" height=\"230\" width=\"350\"\n  minWidth=\"200\">\n  <div *ngIf=\"deleteCachedFlag\" style=\"overflow:auto;\">\n    <ng-container *ngFor=\"let val of reportList\">\n      <span class=\"ui-g-6\">\n        <p-checkbox value={{val.value}} name=\"group1\" label={{val.label}} [(ngModel)]=\"selectedReport\"></p-checkbox>\n      </span>\n    </ng-container>\n  </div>\n  <p-footer>\n    <button pButton type=\"button\" label=\"Close\" (click)=\"deleteCachedFlag=false;\"\n      class=\"ui-button-rounded ui-button-secondary\"></button>\n    <button pButton type=\"button\" label=\"SelectAll\" (click)=\"onselectAll();\" class=\"ui-button-rounded\"></button>\n    <button pButton type=\"button\" label=\"Apply\" (click)=\"onApply();\" class=\"ui-button-rounded\"></button>\n  </p-footer>\n</p-dialog>\n\n<p-dialog class=\"secondary-dialog\" [style]=\"{width: '40vw'}\" [(visible)]=\"isCancelQuery\" modal=\"modal\"\n  [resizable]='false' [modal]=\"true\" [responsive]=\"true\">\n  <p-header>\n    <i class=\"icons8 icons8-info\" style=\"color:red; font-size: 15px;\"></i>\n    <span class=\"ml-4\">Query Load Process</span>\n  </p-header>\n  <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n  <p-footer>\n    <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n      class=\"ui-button-rounded ui-button-secondary\"></button>\n    <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n  </p-footer>\n</p-dialog>\n\n<app-help #help></app-help>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.html":
/*!*********************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.html ***!
  \*********************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n<div class=\"ddr-box\">\n  <div class=\"ddr-toolbar\">\n    <div class=\"p-grid p-justify-between p-align-center ui-table-header\">\n      <div class=\"w-80-p\">\n        <span>{{filterInfo}}</span>\n      </div>\n\n    </div>\n  </div>\n  <div class=\"ddruiscroll\" [ngStyle]=\"{'height': _ddrData.splitViewFlag ? 'calc(100vh - 180px)' : 'calc(100vh - 100px)'}\" style=\"overflow:auto;\">\n    <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n      <p-accordionTab header=\"DB Stats\" [selected]=\"true\">\n        <div class=\"ui-g\">\n          <div class=\"ui-g-4\"  *ngIf=\"showHideChart\">\n            <div *ngIf=\"showChart;else showMsg\" class=\"p-grid p-justify-center\">\n              <highcharts-chart [Highcharts]=\"highcharts\" style=\"display: block; overflow: hidden;\"\n                [options]=\"options\" (click)=\"clickHandler($event)\">\n              </highcharts-chart>\n            </div>\n            <ng-template #showMsg>{{pieChartMessage}}</ng-template>\n          </div>\n\n          <div [ngClass]=\"showHideChart ? 'ui-g-8' : 'ui-g-12' \">\n            <div>\n              <cav-table #fptodb [value]=\"queryInfo\" [scrollable]=\"true\" scrollHeight=\"260px\"\n                [headerRelativePath]=\"headerRelativePath\" [totalRecords]=\"totalCount\" [first]=\"first\" [rows]=\"rows\"\n                [lazyLoadingProcessBar]=\"loading\" (onLazyLoad)=\"loadFpToDbPagination($event)\"\n                (clickButtonEvent)=\"clickButtonEvent($event)\">\n              </cav-table>\n\n              <div *ngIf=\"showTable\">\n                <div class=\"word-break w-100-p scrollArea border-4\">{{fullQueryName}}</div>\n                <cav-table *ngIf=\"dbPerm\" #fptodb2 [value]=\"dbParamInfo\" [scrollable]=\"true\"\n                  scrollHeight=\"130px\" [headerRelativePath]=\"headerRelativePath2\">\n                </cav-table>\n              </div>\n\n            </div>\n          </div>\n        </div>\n\n      </p-accordionTab>\n    </p-accordion>\n  </div>\n</div>\n<p-dialog class=\"secondary-dialog\" [style]=\"{width: '50vw'}\" [(visible)]=\"isCancelQuery\" modal=\"modal\"\n  [resizable]='false' [responsive]=\"true\" height=\"120\">\n  <p-header>\n    <i class=\"icons8 icons8-info\" style=\"color:red\"></i>\n    <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n  </p-header>\n  <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n  <p-footer>\n    <div class=\"p-grid p-justify-end sevbtn\">\n      <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n        class=\"ui-button-rounded ui-button-secondary\"></button>\n      <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n    </div>\n  </p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.html":
/*!*************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.html ***!
  \*************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n<div class=\"ddr-box\">\n  <!-- COMMON TOOLBAR -->\n  <div class=\"ddr-toolbar\">\n    <p-toolbar>\n      <div class='ui-toolbar-group-left p-8'>\n        <label class='headerInfo'>{{filterCriteria}}</label>\n      </div>\n    </p-toolbar>\n  </div>\n  <!-- DDR UI SCROLL -->\n  <div class=\"ddruiscroll\" style=\"overflow:auto; height: calc(100vh - 100px);\">\n    <div>\n      <p-accordion class=\"ddr-accordion\">\n        <p-accordionTab header=\"Graphical View\" [selected]=\"false\">\n          <div class=\"ui-g\">\n            <div class=\"ui-g-6\">\n              <div class=\"ddr-graphpanel\" *ngIf=\"showChart; else pieChart\">\n                <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\" style=\"width:  100%; height: 100%; display: block;\"></highcharts-chart>\n              </div>\n              <ng-template #pieChart>No Pie Chart found based on current Filter Settings.</ng-template>\n            </div>\n            <div class=\"ui-g-6\">\n              <div class=\"ddr-graphpanel\" *ngIf=\"showBarChart; else barChart\">\n                <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options1\" style=\"width:  100%; height: 100%; display: block;\"></highcharts-chart>\n              </div>\n              <ng-template #barChart>No RespTime Time Graph found based on current Filter Settings or Data length is\n                less than 5</ng-template>\n            </div>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n\n    <div style=\"overflow:auto\" class=\"main-box\">\n      <p-accordion class=\"ddr-accordion\">\n        <p-accordionTab header=\"Tabular View [Aggregate BusinessTransaction ]\" [selected]=\"true\">\n          <p-toolbar class=\"ui-primary-toolbar\">\n            <div class=\"p-grid p-align-center p-justify-end p-4\">\n              <p-multiSelect class=\"icon-button no-shadow mr-3\" pTooltip=\"Toggle Columns\" [panelStyle]=\"{ minWidth: '200px' }\" [options]=\"columnOptions\" \n                appendTo=\"body\" (onChange)=\"showHideColumn($event)\" dropdownIcon=\"icons8 icons8-columns\"\n                [(ngModel)]=\"visibleCols\"></p-multiSelect>\n                <div class=\"type-search width-180 mx-5\">\n                  <i class=\"right-icon icons8 icons8-search\"></i>\n                  <input type=\"text\" pInputText class=\"w-100-p pl-6\" placeholder=\"Search\" (input)=\"gt.filterGlobal($event.target.value, 'contains')\">\n                </div>\n\n              <div style=\"display: inline-flex;\">\n                  <button pButton icon=\"icons8 icons8-doc\" *ngIf=\"showDownLoadReportIcon\" tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)='downloadReports(\"word\", \"1\")'\n                  pTooltip=\"Download as Word Report\"></button>\n                  <button pButton icon=\"icons8 icons8-spreadsheet-file\" *ngIf=\"showDownLoadReportIcon\" tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)='downloadReports(\"excel\", \"1\")'\n                  pTooltip=\"Download as Excel Report\"></button>\n                  <button pButton icon=\"icons8 icons8-pdf-2\" *ngIf=\"showDownLoadReportIcon\" tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)='downloadReports(\"pdf\", \"1\")'\n                  pTooltip=\"Download as PDF Report\"></button>\n              </div>\n            </div>\n          </p-toolbar>\n          <div style=\"overflow:auto\">\n\n            <p-table #gt [value]=\"dataValue\" scrollHeight=\"190px\" [scrollable]=\"true\" resizableColumns=\"true\" reorderableColumns=\"true\"\n              columnResizeMode=\"expand\" [globalFilterFields]=\"visibleCols\" [customSort]=\"true\" (sortFunction)=\"CustomsortOnColumnsforbtTable($event, dataValue)\">\n              <ng-template pTemplate=\"colgroup\" let-columns>\n                <colgroup>\n                  <ng-container *ngFor=\"let col of btCols\">\n                    <col class=\"width-165\" *ngIf=\"col.action && col.field == 'BusinesTransaction'\">\n                    <col class=\"width-150\" *ngIf=\"col.action && col.field != 'BusinesTransaction'\">\n                  </ng-container>\n                </colgroup>\n              </ng-template>\n              <ng-template pTemplate=\"header\">\n                <tr>\n                  <ng-container *ngFor=\"let col of btCols\">\n                    <th *ngIf=\"col.action\" pResizableColumn pReorderableColumn [pSortableColumn]=\"col.field\">\n                      <span>{{col.header}}\n                        <p-sortIcon *ngIf=\"col.action\" [field]=\"col.field\" ariaLabel=\"Activate to sort\"\n                          ariaLabelDesc=\"Activate to sort in descending order\" ariaLabelAsc=\"Activate to sort in ascending order\">\n                        </p-sortIcon>\n                      </span>\n                    </th>\n                  </ng-container>\n                </tr>\n              </ng-template>\n              <ng-template pTemplate=\"body\" let-node>\n                <tr>\n                  <ng-container *ngFor=\"let col of btCols\">\n                    <td *ngIf=\"col.action\">\n                      <span><a class=\"left activeLink elipseText\" title=\"{{node[col.field]}}\"\n                        *ngIf=\"(col.field == 'BusinesTransaction' && !(node[col.field] == '0'))\"\n                        (click)=\"oenPieChart(node)\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalOverallCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right activeLink\"\n                        *ngIf=\"(col.field == 'TotalOverallCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalNormalCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right activeLink\"\n                        *ngIf=\"(col.field == 'TotalNormalCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '10')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalSlowCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right activeLink\" *ngIf=\"(col.field == 'TotalSlowCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '11')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\"\n                        *ngIf=\"(col.field == 'TotalVerySlowCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right activeLink\"\n                        *ngIf=\"(col.field == 'TotalVerySlowCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '12')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalErrorCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right activeLink\" *ngIf=\"(col.field == 'TotalErrorCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '13')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\"\n                        *ngIf=\"!(col.field == 'BusinesTransaction') && !(col.field == 'TotalOverallCount') && !(col.field == 'TotalNormalCount')\n                   && !(col.field == 'TotalSlowCount') && !(col.field == 'TotalVerySlowCount') && !(col.field == 'TotalErrorCount')\">\n                        {{node[col.field]}} </span>\n                    </td>\n                  </ng-container>\n                </tr>\n              </ng-template>\n              <ng-template pTemplate=\"emptymessage\" let-columns>\n                <tr>\n                    <td [attr.colspan]=\"btCols?.length + 1\" class=\"text-center\">\n                        <span>No Records Found</span>\n                    </td>\n                </tr>\n            </ng-template>\n            </p-table>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n\n      <p-accordion *ngIf=\"\" class=\"ddr-accordion\">\n        <p-accordionTab [header]=\"CustomTable\" [selected]=\"true\">\n          <p-toolbar class=\"ui-primary-toolbar\">\n            <div class=\"p-grid p-align-center p-justify-end p-4\">\n              <p-multiSelect class=\"icon-button no-shadow mr-3\" pTooltip=\"Toggle Columns\" [panelStyle]=\"{ minWidth: '200px' }\" dropdownIcon=\"icons8 icons8-columns\" [options]=\"columnOptions1\"\n                appendTo=\"body\" (onChange)=\"showHideColumnForCustomData($event)\" [(ngModel)]=\"visibleCols1\"></p-multiSelect>\n                <div class=\"type-search width-180 mx-5\">\n                  <i class=\"right-icon icons8 icons8-search\"></i>\n                  <input type=\"text\" pInputText class=\"pl-6 w-100-p\" placeholder=\"Search\" (input)=\"gb.filterGlobal($event.target.value, 'contains')\">\n                </div>\n\n              <div style=\"display: inline-flex;\">\n                <button pButton icon=\"icons8 icons8-doc\" *ngIf=\"showDownLoadReportIcon\" tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)='downloadReports(\"word\", \"2\")'\n                pTooltip=\"Download as Word Report\"></button>\n                <button pButton icon=\"icons8 icons8-spreadsheet-file\" *ngIf=\"showDownLoadReportIcon\" tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)='downloadReports(\"excel\", \"2\")'\n                pTooltip=\"Download as Excel Report\"></button>\n                <button pButton icon=\"icons8 icons8-pdf-2\" *ngIf=\"showDownLoadReportIcon\" tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)='downloadReports(\"pdf\", \"2\")'\n                pTooltip=\"Download as PDF Report\"></button>\n            </div>\n            </div>\n          </p-toolbar>\n          <div style=\"overflow:auto\">\n\n            <p-table #gb [value]=\"dataValue1\" [scrollable]=\"true\" scrollHeight=\"190px\" resizableColumns=\"true\" reorderableColumns=\"true\"\n            columnResizeMode=\"expand\" [globalFilterFields]=\"visibleCols1\" [customSort]=\"true\" (sortFunction)=\"CustomsortOnColumnsforbtTable($event, dataValue1)\">\n            <ng-template pTemplate=\"colgroup\" let-columns>\n              <colgroup>\n                <ng-container *ngFor=\"let col of cols\">\n                  <col class=\"width-165\" *ngIf=\"col.action && col.field == 'BusinesTransaction'\">\n                  <col class=\"width-150\" *ngIf=\"col.action && col.field != 'BusinesTransaction'\">\n                </ng-container>\n              </colgroup>\n            </ng-template>\n              <ng-template pTemplate=\"header\">\n                <tr>\n                  <ng-container *ngFor=\"let col of cols\">\n                    <th *ngIf=\"col.action\" pResizableColumn pReorderableColumn [pSortableColumn]=\"col.field\">\n                      <span>{{col.header}}\n                        <p-sortIcon *ngIf=\"col.action\" [field]=\"col.field\" ariaLabel=\"Activate to sort\"\n                          ariaLabelDesc=\"Activate to sort in descending order\" ariaLabelAsc=\"Activate to sort in ascending order\">\n                        </p-sortIcon>\n                      </span>\n                    </th>\n                  </ng-container>\n                </tr>\n              </ng-template>\n              <ng-template pTemplate=\"body\" let-node>\n                <tr>\n                  <ng-container *ngFor=\"let col of cols\">\n                    <td *ngIf=\"col.action\">\n                      <span class=\"left elipseText\" *ngIf=\"(col.field == 'BusinesTransaction' && !(node[col.field] == ''))\">\n                        {{node[col.field]}} </span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalOverallCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right\" *ngIf=\"(col.field == 'TotalOverallCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}}</a> </span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalNormalCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right\" *ngIf=\"(col.field == 'TotalNormalCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '10')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalSlowCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right\" *ngIf=\"(col.field == 'TotalSlowCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '11')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalVerySlowCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right\"\n                        *ngIf=\"(col.field == 'TotalVerySlowCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '12')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span class=\"right\" *ngIf=\"(col.field == 'TotalErrorCount' && node[col.field] == '0')\">\n                        {{node[col.field]}} </span>\n                      <span><a class=\"right\" *ngIf=\"(col.field == 'TotalErrorCount' && !(node[col.field] == '0'))\"\n                        (click)=\"openFlowpathReport(node, '13')\" pTooltip=\"View Flowpath Report\">\n                        {{node[col.field]}} </a></span>\n                      <span\n                        *ngIf=\"!(col.field == 'BusinesTransaction') && !(col.field == 'TotalOverallCount') && !(col.field == 'TotalNormalCount')\n                         && !(col.field == 'TotalSlowCount') && !(col.field == 'TotalVerySlowCount') && !(col.field == 'TotalErrorCount')\">\n                        {{node[col.field]}}\n                      </span>\n                    </td>\n                  </ng-container>\n                </tr>\n              </ng-template>\n              <ng-template pTemplate=\"emptymessage\" let-columns>\n                <tr>\n                    <td [attr.colspan]=\"cols?.length + 1\" class=\"text-center\">\n                        <span>No Records Found</span>\n                    </td>\n                </tr>\n            </ng-template>\n            </p-table>\n          </div>\n          <div *ngIf='paginationFlag'>\n            <div> {{customOffset+1}} - {{customOffset+customLimit}} of {{customTotalCount}} </div>\n            <p-paginator rows=\"50\" [rowsPerPageOptions]=\"[50,100,200,400]\" pageLinkSize=\"3\"\n              (onPageChange)=\"paginate($event)\"></p-paginator>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n  </div>\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/hotspot/hotspot.component.html":
/*!***********************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/hotspot/hotspot.component.html ***!
  \***********************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div>\n\t<div class=\"ddr-box\">\n<div class=\"p-grid p-align-center p-justify-between ui-table-header\">\n      <div class=\"w-80-p\">\n      <span title=\"{{completeTier}}\">{{filterTierName}}</span>\n      <span title=\"{{completeServer}}\">{{filterServerName}}</span>\n      <span title=\"{{completeInstance}}\">{{filterInstanceName}}</span>\n      <span>{{filterCriteria}}</span>\n    </div>\n  </div>\n    \n<!-- DDR UI SCROLL -->\n<div class=\"ddruiscroll\" [ngStyle]=\"{'height': screenHeight+'px'}\" style=\"overflow:auto;\">\n<div class=\"ui-g-12\">\n  <p-accordion class=\"ddr-accordion\">\n     <p-accordionTab header=\"Thread HotSpot Stats\" [selected]=\"false\">\n     <div class=\"ui-g\">\n      <p-card class=\"ui-g-6\">\n   <div  class=\"ddr-graphpanel\">\n     <highcharts-chart [options]=\"options\" style=\"width: 100%; display: block; overflow: hidden;\" (click)=\"clickHandler($event)\"\n          [Highcharts] = \"highcharts\">\n          </highcharts-chart>\n</div></p-card>\n<p-card class=\"ui-g-6\">\n    <div class=\"ddr-graphpanel\" >\n    <highcharts-chart [options]=\"options1\" style=\"width: 100%; display: block; overflow: hidden;\" \n          [Highcharts] = \"highcharts\">\n          </highcharts-chart>\n  </div>\n</p-card>\n</div>\n     </p-accordionTab>\n  </p-accordion>\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\" (onOpen)=\"onTabOpen($event)\" (onClose)=\"onTabClose($event)\">\n    <p-accordionTab [selected]=\"true\" header=\"Hotspot Summary {{hotspotFilter}} (Total Hotspot:{{hotspotDataCount}})\">\n    <cav-table [value]=\"hotSpotInfo\" [headerRelativePath]=\"relativePathForHotspot\"\n    [scrollable]=\"true\" [responsive] =\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\"\n        scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n    </p-accordionTab>\n  </p-accordion>\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"true\">\n        <p-header>Thread StackTrace <label title = \"{{stackTraceFilterToolTip}}\">{{stackTraceFilter}}</label>   </p-header>\n             <div>\n            <p-treeTable #IP class=\"all-tables\" [value]=\"hotSpotSecInfo\" [columns]=\"columnOptionsForStackTrace\" [scrollable]=\"true\" scrollHeight=\"200px\" selectionMode=\"single\" [(selection)]=\"selectedNode\" (onNodeSelect)=\"onNodeSelect($event)\" >\n\t\t          <ng-template pTemplate=\"caption\">\n                <div class=\"p-grid p-align-center p-justify-end\">\n                  <button pButton icon=\"icons8 icons8-compress\" pTooltip=\"Merge StackTrace\" *ngIf=\"mergeFlag\" tooltipPosition=\"left\"  (click)=\"mergeAllStackTrace()\" placeholder=\"Left\" class=\"btn-icon mx-3\"></button>\n                  <button pButton icon=\"icons8 icons8-menu\" tooltipPosition=\"left\" placeholder=\"Left\"   class=\"btn-icon mx-3\" (click)=\"toggleColumnFilterForHotspot1()\"\n                  pTooltip=\"Column Filter\"></button>\n                  <p-multiSelect appendTo=\"body\" title=\"Toggle columns\" [options]=\"colsForStackTrace\" class=\"icon-button no-shadow\" optionLabel=\"header\"\n                  [(ngModel)]=\"columnOptionsForStackTrace\" selectedItemsLabel=\"{0} columns selected\" dropdownIcon=\"icons8 icons8-columns\"></p-multiSelect> \n                  <input pInputText type=\"text\" icon=\"icons8 icons8-search\" style=\"margin-left: 5px;\"\n                  (input)=\"IP.filterGlobal($event.target.value, 'contains')\" placeholder=\"Search\" />\n                </div>\n              </ng-template>\n              <ng-template pTemplate=\"colgroup\" let-columns>\n                <colgroup>\n                  <ng-container *ngFor=\"let col of columns\">\n                    <col  *ngIf = \"col.action\" [style.width]=\"col.width\" >\n                  </ng-container>\n                </colgroup>\n              </ng-template>\n              <ng-template pTemplate=\"header\" let-rowNode let-columns>\n                  <tr [ttRow]=\"rowNode\">\n                      <th ttResizableColumn *ngFor=\"let col of columns\" ttResizableColumn>\n                          {{col.header}}\n                      </th>\n                  </tr>\n                  <tr *ngIf=\"isEnabledColumnFilterForHotspot1\">\n                    <ng-container *ngFor=\"let col of columns\">\n                        <th style=\"text-overflow: inherit; white-space:normal;\" *ngIf=\"col.action\">\n                            <input class=\"w-100-p\" pInputText type=\"text\" (input)=\"IP.filter($event.target.value, col.field, 'contains')\">\n                        </th>\n                    </ng-container>\n                  </tr>\n              </ng-template>\n\n              <ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\" let-columns=\"columns\">\n                <tr [ttRow]=\"rowNode\">\n                  <td *ngFor=\"let col of columns; let i = index\"\n                    [ngClass]=\"{'text-center': col.field === 'action','text-right': col.field === 'lineNo'|| col.field === 'elapsedTime'||col.field === 'frameNo'||col.field === 'count'}\">\n                    <!-- Normal columns -->\n                    <ng-container *ngIf=\"col.field !== 'action'\">\n                      <span pTooltip=\"{{rowData[col.field]}}\" tooltipPosition=\"bottom\"> <p-treeTableToggler [rowNode]=\"rowNode\"\n                          *ngIf=\"i == 0\"></p-treeTableToggler> {{rowData[col.field]}} </span>\n                    </ng-container>\n                    <!-- Action column -->\n                    <ng-container *ngIf=\"col.field === 'action'\">\n                      <button pButton type=\"button\" class=\"btn-icon\" icon=\"icons8 icons8-eye\" pTooltip=\"View Source Code\"\n                        tooltipPosition=\"left\" (click)=\"onClick(rowNode, $event)\">\n                      </button>\n                    </ng-container>\n                  </td>\n                </tr>\n              </ng-template>\n              <ng-template pTemplate=\"emptymessage\" let-columns>\n                <tr>\n                  <td [attr.colspan]=\"colsForStackTrace.length + 1\" class=\"text-center\">\n                    <span *ngIf=\"empty\">No Records Found</span>\n                  </td>\n                </tr>\n              </ng-template>\n          </p-treeTable>\n         </div>\n    </p-accordionTab>\n  </p-accordion>\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"false\">\n        <p-header>Integration Point Call(s) <label title = \"{{stackTraceFilterToolTip}}\">{{stackTraceFilter}}</label>   </p-header>\n        <div *ngIf=\"!aggCase; else aggTable\">\n            <cav-table [value]=\"IPInfo\" [headerRelativePath]=\"relativePathForIP\" \n            [scrollable]=\"true\" [responsive] =\"true\"\n            (clickButtonEvent)=\"clickButtonEvent($event)\"\n                scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n        </div>\n      <ng-template #aggTable>\n        <app-agg-ip-info [aggIpInfo]=\"aggIpInfo\" [renamebackendNameMap]=\"renamebackendNameMap\" [actualBackendNameMap]=\"actualBackendNameMap\" [backendSubTypeNameMap]=\"backendSubTypeNameMap\" [filterCriteriaagg]=\"filterCriteriaagg\" [showWarning]=false [maxFlowPath]= 0></app-agg-ip-info>\n        </ng-template>\n    </p-accordionTab>\n  </p-accordion>\n</div>\n</div>\n</div>\n<p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '40vw'}\" header=\"Query Details\" [(visible)]=\"displayPopUp\" modal=\"modal\" appendTo = \"body\" responsive=\"true\">\n    <div class=\"modalPopUp\">\n     <table width=\"500\" border=\"0\" cellspacing=\"1\">\n       <tbody *ngFor=\"let data of rowData\">\n         <tr><td><b>Integration Point</b></td><td>{{data.IPname}}</td></tr>\n         <tr><td><b>Discovered Name</b></td><td>{{data.DiscoveredIPName}}</td></tr>\n         <tr><td><b>Type</b></td><td>{{data.Type}}</td></tr>\n         <tr><td><b>Start Time</b></td><td>{{data.StartTime}}</td></tr>\n           <tr><td><b>Duration(ms)</b></td><td>{{data.Duration}}</td></tr>\n           <tr><td><b>Status</b></td><td>{{data.Status}}</td></tr>\n           <tr><td><b>Query</b></td><td><textarea pInputTextarea rows=\"8\" cols=\"40\">{{data.Query}}</textarea></td></tr>\n        </tbody> \n     </table>\n    </div>\n  </p-dialog>\n\n<p-dialog class=\"secondary-dialog\" header=\"Source Code\" [modal]=\"true\" [(visible)]=\"showSourceCode\" [resizable]=\"true\"\n  [style]=\"{'max-width':'90%', 'max-height':'90%'}\">\n\n  <div *ngIf=\"!loader; else loading\">\n    <pre #preContent id=\"codeBlock\" [innerHTML]=\"methodBody\"></pre>\n  </div>\n\n  <ng-template #loading>\n    <div class=\"p-text-center\">Loading source code...</div>\n  </ng-template>\n\n  <p-footer class=\"p-grid p-justify-end\">\n    <button pButton type=\"button\" label=\"Close\" (click)=\"showSourceCode = false\"></button>\n  </p-footer>\n</p-dialog>\n  \n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.html":
/*!***********************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.html ***!
  \***********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n\n\n<div>\n    <div class=\"ddr-box\">\n        <!-- COMMON TOOLBAR -->\n       \n    <div class=\"p-grid p-align-center p-justify-between ui-table-header\">\n        <div class=\"w-80-p\">\n            <span title=\"{{filterCriteriaToolTip}}\">{{filterCriteria}}</span>\n        </div>\n    </div>\n        <!-- COMMON BOX SCROLLLBAR -->\n        <div class=\"ddruiscroll\" [ngStyle]=\"{'height': 'calc(100vh - 230px)'}\" style=\"overflow:auto;\">\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab header=\"HTTP Information\" [selected]=\"isHttpInfoData\">\n                    <div>\n                        <cav-table [value]=\"httpInfoArr\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" [responsive]=\"true\"\n                        scrollHeight=\"calc(100vh - 240px)\" ></cav-table>\n\n                        <div style=\"border: 1px solid #9eadbd;min-height: 25px;padding: 4px;word-break: break-all;margin-top: 5px;\">\n                            <div style=\"font-size:10px;max-width:100%\"> {{ForFooterUrl}} </div>\n                        </div>\n                    </div>\n                </p-accordionTab>\n            </p-accordion>\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab header=\"Request Headers\" [selected]=\"isRequestHeaders\">\n                    <div>\n                        <cav-table [value]=\"httpRequestArr\" [headerRelativePath]=\"relativePathForCols\" [scrollable]=\"true\" [responsive]=\"true\"\n                        scrollHeight=\"calc(100vh - 240px)\" ></cav-table>\n\n                    </div>\n                </p-accordionTab>\n            </p-accordion>\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab header=\"Request Body\" [selected]=\"isRequestBody\" *ngIf=\"!otelMode\">\n                    <div>\n                        <textarea *ngIf=\"httpRequestArrBody[0]\" pInputTextarea class=\"ui-inputtext ui-corner-all ui-state-default ui-widget\" style=\"width:100%;resize:none;\" rows=\"10\"\n                        readonly>{{httpRequestArrBody[0]?.value}}</textarea>\n                    </div>\n                </p-accordionTab>\n            </p-accordion>\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab header=\"Response Headers\" [selected]=\"isResponseHeaders\">\n                    <div>\n                        <cav-table [value]=\"httpResponseArr\" [headerRelativePath]=\"relativePathForCols\" [responsive]=\"true\"\n                        scrollHeight=\"calc(100vh - 240px)\" ></cav-table>\n                        \n                    </div>\n                </p-accordionTab>\n            </p-accordion>\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab header=\"Response Body\" [selected]=\"isResponseBody\" *ngIf=\"!otelMode\">\n                    <div>\n                        <textarea *ngIf=\"httpResponseArrBody[0]\" pInputTextarea class=\"ui-inputtext ui-corner-all ui-state-default ui-widget\" style=\"width:100%;resize:none;\" rows=\"10\"\n                        readonly>{{httpResponseArrBody[0]?.value}}</textarea>\n                    </div>\n                </p-accordionTab>\n            </p-accordion>\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab header=\"Custom Data\" [selected]=\"isCustomData\" *ngIf=\"!otelMode\">\n                    <div>\n                        <cav-table [value]=\"httpDerivedArr\" [headerRelativePath]=\"relativePathForCols\" [scrollable]=\"true\" [responsive]=\"true\"\n                        scrollHeight=\"calc(100vh - 240px)\" ></cav-table>\n                    </div>\n                </p-accordionTab>\n            </p-accordion>\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab header=\"Session Data\" [selected]=\"isSessionData\" *ngIf=\"!otelMode\">\n                    <div>\n                        <cav-table [value]=\"httpSessionArr\" [headerRelativePath]=\"relativePathForCols\" [scrollable]=\"true\" [responsive]=\"true\"\n                        scrollHeight=\"calc(100vh - 240px)\" ></cav-table>\n                     </div>\n                </p-accordionTab>\n            </p-accordion>\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab header=\"Condition Data\" [selected]=\"isConditionData\" *ngIf=\"!otelMode\">\n                    <div>\n                        <cav-table [value]=\"httpConditionArr\" [headerRelativePath]=\"relativePathForCols\" [responsive]=\"true\"\n                        scrollHeight=\"calc(100vh - 240px)\" ></cav-table>\n                     </div>\n                </p-accordionTab>\n            </p-accordion>\n        </div>\n \n    </div>\n</div>\n  <p-dialog class=\"secondary-dialog foterDialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" height=\"120\" width=\"600\" > \n  <p-header>\n      <i class=\"icons8 icons8-info\" style=\"color:red\"></i>\n      <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n  </p-header>  \n  <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n  <p-footer>\n    <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" class=\"ui-button-rounded ui-button-secondary\"></button>\n  <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n  </p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ip-stat/ip-stat.component.html":
/*!***********************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ip-stat/ip-stat.component.html ***!
  \***********************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-30\"></i> <span class=\"font-30\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"flowmap-box\" id=\"flowmap-box\">\n\n  <div class=\"ddr-toolbar\">\n    <p-toolbar>\n      <div class=\"p-grid p-align-center p-justify-between p-4\">\n      <div>\n        {{headerFilter}}\n      </div>\n      <div class=\"p-grid p-align-center\">\n        <button pButton class=\"btn-light-secondary\" pTooltip=\"Apply custom date\" (click)=\"openTimeFilter()\">{{timeLabel}}</button>\n      </div>\n    </div>\n    </p-toolbar>\n  </div>\n\n\n   <div class=\"p-6\">  \n      <div *ngIf=\"showGraph\" class=\"mb-12\">\n      <p-toolbar class=\"ui-primary-toolbar\" styleClass=\"border-5 border-all\">\n        <div class=\"py-12 px-6 font-weight-600\">IP Stat {{IPStatHeader}}</div>\n      </p-toolbar>\n      <div class=\"border-5 border-all\" style=\"height:220px\">\n        <div class=\"ui-g-12\">\n          <div class=\"ui-g-4\">\n            <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"res\"></highcharts-chart>\n          </div>\n          <div class=\"ui-g-4\">\n            <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"cps\"></highcharts-chart>\n          </div>\n          <div class=\"ui-g-4\">\n            <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"err\"></highcharts-chart>\n          </div>\n        </div>\n      </div>\n      </div>\n      <cav-table [value]=\"ipData\" [scrollable]=\"true\" [responsive]=\"true\" [headerRelativePath]=\"relativePath\"\n        scrollHeight=\"calc(100vh - 510px)\" (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>\n\n</div>\n</div>\n\n<p-dialog styleClass=\"secondary-dialog\" header=\"Apply Time Period\" appendTo=\"body\" [(visible)]=\"display\" [style]=\"{width: '550px'}\"\n  [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n  <div class=\"p-grid \" *ngIf=\"display\">\n    <span class=\"p-grid w-100-p p-align-center\">\n      <span class=\"p-col-2\">\n        Time Period:\n      </span>\n      <span class=\"p-col-10\">\n        <p-dropdown [options]=\"timeFilterOptions\"  appendTo=\"body\" [showTransitionOptions]=\"'250ms'\" [(ngModel)]=\"selectedValue\"\n        [style]=\"{'min-width':'100%'}\" [hideTransitionOptions]=\"'250ms'\" (onChange)=\"openDateFilter($event)\" placeholder={{timeLabel}}></p-dropdown>\n      </span>\n    </span>\n    <div class=\"p-grid p-align-center\">\n      <ng-container *ngIf=\"eventDayFilter\">\n        <div class=\"p-col-2\">\n          Select Day\n        </div>\n            <div class=\"p-col-5\">\n              <p-dropdown #eventDay [options]=\"_eventDaysList\" appendTo=\"body\" [(ngModel)]=\"_selectedEventDay\"\n                (onChange)=\"dateAjaxCall(eventDay.selectedOption.value, eventYear.selectedOption.value)\">\n              </p-dropdown>\n            </div>\n\n            <div class=\"p-col-5\">\n              <p-dropdown #eventYear [options]=\"_yearList\" appendTo=\"body\" [(ngModel)]=\"_selectedEventDayYear\"\n                (onChange)=\"dateAjaxCall(eventDay.selectedOption.value, eventYear.selectedOption.value)\">\n              </p-dropdown>\n            </div>\n          </ng-container>\n      \n      <ng-container *ngIf=\"commonFilter || customFilterDisplay\">\n        <div class=\"p-col-2\">\n          From\n        </div>\n        \n          <div class='p-col-5'>\n            <p-calendar [disabled]=\"_disabled\" inputStyleClass=\"w-100-p\" readonlyInput=\"true\" appendTo=\"body\"\n              dateFormat=\"mm/dd/yy\" [monthNavigator]=\"true\" [yearNavigator]=\"true\" yearRange=\"1970:2030\"\n              [(ngModel)]=\"startDate\"></p-calendar>\n          </div>\n          <div class='p-col-5 p-align-center p-grid p-nogutter'>\n            <div class=\"p-col\">\n              <input pInputText type='text' class=\"w-100-p\" title='HH' [(ngModel)]=\"startHours\" placeholder='HH'\n                autocomplete='off' (keypress)='valEnteredKeyN($event);' tabindex='1' maxlength='2'>\n            </div>\n            <div class=\"p-col-fixed font-weight-700 px-6\">:</div>\n            <div class=\"p-col\">\n              <input pInputText class=\"w-100-p\" type='text' title='MM' (keypress)='valEnteredKeyN($event);'\n                [(ngModel)]=\"startMinutes\" placeholder='MM' autocomplete='off' tabindex='1' maxlength='2'>\n            </div>\n            <div  class=\"p-col-fixed font-weight-700 px-6\">:</div>\n            <div class=\"p-col\">\n              <input class=\"w-100-p\" class=\"w-100-p\" pInputText type='text' title='SS'\n                (keypress)='valEnteredKeyN($event);' [(ngModel)]=\"startSeconds\" placeholder='SS' autocomplete='off'\n                tabindex='1' maxlength='2'>\n            </div>\n          </div>\n        \n\n        <div class=\"p-col-2\">\n          To\n        </div>\n          <div class='p-col-5'>\n            <p-calendar [disabled]=\"_disabled\" inputStyleClass=\"w-100-p\" readonlyInput=\"true\" appendTo=\"body\"\n              dateFormat=\"mm/dd/yy\" [monthNavigator]=\"true\" [yearNavigator]=\"true\" yearRange=\"1970:2030\"\n              [(ngModel)]=\"endDate\"></p-calendar>\n          </div>\n          <div class='p-col-5 p-align-center p-grid p-nogutter'>\n            <div class=\"p-col\">\n              <input pInputText type='text' class=\"w-100-p\" title='HH' [(ngModel)]=\"endHours\" placeholder='HH'\n                autocomplete='off' (keypress)='valEnteredKeyN($event);' tabindex='1' maxlength='2'>\n            </div>\n            <div  class=\"p-col-fixed font-weight-700 px-6\">:</div>\n            <div class=\"p-col\">\n              <input pInputText class=\"w-100-p\" type='text' title='MM' (keypress)='valEnteredKeyN($event);'\n                [(ngModel)]=\"endMinutes\" placeholder='MM' autocomplete='off' tabindex='1' maxlength='2'>\n            </div>\n            <div  class=\"p-col-fixed font-weight-700 px-6\">:</div>\n            <div class=\"p-col\">\n              <input class=\"w-100-p\" class=\"w-100-p\" pInputText type='text' title='SS'\n                (keypress)='valEnteredKeyN($event);' [(ngModel)]=\"endSeconds\" placeholder='SS' autocomplete='off'\n                tabindex='1' maxlength='2'>\n            </div>\n          </div>\n        \n      </ng-container>\n    </div>\n  </div>\n  <p-footer>\n    <div class=\"p-grid p-align-center p-justify-end\">\n        <button pButton type=\"button\"  label=\"Submit\" (click)=\"submitFilterValue()\" class=\"ui-button-rounded\"></button>\n    </div>\n  </p-footer>\n  \n</p-dialog>\n<p-dialog class=\"secondary-dialog\" [style]=\"{width: '25vw'}\" [(visible)]=\"isIPByRespTime\" [responsive]='true' [resizable]='false' [modal]=\"true\"\n  [positionTop]='140' minHeight='120'>\n  <p-header>Integration Point By Response Time</p-header>\n  <div class=\"mt-10\">\n    <span style=\"text-align:center;\">IP Response Time(ms) >=</span>\n    <span> <input id=\"input\" (keypress)=\"validateQty($event)\" type=\"text\" size=\"5\" pInputText [(ngModel)]=\"responseTime\"\n        style='float:right'> </span>\n  </div>\n  <p-footer>\n    <button pButton type=\"button\" label=\"Cancel\" (click)=\"isIPByRespTime=false\" class=\"ui-button-rounded ui-button-secondary\"></button>\n      <button pButton type=\"button\" label=\"Apply\" (click)=\"openFPByIntegrationReport(resData, 'FPByResTime')\" class=\"ui-button-rounded\"></button>\n  </p-footer>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ip-summary/ip-summary.component.html":
/*!*****************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ip-summary/ip-summary.component.html ***!
  \*****************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n<div class=\"ddr-toolbar\">\n  <div class=\"p-grid p-align-center p-justify-between py-3 ui-table-header\">\n    <div class=\"w-80-p\">\n      <span title=\"{{completeTier}}\">{{filterTierName}}</span>\n      <span title=\"{{completeServer}}\">{{filterServerName}}</span>\n      <span title=\"{{completeInstance}}\">{{filterInstanceName}}</span>\n      <span>{{filterCriteria}}</span>\n      <span title=\"{{completeIpName}}\">{{filterIpName}}</span>\n    </div>\n    <div>\n      <p-menu #downloadMenu [popup]=\"true\" [model]=\"downloadOptions\" [showTransitionOptions]=\"'0ms'\"\n        [hideTransitionOptions]=\"'0ms'\" appendTo=\"body\"></p-menu>\n      <button type=\"button\" pButton class=\"btn-icon\" (click)=\"downloadMenu.toggle($event);\"\n        icon=\"icons8 icons8-installing-updates\" pTooltip=\"Download\">\n      </button>\n\n      <button pButton icon=\"icons8 icons8-filter\" class=\"btn-icon\" (click)=\"showflowpathConfDialogue()\"\n        pTooltip=\"Filters\"></button>\n      <span *ngIf=\"isAgent\">\n        <button pButton icon=\"cav debug-trace font-18\" *ngIf=\"displayAutoInst\" class=\"btn-icon\"\n          (click)=\"openAutoInstDialog()\" pTooltip=\"Click to start Dynamic Diagnostics\"></button>\n      </span>\n    </div>\n  </div>\n</div>\n<!-- COMMON BOX SCROLLLBAR -->\n<div class=\"ddruiscroll\" [ngStyle]=\"{'height': screenHeight+'px'}\" style=\"overflow:auto;\">\n<p-accordion class=\"accordHeader\" [multiple]=\"true\">\n  <p-accordionTab header=\"BT Callout Summary\" [selected]=\"true\">\n    <cav-table #cavTableRef [value]=\"btCallOutInfoAgg\" [headerRelativePath]=\"relativePathForCalloutSummaryTable\"\n      [scrollable]=\"true\" [responsive]=\"true\" scrollHeight=\"calc(100vh - 240px)\"\n      [selection]=\"selectedRowInfo\" (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>\n  </p-accordionTab>\n  <p-accordionTab header=\"BT Callout Details {{selectedBT}}{{TotalCalloutcount}}\" [selected]=\"true\">\n    <div *ngIf=\"!aggCase; else aggTable\">\n      <div class=\"p-grid p-align-center p-justify-between py-5\">\n        <div class=\"ui-toolbar-group-left\" style=\"text-align: left\">\n          <div *ngIf=\"showWarning\">\n            <button pButton type=\"button\" class=\"btn-icon\" icon=\"icons8 icons8-error\"></button>\n            <label>\n              <b>Showing for top {{this.formatter(_maxFlowpathToProcess)}} Slowest Flowpath(s).To see more or less apply\n                filter Settings.</b>\n            </label>\n          </div>\n        </div>\n      </div>\n      <cav-table [value]=\"btCalloutInfoInd\" [headerRelativePath]=\"relativePathForCalloutDetailTable\" [scrollable]=\"true\"\n        [responsive]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\"\n        scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n    </div>\n    <ng-template #aggTable>\n      <app-agg-ip-info *ngIf=\"otelMode\" [aggIndInfoOtel]=\"calloutDetailDataArray\" [fpRowData]=\"columnData\" ></app-agg-ip-info>\n      <app-agg-ip-info *ngIf=\"!otelMode\" [aggIpInfo]=\"aggIpInfo\" [renamebackendNameMap]=\"renamebackendNameMap\"\n        [actualBackendNameMap]=\"actualBackendNameMap\" [backendSubTypeNameMap]=\"backendSubTypeNameMap\"\n        [showWarning]=\"showWarning\" [maxFlowPath]=\"_maxFlowpathToProcess\" (calloutCount)=\"assignCallOutCount($event)\"\n        [filterCriteriaagg]=\"filterCriteriaagg\" [urlNameIP]=\"urlNameIP\" [urlIndexIP]=\"urlIndexIP\"></app-agg-ip-info>\n    </ng-template>\n  </p-accordionTab>\n</p-accordion>\n</div>\n\n<p-dialog class=\"secondary-dialog\" [(visible)]=\"showFPConfDia\" width=\"300\" height=\"150\" [closable]=\"false\"\n  [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n  <p-header>\n    <span>Filters</span>\n    <span style=\"float:right;cursor: pointer;\" id=\"myBtn\" (click)=\"closeDialog()\">X</span>\n  </p-header>\n  <div style=\"margin-top:10px;\">\n    <label><b><span title=\"Number of Maximum Flowpath(s) of current BT to be targeted for callout details.\">Max\n          Flowpath(s) </span></b> </label>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type=\"text\"\n      (keypress)=\"valEnteredKeyN($event)\" pInputText [(ngModel)]=\"_maxFlowpathToProcess\" /><br /><br />\n  </div>\n  <p-footer>\n    <button pButton type=\"button\" (click)=\"applyFlowpathConfiguration()\" label=\"Apply\"></button>\n  </p-footer>\n</p-dialog>\n\n<p-dialog class=\"secondary-dialog foterDialog\" header=\"Dynamic Diagnostics Configuration\" [resizable]=\"false\"\n  *ngIf=\"showAutoInstrPopUp\" [(visible)]=\"showAutoInstrPopUp\" modal=\"modal\" [style]=\"{width: '900px'}\"\n  [contentStyle]=\"{'max-height':'500px'}\" responsive=\"true\">\n  <app-dynamic-diagnostics (resultAfterStart)=\"startInstrumentation($event)\" (closeAIDDGui)=\"closeAIDDDialog($event)\"\n    [passAIDDSettings]=\"argsForAIDDSetting\"></app-dynamic-diagnostics>\n</p-dialog>\n\n<p-dialog class=\"secondary-dialog foterDialog\" [(visible)]=\"showMessage\" width=\"290\" height=\"100\" [closable]=\"false\"\n  [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n  <p-header>\n    <span>Message</span>\n    <span style=\"float:right;cursor: pointer;\" id=\"myBtn\" (click)=\"closeMessageDialog()\">X</span>\n  </p-header>\n  <span style=\"font-size:14px\">Please Wait. This operation might take a few minutes.</span>\n  <p-dialog class=\"secondary-dialog\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false' [responsive]=\"true\"\n    height=\"120\" width=\"600\">\n    <p-header>\n      <i class=\"icons8 icons8-info\" style=\"color:red\"></i>\n      <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n    </p-header>\n    <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n    <p-footer>\n      <button pButton type=\"button\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"\n        class=\"ui-button-rounded ui-button-secondary\"></button>\n      <button pButton type=\"button\" (click)=\"waitQuery();\" label=\"Wait\" class=\"ui-button-rounded\"></button>\n    </p-footer>\n  </p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/metadata/metadata.component.html":
/*!*************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/metadata/metadata.component.html ***!
  \*************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<p-blockUI [blocked]=\"loading\"></p-blockUI>\r\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" />\r\n<div class=\"ddruiscroll\" [ngStyle]=\"{'height': screenHeight + 67 +'px'}\" style=\"overflow:auto;\">\r\n    <p-accordion (onOpen)=\"onTopologyEntityTab()\" (onClose)=\"onCloseMetadataTab()\">\r\n        <p-accordionTab header=\"Metadata\" [selected]=\"metadataAccordion\">\r\n            <div class=\"ui-g-12\">\r\n                <div class=\"ui-g-4\">\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:90vh;\">\r\n                        <div class=\"ui-toolbar ui-widget ui-widget-header ui-corner-all ui-helper-clearfix\">\r\n                            <button _ngcontent-c31=\"\" label=\"Apply\" pbutton=\"\" type=\"button\"\r\n                                class=\"ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only\"\r\n                                style=\"float: right;\" (click)=\"refreshTSI()\">\r\n                                <span class=\"ui-button-text ui-clickable\">\r\n                                    <i class=\"fa fa-refresh\" aria-hidden=\"true\" title=\"Refresh\"></i>\r\n                                </span>\r\n                            </button>\r\n                            <div class=\"group-left\">\r\n                                <span>Tier , Server and Instance Tables</span>\r\n                            </div>\r\n                        </div>\r\n                        <p-table class=\"scen-table \" [value]=\"tierMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                        [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of metaTier\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of metaTier\">\r\n                                    <td *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n                        <!-- <p-dataTable class=\"scen-table \" [value]=\"tierMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                            resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of metaTier\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total Tiers {{tierRecord}}</span>\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"serverMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                        [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of metaServer\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of metaServer\">\r\n                                    <td *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"serverMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                            resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of metaServer\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n\r\n                        <span>Total Servers {{serverRecord}}</span>\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"instanceMetadata\" [sortOrder]=\"-1\"\r\n                        selectionMode=\"single\" [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of metaInstance\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of metaInstance\">\r\n                                    <td *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"instanceMetadata\" [sortOrder]=\"-1\"\r\n                            selectionMode=\"single\" resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of metaInstance\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n\r\n                        <span>Total Instances {{instanceRecord}}</span>\r\n\r\n                    </div>\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:80vh;\">\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"backendMetadata\" [sortOrder]=\"-1\"\r\n                        selectionMode=\"single\" [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of backend\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of backend\">\r\n                                    <td *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"backendMetadata\" [sortOrder]=\"-1\"\r\n                            selectionMode=\"single\" resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of backend\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total Backends {{bRecord}} </span>\r\n                    </div>\r\n\r\n                </div>\r\n                <div class=\"ui-g-4\">\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:100vh;\">\r\n                        <div class=\"ui-toolbar ui-widget ui-widget-header ui-corner-all ui-helper-clearfix\">\r\n                            <button _ngcontent-c31=\"\" label=\"Apply\" pbutton=\"\" type=\"button\"\r\n                                class=\"ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only\"\r\n                                style=\"float: right;\" (click)=\"refreshPCMB()\">\r\n                                <span class=\"ui-button-text ui-clickable\">\r\n                                    <i class=\"fa fa-refresh\" aria-hidden=\"true\" title=\"Refresh\"></i>\r\n                                </span>\r\n                            </button>\r\n                            <div class=\"group-left\">\r\n                                <span>Package , Class , Method and Backend Tables</span>\r\n                            </div>\r\n                        </div>\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"packageMetadata\" [totalRecords]=\"ptRecord\"\r\n                        [sortOrder]=\"-1\" selectionMode=\"single\" [resizableColumns]=\"true\" [scrollable]=\"true\"\r\n                        scrollHeight=\"115px\" [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\"\r\n                        [paginator]=\"true\" [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of packageM\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of packageM\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"packageMetadata\" [totalRecords]=\"ptRecord\"\r\n                            [sortOrder]=\"-1\" selectionMode=\"single\" resizableColumns=\"true\" [scrollable]=\"true\"\r\n                            scrollHeight=\"115px\" [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\"\r\n                            [paginator]=\"true\" [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of packageM\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total Package {{ptRecord}} </span>\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"classMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                        [resizableColumns]=\"true\" scrollable=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of classM\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of classM\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"classMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                            resizableColumns=\"true\" scrollable=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of classM\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width+'px','text-align': col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n\r\n                        <span>Total Class {{cRecord}} </span>\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"methodMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                        [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of method\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of method\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"methodMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                            resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of method\">\r\n\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n\r\n                        <span>Total Methods {{mRecord}} </span>\r\n\r\n                    </div>\r\n                </div>\r\n                <div class=\"ui-g-4\">\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:80vh;\">\r\n                        <div class=\"ui-toolbar ui-widget ui-widget-header ui-corner-all ui-helper-clearfix\">\r\n                            <button _ngcontent-c31=\"\" label=\"Apply\" pbutton=\"\" type=\"button\"\r\n                                class=\"ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only\"\r\n                                style=\"float: right;\" (click)=\"refreshTC()\">\r\n                                <span class=\"ui-button-text ui-clickable\">\r\n                                    <i class=\"fa fa-refresh\" aria-hidden=\"true\" title=\"Refresh\"></i>\r\n                                </span>\r\n                            </button>\r\n                            <div class=\"group-left\">\r\n                                <span>Tables Records Table</span>\r\n                            </div>\r\n                        </div>\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"tableMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                        [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of metaTable\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of metaTable\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"tableMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                            resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of metaTable\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total Tables {{tRecord}}</span>\r\n                    </div>\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:80vh;\">\r\n                        <div class=\"ui-toolbar ui-widget ui-widget-header ui-corner-all ui-helper-clearfix\">\r\n                            <button _ngcontent-c31=\"\" label=\"Apply\" pbutton=\"\" type=\"button\"\r\n                                class=\"ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only\"\r\n                                style=\"float: right;\" (click)=\"refreshBT()\">\r\n                                <span class=\"ui-button-text ui-clickable\">\r\n                                    <i class=\"fa fa-refresh\" aria-hidden=\"true\" title=\"Refresh\"></i>\r\n                                </span>\r\n                            </button>\r\n                            <div class=\"group-left\">\r\n                                <span>BT Table</span>\r\n                            </div>\r\n                        </div>\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"btMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                        [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of businessT\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of businessT\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"btMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                            resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of businessT\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total BT {{btRecord}} </span>\r\n                    </div>\r\n\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:80vh;\">\r\n                        <div class=\"ui-toolbar ui-widget ui-widget-header ui-corner-all ui-helper-clearfix\">\r\n                            <button _ngcontent-c31=\"\" label=\"Apply\" pbutton=\"\" type=\"button\"\r\n                                class=\"ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only\"\r\n                                style=\"float: right;\" (click)=\"refreshQP()\">\r\n                                <span class=\"ui-button-text ui-clickable\">\r\n                                    <i class=\"fa fa-refresh\" aria-hidden=\"true\" title=\"Refresh\"></i>\r\n                                </span>\r\n                            </button>\r\n                            <div class=\"group-left\">\r\n                                <span>Query Table</span>\r\n                            </div>\r\n                        </div>\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"pqMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                        [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                        [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of pquery\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of pquery\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"pqMetadata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                            resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of pquery\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total Query {{qRecord}} </span>\r\n                    </div>\r\n                </div>\r\n\r\n            </div>\r\n            <hr noshade>\r\n        </p-accordionTab>\r\n    </p-accordion>\r\n    <p-accordion (onOpen)=\"onMappingTabOpen()\" (onClose)=\"onCloseMappingTab()\">\r\n        <p-accordionTab header=\"Mapping\" [selected]=\"mappingAccordion\">\r\n            <div class=\"ui-g-12\">\r\n                <div class=\"ui-g-4\">\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:80vh;\">\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"tsiTierMapdata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                        [(selection)]=\"selectedTierRow\" [resizableColumns]=\"true\" [scrollable]=\"true\"\r\n                        scrollHeight=\"110px\" [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\"\r\n                        (onRowClick)='onRowClickTier($event)' [paginator]=\"true\" [rows]=\"10\" [pageLinks]=\"3\"\r\n                        [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of tsiTier\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of tsiTier\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"tsiTierMapdata\" [sortOrder]=\"-1\" selectionMode=\"single\"\r\n                            [(selection)]=\"selectedTierRow\" resizableColumns=\"true\" [scrollable]=\"true\"\r\n                            scrollHeight=\"110px\" [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\"\r\n                            (onRowClick)='onRowClickTier($event)' [paginator]=\"true\" [rows]=\"10\" [pageLinks]=\"3\"\r\n                            [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of tsiTier\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total Tiers {{tsitRecord}} </span>\r\n                    </div>\r\n                </div>\r\n                <div class=\"ui-g-4\">\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:80vh;\">\r\n\r\n                        <p-table class=\"scen-table\" [value]=\"tsiServerMapdata\" [sortOrder]=\"-1\"\r\n                        selectionMode=\"single\" [(selection)]=\"selectedServerRow\" [resizableColumns]=\"true\"\r\n                        [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\"\r\n                        (onRowClick)='onRowClickServer($event)' [paginator]=\"true\" [rows]=\"10\" [pageLinks]=\"3\"\r\n                        [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of tsiServer\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of tsiServer\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"tsiServerMapdata\" [sortOrder]=\"-1\"\r\n                            selectionMode=\"single\" [(selection)]=\"selectedServerRow\" resizableColumns=\"true\"\r\n                            [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\"\r\n                            (onRowClick)='onRowClickServer($event)' [paginator]=\"true\" [rows]=\"10\" [pageLinks]=\"3\"\r\n                            [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of tsiServer\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total Map Servers {{tsisRecord}} </span>\r\n                    </div>\r\n                </div>\r\n                <div class=\"ui-g-4\">\r\n                    <div class=\"ddr-box\" id=\"DDR-BOX\" style=\"max-height:80vh;\">\r\n                        <p-table class=\"scen-table\" [value]=\"tsiServerMapdata\" [sortOrder]=\"-1\"\r\n                        selectionMode=\"single\" [(selection)]=\"selectedServerRow\" [resizableColumns]=\"true\"\r\n                        [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                        [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\"\r\n                        (onRowClick)='onRowClickServer($event)' [paginator]=\"true\" [rows]=\"10\" [pageLinks]=\"3\"\r\n                        [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                        <ng-template pTemplate=\"header\">\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of tsiInstance\">\r\n                                    <th pResizableColumn *ngIf=\"col.action\"> \r\n                                        <span >{{ col.header }}</span>\r\n                                    </th>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        <ng-template pTemplate=\"body\" let-node>\r\n                            <tr>\r\n                                <ng-container *ngFor=\"let col of tsiInstance\">\r\n                                    <td [ngStyle]=\"{'width': col.width +'px','text-align':col.align}\" *ngIf=\"col.action\">\r\n                                        {{node[col.field]}}\r\n                                    </td>\r\n                                </ng-container>\r\n                            </tr>\r\n                        </ng-template>\r\n                        </p-table>\r\n                        <!-- <p-dataTable class=\"scen-table\" [value]=\"tsiInstanceMapdata\" [sortOrder]=\"-1\"\r\n                            selectionMode=\"single\" resizableColumns=\"true\" [scrollable]=\"true\" scrollHeight=\"115px\"\r\n                            [style]=\"{'height':'auto','overflow-x':'hidden','overflow':'unset'}\" [paginator]=\"true\"\r\n                            [rows]=\"10\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[10,20,30,40,50]\">\r\n                            <div *ngFor=\"let col of tsiInstance\">\r\n                                <p-column *ngIf=\"col.action\" [field]=\"col.field\" [header]=\"col.header\"\r\n                                    [sortable]=\"col.sortable\" [filterMatchMode]='contains'\r\n                                    [style]=\"{'width': col.width +'px','text-align':col.align}\" [filter]=\"col.filter\">\r\n                                </p-column>\r\n                            </div>\r\n                        </p-dataTable> -->\r\n                        <span>Total Map Instances {{tsiiRecord}} </span>\r\n                    </div>\r\n                </div>\r\n            </div>\r\n            <hr noshade>\r\n        </p-accordionTab>\r\n    </p-accordion>\r\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/method-call-info/method-call-info.component.html":
/*!*****************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/method-call-info/method-call-info.component.html ***!
  \*****************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<app-cav-loader *ngIf=\"loader\"></app-cav-loader>\n<div class =\"p-grid\">\n<div class=\"w-100-p px-6\">\n  <div class=\"p-grid p-align-center\">\n    <ng-container *ngFor=\"let criteria of filterCriteriaArray\">\n      <span class=\"bg-secondary-200 d-bg-secondary-base rounded-3 py-5 px-6 m-3\">{{criteria}}</span>\n    </ng-container>\n  </div>\n</div>\n\n<div class=\"p-6 w-100-p\">\n  <div class=\"p-grid p-align-center p-justify-between w-100-p bg-secondary-100 rounded-4 d-bg-secondary-base\">\n    \n    <!-- Left -->\n    <p-button\n      type=\"button\"\n      [icon]=\"isAllExpanded ? 'icons8 icons8-collapse-arrow' : 'icons8 icons8-expand-arrow'\"\n      styleClass=\"btn-icon\"\n      [matTooltip]=\"isAllExpanded ? 'Collapse All' : 'Expand All'\"\n      (click)=\"toggleExpandAll()\">\n    </p-button>\n\n    <!-- Right: Search + Download -->\n    <div style=\"display: flex; align-items: center; gap: 4px; margin-left: auto;\">\n\n      <!-- Download -->\n      <div class=\"relative\" style=\"display:inline-block\" (click)=\"$event.stopPropagation()\">\n        <button pButton type=\"button\" icon=\"icons8 icons8-download\"\n          class=\"btn-icon no-shadow\"\n          pTooltip=\"Download\" tooltipPosition=\"top\"\n          [matMenuTriggerFor]=\"menu\">\n        </button>\n\n      <mat-menu #menu=\"matMenu\">\n         <button mat-menu-item (click)=\"downloadReports('worddoc');\">Word</button>\n         <button mat-menu-item (click)=\"downloadReports('pdf');\">Pdf</button>\n        <button mat-menu-item (click)=\"downloadReports('excel');\">Excel</button>\n      </mat-menu>\n      </div>\n\n        <!-- Search -->\n      <div style=\"position: relative; display: flex; align-items: center;\">\n        <i class=\"pi pi-search\" style=\"position: absolute; left: 8px; z-index: 1; color: #888; pointer-events: none;\"></i>\n        <input pInputText type=\"text\" placeholder=\"Global Filter\"\n          style=\"padding-left: 28px; height: 28px; font-size: 12px;\"\n          (input)=\"tt.filterGlobal($any($event.target).value, 'contains')\" />\n      </div>\n\n    </div>\n  </div>\n</div>\n   \n\n<!-- LEFT: TreeTable -->\n<div [ngClass]=\"{'p-col-12': !selectedTask, 'p-col-8': selectedTask}\">\n<p-treeTable #tt [value]=\"nodes\" [globalFilterFields]=\"['name','kind','duration','startTime','service','threadName']\" tableStyleClass=\"p-datatable-sm\" selectionMode=\"single\" [(selection)]=\"selectedNode\"\n  (onNodeSelect)=\"nodeSelect($event)\" [scrollable]=\"true\" scrollHeight=\"calc(100vh - 330px)\">\n  <ng-template pTemplate=\"colgroup\">\n  <colgroup>\n    <col style=\"width: 30%\">\n    <col style=\"width: 10%\">\n    <col style=\"width: 15%\">\n    <col style=\"width: 10%\">\n    <col style=\"width: 20%\">\n    <col style=\"width: 15%\">\n  </colgroup>\n</ng-template>\n  <ng-template pTemplate=\"header\">\n      <tr>\n        <th>Name</th>\n        <th>Kind</th>\n        <th>Start Time</th>\n        <th>Duration (ms)</th>\n        <th>Thread Name</th>\n        <th>Service Name</th>\n      </tr>\n    </ng-template>\n  \n<ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\">\n  <tr [ttSelectableRow]=\"rowNode\" style=\"cursor: pointer;\" [style.background-color]=\"getServiceColor(rowData.service)\"> \n    <td>\n      <p-treeTableToggler [rowNode]=\"rowNode\"></p-treeTableToggler>\n      <span pTooltip=\"{{ rowData.name }}\" tooltipPosition=\"bottom\">\n        {{ rowData.name }}\n      </span>\n    </td>\n\n    <td pTooltip=\"{{ rowData.kind }}\" tooltipPosition=\"bottom\">\n      {{ rowData.kind }}\n    </td>\n\n    <td pTooltip=\"{{ rowData.startTime }}\" tooltipPosition=\"bottom\" style=\"text-align: right;\">\n      {{ rowData.startTime }}\n    </td>\n\n    <td pTooltip=\"{{ rowData.duration }}\" tooltipPosition=\"bottom\" style=\"text-align: right;\">\n      {{ rowData.duration }}\n    </td>\n\n    <td pTooltip=\"{{ rowData.threadName }}\" tooltipPosition=\"bottom\">\n      {{ rowData.threadName }}\n    </td>\n    \n    <td pTooltip=\"{{ rowData.service }}\" tooltipPosition=\"bottom\">\n      {{ rowData.service }}\n    </td>\n  </tr>\n</ng-template>\n  </p-treeTable>\n </div> \n<!-- RIGHT: Details -->\n<div class=\"p-col-4\" \n     [style.display]=\"selectedTask ? 'block' : 'none'\" \n     style=\"pointer-events: auto;\">\n  <div class=\"border-all border-7 rounded-3\">\n    <p-toolbar class=\"ui-primary-toolbar\" styleClass=\"border-none\">\n      <div class=\"p-grid p-justify-between p-align-center p-8 font-13\">\n        <strong>Span Details</strong>\n        <button type=\"button\" pButton matTooltip=\"Close\" icon=\"icons8 icons8-delete\" class=\"btn-icon\"\n          (click)=\"closeSelectedTask()\"></button>\n      </div>\n    </p-toolbar>\n    <div class=\"p-6 overflow top-border border-7 line-height18\"  [ngClass]=\"commonService.isFromSplitView ? 'h-100vh-330' : 'h-100vh-330'\">\n      <div class=\"mln-6 mrn-6 mb-4\">\n        <div class=\"p-grid\">\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Service Name</span>\n              <strong class=\"word-break\">{{selectedRowData?.resource?.attributes[\"service.name\"] || '-'}}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Span Name</span>\n              <strong class=\"word-break\">{{selectedRowData?.name || '-'}}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Span ID</span>\n              <strong class=\"word-break\">{{selectedRowData?.span_id || '-'}}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Parent ID</span>\n              <strong class=\"word-break\">{{selectedRowData?.parent_span_id || '-'}}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Duration</span>\n              <strong class=\"word-break\">{{ formatDuration(selectedRowData?.duration) }}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Kind</span>\n              <strong class=\"word-break\">{{selectedRowData?.kind || '-'}}</strong>\n            </div>\n          </div>\n        </div>\n      </div>\n      <p-accordion multiple=\"true\">\n        <p-accordionTab header=\"Span Attributes\" [selected]=\"true\">\n          <table class=\"w-100-p\">\n            <tr *ngFor=\"let entry of flattenObject(spanAttributes); trackBy: trackByKey\">\n              <td class=\"word-break w-35-p\"><strong>{{ entry.key }}</strong></td>\n              <td class=\"word-break w-65-p hover\">{{ entry.value }}\n                <button type=\"button\" pButton class=\"btn-icon showHover\" icon=\"icons8 icons8-copy\"\n                  (click)=\"copyToClipboard(entry.value)\" matTooltip=\"Copy to Clipboard\"></button>\n              </td>\n            </tr>\n          </table>\n        </p-accordionTab>\n        <p-accordionTab header=\"Resource Attributes\" [selected]=\"false\">\n          <table class=\"w-100-p\">\n            <tr *ngFor=\"let entry of flattenObject(resourceAttributes); trackBy: trackByKey\">\n              <td class=\"word-break w-35-p\"><strong>{{ entry.key }}</strong></td>\n              <td class=\"word-break w-65-p hover\">{{ entry.value }}\n                <button type=\"button\" pButton class=\"btn-icon showHover\" icon=\"icons8 icons8-copy\"\n                  (click)=\"copyToClipboard(entry.value)\" matTooltip=\"Copy to Clipboard\"></button>\n              </td>\n            </tr>\n          </table>\n        </p-accordionTab>\n        <p-accordionTab header=\"Scope\" [selected]=\"false\">\n          <table class=\"w-100-p\">\n            <tr *ngFor=\"let entry of flattenObject(scope); trackBy: trackByKey\">\n              <td class=\"word-break w-35-p\"><strong>{{ entry.key }}</strong></td>\n              <td class=\"word-break w-65-p hover\">{{ entry.value }}\n                <button type=\"button\" pButton class=\"btn-icon showHover\" icon=\"icons8 icons8-copy\"\n                  (click)=\"copyToClipboard(entry.value)\" matTooltip=\"Copy to Clipboard\"></button>\n              </td>\n            </tr>\n          </table>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n  </div>\n</div>\n\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.html":
/*!*******************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.html ***!
  \*******************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"ddr-box\">\n  <div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\" loader2 || loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n  </div>\n<!-- COMMON TOOLBAR -->\n  <div class=\"ddr-toolbar\">\n<div class=\"ui-table-header\">\n  <!-- <div> -->\n     <span id=\"filterId\" [innerHTML]=\"filterCriteria\"></span>\n  </div>\n</div>\n  <p-dialog class=\"secondary-dialog foterDialog\" [(visible)]=\"loader\" [style]=\"{'width':'800px'}\" height=\"75\" [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n      <div *ngIf=\"loader\">\n        <p-progressBar [value]=\"value\"></p-progressBar>\n      </div>\n  </p-dialog>\n\n<!-- DDR UI SCROLL -->\n<div class=\"ddruiscroll\">\n<p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n  <p-accordionTab *ngIf=\"!commonService.showMethodCallingTree\" header=\"Method Summary (Total: {{dataCount}})\"\n    [selected]=\"true\">\n    <div style=\"overflow:auto\">\n      <cav-table [value]=\"methodTimingData\" [headerRelativePath]=\"relativePathforMethodSummary\"\n         [scrollable]=\"true\" [responsive]=\"true\"\n        scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n    </div>\n  </p-accordionTab>\n</p-accordion>\n  <p-accordion class=\"ddr-accordion\">\n    <p-accordionTab header=\"Method Calling Tree {{mctAppliedFilter}}\" [selected]=\"true\">\n      <div><b><i style=\"font-size: 11px;\">{{mctHeaderNote}}</i></b></div>\n    <div class=\"p-grid p-align-center p-justify-between py-5\">\n      <div>\n      <button pButton icon=\"icons8 icons8-expand-arrow\" *ngIf='showExpandBtn' (click)=\"showExpandBtn =false;toggleNode(true)\" matTooltip=\"Click to Expand Method calling tree\" class=\"ui-button-secondary\"></button>\n      <button pButton icon=\"icons8 icons8-collapse-arrow\" *ngIf='!showExpandBtn' (click)=\"showExpandBtn = true;toggleNode(false)\" matTooltip=\"Click to Collapse Method calling tree\" class=\"ui-button-secondary\"></button>\n</div>\n\n         \n<div class=\"p-grid p-align-center\" style=\"display: flex;\">\n\n<button type=\"button\" pButton class=\"btn-icon\" icon=\"icons8 icons8-download\" title=\"Download\" [matMenuTriggerFor]=\"menu\"\nmatTooltip=\"Download\"></button>\n<mat-menu #menu=\"matMenu\">\n<button mat-menu-item *ngIf=\"showDownLoadReportIcon\" [disabled]=\"downloadWordEnable\"\n  (click)='downloadReportMCT(\"word\")'>\n  <i class=\"icons8 icons8-word\"></i>\n  <span>Word</span>\n</button>\n<button mat-menu-item *ngIf=\"showDownLoadReportIcon\" [disabled]=\"downloadExcelEnable\"\n  (click)='downloadReportMCT(\"excel\")'>\n  <i class=\"icons8 icons8-spreadsheet-file\"></i>\n  <span>Excel</span>\n</button>\n<button mat-menu-item *ngIf=\"showDownLoadReportIcon\" [disabled]=\"downloadPdfEnable\"\n  (click)='downloadReportMCT(\"pdf\")'>\n  <i class=\"icons8 icons8-pdf-2\"></i>\n  <span>PDF</span>\n</button>\n</mat-menu>\n\n<button type=\"button\" pButton class=\"btn-icon\" (click)=\"toggleExpandedCallout()\" matTooltip=\"{{expandCollapseHint}}\" icon=\"icons8 icons8-globe\" ></button>\n\n<button type=\"button\" pButton class=\"btn-icon\" (click)=\"openDLDialog()\" matTooltip=\"Dynamic logging\" icon=\"cav System-Events\"></button>\n<div *ngIf=\"isAgent\">\n  <button pButton icon=\"cav debug-trace font-18\" (click)=\"openAutoInstDialog()\" matTooltip=\"Click to Start Dynamic Diagnostics\" class=\"btn-icon\"></button>\n</div>            \n          <button pButton type=\"button\" (click)=\"openDialogforfilter()\" label=\"Filters\" class=\"ui-button-secondary ui-button-rounded\"></button>\n          \n          <!-- <button pButton icon=\"icons8 icons8-settings\" (click)=\"showFPInsanceInfo()\" matTooltip=\"Click to get FlowpathInstances\" class=\"btn-icon\"></button> -->\n\n\n          <p-multiSelect class=\"icon-button no-shadow\" [options]=\"columnOptionsForMCT\"\n              [(ngModel)]=\"visibleColsForMCT\" (onChange)=\"showHideColumnForMCT($event)\" dropdownIcon=\"icons8 icons8-columns font-18\" pTooltip=\"Toggle Columns\" [panelStyle]=\"{ minWidth: '200px' }\" appendTo=\"body\">\n            </p-multiSelect>\n          <button pButton icon=\"icons8 icons8-paint-palette\"  matTooltip=\"Show Method Color Meaning\" (click)=\"showColorMeaning()\" class=\"btn-icon\"></button>\n          <span class=\"p-input-icon-left\">\n            <i class=\"pi pi-search\"></i>\n            <input type=\"text\" pInputText size=\"50\" placeholder=\"Global Filter\"\n              (input)=\"treeRef.filterGlobal($event.target.value, 'contains')\" style=\"width:auto\" />\n          </span>\n\n         </div>\n        </div>\n        <div class=\"ui-panel-contents\">\n        <p-treeTable #treeRef [value]=\"mctData\" [rows]=\"100\" [virtualScroll]=\"true\" [virtualRowHeight]=\"34\"  (onNodeSelect)=\"loadNodeUpto($event)\" (contextmenu)=\"onNodeRightClick($event,cm)\" [reorderableColumns]=\"true\" [columns]=\"colsForMCT\" [resizableColumns]=\"true\" selectionMode=\"single\" [(selection)]=\"selectedNode\" [(contextMenuSelection)]=\"selectedNode\" [contextMenu]=\"cm\" (onColResize)=\"resizingColumns($event)\" [scrollable]=\"true\" scrollHeight=\"calc(100vh - 340px)\">\n            <ng-template pTemplate=\"colgroup\" let-columns>\n                <colgroup>\n                  <ng-container  *ngFor=\"let col of columns\">\n                  <col *ngIf = \"col.action\"  [style.width]=\"col.width\">\n                  </ng-container>\n                </colgroup>\n              </ng-template>\n\n          <ng-template pTemplate=\"header\" let-columns>\n            <tr>\n                <ng-container  *ngFor=\"let col of columns\">\n                    <th *ngIf = \"col.action && col.field == 'methodName'\"  ttResizableColumn>\n                        {{col.header}}\n                    </th>  \n                <th   *ngIf = \"col.action && col.field != 'methodName'\" ttResizableColumn>\n                    {{col.header}}\n                </th>\n              </ng-container>\n            </tr>\n        </ng-template>\n        <ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\" let-columns=\"columns\">\n            <tr [ttRow]=\"rowNode\" [ttSelectableRow]=\"rowNode\" [ttSelectableRowDblClick]=\"rowNode\" [ttContextMenuRow]=\"rowNode\" [style.background-color]=\"rowData.showMethodColor.includes('hghtDiffElapsedTime') ? 'rgba(255, 255, 23, 0.5)' : ''\">\n                <ng-container  *ngFor=\"let col of columns; let i = index\">\n                        <td *ngIf=\"col.field == 'methodName'\">\n                            <p-treeTableToggler [rowNode]=\"rowNode\"></p-treeTableToggler>\n\n                            <i class=\"icons8 icons8-info\" matTooltip={{repeatedMethodMsg}} *ngIf=\" rowData.repeatedMethodCount>maxRepeatedMethod\"></i>\n                            <span *ngIf=\" rowData.repeatedMethodCount >0\" class=\"ddr-table-left elipseText\" matTooltip=\"View Repeated Details\" (click)=\"showRepeatedData(rowData,0)\">{{rowData.repeatedMethodCount+1 }} </span>\n                            <span *ngIf=\" rowData.repeatedMethodCount>0\" class=\"elipseText\">x </span> \n                            <span [ngSwitch]=\"rowData.showMethodColor\" class=\"elipseText\">\n\n                                <span class=\"elipseText\" *ngSwitchCase= \"'unInstrumented'\" style=\"color:gray\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\"> {{decodeHTMLString(rowData.methodName)}}\n                                </span>\n                                <span *ngSwitchCase= \"'httpOrthreadCallout'\" class=\"ddr-table-left elipseText\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"getChildFLowpathsData(rowNode)\">  \n                                        {{decodeHTMLString(rowData.methodName)}}\n                                </span>\n                                 <span class=\"elipseText\" *ngSwitchCase= \"'restCallout'\" style=\"color:green\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">    \n                                        {{decodeHTMLString(rowData.methodName)}}\n                                </span>\n                                <span class=\"elipseText\" *ngSwitchCase=\"',highlightWallTime'\" style=\"color:red\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                                  {{decodeHTMLString(rowData.methodName)}}\n                                </span>\n                                 <span class=\"elipseText\" *ngSwitchCase=\"'restCallout,highlightWallTime'\" style=\"color:red\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                              {{decodeHTMLString(rowData.methodName)}}\n                            </span> \n                                <span class=\"elipseText\" *ngSwitchCase=\"'httpOrthreadCallout,highlightWallTime'\" style=\"color:red\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"getChildFLowpathsData(rowNode)\">\n                                  {{decodeHTMLString(rowData.methodName)}}\n                                </span>\n                                <span class=\"elipseText\" *ngSwitchCase=\"',highlightWallTime,hghtDiffElapsedTime'\" #diffElapsedTime style=\"color:red\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" >\n                                    {{decodeHTMLString(rowData.methodName)}}\n                                </span>\n                                <span *ngSwitchCase=\"'asynCall,hghtDiffElapsedTime'\" #diffElapsedTime #asyncall id=\"{{decodeHTMLString(rowData.methodName.substring(rowData.methodName.lastIndexOf(':')+1,rowData.methodName.length-1))}}\" class=\"ddr-table-left elipseText\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">{{decodeHTMLString(rowData.methodName)}}\n                               </span>\n                                <span class=\"elipseText\" *ngSwitchCase=\"',hghtDiffElapsedTime'\" #diffElapsedTime   matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">{{decodeHTMLString(rowData.methodName)}}\n                                </span>\n                                    <span class=\"elipseText\" *ngSwitchCase= \"'eventIdLight'\" style=\"color:palevioletred\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">    \n                                      {{decodeHTMLString(rowData.methodName)}}\n                                  </span>\n                              <span class=\"elipseText\" *ngSwitchCase= \"'eventIdDark'\" style=\"color:pink\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">    \n                                  {{decodeHTMLString(rowData.methodName)}}\n                                     </span>\n                                     <span  *ngSwitchCase= \"'asynCall'\" #asynCall id=\"{{rowData.asyncToBeMatchedId}}\" class=\"ddr-table-left elipseText\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">    \n                                      {{decodeHTMLString(rowData.methodName)}}\n                                         </span>\n                                        <span *ngSwitchCase=\"'asynCall,highlightWallTime'\" #asynCall id=\"{{rowData.asyncToBeMatchedId}}\"\n                                          class=\"ddr-table-left elipseText\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">\n                                          {{decodeHTMLString(rowData.methodName)}}\n                                        </span>\n                                         <span *ngSwitchCase= \"'asynCallOutCase'\"  #asynCall  id=\"{{rowData.asyncToBeMatchedId}}\" class=\"ddr-table-left elipseText\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"getAsyncExit(rowData)\" >    \n                                          {{decodeHTMLString(rowData.methodName)}}\n                                             </span>\n                                    <span class=\"elipseText\" *ngSwitchDefault  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                                            {{decodeHTMLString(rowData.methodName)}}\n                                    </span>\n                                  </span>\n                             <span  *ngIf=\"rowData.limit >0 && ( rowData.offset <=rowData.last) && rowData.limit < rowData.last && rowData.type==2\" class=\"ddr-table-left elipseText\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.limit,rowData.last)\">\n                               Next({{rowData.limit+1}} - {{rowData.offset}} of {{rowData.last}})>>\n                          </span>\n                           <span *ngIf=\"rowData.limit >=0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==1\" class=\"ddr-table-left elipseText\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.limit,rowData.last)\">\n                               (Previous({{rowData.limit+1}} - {{rowData.limit+50}} of {{rowData.last}})\n                          </span>\n                           <span *ngIf=\"rowData.limit >= 0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==1\" class=\"ddr-table-left elipseText\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,0,rowData.last)\">\n                               &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;FIRST\n                          </span>\n                          <span *ngIf=\"rowData.limit >0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==2\" class=\"ddr-table-left elipseText\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.last,rowData.last)\">\n                               &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;LAST\n                          </span>\n                        </td>\n                        <td *ngIf = \"col.action && col.field == 'dynLogFlag'\"  [style.text-align]=\"col.align\" ttSelectableRowDblClick >\n                          <img *ngIf=\"(rowData.dynLogFlag == '1')\" src=\"./assets/images/dl.png\" matTooltip='Dynamic Logging' (click)=\"commonModuleCall(rowData)\" style=\"overflow: auto;display: inline-block; margin-left: 10px;width:16px;height:16px;cursor:pointer;\"/>\n                        </td>\n                        <td *ngIf = \"col.action && col.field == 'threadId'\"  [style.text-align]=\"col.align\">\n                          <span class=\"elipseText\" matTooltip=\"{{(rowData[col.field])}}\">   {{(rowData[col.field])}} </span>\n                        </td>\n                <td *ngIf = \"col.action && col.field != 'methodName' && col.field != 'dynLogFlag'  && col.field != 'threadId'\"  [style.text-align]=\"col.align\" ttSelectableRowDblClick >\n                  <span class=\"elipseText\" matTooltip=\"{{formatter(rowData[col.field])}}\">   {{formatter(rowData[col.field])}} </span>\n                </td>\n\n              </ng-container>\n            </tr>\n        </ng-template>\n        <ng-template [ngIf]='showErrorMessage' let-columns>\n            <tr>\n                <td [attr.colspan]=\"colsForMCT.length\">\n                    No Methods available.\n                </td>\n            </tr>\n            </ng-template>\n      </p-treeTable>\n      </div>\n        <p-contextMenu  #cm [model]=\"menuIte\"  appendTo=\"body\" [style]=\"{'width':'147px'}\" ></p-contextMenu> \n    </p-accordionTab>\n  </p-accordion>\n<p-dialog class=\"secondary-dialog foterDialog\" header=\"Color Meaning For Methods\" [style]=\"{width: '30vw'}\" height='150px' [(visible)]=\"showColor\" [resizable]=false [modal]=\"true\" autoAlign=\"true\">\n  <div >\n  \n    <div class='ui-g-12'>\n      <div class='ui-g-2' style=\"width:10px;height:10px;border:1px solid #D3D3D3; background-color: red\"></div>\n      <div class='ui-g-10' style=\"margin-top: -5px\">\n        <span >\n          <b>HighlightWallTime</b>\n        </span>\n      </div>\n      </div>\n<div class='ui-g-12'>\n      <div class='ui-g-2' style=\"width:10px;height:10px;border:1px solid #D3D3D3; background-color: yellow\"></div>\n      <div class='ui-g-10' style=\"margin-top: -5px\">\n        <span >\n          <b>\tElapsed Threshold</b>\n        </span>\n      </div>\n    </div>\n    <div class='ui-g-12'>\n      <div class='ui-g-2' style=\"width:10px;height:10px;border:1px solid #D3D3D3; background-color: palevioletred\"></div>\n      <div class='ui-g-10' style=\"margin-top: -5px\">\n        <span >\n          <b>Method Throwing Exception</b>\n        </span>\n      </div>\n    </div>\n    <div class='ui-g-12'>\n      <div class='ui-g-2' style=\"width:10px;height:10px;border:1px solid #D3D3D3; background-color: pink\"></div>\n      <div class='ui-g-10' style=\"margin-top: -6px\">\n        <span>\n          <b>Method Catching Exception</b>\n        </span>\n      </div>\n    </div>\n    <div class='ui-g-12'>\n      <div class='ui-g-2' style=\"width:10px;height:10px;border:1px solid #D3D3D3; background-color: green\"></div>\n      <div class='ui-g-10' style=\"margin-top: -5px\">\n        <span>\n          <b>JMS/JDBC Callout</b>\n        </span>\n      </div>\n    </div>\n    <div class='ui-g-12'>\n      <div class='ui-g-2' style=\"width:10px;height:10px;border:1px solid #D3D3D3; background-color: gray\"></div>\n      <div class='ui-g-10' style=\"margin-top: -6px\">\n        <p>\n          <b>UnInstrumented Method</b>\n        </p>\n      </div>\n    </div>\n    <div class='ui-g-12' style=\"margin-top:-10px\">\n      <div class='ui-g-2' style=\"width:10px;height:10px;border:1px solid #D3D3D3; background-color: blue\"></div>\n      <div class='ui-g-10' style=\"margin-top: -5px\">\n        <p>\n          <b>HTTP/Thread Callout</b>\n        </p>\n      </div>\n    </div>\n  </div>\n\n        \n</p-dialog>\n\n<p-dialog class=\"secondary-dialog foterDialog\" header=\"Call Stack\" [style]=\"{'width': '80vw'}\" [(visible)]=\"showParent\" [resizable]=\"false\" [modal]=\"true\">\n  <div style=\"height:300px; \" class=\"p-grid p-align-center p-justify-center loader-container vertical-container \" *ngIf=\"tableLoading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n  </div>\n  <div class=\"w-100-p\" *ngIf=\"!tableLoading\">\n\n    <p-treeTable [columns]=\"colsForMCT\" [value]=\"parentDataArray\" [scrollable]=\"true\" class=\"ui-treetable all-tables\" [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"250px\">\n      <ng-template pTemplate=\"colgroup\" let-columns>\n        <colgroup>\n          <ng-container  *ngFor=\"let col of columns\">\n          <col *ngIf = \"col.action\"  [style.width]=\"col.width\">\n          </ng-container>\n        </colgroup>\n      </ng-template>\n\n  <ng-template pTemplate=\"header\" let-columns>\n    <tr>\n        <ng-container  *ngFor=\"let col of columns\">\n            <th *ngIf = \"col.action && col.field == 'methodName'\"  ttResizableColumn>\n                {{col.header}}\n            </th>  \n        <th   *ngIf = \"col.action && col.field != 'methodName'\" ttReorderableColumn ttResizableColumn>\n            {{col.header}}\n        </th>\n      </ng-container>\n    </tr>\n</ng-template>\n<ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\" let-columns=\"columns\">\n  <tr [ttRow]=\"rowNode\" [ttSelectableRow]=\"rowNode\" [ttSelectableRowDblClick]=\"rowNode\" [ttContextMenuRow]=\"rowNode\" [style.background-color]=\"rowData.showMethodColor.includes('hghtDiffElapsedTime') ? 'rgba(255, 255, 23, 0.5)' : ''\">\n      <ng-container  *ngFor=\"let col of columns; let i = index\">\n                  <td  *ngIf=\"col.field == 'methodName'\">\n                    <div class=\"p-grid p-align-center \" >\n\n                    <div class=\"p-col-fixed p-0 \">\n                      <p-treeTableToggler [rowNode]=\"rowNode\"></p-treeTableToggler>\n                    </div>\n                    <div *ngIf=\" rowData.repeatedMethodCount >0\" class=\"ddr-table-left\" matTooltip=\"View Repeated Details\"\n                      (click)=\"showRepeatedData(rowData,0)\">{{rowData.repeatedMethodCount+1 }} </div>\n                    <div *ngIf=\" rowData.repeatedMethodCount >0\">x </div>\n                    <div class=\"p-col elipseText  p-0\" [ngSwitch]=\"rowData.showMethodColor\">\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'unInstrumented'\" style=\"color:gray\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'httpOrthreadCallout'\" class=\"ddr-table-left\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\"\n                        (click)=\"getChildFLowpathsData(rowNode)\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'restCallout'\" style=\"color:green\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"',highlightWallTime'\" style=\"color:red\" \n                        matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'restCallout,highlightWallTime'\"  style=\"color:red\"\n                        matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'httpOrthreadCallout,highlightWallTime'\"  style=\"color:red\"\n                        matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"getChildFLowpathsData(rowNode)\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"',highlightWallTime,hghtDiffElapsedTime'\" #diffElapsedTime style=\"color:red\"\n                          matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'asynCall,hghtDiffElapsedTime'\" #diffElapsedTime #asyncall\n                        id=\"{{decodeHTMLString(rowData.methodName.substring(rowData.methodName.lastIndexOf(':')+1,rowData.methodName.length-1))}}\"\n                        class=\"ddr-table-left\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"',hghtDiffElapsedTime'\" #diffElapsedTime matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'eventIdLight'\" style=\"color:palevioletred\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'eventIdDark'\" style=\"color:pink\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchCase=\"'asynCall'\" #asynCall id=\"{{rowData.asyncToBeMatchedId}}\" class=\"ddr-table-left\"\n                        matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText ddr-table-left \" *ngSwitchCase=\"'asynCall,highlightWallTime'\" #asynCall id=\"{{rowData.asyncToBeMatchedId}}\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText ddr-table-left\" *ngSwitchCase=\"'asynCallOutCase'\" #asynCall id=\"{{rowData.asyncToBeMatchedId}}\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"getAsyncExit(rowData)\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                      <div class=\"w-100-p p-0 elipseText \" *ngSwitchDefault matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                        {{decodeHTMLString(rowData.methodName)}}\n                      </div>\n                    </div>\n                    <span\n                      *ngIf=\"rowData.limit >0 && ( rowData.offset <=rowData.last) && rowData.limit < rowData.last && rowData.type==2\"\n                      class=\"ddr-table-left elipseText\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.limit,rowData.last)\">\n                      Next({{rowData.limit+1}} - {{rowData.offset}} of {{rowData.last}})>>\n                    </span>\n                    <span\n                      *ngIf=\"rowData.limit >=0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==1\"\n                      class=\"ddr-table-left elipseText\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.limit,rowData.last)\">\n                      (Previous({{rowData.limit+1}} - {{rowData.limit+50}} of {{rowData.last}})\n                    </span>\n                    <span\n                      *ngIf=\"rowData.limit >= 0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==1\"\n                      class=\"ddr-table-left elipseText\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,0,rowData.last)\">\n                      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;FIRST\n                    </span>\n                    <span\n                      *ngIf=\"rowData.limit >0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==2\"\n                      class=\"ddr-table-left elipseText\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.last,rowData.last)\">LAST\n                    </span>\n                  </div>\n              </td>\n              <td *ngIf = \"col.action && col.field == 'dynLogFlag'\"  [style.text-align]=\"col.align\" ttSelectableRowDblClick >\n                <img *ngIf=\"(rowData.dynLogFlag == '1')\" src=\"./assets/images/dl.png\" matTooltip='Dynamic Logging' (click)=\"commonModuleCall(rowData)\" style=\"overflow: auto;display: inline-block; margin-left: 10px;width:16px;height:16px;cursor:pointer;\"/>\n              </td>\n              <td *ngIf = \"col.action && col.field == 'threadId'\"  [style.text-align]=\"col.align\">\n                <span class=\"elipseText\" matTooltip=\"{{(rowData[col.field])}}\">   {{(rowData[col.field])}} </span>\n              </td>\n\n      <td *ngIf = \"col.action && col.field != 'methodName' && col.field != 'dynLogFlag' && col.field != 'threadId'\"  [style.text-align]=\"col.align\" ttSelectableRowDblClick >\n        <span matTooltip=\"{{formatter(rowData[col.field])}}\">   {{formatter(rowData[col.field])}} </span>\n      </td>\n\n    </ng-container>\n  </tr>\n</ng-template>\n</p-treeTable>\n  </div>\n</p-dialog>\n  <p-dialog class=\"secondary-dialog\" header=\"Method Call Tree Filter Settings\" width='700' [(visible)]=\"filterDialog\" [resizable]=false [modal]=\"true\" autoAlign=\"true\">\n<div style=\"overflow: auto;\">\n      <div class='ui-g'>\n          <div class='ui-g-6'>\n            <span style='margin-right:13px'>Show Methods(max depth)</span>\n            </div>\n            <div class='ui-g-6'>\n            <input type=\"number\" min=0 style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtFlterMethodLevel\" />\n          </div>\n          </div>\n          <div class='ui-g'>\n          <div class='ui-g-6'>\n            <span style='margin-right:13px'>Show Methods (walltime in ms) >=\t</span>\n            </div>\n            <div class='ui-g-6'>\n            <input type=\"number\" min=0  style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtFilterWallTime\" />\n          </div>\n          </div>\n          <div class='ui-g'>\n            <div class='ui-g-6'>\n              <span style='margin-right:13px'>Show Methods (selfTime in ms) >=\t</span>\n              </div>\n              <div class='ui-g-6'>\n              <input type=\"number\" min=0  style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtFilterSelfTime\" />\n            </div>\n            </div>\n          <div class='ui-g'>\n          <div class='ui-g-6'>\n            <span style='margin-right:13px'>Highlight Methods(walltime in ms) >= </span>\n            </div>\n            <div class='ui-g-6'>\n            <input type=\"number\" min=0 style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtThresholdWallTime\" />\n          </div>\n  \n        </div>\n        <div class='ui-g'>\n          <div class='ui-g-6'>\n            <span style='margin-right:13px'>Highlight successor Methods(w.r.t. elapsed time in ms) >= </span>\n            </div>\n            <div class='ui-g-6'>\n            <input type=\"number\" min=0 style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtThresholdelapsedTime\" />\n          </div>\n  \n        </div>\n  <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n   <p-accordionTab header=\"Positive Filters\" [selected]=\"true\">\n         <div class='ui-g'>\n          <div class='ui-g-6'>\n            <span style='margin-right:13px'>Packages </span>\n            </div>\n            <div class='ui-g-6'>\n            <p-multiSelect class=\"mutilSelectDropDown-width\"  [options]=\"packageList\" [(ngModel)]=\"selectedPackageList\" (onChange)=\"getClassList()\" [maxSelectedLabels]=2  appendTo=\"body\" [style]=\"{'width':'230px'}\"  [panelStyle]=\"{'width':'230px' }\">\n              <ng-template let-package pTemplate=\"item\">\t\n                <span pTooltip=\"{{package.label}}\">{{package.label}}</span>\t\n              </ng-template>\n            </p-multiSelect>\n          </div>\n  \n        </div>\n         <div class='ui-g'>\n          <div class='ui-g-6'>\n            <span style='margin-right:13px'>Classes </span>\n            </div>\n            <div class='ui-g-6'>\n            <p-multiSelect class=\"mutilSelectDropDown-width\"  [options]=\"classList\" [(ngModel)]=\"selectedClassList\" (onChange)=\"getMethodList()\"  [maxSelectedLabels]=2  appendTo=\"body\" [style]=\"{'width':'230px'}\"  [panelStyle]=\"{ 'width':'230px' }\">\n              <ng-template let-class pTemplate=\"item\">\t\n                <span pTooltip=\"{{class.label}}\">{{class.label}}</span>\t\n              </ng-template>\n            </p-multiSelect>\n          </div>\n  \n        </div>\n         <div class='ui-g'>\n          <div class='ui-g-6'>\n            <span style='margin-right:13px'>Methods </span>\n            </div>\n            <div class='ui-g-6'>\n            <p-multiSelect class=\"mutilSelectDropDown-width\"  [options]=\"methodList\" [(ngModel)]=\"selectedMethodList\" [maxSelectedLabels]=2 appendTo=\"body\" (onChange)=getActualMethodList() [style]=\"{'width':'230px'}\"  [panelStyle]=\"{'width':'230px' }\">\n              <ng-template let-method pTemplate=\"item\">\t\n                <span pTooltip=\"{{method.label}}\">{{method.label}}</span>\t\n              </ng-template>\n            </p-multiSelect>\n          </div>\n  \n        </div>\n   </p-accordionTab>\n<p-accordionTab header=\"Negative Filters\" [selected]=\"true\">\n  <div class='p-grid p-align-center'>\n    <div class='p-col'>\n      <span style='margin-right:13px'>Do not show methods </span>\n    </div>\n      <div class=\"p-col-fixed w-60-p\">\n        <p-chips class=\"input-chips\" [addOnTab]=\"true\" [addOnBlur]=\"true\"\n          [(ngModel)]=\"selectedNegativeMethod\" name=\"includedException\"></p-chips>\n      </div>\n  </div>\n</p-accordionTab>\n    <p-accordionTab header=\"Advanced Settings\" [selected]=\"false\">\n      <h4 class=\"my-8\">Do not filter callouts</h4>\n\n        <table class=\"w-100-p\">\n          <tr>\n          <td><p-checkbox name=\"groupname\" label=\"HTTP CallOuts\" value=\"T,E\" [(ngModel)]=\"ignoreFilterCallOuts\"></p-checkbox></td>\n          <td> <p-checkbox name=\"groupname\" label=\"DB CallOuts\" value=\"D\" [(ngModel)]=\"ignoreFilterCallOuts\"></p-checkbox></td></tr>\n          <tr> <td>  <p-checkbox name=\"groupname\" label=\"JMS CallOuts\" value=\"J,j\" [(ngModel)]=\"ignoreFilterCallOuts\"></p-checkbox></td>\n             <td><p-checkbox name=\"groupname\" label=\"Exceptions\" value=\"e\" [(ngModel)]=\"ignoreFilterCallOuts\"></p-checkbox></td></tr>\n           <tr> <td>   <p-checkbox name=\"groupname\" label=\"Thread CallOuts\" value=\"t\" [(ngModel)]=\"ignoreFilterCallOuts\"></p-checkbox></td>\n           <td>   <p-checkbox name=\"groupname\" label=\"Async CallOuts\" value=\"a,A\" [(ngModel)]=\"ignoreFilterCallOuts\"></p-checkbox></td></tr>\n           <tr>\n            <td colspan=\"2\">\n              <p-checkbox label=\"Show Thread Queue Time and Self Time\" [(ngModel)]=\"isEnabledQAS\" binary=\"true\"></p-checkbox>\n            </td>\n           </tr>\n        </table>\n        <div class=\"p-grid p-align-center p-nogutter8\">\n            <div class='p-col-fixed'>\n          <p-checkbox label=\"Expand methods upto\" [(ngModel)]=\"isExpandCount\" (onChange)=\"expandSetter()\" binary=\"true\"></p-checkbox>\n           </div>\n           <div class='p-col-fixed width-120'>\n          <input type=\"text\" class=\"text-right w-100-p\" [disabled]=\"!isExpandCount\" maxlength=\"5\" (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtExpandCount\" />\n        </div>\n        </div>\n      </p-accordionTab>\n         </p-accordion>\n  </div>\n  <p-footer>\n    <div class=\"p-grid p-align-center p-justify-end py-5\">\n      <button pButton type=\"button\" label=\"Apply\" (click)=\"applyThresholdFilter()\" class=\"ui-btn-primary mx-3\"></button>\n     <button pButton type=\"button\" label=\"Reset\" (click)=\"applyDefaultValue()\" class=\"btn-secondary-outline mx-3\"></button>\n     <button pButton type=\"button\" label=\"Cancel\" (click)=\"filterDialog =false\" class=\"btn-secondary-outline mx-3\"></button>\n     </div>    \n      \n </p-footer>\n  </p-dialog>\n\n  <p-dialog class=\"secondary-dialog\" [header]=\"methodDetailsHeaderName\" [modal]=\"true\" [(visible)]=\"methodDetails\" [resizable]=false [style]=\"{'height': '500px', 'width':'500px'}\">\n      <div class=\"methDetais\">\n      <table class=\"w-100-p\" style=\"table-layout: auto;\">\n        <colgroup>\n          <col class=\"w-25-p\"> \n          <col class=\"w-75-p\"> \n        </colgroup>\n          <tr><td>Method</td><td><textarea class=\"w-100-p\" pInputTextarea readonly>{{methodname}}</textarea></td></tr>\n          <!-- <tr><th>Method</th><td>{{methodname}}</td></tr> -->\n          <tr *ngIf=\"classname != '-'\"><td>Class</td><td>{{classname}}</td></tr>\n          <tr *ngIf=\"packagename != '-'\"><td>Package</td><td>{{packagename}}</td></tr>\n          <tr><td>Instance</td><td>{{appname}}</td></tr>\n          <tr><td>Server</td><td>{{servername}}</td></tr>\n          <tr><td>Tier</td><td>{{tiername}}</td></tr>\n          <tr><td>Elapsed Time(ms)</td><td>{{formatter(timeStamp)}}</td></tr>\n          <tr><td>Wall Time(ms)</td><td>{{formatter(walltime)}}</td></tr>\n          <tr><td>CPU Time(ms)</td><td>{{cpuTimeFormatter(cputime)}}</td></tr>\n          <tr><td>Percentage</td><td>{{pctFormatter(percentage)}}</td></tr>\n          <tr *ngIf=\"pagename != '-'\"><td>Page</td><td>{{pagename}}</td></tr>\n           <tr *ngIf=\"queryParams.instanceType != 'php' && queryParams.Instance_Type != 'php'\"><td>Thread Id</td><td>{{threadId}}</td></tr>\n          <tr *ngIf=\"queryParams.instanceType == 'Java' || queryParams.Instance_Type == 'Java'\"><td>Thread</td><td><textarea class=\"w-100-p\" pInputTextarea readonly >{{threadname}}</textarea></td></tr>\n          <tr><td>Argument</td><td><textarea class=\"w-100-p\" pInputTextarea readonly>{{argument}}</textarea></td></tr>\n          <tr><td>Return Value</td><td><textarea class=\"w-100-p\" pInputTextarea readonly>{{returnvalue}}</textarea></td></tr>\n          <tr *ngIf=\"dbPerm\"><td>Query Param</td><td><textarea class=\"w-100-p\" pInputTextarea readonly>{{queryparameter}}</textarea></td></tr>\n       </table>\n    </div>\n    <p-footer class=\"p-grid p-justify-end\">\n      <button pButton type=\"button\" label=\"Close\" (click)=\"methodDetails =false\"></button>\n    </p-footer>\n  </p-dialog>\n  \n  <p-dialog class=\"foterDialog\" header=\"Dynamic Diagnostics Configuration\" [resizable]=\"false\" *ngIf=\"showAutoInstrPopUp\" [(visible)]=\"showAutoInstrPopUp\" modal=\"modal\" [style]=\"{'width':'950px'}\" [contentStyle]=\"{'max-height':'500px'}\">\n<app-dynamic-diagnostics (resultAfterStart)=\"startInstrumentation($event)\" (closeAIDDGui)=\"closeAIDDDialog($event)\" [passAIDDSettings]=\"argsForAIDDSetting\"></app-dynamic-diagnostics>\n  </p-dialog>\n  <p-dialog class=\"secondary-dialog\" header=\"Source Code\" [modal]=\"true\" [(visible)]=\"showSourceCode\" [resizable]=\"true\" [style]=\"{'max-width':'90%', 'max-height':'90%'}\">    <div>\n      <pre #preContent id=\"codeBlock\" [innerHTML]=\"methodBody\"></pre>\n    </div>\n    <p-footer class=\"p-grid p-justify-end\">\n      <button pButton type=\"button\" label=\"Close\" (click)=\"showSourceCode = false\"></button>\n    </p-footer>\n  </p-dialog>    \n\n    <p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{'width':'1400px'}\" [modal]=\"true\" [(visible)]=\"showRepeatedDialogue\" [resizable]=false autoAlign=\"true\">\n      <p-header *ngIf=\"repeatedFQM != '-'\">Repeated Method Details <span matTooltip=\"{{repeatedFQM}}\">( {{substringFQM}} )</span></p-header>\n      <p-header *ngIf=\"repeatedFQM == '-'\">Repeated Callout Details <span matTooltip=\"{{methodName}}\">( {{substringFQM}} )</span></p-header>\n\n      <div>\n        <cav-table [value]=\"repeatedMethodsDatapop\" (clickButtonEvent)=\"clickButtonEvent($event)\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" [responsive]=\"true\"\n          scrollHeight=\"calc(100vh - 320px)\"></cav-table>\n     <div>\n        <textarea pInputTextarea rows=\"5\" style=\"width:100%;resize:none;\" class=\"ui-inputtext ui-corner-all ui-state-default ui-widget\" readonly>{{textAreaRepeatedMethod}}</textarea>\n      </div>  \n    </div>\n</p-dialog>\n<p-dialog class=\"secondary-dialog\"  [style]=\"{'width':'800px'}\" [modal]=\"true\"  [(visible)]=\"showColumnReorderDialog\" [closable]=\"false\" [resizable]=\"false\"  [responsive]=\"true\"  >\n<p-header>\n    Reorder Columns\n  <span style=\"float:right;cursor: pointer;\" id=\"myBtn\" (click)=\"resetReorderlist()\">X</span>\n</p-header>\n<p-pickList [source]=\"list1\" [target]=\"list2\"  sourceHeader=\"Available\" targetHeader=\"Selected\">\n    <ng-template let-car pTemplate=\"item\">\n        <div class=\"ui-helper-clearfix \">\n            <div style=\"font-size:12px;\">{{car.header}}</div>\n        </div>\n    </ng-template>\n</p-pickList>\n<p-footer>\n    <button pButton type=\"button\" label=\"Apply\" (click)=\"reOrderColumns();\"></button>\n    <button pButton type=\"button\" label=\"Close\" (click)=\"showColumnReorderDialog =false;resetReorderlist()\"></button>\n\n  </p-footer>\n</p-dialog>\n\n</div>\n<!-- <p-growl life=50000 [value]=\"msgs\" [sticky]=\"true\"></p-growl> -->\n</div>\n<p-toast [style]=\"{'top':'60px'}\"></p-toast>\n<div *ngFor=\"let value of values ;let i=index\">\n<p-dialog class=\"secondary-dialog\" [style]=\"{'width':'1000px'}\" [(visible)]=\"visibleArr[i]\" [closable]=\"false\" [resizable]=false autoAlign=\"true\" (onHide)=\"callHideFunction(i)\"  [positionTop]=\"childMCTPositionTop\">\n   <p-header>\n    <span matTooltip=\"Parent Method Name: {{value.parentMethodName}}\">{{value.subsParentMethodName}}</span>\n    <span class=\"word-break\" matTooltip={{value.Callout}}>{{value.subCallout}}</span>\n  </p-header>\n           <!--button type=\"button\" pButton (click)=\"openAdjustColWidDia()\" label=\"Column Width\" matTooltip=\"Click here to adjust column width\"></button>\n     <button pButton type=\"button\"  (click)=\"openColumnOrdderDialog()\" label='Reorder Columns'></button-->\n      \n     <p-treeTable #treeRef [value]=\"value.treeData\" [scrollable]=\"true\" scrollHeight=\"400px\"  (onNodeSelect)=\"loadNodeUpto($event)\"  selectionMode=\"single\" [(selection)]=\"selectedFile2\" [reorderableColumns]=\"true\" [columns]=\"colsForMCT\" [resizableColumns]=\"true\"  [(contextMenuSelection)]=\"selectedFile2\" [contextMenu]=\"cm\">\n\n\n      <ng-template pTemplate=\"caption\">\n        <div class=\"text-right\">        \n          <p-multiSelect matTooltip=\"Show/Hide columns\" [options]=\"columnOptionsForMCT\" class=\"icon-button no-shadow\"\n          (onChange)=\"showHideColumnForMCT($event)\" [(ngModel)]=\"visibleColsForMCT\"  appendTo=\"body\" dropdownIcon=\"icons8 icons8-columns\"></p-multiSelect>\n        </div>\n    </ng-template>\n\n        <ng-template pTemplate=\"colgroup\" let-columns>\n            <colgroup>\n              <ng-container  *ngFor=\"let col of columns\">\n              <col *ngIf = \"col.action\" class=\"width-150\">\n              </ng-container>\n            </colgroup>\n          </ng-template>\n\n      <ng-template pTemplate=\"header\" let-columns>\n        <tr>\n            <ng-container  *ngFor=\"let col of columns\">\n                <th [style.width]=\"col.width\"  *ngIf = \"col.action && col.field == 'methodName'\"  ttResizableColumn>\n                    {{col.header}}\n                </th>  \n            <th [style.width]=\"col.width\"  *ngIf = \"col.action && col.field != 'methodName'\" ttReorderableColumn ttResizableColumn>\n                {{col.header}}\n            </th>\n          </ng-container>\n        </tr>\n    </ng-template>\n    <ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\" let-columns=\"columns\">\n        <tr [ttRow]=\"rowNode\" [ttSelectableRow]=\"rowNode\" [ttSelectableRowDblClick]=\"rowNode\" [ttContextMenuRow]=\"rowNode\">\n            <ng-container  *ngFor=\"let col of columns; let i = index\">\n                    <td *ngIf=\"col.field == 'methodName'\">\n                        <p-treeTableToggler [rowNode]=\"rowNode\"></p-treeTableToggler>\n                        <span *ngIf=\" rowData.repeatedMethodCount >0\" class=\"ddr-table-left\" matTooltip=\"View Repeated Details\" (click)=\"showRepeatedData(rowData,0)\">{{rowData.repeatedMethodCount+1 }} </span>\n                        <span *ngIf=\" rowData.repeatedMethodCount >0\" >x </span> \n                        <span [ngSwitch]=\"rowData.showMethodColor\">\n                            <span *ngSwitchCase= \"'unInstrumented'\" style=\"color:gray\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">    \n                                    {{decodeHTMLString(rowData.methodName)}}\n                            </span>\n                                 <span *ngSwitchCase= \"'httpOrthreadCallout'\" class=\"ddr-table-left\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"getChildFLowpathsData(rowNode)\">    \n                                    {{decodeHTMLString(rowData.methodName)}}\n                            </span>\n                             <span *ngSwitchCase= \"'restCallout'\" style=\"color:green\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">    \n                                    {{decodeHTMLString(rowData.methodName)}}\n                            </span>\n                            <span *ngSwitchCase=\"',highlightWallTime'\" style=\"color:red\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                              {{decodeHTMLString(rowData.methodName)}}\n                            </span>\n                            <span *ngSwitchCase=\"'restCallout,highlightWallTime'\" style=\"color:red\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                              {{decodeHTMLString(rowData.methodName)}}\n                            </span>\n                            <span *ngSwitchCase=\"'httpOrthreadCallout,highlightWallTime'\" style=\"color:red\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"getChildFLowpathsData(rowNode)\">\n                              {{decodeHTMLString(rowData.methodName)}}\n                            </span>\n                            <span *ngSwitchCase=\"',highlightWallTime,hghtDiffElapsedTime'\" #diffElapsedTime style=\"color:red\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" >\n                                {{decodeHTMLString(rowData.methodName)}}\n                            </span>\n                            <span *ngSwitchCase=\"'asynCall,hghtDiffElapsedTime'\" #diffElapsedTime #asyncall id=\"{{decodeHTMLString(rowData.methodName.substring(rowData.methodName.lastIndexOf(':')+1,rowData.methodName.length-1))}}\" class=\"ddr-table-left\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">\n                               {{decodeHTMLString(rowData.methodName)}}\n                           </span>\n                            <span *ngSwitchCase=\"',hghtDiffElapsedTime'\" #diffElapsedTime   matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                                {{decodeHTMLString(rowData.methodName)}}\n                            </span>\n                                <span *ngSwitchCase= \"'eventIdLight'\" style=\"color:palevioletred\" matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">    \n                                  {{decodeHTMLString(rowData.methodName)}}\n                              </span>\n                          <span *ngSwitchCase= \"'eventIdDark'\" style=\"color:pink\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">    \n                              {{decodeHTMLString(rowData.methodName)}}\n                                 </span>\n                                 <span *ngSwitchCase= \"'asynCall'\" #asynCall id=\"{{rowData.asyncToBeMatchedId}}\" class=\"ddr-table-left\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">    \n                                  {{decodeHTMLString(rowData.methodName)}}\n                                     </span>\n<span *ngSwitchCase= \"'asynCall,highlightWallTime'\" #asynCall id=\"{{rowData.asyncToBeMatchedId}}\" class=\"ddr-table-left\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"scrollnextTO(rowData)\">    \n                                      {{decodeHTMLString(rowData.methodName)}}\n                                         </span>\n                                     <span *ngSwitchCase= \"'asynCallOutCase'\"  #asynCall  id=\"{{rowData.asyncToBeMatchedId}}\" class=\"ddr-table-left\"  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\" (click)=\"getAsyncExit(rowData)\" >    \n                                      {{decodeHTMLString(rowData.methodName)}}\n                                         </span>\n                                <span *ngSwitchDefault  matTooltip=\"{{decodeHTMLString(rowData.methodName)}}\">\n                                        {{decodeHTMLString(rowData.methodName)}}\n                                </span>\n                              </span>\n                         <span *ngIf=\"rowData.limit >0 && ( rowData.offset <=rowData.last) && rowData.limit < rowData.last && rowData.type==2\" class=\"ddr-table-left\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.limit,rowData.last)\">\n                           Next({{rowData.limit+1}} - {{rowData.offset}} of {{rowData.last}})>>\n                      </span>\n                       <span *ngIf=\"rowData.limit >=0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==1\" class=\"ddr-table-left\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.limit,rowData.last)\">\n                           (Previous({{rowData.limit+1}} - {{rowData.limit+50}} of {{rowData.last}})\n                      </span>\n                       <span *ngIf=\"rowData.limit >= 0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==1\" class=\"ddr-table-left\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,0,rowData.last)\">\n                           &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;FIRST\n                      </span>\n                      <span *ngIf=\"rowData.limit >0 && ( rowData.offset <= rowData.last) && rowData.limit <rowData.last && rowData.type==2\" class=\"ddr-table-left\" (click)=\"expandSameLeveluptoFixLevelforValue(rowData.line,rowData.last,rowData.last)\">\n                           &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;LAST\n                      </span>\n                    </td>\n                    <td *ngIf = \"col.action && col.field == 'threadId'\"  [style.text-align]=\"col.align\">\n                      <span class=\"elipseText\" matTooltip=\"{{(rowData[col.field])}}\">   {{(rowData[col.field])}} </span>\n                    </td>\n\n            <td *ngIf = \"col.action && col.field != 'methodName' && col.field != 'dynLogFlag' && col.field != 'threadId'\"  [style.text-align]=\"col.align\" ttSelectableRowDblClick >\n                {{formatter(rowData[col.field])}}\n            </td>\n\n          </ng-container>\n        </tr>\n    </ng-template>\n    <ng-template pTemplate=\"emptymessage\" let-columns>\n        <tr>\n            <td [attr.colspan]=\"colsForMCT.length\">\n                No Methods available.\n            </td>\n        </tr>\n        </ng-template>\n  </p-treeTable>\n  <p-footer class=\"p-grid p-justify-end\">\n     <button pButton type=\"button\" label=\"Close\" class=\"ui-button-secondary\" (click)=\"visibleArr[i]=false;\"></button>\n  </p-footer>\n</p-dialog>\n</div>\n<style>\n\n.dot {\nheight: 18px;\nwidth: 18px;\nbackground-color: #FF0000;\nborder-radius: 50%;\ndisplay: inline-block;\ncolor: #fff;\ntext-align: center;\nfont: 16px Arial, sans-serif;\n}\n\n</style>\n\n\n  <!--Dialog for Entering FQC -->\n  <p-dialog  class=\"secondary-dialog foterDialog\" [style]=\"{width: '800px'}\" appendTo=\"body\" [resizable]=\"false\"\n  header=\"Enter Fully Qualified Class Name For Dynamic Logging \" *ngIf=\"openDLDialogFromButton\"\n  [(visible)]=\"openDLDialogFromButton\" modal=\"modal\" responsive=\"true\">\n  <form (ngSubmit)=\"openDLbasedOnFQC()\" #groupForm=\"ngForm\" ngNativeValidate>\n      <div class=\"p-grid p-align-center\">\n          <div class=\"p-col-3 red \">\n              <label> Fully Qualified Class Name :</label>\n          </div>\n          <div class=\"p-col-9\">\n              <input name=\"className\"  type=\"text\" size=\"100\" class=\"configUI-profile-dialog w-100-p\" pInputText required\n                  [(ngModel)]=\"FQCforDL\" ngModel />\n          </div>\n        </div>\n        <div class=\"p-justify-end py-8 p-grid w-100-p p-align-center\">\n          <button type=\"button\" class=\"ui-button-sucess mr-6\" pButton icon=\"icons8 icons8-delete\" (click)=\"openDLDialogFromButton=false\"\n              label=\"Cancel\"></button>\n          <button type=\"submit\" class=\"ui-button-sucess mr-6\" pButton icon=\"icons8 icons8-checkmark\" label=\"View\"></button>\n        </div>\n  </form>\n</p-dialog>\n<!-- Common Component code -->\n<app-dynamic-logging  *ngIf=\"ShowCommonDLModule\" (closeDLGui)=\"closeDynamicLogging($event)\" [DynamicLoggingData]=\"argsForDynamicLogging\"></app-dynamic-logging>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/methodtiming/methodtiming.component.html":
/*!*********************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/methodtiming/methodtiming.component.html ***!
  \*********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"ui-panel-contents\">\n  <div>\n    <div class=\"ddr-box\">\n      <div class=\"p-grid p-align-center p-justify-between ui-table-header\">\n        <div class=\"w-70-p\">\n          <span title=\"{{completeTier}}\">{{filterTierName}}</span>\n          <span title=\"{{completeServer}}\">{{filterServerName}}</span>\n          <span title=\"{{completeInstance}}\">{{filterInstanceName}}</span>\n          <span>{{filterCriteria}}</span>\n          <span title=\"{{CompleteURL}}\">{{URLstr}}</span>\n        </div>\n        <div class=\"mt-3\" *ngIf=\"!otelMode\">\n          <span *ngIf=\"isAgent\">\n            <button pButton icon=\"cav debug-trace font-18\" *ngIf=\"displayAutoInst\" class=\"btn-icon\"\n              (click)=\"openAutoInstDialog()\" pTooltip=\"Click to start Dynamic Diagnostics\"></button>\n          </span>\n          <button pButton icon=\"las-etsy font-16\" class=\"btn-icon\" (click)=\"ignoreFlag = true\"\n            pTooltip=\"Exclude Level1 Flowpaths\" tooltipPosition=\"left\"></button>\n          <button pButton icon=\"icons8 icons8-sugar-cube\" class=\"btn-icon\" (click)=\"changeData('package','2')\"\n            pTooltip=\"Show summary of all packages\"></button>\n          <button pButton icon=\"cav wan\" class=\"btn-icon\" (click)=\"changeData('class','1')\"\n            pTooltip=\"Show summary of all classes\"></button>\n          <button pButton icon=\"las-maxcdn font-16\" class=\"btn-icon\" (click)=\"changeData('method','0')\"\n            pTooltip=\"Show summary of all methods\"></button>\n        </div>\n      </div>\n      <!-- COMMON BOX SCROLLLBAR -->\n      <div class=\"ddruiscroll\" [ngStyle]=\"{'height': screenHeight+'px'}\" style=\"overflow:auto;\">\n        <p-dialog class=\"secondary-dialog\" [style]=\"{width: '50vw'}\" [(visible)]=\"loader\" height=\"75\" [closable]=\"false\"\n          [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n          <div *ngIf=\"loader\">\n            <p-progressBar [value]=\"value\"></p-progressBar>\n          </div>\n        </p-dialog>\n        <p-accordion class=\"ddr-accordion\">\n          <p-accordionTab header=\"{{headerStats}}\" [selected]=\"false\">\n            <div class=\"ui-g\">\n              <div class=\"ui-g-6\">\n                <p-card class=\"ddr-graphpanel\" *ngIf=\"showChart; else pieChart\"><highcharts-chart\n                    [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n                    [options]=\"options\"></highcharts-chart></p-card>\n                <ng-template #pieChart>No Pie Chart found based on current Filter Settings.</ng-template>\n              </div>\n              <div class=\"ui-g-6\">\n                <p-card class=\"ddr-graphpanel\" *ngIf=\"showCountPieChart; else CountChart\">\n                  <highcharts-chart [Highcharts]=\"highcharts\" style=\"width: 100%; display: block; overflow: hidden;\"\n                    [options]=\"CountPieChartOptions\"></highcharts-chart></p-card>\n                <ng-template #CountChart>No RespTime Time Graph found based on current Filter Settings.</ng-template>\n              </div>\n            </div>\n          </p-accordionTab>\n        </p-accordion>\n        <div class=\"my-6\">\n          <p-accordion class=\"ddr-accordion\">\n            <p-accordionTab header=\"{{filterType}} Summary (Total: {{dataCount}}) {{pointName}}\" [selected]=\"true\">\n              <cav-table [value]=\"methodTimingData\" [headerRelativePath]=\"relativePath\" [paginator]=\"showPagination\"\n                (clickButtonEvent)=\"clickButtonEvent($event)\" [scrollable]=\"true\" [responsive]=\"true\"\n                scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n            </p-accordionTab>\n          </p-accordion>\n        </div>\n\n        <p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '50vw'}\"\n          header=\"Dynamic Diagnostics Configuration\" [resizable]=\"false\" *ngIf=\"showAutoInstrPopUp\"\n          [(visible)]=\"showAutoInstrPopUp\" modal=\"modal\" [contentStyle]=\"{'max-height':'500px'}\" responsive=\"true\">\n          <app-dynamic-diagnostics (resultAfterStart)=\"startInstrumentation($event)\"\n            (closeAIDDGui)=\"closeAIDDDialog($event)\" [passAIDDSettings]=\"argsForAIDDSetting\"></app-dynamic-diagnostics>\n        </p-dialog>\n\n        <p-dialog class=\"secondary-dialog\" [style]=\"{width: '300px'}\" [resizable]=\"false\" [(visible)]=\"ignoreFlag\"\n          header=\"Exclude Flowpaths\" [responsive]=\"true\">\n          <div class=\"py-20 px-10\">\n            <p-checkbox [(ngModel)]=\"valuechbx\" binary=\"true\" label=\"Exclude L1 Flowpaths\"></p-checkbox>\n          </div>\n          <p-footer>\n            <button pButton type=\"button\" label=\"Apply\" (click)=\"ApplyignoreFP()\"></button>\n          </p-footer>\n        </p-dialog>\n      </div>\n    </div>\n  </div>\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.html":
/*!************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.html ***!
  \************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--component html goes here -->\n<app-page-summary-report *ngIf=\"summary\" [summaryByStatus]=\"summaryByStatus\"></app-page-summary-report>\n<app-page-session-summary *ngIf=\"sessionSummary\"></app-page-session-summary>\n<app-page-instance-report *ngIf=\"instance\"></app-page-instance-report>\n<app-page-failure-report *ngIf=\"failure\"></app-page-failure-report>\n<app-page-component-details *ngIf=\"compDetail\"></app-page-component-details>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.html":
/*!*******************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.html ***!
  \*******************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"ddr-box\">\n\n  <div class=\"ddr-toolbar\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n      <div class=\"p-grid p-justify-between p-align-center px-6 py-3\">\n      <div class=\"group-left textElipse\" style=\"max-width: 1040px;white-space: nowrap;\">\n        <span title=\"{{filterCriteria}}\">{{filterCriteria}}</span>\n      </div>\n      <div class=\"p-grid p-align-center\">\n        <span style=\"padding: 0px 4px;\">TR: {{sessionService.session.testRun.id}}</span>\n      </div>\n      </div>\n    </p-toolbar>\n  </div>\n\n  <div *ngIf=\"isDdrEnabled && !errorData\" class=\"ddruiscroll\" style=\"overflow:auto;height: calc(100vh - 150px);\">\n    <div class=\"ui-g-12\">\n      <p-accordion class=\"ddr-accordion\">\n        <p-accordionTab [selected]=\"true\">\n          <p-header title=\"Page Component Stats {{sessionPct}}\">\n            Page Component Stats {{sessionPct}}\n          </p-header>\n          <div class=\"ui-g\">\n            <div class=\"ui-g-6\">\n              <div class=\"ddr-graphpanel\" *ngIf=\"showPieChart == true\"><highcharts-chart [Highcharts]=\"highcharts\" [options]=\"pieOptions\"></highcharts-chart></div>\n              <div *ngIf=\"showPieChart == false\" style=\"text-align:center;\">No Pie Chart found based on current Filter Settings.</div>\n            </div>\n            <div class=\"ui-g-6\">\n              <div class=\"ddr-graphpanel\" *ngIf=\"showStackedBarChart == true\"><highcharts-chart [Highcharts]=\"highcharts\" [options]=\"stackedBarOptions\"></highcharts-chart></div>\n              <div *ngIf=\"showStackedBarChart == false\" style=\"text-align:center;\">No Bar Chart found based on current Filter Settings.</div>\n            </div>\n          </div>\n          </p-accordionTab>\n        </p-accordion>\n      </div>\n\n      <div class=\"ui-g-12\">\n        <p-accordion class=\"ddr-accordion dynamic-column-width-acc\">\n          <p-accordionTab header=\"Page Component Details\" [selected]=\"true\">\n            <cav-table [value]=\"pageCompDetailInfo\" [responsive]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\"\n              [headerRelativePath]=\"relativePath\"></cav-table>\n          </p-accordionTab>\n        </p-accordion>\n      </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n      <div class=\"p-col text-center\">\n          <h3>Drill Down Report is not configured</h3>\n          <p>You can configure it from scenario: <br>\n              Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"errorData\">\n      <div class=\"p-col text-center\">\n         {{errorData}}\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n    </div>\n\n  </div>\n\n  <p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n      <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer class=\"p-grid p-justify-end\">\n      <button type=\"button\" pButton class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n    <button type=\"button\" pButton class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\"></button>\n    </p-footer>\n  </p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.html":
/*!*************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.html ***!
  \*************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"ddr-box\">\n  <div class=\"ddr-toolbar\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n      <div class=\"p-grid p-justify-between p-align-center px-6 py-3\">\n        <div class=\"group-left textElipse\" style=\"max-width: 1040px;white-space: nowrap;\">\n          <span title=\"{{filterCriteria}}\">{{filterCriteria}}</span>\n        </div>\n        <div class=\"group-right\">\n          <span style=\"padding: 0px 4px;\">TR: {{sessionService.session.testRun.id}}</span>\n        </div>\n      </div>\n    </p-toolbar>\n  </div>\n\n  <div *ngIf=\"isDdrEnabled && !errorData\" class=\"ddruiscroll\">\n      <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n          <div class=\"ui-g\">\n            <div class=\"ui-g-6\">\n              <p-accordionTab header=\"Page Failure Stats\" [selected]=\"true\">\n                <div class=\"ddr-graphpanel\" *ngIf=\"showChart == true\"><highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\"></highcharts-chart></div>\n                <div *ngIf=\"showChart == false\" style=\"text-align:center;\">No Column Chart found based on current Filter Settings.</div>\n              </p-accordionTab>\n            </div>\n\n            <div class=\"ui-g-6\">\n              <p-accordionTab header=\"Failure Detail Report for Page\" [selected]=\"true\">\n                <cav-table [value]=\"pageFailureData\" [responsive]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\"\n                [headerRelativePath]=\"relativePath\"></cav-table>\n             </p-accordionTab>\n            </div>\n          </div>\n        </p-accordion>\n\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n    <div class=\"p-col text-center\">\n        <h3>Drill Down Report is not configured</h3>\n        <p>You can configure it from scenario: <br>\n            Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"errorData\">\n    <div class=\"p-col text-center\">\n       {{errorData}}\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n  \n</div>\n\n<p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n  <p-header>\n    <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n      <span>Query load process</span>\n  </p-header>\n  <p>{{this.commonService.cancelationMessage}} </p>\n  <p-footer class=\"p-grid p-justify-end\">\n    <button type=\"button\" pButton  class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n  <button type=\"button\" pButton  class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\"></button>\n  </p-footer>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.html":
/*!***************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.html ***!
  \***************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"ddr-box\">\n  <div class=\"ddr-toolbar\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n      <div class=\"p-grid p-justify-between px-6 py-3\">\n        <div class=\"p-grid p-align-center\">\n          <label class=\"headerInfo\">{{filterCriteria}}</label>\n          <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{filterStatus}}</label>\n          <label class=\"headerInfo\" title=\"{{toolTipUrl}}\">{{filterUrl}}</label>\n        </div>\n\n        <div class=\"p-grid p-align-center\">\n          <span style=\"padding: 0px 4px;\">TR: {{sessionService.session.testRun.id}}</span>\n        </div>\n      </div>\n    </p-toolbar>\n  </div>\n\n  <div class=\"ddruiscroll\" *ngIf=\"isDdrEnabled && !errorData\">\n    <p-accordion class=\"ddr-accordion\">\n      <p-accordionTab [selected]=\"true\">\n        <p-header title=\"Page Instance Report {{sessionPct}}\">\n          Page Instance Report {{sessionPct}}\n        </p-header>\n        <div class=\"p-grid p-align-center p-justify-end p-3\">\n        </div>\n\n        <cav-table [value]=\"pageInstanceData\" [scrollable]=\"true\" [headerRelativePath]=\"relativePath\"\n          [paginator]=\"true\" (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"totalCount\" [first]=\"first\" [rows]=\"rows\"\n          [lazyLoadingProcessBar]=\"loading\" scrollHeight=\"calc(100vh - 290px)\"\n          (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>\n      </p-accordionTab>\n    </p-accordion>\n\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n    <div class=\"p-col text-center\">\n        <h3>Drill Down Report is not configured</h3>\n        <p>You can configure it from scenario: <br>\n            Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"errorData\">\n    <div class=\"p-col text-center\">\n       {{errorData}}\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n</div>\n\n<p-dialog class=\"ddr-dialog\" appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" modal=\"modal\"\n  [style]=\"{ 'width':'600px'}\">\n  <p-header>\n    <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n    <span> Query load process</span>\n  </p-header>\n  <p>{{this.commonService.cancelationMessage}} </p>\n  <p-footer class=\"p-grid p-justify-end\">\n\n    <button type=\"button\" pButton class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\"\n      [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n    <button type=\"button\" pButton class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\"></button>\n  </p-footer>\n</p-dialog>\n\n\n<p-dialog [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\" [closable]=\"false\"\n  [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\" [showHeader]=\"false\">\n  <div *ngIf=\"loader\">\n    <p-progressBar [value]=\"value\"></p-progressBar>\n  </div>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.html":
/*!***************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.html ***!
  \***************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"ddr-box\">\n\n  <div class=\"ddr-toolbar\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n      <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n      <div class=\"group-left textElipse\" style=\"max-width: 1040px;white-space: nowrap;\">\n        <span title=\"{{filterCriteria}}\">{{filterCriteria}}</span>\n      </div>\n      <div class=\"group-right\" >\n        <span style=\"padding: 0px 4px;\">TR: {{sessionService.session.testRun.id}}</span>\n      </div>\n      </div>\n    </p-toolbar>\n  </div>\n\n  <div class=\"ddruiscroll\" *ngIf=\"isDdrEnabled && !errorData\">\n      <p-accordion class=\"ddr-accordion\">\n        <p-accordionTab styleClass=\"elipseText\"  [selected]=\"true\">\n          <p-header title=\"Page Session Summary {{sessionPct}}\">\n            Page Session Summary {{sessionPct}}\n          </p-header>\n          <div class=\"p-grid p-align-center p-justify-end\">\n            </div>\n              <cav-table [value]=\"pageSessionSummaryData\" (clickButtonEvent)=\"clickButtonEvent($event)\" \n              [paginator]=\"true\" (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"totalCount\" [first]=\"first\" [rows]=\"rows\" \n              [lazyLoadingProcessBar]=\"loading\" [headerRelativePath]=\"relativePath\"></cav-table>\n          </p-accordionTab>\n      </p-accordion>\n\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n    <div class=\"p-col text-center\">\n        <h3>Drill Down Report is not configured</h3>\n        <p>You can configure it from scenario: <br>\n            Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"errorData\">\n    <div class=\"p-col text-center\">\n       {{errorData}}\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n</div>\n\n<p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n  <p-header>\n    <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n      <span>Query load process</span>\n  </p-header>\n  <p>{{this.commonService.cancelationMessage}} </p>\n  <p-footer class=\"p-grid p-justify-end sevbtn\">\n    <button type=\"button\" pButton (click)=\"onCancelQuery();\" class=\"ui-button-rounded ui-toolbar-secondary mx-6\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n  <button type=\"button\" pButton (click)=\"waitQuery();\"  class=\"ui-button-rounded\" label=\"Wait\"></button>\n  </p-footer>\n</p-dialog>\n<p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\" [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n  <div *ngIf=\"loader\">\n    <p-progressBar [value]=\"value\"></p-progressBar>\n  </div>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.html":
/*!*************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.html ***!
  \*************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"ddr-box\">\n\n  <div class=\"ddr-toolbar\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n      <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n        <div class=\"group-left textElipse\" style=\"max-width: 1040px;white-space: nowrap;\">\n          <ng-container *ngIf=\"filterCriteria || filterStatus || filterUrl\">\n            <label class='headerInfo'>\n              <b>Filter Criteria : </b>\n            </label>\n            <label class=\"headerInfo\" title=\"{{filterCriteria}}\">{{filterCriteria}}</label>\n            <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{filterStatus}}</label>\n            <label class=\"headerInfo\" title=\"{{toolTipUrl}}\">{{filterUrl}}</label>\n          </ng-container>\n        </div>\n        <div class=\"group-right\">\n                <span style=\"padding: 0px 4px;\">TR: {{sessionService.session.testRun.id}}</span>\n         </div>\n      </div>\n\n    </p-toolbar>\n  </div>\n\n  <div class=\"ddruiscroll\" *ngIf=\"isDdrEnabled && !errorData\">\n    <p-accordion class=\"ddr-accordion\">\n      <p-accordionTab styleClass=\"elipseText\"  [selected]=\"true\">\n        <p-header title=\"{{tableHeader}} {{sessionPct}}\">\n          {{tableHeader}} {{sessionPct}}\n        </p-header>\n\n        <cav-table [value]=\"pageSummaryData\" [tableConfig]=\"tableConfig\" [headers]=\"colsForTable\" [scrollable]=\"true\"\n          (clickButtonEvent)=\"clickButtonEvent($event)\" scrollHeight=\"calc(100vh - 290px)\" [paginator]=\"true\" [lazy]=\"true\"\n          (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"totalCount\" [first]=\"first\" [rows]=\"rows\"\n          [rowsPerPageOptions]=\"[50,100,200,400,700,1000]\" [lazyLoadingProcessBar]=\"loading\" [showCurrentPageReport]=\"true\">\n        </cav-table>\n      </p-accordionTab>\n    </p-accordion>\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n    <div class=\"p-col text-center\">\n        <h3>Drill Down Report is not configured</h3>\n        <p>You can configure it from scenario: <br>\n            Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n  \n  <div class=\"no-transactions\" *ngIf=\"errorData\">\n    <div class=\"p-col text-center\">\n       {{errorData}}\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n</div>\n\n<p-dialog appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [style]=\"{ 'width':'600px'}\">\n  <p-header>\n    <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n    <span>Query load process</span>\n  </p-header>\n  <p>{{this.commonService.cancelationMessage}} </p>\n  <p-footer class=\"p-grid p-justify-end\">\n    <button type=\"button\" pButton class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\"\n      [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n    <button type=\"button\" pButton class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\"></button>\n  </p-footer>\n</p-dialog>\n\n<p-dialog [(visible)]=\"loader\" [showHeader]=\"false\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\"\n  [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n  <div *ngIf=\"loader\">\n    <p-progressBar [value]=\"value\"></p-progressBar>\n  </div>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-reports.component.html":
/*!*****************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-reports.component.html ***!
  \*****************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--component html goes here -->\n<ns-session-report *ngIf=\"sessionReport\" [id]=\"id\" ></ns-session-report>\n<ns-url-report *ngIf=\"urlReport\" [id]=\"id\" ></ns-url-report>\n<ns-page-report *ngIf=\"pageReport\" [id]=\"id\" ></ns-page-report>\n<ns-transaction-report *ngIf=\"transactionReport\" [id]=\"id\" ></ns-transaction-report>\n<app-ns-usersessions-report *ngIf=\"userSessionReport\" [id]=\"id\"></app-ns-usersessions-report>\n\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.html":
/*!******************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.html ***!
  \******************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--component html goes here -->\n<session-instance-report *ngIf=\"instanceReport\"></session-instance-report>\n<session-summary-report *ngIf=\"summaryReport\" [summaryReportByStatus]=\"summaryReportByStatus\"></session-summary-report>\n<session-failure-report *ngIf=\"sessionFailure\"></session-failure-report>\n<session-detail-report *ngIf=\"sessionDetail\"></session-detail-report>\n<session-timing-detail *ngIf=\"sessionTiming\"></session-timing-detail>\n\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.html":
/*!********************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.html ***!
  \********************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--component html goes here -->\n<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n<div class=\"ddr-box\">\n    <p-toolbar>\n        <div class='ui-toolbar-group-left'>\n            <label class='headerInfo'>{{filterCriteria}}</label>\n        </div>\n        <div class=\"ui-toolbar-group-right\">\n          <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n       </div>\n    </p-toolbar>\n    <div *ngIf=\"isDdrEnabled && !errorData\" style=\"overflow:auto;max-height:83vh\">\n        <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n            <div>\n              <!-- {{thinkData}} -->\n              <p-accordionTab header=\"Average Time\" [selected]=\"true\">\n                <cav-table [value]=\"thinkData\" [responsive]=\"true\" [headerRelativePath]=\"thinkDataPath\"\n                ></cav-table>\n            \n              </p-accordionTab>\n            </div>\n            <div class=\"ui-g-12\">\n                <div class=\"ui-g-6\">\n                    <p-accordionTab header=\"Average Time Stats\" [selected]=\"true\">\n                        <div style=\"overflow:auto;height:421px\">\n                            <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\"></highcharts-chart>\n                        </div>\n                    </p-accordionTab>\n                </div>\n                <div class=\"ui-g-6\">\n                    <p-accordionTab header=\"Split Time Stats\" [selected]=\"true\">\n                        <div style=\"overflow:auto;height:421px\">\n                            <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options1\"></highcharts-chart>\n                        </div>\n                    </p-accordionTab>\n                </div>\n            </div>\n            <div class=\"ui-g-12\">\n              <p-accordionTab header=\"Page Detail\" [selected]=\"true\">\n                <cav-table [value]=\"data\" [responsive]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\"\n                  [headerRelativePath]=\"pageDetailPath\"></cav-table>\n              </p-accordionTab>\n            </div>\n        </p-accordion>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n      <div class=\"p-col text-center\">\n          <h3>Drill Down Report is not configured</h3>\n          <p>You can configure it from scenario: <br>\n              Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"errorData\">\n      <div class=\"p-col text-center\">\n         {{errorData}}\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n    </div>\n    \n</div>\n<p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n        <i class=\"fa fa-info-circle\" style=\"color:red\"></i>\n        <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n    </p-header>\n    <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n    <p-footer>\n    <button type=\"button\" pButton icon=\"fa fa-clock-o \" (click)=\"waitQuery();\" label=\"Wait\" style=\"height: 25px;\"></button>\n    <button type=\"button\" pButton icon=\"fa fa-times\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\" style=\"height: 25px;\"></button>\n    </p-footer>\n  </p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.html":
/*!**********************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.html ***!
  \**********************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--component html goes here -->\n<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n<div class=\"ddr-box\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n        <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n        <div class=\"ui-toolbar-group-left textElipse height-14\" style=\"max-width: 1040px;white-space: nowrap;\">\n            <label class=\"headerInfo\" title=\"{{filterCriteria}}\">{{filterCriteria}}</label>\n            <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{failureFilter}}</label>\n        </div>\n        <div class=\"ui-toolbar-group-right\">\n            <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n        </div>\n        </div>\n    </p-toolbar>\n\n    <div *ngIf=\"isDdrEnabled && !errorData\">\n        <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n            <div class=\"ui-g-6\">\n                <p-accordionTab header=\"Session Failure Stats\" [selected]=\"true\">\n                    <div class=\"ddr-graphpanel\">\n                        <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\"></highcharts-chart>\n                    </div>\n                </p-accordionTab>\n            </div>\n            <div class=\"ui-g-6\">\n                <p-accordionTab header=\"Session Failure\" [selected]=\"true\">\n                    \n                    <cav-table [value]=\"data\" [responsive]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\"\n                    [headerRelativePath]=\"relativePath\"\n                    ></cav-table>                            \n                \n                </p-accordionTab>\n            </div>\n        </p-accordion>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n        <div class=\"p-col text-center\">\n            <h3>Drill Down Report is not configured</h3>\n            <p>You can configure it from scenario: <br>\n                Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n      </div>\n\n      <div class=\"no-transactions\" *ngIf=\"errorData\">\n        <div class=\"p-col text-center\">\n           {{errorData}}\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n      </div>\n\n</div>\n<p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n        <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer class=\"p-grid p-justify-end\">\n        <button type=\"button\" pButton (click)=\"onCancelQuery();\"  class=\"ui-button-rounded ui-toolbar-secondary mx-6\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n    <button type=\"button\" pButton (click)=\"waitQuery();\"  class=\"ui-button-rounded\" label=\"Wait\"></button>\n    </p-footer>\n  </p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.html":
/*!************************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.html ***!
  \************************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n<div class=\"ddr-box\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n        <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n            <div class=\"ui-toolbar-group-left textElipse height-14\" style=\"max-width: 900px;white-space: nowrap;\">\n                <label class=\"headerInfo\">{{filterCriteria}}</label>\n                <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{filterStatus}}</label>\n                <label class=\"headerInfo\" title=\"{{toolTipUrl}}\">{{filterUrl}}</label>\n            </div>\n            <div class=\"p-grid p-align-center p-justify-end p-3\" style=\"max-width: 325px;\">\n                <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n            </div>\n        </div>\n    </p-toolbar>\n\n\n            <!-- COMMON BOX SCROLLLBAR -->\n<div *ngIf=\"isDdrEnabled && !errorData\" class=\"ddruiscroll\"  style=\"overflow:auto; max-height:85vh\">\n    <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n        <p-accordionTab styleClass=\"elipseText\" [selected]=\"true\">\n            <p-header title=\"Session Instance {{sessionPct}}\">\n                Session Instance {{sessionPct}}\n            </p-header>\n            <div class=\"p-grid p-align-center p-justify-end p-3\">\n            </div>\n            <cav-table [value]=\"data\" [headerRelativePath]=\"relativePath\"\n                scrollHeight=\"calc(100vh - 290px)\" [paginator]=\"true\" (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"totalCount\" [first]=\"first\" [rows]=\"rows\"\n                (clickButtonEvent)=\"clickButtonEvent($event)\" [lazyLoadingProcessBar]=\"loading\"></cav-table>\n        </p-accordionTab>\n    </p-accordion>\n</div>\n\n<div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n    <div class=\"p-col text-center\">\n        <h3>Drill Down Report is not configured</h3>\n        <p>You can configure it from scenario: <br>\n            Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"errorData\">\n    <div class=\"p-col text-center\">\n       {{errorData}}\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n</div>\n<p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\" >\n    <p-header>\n        <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n\n    <p-footer class=\"p-grid p-justify-end\">\n        <button type=\"button\" pButton (click)=\"onCancelQuery();\" class=\"ui-button-rounded ui-toolbar-secondary mx-6\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n    <button type=\"button\" pButton (click)=\"waitQuery();\" class=\"ui-button-rounded\" label=\"Wait\"></button>\n    </p-footer>\n  </p-dialog>\n  <p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\" [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n    <div *ngIf=\"loader\">\n      <p-progressBar [value]=\"value\"></p-progressBar>\n    </div>\n  </p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.html":
/*!**********************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.html ***!
  \**********************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"ddr-box\">\n  <p-toolbar class=\"ui-toolbar-secondary\">\n    <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n        <div class=\"ui-toolbar-group-left textElipse\" style=\"max-width: 1040px;white-space: nowrap;\">\n          <ng-container *ngIf=\"filterCriteria || filterStatus || filterUrl\">\n            <label class='headerInfo'>\n              <b>Filter Criteria : </b>\n            </label>\n            <label class=\"headerInfo\" title=\"{{filterCriteria}}\">{{filterCriteria}}</label>\n            <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{filterStatus}}</label>\n            <label class=\"headerInfo\" title=\"{{toolTipUrl}}\">{{filterUrl}}</label>\n          </ng-container>\n        </div>\n        <div class=\"ui-toolbar-group-right\">\n          <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n        </div>\n        </div>\n    </p-toolbar>\n        <!-- COMMON BOX SCROLLLBAR -->\n<div *ngIf=\"isDdrEnabled && !errorData\" class=\"ddruiscroll\"  style=\"overflow:auto; height:85vh;\">\n    <p-accordion class=\"ddr-accordion\" [multiple]=\"true\"> \n        <p-accordionTab styleClass=\"elipseText\"  [selected]=\"true\">\n          <p-header title=\"Session Summary {{sessionPct}}\">\n            Session Summary {{sessionPct}}\n          </p-header>\n            <div>\n\n              <cav-table [value]=\"data\" [tableConfig]=\"tableConfig\" [headers]=\"colsForTable\" [scrollable]=\"true\"\n                (clickButtonEvent)=\"clickButtonEvent($event)\" scrollHeight=\"calc(100vh - 290px)\" [paginator]=\"true\" [lazy]=\"true\"\n                (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"count\" [first]=\"first\" [rows]=\"rows\"\n                [rowsPerPageOptions]=\"[50,100,200,400]\" [lazyLoadingProcessBar]=\"loading\" [showCurrentPageReport]=\"true\">\n              </cav-table>\n            </div>\n        </p-accordionTab>\n    </p-accordion>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n      <div class=\"p-col text-center\">\n          <h3>Drill Down Report is not configured</h3>\n          <p>You can configure it from scenario: <br>\n              Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"errorData\">\n      <div class=\"p-col text-center\">\n         {{errorData}}\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n    </div>\n</div>\n<p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n      <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer class=\"p-grid p-justify-end\">\n      <button type=\"button\" pButton (click)=\"onCancelQuery();\" class=\"ui-button-rounded ui-toolbar-secondary mx-6\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n      <button type=\"button\" pButton (click)=\"waitQuery();\" class=\"ui-button-rounded\" label=\"Wait\"></button>\n    </p-footer>\n  </p-dialog>\n  <p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\" [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n    <div *ngIf=\"loader\">\n      <p-progressBar [value]=\"value\"></p-progressBar>\n    </div>\n  </p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.html":
/*!**************************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.html ***!
  \**************************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<p-sidebar [(visible)]=\"showTansactionTimeSidebar\" [modal]=\"false\" [showCloseIcon]=\"false\" class=\"sidebarHeightClass\"\n    position=\"bottom\" [baseZIndex]=\"-900\">\n    <div class=\"w-100-p p-grid p-16 p-align-center\">\n        <div class=\"w-100-p p-grid p-align-center my-8 p-justify-between\">\n            <div class=\"font-weight-600 font-16\">End-to-end {{dataObj.reportType == 'Url' ? dataObj.reportType.toUpperCase() : dataObj.reportType }} Time</div>\n            <div class=\"p-grid p-align-center\">\n                <div *ngIf=\"togglingTreeTable || isCallOut\">\n                    Loading <i class=\"icons8 icons8-loading spin text-danger mx-5\"></i>\n                    <!-- <i class=\"icons8 icons8-spinner spin\"></i> -->\n                </div>\n                <button type=\"button\" pButton (click)=\"closeSideBar()\" class=\"btn-icon \"\n                    icon=\"las-times-solid font-18\"></button>\n            </div>\n        </div>\n        <div class=\"w-100-p p-grid p-align-center my-8 p-justify-between\">\n            <div class=\"p-grid p-align-center\">\n                <button pButton type=\"button\" label=\"Expand All\" (click)=\"expandCollapse(true)\" class=\"btn-secondary-outline\"></button>\n                <button pButton type=\"button\" label=\"Collapse All\" (click)=\"expandCollapse(false)\" class=\"btn-secondary-outline ml-10\"></button>\n            </div>\n            \n            <!-- <button pButton type=\"button\" icon=\"icons8 icons8-columns\" class=\"btn-icon \"></button> -->\n            <p-multiSelect class=\"icon-button no-shadow\" [options]=\"cols\" [(ngModel)]=\"tableColsSelected\" optionLabel=\"header\"\n                   [displaySelectedLabel]=\"false\" (onChange)=\"onChangeMultiselect($event)\"\n                  dropdownIcon=\"icons8 icons8-columns font-18\" matTooltip=\"Show/Hide columns\" styleClass=\"dropdown-panel-left\">\n            </p-multiSelect>\n            \n        </div>\n        <p-treeTable #treeTable [scrollable]=\"true\" scrollHeight=\"calc(100vh - 200px)\" [columns]=\"tableCols\"\n            [value]=\"treeTableData\"  [rows]=\"5\">\n            <ng-template pTemplate=\"colgroup\" let-columns>\n                <colgroup>\n                    <col [style]=\"{'width': col.width + '%'}\" *ngFor=\"let col of columns\" />\n                </colgroup>\n            </ng-template>\n\n            <ng-template pTemplate=\"header\" let-columns>\n                      <tr>\n                          <th *ngFor=\"let col of columns\">\n                              {{ col.header }}\n                          </th>\n                      </tr>\n                  </ng-template>\n\n            <ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\" let-columns=\"columns\">\n                <tr [ttRow]=\"rowNode\">\n                    <td *ngFor=\"let col of columns; let i = index\">\n                        <div class=\"w-100-p p-grid p-align-center \" >\n\n                            <p-treeTableToggler class=\"pt-12\" [rowNode]=\"rowNode\" *ngIf=\"i == 0\">\n                            </p-treeTableToggler>\n                           \n                            <i *ngIf=\"rowNode.node.data.name === 'First Byte' && i === 0 && dataObj.ndKeyValue\" (click)=\"openCalloutTreeTable(rowData, rowNode.parent.data)\"\n                                [ngClass]=\"calloutTreeTableData[rowNode.node.data.flowpath] && calloutTreeTableData[rowNode.node.data.flowpath]['isTableIconCollapsed'] ? 'pi pi-chevron-down pt-5 ' : 'pi pi-chevron-right pt-5 ' \"></i>\n\n                            <span  [ngClass]=\"col.field == 'absStartTime' || col.field == 'duration' ? 'text-right' : 'text-left'\" class=\"pt-5 p-col p-col-nogutter elipseText\" >\n                                <span  *ngIf=\"((rowNode.level != 3 && rowNode.level != 1 && rowNode.node.data.name != 'First Byte') || (rowNode.level == 1 && i != 0) || (rowNode.level == 3 && i != 0) || (rowNode.node.data.name == 'First Byte' && col.field != 'duration') || (rowNode.node.data.name == 'First Byte' && col.field == 'duration' && !dataObj.ndKeyValue)) && col.field != 'absStartTime' && col.field != 'duration'\" [matTooltip]=\"rowData[col.field]\" tooltipPosition=\"top\">\n                                    {{ rowData[col.field] }}\n                                </span>  \n                                <span *ngIf=\"rowNode.level == 1 && i == 0 && dataObj.pdKeyValue\" style=\"color:blue\" [matMenuTriggerFor]=\"urlMenu\" class=\"clickable\" [matTooltip]=\"rowData[col.field] | DdrConversionPipe\" tooltipPosition=\"top\">\n                                    {{ rowData[col.field] | DdrConversionPipe}}\n                                </span> \n                                \n                                <span *ngIf=\"(rowNode.level == 3 && i == 0) || (rowNode.level == 1 && i == 0 && !dataObj.pdKeyValue)\" [matTooltip]=\"rowData[col.field] | DdrConversionPipe\" tooltipPosition=\"top\">\n                                     {{rowData[col.field] | DdrConversionPipe}}\n                                </span> \n\n                                <span *ngIf=\"col.field == 'absStartTime'\" [matTooltip]=\"rowData[col.field] | ddrDateTransform\" tooltipPosition=\"top\">\n                                    {{rowData[col.field] | ddrDateTransform}}\n                               </span> \n\n                               <span *ngIf=\"rowNode.node.data.name === 'First Byte' && col.field == 'duration' && dataObj.ndKeyValue\" style=\"color:blue\" (click)=\"openFlowpathReport(rowData)\" class=\"clickable\" matTooltip=\"Open FlowPath\" tooltipPosition=\"top\">\n                                {{ rowData[col.field] | ddrDurationTransform}}\n                                </span> \n\n                                <span *ngIf=\"rowNode.node.data.name != 'First Byte' && col.field == 'duration'\" [matTooltip]=\"rowData[col.field] | ddrDurationTransform\" tooltipPosition=\"top\">\n                                    {{rowData[col.field] | ddrDurationTransform}}\n                               </span>\n\n                                <!-- <span *ngIf=\"rowNode.level == 3 && i == 0\" [matTooltip]=\"rowData[col.field]\" tooltipPosition=\"top\">\n                                    {{rowData['method']}} {{rowData[col.field]}}\n                                </span>  -->\n                            </span>\n\n                            <!-- button for url network menu -->\n                           \n                            <mat-menu #urlMenu=\"matMenu\">\n                                <button mat-menu-item (click)=\"ViewNetworkLogs(rowNode.node.data)\">Open network logs for current page</button>\n                                <button mat-menu-item (click)=\"ViewNetworkLogs(rowNode.node.data,true)\">Open network logs for current session</button>\n                            </mat-menu>\n                           \n                        </div>\n                    </td>\n                </tr>\n\n    <tr *ngIf=\"rowNode.node.data.name === 'First Byte' && calloutTreeTableData[rowNode.node.data.flowpath] && calloutTreeTableData[rowNode.node.data.flowpath]['isTableIconCollapsed'] && !calloutTreeTableData[rowNode.node.data.flowpath]['loading']\">\n        <td [attr.colspan]=\"columns.length\" style=\"padding:0\" class=\"w-100-p \">\n            <p-treeTable #calloutTT [columns]=\"tableColsFirstBytes\" scrollHeight=\"calc(100vh - 180px)\"\n                [value]=\"calloutTreeTableData[rowNode.node.data.flowpath]['data']\" [rows]=\"5\">\n                <ng-template pTemplate=\"colgroup\" let-columns>\n                    <colgroup>\n                        <col [style]=\"{'width': col.width + '%' }\" *ngFor=\"let col of columns\" />\n                    </colgroup>\n                </ng-template>\n                <ng-template pTemplate=\"body\" let-rowNodeForTable let-rowData=\"rowData\" let-columns=\"columns\">\n                    <tr>\n                        <td [ngStyle]=\"{'padding-left': i == 0 ? '102px' :'' }\" *ngFor=\"let col of columns; let i = index\">\n                            <div class=\"w-100-p p-grid p-align-center\">\n                                <p-treeTableToggler class=\"pt-5\" [rowNode]=\"rowNodeForTable\" *ngIf=\"i == 0\">\n                                </p-treeTableToggler>\n                                <span *ngIf=\"col.field != 'startTimeInMs' && col.field != 'selfResponseTime' && col.field != 'urlName'\" [ngClass]=\"col.field == 'selfResponseTime' ? 'pt-5 p-col p-col-nogutter elipseText text-right' : 'text-left'\" style=\"width:80%\" tooltipPosition=\"top\" [matTooltip]=\"rowData[col.field]\"\n                                    class=\"elipseText\">\n                                    {{ rowData[col.field]}}\n                                </span>\n\n                                <span *ngIf=\"col.field == 'selfResponseTime'\" class=\"pt-5 p-col p-col-nogutter elipseText text-right\" [matTooltip]=\"rowData[col.field] | ddrDurationTransformForCallOut\" tooltipPosition=\"top\">\n                                {{ rowData[col.field] | ddrDurationTransformForCallOut}}\n                                </span>\n\n                                <span *ngIf=\"col.field == 'startTimeInMs'\" class=\"pt-5 p-col p-col-nogutter elipseText text-right\" [matTooltip]=\"rowData[col.field] | ddrDateTransform\" tooltipPosition=\"top\">\n                                    {{rowData[col.field] | ddrDateTransform}}\n                               </span> \n\n                               <span *ngIf=\"col.field == 'urlName'\">\n                                    {{ rowData[col.field] != \"-\" ? rowData[col.field] : rowData['backEndName'] && rowData['backEndName'] != \"\"  ? rowData['backEndName'] :  rowData['backendType']}} {{ rowData['count'] > 1 ? 'X ' + rowData['count'] : '' }}\n                               </span>\n        \n                            </div>\n                        </td>\n                    </tr>\n                </ng-template>\n                <ng-template pTemplate=\"emptymessage\" let-columns>\n                    <tr>\n                        <td [attr.colspan]=\"columns.length + 1\" class=\"text-center\">\n                            No records found\n                        </td>\n                    </tr>\n                </ng-template>\n            </p-treeTable>\n        </td>\n</tr>\n    </ng-template>\n    </p-treeTable>\n    </div>\n</p-sidebar>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.html":
/*!********************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.html ***!
  \********************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--component html goes here -->\n<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"blockedUI\" *ngIf=\"isLoading\">\n  <i class=\"icons8 icons8-spinner spin\"></i>\n</div>\n\n\n<div class=\"no-transactions\" *ngIf=\"errorData\">\n  <div class=\"p-col text-center\">\n     {{errorData}}\n  </div>\n  <div class=\"p-col-fixed text-center\">\n      <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n  </div>\n</div>\n\n<div *ngIf=\"!errorData\" class=\"ddr-box\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n        <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n        <div class=\"ui-toolbar-group-left textElipse height-14\" style=\"max-width: 1040px; white-space: nowrap;\">\n            <label class=\"headerInfo\" title=\"{{filterCriteria}}\">{{filterCriteria}}</label>\n        </div>\n        <div class=\"ui-toolbar-group-right\">\n            <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n            <span class=\"pl-5\" style=\"opacity: .5;\">|</span>\n            <button type=\"button\" pButton [disabled]=\"!isDdrEnabled || errorData\" class=\"btn-icon btn-white\" icon=\"icons8 icons8-download\" title=\"Download\"\n              [matMenuTriggerFor]=\"menu\"></button>\n            <mat-menu #menu=\"matMenu\">\n              <button mat-menu-item [disabled]=\"tableData.length == 0\" (click)='downloadReports(\"pdf\")'>\n                <i class=\"icons8 icons8-pdf-2\"></i>\n                <span>PDF</span>\n              </button>\n              <button mat-menu-item [disabled]=\"tableData.length == 0\" (click)='downloadReports(\"excel\")'>\n                <i class=\"icons8 icons8-spreadsheet-file\"></i>\n                <span>Excel</span>\n              </button>\n              <button mat-menu-item [disabled]=\"tableData.length == 0\" (click)='downloadReports(\"worddoc\")'>\n                <i class=\"icons8 icons8-word\"></i>\n                <span>Word</span>\n              </button>\n            </mat-menu>\n        </div>\n        </div>\n    </p-toolbar>\n    <div *ngIf=\"isDdrEnabled\"  style=\"overflow: auto; max-height: calc(100vh - 140px);\">\n        <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n                <p-accordionTab header=\"{{reportType}} Detail Stats\" [selected]=\"true\">\n                    <div class=\"p-grid p-align-center\">\n                    <div class=\"p-col-3 textElipse\">\n                        <strong class=\"mr-5\">{{reportType}}:</strong><span title=\"{{pageName}}\">{{pageName}}</span> </div>\n\n                        <div *ngIf=\"!this.sessionService.session.testRun.cmt\" class=\"p-col-4\" >\n                          <strong class=\"mr-5\" title=\"Relative time since start of the test in HH:MM:SS.ms\">Start Time:</strong>{{msToTimeFormate(startTime)}}\n                          (Absolute Time: {{nsCommonData._sendAbsoluteTime}})\n                        </div>\n\n                        <div *ngIf=\"this.sessionService.session.testRun.cmt\" class=\"p-col-4\" >\n                          <strong class=\"mr-5\" title=\"Relative time since start of the test in HH:MM:SS.ms\">Absolute Time:</strong>{{nsCommonData._sendAbsoluteTime}}\n                        </div>\n                        \n\n                        <div class=\"p-col-2\">\n                          <strong class=\"mr-5\">Response Time:</strong>{{respTime}} (Seconds)\n                        </div>\n                        \n                        <div class=\"p-col-1\">\n                          <strong class=\"mr-5\">Status:</strong>{{status}}\n                        </div>\n                        \n                        <div class=\"p-col-2 textElipse\">\n                          <strong class=\"mr-5\">Total Bytes:</strong>{{totalBytes}}\n                        </div>\n\n                    </div>\n                    <div *ngIf=\"chartData && chartData.length != 0\">\n                      <table border=\"1\" style=\"width: 100%; table-layout: fixed; border: solid 1px #d8dae2; border-block-color: initial; border-block: initial\">\n                        <colgroup>\n                        <col style=\"width: 30%\">\n                        <col style=\"width: 70%;\">\n                        </colgroup>  \n                        \n                        \n                        <tr>\n                              <td colspan='2'>&nbsp;</td>\n                          </tr>\n          <tr *ngFor=\"let d of chartData\">\n              <td *ngIf=\"(d.objName.startsWith('Page'))\" nowrap  title='{{d.objName}}'>\n                  {{d.objName}}\n              </td>\n              <td *ngIf=\"(d.objName.startsWith('Page'))\">\n                  <img src='./assets/images/dotclear.gif' *ngIf=\"strinToNum(d.startPix) > 0\" border='0' height='10' width='{{d.startPix}}'>\n  \n                  <img src='./assets/images/0.gif' title='{{showToolTipForPageDownload(\"Page Download Time\",d.objName,d.intvalSec)}}' border='0' height='10' width='{{d.intvalPix}}'>\n              </td>\n  \n              <td *ngIf=\"(d.objName.startsWith('Conn'))\" nowrap  title='{{d.objName}}'>\n                  {{d.instance}}: {{truncateUrl(d.object,60)}}\n              </td>\n              <td *ngIf=\"(d.objName.startsWith('Conn'))\" title='{{showToolTip(d)}}'>\n                  <img src='./assets/images/dotclear.gif' *ngIf=\"strinToNum(d.startPix) > 0\" border='0' height='10' width='{{d.startPix}}'>\n  \n                  <img src='./assets/images/6.gif'  *ngIf=\"strinToNum(d.dnsLookupSec) > 0\" border='0' height='10' width='{{d.dnsLookupPix}}'>\n  \n                  <img src='./assets/images/1.gif'  *ngIf=\"strinToNum(d.connecPix) > 0\" border='0' height='10' width='{{d.connecPix}}'>\n  \n                 <img src='./assets/images/2.gif'  *ngIf=\"strinToNum(d.sslPix) > 0\" border='0' height='10' width='{{d.sslPix}}'>\n  \n                 <img src='./assets/images/3.gif'  *ngIf=\"strinToNum(d.writePix) > 0\" border='0' height='10' width='{{d.writePix}}'>\n  \n                  <img src='./assets/images/4.gif'  *ngIf=\"strinToNum(d.firstPix) > 0\" border='0' height='10' width='{{d.firstPix}}'>\n  \n                  <img src='./assets/images/5.gif'  *ngIf=\"strinToNum(d.contentPix) > 0\" border='0' height='10' width='{{d.contentPix}}'>\n              </td>\n          </tr>\n                          <tr>\n                              <td></td>\n                              <td style=\"border:0px\">\n                                  <table cellpadding='0' cellspacing='0' class='black-0 w-100-p'>\n                                      <tr>\n                                          <td *ngFor=\"let i of scaleData\">\n                                              <!-- <img src='./images/dotclear.gif' height='2' width='59'> -->\n                                              <img src='./assets/images/pixel_black.gif' border='0' height='2' width='1'>\n                                          </td>\n                                      </tr>\n                                      <tr>\n                                          <td *ngFor=\"let index of scaleData\">{{index}}</td>\n                                      </tr>\n                                      <tr>\n                                          <td [attr.colspan]='scaleData.length+1' class=\"text-center\">seconds</td>\n                                      </tr>\n                                  </table>\n                              </td>\n                          </tr>\n                          <tr>\n                              <td></td>\n                              <td>\n                                  <table border='0' cellpadding='0' cellspacing='5' class='black-1'>\n                                      <tr>\n                                          <td>\n                                              <img src='./assets/images/0.gif' border='0' height='10' width='10'>&nbsp;Page Download Time&nbsp;&nbsp;&nbsp;</td>\n                                          <td>\n                                              <img src='./assets/images/6.gif' border='0' height='10' width='10'>&nbsp;DNS Lookup Time&nbsp;&nbsp;&nbsp;</td>\n                                          <td>\n                                              <img src='./assets/images/1.gif' border='0' height='10' width='10'>&nbsp;Connect Time&nbsp;&nbsp;&nbsp;</td>\n                                          <td>\n                                              <img src='./assets/images/2.gif' border='0' height='10' width='10'>&nbsp;SSL Time&nbsp;&nbsp;&nbsp;</td>\n                                          <td>\n                                              <img src='./assets/images/3.gif' border='0' height='10' width='10'>&nbsp;Request Sent Time&nbsp;&nbsp;&nbsp;</td>\n                                          <td>\n                                              <img src='./assets/images/4.gif' border='0' height='10' width='10'>&nbsp;First Byte Time&nbsp;&nbsp;&nbsp;</td>\n                                          <td>\n                                              <img src='./assets/images/5.gif' border='0' height='10' width='10'>&nbsp;Content Download</td>\n                                      </tr>\n                                  </table>\n                              </td>\n                          </tr>\n                      </table>\n                    </div>\n                    <div class=\"no-record\" *ngIf=\"chartData && chartData.length == 0\">\n                      <h4>No page/URL records found for this session.</h4>\n                      This session may be selected for page dump only (not for drill down) as sessions are selected randomly based on percentage settings.<br>\n                      \n                   \n                      <div title=\"{{sessiontimingPct}}\">\n                         {{sessiontimingPct}}\n                      </div>\n                    </div>\n                </p-accordionTab>\n\n            <!-- <p-accordion class=\"ddr-accordion\" [multiple]=\"true\"> -->\n            <p-accordionTab header=\"{{reportType}} Response Time Data(All timings are in seconds)\" [selected]=\"true\">\n                <div style=\"overflow:auto\">\n                  <div class=\"w-100-p p-grid p-align-center p-justify-end\">\n                    <button type=\"button\" pButton class=\"btn-icon\" icon=\"cav graph-tree\"\n                              (click)=\"openTreeView()\" matTooltip=\"Show tree view\" tooltipPosition=\"top\"></button>\n                    <button type=\"button\" pButton class=\"btn-icon\" icon=\"icons8 icons8-search-property\"\n                              (click)=\"filterApply=!filterApply\" matTooltip=\"Search and filter\" tooltipPosition=\"top\"></button>\n                  </div>\n\n                <cav-table #upload [value]=\"tableData\" [headerRelativePath]=\"headerRelativePath\" [scrollable]=\"true\"\n                    scrollHeight=\"calc(100vh - 240px)\" (clickButtonEvent)=\"clickButtonEvent($event)\">\n                </cav-table>\n\n                    <!-- <p-dataTable class=\"scen-table\" [value]=\"tableData\" resizableColumns=\"true\" [rows]=\"10\" [paginator]=\"true\" [pageLinks]=\"3\"\n                        [rowsPerPageOptions]=\"[10,20,30,40,50]\">\n                        <div *ngFor=\"let col of cols1\">\n                            <p-column [field]=\"col.field\" [header]=\"col.header\" [style]=\"{'width': col.width + '%','text-align':col.align}\" [sortable]=\"col.sortable\"\n                                (sortFunction)=\"customsortOnColumns($event,tableData)\">\n                                <ng-template let-col let-node=\"rowData\" pTemplate type=\"body\" *ngIf=\"(col.field != 'action')\"><span [title]=\"node[col.field]\">{{ node[col.field] }} </span> </ng-template>\n                                <ng-template let-col let-node=\"rowData\" pTemplate type=\"body\" *ngIf=\"(col.field == 'action')\">\n                                    <div *ngIf=\"ndKeyValue\">\n                                    <span *ngIf=\"(node.fpSignature == '1' && convertIntoNumber(node.flowpath) > 0)\">\n                                        <img class=\"img-8\" title='View FlowPath: {{node.flowpath}}' src='./images/SequenceIcon.png' (click)=\"openFlowpathReport(node)\">\n                                    </span>\n                                    <span *ngIf=\"(node.fpSignature == '1' && convertIntoNumber(node.flowpath) > 0 && pdKeyValue ) \">\n                                    <img class=\"img-8\" title='Show Page Dump for Session associated with flowpath instance {{node.flowpath}}' src='./images/imgPageDump.png' (click)=\"ViewPageDump(node)\">\n                                    </span>\n                                  </div>\n                                  <div *ngIf=\"( !(ndKeyValue) || !(node.fpSignature == '1' && convertIntoNumber(node.flowpath) > 0))\" >\n                                        <span *ngIf=\"node.instance.startsWith('Conn') &&  pdKeyValue\">\n                                                <img class=\"img-8\" title='Show Page Dump for page {{node.pageName}}' src='./images/imgPageDump.png' (click)=\"ViewPageDump(node)\">\n                                        </span>\n                                  </div>\n                                </ng-template>\n                            </p-column>\n                        </div>\n                    </p-dataTable> -->\n                </div>\n            </p-accordionTab>\n        </p-accordion>\n    </div>\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n      <div class=\"p-col text-center\">\n          <h3>Drill Down Report is not configured</h3>\n          <p>You can configure it from scenario: <br>\n              Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n    </div>\n</div>\n\n<p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n        <p-header>\n            <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n            <span>Query load process</span>\n        </p-header>\n      <p>{{this.commonService.cancelationMessage}} </p>\n      <p-footer class=\"p-grid p-justify-end\">\n          <button type=\"button\" pButton (click)=\"onCancelQuery();\" label=\"Cancel\" class=\"ui-button-rounded ui-toolbar-secondary mx-6\" ></button>\n        <button type=\"button\" pButton (click)=\"waitQuery();\" label=\"Wait\" class=\"ui-button-rounded\" ></button>\n        </p-footer>\n    </p-dialog>\n\n    <p-dialog header=\"Correlation ID\" [(visible)]=\"viewCorrelationId\" modal=\"modal\" [style]=\"{width: '50vw'}\"\n    [draggable]=\"false\" [resizable]=\"false\">\n    <table class=\"border-all border-5 w-100-p\" style=\"border-collapse: collapse;\">\n        <colgroup>\n        <col class=\"w-20-p\">\n        <col class=\"w-80-p\">\n        </colgroup>        \n            <tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>X-Correlation-Id</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                    <div class=\"p-grid p-align-center p-justify-between\">\n                        <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"correlationId\">{{correlationId}}</div>\n                        <div>\n                            <button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyCorrelationId(correlationId)\" matTooltip=\"Copy X-Correlation\"\n                 class=\"btn-icon\"></button>\n                        </div>\n                      </div>\n                 </td>\n                 </tr>\n\n<tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>x-dynaTrace</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                  <div class=\"p-grid p-align-center p-justify-between\">\n                    <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"dynaTraceVal\"> {{dynaTraceVal}}</div>\n                    <div><button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyDynaTrace(dynaTraceVal)\" matTooltip=\"Copy X-Dynatrace\"\n                        class=\"btn-icon\"></button></div>\n                  </div> \n            \n                </td>\n                </tr>\n                <tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>Script Name</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                    <div class=\"p-grid p-align-center p-justify-between\">\n                        <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"scriptname\"> {{scriptname}}</div>\n                        <div><button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyScriptName(scriptname)\" matTooltip=\"Copy Script Name\"\n                            class=\"btn-icon\"></button></div>\n                      </div>\n                   </td>\n                </tr>\n\n                <tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>Page Name</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                    <div class=\"p-grid p-align-center p-justify-between\">\n                        <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"pagename\">{{pagename}}</div>\n                        <div><button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyPageName(pagename)\" matTooltip=\"Copy Page Name\"\n                            class=\"btn-icon\"></button></div>\n                      </div>\n                    </td>\n                </tr>\n\n                <tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>URL Name</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                    <div class=\"p-grid p-align-center p-justify-between\">\n                        <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"urlName\"> {{urlName}}</div>\n                        <div><button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyURLName(urlName)\" matTooltip=\"Copy URL Name\"\n                            class=\"btn-icon\"></button></div>\n                      </div>\n                   </td>\n            </tr>\n        \n    </table>\n    \n    <p-footer>\n        <div class=\"p-grid w-100-p p-align-center p-nogutter\">\n            <div class=\"p-col text-left\">\n                <p class=\"my-8\"><strong>Note:</strong> Correlation and Dynatrace header will be sent in HTTP request if enabled from scenario <u><em>(Group Settings -> Protocol Settings -> HTTP Header -> ADD PERFORMANCE MEASUREMENT HEADER)</em></u> </p>\n    \n            </div>\n            <div class=\"p-col-fixed\">\n            <button type=\"button\" class=\"ui-button-rounded mr-5 ui-button-secondary\" pButton\n                (click)=\"viewCorrelationId=false;\" label=\"Close\"></button>\n                </div>\n        </div>\n    </p-footer>\n</p-dialog>\n    <session-timing-detail-panel [showTansactionTimeSidebar]=\"showTansactionTimeSidebar\"\n    [treeTableData]=\"treeTableData\" (sessTimingPanelEvent)=\"onSessTimingPanelEvent($event)\" [dataObj]=\"dataObj\"></session-timing-detail-panel>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.html":
/*!**************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.html ***!
  \**************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--component html goes here -->\n<transaction-summary-report *ngIf=\"summaryReport\" [summarybystatusReport]=\"summarybystatusReport\"></transaction-summary-report>\n<transaction-summary-report *ngIf=\"summarybystatusReport\" [summarybystatusReport]=\"summarybystatusReport\"></transaction-summary-report>\n<transaction-instance-report *ngIf=\"instanceReport\"></transaction-instance-report>\n<transaction-details-report *ngIf=\"transactionDetail\"></transaction-details-report>\n<transaction-session-summary-report *ngIf=\"transactionSessionSummary\"></transaction-session-summary-report>\n<transaction-failure-report *ngIf=\"transactionFailure\"></transaction-failure-report>\n\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.html":
/*!*********************************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.html ***!
  \*********************************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n  </div>\n<div>\n\t<div class= \"ddr-box\" style=\"overflow: auto; height: calc(100vh - 150px);\">\n<!-- COMMON TOOLBAR -->\n<div class=\"ddr-toolbar\">\n  <p-toolbar class=\"ui-toolbar-secondary\">\n    <div class=\"p-grid p-justify-between p-align-center px-6 py-3\">\n    <div class=\"ui-toolbar-group-left textElipse height-14\" style=\"max-width: 1040px;white-space: nowrap;\">\n          <span class=\"headerInfo\" title=\"{{filterCriteria}}\">{{filterCriteria}}</span>\n    </div>\n    <div class=\"ui-toolbar-group-right\">\n      <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n      <span class=\"pl-5\" style=\"opacity: .5;\">|</span>\n      <button type=\"button\" [disabled]=\"!isDdrEnabled || errorData\" pButton class=\"btn-icon btn-white\" icon=\"icons8 icons8-download\" title=\"Download\"\n        [matMenuTriggerFor]=\"menu\"></button>\n      <mat-menu #menu=\"matMenu\">\n        <button mat-menu-item [disabled]=\"thinkData.length == 0\" (click)='downloadReports(\"pdf\")'>\n          <i class=\"icons8 icons8-pdf-2\"></i>\n          <span>PDF</span>\n        </button>\n        <button mat-menu-item [disabled]=\"thinkData.length == 0\" (click)='downloadReports(\"excel\")'>\n          <i class=\"icons8 icons8-spreadsheet-file\"></i>\n          <span>Excel</span>\n        </button>\n        <button mat-menu-item [disabled]=\"thinkData.length == 0\" (click)='downloadReports(\"worddoc\")'>\n          <i class=\"icons8 icons8-word\"></i>\n          <span>Word</span>\n        </button>\n      </mat-menu>\n    </div>\n    </div>\n  </p-toolbar>\n</div>\n<!-- COMMON BOX SCROLLLBAR -->\n<div *ngIf=\"isDdrEnabled && !errorData\" class=\"ddruiscroll\">\n\n<p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\" [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n    <div *ngIf=\"loader\">\n        <p-progressBar [value]=\"value\"></p-progressBar>\n    </div>\n    </p-dialog>\n    <p-accordion class=\"ddr-accordion transaction-accordion\">\n      <p-accordionTab styleClass=\"elipseText\"  [selected]=\"true\">\n        <p-header title=\"Transaction Details Report {{sessionPct}}\">\n          Transaction Details Report {{sessionPct}}\n        </p-header>\n    <div style=\"overflow:auto\">\n        <cav-table [value]=\"thinkData\" [headerRelativePath]=\"headerRelativePath\" [scrollable]=\"true\"\n               scrollHeight=\"calc(100vh - 240px)\" (clickButtonEvent)=\"clickButtonEvent($event)\">\n        </cav-table>\n      </div>\n\n<!-- Charts for Transaction Details Report -->\n\n<p-accordion class=\"ddr-accordion\">\n    <div class=\"ui-g-12\">\n      <div class=\"ui-g-6\">\n        <div class=\"ddr-graphpanel\" *ngIf=\"showChart; else pieChart\">\n          <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\"></highcharts-chart>\n        </div>\n        <ng-template #pieChart>No PieChart found based on current Filter Settings.</ng-template>\n      </div>\n\n      <div class=\"ui-g-6\">\n        <div class=\"ddr-graphpanel\" *ngIf=\"showChart; else StackChart\">\n          <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"StackBarChartOptions\"></highcharts-chart>\n        </div>\n        <ng-template #StackChart>No split time chart found based on current Filter Settings.</ng-template>\n      </div>\n\n    </div>\n</p-accordion>\n<p-accordion class=\"ddr-accordion\">\n\n  <div class=\"p-grid p-justify-end p-align-center px-6 py-3\">\n \n\n  </div>\n\n  <div style=\"overflow:auto\">\n    <cav-table [value]=\"TransactionDetailsData\" [responsive]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\"\n      [headerRelativePath]=\"relativePath\"></cav-table>\n  </div>\n\n</p-accordion>\n</p-accordionTab>\n</p-accordion>\n</div>\n\n<div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n  <div class=\"p-col text-center\">\n      <h3>Drill Down Report is not configured</h3>\n      <p>You can configure it from scenario: <br>\n          Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n  </div>\n  <div class=\"p-col-fixed text-center\">\n      <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n  </div>\n</div>\n\n<div class=\"no-transactions\" *ngIf=\"errorData\">\n  <div class=\"p-col text-center\">\n     {{errorData}}\n  </div>\n  <div class=\"p-col-fixed text-center\">\n      <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n  </div>\n</div>\n\n\n</div>\n</div>\n\n<p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n      <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer class=\"p-grid p-justify-end\">\n      <button type=\"button\" pButton class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n      <button type=\"button\" pButton class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\" style=\"height: 25px;\"></button>\n    </p-footer>\n  </p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.html":
/*!**********************************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.html ***!
  \**********************************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n<div>\n\t<div class= \"ddr-box\">\n<!-- COMMON TOOLBAR -->\n<div class=\"ddr-toolbar\">\n  <p-toolbar class=\"ui-toolbar-secondary\">\n    <div class=\"p-grid p-justify-between p-align-center px-6 py-3\">\n    <div class=\"ui-toolbar-group-left textElipse height-14\" style=\"max-width: 1040px;white-space: nowrap;\">\n          <label class=\"headerInfo\" title=\"{{filterCriteria}}\">{{filterCriteria}}</label>\n    </div>\n    <div class=\"ui-toolbar-group-right\">\n      <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n    </div>\n    </div>\n  </p-toolbar>\n\n</div>\n<!-- COMMON BOX SCROLLLBAR -->\n<div class=\"ddruiscroll\">\n\n<p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\" [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n  <div *ngIf=\"loader\">\n    <p-progressBar [value]=\"value\"></p-progressBar>\n  </div>\n</p-dialog>\n\n<!-- Chart for Failure Report -->\n<div *ngIf=\"isDdrEnabled && !errorData\">\n  <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n       <div class=\"ui-g\">\n      <div class=\"ui-g-6\" >\n          <p-accordionTab header=\"Failure Stats\" [selected]=\"true\">\n  <div class=\"ddr-graphpanel\" *ngIf=\"showChart; else BarChart\">\n    <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\" ></highcharts-chart>\n  </div>\n  <span><ng-template #BarChart>No  Chart found based on current Filter Settings.</ng-template></span>\n          </p-accordionTab>\n  </div>\n  \n  <div class=\"ui-g-6\" >\n          <p-accordionTab header=\"Transaction Failure\" [selected]=\"true\">\n            <cav-table [value]=\"TransactionFailureData\"  [responsive]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\" [headerRelativePath]=\"relativePath\"\n            ></cav-table> \n      \n  </p-accordionTab>\n  </div>\n  </div>\n  </p-accordion>\n</div>\n\n        \n<div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n  <div class=\"p-col text-center\">\n      <h3>Drill Down Report is not configured</h3>\n      <p>You can configure it from scenario: <br>\n          Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n  </div>\n  <div class=\"p-col-fixed text-center\">\n      <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n  </div>\n</div>\n\n\n<div class=\"no-transactions\" *ngIf=\"errorData\">\n  <div class=\"p-col text-center\">\n     {{errorData}}\n  </div>\n  <div class=\"p-col-fixed text-center\">\n      <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n  </div>\n</div>\n\n</div>\n</div>\n</div>\n  <p-dialog appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false' [responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n  <p-header>\n    <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n      <span>Query load process</span>\n  </p-header>\n  <p>{{this.commonService.cancelationMessage}} </p>\n  <p-footer class=\"p-grid p-justify-end\">\n    <button type=\"button\" pButton class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\" ></button>\n  <button type=\"button\" pButton class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\"></button>\n  </p-footer>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.html":
/*!************************************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.html ***!
  \************************************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n<div>\n    <div class=\"ddr-box\">\n        <!-- COMMON TOOLBAR -->\n        <div class=\"ddr-toolbar\">\n            <p-toolbar class=\"ui-toolbar-secondary\">\n                <div class=\"p-grid p-justify-between p-align-center px-6 py-3\">\n                <div class=\"ui-toolbar-group-left textElipse height-14\">\n                    <label class=\"headerInfo\" title=\"{{filterCriteria}}\">{{filterCriteria}}</label>\n                    <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{filterStatus}}</label>\n                </div>\n                <div class=\"ui-toolbar-group-right\">\n                    <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n                </div>\n                </div>\n            </p-toolbar>\n\n        </div>\n        <!-- COMMON BOX SCROLLLBAR -->\n        <div class=\"ddruiscroll\" *ngIf=\"isDdrEnabled && !errorData\">\n\n            <p-dialog [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\"\n                [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n                <div *ngIf=\"loader\">\n                    <p-progressBar [value]=\"value\"></p-progressBar>\n                </div>\n            </p-dialog>\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab styleClass=\"elipseText\" [selected]=\"true\">\n                    <p-header title=\"Transaction Instance {{sessionPct}}\">\n                        Transaction Instance {{sessionPct}}\n                    </p-header>\n                    <div class=\"p-grid p-justify-end p-align-center px-6 py-3\">\n                        <cav-table [value]=\"TransactionInstanceData\" [headerRelativePath]=\"relativePath\" \n                            scrollHeight=\"calc(100vh - 290px)\"  [paginator]=\"true\" (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"txTotalCount\" [first]=\"first\" [rows]=\"rows\"\n                            (clickButtonEvent)=\"clickButtonEvent($event)\" [lazyLoadingProcessBar]=\"loading\"></cav-table>\n                    </div>\n            \n                </p-accordionTab>\n            </p-accordion>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n        <div class=\"p-col text-center\">\n            <h3>Drill Down Report is not configured</h3>\n            <p>You can configure it from scenario: <br>\n                Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"errorData\">\n        <div class=\"p-col text-center\">\n           {{errorData}}\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n    </div>\n</div>\n</div>\n<p-dialog class=\"ddr-dialog\" appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'\n    [responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n        <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer class=\"p-grid p-justify-end\">\n        <button type=\"button\" pButton  class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\"></button>\n        <button type=\"button\" pButton class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\"></button>\n    </p-footer>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.html":
/*!**************************************************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.html ***!
  \**************************************************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n  </div>\n<div>\n\t<div class= \"ddr-box\">\n    <!-- <transaction-instance-report *ngIf=\"failureReport\"></transaction-instance-report>    </transaction-instance-report> -->\n<!-- COMMON TOOLBAR -->\n<div class=\"ddr-toolbar\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n        <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n            <div class=\"ui-toolbar-group-left\">\n                <label class=\"headerInfo\">{{filterCriteria}}</label>\n            </div>\n            <div class=\"ui-toolbar-group-right\">\n            </div>\n        </div>\n    </p-toolbar>\n\n</div>\n<!-- COMMON BOX SCROLLLBAR -->\n<div class=\"ddruiscroll\">\n\n<p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\"\n [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n  <div *ngIf=\"loader\">\n    <p-progressBar [value]=\"value\"></p-progressBar>\n  </div>\n</p-dialog>\n<div *ngIf=\"isDdrEnabled && !errorData\">\n    <p-accordion class=\"ddr-accordion\" >\n    <p-accordionTab header=\"Transaction Session Summary\" [selected]=\"true\">\n    \n            <div style=\"overflow:auto\">\n                <cav-table [value]=\"TransactionSessionSummaryData\"  [responsive]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\" \n\t\t\t\t[paginator]=\"true\" (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"txTotalCount\" [first]=\"first\" [rows]=\"rows\"\n                [headerRelativePath]=\"relativePath\" [lazyLoadingProcessBar]=\"loading\"></cav-table> \n            </div>\n    </p-accordionTab>\n    </p-accordion>\n</div>\n\n        \n<div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n    <div class=\"p-col text-center\">\n        <h3>Drill Down Report is not configured</h3>\n        <p>You can configure it from scenario: <br>\n            Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n</div>\n\n<div class=\"no-transactions\" *ngIf=\"errorData\">\n    <div class=\"p-col text-center\">\n       {{errorData}}\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n  </div>\n\n</div>\n</div>\n</div>\n  <p-dialog class=\"ddr-dialog\"   appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n  <p-header>\n    <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n      <span>Query load process</span>\n  </p-header>\n  <p>{{this.commonService.cancelationMessage}} </p>\n  <p-footer class=\"p-grid p-justify-end\">\n      <button type=\"button\" pButton (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\" label=\"Cancel\" class=\"ui-button-rounded ui-button-secondary mx-6\"></button>\n  <button type=\"button\" pButton (click)=\"waitQuery();\" label=\"Wait\" class=\"ui-button-rounded\"></button>\n  </p-footer>\n\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.html":
/*!**********************************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.html ***!
  \**********************************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n  </div>\n<div>\n    <div class=\"ddr-box\">\n        <!-- COMMON TOOLBAR -->\n        <div class=\"ddr-toolbar\">\n            <p-toolbar class=\"ui-toolbar-secondary\">\n                <div class=\"p-grid p-justify-between p-align-center px-6 py-3\">\n                <div class=\"ui-toolbar-group-left textElipse height-14\" style=\"max-width: 1040px;white-space: nowrap;\">\n                    <ng-container *ngIf=\"filterCriteria || filterStatus\">\n                        <label class='headerInfo'>\n                            <b>Filter Criteria : </b>\n                        </label>\n                    <label class=\"headerInfo\" title=\"{{filterCriteria}}\">{{filterCriteria}}</label>\n                    <label class=\"headerInfo\" title=\"{{statusHint}}\">{{filterStatus}}</label>\n                    </ng-container>\n                </div>\n                <div class=\"ui-toolbar-group-right\">\n                    <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n                </div>\n                </div>\n            </p-toolbar>\n\n        </div>\n        <!-- COMMON BOX SCROLLLBAR -->\n        <div *ngIf=\"isDdrEnabled && !errorData\" class=\"ddruiscroll\">\n\n            <p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\"\n                [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n                <div *ngIf=\"loader\">\n                    <p-progressBar [value]=\"value\"></p-progressBar>\n                </div>\n            </p-dialog>\n            <p-accordion class=\"ddr-accordion transaction-accordion\">\n                <p-accordionTab class=\"elipseText\"  [selected]=\"true\">\n                    <p-header title=\"{{tabName}} {{sessionPct}}\">\n                        {{tabName}} {{sessionPct}}\n                    </p-header>\n                    \n                    <cav-table [value]=\"TransactionSummaryData\" [tableConfig]=\"tableConfig\" [headers]=\"colsForTable\" [scrollable]=\"true\"\n                        (clickButtonEvent)=\"clickButtonEvent($event)\" scrollHeight=\"calc(100vh - 290px)\" [paginator]=\"true\" [lazy]=\"true\"\n                        (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"txTotalCount\" [first]=\"first\" [rows]=\"rows\"\n                        [rowsPerPageOptions]=\"[50,100,200,400,700,1000]\" [lazyLoadingProcessBar]=\"loading\" [showCurrentPageReport]=\"true\">\n                    </cav-table>\n\n                </p-accordionTab>\n            </p-accordion>\n        </div>\n\n        <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n            <div class=\"p-col text-center\">\n                <h3>Drill Down Report is not configured</h3>\n                <p>You can configure it from scenario: <br>\n                    Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n            </div>\n            <div class=\"p-col-fixed text-center\">\n                <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n            </div>\n        </div>\n\n        <div class=\"no-transactions\" *ngIf=\"errorData\">\n            <div class=\"p-col text-center\">\n               {{errorData}}\n            </div>\n            <div class=\"p-col-fixed text-center\">\n                <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n            </div>\n        </div>\n        \n    </div>\n</div>\n<p-dialog class=\"ddr-dialog\" appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'\n    [responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n        <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer class=\"p-grid p-justify-end\">\n        <button type=\"button\" pButton class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n            label=\"Cancel\"></button>\n        <button type=\"button\" pButton class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\" ></button>\n    </p-footer>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.html":
/*!**********************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.html ***!
  \**********************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!--component html goes here -->\n<app-url-instance-report *ngIf=\"urlInstanceReport\"></app-url-instance-report>\n<app-url-summary-report *ngIf=\"urlSummaryReport\" [urlSummaryStatus]=\"urlSummaryStatus\"></app-url-summary-report>\n<app-url-component-details *ngIf=\"urlDetail\"></app-url-component-details>\n<app-url-failure-report *ngIf=\"urlFailure\"></app-url-failure-report>\n<app-url-session-summary *ngIf=\"urlSessionsummary\"></app-url-session-summary>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.html":
/*!****************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.html ***!
  \****************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n<div class=\"ddr-box\" style=\"height: calc(100vh - 105px);overflow: auto;\">\n  <div class=\"ddr-toolbar\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n      <div class=\"p-grid p-justify-between p-align-center px-6 py-3\" style=\"height: 30px;\">\n        <div class=\"ui-toolbar-group-left textElipse height-14\" style=\"max-width: 1040px;white-space: nowrap;\">\n          <span title=\"{{filter}}\">{{filter}}</span>\n        </div>\n        <div class=\"p-grid p-align-center\" *ngIf=\"showDownloadOption\">\n          <span style=\"padding: 0px 4px;\">TR: {{sessionService.session.testRun.id}}</span>\n        </div>\n      </div>\n    </p-toolbar>\n  </div>\n\n  <div class=\"ddruiscroll\" *ngIf=\"isDdrEnabled && !errorData\">\n\n      <p-accordion class=\"ddr-accordion\">\n        <p-accordionTab styleClass=\"elipseText\"  [selected]=\"true\">\n          <p-header title=\"URL Component Stats {{sessionPct}}\">\n            URL Component Stats {{sessionPct}}\n          </p-header>\n          <div class=\"ui-g\">\n            <div class=\"ui-g-6\">\n              <div class=\"ddr-graphpanel\" *ngIf=\"showChart == true\">\n                <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\"></highcharts-chart>\n              </div>\n              <div *ngIf=\"showChart == false\" style=\"text-align:center;\">No Pie Chart found based on current Filter\n                Settings.</div>\n            </div>\n            <div class=\"ui-g-6\">\n              <div class=\"ddr-graphpanel\" *ngIf=\"showChartForRespTime == true\">\n                <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options1\"></highcharts-chart>\n              </div>\n              <div *ngIf=\"showChartForRespTime == false\" style=\"text-align:center;\">No Response Time Pie Chart found\n                based\n                on current Filter Settings.</div>\n            </div>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n\n    <div class=\"ui-g-12\">\n      <p-accordion class=\"ddr-accordion dynamic-column-width-acc\">\n        <p-accordionTab header=\"URL Component Details\" [selected]=\"true\">\n          <div style=\"overflow:auto\">\n            <cav-table [value]=\"columnData\" [responsive]=\"true\" [headerRelativePath]=\"relativePath\"\n            ></cav-table>\n          </div>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n  </div>\n\n  \n  <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n    <div class=\"p-col text-center\">\n        <h3>Drill Down Report is not configured</h3>\n        <p>You can configure it from scenario: <br>\n            Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n</div>\n\n<div class=\"no-transactions\" *ngIf=\"errorData\">\n  <div class=\"p-col text-center\">\n     {{errorData}}\n  </div>\n  <div class=\"p-col-fixed text-center\">\n      <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n  </div>\n</div>\n\n  <p-dialog class=\"ddr-dialog\" appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'\n    [responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n      <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n      <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer>\n      <div class=\"p-grid p-justify-end sevbtn py-12\">\n        <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n          class=\"ui-button-rounded ui-toolbar-secondary mx-6\"></button>\n        <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n      </div>\n    </p-footer>\n  </p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.html":
/*!**********************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.html ***!
  \**********************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"ddr-box\">\n  <div class=\"ddr-toolbar\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n      <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n      <div class=\"group-left textElipse\" style=\"max-width: 1040px;white-space: nowrap;\">\n        <span title=\"{{filter}}\">{{filter}}</span>\n        <!-- <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{filterStatus}}</label> -->\n      </div>\n      </div>\n    </p-toolbar>\n  </div>\n  <div *ngIf=\"isDdrEnabled && !errorData\">\n    <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\n      <div class=\"ui-g\">\n        <div class=\"ui-g-6\">\n          <p-accordionTab header=\"Page Failure Stats\" [selected]=\"true\">\n            <div class=\"ddr-graphpanel\">\n              <highcharts-chart [Highcharts]=\"highcharts\" [options]=\"options\"></highcharts-chart>\n            </div>\n          </p-accordionTab>\n        </div>\n        <div class=\"ui-g-6\">\n          <p-accordionTab header=\"URL Failure\" [selected]=\"true\">\n            <div style=\"overflow:auto\">\n              <cav-table [value]=\"urlFailureData\" [headerRelativePath]=\"headerRelativePath\" [scrollable]=\"true\"\n               scrollHeight=\"calc(100vh - 240px)\" (clickButtonEvent)=\"clickButtonEvent($event)\">\n              </cav-table>\n            </div>\n          </p-accordionTab>\n        </div>\n      </div>\n    </p-accordion>\n  </div>\n      \n\n      <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n        <div class=\"p-col text-center\">\n            <h3>Drill Down Report is not configured</h3>\n            <p>You can configure it from scenario: <br>\n                Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"errorData\">\n      <div class=\"p-col text-center\">\n         {{errorData}}\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n  </div>\n\n</div>\n\n<p-dialog class=\"secondary-dialog\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false' [responsive]=\"true\"\n  [style]=\"{'height':'120px', 'width':'600px'}\">\n  <p-header>\n    <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n    <span>Query load process</span>\n  </p-header>\n  <p>{{this.commonService.cancelationMessage}} </p>\n  <p-footer>\n    <div class=\"p-grid p-justify-end sevbtn py-12\">\n      <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n        class=\"ui-button-rounded ui-button-secondary mx-6\"></button>\n      <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n    </div>\n  </p-footer>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.html":
/*!************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.html ***!
  \************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n\n<div class=\"blockedUI\" *ngIf=\"isLoading\">\n    <i class=\"icons8 icons8-spinner spin\"></i>\n</div>\n\n<div class=\"ddr-box\">\n    <!-- COMMON TOOLBAR -->\n    <div class=\"ddr-toolbar\">\n        <p-toolbar class=\"ui-toolbar-secondary\">\n            <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n            <div class=\"group-left textElipse\" style=\"max-width: 1040px;white-space: nowrap;\">\n                <label class=\"headerInfo\" title=\"{{filter}}\">{{filter}}</label>\n                <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{filterStatus}}</label>\n                <label class=\"headerInfo\" title=\"{{toolTipUrl}}\">{{filterUrl}}</label>\n            </div>\n            <div class=\"ui-toolbar-group-right\">\n                <span style=\"padding: 0px 4px;\">TR: {{sessionService.session.testRun.id}}</span>\n            </div>\n            </div>\n            </p-toolbar>\n            \n            </div>\n    <!-- COMMON BOX SCROLLLBAR -->\n\n    <div class=\"ddruiscroll\" *ngIf=\"isDdrEnabled && !errorData\" [ngStyle]=\"{'height': screenHeight+'px'}\" style=\"overflow:auto;\">\n        <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n            <p-accordionTab [selected]=\"true\" styleClass=\"elipseText\">\n                <p-header title=\"URL Instance {{sessionPct}}\">\n                    URL Instance {{sessionPct}}\n                </p-header>\n                <div class=\"p-grid p-align-center p-justify-end mtn-4 mb-5\">\n                </div>\n\n                <cav-table [value]=\"urlInstanceData\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" \n                    scrollHeight=\"calc(100vh - 290px)\" [paginator]=\"true\" (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"count\" [first]=\"first\" [rows]=\"rows\"\n                    (clickButtonEvent)=\"clickButtonEvent($event)\" [lazyLoadingProcessBar]=\"loading\"></cav-table>\n            \n            </p-accordionTab>\n        </p-accordion>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n        <div class=\"p-col text-center\">\n            <h3>Drill Down Report is not configured</h3>\n            <p>You can configure it from scenario: <br>\n                Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"errorData\">\n        <div class=\"p-col text-center\">\n           {{errorData}}\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n    </div>\n\n</div>\n<p-dialog class=\"ddr-dialog\" appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'\n    [responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n        <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer>\n        <div class=\"p-grid p-justify-end sevbtn py-12\">\n            <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n                class=\"ui-button-rounded ui-toolbar-secondary mx-6\"></button>\n            <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n        </div>\n    </p-footer>\n</p-dialog>\n<p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\"\n    [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n    <div *ngIf=\"loader\">\n        <p-progressBar [value]=\"value\"></p-progressBar>\n    </div>\n</p-dialog>\n\n\n<p-dialog header=\"Correlation ID\" [(visible)]=\"viewCorrelationId\" modal=\"modal\" [style]=\"{width: '50vw'}\"\n    [draggable]=\"false\" [resizable]=\"false\">\n    <table class=\"border-all border-5 w-100-p\" style=\"border-collapse: collapse;\">\n        <colgroup>\n        <col class=\"w-20-p\">\n        <col class=\"w-80-p\">\n        </colgroup>        \n            <tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>X-Correlation-Id</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                    <div class=\"p-grid p-align-center p-justify-between\">\n                        <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"correlationId\">{{correlationId}}</div>\n                        <div>\n                            <button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyCorrelationId(correlationId)\" matTooltip=\"Copy X-Correlation\"\n                 class=\"btn-icon\"></button>\n                        </div>\n                      </div>\n                 </td>\n                 </tr>\n\n<tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>x-dynaTrace</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                  <div class=\"p-grid p-align-center p-justify-between\">\n                    <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"dynaTraceVal\"> {{dynaTraceVal}}</div>\n                    <div><button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyDynaTrace(dynaTraceVal)\" matTooltip=\"Copy X-Dynatrace\"\n                        class=\"btn-icon\"></button></div>\n                  </div> \n            \n                </td>\n                </tr>\n                <tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>Script Name</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                    <div class=\"p-grid p-align-center p-justify-between\">\n                        <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"scriptName\"> {{scriptName}}</div>\n                        <div><button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyScriptName(scriptName)\" matTooltip=\"Copy Script Name\"\n                            class=\"btn-icon\"></button></div>\n                      </div>\n                   </td>\n                </tr>\n\n                <tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>Page Name</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                    <div class=\"p-grid p-align-center p-justify-between\">\n                        <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"pageName\">{{pageName}}</div>\n                        <div><button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyPageName(pageName)\" matTooltip=\"Copy Page Name\"\n                            class=\"btn-icon\"></button></div>\n                      </div>\n                    </td>\n                </tr>\n\n                <tr>\n                <td class=\"border-all border-5 p-6 height-36\"><strong>URL Name</strong></td>\n                <td class=\"border-all border-5 p-6 height-36\">\n                    <div class=\"p-grid p-align-center p-justify-between\">\n                        <div class=\"elipseText\" style=\"max-width: 600px;\" [title]=\"urlName\"> {{urlName}}</div>\n                        <div><button type=\"button\" pButton icon=\"icons8 icons8-copy\" (click)=\"copyURLName(urlName)\" matTooltip=\"Copy URL Name\"\n                            class=\"btn-icon\"></button></div>\n                      </div>\n                   </td>\n            </tr>\n        \n    </table>\n    \n    <p-footer>\n        <div class=\"p-grid w-100-p p-align-center p-nogutter\">\n            <div class=\"p-col text-left\">\n                <p class=\"my-8\"><strong>Note:</strong> Correlation and Dynatrace header will be sent in HTTP request if enabled from scenario <u><em>(Group Settings -> Protocol Settings -> HTTP Header -> ADD PERFORMANCE MEASUREMENT HEADER)</em></u> </p>\n    \n            </div>\n            <div class=\"p-col-fixed\">\n            <button type=\"button\" class=\"ui-button-rounded mr-5 ui-button-secondary\" pButton\n                (click)=\"viewCorrelationId=false;\" label=\"Close\"></button>\n                </div>\n        </div>\n    </p-footer>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.html":
/*!************************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.html ***!
  \************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!-- <p-blockUI [blocked]=\"loading\"></p-blockUI>\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" /> -->\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n<div class=\"ddr-box\">\n    <!-- COMMON TOOLBAR -->\n    <div class=\"ddr-toolbar\">\n        <p-toolbar class=\"ui-toolbar-secondary\">\n            <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n            <div class=\"group-left textElipse\" style=\"max-width: 1040px;white-space: nowrap;\">\n                <span title=\"{{filter}}\">{{filter}}</span>\n            </div>\n            <div class=\"group-right\">\n               \n              </div>\n              <div class=\"ui-toolbar-group-right\">\n                <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>   \n            </div>\n              </div>\n        </p-toolbar>\n    </div>\n    <!-- <div class=\"ddruiscroll\" [ngStyle]=\"{'height': screenHeight+'px'}\" style=\"overflow:auto;\"> -->\n    <div style=\"overflow:auto;min-height: 330px;\" *ngIf=\"isDdrEnabled && !errorData\">\n\n        <div class=\"ui-g-12\">\n            <p-accordion class=\"ddr-accordion\">\n                <p-accordionTab styleClass=\"elipseText\"  [selected]=\"true\">\n                    <p-header title=\"URL Session Summary {{sessionPct}}\">\n                        URL Session Summary {{sessionPct}}\n                    </p-header>\n                  \n                        <cav-table [value]=\"urlSessionSummaryData\" [scrollable]=\"true\" (clickButtonEvent)=\"clickButtonEvent($event)\"\n                        [paginator]=\"true\" (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"count\" [first]=\"first\" [rows]=\"rows\"\n                        [headerRelativePath]=\"relativePath\" [lazyLoadingProcessBar]=\"loading\"></cav-table>\n                </p-accordionTab>\n            </p-accordion>\n        </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n        <div class=\"p-col text-center\">\n            <h3>Drill Down Report is not configured</h3>\n            <p>You can configure it from scenario: <br>\n                Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"errorData\">\n        <div class=\"p-col text-center\">\n           {{errorData}}\n        </div>\n        <div class=\"p-col-fixed text-center\">\n            <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n        </div>\n    </div>\n\n</div>\n<p-dialog class=\"ddr-dialog\" appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'\n    [responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n    <p-header>\n        <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n        <span>Query load process</span>\n    </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer class=\"p-grid p-justify-end\">\n        <div class=\"p-grid p-justify-end sevbtn py-12\">\n            <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n                class=\"ui-button-rounded ui-button-secondary mx-6\"></button>\n            <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n        </div>\n    </p-footer>\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.html":
/*!**********************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.html ***!
  \**********************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n    <div class=\"p-col p-col-align-center text-center\">\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n    </div>\n</div>\n<div class=\"ddr-box\">\n    <!-- COMMON TOOLBAR -->\n\n    <p-toolbar class=\"ui-toolbar-secondary\">\n        <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n            <div class=\"ui-toolbar-group-left textElipse height-14\" style=\"max-width: 1040px;white-space: nowrap;\" >\n                <ng-container *ngIf=\"(filter != '' && filter != undefined && filter != null)\">\n                <label class='headerInfo'>\n                    <b>Filter Criteria : </b>\n                </label>\n                <label class='headerInfo' title=\"{{filter}}\">{{filter}}</label>\n                <label class=\"headerInfo\" title=\"{{toolTipStatus}}\">{{filterStatus}}</label>\n                <label class=\"headerInfo\" title=\"{{toolTipUrl}}\">{{filterUrl}}</label>\n                </ng-container>\n            </div>\n            <div class=\"ui-toolbar-group-right\">\n                <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>   \n            </div>\n        </div>\n    </p-toolbar>\n\n    <!-- COMMON BOX SCROLLLBAR -->\n    <div class=\"ddruiscroll\" *ngIf=\"isDdrEnabled && !errorData\">\n        <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n            <p-accordionTab styleClass=\"elipseText\"  [selected]=\"true\">\n                <p-header title=\"URL Summary {{sessionPct}}\">\n                    URL Summary {{sessionPct}}\n                </p-header>\n\n                <cav-table [value]=\"urlSummaryData\" [tableConfig]=\"tableConfig\" [headers]=\"colsForTable\" [scrollable]=\"true\"\n                    (clickButtonEvent)=\"clickButtonEvent($event)\" scrollHeight=\"calc(100vh - 290px)\" [paginator]=\"true\" [lazy]=\"true\"\n                    (onLazyLoad)=\"paginate($event)\" [totalRecords]=\"count\" [first]=\"first\" [rows]=\"rows\" [rowsPerPageOptions]=\"[50,100,200,400,700,1000]\"\n                    [lazyLoadingProcessBar]=\"loading\" [showCurrentPageReport]=\"true\">\n                </cav-table>\n            </p-accordionTab>\n        </p-accordion>\n    </div>\n\n        <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n            <div class=\"p-col text-center\">\n                <h3>Drill Down Report is not configured</h3>\n                <p>You can configure it from scenario: <br>\n                    Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n            </div>\n            <div class=\"p-col-fixed text-center\">\n                <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n            </div>\n        </div>\n\n        <div class=\"no-transactions\" *ngIf=\"errorData\">\n            <div class=\"p-col text-center\">\n               {{errorData}}\n            </div>\n            <div class=\"p-col-fixed text-center\">\n                <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n            </div>\n        </div>\n\n    <p-dialog class=\"ddr-dialog\" appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'\n        [responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n        <p-header>\n            <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n            <span>Query load process</span>\n        </p-header>\n        <p>{{this.commonService.cancelationMessage}} </p>\n        <p-footer class=\"p-grid p-justify-end\">\n            <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n                class=\"ui-button-rounded ui-button-secondary mx-6\"></button>\n            <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n\n        </p-footer>\n    </p-dialog>\n\n    <p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\"\n        [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n        <div *ngIf=\"loader\">\n            <p-progressBar [value]=\"value\"></p-progressBar>\n        </div>\n    </p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.html":
/*!****************************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.html ***!
  \****************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("\n<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n      <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n<div>\n  <div class=\"ddr-box\">\n    <p-toolbar class=\"ui-toolbar-secondary\">\n      <div class=\"p-grid p-align-center p-justify-between px-6 py-3\">\n        <div class='ui-toolbar-group-left textElipse height-14' style=\"max-width: 1040px;white-space: nowrap;\">\n          <label class='headerInfo'>\n            <b>Filter Criteria : </b>\n          </label>\n          <label class='headerInfo' title=\"{{filterCriteria}}\">{{filterCriteria}}</label>\n        </div>\n        <div class=\"ui-toolbar-group-right\">\n          <span class=\"px-4\">TR: {{sessionService.session.testRun.id}}</span>\n        </div>\n      </div>\n    </p-toolbar>\n\n    <div *ngIf=\"isDdrEnabled && !errorData\">\n      <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n        <p-accordionTab [selected]=\"true\" styleClass=\"elipseText\">\n          <p-header title=\"User Sessions {{sessionPct}}\">\n            User Sessions {{sessionPct}}\n          </p-header>\n    \n          <div class=\"p-grid p-align-center p-justify-end p-3\">\n    \n          </div>\n    \n          <cav-table [value]=\"UserSessionsData\" [responsive]=\"true\" [headerRelativePath]=\"relativePath\"\n            (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>\n    \n        </p-accordionTab>\n      </p-accordion>\n    </div>\n\n    <div class=\"no-transactions\" *ngIf=\"!isDdrEnabled\">\n      <div class=\"p-col text-center\">\n          <h3>Drill Down Report is not configured</h3>\n          <p>You can configure it from scenario: <br>\n              Group settings > Logs & Reports > Drill Down Reports and Network Logs</p>\n      </div>\n      <div class=\"p-col-fixed text-center\">\n          <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n      </div>\n    </div>\n  </div>\n\n  <div class=\"no-transactions\" *ngIf=\"errorData\">\n    <div class=\"p-col text-center\">\n       {{errorData}}\n    </div>\n    <div class=\"p-col-fixed text-center\">\n        <img src=\"assets/images/no-transactions.svg\" class=\"la-rotate-90\">\n    </div>\n</div>\n\n\n  <p-dialog appendTo=\"body\" [(visible)]=\"isCancelQuery\" modal=\"modal\" [resizable]='false'[responsive]=\"true\" [style]=\"{'height':'120px', 'width':'600px'}\">\n      <p-header>\n        <i class=\"icons8 icons8-info mx-5 text-danger\"></i>\n          <span>Query load process</span>\n      </p-header>\n    <p>{{this.commonService.cancelationMessage}} </p>\n    <p-footer class=\"p-grid p-justify-end\">\n      <button type=\"button\" pButton class=\"ui-button-rounded ui-toolbar-secondary mx-6\" (click)=\"onCancelQuery();\" label=\"Cancel\"></button>\n      <button type=\"button\" pButton class=\"ui-button-rounded\" (click)=\"waitQuery();\" label=\"Wait\"></button>\n      </p-footer>\n  </p-dialog>\n\n  <p-dialog class=\"ddr-dialog\" [(visible)]=\"loader\" appendTo=\"body\" [style]=\"{'height':'75px', 'width':'500px'}\" [closable]=\"false\" [resizable]=\"false\" modal=\"modal\" [responsive]=\"true\">\n    <div *ngIf=\"loader\">\n      <p-progressBar [value]=\"value\"></p-progressBar>\n    </div>\n  </p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.html":
/*!*********************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.html ***!
  \*********************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div (click)=\"onNodeClick()\">\n<div *ngIf=\"nodeInfo.id =='root'\" class=\"parent-cluster\">Start</div>\n<div class=\"child-indices relative\"  *ngIf=\"nodeInfo.id !='root'\">\n  <div  class=\"indices-index relative\">\n    <img [src]=\"'assets/icons8-png/' + nodeInfo.data.nodeIcon\" alt=\"Default Icon\" class=\"indices-icon\">\n  </div>\n  <div class=\"p-grid p-align-center p-nogutter\">\n    <div class=\"p-grid p-dir-col p-nogutter p-col\" *ngIf=\"(nodeInfo.data.kind | lowercase) =='server'\">\n      <div class=\"p-4 font-10 inline-flex\">\n        <img src=\"./assets/images/tier.png\" alt=\"image\" height=\"15px\" width=\"15px\">\n        <span class=\"pl-4\">{{nodeInfo.data.attributes['cav.tier'] || nodeInfo.data.resource.attributes['service.name']}} </span>\n      </div>\n      <div class=\"p-4 font-10 inline-flex\">\n        <img src=\"./assets/images/server.png\" alt=\"image\" height=\"15px\" width=\"15px\">\n        <span class=\"pl-4\">{{ nodeInfo.data.attributes['cav.server'] || nodeInfo.data.resource.attributes['host.name']}}</span>\n      </div>\n    </div>\n    <div class=\"p-grid p-dir-col p-nogutter p-col\" *ngIf=\"(nodeInfo.data.kind | lowercase) =='client'\">\n      <div class=\"p-4 font-10 inline-flex\">\n        <!-- Prefer the merged backend label so collapsed nodes show the shared endpoint name. -->\n        <span class=\"pl-4\">{{nodeInfo.data.backendDisplayName || nodeInfo.data.attributes['cav.IP'] || nodeInfo.data.name}} </span>\n      </div>\n    </div>\n    <button pButton icon=\"icons8 icons8-menu-vertical\" class=\"btn-icon\" [matMenuTriggerFor]=\"menu.childMenu\"  *ngIf=\"(nodeInfo.data.kind | lowercase) =='server'\"></button>\n    <app-widget-submenu #menu [items]=\"menuItems\" (onMenuClick)=\"onMenuClick($event)\"></app-widget-submenu>\n  </div>\n  <div class=\"connection-point left\" jtk-source=\"true\" jtk-target=\"true\"></div>\n  <div class=\"connection-point right\" jtk-source=\"true\" jtk-target=\"true\"></div>\n\n  <div class=\"hover-popup\" *ngIf=\"hoveredNodeData\">\n  \n    <div class=\"popup-header bg-secondary-100 d-bg-neutral-900 nowrap\">\n      <strong>{{ hoveredNodeData.name || hoveredNodeData.span_id }}</strong>\n    </div>\n    <div class=\"p-grid p-align-center\">\n      <span class=\"label font-weight-600 p-col-4\">Span ID:</span>\n      <span class=\"value p-col-8 nowrap\">{{ hoveredNodeData.span_id }}</span>\n      <span class=\"label font-weight-600 p-col-4\">Kind:</span>\n      <span class=\"value p-col-8 nowrap\">{{ hoveredNodeData.kind }}</span>\n      <span class=\"label font-weight-600 p-col-4\">Duration:</span>\n      <span class=\"value p-col-8 nowrap\">{{ hoveredNodeData.totalDuration || 'N/A' }} ms</span>\n      <ng-container class=\"popup-row\" *ngIf=\"hoveredNodeData.service_name\">\n        <span class=\"label font-weight-600 p-col-4\">Service:</span>\n        <span class=\"value p-col-8 nowrap\">{{ hoveredNodeData.service_name }}</span>\n      </ng-container>\n  \n    </div>\n  \n  </div>\n\n</div>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.html":
/*!*******************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.html ***!
  \*******************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"otel-service-view-container\">\n\n    <!-- Loader -->\n    <div *ngIf=\"loader\">\n        <i class=\"fa fa-spinner fa-spin\"></i> Loading...\n    </div>\n\n    <!-- Table -->\n    <div *ngIf=\"!loader\">\n        <cav-table \n            [value]=\"serviceData\" \n            [headerRelativePath]=\"relativePath\"\n            [paginator]=\"showPagination\"\n            [scrollable]=\"true\" \n            [responsive]=\"true\"\n            scrollHeight=\"calc(100vh - 240px)\"\n            (clickButtonEvent)=\"clickButtonEvent($event)\">\n        </cav-table>\n    </div>\n\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.html":
/*!*****************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.html ***!
  \*****************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\r\n    <div class=\"p-col p-col-align-center text-center\">\r\n        <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\r\n    </div>\r\n</div>\r\n\r\n<div class=\"ddr-box\">\r\n    <div class=\"ddr-toolbar\" *ngIf=\"showFilter\">\r\n        <div class=\"p-grid p-align-center p-justify-start ui-table-header\">\r\n            <span id=\"filterId\" [innerHTML]=\"filterCriteria\"></span>\r\n        </div>\r\n    </div>\r\n    <div class=\"ddruiscroll\" [ngStyle]=\"{'height': '511px'}\" style=\"overflow:auto;\">\r\n        <p-accordion class=\"ddr-accordion\"  [multiple]=\"true\">\r\n            <p-accordionTab header=\" Sequence Diagram {{seqDFilter}}\" [selected]=\"true\" *ngFor=\"let key of keysArr; let j = index\">\r\n                    <div class=\"p-grid p-align-center p-justify-end py-5\">\r\n                        <button pButton class=\"btn-icon\" icon=\"icons8 icons8-resize\" *ngIf=\"showImage == true\" (click)=\"openSeqDiagInNewTab()\" title=\"View Image In New Tab\"></button>\r\n                        <button pButton type=\"button\" (click)=\"openDialogforfilter()\" label=\"Filters\" class=\"ui-button-secondary\"></button>\r\n                        <div *ngIf=\"isAgent\">\r\n\t\t\t           <button type=\"button\" pButton class=\"btn-icon\" icon=\"cav debug-trace font-18\" (click)=\"openAutoInstDialog()\"title=\"Click to start Dynamic Diagnostics\"></button>\r\n                        </div>\r\n                    </div>\r\n                    <div class=\"ui-panel-contents\" style=\"height: auto;\">\r\n                <div class=\"seq-dig-div\" *ngIf=\"showImage == true\">                 \r\n                    <img src=\"{{imagePathObj[key]}}\" id=\"imgNDSeqId\" usemap=\"#seqImgMap\"> \r\n                        <map name=\"seqImgMap\" id='seqImgMapId'>\r\n                            <div *ngFor=\"let data of corrInfo; let i = index;\">\r\n                                <div *ngIf=\"data.pcm.indexOf('%%%') != -1;else custom\">    \r\n                                    <div class=\"container\" *ngIf=\"data.pcm.startsWith('DB Error')\">\r\n                                        <area class=\"dropbtn\" shape=\"rect\" coords=\"{{data.corrdinates}}\" areaDirective=\"{{data.pcm}}\" agent=\"{{queryParams && queryParams.Instance_Type}}\" startTime=\"{{startTimeInDateFormat}}\" id=\"area{{i}}\" (contextmenu)=\"onRightClick($event)\">\r\n                                        <div class=\"context-menu\">\r\n                                            <ul>\r\n                                                <li><a (click)=\"openDBReport(data.pcm, j)\">DB Request</a></li>\r\n                                                <li><a (click)=\"openExceptionReport(data.pcm,j,'callOut')\">Exception</a></li>\r\n                                            </ul>                   \r\n                                        </div>\r\n                                    </div>  \r\n                                   \r\n                                    <area *ngIf=\"data.pcm.startsWith('Exception')\" shape=\"rect\" coords=\"{{data.corrdinates}}\" areaDirective=\"{{data.pcm}}\" agent=\"{{queryParams && queryParams.Instance_Type}}\" startTime=\"{{startTimeInDateFormat}}\" id=\"area{{i}}\"  (click)=\"openExceptionReport(data.pcm,j,'exception')\">  \r\n           \r\n                                    <area *ngIf=\"data.pcm.startsWith('DB')\" shape=\"rect\" coords=\"{{data.corrdinates}}\" (click)=\"openDBReport(data.pcm,j)\" areaDirective=\"{{data.pcm}}\" agent=\"{{queryParams && queryParams.Instance_Type}}\" startTime=\"{{startTimeInDateFormat}}\" id=\"area{{i}}\">\r\n                                    \r\n                                    <div class=\"container\" *ngIf=\"data.pcm.startsWith('Error')\">\r\n                                        <area shape=\"rect\" coords=\"{{data.corrdinates}}\" areaDirective=\"{{data.pcm}}\" agent=\"{{queryParams && queryParams.Instance_Type}}\" startTime=\"{{startTimeInDateFormat}}\" id=\"area{{i}}\" (contextmenu)=\"onRightClick($event)\">\r\n                                            <div class=\"context-menu\">\r\n                                                <ul>\r\n                                                    <li><a (click)=\"openCallOutFlowpathInstance(data.pcm, j)\">Child Sequence Diag</a></li>\r\n                                                    <li><a (click)=\"openExceptionReport(data.pcm, j,'callOut')\">Exception</a></li>\r\n                                                </ul>                   \r\n                                            </div>\r\n                                    </div>\r\n           \r\n                                    <area *ngIf=\"data.pcm.startsWith('JMS')\" shape=\"rect\" coords=\"{{data.corrdinates}}\" areaDirective=\"{{data.pcm}}\" agent=\"{{queryParams && queryParams.Instance_Type}}\" startTime=\"{{startTimeInDateFormat}}\" id=\"area{{i}}\">\r\n                                    <area *ngIf=\"data.pcm.startsWith('Tier') || data.pcm.startsWith('Thread')\" shape=\"rect\" coords=\"{{data.corrdinates}}\" (click)=\"openCallOutFlowpathInstance(data.pcm, j)\" areaDirective=\"{{data.pcm}}\" agent=\"{{queryParams && queryParams.Instance_Type}}\" startTime=\"{{startTimeInDateFormat}}\" id=\"area{{i}}\">\r\n                                     <area shape=\"rect\" coords=\"{{data.corrdinates}}\" areaDirective=\"{{data.pcm}}\" agent=\"{{queryParams && queryParams.Instance_Type}}\" startTime=\"{{startTimeInDateFormat}}\" id=\"area{{i}}\">\r\n                                </div>\r\n                                <ng-template #custom>\r\n                                    <area shape=\"rect\" coords=\"{{data.corrdinates}}\" areaDirective=\"{{data.pcm}}\" agent=\"{{queryParams && queryParams.Instance_Type}}\" startTime=\"{{startTimeInDateFormat}}\" id=\"area{{i}}\">\r\n                                </ng-template>\r\n                            </div>\r\n                        </map>\r\n                   </div>\r\n                </div>\r\n                </p-accordionTab>\r\n                <p-accordionTab header=\" Sequence Diagram\" [selected]=\"true\" *ngIf=\"!showImage\">\r\n                <div> {{errorMsg}} </div>\r\n                </p-accordionTab>\r\n        </p-accordion>\r\n\r\n        <p-dialog class=\"secondary-dialog\" header=\"Sequence Diagram Filter Settings\" [style]=\"{width: '50vw'}\" [(visible)]=\"filterDialog\" [resizable]=false [modal]=\"true\" autoAlign=\"true\">\r\n         \r\n                <div class='ui-g'>\r\n                    <div class='ui-g-6'>\r\n                        <span style='margin-right:13px'>Class Name Width(in px)</span>\r\n                    </div>\r\n                    <div class='ui-g-6'>\r\n                        <input type=\"number\" min=0 style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtClassWidth\" />\r\n                    </div>\r\n                </div>\r\n                <div class='ui-g'>\r\n                    <div class='ui-g-6'>\r\n                        <span style='margin-right:13px'>Top Methods</span>\r\n                    </div>\r\n                    <div class='ui-g-6'>\r\n                        <input type=\"number\" min=0 style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtFlterMethodLevel\" />\r\n                    </div>\r\n                </div>\r\n                <div class='ui-g'>\r\n                    <div class='ui-g-6'>\r\n                        <span style='margin-right:13px'>Show Methods (walltime in ms) >=</span>\r\n                    </div>\r\n                    <div class='ui-g-6'>\r\n                        <input type=\"number\" min=0  style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtFilterWallTime\" />\r\n                    </div>\r\n                </div>\r\n                <div class='ui-g'>\r\n                    <div class='ui-g-6'>\r\n                        <span style='margin-right:13px'>Highlight Methods(walltime in ms) > </span>\r\n                    </div>\r\n                    <div class='ui-g-6'>\r\n                      <input type=\"number\" min=0 style='width:45%' (keypress)=\"validateQty($event)\" pInputText [(ngModel)]=\"txtThresholdWallTime\" />\r\n                    </div>\r\n                </div>\r\n                <p-accordion class=\"ddr-accordion\" [multiple]=\"true\">\r\n                    <p-accordionTab header=\"Positive Filters\" [selected]=\"true\">\r\n                        <div class='ui-g'>\r\n                            <div class='ui-g-6'>\r\n                                <span style='margin-right:13px'>Packages </span>\r\n                            </div>\r\n                            <div class='ui-g-6'>\r\n                                <p-multiSelect class=\"mutilSelectDropDown\"  [options]=\"packageList\" [(ngModel)]=\"selectedPackageList\" (onChange)=\"getClassList()\" [maxSelectedLabels]=2 appendTo=\"body\" [style]=\"{'width':'230px'}\"  [panelStyle]=\"{ 'width':'230px' }\"></p-multiSelect>\r\n                            </div>\r\n                        </div>\r\n                        <div class='ui-g'>\r\n                            <div class='ui-g-6'>\r\n                                <span style='margin-right:13px'>Classes </span>\r\n                            </div>\r\n                            <div class='ui-g-6'>\r\n                                <p-multiSelect class=\"mutilSelectDropDown\"  [options]=\"classList\" [(ngModel)]=\"selectedClassList\" (onChange)=\"getMethodList()\"  [maxSelectedLabels]=2 appendTo=\"body\" [style]=\"{'width':'230px'}\"  [panelStyle]=\"{ 'width':'230px' }\"></p-multiSelect>\r\n                            </div>\r\n                        </div>\r\n                        <div class='ui-g'>\r\n                            <div class='ui-g-6'>\r\n                                <span style='margin-right:13px'>Methods </span>\r\n                            </div>\r\n                            <div class='ui-g-6'>\r\n                                <p-multiSelect class=\"mutilSelectDropDown mctdropbox\"  [options]=\"methodList\" [(ngModel)]=\"selectedMethodList\" [maxSelectedLabels]=2 (onChange)=getActualMethodList() appendTo=\"body\" [style]=\"{'width':'230px'}\"  [panelStyle]=\"{ 'width':'230px' }\"></p-multiSelect>\r\n                            </div>\r\n                        </div>\r\n                    </p-accordionTab>\r\n                    <p-accordionTab header=\"Negative Filters\" [selected]=\"true\">\r\n                        <div class='ui-g'>\r\n                            <div class='ui-g-6'>\r\n                                <span style='margin-right:13px'>Do not show methods </span>\r\n                            </div>\r\n                            <div class='ui-g-6'>\r\n                                <span class=\"ui-fluid\">\r\n                                    <p-autoComplete [(ngModel)]=\"selectedNegativeMethod\" [size]=\"30\" styleClass=\"ddr-autocomplete\" [suggestions]=\"negativeMethodArr\"\r\n                                    (completeMethod)=\"searchMethodName($event)\" [multiple]=\"true\" appendTo=\"body\"></p-autoComplete>\r\n                                </span>\r\n                            </div>\r\n                        </div>\r\n                      </p-accordionTab>\r\n                    <p-accordionTab header=\"Advanced Settings\" [selected]=\"true\">\r\n                        <p class=\"font-weight-600\">Do not filter CallOuts</p>\r\n                        <div class=\"ui-g border-1 p-5\" style=\"border-style:solid; border-width: 1px;\">\r\n                            <table class=\"w-60-p\">\r\n                                <tr>\r\n                                    <td><p-checkbox name=\"groupname\" label=\"HTTP CallOuts\" value=\"T\" [(ngModel)]=\"ignoreFilterCallOutsforSD\"></p-checkbox></td>\r\n                                    <td><p-checkbox name=\"groupname\" label=\"DB CallOuts\" value=\"D\" [(ngModel)]=\"ignoreFilterCallOutsforSD\"></p-checkbox></td>\r\n                                </tr>\r\n                                <tr> \r\n                                    <td><p-checkbox name=\"groupname\" label=\"JMS CallOuts\" value=\"J\" [(ngModel)]=\"ignoreFilterCallOutsforSD\"></p-checkbox></td>\r\n                                    <td><p-checkbox name=\"groupname\" label=\"Error CallOuts\" value=\"E\" [(ngModel)]=\"ignoreFilterCallOutsforSD\"></p-checkbox></td>\r\n                                </tr>\r\n                                <tr> \r\n                                    <td><p-checkbox name=\"groupname\" label=\"Thread CallOuts\" value=\"t\" [(ngModel)]=\"ignoreFilterCallOutsforSD\"></p-checkbox></td>\r\n                                    <td><p-checkbox name=\"groupname\" label=\"DBError CallOuts\" value=\"d\" [(ngModel)]=\"ignoreFilterCallOutsforSD\"></p-checkbox></td>\r\n                                </tr>\r\n                                <tr> \r\n                                    <td><p-checkbox name=\"groupname\" label=\"Async callouts\" value=\"A\" [(ngModel)]=\"ignoreFilterCallOutsforSD\"></p-checkbox></td>\r\n                                    <td><p-checkbox name=\"groupname\" label=\"Exception\" value=\"e\" [(ngModel)]=\"ignoreFilterCallOutsforSD\"></p-checkbox></td>\r\n                                </tr>\r\n                            </table>\r\n                        </div>\r\n                    </p-accordionTab>\r\n                </p-accordion>\r\n            \r\n            <p-footer>\r\n                <div class=\"p-grid p-align-center p-justify-end py-5\">\r\n                    <button pButton type=\"button\" label=\"Reset\" (click)=\"applyDefaultValue()\" class=\"ui-button-rounded ui-button-secondary mx-3\"></button>\r\n                    <button pButton type=\"button\" label=\"Cancel\" (click)=\"filterDialog =false\" class=\"ui-button-rounded ui-button-secondary mx-3\"></button>\r\n\r\n                    <button pButton type=\"button\" label=\"Show All\" (click)=\"showAllData()\" class=\"ui-button-rounded mx-3\"></button>\r\n                    <button pButton type=\"button\" label=\"Apply\"  (click)=\"applyThresholdFilter()\" class=\"ui-button-rounded mx-3\"></button>\r\n                </div>      \r\n            </p-footer>\r\n        </p-dialog>\r\n    </div>\r\n</div>\r\n\r\n<p-dialog class=\"secondary-dialog foterDialog\" [style]=\"{width: '900px'}\" header=\"Dynamic Diagnostics Configuration\" [resizable]=\"false\" *ngIf=\"showAutoInstrPopUp\" [(visible)]=\"showAutoInstrPopUp\" modal=\"modal\" [contentStyle]=\"{'max-height':'500px'}\" responsive=\"true\">\r\n        <app-dynamic-diagnostics (resultAfterStart)=\"startInstrumentation($event)\" (closeAIDDGui)=\"closeAIDDDialog($event)\" [passAIDDSettings]=\"argsForAIDDSetting\"></app-dynamic-diagnostics>\r\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.html":
/*!***************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.html ***!
  \***************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid loader-container vertical-container h-100-vh\" *ngIf=\"loading\">\n  <div class=\"p-col p-col-align-center text-center\">\n    <div><i class=\"pi pi-spin pi-spinner font-25\"></i> <span class=\"font-25\">Loading</span></div>\n  </div>\n</div>\n\n<div class=\"ddr-box\">\n  <div class=\"p-grid p-align-center p-justify-between ui-table-header\">\n    <div>\n      <span title=\"{{completeTier}}\">{{filterTierName}}</span>\n      <span>{{filterCriteria}}</span>\n    </div>\n    <div>\n    </div>\n  </div>\n\n  <!-- COMMON BOX SCROLLLBAR -->\n  <div class=\"ddruiscroll\" [ngStyle]=\"{'height': 'calc(90vh - 15px)'}\" style=\"overflow:auto;\">\n    <div class=\"ui-g-12\">\n      <cav-table [value]=\"data\" [headerRelativePath]=\"relativePath\" [scrollable]=\"true\" [responsive]=\"true\"\n        scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n      <div class=\"py-12\">{{offset+1}} - {{offset+limit}} of {{totalCount}}</div>\n      <div *ngIf=\"showPagination\">\n        <p-paginator rows=\"50\" [totalRecords]=\"totalCount\" [rowsPerPageOptions]=\"[50,100,200,300,400]\" pageLinkSize=\"3\"\n          (onPageChange)=\"paginate($event)\"></p-paginator>\n      </div>\n    </div>\n  </div>\n  <p-dialog class=\"secondary-dialog\" [style]=\"{width: '50vw'}\" [(visible)]=\"isCancelQuery\" modal=\"modal\"\n    [resizable]='false' [responsive]=\"true\" height=\"120\" width=\"600\">\n    <p-header>\n      <i class=\"icons8 icons8-info\" style=\"color:red\"></i>\n      <span>&nbsp;&nbsp;&nbsp;Query load process</span>\n    </p-header>\n    <span style=\"font-size:14px\">{{this.commonService.cancelationMessage}} </span>\n    <p-footer>\n      <div class=\"p-grid p-justify-end sevbtn py-12\">\n        <button pButton type=\"button\" label=\"Cancel\" (click)=\"onCancelQuery();\" [disabled]=\"isCancelQuerydata\"\n          class=\"ui-button-rounded ui-button-secondary\"></button>\n        <button pButton type=\"button\" label=\"Wait\" (click)=\"waitQuery();\" class=\"ui-button-rounded\"></button>\n      </div>\n    </p-footer>\n  </p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.html":
/*!************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.html ***!
  \************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid p-align-center p-justify-between my-8\">\n  <div class=\"p-grid p-align-center\">\n    <div class=\"mr-3\">Showing Hotspots</div>\n    <label *ngIf=\"hideTimeFilters\">From={{startTimeInDate}} To={{endTimeInDate}}</label>\n    <p-dropdown *ngIf=\"hideTimeRange\"  [options]=\"timeRange\" [(ngModel)]=\"selectedTimeRange\" placeholder=\"Select Time\"\n      [style]=\"{'width': '93px'}\"></p-dropdown>\n      <div class=\"ml-10 mr-4\">Stacktrace Contains</div>\n      <input id=\"input\" type=\"text\" size=\"20\" pInputText [(ngModel)]=\"stackTrace\">\n    <button pTooltip=\"Apply\" pButton label=\"Apply\" class=\"ml-20\"\n    (click)=\"clickApply(stackTrace,selectedTimeRange)\"></button>\n  <button pButton label=\"Reset\" class=\"mx-6 btn-secondary-outline\" (click)=\"clickReset(stackTrace)\"></button>\n  </div>\n</div>\n<div class=\"ddruiscroll\" [ngStyle]=\"{'height': 'calc(75vh - 17px)'}\" style=\"overflow:auto;\">\n<div class=\"ddr-acc-threadHotspot\">\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"true\" header=\"Thread Signature {{hotspotFilter}}\">\n        <div class=\"p-grid p-align-center p-justify-end my-6\">\n          <div class=\"p-grid p-align-center\">\n          </div>\n        </div>\n        <cav-table [value]=\"hotSpotInfo\" [headerRelativePath]=\"relativePathForSignature\" [scrollable]=\"true\" [responsive]=\"true\"\n        (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>\n    </p-accordionTab>\n  </p-accordion>\n\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"true\" header=\"Thread StackTrace {{stackTraceFilter}}\">\n      <div style=\"overflow:auto;\">\n        <p-treeTable #threadStack class=\"all-tables\" [value]=\"hotSpotSecInfo\" [scrollable]=\"true\" scrollHeight=\"200px\"Custom Match Stack Depth\n        [columns]=\"colsForStackTrace\" [resizableColumns]=\"true\"\n          columnResizeMode=\"expand\" [scrollable]=\"true\">\n          <ng-template pTemplate=\"caption\">\n            <div class=\"p-grid p-align-center p-justify-end\">\n            <div class=\"type-search width-180 mr-4\">\n              <i class=\"left-icon icons8 icons8-search\"></i>\n              <input pInputText type=\"text\" class=\"pl-22\" placeholder=\"Search\" \n                (input)=\"threadStack.filterGlobal($event.target.value, 'contains')\" />\n            </div>\n            </div>\n          </ng-template>\n          <ng-template pTemplate=\"colgroup\" let-columns>\n            <colgroup>\n              <ng-container *ngFor=\"let col of columns\">\n                <col *ngIf=\"col.action\" [style.width]=\"col.width\">\n              </ng-container>\n            </colgroup>\n          </ng-template>\n          <ng-template pTemplate=\"header\" let-rowNode let-columns>\n            <tr [ttRow]=\"rowNode\">\n              <th *ngFor=\"let col of columns\" ttResizableColumn>\n                {{col.header}}\n              </th>\n            </tr>\n          </ng-template>\n          <ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\" let-columns=\"columns\">\n            <tr>\n              <td *ngFor=\"let col of columns; let i = index\">\n                <p-treeTableToggler [rowNode]=\"rowNode\" *ngIf=\"i == 0\"></p-treeTableToggler>\n                <span *ngIf=\"col.field == 'lineNo' || col.field == 'frameNo'\" class=\"right\" tooltipPosition=\"bottom\"\n                  tooltipEvent=\"hover\" pTooltip={{rowData[col.field]}}>\n                  {{rowData[col.field]}} </span>\n                <span *ngIf=\"!(col.field == 'lineNo' || col.field == 'frameNo')\" tooltipPosition=\"bottom\"\n                  tooltipEvent=\"hover\" pTooltip={{rowData[col.field]}}>\n                  {{rowData[col.field]}} </span>\n              </td>\n            </tr>\n          </ng-template>\n          <ng-template pTemplate=\"emptymessage\">\n            <tr>\n              <td [attr.colspan]=\"colsForStackTrace.length\" class=\"text-center\">No Records Found</td>\n            </tr>\n          </ng-template>\n        </p-treeTable>\n      </div>\n    </p-accordionTab>\n  </p-accordion>\n</div>\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.html":
/*!******************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.html ***!
  \******************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid p-align-center p-justify-between my-8\">\n  <div class=\"p-grid p-align-center\">\n    <div class=\"mr-3\">Showing Hotspots</div>\n    <label *ngIf=\"hideTimeFilters\">From={{startTimeInDate}} To={{endTimeInDate}}</label>\n    <p-dropdown *ngIf=\"hideTimeRange\"  [options]=\"timeRange\" [(ngModel)]=\"selectedTimeRange\" placeholder=\"Select Time\"\n      [style]=\"{'width': '93px'}\"></p-dropdown>\n      <div class=\"ml-10 mr-4\">Stacktrace Contains</div><input id=\"input\" type=\"text\" size=\"20\" pInputText [(ngModel)]=\"stackTrace\">\n\n    <button pTooltip=\"Apply\" pButton label=\"Apply\" class=\"ml-20\"\n    (click)=\"clickApply(stackTrace,selectedTimeRange)\"></button>\n  <button pButton label=\"Reset\" class=\"mx-6 btn-secondary-outline\" (click)=\"clickReset(stackTrace)\"></button>\n\n  </div>\n</div>\n\n<div class=\"ddr-acc-threadHotspot\" [ngStyle]=\"{'height': 'calc(75vh - 17px)'}\" style=\"overflow:auto;\">\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"true\" header=\"Thread Signature {{hotspotFilter}}\">\n        <cav-table [value]=\"hotSpotInfo\" [headerRelativePath]=\"relativePathForSignature\"\n        [scrollable]=\"true\" [responsive]=\"true\"\n        (clickButtonEvent)=\"clickButtonEvent($event)\" ></cav-table>\n    </p-accordionTab>\n  </p-accordion>\n\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"true\" header=\"Thread StackTrace {{stackTraceFilter}}\">\n      <div>\n        <p-treeTable #threadStack class=\"all-tables\" [scrollable]=\"true\" scrollHeight=\"200px\" [value]=\"hotSpotSecInfo\" [columns]=\"colsForStackTrace\" [resizableColumns]=\"true\"\n          columnResizeMode=\"expand\" [scrollable]=\"true\">\n          <ng-template pTemplate=\"caption\">\n            <div class=\"p-grid p-align-center p-justify-end\">\n              <div class=\"type-search width-180 mr-4\">\n                <i class=\"left-icon icons8 icons8-search\"></i>\n                <input pInputText type=\"text\" class=\"pl-22\" placeholder=\"Search\" \n                (input)=\"threadStack.filterGlobal($event.target.value, 'contains')\" />\n            </div>\n            </div>\n          </ng-template>\n          <ng-template pTemplate=\"colgroup\" let-columns>\n            <colgroup>\n              <ng-container *ngFor=\"let col of columns\">\n                <col *ngIf=\"col.action\" [style.width]=\"col.width\">\n              </ng-container>\n            </colgroup>\n          </ng-template>\n          <ng-template pTemplate=\"header\" let-rowNode let-columns>\n            <tr [ttRow]=\"rowNode\">\n              <th *ngFor=\"let col of columns\" ttResizableColumn>\n                {{col.header}}\n              </th>\n            </tr>\n          </ng-template>\n          <ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\" let-columns=\"columns\">\n            <tr>\n              <td *ngFor=\"let col of columns; let i = index\">\n                <p-treeTableToggler [rowNode]=\"rowNode\" *ngIf=\"i == 0\"></p-treeTableToggler>\n                <span *ngIf=\"col.field == 'lineNo' || col.field == 'frameNo'\" class=\"right\" tooltipPosition=\"bottom\"\n                  tooltipEvent=\"hover\" pTooltip={{rowData[col.field]}}>\n                  {{rowData[col.field]}} </span>\n                <span *ngIf=\"!(col.field == 'lineNo' || col.field == 'frameNo')\" tooltipPosition=\"bottom\"\n                  tooltipEvent=\"hover\" pTooltip={{rowData[col.field]}}>\n                  {{rowData[col.field]}} </span>\n              </td>\n            </tr>\n          </ng-template>\n          <ng-template pTemplate=\"emptymessage\">\n            <tr>\n              <td [attr.colspan]=\"colsForStackTrace.length\" class=\"text-center\">No Records Found</td>\n            </tr>\n          </ng-template>\n        </p-treeTable>\n      </div>\n    </p-accordionTab>\n  </p-accordion>\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.html":
/*!********************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.html ***!
  \********************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"p-grid p-align-center p-justify-between my-8\">\n  <div class=\"p-grid p-align-center\">\n    <div class=\"mr-3\">Showing Hotspots</div>\n    <label *ngIf=\"hideTimeFilters\">From={{startTimeInDate}} To={{endTimeInDate}}</label>\n    <p-dropdown *ngIf=\"hideTimeRange\" [options]=\"timeRange\" dropdownIcon=\"icons8 icons8-expand-arrow\" [(ngModel)]=\"selectedTimeRange\" placeholder=\"Select Time\"\n      [style]=\"{'width': '93px'}\"></p-dropdown>\n    <div class=\"ml-10 mr-4\">Stacktrace Contains</div><input id=\"input\" type=\"text\" size=\"7\" pInputText [(ngModel)]=\"stackTrace\">\n    <div class=\"ml-10 mr-4\">Min Depth</div><input id=\"input\" type=\"text\" size=\"7\" pInputText [(ngModel)]=\"minDepth\">\n    <div class=\"ml-10 mr-4\">Min Duration(in sec)</div><input id=\"input\" type=\"text\" size=\"7\" pInputText [(ngModel)]=\"minDuration\">\n    <div class=\"ml-10 mr-4\" *ngIf=\"signaturePassHeader != ''\">Signature:<input type=\"text\" pInputText #stSignature\n        value=\"{{signaturePassHeader}}\" />\n        <button pTooltip=\"Update Signature\" pButton class=\"btn-icon\"\n        icon=\"las-save\" (click)='updateSignature(stSignature.value)'></button>\n      </div>\n      <button pTooltip=\"Apply\" pButton label=\"Apply\" class=\"ml-20\"\n      (click)=\"clickApply(stackTrace,minDepth,selectedTimeRange,minDuration)\"></button>\n    <button pButton label=\"Reset\" class=\"mx-6 btn-secondary-outline\" (click)=\"clickReset()\"></button>\n  </div>\n\n  <div class=\"p-grid p-align-center\">\n    <button *ngIf=\"BackFlag\" pTooltip=\"Back\" pButton icon=\"icons8 icons8-back-arrow\" class=\"btn-icon\"\n      (click)=\"clickBack()\"></button>\n\n  </div>\n</div>\n\n<div class=\"ddr-acc-threadHotspot\" [ngStyle]=\"{'height': 'calc(75vh - 17px)'}\" style=\"overflow:auto;\">\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"true\" header=\"Hotspot Summary {{hotspotFilter}}\">\n      <cav-table [value]=\"hotSpotInfo\" [headerRelativePath]=\"relativePathForHotspot\" [scrollable]=\"true\" [responsive]=\"true\"\n        (clickButtonEvent)=\"clickButtonEvent($event)\"></cav-table>\n    </p-accordionTab>\n  </p-accordion>\n\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"true\" header=\"Thread StackTrace {{stackTraceFilter}}\">\n      <p-treeTable #threadStack [value]=\"hotSpotSecInfo\" [columns]=\"colsForStackTrace\" [resizableColumns]=\"true\" [scrollable]=\"true\" scrollHeight=\"330px\" columnResizeMode=\"expand\" [scrollable]=\"true\">\n        <ng-template pTemplate=\"caption\">\n          <div class=\"p-grid p-align-center p-justify-end\">\n          <div class=\"type-search width-180 mr-4\">\n            <i class=\"left-icon icons8 icons8-search\"></i>\n            <input pInputText type=\"text\" class=\"pl-22\" placeholder=\"Search\" \n              (input)=\"threadStack.filterGlobal($event.target.value, 'contains')\" />\n          </div>\n          </div>\n        </ng-template>\n        <ng-template pTemplate=\"colgroup\" let-columns>\n          <colgroup>\n            <ng-container *ngFor=\"let col of columns\">\n              <col *ngIf=\"col.action\" [style]=\"{'width': col.width,'text-align': col.align}\">\n            </ng-container>\n          </colgroup>\n        </ng-template>\n        <ng-template pTemplate=\"header\" let-rowNode let-columns>\n          <tr [ttRow]=\"rowNode\">\n            <th *ngFor=\"let col of columns\" ttResizableColumn>\n              {{col.header}}\n            </th>\n          </tr>\n        </ng-template>\n        <ng-template pTemplate=\"body\" let-rowNode let-rowData=\"rowData\" let-columns=\"columns\">\n          <tr>\n            <td *ngFor=\"let col of columns; let i = index\">\n              <p-treeTableToggler [rowNode]=\"rowNode\" *ngIf=\"i == 0\"></p-treeTableToggler>\n              <span *ngIf=\"col.field == 'lineNo' || col.field == 'elapsedTime' || col.field == 'frameNo'\" class=\"right\"\n                pTooltip=\"{{rowData[col.field]}}\" tooltipPosition=\"bottom\"> {{rowData[col.field]}}</span>\n              <span *ngIf=\"!(col.field == 'lineNo' || col.field == 'elapsedTime' || col.field == 'frameNo')\"\n                pTooltip=\"{{rowData[col.field]}}\" tooltipPosition=\"bottom\"> {{rowData[col.field]}}</span>\n            </td>\n          </tr>\n        </ng-template>\n        <ng-template pTemplate=\"emptymessage\">\n          <tr>\n            <td [attr.colspan]=\"colsForStackTrace.length\" class=\"text-center\">No Records Found</td>\n          </tr>\n        </ng-template>\n      </p-treeTable>\n    </p-accordionTab>\n  </p-accordion>\n\n  <p-accordion [multiple]=\"true\" class=\"ddr-accordion\">\n    <p-accordionTab [selected]=\"false\" header=\"Integration Point Call(s) {{stackTraceFilter}}\">\n      <div *ngIf=\"!aggCase; else aggTable\">\n        <cav-table [value]=\"IPInfo\" [headerRelativePath]=\"relativePathForIp\" [scrollable]=\"true\" [responsive]=\"true\"\n        scrollHeight=\"calc(100vh - 240px)\"></cav-table>\n      </div>\n      <ng-template #aggTable>\n        <app-agg-ip-info [aggIpInfo]=\"aggIpInfo\" [renamebackendNameMap]=\"renamebackendNameMap\"\n          [actualBackendNameMap]=\"actualBackendNameMap\" [backendSubTypeNameMap]=\"backendSubTypeNameMap\"\n          [filterCriteriaagg]=\"filterCriteriaagg\" [showWarning]=false [maxFlowPath]=0></app-agg-ip-info>\n      </ng-template>\n    </p-accordionTab>\n  </p-accordion>\n</div>\n\n<p-dialog header=\"Query Details\" [(visible)]=\"displayPopUp\" modal=\"modal\" appendTo=\"body\" responsive=\"true\">\n  <div class=\"modalPopUp\">\n    <table width=\"600\" border=\"0\" cellspacing=\"3\">\n      <tbody *ngFor=\"let data of rowData\">\n        <tr>\n          <td><b>Integration Point</b></td>\n          <td>{{data.IPname}}</td>\n        </tr>\n        <tr>\n          <td><b>Discovered Name</b></td>\n          <td>{{data.DiscoveredIPName}}</td>\n        </tr>\n        <tr>\n          <td><b>Type</b></td>\n          <td>{{data.Type}}</td>\n        </tr>\n        <tr>\n          <td><b>Start Time</b></td>\n          <td>{{data.StartTime}}</td>\n        </tr>\n        <tr>\n          <td><b>Duration(ms)</b></td>\n          <td>{{data.Duration}}</td>\n        </tr>\n        <tr>\n          <td><b>Status</b></td>\n          <td>{{data.Status}}</td>\n        </tr>\n        <tr>\n          <td><b>Query</b></td>\n          <td><textarea pInputTextarea rows=\"8\" cols=\"40\">{{data.Query}}</textarea></td>\n        </tr>\n      </tbody>\n    </table>\n  </div>\n</p-dialog>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.html":
/*!*************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.html ***!
  \*************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<p-dialog class=\"secondary-dialog\" header=\"Custom Match Stack Depth\" [(visible)]=\"display\" [closable] = \"false\" modal=\"modal\" appendTo = \"body\" [style]=\"{width: '23vw'}\" [responsive]=\"true\" [draggable]=\"false\">\n    Number of Top Frames for Grouping \n    \n    <input id=\"input\" class=\"ml-3\" type=\"text\" size=\"5\" maxlength=\"5\" pInputText [(ngModel)]=\"topFrame\">\n    <p-footer>\n        <button pButton type=\"button\"  pButton (click)=\"back()\" label=\"Cancel\" class=\"ui-button-rounded ui-button-secondary mr-6\"></button>\n        <button pButton type=\"button\" (click)=\"getValue()\" label=\"Ok\" class=\"ui-button-rounded\"></button>\n\n     \n    </p-footer>\n</p-dialog>\n\n<div>\n     <!-- COMMON TOOLBAR -->\n    <div class=\"ddr-box\">\n <!-- <p-toolbar>\n    <div class=\"reportInfo\">\n      <label class=\"headerInfo\"><b>{{reportHeader}}</b></label>\n    </div>\n </p-toolbar> -->\n<! --COMMON BOX SCROLLLBAR -->\n<!-- <div [ngStyle]=\"{'height': screenHeight+'px'}\" style=\"overflow:auto;\"> -->\n<p-tabView class=\"ddr-tabs\" (onChange)=\"handleChange($event)\">\n    <p-tabPanel header=\"No Grouping\" leftIcon=\"fa fa-map-o\" [selected]=\"index == 0\" >\n        <app-nogrouping *ngIf = \"index == 0\"  [signatureName]=\"signatureName\" [displayName] = \"displayName\" (stSignature)=\"saveSignatureData($event)\" [compareDepth]=\"depth\"></app-nogrouping>\n    </p-tabPanel>\n    <p-tabPanel header=\"All Frame\" leftIcon=\"fa fa-bookmark-o\" [selected]=\"index == 1\">\n        <app-group-by-all *ngIf = \"index == 1\"  (stSignature)=\"saveSignatureData($event)\" ></app-group-by-all>\n    </p-tabPanel>\n    <p-tabPanel header=\"Custom Depth\" leftIcon=\"fa fa-crosshairs\" [selected]=\"index == 2\">\n        <app-group-by-custom *ngIf =\"(!display && index == 2)\" [topFrame]=\"topFrame\" (stSignature)=\"saveSignatureData($event)\" ></app-group-by-custom>\n    </p-tabPanel>\n</p-tabView>\n<!-- </div> -->\n</div>\n</div>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.html":
/*!*****************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.html ***!
  \*****************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<div class=\"page\">\n    <div class=\"p-grid p-align-center p-justify-between w-100-p bg-secondary-100 d-bg-secondary-base\">\n        <div class=\"p-col-fixed\">\n            <h3 class=\"my-0\">Flame Graph</h3>\n        </div>\n        <div class=\"p-col-fixed inline-flex\">\n            <div class=\"type-search width-200\">\n                <i class=\"right-icon icons8 icons8-search clickable mr-6\" (click)=\"onSearch()\"></i>\n                <input type=\"text\" class=\"pl-6 w-100-p mr-6\" placeholder=\"Search\" [(ngModel)]=\"searchTerm\" pInputText />\n            </div>\n            <button pButton class=\"mx-3 ui-button-secondary mr-5\" (click)=\"toggleInvert()\" label=\"Invert\"></button>\n            <button pButton class=\"mx-3 btn-secondary-outline\" (click)=\"onReset()\" label=\"Reset\"></button>\n        </div>\n    </div>\n    <div class=\"chart-wrap\" [class.inverted]=\"isInverted\">\n        <div #chartRef id=\"chart\"></div>\n    </div>\n</div>");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.html":
/*!***************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.html ***!
  \***************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("\n<app-cav-loader *ngIf=\"loader\"></app-cav-loader>\n<div class=\"p-grid\"  *ngIf=\"chartOptions && chartOptions.series && chartOptions.series.length > 0\">\n<div [ngClass]=\"{'p-col-12': !selectedTask, 'p-col-8': selectedTask}\" style=\"transition: width 200ms ease-in-out;\">\n  <div class=\"border-all border-7 rounded-3\">\n    <p-toolbar class=\"ui-primary-toolbar\" styleClass=\"border-none\">\n      <div class=\"p-grid p-align-center font-13 min-height-37\" *ngIf=\"selectedTopRowData\">\n        <div class=\"p-col-fixed\"><span class=\"opc-80\">Service Name:</span>\n          <strong>{{selectedTopRowData?.resource?.attributes[\"service.name\"]}}</strong></div>\n        <div class=\"p-col-fixed\"><span class=\"opc-80\">Total Spans:</span> <strong>{{graphData.length}}</strong></div>\n        <div class=\"p-col-fixed\"><span class=\"opc-80\">Trace Id:</span> <strong>{{selectedTopRowData.trace_id}}</strong></div>\n        <div class=\"p-col-fixed\"><span class=\"opc-80\">Duration:</span> <strong>{{formatDuration(selectedTopRowData.duration)}}</strong></div>\n        <div class=\"p-col-fixed\"><span class=\"opc-80\">Tier:</span> <strong>{{selectedTopRowData.attributes[\"cav.tier\"]}}</strong></div>\n        <div class=\"p-col-fixed\"><span class=\"opc-80\">Server:</span> <strong>{{selectedTopRowData.attributes[\"cav.server\"]}}</strong></div>\n        <div class=\"p-col-fixed\"><span class=\"opc-80\">Instance:</span> <strong>{{selectedTopRowData.attributes[\"cav.instance\"]}}</strong></div>\n        <div class=\"p-col-fixed\"><span class=\"opc-80\">BT:</span> <strong>{{selectedTopRowData.attributes[\"cav.BT\"]}}</strong></div>\n        <div class=\"p-col\" style=\"text-align: right;\">\n        <button type=\"button\" pButton matTooltip=\"Download\" icon=\"las-download-solid\" class=\"btn-icon\" (click)=\"downloadTraceDetails()\"></button>\n        </div>\n      </div> \n    </p-toolbar>\n    <div class=\"p-6 overflow top-border border-7\" [ngClass]=\"commonService.isFromSplitView ? 'h-100vh-250' : 'h-100vh-150'\">\n    <div class=\"mln-6 mrn-6\">  \n    <highcharts-chart \n    [Highcharts]=\"Highcharts\" \n    [constructorType]=\"'ganttChart'\" \n    [options]=\"chartOptions\"\n    [callbackFunction]=\"chartCallback\"\n    style=\"display: block; width: 100%;\">\n    </highcharts-chart>\n    </div>\n    </div>\n  </div>\n</div>\n<div class=\"p-col-4\" *ngIf=\"selectedTask\">\n  <div class=\"border-all border-7 rounded-3\">\n    <p-toolbar class=\"ui-primary-toolbar\" styleClass=\"border-none\">\n      <div class=\"p-grid p-justify-between p-align-center p-8 font-13\">\n        <strong>Span Details</strong>\n        <button type=\"button\" pButton matTooltip=\"Close\" icon=\"icons8 icons8-delete\" class=\"btn-icon\"\n          (click)=\"closeSelectedTask()\"></button>\n      </div>\n    </p-toolbar>\n    <div class=\"p-6 overflow top-border border-7 line-height18\"  [ngClass]=\"commonService.isFromSplitView ? 'h-100vh-220' : 'h-100vh-150'\">\n      <div class=\"mln-6 mrn-6 mb-4\">\n        <div class=\"p-grid\">\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Service Name</span>\n              <strong class=\"word-break\">{{selectedRowData?.resource?.attributes[\"service.name\"] || '-'}}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Span Name</span>\n              <strong class=\"word-break\">{{selectedRowData.name || '-'}}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Span ID</span>\n              <strong class=\"word-break\">{{selectedRowData.span_id || '-'}}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Parent ID</span>\n              <strong class=\"word-break\">{{selectedRowData.parent_span_id || '-'}}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Duration</span>\n              <strong class=\"word-break\">{{ formatDuration(selectedRowData.duration) }}</strong>\n            </div>\n          </div>\n          <div class=\"p-col-6\">\n            <div class=\"bg-neutral-100 d-bg-neutral-800 rounded-3 p-grid p-dir-col p-6 h-100-p\">\n              <span class=\"opc-70 font-11\">Kind</span>\n              <strong class=\"word-break\">{{selectedRowData.kind || '-'}}</strong>\n            </div>\n          </div>\n        </div>\n      </div>\n      <p-accordion multiple=\"true\">\n        <p-accordionTab header=\"Span Attributes\" [selected]=\"true\">\n          <table class=\"w-100-p\">\n            <tr *ngFor=\"let entry of flattenObject(spanAttributes); trackBy: trackByKey\">\n              <td class=\"word-break w-35-p\"><strong>{{ entry.key }}</strong></td>\n              <td class=\"word-break w-65-p hover\">{{ entry.value }}\n                <button type=\"button\" pButton class=\"btn-icon showHover\" icon=\"icons8 icons8-copy\"\n                  (click)=\"copyToClipboard(entry.value)\" matTooltip=\"Copy to Clipboard\"></button>\n              </td>\n            </tr>\n          </table>\n        </p-accordionTab>\n        <p-accordionTab header=\"Resource Attributes\" [selected]=\"false\">\n          <table class=\"w-100-p\">\n            <tr *ngFor=\"let entry of flattenObject(resourceAttributes); trackBy: trackByKey\">\n              <td class=\"word-break w-35-p\"><strong>{{ entry.key }}</strong></td>\n              <td class=\"word-break w-65-p hover\">{{ entry.value }}\n                <button type=\"button\" pButton class=\"btn-icon showHover\" icon=\"icons8 icons8-copy\"\n                  (click)=\"copyToClipboard(entry.value)\" matTooltip=\"Copy to Clipboard\"></button>\n              </td>\n            </tr>\n          </table>\n        </p-accordionTab>\n        <p-accordionTab header=\"Scope\" [selected]=\"false\">\n          <table class=\"w-100-p\">\n            <tr *ngFor=\"let entry of flattenObject(scope); trackBy: trackByKey\">\n              <td class=\"word-break w-35-p\"><strong>{{ entry.key }}</strong></td>\n              <td class=\"word-break w-65-p hover\">{{ entry.value }}\n                <button type=\"button\" pButton class=\"btn-icon showHover\" icon=\"icons8 icons8-copy\"\n                  (click)=\"copyToClipboard(entry.value)\" matTooltip=\"Copy to Clipboard\"></button>\n              </td>\n            </tr>\n          </table>\n        </p-accordionTab>\n      </p-accordion>\n    </div>\n  </div>\n</div>\n</div>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.html":
/*!*******************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.html ***!
  \*******************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<app-cav-loader *ngIf=\"loader\"></app-cav-loader>\n<div class=\"mln-3 mrn-3\">\n  <div class=\"p-grid p-align-center\">\n    <ng-container *ngFor=\"let criteria of filterCriteriaArray\">\n      <span class=\"bg-secondary-200 d-bg-secondary-base rounded-3 py-3 px-6 m-3\">{{criteria}}</span>\n    </ng-container>\n  </div>\n</div>\n\n<div class=\"surfWrap\">\n    <jsplumb-surface #jsplumbSurface [toolkitId]=\"toolkitId\" [surfaceId]=\"surfaceId\" [view]=\"view\"\n      [renderParams]=\"renderParams\">\n    </jsplumb-surface>\n</div>\n\n<p-dialog header=\"Node Details\" [(visible)]=\"nodeDetails\" [modal]=\"true\" [style]=\"{width: '60vw'}\">\n  <div class=\"p-grid p-nogutter\">\n    <div class=\"p-col-12\" *ngIf=\"nodeKind == 'client'\">\n      <cav-table [value]=\"clientNodeData\" [headerRelativePath]=\"relativePathForINDPopup\"\n        (clickButtonEvent)=\"clickButtonEvent($event)\" scrollable=\"true\" scrollHeight=\"calc(100vh - 320px)\"></cav-table>\n    </div>\n    <div class=\"p-col-12\" *ngIf=\"nodeKind == 'server'\">\n      <cav-table [value]=\"serverNodeData\" [headerRelativePath]=\"relativePathForINDPopup\"\n        (clickButtonEvent)=\"clickButtonEvent($event)\" scrollable=\"true\" scrollHeight=\"calc(100vh - 320px)\"></cav-table>\n    </div>\n  </div>\n  <p-footer *ngIf=\"nodeKind == 'client'\">\n    <div class=\"p-grid p-align-center p-justify-between\">\n      <div class=\"left-content word-break\">\n        {{fullQueryName}}\n      </div>\n      <div class=\"right-content\">\n        <i class=\"icons8 icons8-copy font-18 mr-3\" label=\"Copy Query\" (click)=\"copytext(fullQueryName)\"></i>\n      </div>\n    </div>\n  </p-footer>\n\n</p-dialog>\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/weblogic/weblogic.component.html":
/*!*************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/weblogic/weblogic.component.html ***!
  \*************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<p-blockUI [blocked]=\"loading\"></p-blockUI>\r\n<img *ngIf=\"loading\" class=\"loadingIcon1\" src=\"./images/loading.gif\" />\r\n\r\n<div class= \"main-box\">\r\n<p-toolbar>\r\n  <div style='text-align:center'>\r\n     <label style=\"font-size: 15px;font-family:'Roboto','Trebuchet MS',Arial, Helvetica, sans-serif;\"><b>{{reportHeader}}</b></label>\r\n  </div>\r\n</p-toolbar>\r\n<p-toolbar>\r\n      <div class='ui-toolbar-group-left'>\r\n       <label style=\"font-size: 14px;margin-left: 3px;font-family:'Roboto','Trebuchet MS',Arial, Helvetica, sans-serif;\"><b>Filter Criteria : </b></label><label style=\"font-size: 14px;font-family:'Roboto','Trebuchet MS',Arial, Helvetica, sans-serif;\">{{filterCriteria}}</label>\r\n      </div>\r\n    </p-toolbar>\r\n\r\n<div>\r\n  <p-accordion class=\"ddr-accordion\">\r\n     <p-accordionTab header=\"Weblogic Thread Pool Stats\" [selected]=\"true\">\r\n     <div>\r\n      <div class=\"ui-g-6\" >\r\n        <div *ngIf=\"showPieChart == true\"><highcharts-chart [Highcharts] = \"highcharts\" [options]=\"options\" (click)=\"changeTableData($event)\"></highcharts-chart></div>\r\n        <div *ngIf=\"showPieChart == false\" style=\"text-align:left;\">No Pie Chart found based on current Filter Settings.</div>\r\n      </div>\r\n     \r\n     <div class=\"ui-g-6\">  \r\n         <div style=\"overflow:auto\"> \r\n          <p-toolbar>\r\n            <div class='ui-toolbar-group-left'>\r\n               <label>{{selectedThreadState}}</label>\r\n             </div>\r\n             <div class='ui-toolbar-group-right'>\r\n                <button pTooltip=\"Reset\" pButton type=\"button\" icon=\"fa-refresh\"  (click)=\"resetTableData()\"></button>\r\n             </div>\r\n            </p-toolbar>\r\n\r\n\r\n            <p-table class=\"scen-table\" [value]=\"weblogicDataInfo\" scrollHeight=\"402px\" [style]=\"{'height':'402px','font-size':'12px'}\" [resizableColumns]=\"true\" reorderableColumns=\"true\"  [rows]=\"15\" [paginator]=\"true\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[15,30,45,60]\" columnResizeMode=\"expand\">\r\n              <ng-template pTemplate=\"header\">\r\n                <tr>\r\n                  <th pResizableColumn>Thread Name</th>\r\n                  <th pResizableColumn>Work Manager</th>\r\n                  <th pResizableColumn>Current Request</th>\r\n                  <th pResizableColumn>Total Request</th>\r\n                  <th pResizableColumn>Thread State</th>\r\n              </tr>\r\n              </ng-template>\r\n              <ng-template pTemplate=\"body\" let-node>\r\n                <tr>\r\n                    <td><a pTooltip=\"{{node.threadName}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node.threadName}}</a></td>\r\n                    <td><a pTooltip=\"{{node.workManager}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node.workManager}}</a></td>\r\n                    <td><a pTooltip=\"{{node.currReq}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node.currReq}}</a></td>\r\n                    <td><a pTooltip=\"{{node.totalReq}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node.totalReq}}</a></td>\r\n                    <td><a pTooltip=\"{{node.threadState}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node.threadState}}</a></td>\r\n                </tr>\r\n            </ng-template>\r\n            </p-table>\r\n\r\n       <!-- <p-dataTable class=\"scen-table\" [value]=\"weblogicDataInfo\" scrollHeight=\"402px\" [style]=\"{'height':'402px','font-size':'12px'}\" resizableColumns=\"true\" reorderableColumns=\"true\"  [rows]=\"15\" [paginator]=\"true\" [pageLinks]=\"3\" [rowsPerPageOptions]=\"[15,30,45,60]\" columnResizeMode=\"expand\">\r\n           <p-column field=\"threadName\" header=\"Thread Name\" [sortable]=\"true\" [style]=\"{'width':'110px','text-align':'left'}\">\r\n             <ng-template let-col let-node=\"rowData\" pTemplate type=\"body\">\r\n\t\t\t    <a pTooltip=\"{{node[col.field]}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node[col.field]}}</a>\r\n\t\t     </ng-template>\r\n           </p-column>\r\n           <p-column field=\"workManager\" header=\"Work Manager\" [sortable]=\"true\" [style]=\"{'width':'70px','text-align':'left'}\">\r\n                <ng-template let-col let-node=\"rowData\" pTemplate type=\"body\">\r\n\t\t\t    <a pTooltip=\"{{node[col.field]}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node[col.field]}}</a>\r\n\t\t     </ng-template>\r\n           </p-column>\r\n           <p-column field=\"currReq\" header=\"Current Request\" [sortable]=\"true\" [style]=\"{'width':'70px','text-align':'left'}\">\r\n                <ng-template let-col let-node=\"rowData\" pTemplate type=\"body\">\r\n\t\t\t    <a pTooltip=\"{{node[col.field]}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node[col.field]}}</a>\r\n\t\t     </ng-template>\r\n           </p-column>\r\n            <p-column field=\"totalReq\" header=\"Total Request\" [sortable]=\"true\" [style]=\"{'width':'70px','text-align':'right'}\">\r\n                <ng-template let-col let-node=\"rowData\" pTemplate type=\"body\">\r\n\t\t\t    <a pTooltip=\"{{node[col.field]}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node[col.field]}}</a>\r\n\t\t     </ng-template>\r\n           </p-column>\r\n           <p-column field=\"threadState\" header=\"Thread State\" [sortable]=\"true\" [style]=\"{'width':'55px','text-align':'left'}\">\r\n                <ng-template let-col let-node=\"rowData\" pTemplate type=\"body\">\r\n\t\t\t    <a pTooltip=\"{{node[col.field]}}\" tooltipPosition=\"top\" tooltipEvent=\"hover\">{{node[col.field]}}</a>\r\n\t\t     </ng-template>\r\n           </p-column>\r\n       </p-dataTable> -->\r\n         </div>\r\n</div>\r\n\r\n<div class=\"section\" *ngIf =\"showDownLoadReportIcon\">\r\n<label style=\"font-size: 12px;padding-left: 6px;\" >Download Reports as: </label>\r\n    <span title=\"Word Report\"><img border='0' width='13' height='14' style='margin-bottom: -3px; cursor:pointer' (click)='downloadReport(\"word\")' src='./images/iconWord.gif'></span>\r\n     <span title=\"Excel Report\"><img border='0' width='13' height='14' style='margin-bottom: -3px; cursor:pointer' (click)='downloadReport(\"excel\")' src='./images/iconExcel.gif'></span>\r\n      <span title=\"PDF Report\"><img border='0' width='13' height='14' style='margin-bottom: -3px; cursor:pointer' (click)='downloadReport(\"pdf\")' src='./images/iconPDF.gif'></span>\r\n</div>\r\n</div>\r\n");

/***/ }),

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/ddr.component.html":
/*!************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/ddr.component.html ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<!-- <div class=\"blockedUI\" *ngIf=\"commonServices.loaderForDdr\">\r\n    <img class=\"loadingIcon\" src=\"./assets/images/loading.gif\" />\r\n</div> -->\r\n<div class=\"vertical-container loader-container overlay\" *ngIf=\"commonServices.spinner == true\">\r\n    <div class=\"container\">\r\n        <div><i class=\"pi pi-spin pi-spinner font-20\"></i><span class=\"font-20\">Loading...</span></div>\r\n    </div>\r\n</div>\r\n<!--Showing time bar for page dump revamped ui-->\r\n<div class=\"global-time-bar\" *ngIf=\"!showBreadcrumb\">\r\n    <app-time-bar></app-time-bar>\r\n</div>\r\n<div *ngIf=\"commonServices.isToLoadSideBar || commonServices.isBackButton\">\r\n    <app-ddr-header-top-nav-bar [currentReport]=\"commonServices.currentReport\"></app-ddr-header-top-nav-bar>\r\n</div>\r\n<div *ngIf=\"commonServices.isToLoadSideBar\">\r\n    <!-- <app-ddr-bread-crumb></app-ddr-bread-crumb> -->\r\n    <p-breadcrumb styleClass=\"pl-30\" [model]=\"breadcrumb.getBreadcrumbMenu() | async\" (onItemClick)=\"breadcrumb.handleBreadcrumbClick($event)\"></p-breadcrumb>\r\n</div>\r\n<div *ngIf=\"!commonServices.isToLoadSideBar && showBreadcrumb\">\r\n    <!-- <app-ddr-bread-crumb></app-ddr-bread-crumb> -->\r\n    <p-breadcrumb styleClass=\"pl-30\"  [model]=\"breadcrumb.getBreadcrumbMenu() | async\" (onItemClick)=\"breadcrumb.handleBreadcrumbClick($event)\"></p-breadcrumb>\r\n</div>\r\n<div *ngIf=\"commonServices.isToLoadSideBar\" class=\"sidenav\">\r\n    <i class=\"icons8 icons8-filter\" title=\"UI Filters\" style=\"height:23px\" type=\"button\" *ngIf=\"commonServices.isToLoadSideBar\" \r\n        (click)=\"openSideNav()\"></i>\r\n</div>\r\n<mat-sidenav-container class=\"sidebarUI-container ddr-side-bar-override\">\r\n    <mat-sidenav class=\"sidebarUI-sidenav\" *ngIf=\"commonServices.isToLoadSideBar\" #navSideBar mode='slide'>\r\n        <app-ddr-side-bar [currentReport]=\"commonServices.currentReport\" (dataChangeDetected)=\"onCloseSidebar()\"></app-ddr-side-bar>\r\n    </mat-sidenav>\r\n    <router-outlet></router-outlet>\r\n</mat-sidenav-container>\r\n<!-- <p-growl life=50000 [value]=\"commonServices.errMsg\"></p-growl> -->\r\n");

/***/ }),

/***/ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js":
/*!****************************************************************************!*\
  !*** ./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js ***!
  \****************************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var isOldIE = function isOldIE() {
  var memo;
  return function memorize() {
    if (typeof memo === 'undefined') {
      // Test for IE <= 9 as proposed by Browserhacks
      // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805
      // Tests for existence of standard globals is to allow style-loader
      // to operate correctly into non-standard environments
      // @see https://github.com/webpack-contrib/style-loader/issues/177
      memo = Boolean(window && document && document.all && !window.atob);
    }

    return memo;
  };
}();

var getTarget = function getTarget() {
  var memo = {};
  return function memorize(target) {
    if (typeof memo[target] === 'undefined') {
      var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself

      if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {
        try {
          // This will throw an exception if access to iframe is blocked
          // due to cross-origin restrictions
          styleTarget = styleTarget.contentDocument.head;
        } catch (e) {
          // istanbul ignore next
          styleTarget = null;
        }
      }

      memo[target] = styleTarget;
    }

    return memo[target];
  };
}();

var stylesInDom = [];

function getIndexByIdentifier(identifier) {
  var result = -1;

  for (var i = 0; i < stylesInDom.length; i++) {
    if (stylesInDom[i].identifier === identifier) {
      result = i;
      break;
    }
  }

  return result;
}

function modulesToDom(list, options) {
  var idCountMap = {};
  var identifiers = [];

  for (var i = 0; i < list.length; i++) {
    var item = list[i];
    var id = options.base ? item[0] + options.base : item[0];
    var count = idCountMap[id] || 0;
    var identifier = "".concat(id, " ").concat(count);
    idCountMap[id] = count + 1;
    var index = getIndexByIdentifier(identifier);
    var obj = {
      css: item[1],
      media: item[2],
      sourceMap: item[3]
    };

    if (index !== -1) {
      stylesInDom[index].references++;
      stylesInDom[index].updater(obj);
    } else {
      stylesInDom.push({
        identifier: identifier,
        updater: addStyle(obj, options),
        references: 1
      });
    }

    identifiers.push(identifier);
  }

  return identifiers;
}

function insertStyleElement(options) {
  var style = document.createElement('style');
  var attributes = options.attributes || {};

  if (typeof attributes.nonce === 'undefined') {
    var nonce =  true ? __webpack_require__.nc : undefined;

    if (nonce) {
      attributes.nonce = nonce;
    }
  }

  Object.keys(attributes).forEach(function (key) {
    style.setAttribute(key, attributes[key]);
  });

  if (typeof options.insert === 'function') {
    options.insert(style);
  } else {
    var target = getTarget(options.insert || 'head');

    if (!target) {
      throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");
    }

    target.appendChild(style);
  }

  return style;
}

function removeStyleElement(style) {
  // istanbul ignore if
  if (style.parentNode === null) {
    return false;
  }

  style.parentNode.removeChild(style);
}
/* istanbul ignore next  */


var replaceText = function replaceText() {
  var textStore = [];
  return function replace(index, replacement) {
    textStore[index] = replacement;
    return textStore.filter(Boolean).join('\n');
  };
}();

function applyToSingletonTag(style, index, remove, obj) {
  var css = remove ? '' : obj.media ? "@media ".concat(obj.media, " {").concat(obj.css, "}") : obj.css; // For old IE

  /* istanbul ignore if  */

  if (style.styleSheet) {
    style.styleSheet.cssText = replaceText(index, css);
  } else {
    var cssNode = document.createTextNode(css);
    var childNodes = style.childNodes;

    if (childNodes[index]) {
      style.removeChild(childNodes[index]);
    }

    if (childNodes.length) {
      style.insertBefore(cssNode, childNodes[index]);
    } else {
      style.appendChild(cssNode);
    }
  }
}

function applyToTag(style, options, obj) {
  var css = obj.css;
  var media = obj.media;
  var sourceMap = obj.sourceMap;

  if (media) {
    style.setAttribute('media', media);
  } else {
    style.removeAttribute('media');
  }

  if (sourceMap && btoa) {
    css += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), " */");
  } // For old IE

  /* istanbul ignore if  */


  if (style.styleSheet) {
    style.styleSheet.cssText = css;
  } else {
    while (style.firstChild) {
      style.removeChild(style.firstChild);
    }

    style.appendChild(document.createTextNode(css));
  }
}

var singleton = null;
var singletonCounter = 0;

function addStyle(obj, options) {
  var style;
  var update;
  var remove;

  if (options.singleton) {
    var styleIndex = singletonCounter++;
    style = singleton || (singleton = insertStyleElement(options));
    update = applyToSingletonTag.bind(null, style, styleIndex, false);
    remove = applyToSingletonTag.bind(null, style, styleIndex, true);
  } else {
    style = insertStyleElement(options);
    update = applyToTag.bind(null, style, options);

    remove = function remove() {
      removeStyleElement(style);
    };
  }

  update(obj);
  return function updateStyle(newObj) {
    if (newObj) {
      if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap) {
        return;
      }

      update(obj = newObj);
    } else {
      remove();
    }
  };
}

module.exports = function (list, options) {
  options = options || {}; // Force single-tag solution on IE6-9, which has a hard limit on the # of <style>
  // tags it will allow on a page

  if (!options.singleton && typeof options.singleton !== 'boolean') {
    options.singleton = isOldIE();
  }

  list = list || [];
  var lastIdentifiers = modulesToDom(list, options);
  return function update(newList) {
    newList = newList || [];

    if (Object.prototype.toString.call(newList) !== '[object Array]') {
      return;
    }

    for (var i = 0; i < lastIdentifiers.length; i++) {
      var identifier = lastIdentifiers[i];
      var index = getIndexByIdentifier(identifier);
      stylesInDom[index].references--;
    }

    var newLastIdentifiers = modulesToDom(newList, options);

    for (var _i = 0; _i < lastIdentifiers.length; _i++) {
      var _identifier = lastIdentifiers[_i];

      var _index = getIndexByIdentifier(_identifier);

      if (stylesInDom[_index].references === 0) {
        stylesInDom[_index].updater();

        stylesInDom.splice(_index, 1);
      }
    }

    lastIdentifiers = newLastIdentifiers;
  };
};

/***/ }),

/***/ "./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.css":
/*!****************************************************************************!*\
  !*** ./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.css ***!
  \****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".break-text{ cursor: pointer;  color: blue;  white-space: nowrap; width: 80px; display: block;}\n\n\n\n.ui-dialog-footer {\n    display: flex;\n    justify-content: space-between;\n  }\n\n\n\n.left-content {\n    flex-grow: 1;\n    text-align: left;\n  }\n\n\n\n.right-content {\n    text-align: right;\n  }\n  \n  \n  \n");

/***/ }),

/***/ "./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.ts":
/*!***************************************************************************!*\
  !*** ./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.ts ***!
  \***************************************************************************/
/*! exports provided: AggIpInfoComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AggIpInfoComponent", function() { return AggIpInfoComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! moment-timezone */ "./node_modules/moment-timezone/index.js");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");










let AggIpInfoComponent = class AggIpInfoComponent {
    constructor(commonService, _router, _ddrData, breadcrumbService, messageService, elasticSearchService) {
        this.commonService = commonService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.messageService = messageService;
        this.elasticSearchService = elasticSearchService;
        this.showWarning = false;
        this.calloutCount = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"](); //emit the callout-count to parent component to show count on accordion header...
        this.indIPInfo = []; //Individual IP popup data
        this.showPagination = false; //flag to show table pagination..
        this.showPaginationIP = false; //flag to show Ind IP table pagination..
        this.showIndIPInfo = false; //flag to toggle Ind IP Dialog...
        this.isIPByRespTime = false; //flag to toggle Integration Point By Response Time
        this.responseTime = '';
        this.ipName = ""; //shows the selected IP Name on Ind IP Dialog Header...
        this.otelMode = this._ddrData.otelMode;
    }
    ngOnInit() {
        this.initializeColsForAggreate();
        this.tooltipText = "Copy Query";
    }
    ngOnChanges() {
        this.convertIntoAggIPInfo();
        this.selectedRowInfo = {};
        this.fullQueryName = '';
    }
    onRowSelectEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.showRowInfo(event.cavEventExt.row);
        }
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.openIndIpInfoPopUp(event.cavEventExt.row);
        }
        if (((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.action) === "FPByIP") {
            me.openFPByIntegrationReport(event.cavEventExt.row, 'FPByID');
        }
        if (((_f = (_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.actionConfig) === null || _f === void 0 ? void 0 : _f.action) === "FPByResTime") {
            me.isIPByResp(event.cavEventExt.row);
        }
    }
    initializeColsForAggreate() {
        if (!this.otelMode) {
            /**Agg Table Header */
            this.relativePathForAGG = "ddr/agg-ip-info/agg-ip-detail.json";
            /**Ind-Popup */
            this.relativePathForINDPopup = "ddr/agg-ip-info/ind-popup.json";
        }
        else {
            this.relativePathForAGG = "ddr/agg-ip-info/agg-ip-detail-elasticSearch.json";
        }
        if ((this.commonService.showIPSummary == false || this.commonService.hsFlag == false) && this._ddrData.splitViewFlag == false && this._ddrData.isCompFlowpath == false) {
            this.relativePathForAGG = "ddr/agg-ip-info/agg-ip-info-agg-detail.json";
        }
    }
    convertIntoAggIPInfo() {
        const aggIPArr = [];
        let totalCalloutCount = 0;
        if (this.aggIpInfo) {
            let backendsArr = Object.keys(this.aggIpInfo);
            backendsArr.forEach((val, index) => {
                if (this.aggIpInfo[val]["backendID"] != -1) {
                    let dur = this.aggIpInfo[val]['duration'];
                    let splicedValue = dur.shift();
                    let arr = [];
                    arr[0] = splicedValue;
                    this.aggIpInfo[val]['duration'] = arr.concat(this.aggIpInfo[val]['duration']); //changes for bug:-65886
                    let count = Object.keys(this.aggIpInfo[val]['agg_count']).map((item) => { return this.aggIpInfo[val]['agg_count'][item]; });
                    let max = this.getMax(dur);
                    let min = this.getMin(dur);
                    aggIPArr.push({
                        renamebackendIPname: this.renamebackendNameMap[this.aggIpInfo[val]["backendID"]],
                        actualbackendIPname: this.getActualBackendMap(this.actualBackendNameMap[this.aggIpInfo[val]["backendID"]]),
                        backendType: this.commonService.BackendTypeName(this.aggIpInfo[val]["backendType"]),
                        backendID: this.aggIpInfo[val]["backendID"],
                        totalDuration: (Number)(this.aggIpInfo[val]['duration'][0]),
                        avgDuration: (Number)(this.aggIpInfo[val]['duration'][0] / (this.aggIpInfo[val]['countIndex'] + this.aggIpInfo[val]['errorCountIndex'])),
                        maxDuration: max,
                        minDuration: min,
                        count: (Number)(this.aggIpInfo[val]['countIndex'] + this.aggIpInfo[val]['errorCountIndex']),
                        mincount: Math.min(...count),
                        maxcount: Math.max(...count),
                        errorCount: (Number)(this.aggIpInfo[val]['errorCountIndex']),
                        totalNWDelay: this.calulateTotalNetworkDelay(this.aggIpInfo[val]['senderNWDelay'][0], this.aggIpInfo[val]['receiveNWDelay'][0]),
                        avgNWDelay: this.calAvgNWDelay(this.aggIpInfo[val]['senderNWDelay'][0], this.aggIpInfo[val]['receiveNWDelay'][0], (this.aggIpInfo[val]['countIndex'] + this.aggIpInfo[val]['errorCountIndex']))
                    });
                    totalCalloutCount += (this.aggIpInfo[val]['countIndex'] + this.aggIpInfo[val]['errorCountIndex']);
                }
            });
        }
        try {
            this.calloutCount.emit(totalCalloutCount);
        }
        catch (e) {
            console.error("Error in emmitting calloutCount ~ ", e);
        }
        this.actualAggIPInfo = aggIPArr;
        if (this.aggIndInfOtel) {
            this.actualAggIPInfo = this.aggIndInfOtel;
        }
        this.showPagination = this.actualAggIPInfo.length > 10;
    }
    getMin(dur) {
        let len = dur.length;
        let min = Infinity;
        while (len--) {
            min = dur[len] < min ? dur[len] : min;
        }
        return min;
    }
    getMax(dur) {
        let len = dur.length;
        let max = -Infinity;
        while (len--) {
            max = dur[len] > max ? dur[len] : max;
        }
        return max;
    }
    calAvgNWDelay(senderNwDelay, receNWDelay, count) {
        return count !== 0 ? (Number)((senderNwDelay + receNWDelay) / count) : 0;
    }
    calulateTotalNetworkDelay(senderNwDelay, receNWDelay) {
        return (Number)((senderNwDelay + receNWDelay));
    }
    openIndIpInfoPopUp(node) {
        this.ipName = "[Integration Point = " + node.renamebackendIPname + "]";
        if (this.otelMode) {
            //creates payload for restCall on elasticSearch
            const payload = {
                "testRun": this.fpRowData.testRun,
                "tierName": this.fpRowData.tierName,
                "serverName": this.fpRowData.serverName,
                "appName": this.fpRowData.appName,
                "strStartTime": Math.floor(this.fpRowData.startTimeInMs),
                "strEndTime": (Math.floor(this.fpRowData.startTimeInMs) + Math.ceil(this.fpRowData.selfResponseTime) + 1000),
                "traceId": this.fpRowData.TraceId,
                "backendIPname": node.renamebackendIPname
            };
            const resFields = [
                "trace_id",
                "span_id",
                "name",
                "@timestamp",
                "duration",
                "attributes.cav.*",
                "attributes.http.*",
                "attributes.db.*",
                "attributes.url.full"
            ];
            const ipIndInfoESQuery = this.elasticSearchService.buildElasticSearchQuery(payload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].IP_CALLOUT_DETAILS);
            this.elasticSearchService.search(ipIndInfoESQuery).subscribe(res => {
                var _a, _b;
                this.elasticSearchData = res;
                const indCalloutDataArray = this.processIndElasticInfo(this.elasticSearchData, node["ipType"]);
                this.indIPInfo = indCalloutDataArray;
                this.fullQueryName = ((_a = indCalloutDataArray[0]) === null || _a === void 0 ? void 0 : _a.queries) || ((_b = indCalloutDataArray[0]) === null || _b === void 0 ? void 0 : _b.url) || "-";
                this.showIndIPInfo = true;
                if (window['logLevel'] > 1) {
                    console.log("Data from process elastic", indCalloutDataArray);
                    console.log('Search results from Elasticsearch:', res);
                }
            }, error => {
                console.error('Error in getting data from Elasticsearch:', error);
                this.indIPInfo = [];
            });
        }
        else {
            let INDRawIPInfo = this.aggIpInfo[node.backendID];
            this.assignINDIPData(INDRawIPInfo);
        }
    }
    //process's and fills the data received from elasticSearch
    processIndElasticInfo(elasticData, ipType) {
        var _a, _b, _c;
        const elasticInd = elasticData.hits.hits;
        let calloutType;
        let queries;
        let startTime;
        let endTime;
        let url;
        let spanName;
        const result = [];
        if (ipType.toLowerCase() == "db") {
            this.relativePathForINDPopup = "ddr/agg-ip-info/ind-popup-elasticSearch.json";
            for (const indData of elasticInd) {
                spanName = indData._source.name;
                calloutType = (_a = indData._source.attributes["cav.IP"]) !== null && _a !== void 0 ? _a : indData._source.name;
                queries = (_b = indData._source.attributes["db.statement"]) !== null && _b !== void 0 ? _b : spanName;
                startTime = Math.floor(indData._source["@timestamp"]);
                endTime = (indData._source.duration) / 1000000;
                result.push({
                    callOutType: calloutType,
                    queries: queries,
                    startTime: startTime,
                    endTime: endTime
                });
            }
            return result;
        }
        else if (ipType.toLowerCase() == "http") {
            this.relativePathForINDPopup = "ddr/agg-ip-info/ind-popup-http-elasticSearch.json";
            for (const indData of elasticInd) {
                calloutType = (_c = indData._source.attributes["cav.IP"]) !== null && _c !== void 0 ? _c : indData._source.name;
                startTime = Math.floor(indData._source["@timestamp"]);
                endTime = (indData._source.duration) / 1000000;
                url = indData._source.attributes["url.full"] || indData._source.attributes["http.url"] || indData._source.attributes["http.request.url"];
                result.push({
                    callOutType: calloutType,
                    url: url,
                    startTime: startTime,
                    endTime: endTime
                });
            }
            return result;
        }
    }
    assignINDIPData(INDRawIPInfo) {
        const ipName = this.ipName.substring(20, this.ipName.indexOf(']'));
        let backendType = '';
        let indIPInfo = [];
        INDRawIPInfo['callOutType'].forEach((val, index) => {
            if (val != 'a') { //Filtering callout type of a,  due to BugId -142325 
                var obj = {
                    queries: this.commonService.getBackendSubType(INDRawIPInfo['backendSubType'][index], this.backendSubTypeNameMap),
                    callOutType: this.getCallOutType(val, INDRawIPInfo['backendType']) + '(' + ipName + ')',
                    //startTime:this.commonService.formatter(INDRawIPInfo['startTime'][index+1]),
                    startTime: INDRawIPInfo['startTime'][index + 1],
                    endTime: this.commonService.formatter(INDRawIPInfo['duration'][index + 1]),
                    sourceNW: this.commonService.formatterFixed(INDRawIPInfo['senderNWDelay'][index + 1]),
                    destNW: this.commonService.formatterFixed(INDRawIPInfo['receiveNWDelay'][index + 1])
                };
                if (index === 0) {
                    this.selectedRowInfo = obj;
                    this.fullQueryName = obj.queries;
                }
                indIPInfo.push(obj);
                backendType = this.getCallOutType(val, INDRawIPInfo['backendType']);
            }
        });
        if (backendType === "HTTP") {
            this.relativePathForINDPopup = "ddr/agg-ip-info/ind-popup-http.json";
        }
        this.indIPInfo = indIPInfo;
        this.showPaginationIP = this.indIPInfo.length > 10;
        this.showIndIPInfo = true;
    }
    showInfoMessage() {
        const message = 'Query copied!';
        this.messageService.showInfo(message);
        setTimeout(() => {
            this.messageService.clear();
        }, 5000); // 5000 milliseconds = 5 seconds
    }
    copytext(val) {
        const text = val;
        const tempInput = document.createElement('textarea');
        tempInput.value = text;
        document.body.appendChild(tempInput);
        tempInput.select();
        document.execCommand('copy');
        tempInput.remove();
        this.showInfoMessage();
    }
    getCallOutType(callOutType, backendType) {
        if (callOutType == 'a')
            return "Async Init";
        else if (callOutType == 'A')
            return "Async Call";
        else if (callOutType == 'x')
            return "Asynchronous Thread Call";
        else if (callOutType == "T" && backendType == 24)
            return "LDAP";
        else if (callOutType == "T" && backendType == 26)
            return "SOCKET";
        else if (callOutType == "T" && (backendType == 2 || backendType == 6 || backendType == 9 || backendType == 10 || backendType == 15 || backendType == 16 || backendType == 19 || backendType == 25))
            return "DATABASE";
        else if (callOutType == 'T')
            return "HTTP";
        else if (callOutType == 'E')
            return "CallOut Error";
        else
            return "OTHERS";
    }
    getActualBackendMap(actualbackendMap) {
        if (actualbackendMap)
            return actualbackendMap.replace(/&#46;/g, '.');
        return actualbackendMap;
    }
    openFPByIntegrationReport(rowData, flag) {
        try {
            if (flag == 'FPByID' || this.responseTime) {
                this.urlParam = this.commonService.getData();
                const fpdata = {};
                fpdata["tierId"] = this.urlParam.tierId;
                fpdata["serverId"] = this.urlParam.serverid;
                fpdata["appId"] = this.urlParam.appid;
                fpdata["tierName"] = this.urlParam.tierName;
                fpdata["serverName"] = this.urlParam.serverName;
                fpdata["appName"] = this.urlParam.appName;
                fpdata["backendId"] = rowData.backendID;
                fpdata['minresTimeOfBackend'] = rowData.totalDuration;
                if (flag === 'FPByResTime') {
                    fpdata['maxresTimeOfBackend'] = this.responseTime;
                }
                fpdata['avgresTimeOfBackend'] = rowData.avgResponseTime;
                fpdata["startTime"] = this.urlParam.startTime;
                fpdata['endTime'] = this.urlParam.endTime;
                fpdata['backendName'] = rowData.actualbackendIPname;
                fpdata['urlNameIP'] = this.urlNameIP;
                this._ddrData.urlIndex = this.urlIndexIP;
                this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].IPSUMMARY;
                this._ddrData.IPByFPFlag = true;
                this._ddrData.FromexpFlag = 'false';
                this.commonService.isFilterFromSideBar = false;
                this.commonService.IPByFPData = fpdata;
                if (this._router.url.indexOf("/home/ddrCopyLink/") != -1)
                    this._router.navigate(['/home/ddrCopyLink/flowpath']);
                else if (this._router.url.indexOf("/home/ED-ddr") != -1)
                    this._router.navigate(['/home/ED-ddr/flowpath']);
                else
                    this._router.navigate(['/ddr/flowpath']);
            }
            else {
                this.commonService.showError("Response time cannot be empty");
            }
        }
        catch (error) {
            console.error("error   ", error);
        }
    }
    showRowInfo(rowData) {
        if (rowData.queries || rowData.url) {
            this.fullQueryName = rowData.queries || rowData.url;
        }
    }
    /* Validating Number input (allowing only numeric characters to be entered) */
    validateQty(event) {
        if (event.charCode > 31 && (event.charCode < 48 || event.charCode > 57))
            return false;
        else
            return true;
    }
    isIPByResp(rowData) {
        this.isIPByRespTime = true;
        this.resData = rowData;
    }
};
AggIpInfoComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_8__["CavMessageService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_9__["ElasticsearchQueryService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('aggIndInfoOtel')
], AggIpInfoComponent.prototype, "aggIndInfOtel", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('aggIpInfo')
], AggIpInfoComponent.prototype, "aggIpInfo", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('renamebackendNameMap')
], AggIpInfoComponent.prototype, "renamebackendNameMap", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('actualBackendNameMap')
], AggIpInfoComponent.prototype, "actualBackendNameMap", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('backendSubTypeNameMap')
], AggIpInfoComponent.prototype, "backendSubTypeNameMap", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('urlParam')
], AggIpInfoComponent.prototype, "urlParam", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('filterCriteriaagg')
], AggIpInfoComponent.prototype, "filterCriteriaagg", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('showWarning')
], AggIpInfoComponent.prototype, "showWarning", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('maxFlowPath')
], AggIpInfoComponent.prototype, "maxFlowPath", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('urlNameIP')
], AggIpInfoComponent.prototype, "urlNameIP", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('urlIndexIP')
], AggIpInfoComponent.prototype, "urlIndexIP", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('fpRowData')
], AggIpInfoComponent.prototype, "fpRowData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"])()
], AggIpInfoComponent.prototype, "calloutCount", void 0);
AggIpInfoComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-agg-ip-info',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./agg-ip-info.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./agg-ip-info.component.css */ "./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.css")).default]
    })
], AggIpInfoComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/db-group-by/db-group-by.component.scss":
/*!*****************************************************************************!*\
  !*** ./src/app/pages/ddr/components/db-group-by/db-group-by.component.scss ***!
  \*****************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/db-group-by/db-group-by.component.ts":
/*!***************************************************************************!*\
  !*** ./src/app/pages/ddr/components/db-group-by/db-group-by.component.ts ***!
  \***************************************************************************/
/*! exports provided: DbGroupByComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DbGroupByComponent", function() { return DbGroupByComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../services/ddr-message.service */ "./src/app/pages/ddr/services/ddr-message.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");












let DbGroupByComponent = class DbGroupByComponent {
    constructor(commonService, _ddrData, _router, messageService, sessionService, ndDdrHttpService, ddrRequest, breadcrumb) {
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this._router = _router;
        this.messageService = messageService;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.ddrRequest = ddrRequest;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_7__; // Highcharts instance for rendering charts
        this.limit = 50; // Limit for pagination
        this.offset = 0; // Offset for pagination
        this.isFilterFromSideBar = false; // To check if filter is applied from sidebar
        this.showDownloadOption = true; // To show download option
        this.showChartForBT = true; // To show pie chart for BT
        this.showChartForRespTime = true; // To show pie chart for response time
        this.showAllOption = false; // To showAll option
        //Filter variables
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.filterGroupByStr = '';
        this.filterOrderByStr = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        this.completeGroupBy = '';
        this.completeOrderBy = '';
        //Download filter variables
        this.downloadHeaderInfo = '';
        this.isEnabledColumnFilter = false;
        this.toggleFilterTitle = 'Show Column Filters'; //Toggle Filter Tooltip
        this.protocol = '//';
        this.host = '';
        this.port = '';
        this.showDCMenu = false;
        this.dcProtocol = '';
        this.tierName = "NA";
        this.showPagination = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.msgs = [];
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.breadcrumb = breadcrumb;
    }
    ngOnInit() {
        if (this._ddrData.tagData) {
            this.tagInfo = this._ddrData.createGtagsIntoStr(this._ddrData.tagData);
        }
        this.first.first = 0;
        this.rows.rows = 50;
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.commonService.isToLoadSideBar = true;
        this.commonService.currentReport = "DBGroupBy";
        this.commonService.enableQueryCaching = this._ddrData.enableQueryCaching;
        this.loading = true;
        this.headerName = "DB Request";
        this.breadcrumb.add({ label: 'DB Group By BT', routerLink: '/ddr/dbGroupBy' });
        this.id = this.commonService.getData();
        this.randomNumber();
        if ((this._router.url.indexOf('?') != -1) && (this._router.url.indexOf('/home/ED-ddr/dbGroupBy') != -1)) {
            let queryParams1 = location.href.substring(location.href.indexOf("?") + 1, location.href.length);
            this.id = JSON.parse('{"' + decodeURI(queryParams1).replace(/"/g, '\\"').replace(/&/g, '","').replace(/=/g, '":"') + '"}');
            sessionStorage.setItem("hostDcName", location.host);
            this.commonService.removeFromStorage();
            this.commonService.setInStorage = this.id;
            this.commonService.dbDataFromFPInED = this.id;
            this.commonService.dcNameList = this.id.dcNameList;
            this.commonService.selectedDC = this.id.dcName;
            this.commonService.isAllCase = this.id.isAll;
            this.commonService.tierNameList = this.id.tierNameList;
            if (this.id.dcNameList != null && this.id.dcNameList != '' && this.id.dcNameList != undefined && this.id.dcNameList != 'undefined') {
                sessionStorage.setItem("dcNameList", this.id.dcNameList);
                sessionStorage.setItem("tierNameList", this.id.tierNameList);
                sessionStorage.setItem("isAllCase", this.id.isAll);
            }
        }
        if (this._router.url.indexOf('/home/ED-ddr/dbGroupBy') != -1 && this.commonService.dbFilters['fromDBCallByBT'] == 'true')
            this.id = this.commonService.dbDataFromFPInED;
        if (this.id.enableQueryCaching) {
            this.commonService.enableQueryCaching = this.id.enableQueryCaching;
        }
        if (this.id.strStartTime == undefined && this.id.strEndTime == undefined) {
            this.startTimeInMs = this.id.startTime;
            this.endTimeInMs = this.id.endTime;
        }
        else {
            this.startTimeInMs = this.id.strStartTime;
            this.endTimeInMs = this.id.strEndTime;
        }
        this.sideBarDbGroupBy = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "DBGroupBy") {
                this.commonService.isFilterFromSideBar = true;
                this.headerName = "DB Request";
                this.loading = true;
                this.limit = 50;
                this.offset = 0;
                this.getQueryData();
            }
        });
        this.getQueryData();
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d;
        const me = this;
        console.log('Event: ', event);
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.openQueryCount(event.cavEventExt.row);
        }
        else if (((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.action) === "showalldata") {
            me.showAllData();
        }
    }
    createDynamicColumns() {
        let dbParam = this.commonService.dbGroupByFilters;
        this.colsForDbGroupByBT = [];
        this.colsForDbGroupByBT[0] = {
            cols: []
        };
        const columnMapping = {
            'url': { label: 'Business Transaction', key: 'urlName' },
            'tier': { label: 'Tier', key: 'tierName' },
            'server': { label: 'Server', key: 'serverName' },
            'app': { label: 'Instance', key: 'appName' },
            'btcategory': { label: 'BT Category', key: 'BTCategory' },
            'page': { label: 'Page', key: 'page' },
            'session': { label: 'Session', key: 'session' },
            'transaction': { label: 'Transaction', key: 'transaction' }
        };
        // Create a new array to store the columns that should be kept
        let newColumns = [];
        // Add columns based on strGroup
        for (let groupKey in columnMapping) {
            if (dbParam['strGroup'].indexOf(groupKey) !== -1) {
                newColumns.push({
                    label: columnMapping[groupKey].label,
                    selected: true,
                    key: columnMapping[groupKey].key,
                    width: '80px',
                    type: 0
                });
            }
        }
        // Always include Flowpath Count column
        newColumns.push({
            label: 'Query Count',
            selected: true,
            key: 'count',
            width: '80px',
            click: true,
            type: 1
        });
        // Update the columns array
        this.colsForDbGroupByBT[0].cols = newColumns;
        let tableConfig = {
            config: {
                globalFilter: true,
                toggleFilter: true
            },
            tableAction: []
        };
        this.tableConfig = tableConfig;
    }
    openQueryCount(nodeInfo) {
        this._ddrData.queryCountToDBFlag = true;
        this.commonService.previousReport = 'DB Report';
        this.commonService.queryCountToDB = JSON.parse(JSON.stringify(nodeInfo));
        this.commonService.queryCountToDB['urlIndex'] = 'NA'; // because from nodeinfo we are copying urlIndex to queryCountToDB and in queryCountToDB we make changes in urlIdx
        this.commonService.queryCountToDB['testRun'] = this.id.testRun;
        this.commonService.queryCountToDB['product'] = this.id.product;
        this.commonService.queryCountToDB['urlIdx'] = nodeInfo.urlIndex;
        this.commonService.queryCountToDB['strStartTime'] = this.commonService.dbGroupByFilters['strStartTime'];
        this.commonService.queryCountToDB['tierName'] = this.commonService.dbGroupByFilters['tierName'];
        this.commonService.queryCountToDB['serverName'] = this.commonService.dbGroupByFilters['serverName'];
        this.commonService.queryCountToDB['appName'] = this.commonService.dbGroupByFilters['appName'];
        this.commonService.queryCountToDB['strEndTime'] = this.commonService.dbGroupByFilters['strEndTime'];
        this.commonService.queryCountToDB['sqlIndex'] = "NA";
        this.commonService.queryCountToDB['strGroup'] = "NA";
        this.commonService.queryCountToDB['strOrder'] = "query";
        if (this.commonService.isValidParameter(nodeInfo.BTCategory)) {
            this.commonService.queryCountToDB['btcategoryId'] = this.commonService.getBTCategoryID(nodeInfo.BTCategory);
        }
        this.commonService.queryCountToDB['fromDBCallByBT'] = 'true';
        console.log(" this.commonService.dbGroupByFilters--", this.commonService.dbGroupByFilters);
        if (this._router.url.indexOf('/home/ddrCopyLink') != -1) {
            this._router.navigate(['/home/ddrCopyLink/dbReport']);
        }
        else {
            this._router.navigate(['/ddr/dbReport']);
        }
    }
    getQueryData() {
        let urlParam;
        let url = "";
        if (this.commonService.enableQueryCaching == 1) {
            url += 'cacheId=' + this.id.testRun + "&testRun=" + this.id.testRun;
        }
        else {
            url += "testRun=" + this.id.testRun;
        }
        let btCatId = this.id.btCategory;
        if (this.id.btCategory == null) {
            btCatId = undefined;
        }
        if (this.commonService.isFilterFromSideBar && Object.keys(this.commonService.dbGroupByFilters).length != 0) {
            let dbParam = this.commonService.dbGroupByFilters;
            if (this.commonService.isValidParamInObj(dbParam, 'ndeProtocol') && this.commonService.isValidParamInObj(dbParam, 'pubicIP') && this.commonService.isValidParamInObj(dbParam, 'publicPort') && this.commonService.isValidParamInObj(dbParam, 'ndeTestRun')) {
                if (this.commonService.enableQueryCaching == 1) {
                    url = 'cacheId=' + dbParam['ndeTestRun'] + '&testRun=' + dbParam['ndeTestRun'];
                }
                else {
                    url = 'testRun=' + dbParam['ndeTestRun'];
                }
            }
            urlParam = this.commonService.makeParamStringFromObj(dbParam);
        }
        else {
            urlParam =
                "&tierName=" + this.id.tierName +
                    "&serverName=" + this.id.serverName +
                    "&appName=" + this.id.appName +
                    "&tierId=" + this.id.tierid +
                    "&serverId=" + this.id.serverid +
                    "&appId=" + this.id.appid +
                    "&strStartTime=" + this.startTimeInMs +
                    "&strEndTime=" + this.endTimeInMs +
                    "&statusCode=-2" +
                    "&strGroup=" + "url" +
                    "&object=6" +
                    "&urlIndex=" + this.id.urlIndex +
                    "&btcategoryId=" + btCatId +
                    "&urlName=" + this.id.urlName +
                    "&groupByFC=BT" +
                    "&backend_ID=" + this._ddrData.backendId;
            let urlAjaxParamObject = this.commonService.makeObjectFromUrlParam(urlParam);
            urlAjaxParamObject['tags'] = this.tagInfo;
            this.commonService.dbGroupByFilters = urlAjaxParamObject;
            if (this.tagInfo && this.tagInfo.length != 0) {
                urlParam += "&tags=" + this.tagInfo;
            }
            setTimeout(() => {
                this.messageService.sendMessage(this.commonService.dbGroupByFilters);
            }, 2000);
        }
        this.ajaxUrl = url + urlParam;
        let finalUrl = this.ajaxUrl + "&limit=" + this.limit + "&offset=" + this.offset + "&showCount=false" + "&queryId=" + this.queryId;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        return this.ndDdrHttpService.getDBReportData(finalUrl).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__["DBReportLoadedState"]) {
                this.assignDataValues(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.commonService.showError(error);
            this.loading = false;
        });
    }
    assignDataValues(res) {
        this.commonService.isFilterFromSideBar = false;
        this.isCancelQuerydata = true;
        this.dbQueryData = res.data;
        this.loading = false;
        this.wholeData = this.dbQueryData;
        if (this.dbQueryData.length == 0) {
            this.limit = 0;
            this.offset = 0;
        }
        this.dbQueryData.forEach((val, index) => {
            val.BTCategory = this.commonService.getBTCategoryName(val.BTCategory);
        });
        this.getQueryDataCount();
        this.createDynamicColumns();
        this.createPieChart(this.dbQueryData);
        this.totalQueryCount = "DB Stats [ Total Query Count : " + res.queryCount + "]";
        this.commonService.dbGroupByFilters['startTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.startTime), "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
        this.commonService.dbGroupByFilters['endTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.endTime), "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
        this.showHeaderInfo();
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
    }
    getQueryDataCount() {
        let finalUrl = this.ajaxUrl + "&showCount=true" + "&queryId=" + this.queryId;
        this.ndDdrHttpService.getDBReportCountData(finalUrl).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__["DBReportCountLoadedState"]) {
                this.assignCountValues(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.commonService.showError(error);
            this.loading = false;
        });
    }
    assignCountValues(res) {
        this.totalCount = res.totalCount;
        if (this.totalCount > 50) { //If data is less then 50 then no pagination .
            this.showPagination = true;
        }
        else {
            this.showPagination = false;
        }
        if (this.totalCount > 0 && this.limit > this.totalCount)
            this.limit = Number(this.totalCount);
    }
    paginate(event) {
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        if (this.limit > this.totalCount) {
            this.limit = Number(this.totalCount);
        }
        if ((this.limit + this.offset) > this.totalCount) {
            this.limit = Number(this.totalCount) - Number(this.offset);
        }
        this.commonService.isFilterFromSideBar = true;
        this.getQueryData();
    }
    createPieChart(chartData) {
        let dataArr = [];
        let dataArrForRespTime = [];
        let dbParam = this.commonService.dbGroupByFilters;
        let groupChart = '';
        this.pieData = chartData;
        let avgRespTime = '';
        let count;
        let pieText = " DB Queries By Count";
        let pieText2 = " DB Queries By Response Time";
        if (this.pieData.length == 0) {
            this.showChartForBT = false;
            this.showChartForRespTime = false;
        }
        else {
            this.showChartForBT = true;
            this.showChartForRespTime = true;
        }
        for (var i = 0; i < this.pieData.length; i++) {
            groupChart = '';
            if (dbParam['strGroup'].indexOf('url') != -1)
                groupChart = this.pieData[i]["urlName"] + ",";
            if (dbParam['strGroup'].indexOf('tier') != -1) {
                groupChart += this.pieData[i]["tierName"] + ",";
            }
            if (dbParam['strGroup'].indexOf('server') != -1) {
                groupChart += this.pieData[i]["serverName"] + ",";
            }
            if (dbParam['strGroup'].indexOf('app') != -1) {
                groupChart += this.pieData[i]["appName"] + ",";
            }
            if (dbParam['strGroup'].indexOf('btcategory') != -1) {
                groupChart += this.pieData[i]["BTCategory"] + ",";
            }
            if (dbParam['strGroup'].indexOf('page') != -1)
                groupChart += this.pieData[i]["page"] + ",";
            if (dbParam['strGroup'].indexOf('session') != -1)
                groupChart += this.pieData[i]["session"] + ",";
            if (dbParam['strGroup'].indexOf('transaction') != -1)
                groupChart += this.pieData[i]["transaction"];
            if (groupChart.endsWith(','))
                groupChart = groupChart.substring(0, groupChart.length - 1);
            count = this.pieData[i]["count"];
            avgRespTime = this.pieData[i]["avg"];
            count = count.replace(/\,/g, '');
            dataArr.push({ "name": groupChart, "y": Number(count) });
            dataArrForRespTime.push({ "name": groupChart, "y": Number(avgRespTime) });
        }
        this.btOptions = {
            chart: {
                type: "pie"
            },
            credits: {
                enabled: false
            },
            exporting: {
                enabled: false
            },
            title: {
                text: pieText,
                style: { 'fontSize': '13px' }
            },
            legend: {
                itemWidth: 600
            },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>, Count: <b> {point.y}</b>'
            },
            plotOptions: {
                pie: {
                    allowPointSelect: true,
                    cursor: 'pointer',
                    dataLabels: {
                        enabled: false
                    },
                    showInLegend: true
                }
            },
            series: [
                {
                    name: "Percentage",
                    data: dataArr,
                    enableMouseTracking: true
                }
            ]
        };
        this.respOptions = {
            chart: {
                type: "pie"
            },
            credits: {
                enabled: false
            },
            exporting: {
                enabled: false
            },
            title: {
                text: pieText2,
                style: { 'fontSize': '13px' }
            },
            legend: {
                itemWidth: 600
            },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>, Response Time: <b> {point.y}</b>'
            },
            plotOptions: {
                pie: {
                    allowPointSelect: true,
                    cursor: 'pointer',
                    dataLabels: {
                        enabled: false
                    },
                    showInLegend: true
                }
            },
            series: [
                {
                    name: "Percentage",
                    data: dataArrForRespTime,
                    enableMouseTracking: true
                }
            ]
        };
    }
    clickHandlerBTCount(event) {
        this.headerName = "DB Request ";
        this.showAllOption = true;
        let tableConfig = {
            config: {
                globalFilter: true,
                toggleFilter: true
            },
            tableAction: [
                {
                    "iconType": "icon",
                    "iconClass": "las-undo-alt-solid",
                    "toolTip": "Show All data",
                    "action": "showalldata",
                }
            ]
        };
        this.tableConfig = tableConfig;
        let filteredData = [];
        for (let k = 0; k < this.pieData.length; k++) {
            let count = this.pieData[k]['count'];
            count = count.replace(/\,/g, '');
            if (event.point.y == count) {
                filteredData.push(this.pieData[k]);
                break;
            }
        }
        this.dbQueryData = filteredData;
        // Traverse filteredData and replace ',' in count
        this.dbQueryData.forEach(item => {
            item.count = item.count.replace(/,/g, '');
        });
    }
    clickHandlerResponseTime(event) {
        this.showAllOption = true;
        let tableConfig = {
            config: {
                globalFilter: true,
                toggleFilter: true
            },
            tableAction: [
                {
                    "iconType": "icon",
                    "iconClass": "las-undo-alt-solid",
                    "toolTip": "Show All data",
                    "action": "showalldata",
                }
            ]
        };
        this.tableConfig = tableConfig;
        let filteredData = [];
        for (let k = 0; k < this.pieData.length; k++) {
            if (event.point.y == this.pieData[k]['avg']) {
                this.headerName = "DB Request [ Response Time : " + this.pieData[k]['avg'] + " (in ms)]";
                filteredData.push(this.pieData[k]);
                break;
            }
        }
        this.dbQueryData = filteredData;
        // Traverse filteredData and replace ',' in count
        this.dbQueryData.forEach(item => {
            item.count = item.count.replace(/,/g, '');
        });
    }
    showAllData() {
        this.headerName = "DB Request";
        this.showAllOption = false;
        this.dbQueryData = this.wholeData;
    }
    showHeaderInfo() {
        let dbGroupByFilters = this.commonService.dbGroupByFilters;
        this.headerInfo = "";
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.filterGroupByStr = '';
        this.filterOrderByStr = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        this.completeGroupBy = '';
        this.completeOrderBy = '';
        if (this.sessionService.preSession.multiDc === true) {
            let dcName = this._ddrData.dcName;
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "tierName")) {
            if (dbGroupByFilters['tierName'].length > 32) {
                this.filterTierName += 'Tier=' + dbGroupByFilters['tierName'].substring(0, 32) + '..' + ' ,';
                this.completeTier = dbGroupByFilters['tierName'];
            }
            else
                this.filterTierName += 'Tier=' + dbGroupByFilters['tierName'] + ' ,';
            this.downloadHeaderInfo += 'Tier=' + dbGroupByFilters['tierName'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "serverName")) {
            if (dbGroupByFilters['serverName'].length > 32) {
                this.filterServerName = 'Server=' + dbGroupByFilters['serverName'].substring(0, 32) + '..' + ' ,';
                this.completeServer = dbGroupByFilters['serverName'];
            }
            else
                this.filterServerName = 'Server=' + dbGroupByFilters['serverName'] + ' ,';
            this.downloadHeaderInfo += 'Server=' + dbGroupByFilters['serverName'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "appName")) {
            if (dbGroupByFilters['appName'].length > 32) {
                this.filterInstanceName = ', Instance=' + dbGroupByFilters['appName'].substring(0, 32) + '..' + ' ,';
                this.completeInstance = dbGroupByFilters['appName'];
            }
            else
                this.filterInstanceName = 'Instance=' + dbGroupByFilters['appName'] + ' ,';
            this.downloadHeaderInfo += 'Instance=' + dbGroupByFilters['appName'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "groupByFC")) {
            if (dbGroupByFilters['groupByFC'].length > 32) {
                this.filterGroupByStr = 'Group By=' + dbGroupByFilters['groupByFC'].substring(0, 32) + '..' + ' ,';
                this.completeGroupBy = dbGroupByFilters['groupByFC'];
            }
            else
                this.filterGroupByStr = 'Group By=' + dbGroupByFilters['groupByFC'] + ' ,';
            this.downloadHeaderInfo += 'Group By=' + dbGroupByFilters['groupByFC'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "orderByFC")) {
            if (dbGroupByFilters['orderByFC'].length > 32) {
                this.filterOrderByStr = ', Order By=' + dbGroupByFilters['orderByFC'].substring(0, 32) + '..' + ' ,';
                this.completeOrderBy = dbGroupByFilters['orderByFC'];
            }
            else
                this.filterOrderByStr = 'Order By=' + dbGroupByFilters['orderByFC'] + ' ,';
            this.downloadHeaderInfo += 'Order By=' + dbGroupByFilters['orderByFC'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "startTimeInDateFormat")) {
            this.headerInfo += 'StartTime=' + dbGroupByFilters['startTimeInDateFormat'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "endTimeInDateFormat")) {
            this.headerInfo += 'EndTime=' + dbGroupByFilters['endTimeInDateFormat'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "btcategoryId"))
            this.headerInfo += 'BT Type=' + this.commonService.getBTCategoryName(dbGroupByFilters['btcategoryId']) + ' ,';
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "urlName")) {
            this.headerInfo += 'BT=' + decodeURIComponent((dbGroupByFilters['urlName']).toString()) + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "url")) {
            let val = dbGroupByFilters['url'];
            if (val.length > 40) {
                this.urlStr = 'URL=' + val.substring(0, 40) + ".." + ' ,';
                this.CompleteURL = val;
            }
            else {
                this.urlStr = 'URL=' + val + ' ,';
                this.CompleteURL = val;
            }
            this.downloadHeaderInfo += 'URL=' + dbGroupByFilters['url'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "statusCodeFC")) {
            this.headerInfo += 'Status =' + dbGroupByFilters['statusCodeFC'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "page")) {
            this.headerInfo += 'Page=' + dbGroupByFilters['page'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "script")) {
            this.headerInfo += 'Script=' + dbGroupByFilters['script'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "transaction")) {
            this.headerInfo += 'Transaction=' + dbGroupByFilters['transaction'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "browser")) {
            this.headerInfo += 'Browser=' + dbGroupByFilters['browser'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "access")) {
            this.headerInfo += 'Access=' + dbGroupByFilters['access'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "location")) {
            this.headerInfo += 'Location=' + dbGroupByFilters['location'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(dbGroupByFilters, "tags")) {
            this.headerInfo += 'Tag:' + dbGroupByFilters['tags'];
            this.headerInfo = this.headerInfo.replace(/["']/g, "");
        }
        if (this.headerInfo.startsWith(',')) {
            this.headerInfo = this.headerInfo.substring(1);
        }
        if (this.headerInfo.endsWith(',')) {
            this.headerInfo = this.headerInfo.substring(0, this.headerInfo.length - 1);
        }
    }
    ngOnDestroy() {
        this.sideBarDbGroupBy.unsubscribe();
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = this.id.testRun + "&queryId=" + this.queryId + "&tierName=" + this.id.tierName;
        this.isCancelQuery = false;
        this.ndDdrHttpService.getCancelQueryResult(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__["CancelQueryLoadedState"]) {
                return (state.data.status);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
DbGroupByComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__["DdrDataModelService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_5__["MessageService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["NdDdrHttpService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_6__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__["BreadcrumbService"] }
];
DbGroupByComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'db-group-by',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./db-group-by.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/db-group-by/db-group-by.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./db-group-by.component.scss */ "./src/app/pages/ddr/components/db-group-by/db-group-by.component.scss")).default]
    })
], DbGroupByComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/db-report/db-report.component.scss":
/*!*************************************************************************!*\
  !*** ./src/app/pages/ddr/components/db-report/db-report.component.scss ***!
  \*************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".ui-panel-contents {\n  overflow: auto;\n  height: 380px;\n}\n\n.ddr-graphpanel .highcharts-container {\n  height: 400px !important;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/db-report/db-report.component.ts":
/*!***********************************************************************!*\
  !*** ./src/app/pages/ddr/components/db-report/db-report.component.ts ***!
  \***********************************************************************/
/*! exports provided: DbReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DbReportComponent", function() { return DbReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");














let DbReportComponent = class DbReportComponent {
    constructor(commonService, _ddrData, _router, breadcrumbService, ddrRequest, breadcrumb, sessionService, ndDdrHttpService, elasticSearchService) {
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this._router = _router;
        this.breadcrumbService = breadcrumbService;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.elasticSearchService = elasticSearchService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_3__;
        this.sortOn = ""; // used to set the default sort order
        this.queryDetail = [{
                "tierName": "", "tierId": "", "serverName": "", "serverId": "", "appName": "", "appId": "", "urlName": "", "count": "", "min": "", "max": "", "cumsqlexectime": "", "mincumsqlexectime": "", "maxcumsqlexectime": "", "avg": "", "failedcount": "", "sqlIndex": "", "sqlQuery": "", "urlIndex": "", "id": 0, "sqlbegintimestamp": "", "sqlendtimestamp": "", "sqlquery": ""
            }]; // stores the query details in above format
        this.customFlag = false;
        this.limit = 50; // specifies the maximum number of records to be retrieved from the server
        this.offset = 0; // represents the offset value used in pagination for fetching db-report data
        this.loading = false; //ajax-loader
        this.tableHeader = "DB Request"; // shows DB report accordion header
        this.showChart = true; // flag to show/hide chart
        this.topNQueries = ''; // show top N queries in pie chart 
        this.headerInfo = ""; // holds the filter-criteria info for db-report
        this.showPagination = false; // flag to show/hide pagination
        this.isCancelQuery = false; // variable to toggle Cancel Query Dialog
        this.isCancelQuerydata = false; // variable to disable cancel query Button
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.breadcrumb = breadcrumb;
        this.otelMode = this._ddrData.otelMode;
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.isFromCQM = false;
        this.first.first = 0;
        this.rows.rows = 50;
        if (this._ddrData.splitViewFlag === false)
            this.commonService.isToLoadSideBar = true;
        this.commonService.currentReport = "DB Report";
        this.breadcrumb.add({ label: 'DB Queries', routerLink: '/ddr/dbReport' });
        if (this._ddrData.tagData) {
            this.tagInfo = this._ddrData.createGtagsIntoStr(this._ddrData.tagData);
        }
        window.onpopstate = function (event) {
            this.commonService.isFilterFromSideBar = true;
            console.log(' window.onpopstate called -- isFilterFromSideBar -- ', this.commonService.isFilterFromSideBar);
        };
        this.commonService.enableQueryCaching = this._ddrData.enableQueryCaching;
        this.id = this.commonService.getData();
        this.randomNumber();
        this.commonService.removeFromStorage();
        this.commonService.setParameterIntoStorage = this.id;
        //DB Report opens from flowpath-by-signature or ddr-integrated-flowpath screen
        if (this.commonService.signatureToDB === true) {
            this.dataFromFPComponent = this.commonService.getFPData;
        }
        if (this.id.strStartTime == undefined && this.id.strEndTime == undefined) {
            this.startTimeInMs = this.id.startTime;
            this.endTimeInMs = this.id.endTime;
        }
        else {
            this.startTimeInMs = this.id.strStartTime;
            this.endTimeInMs = this.id.strEndTime;
        }
        this.getQueryData();
        if (!this.otelMode) {
            this.getQueryDataCount();
        }
        this.createColumns();
        //DB Report from Sidebar(CQM)
        this.sideBarDbReport = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "DB Report") {
                this.commonService.isFilterFromSideBar = true;
                this.limit = 50;
                this.topNQueries = this.commonService.dbFilters.topNQueries;
                this.createColumns();
                this.getQueryData();
                if (!this.otelMode) {
                    this.getQueryDataCount();
                }
            }
        });
    }
    createColumns() {
        if (!this.otelMode) {
            this.relativePath = "ddr/db-report/db-report-agg.json";
        }
        if (this.otelMode) {
            this.relativePath = "ddr/db-report/db-report-agg-elasticSearch.json";
        }
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
        const me = this;
        console.log('Event: ', event);
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable" && ((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.columnClicked) === null || _d === void 0 ? void 0 : _d.label) === "Query Count") {
            me.getDbFlowpathData(event.cavEventExt.row);
        }
        if (((_f = (_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.actionConfig) === null || _f === void 0 ? void 0 : _f.action) === "clickable" && ((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label) === "Query") {
            me.showRowInfo(event.cavEventExt.row);
        }
        if (((_k = (_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.actionConfig) === null || _k === void 0 ? void 0 : _k.action) === "showalldata") {
            this.showAllData();
        }
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    getQueryData() {
        if (this.id.dbReportCategory == 'DB Request Report') {
            this.id.strOrderBy = 'exec_time_desc'; // beacuse undefined is passing in orderby from webdashboard
        }
        var queryParams = "";
        let urlParam = "";
        const pagination = `&limit=${this.limit}&offset=${this.offset}`;
        const flag = `&showCount=false&customFlag=${this.customFlag}`;
        if (this.commonService.enableQueryCaching == 1) {
            queryParams += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun;
        }
        else {
            queryParams += "testRun=" + this.id.testRun;
        }
        // Handling filters from sidebar
        if (this.commonService.isFilterFromSideBar && Object.keys(this.commonService.dbFilters).length != 0) {
            const dbParam = this.commonService.dbFilters;
            // Adding orderby parameter if present and not from DB call by BT
            if (this._ddrData.strOrderBy && this.commonService.queryCountToDB['fromDBCallByBT'] != 'true') {
                dbParam['strOrderBy'] = this._ddrData.strOrderBy;
            }
            // Handling queryParams construction based on filter parameters
            if (this.commonService.isValidParamInObj(dbParam, 'ndeProtocol') && this.commonService.isValidParamInObj(dbParam, 'pubicIP') && this.commonService.isValidParamInObj(dbParam, 'publicPort') && this.commonService.isValidParamInObj(dbParam, 'ndeTestRun')) {
                if (this.commonService.enableQueryCaching == 1) {
                    queryParams = 'cacheId=' + dbParam['ndeTestRun'] + '&testRun=' + dbParam['ndeTestRun'];
                }
                else {
                    queryParams = 'testRun=' + dbParam['ndeTestRun'];
                }
            }
            urlParam = this.commonService.makeParamStringFromObj(dbParam);
        }
        else {
            // DB Report opens from DB Group By BT Screen (By Clicking on query count)
            if (this._ddrData.queryCountToDBFlag === true) {
                urlParam = `&tierName=${this.commonService.queryCountToDB.tierName}&serverName=${this.commonService.queryCountToDB.serverName}&appName=${this.commonService.queryCountToDB.appName}&strStartTime=${this.commonService.queryCountToDB.strStartTime}&strEndTime=${this.commonService.queryCountToDB.strEndTime}&statusCode=-2&strOrderBy=${this.commonService.queryCountToDB.strOrder}&object=6&urlIndex=${this.commonService.queryCountToDB.urlIdx}&btcategoryId=${this.commonService.queryCountToDB.btcategoryId}`;
            }
            else {
                let group = '';
                if (this.id.tierName && this.id.tierName != 'NA' && (this.id.serverName && this.id.serverName != 'NA') && (this.id.appName && this.id.appName != 'NA'))
                    group = 'tier,server,app';
                else if (this._ddrData.strGroup == null || this._ddrData.strGroup == "tier")
                    group = 'tier';
                else
                    group = 'url';
                let btCat = this.id.btCategory;
                if (this.id.btCategory && this.id.btCategory.toLowerCase() == "all" || this.id.btCategory == null) {
                    btCat = undefined;
                }
                urlParam = `&tierName=${this.id.tierName}&serverName=${this.id.serverName}&appName=${this.id.appName}&tierId=${this.id.tierid}&serverId=${this.id.serverid}&appId=${this.id.appid}&strStartTime=${this.startTimeInMs}&strEndTime=${this.endTimeInMs}&statusCode=-2&strOrderBy=${this.id.strOrderBy}&object=6&urlIndex=${this.id.urlIndex}&btcategoryId=${btCat}&urlName=${this.id.urlName}&backend_ID=${this._ddrData.backendId}`;
                //DB Report opens from flowpath-by-signature or ddr-integrated-flowpath screen
                if (this.commonService.signatureToDB === true) {
                    urlParam += `&flowpathSignature=${this.dataFromFPComponent.flowpathSignature}`;
                }
                else {
                    urlParam += `&strGroup=${group}`;
                }
            }
            if (this.tagInfo && this.tagInfo.length != 0) {
                urlParam += "&tags=" + this.tagInfo;
            }
            this.commonService.dbFilters = this.commonService.makeObjectFromUrlParam(urlParam);
        }
        this.ajaxUrl = queryParams + urlParam; //using it as count query parameter
        this.setDefaultSort(this.commonService.dbFilters['strOrderBy']);
        queryParams += urlParam + pagination + flag;
        queryParams += '&queryId=' + this.queryId;
        //commenting for now TBD: Query Cancellation
        // setTimeout(() => {
        //     this.openpopup();
        // }, this._ddrData.guiCancelationTimeOut);
        if (!this.otelMode) {
            this.fetchDataFromPsql(queryParams);
        }
        if (this.otelMode) {
            this.fetchDataFromElasticSearch(queryParams);
        }
    }
    fetchDataFromPsql(queryParams) {
        this.ndDdrHttpService.getDBReportData(queryParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["DBReportLoadedState"]) {
                this.doAssignValues(state.data);
                this.loading = false;
            }
        }, (error) => {
            console.error('Error in fetching response ... ', error);
            this.commonService.showError(error);
            this.loading = false;
        });
    }
    /**
    * Fetches data from Elasticsearch using the specified query parameters.
    *
    * @param queryParams The query parameters to use when constructing the query.
    */
    fetchDataFromElasticSearch(queryParams) {
        let reqPayload = {};
        if (this.elasticSearchService.isFromOtelTrxnServiceMap) {
            this.elasticSearchService.isFromOtelTrxnServiceMap = false;
            reqPayload = this.elasticSearchService.getTrxServiceMapPayload();
        }
        else {
            reqPayload = this.ndDdrHttpService.createPayloadForPOSTCall(queryParams);
        }
        if (window['logLevel'] > 1) {
            console.log("********reqPayload******", reqPayload);
        }
        const resFields = [
            "trace_id",
            "span_id",
            "@timestamp",
            "duration",
            "attributes.cav.*",
            "attributes.db.*",
        ];
        const elasticQuery = this.elasticSearchService.buildElasticSearchQuery(reqPayload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_12__["BREADCRUMB_ITEMS"].DB_QUERIES);
        if (window['logLevel'] > 1) {
            console.log("********elasticQuery******", elasticQuery);
        }
        const dataSubscription = this.elasticSearchService.search(elasticQuery).subscribe(res => {
            this.elasticSearchData = res;
            if (window['logLevel'] > 1) {
                console.log('Search results from Elasticsearch:', res);
            }
            this.processElasticData(this.elasticSearchData);
        }, error => {
            console.error('Error searching Elasticsearch:', error);
            this.queryInfo = [];
            this.totalCount = 0;
            this.loading = false;
        });
    }
    /**
     * Processes the data returned from Elasticsearch
     * and assigns it to the local variables.
     *
     * @param elasticData The response from Elasticsearch
     */
    processElasticData(elasticData) {
        this.queryInfo = [];
        this.fullQueryName = '';
        this.totalCount = 0;
        this.commonService.isFilterFromSideBar = false;
        if (elasticData && elasticData.hits && elasticData.hits.total && elasticData.aggregations.statements.buckets) {
            // Assign the aggregations data
            this.elasticDBAggData = elasticData.aggregations.statements.buckets;
            this.totalElasticRecords = Number(elasticData.hits.total.value);
            // Create a new array with the required data
            this.DbReportDataArray = this.elasticDBAggData.map((record) => {
                // Creating new FlowpathData object and assign properties for every record from elastic search
                let durationStats = record.duration_stats;
                // Calculate the duration in milliseconds
                const avgInMs = Number(durationStats["avg"]) / 1000000;
                const minInMs = Number(durationStats["min"]) / 1000000;
                const maxInMs = Number(durationStats["max"]) / 1000000;
                const sumInMs = Number(durationStats["sum"]) / 1000000;
                return {
                    sqlQuery: record.key,
                    count: record.doc_count,
                    maxcumsqlexectime: isNaN(maxInMs) ? "" : maxInMs,
                    mincumsqlexectime: isNaN(minInMs) ? "" : minInMs,
                    avg: isNaN(avgInMs) ? "" : avgInMs
                };
            });
            this.totalCount = this.totalElasticRecords;
            this.queryInfo = this.DbReportDataArray;
            this.headerInfo = this.elasticSearchService.filtercriteria;
            if (window['logLevel'] > 1) {
                console.log("Elasticsearch processed DB Data Final Data", this.queryInfo);
            }
            if (this.queryInfo.length === 0) {
                this.limit = 0;
                this.offset = 0;
                this.fullQueryName = 'No Query is present.';
            }
            else {
                this.fullQueryName = this.queryInfo[0]['sqlQuery'];
            }
            this.loading = false;
        }
        else {
            this.queryInfo = [];
            this.totalCount = 0;
            this.loading = false;
        }
        this.createPieChart(this.queryInfo);
    }
    getQueryDataCount() {
        const countUrl = `${this.ajaxUrl}&customFlag=${this.customFlag}&showCount=true`;
        this.ndDdrHttpService.getDBReportCountData(countUrl).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["DBReportCountLoadedState"]) {
                this.assignCountValues(state.data);
            }
        }, (error) => {
            console.error('Error fetching response .... ', error);
            this.commonService.showError(error);
        });
    }
    assignCountValues(res) {
        this.customFlag = false;
        this.totalCount = res.totalCount;
        // Determine if pagination should be shown
        this.showPagination = this.totalCount.valueOf() > 50;
        // Ensure limit does not exceed totalCount
        if (this.totalCount.valueOf() > 0 && this.limit.valueOf() > this.totalCount.valueOf()) {
            this.limit = Number(this.totalCount);
        }
    }
    doAssignValues(res) {
        this.isCancelQuerydata = true;
        if (res.hasOwnProperty('Status')) {
            this.commonService.showError(res.Status);
        }
        this.commonService.isFilterFromSideBar = false;
        this.queryDetail = res.data;
        this.loading = false;
        this.first = { first: this.offset };
        this.rows = { rows: this.limit };
        this.totalQueryCount = " [ Total Query Count: " + res.queryCount + "]";
        this.queryInfo = this.getQueryInfo();
        if (this.queryDetail.length === 0) {
            this.limit = 0;
            this.offset = 0;
            this.fullQueryName = 'No Query is present.';
        }
        this.commonService.dbFilters['startTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.startTime), "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
        this.commonService.dbFilters['endTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.endTime), "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
        this.createPieChart(res);
        this.headerInfo = this.commonService.createFilterCriteria(this.commonService.dbFilters);
    }
    getQueryInfo() {
        var queryArr = [];
        if (this.queryDetail.length > 0) {
            for (var i = 0; i < this.queryDetail.length; i++) {
                if (this.queryDetail[i]['sqlQuery'] != undefined)
                    this.queryDetail[i]['sqlQuery'] = this.queryDetail[i]['sqlQuery'].replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
                else
                    this.queryDetail[i]['sqlquery'] = this.queryDetail[i]['sqlquery'].replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
                if (i == 0) {
                    this.fullQueryName = this.queryDetail[0]['sqlQuery'] || this.queryDetail[0]['sqlquery'];
                }
                queryArr[i] = { tierName: this.queryDetail[i]["tierName"], tierId: this.queryDetail[i]["tierId"], serverName: this.queryDetail[i]["serverName"], serverId: this.queryDetail[i]["serverId"], appName: this.queryDetail[i]["appName"], appId: this.queryDetail[i]["appId"], count: this.queryDetail[i]["count"], min: this.queryDetail[i]["min"], max: this.queryDetail[i]["max"], avg: this.queryDetail[i]["avg"], failedcount: this.queryDetail[i]["failedcount"], sqlQuery: this.queryDetail[i]["sqlQuery"], sqlIndex: this.queryDetail[i]["sqlIndex"], mincumsqlexectime: this.queryDetail[i]["mincumsqlexectime"], maxcumsqlexectime: this.queryDetail[i]["maxcumsqlexectime"], urlName: this.queryDetail[i]["urlName"], urlIndex: this.queryDetail[i]["urlIndex"], sqlquery: this.queryDetail[i]["sqlquery"], sqlbegintimestamp: this.queryDetail[i]["sqlbegintimestamp"], sqlendtimestamp: this.queryDetail[i]["sqlendtimestamp"], cumsqlexectime: this.queryDetail[i]["cumsqlexectime"] };
            }
            return queryArr;
        }
        else {
            return queryArr;
        }
    }
    loadDbReportPagination(event) {
        this.loading = true;
        this.offset = event.first;
        this.limit = event.rows;
        if (this.limit.valueOf() > this.totalCount.valueOf()) {
            this.limit = Number(this.totalCount);
        }
        if ((this.limit.valueOf() + this.offset.valueOf()) > this.totalCount.valueOf()) {
            this.limit = Number(this.totalCount) - Number(this.offset);
        }
        this.commonService.isFilterFromSideBar = true;
        this.createColumns();
        this.getQueryData();
    }
    setDefaultSort(order) {
        if (order == "exec_time_desc" || order == "undefined")
            this.sortOn = "avg";
        if (order == "count_desc")
            this.sortOn = "count";
        if (order == "query_count")
            this.sortOn = "failedcount";
        if (order == "query")
            this.sortOn = "sqlQuery";
    }
    clickHandler(event) {
        console.log("inside click handler -- event -- ", event);
        if (event.point != undefined) {
            if (event.point.name == "Other") {
                this.queryInfo = this.restDataArrOfPie;
            }
            else {
                let filteredData = [];
                for (let k = 0; k < this.chartData.length; k++) {
                    if (this.chartData[k]["sqlQuery"] == event.point.name || this.chartData[k]["sqlquery"] == event.point.name) {
                        filteredData.push(this.chartData[k]);
                    }
                }
                this.queryInfo = filteredData;
            }
            this.showRowInfo(this.queryInfo[0]);
        }
    }
    showAllData() {
        this.queryInfo = this.wholeData;
        this.showRowInfo(this.queryInfo[0]);
    }
    createPieChart(pieData) {
        let dbParams = this.commonService.dbFilters;
        if (this.topNQueries == '' || this.topNQueries == undefined)
            this.topNQueries = '5';
        let queryName;
        let dataArr = [];
        let restDataArr = [];
        let tooltipHoverType = "";
        let pieText = "Top " + this.topNQueries + " DB Queries By Response Time";
        if (!this.otelMode) {
            this.chartData = pieData.data;
        }
        if (this.otelMode) {
            this.chartData = pieData;
        }
        this.wholeData = this.chartData;
        if (this.chartData.length == 0) {
            this.showChart = false;
        }
        else {
            this.showChart = true;
        }
        if (this._ddrData.queryCountToDBFlag == true) {
            pieText = "Top " + this.topNQueries + " DB Queries By Response Time";
            this.tableHeader = "DB Request By url";
            tooltipHoverType = " Response Time: ";
        }
        else if (dbParams.strOrderBy == "exec_time_desc") {
            pieText = "Top " + this.topNQueries + " DB Queries By Response Time";
            this.tableHeader = "Slow DB Calls By Response Time";
            tooltipHoverType = " Response Time: ";
        }
        else if (dbParams.strOrderBy == "count_desc") {
            pieText = "Top " + this.topNQueries + " DB Calls By Count";
            this.tableHeader = "Top " + this.topNQueries + " DB Calls By Count";
            tooltipHoverType = " Count: ";
        }
        else if (dbParams.strOrderBy == "query_count") {
            pieText = "Top " + this.topNQueries + " DB Queries By Error Count";
            this.tableHeader = "Top DB Queries By Error Count";
            tooltipHoverType = " Error Count: ";
        }
        else {
            pieText = "Top " + this.topNQueries + " DB Queries By Response Time";
            this.tableHeader = "DB Request ";
            tooltipHoverType = " Response Time: ";
        }
        if (this.totalQueryCount) {
            this.tableHeader += this.totalQueryCount;
        }
        for (var i = 0; i < this.chartData.length; i++) {
            if (i < Number(this.topNQueries)) {
                let queryName = this.chartData[i]["sqlquery"] || this.chartData[i]["sqlQuery"];
                if (dbParams.strOrderBy == "exec_time_desc" || this._ddrData.queryCountToDBFlag == true) {
                    let avgRespTime = this.chartData[i]["avg"];
                    dataArr.push({ "name": queryName, "y": Number(avgRespTime.toFixed(3)) });
                }
                else if (dbParams.strOrderBy == "count_desc") {
                    let count = this.chartData[i]["count"];
                    dataArr.push({ "name": queryName, "y": Number(count) });
                }
                else if (dbParams.strOrderBy == "query_count") {
                    let errorCount = this.chartData[i]["failedcount"];
                    dataArr.push({ "name": queryName, "y": Number(errorCount) });
                }
                else {
                    let avgRespTime = this.chartData[i]["avg"];
                    dataArr.push({ "name": queryName, "y": Number(avgRespTime.toFixed(3)) });
                }
            }
            else {
                restDataArr.push(this.chartData[i]);
            }
        }
        this._ddrData.queryCountToDBFlag = false;
        if (this.chartData.length > Number(this.topNQueries)) {
            let totalRespTime = 0;
            let totalQueryCount = 0;
            let totalErrorCount = 0;
            queryName = "Other";
            for (let j = 0; j < restDataArr.length; j++) {
                totalRespTime += Number(restDataArr[j]["avg"]);
                totalQueryCount += Number(restDataArr[j]["count"]);
                totalErrorCount += Number(restDataArr[j]["failedcount"]);
            }
            if (this._ddrData.queryCountToDBFlag == true || dbParams.strOrderBy == "exec_time_desc") {
                dataArr.push({ "name": queryName, "y": Number(totalRespTime.toFixed(3)) });
            }
            else if (dbParams.strOrderBy == "count_desc") {
                dataArr.push({ "name": queryName, "y": Number(totalQueryCount) });
            }
            else if (dbParams.strOrderBy == "query_count") {
                dataArr.push({ "name": queryName, "y": Number(totalErrorCount) });
            }
            else
                dataArr.push({ "name": queryName, "y": Number(totalRespTime.toFixed(3)) });
        }
        this.restDataArrOfPie = restDataArr;
        this.options = {
            chart: {
                type: "pie",
                width: 400
            },
            credits: {
                enabled: false
            },
            title: {
                text: pieText,
                style: { 'fontSize': '13px' }
            },
            legend: {
                itemWidth: 400
            },
            tooltip: {
                //pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>,Response Time: <b>{point.y}</b>'
                style: {
                    fontSize: '7pt',
                    width: 300,
                    height: 50
                },
                formatter: function () {
                    let tooltip = "";
                    let pointName = this.point.name;
                    if (pointName.length > 60)
                        tooltip += pointName.substring(0, 60) + "...";
                    else
                        tooltip += pointName;
                    tooltip += " Percentage: " + "<b>" + this.point.percentage.toFixed(2) + "%" + "</b>" + "," + tooltipHoverType + "<b>" + this.point.y + "</b>";
                    return tooltip;
                }
            },
            plotOptions: {
                pie: {
                    allowPointSelect: true,
                    cursor: 'pointer',
                    dataLabels: {
                        enabled: false
                    },
                    showInLegend: true
                }
            },
            exporting: {
                enabled: false
            },
            series: [
                {
                    name: "Percentage",
                    data: dataArr,
                    enableMouseTracking: true
                }
            ]
        };
    }
    getDbFlowpathData(data) {
        this._ddrData.dbTofpflag = true;
        this.commonService.previousReport = 'Flowpath';
        this.commonService.dbflowpathdata = data;
        this.commonService.dbflowpathdata['strStartTime'] = this.commonService.dbFilters['strStartTime'];
        this.commonService.dbflowpathdata['strEndTime'] = this.commonService.dbFilters['strEndTime'];
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_12__["BREADCRUMB_ITEMS"].DB_REPORT;
        if (this._router.url.indexOf('/home/ddrCopyLink/') != -1) {
            this._router.navigate(['/home/ddrCopyLink/flowpath']);
        }
        else {
            this._router.navigate(['/ddr/flowpath']);
        }
    }
    openErrorCount(rowData) {
        if (rowData !== undefined) {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_12__["BREADCRUMB_ITEMS"].DB_REPORT;
            this.commonService.fromDBtoExpFlag = true;
            this.commonService.fromDBtoExpData = rowData;
            if (this._router.url.indexOf('/home/ddrCopyLink/') != -1) {
                this._router.navigate(['/home/ddrCopyLink/exception']);
            }
            else {
                this._router.navigate(['/ddr/exception']);
            }
        }
    }
    showRowInfo(nodeInfo) {
        this.fullQueryName = (nodeInfo.sqlQuery === undefined) ? nodeInfo.sqlquery : nodeInfo.sqlQuery;
    }
    ngOnDestroy() {
        this.breadcrumb['items'].pop();
        this.sideBarDbReport.unsubscribe();
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = "testRun=" + this.id.testRun + "&queryId=" + this.queryId + "&tierName=" + this.id.tierName;
        this.isCancelQuery = false;
        this.ndDdrHttpService.getCancelQueryResult(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["CancelQueryLoadedState"]) {
                return state.data;
            }
        });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
DbReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_7__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_13__["DdrBreadcrumbService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["BreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_5__["SessionService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__["NdDdrHttpService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_9__["ElasticsearchQueryService"] }
];
DbReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'db-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./db-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/db-report/db-report.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./db-report.component.scss */ "./src/app/pages/ddr/components/db-report/db-report.component.scss")).default]
    })
], DbReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.css":
/*!************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.css ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("\r\n .ui-widget-header {\r\n        border: 1px solid #aaaaaa;\r\n        background: #cccccc url(\"/netstorm/images/tableHeader.png\") 50% 50% repeat-x\r\n                !important;\r\n        color: #222222;\r\n        font-weight: bold;\r\n}\r\nsvg.redLine path {\r\n  stroke:red;\r\n  stroke-width:1;\r\n}\r\n#divMapimg {\r\n  display:    none;\r\n    position:   fixed;\r\n    z-index:    1000;\r\n    top:        -130;\r\n    left:       -430;\r\n    height:     100%;\r\n    width:      100%;\r\n    background: rgba( 255, 255, 255, .8 )\r\n                url('/netstorm/images/ajax-loader.gif') \r\n                50% 50% \r\n                no-repeat;\r\n\r\n}\r\n.open{\r\n\t  z-index:50!important;\r\n  }\r\na.tooltips {\r\n  position: relative;\r\n  display: inline;\r\n}\r\na.tooltips span {\r\n  position: absolute;\r\n  min-width:200px; \r\n  color: black;\r\n  \r\n   background-color: white;\r\n  /* outer shadows  (note the rgba is red, green, blue, alpha) */\r\n  -webkit-box-shadow: 0px 0px 12px rgba(0, 0, 0, 0.4);\r\n  -moz-box-shadow: 0px 1px 6px rgba(23, 69, 88, .5);\r\n  /* rounded corners */\r\n  border-radius: 7px;\r\n  /* gradients */\r\n  background: -moz-linear-gradient(top, white 0%, white 55%, #D5E4F3 130%);\r\n  \r\n /* background: #000000; */\r\n  padding-left: 4px;\r\n  padding-right: 4px;\r\n  min-height: 30px;\r\n  line-height: 16px;\r\n  overflow: hidden;\r\n  text-align: left;\r\n  visibility: hidden;\r\n  border: 1px solid #1a1a1a;\r\n  z-index: 99999;\r\n  border: 2px Solid #999;\r\n  border-top-left-radius: 7px 7px;\r\n  border-top-right-radius: 7px 7px;\r\n  border-bottom-right-radius: 7px 7px;\r\n  border-bottom-left-radius: 7px 7px;\r\n  /*border-radius: 6px; */\r\n      /*opacity: 1;*/\r\n    /*transition: opacity 1s;*/\r\n  white-space: nowrap;\r\n}\r\na.tooltips span:after {\r\n  content: '';\r\n  position: absolute;\r\n  bottom: 100%;\r\n  left: 50%;\r\n  margin-left: -8px;\r\n  width: 0; height: 0;\r\n  border-bottom: 8px solid #000000;\r\n  border-right: 8px solid transparent;\r\n  border-left: 8px solid transparent;\r\n}\r\na:hover.tooltips span {\r\n  visibility: visible;\r\n  /*opacity: 1!important;*/\r\n  top: 30px;\r\n  left: 50%;\r\n  margin-left: -76px;\r\n}\r\n.err-node{\r\n    width:48px; \r\n height:48px; \r\n border-radius: 25px;\r\n border: 3px solid red;\r\n box-shadow: 0px 0px 15px red;\r\n \r\n  }\r\n.err-page-node {\r\n    width: 48px;\r\n    height: 48px;\r\n    border-radius: 25px;\r\n    border: 4px solid #ffbf00;\r\n    box-shadow: 0px 0px 28px #000\r\n \r\n  }\r\n.node{\r\n    width:48px; height:48px; border-radius: 25px;border: 3px solid #1695fb;\r\n    box-shadow: 0px 0px 15px #000;\r\n    background:ghostwhite;\r\n  }\r\n.nodeImage{\r\n    float:left; width:30px; /* height:50px; */\r\n\r\n  }\r\n.nodeRight{\r\n    float:right; width:108px; \r\n     height:20px; \r\n  }\r\n.nodeIcon{\r\n     /*height:16px;  width:10px;*/\r\n    padding-top:1px;\r\n  }\r\n.nodeHeading{\r\n    text-align: center;\r\n    color: #0c5207;\r\n    font-weight: bold;\r\n    font-size: 10px;\r\n        padding-top: 11px;\r\n        width: 185px;\r\n        height:20px;\r\n  }\r\n.nodeBottom{\r\n    text-align: center;\r\n    margin-top:6px;\r\n    font-size: 10px;\r\n        width:183px;\r\n  }\r\na{\r\n color:black !important;\r\n}\r\n.flowmap-box {\r\n  margin: 5px 4px;\r\n  height: 87vh;\r\n  padding: 1px;\r\n  border-radius: 4px;\r\n  box-shadow: 0 0 6px 2px #565656;\r\n  background: hsla(0, 0%, 100%, 0.8);\r\n  overflow: auto;\r\n  position: relative;\r\n}\r\n.textWrap {\r\n    width: 450px;\r\n    text-overflow: ellipsis;\r\n    overflow: hidden;\r\n    white-space: nowrap;\r\n}\r\n.fieldsetClass{\r\n    border-color: rgba(79, 79, 80, 0.3);\r\n}\r\n.for-filter{\r\n    border: 1px solid lightgray;\r\n    height: 20px;\r\n    padding: 2px;\r\n}\r\n.flowmapicon{\r\n  display: inline-flex;\r\n  width: 50%;\r\n}\r\n.graphDiv{\r\n  width: 600px;\r\n  height: 400px;\r\n  float: left;\r\n  font-size: 12px;\r\n}\r\n.pre_next {\r\n  width: 45px;\r\n  height: 18px;\r\n  float: right;\r\n  text-align: center;\r\n  padding: 0.2rem 0.5rem;\r\n  font-size: 11px;\r\n  border: solid 1px #d6d6d6;\r\n  border-radius: 0.2rem;\r\n  color: #7d7d7d;\r\n  cursor: pointer;\r\n}\r\n.pagination {\r\n  width: 50%;\r\n  float: left;\r\n  box-sizing: border-box;\r\n  padding: .5em;\r\n  display: block;\r\n  font-size: 11px;\r\n  /* margin-top: 36px;\r\n  float: right;\r\n  margin-left: 10px; */\r\n}\r\n.paginationText {\r\n  width: 50%;\r\n  float: left;\r\n  text-align: right;\r\n  box-sizing: border-box;\r\n  padding: .5em;\r\n  display: block;\r\n  font-size: 11px;\r\n  /* width: 85px; \r\n  height: 18px;\r\n  margin-top: 36px;\r\n  text-align: center;\r\n  float: left;\r\n  padding-left: 500px;\r\n  font-size: 13px; */\r\n}\r\n.btn {\r\n  font-family: arial,helvetica,clean,sans-serif;\r\n  float: right;\r\n  cursor: pointer;\r\n  font-style: normal;\r\n  font-variant: normal;\r\n  font-weight: normal;\r\n  font-size: 10px;\r\n  line-height: normal;\r\n  text-align: justify;\r\n  color: #474747;\r\n}\r\n.graphDiv1 {\r\n  width: 400px;\r\n  height: 220px;\r\n  float: left;\r\n  font-size: 12px;\r\n  border: 1px solid grey;\r\n}\r\n.warnMesgclass{\r\n  background: #ffd400;\r\n  height: 21px;\r\n  width: 52%;\r\n  float:left;\r\n }\r\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.ts":
/*!***********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.ts ***!
  \***********************************************************************************/
/*! exports provided: DdrAggFlowmapComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrAggFlowmapComponent", function() { return DdrAggFlowmapComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../services/ddr-txn-flowmap-data.service */ "./src/app/pages/ddr/services/ddr-txn-flowmap-data.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-top-panel-navigation.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-top-panel-navigation.service.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/common/http */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/http.js");
/* harmony import */ var _services_ddr_agg_flowmap_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./../../services/ddr-agg-flowmap.service */ "./src/app/pages/ddr/services/ddr-agg-flowmap.service.ts");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! moment-timezone */ "./node_modules/moment-timezone/index.js");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_11__);



//import { DdrTransactioIndividualInfoService } from './../../services/ddr-transactio-individual-info.service';




// import { MenuItem, ContextMenu } from 'primeng/primeng';





//import { LZString } from './../../services/common.services';
//import { jCaptcha } from './../../services/common.services';
//declare var LZString: any
let DdrAggFlowmapComponent = class DdrAggFlowmapComponent {
    constructor(flowmapData, _render, 
    //private nodeTabledataService: DdrTransactioIndividualInfoService, 
    CommonServices, _navService, _router, _ddrData, breadcrumbService, _cavConfigService, http, el, changeDetection, aggFlowmapService) {
        this.flowmapData = flowmapData;
        this._render = _render;
        this.CommonServices = CommonServices;
        this._navService = _navService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this._cavConfigService = _cavConfigService;
        this.http = http;
        this.el = el;
        this.changeDetection = changeDetection;
        this.aggFlowmapService = aggFlowmapService;
        this.dataToDraw = [];
        this.labelNode = '';
    }
    ngOnInit() {
        this.aggFlowmapService.getDataForAgg().then(data => {
            this.dataToDraw = this.aggFlowmapService.jsonData;
            this.CommonServices.loaderForDdr = false;
            this.breadcrumbService.setBreadcrumbs("DdrAggFlowmapComponent");
            setTimeout(() => {
                this.creteflowmap(this.dataToDraw);
                this.showHeaderInfo();
            }, 600);
        });
    }
    creteflowmap(jsonDataToDraw) {
        //passing the referrence to use with function inside function
        var that = this;
        jsPlumb.ready(() => {
            var instance = window['jsp'] = jsPlumb.getInstance({
                Container: "canvas",
                Endpoint: ["Dot", { radius: 2 }],
                EndpointStyle: { fillStyle: "#567567" },
                //Anchor: "Continuous",
                connector: "Straight",
            });
            var basicType = {
                connector: "Straight",
                paintStyle: { stroke: "red", strokeWidth: 4 },
                hoverPaintStyle: { stroke: "blue" },
                overlays: [
                    "Arrow"
                ]
            };
            let agentID;
            instance.registerConnectionType("basic", basicType);
            jsonDataToDraw.forEach((obj, index) => {
                // suspend drawing and initialise.
                instance.batch(function () {
                    // make all the window divs draggable
                    instance.draggable(jsPlumb.getSelector(".flowchart-demo .window"), { grid: [20, 20] });
                    // THIS DEMO ONLY USES getSelector FOR CONVENIENCE. Use your library's appropriate selector
                    // method, or document.querySelectorAll:
                    //  jsPlumb.draggable(jsPlumb.querySelectorAll(".window"), {containment:[5,130,99999,99999]});
                    //instance.draggable(jQuery(".window"),{ containment: jQuery('flowmap-box')});
                    if (obj.cType == "P" || obj.cType == "OP" || obj.cType == "C") {
                        let callCount;
                        if (obj.pF == 0 || obj.F == obj.pF) {
                            callCount = "";
                        }
                        else {
                            callCount = "," + getCalls(obj.count);
                        }
                        instance.connect({
                            source: obj.sourceId + "",
                            target: obj.id + "",
                            // connectorStyle: connectorPaintStyle,
                            hoverPaintStyle: { stroke: "red" },
                            anchors: [["Perimeter", { shape: "Circle" }], ["Perimeter", { shape: "Rectangle" }]],
                            deleteEndpointsOnDetach: false,
                            detachable: false,
                            connector: "Straight",
                            overlays: [
                                ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                ["Label", { label: "<a style='color:black !important' id='label" + obj.id + "'><center>" + getBtName(obj.btI) + callCount + "," + timeFormatter(obj.D) + "ms" + "</center><span id='labela" + obj.id + "'></span></a>", location: 0.5, id: "myLabel", cssClass: " greenLabel" }]
                            ],
                        });
                    }
                    else {
                        instance.connect({
                            source: obj.sourceId + "",
                            target: obj.id + "",
                            // connectorStyle: connectorPaintStyle,
                            hoverPaintStyle: { stroke: "red" },
                            anchors: [["Perimeter", { shape: "Circle" }], ["Perimeter", { shape: "Rectangle" }]],
                            deleteEndpointsOnDetach: false,
                            detachable: false,
                            connector: "Straight",
                            overlays: [
                                ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                ["Label", { label: "<a style='color:black !important' id='label" + obj.id + "'><center>" + getIpName(obj.t) + "," + getCalls(obj.count) + "," + timeFormatter(obj.D) + "ms" + "</center><span id='labela" + obj.id + "'></span></a>", location: 0.5, id: "myLabel", cssClass: " greenLabel" }]
                            ],
                        });
                    }
                });
            });
            function getCalls(count) {
                if (count < 2) {
                    let lab = count + " call";
                    return lab;
                }
                else if (count == 2 || count > 2) {
                    let lab = count + " calls";
                    return lab;
                }
            }
            function timeFormatter(value) {
                if (!isNaN(value) && value % 1 != 0) {
                    value = (Number(value)).toFixed(2).toLocaleString();
                }
                return value;
            }
            function getBtName(btId) {
                for (let prop in that.aggFlowmapService.mergeBts) {
                    if (prop == btId) {
                        return that.aggFlowmapService.mergeBts[prop];
                    }
                }
            }
            function getIpName(type) {
                return that.aggFlowmapService.getBackendTypeName(type);
            }
        });
    }
    showHeaderInfo() {
        this.labelNode = '';
        let dat = new Date(this.aggFlowmapService.startTime);
        let str = dat.toLocaleString();
        dat = new Date(this.aggFlowmapService.endTime);
        let end = dat.toLocaleString();
        this.labelNode = "<b>BT :</b> " + this.aggFlowmapService.btName + ",&nbsp <b>Start Date/Time :</b> " + str + ",&nbsp <b>End Date/Time :</b> " + end;
        setTimeout(() => {
            var d = document.getElementById('filterAgg');
            d.innerHTML = this.labelNode;
        }, 400);
    }
};
DdrAggFlowmapComponent.ctorParameters = () => [
    { type: _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_2__["DdrTxnFlowmapDataService"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Renderer2"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_4__["CavTopPanelNavigationService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_5__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__["DdrBreadcrumbService"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_6__["CavConfigService"] },
    { type: _angular_common_http__WEBPACK_IMPORTED_MODULE_9__["HttpClient"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"] },
    { type: _services_ddr_agg_flowmap_service__WEBPACK_IMPORTED_MODULE_10__["DdrAggFlowmapService"] }
];
DdrAggFlowmapComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-agg-flowmap',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-agg-flowmap.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-agg-flowmap.component.css */ "./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.css")).default]
    })
], DdrAggFlowmapComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.css":
/*!************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.css ***!
  \************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.ts":
/*!***********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.ts ***!
  \***********************************************************************************/
/*! exports provided: DdrBreadCrumbComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrBreadCrumbComponent", function() { return DdrBreadCrumbComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");






let DdrBreadCrumbComponent = class DdrBreadCrumbComponent {
    constructor(breadcrumbService, commonServices, _router, _ddrData) {
        this.breadcrumbService = breadcrumbService;
        this.commonServices = commonServices;
        this._router = _router;
        this._ddrData = _ddrData;
        this.isFromEd = false;
        //this.objDdrBreadcrumbs = [];
    }
    ngOnInit() {
        let obj;
        this.testRunVisible = "";
        this.testRunVisible = this._ddrData.testRun;
        this.breadcrumbService.breadCrumbAsObservable$.subscribe((val) => {
            if (val) {
                this.objDdrBreadcrumbs = val;
                if (this.objDdrBreadcrumbs.length > 0) {
                    if (this.objDdrBreadcrumbs[0].label == 'Flowpath') {
                        this._ddrData.fpByBTFlag = false; // for bug 50708
                        obj = {
                            label: val[0].label, command: (event) => {
                                console.log('coming here for flowpath');
                                this.commonServices.flowpathHomeData$.next('');
                                this.breadcrumbService.isFromHome = true;
                                if (this.commonServices.isFromCopyLink == true)
                                    this._router.navigate(['/home/ddrCopyLink/' + val[0].routerLink[0]]);
                                else
                                    this._router.navigate(['/ddr/' + val[0].routerLink[0]]);
                            }
                        };
                    }
                    else {
                        if (val[0].routerLink[0] == 'DdrBtTrendComponent') {
                            obj = {
                                label: val[0].label, command: (event) => {
                                    this.breadcrumbService.isFromHome = true;
                                    this.breadcrumbService.isFromBreadCrumb = true;
                                    this._router.navigate(['/ddr/' + val[0].routerLink[0]]);
                                }
                            };
                        }
                        else {
                            obj = {
                                label: val[0].label, command: (event) => {
                                    this.breadcrumbService.isFromHome = true;
                                    this.breadcrumbService.isFromBreadCrumb = true;
                                    this._router.navigate(['/ddr/' + val[0].routerLink[0]]);
                                }
                            };
                        }
                    }
                }
                this.routeToHome = obj;
                console.log(val, 'value of bread', this.objDdrBreadcrumbs, this.routeToHome);
            }
        });
    }
};
DdrBreadCrumbComponent.ctorParameters = () => [
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__["DdrBreadcrumbService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__["DdrDataModelService"] }
];
DdrBreadCrumbComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-bread-crumb',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-bread-crumb.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-bread-crumb.component.css */ "./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.css")).default]
    })
], DdrBreadCrumbComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.scss":
/*!*******************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.scss ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-ddr-bt-trend .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-ddr-bt-trend .s-grid {\n  display: flex;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.ts":
/*!*****************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.ts ***!
  \*****************************************************************************/
/*! exports provided: DdrBtTrendComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrBtTrendComponent", function() { return DdrBtTrendComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! moment */ "./node_modules/moment/moment.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! moment-timezone */ "./node_modules/moment-timezone/index.js");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var highcharts_highcharts_src__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! highcharts/highcharts.src */ "./node_modules/highcharts/highcharts.src.js");
/* harmony import */ var highcharts_highcharts_src__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(highcharts_highcharts_src__WEBPACK_IMPORTED_MODULE_8__);
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _services_ddr_agg_flowmap_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./../../services/ddr-agg-flowmap.service */ "./src/app/pages/ddr/services/ddr-agg-flowmap.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
var DdrBtTrendComponent_1;


















let DdrBtTrendComponent = DdrBtTrendComponent_1 = class DdrBtTrendComponent {
    constructor(commonService, _changeDetection, _cavConfigService, _ddrData, _router, activatedRoute, breadcrumbService, ddrRequest, sessionService, messageService, _DdrAggFlowmapService, breadcrumb, ndDdrHttpService) {
        this.commonService = commonService;
        this._changeDetection = _changeDetection;
        this._cavConfigService = _cavConfigService;
        this._ddrData = _ddrData;
        this._router = _router;
        this.activatedRoute = activatedRoute;
        this.breadcrumbService = breadcrumbService;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.messageService = messageService;
        this._DdrAggFlowmapService = _DdrAggFlowmapService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.highcharts = highcharts_highcharts_src__WEBPACK_IMPORTED_MODULE_8__;
        this.strGraphKey = ''; // graph key
        this.health = '';
        this.isCompare = false;
        this.strCGraphKey = null;
        this.rt = '-1.0';
        this.rtt = '-1';
        this.tps = '-1.0';
        this.tpst = '-1';
        this.es = '-1.0';
        this.est = '-1';
        this.tierFilter = "";
        this.tierToolTip = "";
        this.displayFilterDialog = false; // toggle transaction filters dialog....
        this.graphTab = true; // flag to show accordion selected or not...
        this.showBtGraphs = false; // toggle graph tab for Response Time, TPS, Error/Sec...
        this.headerFilter = ''; // filter criteria...
        this.BtStatHeader = ''; // Accordion header...
        this.timeLabel = ''; // label for selected value from time-filter dropdown
        this.strStartDate = '00/00/00 00:00:00'; // default start time
        this.strEndDate = '00/00/00 23:59:59'; // default end time
        this.display = false; // toggle time filter dialog
        this.timeCompareList = [];
        this.selectedValues = false;
        this.showAutoInstrPopUp = false; // toggle auto inst popup
        this.vectorArray = []; // contains vector name array [Tier, Server, App]
        this.customFilterDisplay = false;
        this.totalCount = 0;
        this.showPagination = true;
        this.showCompare = false;
        this.colorThemes = window['arrColorddr'] || ['#3A99D9', '#F1C330', '#7CB5EC', '#434348'];
        this.BtRequestType = 2; // keyword for request (byDefault request = 2 for post)
        this.enableAggFlowmap = 1;
        this.startIndexForAgg = 0;
        this.lastIndexForAgg = 1000;
        this.loading1 = false;
        this.timeStampArr = []; // timestamp array for each sample
        this.isFilterChanged = false; // flag to check if filter is changed
        this.eventDayFilter = false; // flag to toggle event day filters
        this.commonFilter = false; // flag for common filters to be used for Yesterday, Last Week same days time period...
        this._disabled = false; // flag to disable p-calendar
        this._yearList = []; // year list for event day filter's
        this._eventDaysList = []; // event day list for event day filter
        this._selectedEventDay = ""; // selected event day from event day filter
        this._selectedEventDayYear = ""; // selected year from event day filter
        this._limits = []; // array for number of records to be retrieved
        this._colsOptions = []; // array to sort the data in ascending or descending order btCategory wise...
        this._selectedColumn = ""; // selected column 
        this._txPattern = ""; // shows result based on transaction pattern
        this.isIncDisGraph = true;
        this.isTotalTestRun = true;
        this.showCustomDialogforCompare = false;
        this.count = 0;
        this.countCps = 0;
        this.countEps = 0;
        this.displayBtStatsDialog = false;
        this.startCDate = '';
        this.endCDate = '';
        this.endCSeconds = '';
        this.startCHours = '';
        this.startCMinutes = '';
        this.startCSeconds = '';
        this.endCHours = '';
        this.endCMinutes = '';
        this.breadcrumb = breadcrumb;
        this.activatedRoute.queryParams.subscribe((params) => {
            this.stateID = params['state'];
        });
    }
    setInCommonService(trun) {
        if (trun)
            this.commonService.testRun = trun;
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
        const me = this;
        console.log('Event: ', event);
        const action = (_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action;
        if (((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.action) != 'VIEWFAR') {
            this.checkTransactionCount(event.cavEventExt.row.totalCount);
        }
        switch (action) {
            case "VIEWMTR":
                me.openPieWindow(event.cavEventExt.row);
                break;
            case "VIEWDBR":
                me.openLogAndQuery(event.cavEventExt.row);
                break;
            case "VIEWFAR":
                if (event.cavEventExt.row.bt == 'Others') {
                    alert('Flowpath analysis is not meaningful when it is done for multiple Transactions i.e. "Others". Please select specific transaction for the analysis.');
                }
                else {
                    this.checkTransactionCount(event.cavEventExt.row.totalCount);
                    me.openFPAnalyzer(event.cavEventExt.row);
                }
                break;
            case "VIEWBTIPSR":
                me.openBTIPSummary(event.cavEventExt.row);
                break;
            case "VIEWATFMR":
                me.gettierData(event.cavEventExt.row);
                break;
            case "STARTDD":
                me.openAutoInstDialog(event.cavEventExt.row);
                break;
            case "clickable":
                const keyOrLabel = ((_f = (_e = event.cavEventExt) === null || _e === void 0 ? void 0 : _e.columnClicked) === null || _f === void 0 ? void 0 : _f.key) === 'count'
                    ? (_h = (_g = event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label : (_k = (_j = event.cavEventExt) === null || _j === void 0 ? void 0 : _j.columnClicked) === null || _k === void 0 ? void 0 : _k.key;
                me.openFpReport(event.cavEventExt.row, keyOrLabel);
                break;
            default:
                break;
        }
    }
    checkTransactionCount(totalCount) {
        if (totalCount > 10000) {
            this.messageService.showInfo('As the number of transactions are very high, it may take some time');
        }
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.screenHeight = Number(this.commonService.screenHeight) - 130;
        if (this._ddrData.btTrendParamFromStoreView === undefined) {
            this.id = this.commonService.getData();
            this.setInCommonService(this.id.testRun);
        }
        this._ddrData.ddrThemeChangeUIObservable$.subscribe(() => {
            this.colorThemes = window['arrColorddr'] || ['#3A99D9', '#F1C330', '#7CB5EC', '#434348'];
            setTimeout(() => {
                this.showGraphWithInfo(this.commonService.btTrendRowData);
            }, 1000);
        });
        if (this._router.url.indexOf('/home/ddr/DdrBtTrendComponent') != -1 || this._ddrData.btTrendParamFromStoreView != undefined) {
            this.urlParam = this._ddrData.btTrendParamFromStoreView;
            this.commonService.testRun = this._ddrData.btTrendParamFromStoreView.testRun;
            if (this.urlParam && !this.urlParam.product.startsWith("/"))
                this.urlParam.product = "/" + this.urlParam.product;
            this.vectorArray = this.urlParam.vectorName.split('>');
            this.commonService.dcNameList = this.urlParam.dcNameList;
            this.commonService.selectedDC = this.urlParam.dcName;
            this.commonService.isAllCase = this.urlParam.isAll;
            this.commonService.tierNameList = this.urlParam.tierNameList;
            sessionStorage.setItem("dcNameList", this.urlParam.dcNameList);
            sessionStorage.setItem("tierNameList", this.urlParam.tierNameList);
            sessionStorage.setItem("isAllCase", this.urlParam.isAll);
            this.commonService.enableQueryCaching = this.urlParam.enableQueryCaching;
        }
        else {
            if (this.commonService.paramsForBtTrend != undefined) {
                this.strGraphKey = this.urlParam.strGraphKey;
                this.urlParam = this.commonService.paramsForBtTrend;
            }
            else {
                this.urlParam = this.commonService.getData();
                this.urlParam.vectorName = sessionStorage.getItem('vectorName');
            }
        }
        this.setInCommonService(this.urlParam.testRun);
        let len = Object.keys(this.activatedRoute.snapshot.queryParams);
        if (len.length == 0) {
            this.breadcrumb.add({ label: 'End-To-End', routerLink: '/exec-dashboard/main/tierStatus' });
            this.breadcrumb.add({ label: 'BT Trend', routerLink: '/ddr/DdrBtTrendComponent' });
        }
        else {
            this.breadcrumb.add({ label: 'BT Trend', routerLink: '/ddr/DdrBtTrendComponent', queryParams: { state: this.stateID } });
        }
        if (this.id != undefined) {
            if (this.id.strGraphKey != undefined) {
                this.strGraphKey = this.id.strGraphKey;
            }
        }
        else {
            if (this.urlParam.strGraphKey != undefined) {
                this.strGraphKey = this.urlParam.strGraphKey;
            }
        }
        this.fillData(); // method to fetch bt-trend data...
        this.getVectorIds(); // method to fetch vector id's for Tier, Server and Instance...
    }
    getVectorIds() {
        if (this.vectorArray.length <= 1) {
            return;
        }
        let url;
        if (this.commonService.BtRequestType == 2) {
            const payload = {
                testRun: this.commonService.testRun,
                tierName: this.vectorArray[0],
                serverName: this.vectorArray[1],
                appName: this.vectorArray[2]
            };
            url = this._ddrData.createHostUrl() + '/DashboardServer/v2/ddr/getTierServerAppId';
            return this.ddrRequest.getDataInStringUsingPost(url, payload).subscribe(data => {
                this.getAgentInfo(JSON.parse(data));
            });
        }
    }
    getAgentInfo(res) {
        this.vecId = res;
        const payload = "testRun=" + this.commonService.testRun + "&tierId=" + res.tierId + "&serverId=" + res.serverId + "&appId=" + res.appId;
        this.ndDdrHttpService.getAgentType(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__["AgentTypeLoadedState"]) {
                this.agentType = state.data.agentType;
            }
        });
    }
    openAutoInstDialog(rowData) {
        const payload = { testRun: this.commonService.testRun, tierName: this.urlParam.tierNameList };
        this.ndDdrHttpService.getTRStatus(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__["TestRunStatusLoadedState"]) {
                let res = state.data;
                const testRunStatus = res.data;
                if (testRunStatus.length === 0) {
                    this.showAutoInstrPopUp = false;
                    this.messageService.showError("Could not start instrumentation, test is not running");
                    return;
                }
                this.showAutoInstrPopUp = true;
                let instanceType;
                if (this.agentType.toLowerCase() == 'java')
                    instanceType = 'Java';
                else if (this.agentType.toLowerCase() == 'dotnet')
                    instanceType = 'DotNet';
                else if (this.agentType.toLowerCase() == 'dotnetc')
                    instanceType = 'DotNetC';
                this.argsForAIDDSetting = [this.vectorArray[2], this.vecId.appId, instanceType, this.vectorArray[0], this.vectorArray[1], this.vecId.serverId, '-1', rowData.bt, 'DDR', testRunStatus[0].status, this.commonService.testRun];
            }
        });
    }
    startInstrumentation(result) {
        this.showAutoInstrPopUp = false;
    }
    closeAIDDDialog(isCloseAIDDDialog) {
        this.showAutoInstrPopUp = isCloseAIDDDialog;
    }
    fillData() {
        const EVENT_DAYS = {
            BLACK_FRIDAY: "Black Friday",
            CHRISTMAS_DAY: "Christmas Day",
            CYBER_MONDAY: "Cyber Monday",
            GOOD_FRIDAY: "Good Friday",
            NEW_YEARS_DAY: "New Years Day",
            PRESIDENTS_DAY: "President's Day",
            THANKS_GIVING_DAY: "Thanks Giving Day",
            VALENTINES_DAY: "Valentines Day"
        };
        // Create _eventDaysList array
        this._eventDaysList = Object.values(EVENT_DAYS).map(element => ({ label: element, value: element }));
        // Create _yearList array
        for (let year = 2014; year <= new Date().getFullYear(); year++) {
            this._yearList.push({ label: year.toString(), value: year });
        }
        this._limits = [];
        this._limits = [
            { label: '50', value: 50 },
            { label: '100', value: 100 },
            { label: '150', value: 150 },
            { label: '200', value: 200 }
        ];
        // object that associates each btCategory with its corresponding relativePath and columnOptions(vectorArray length > 1 means it is at instance level)
        const categoryMappings = {
            "VerySlow": {
                relativePath: this.vectorArray.length <= 1 ? "ddr/bt-trend/bt-trend-verySlow.json" : "ddr/bt-trend/bt-trend-verySlow-instance.json",
                columns: [
                    { label: "Very Slow Count", value: "Very Slow Count" },
                    { label: "Very Slow Min(ms)", value: "Very Slow Min(ms)" },
                    { label: "Very Slow Max(ms)", value: "Very Slow Max(ms)" },
                    { label: "Average", value: "Average" }
                ]
            },
            "Normal": {
                relativePath: this.vectorArray.length <= 1 ? "ddr/bt-trend/bt-trend-normal.json" : "ddr/bt-trend/bt-trend-normal-instance.json",
                columns: [
                    { label: "Normal Count", value: "Normal Count" },
                    { label: "Normal Min(ms)", value: "Normal Min(ms)" },
                    { label: "Normal Max(ms)", value: "Normal Max(ms)" },
                    { label: "Average", value: "Average" }
                ]
            },
            "Slow": {
                relativePath: this.vectorArray.length <= 1 ? "ddr/bt-trend/bt-trend-slow.json" : "ddr/bt-trend/bt-trend-slow-instance.json",
                columns: [
                    { label: "Slow Count", value: "Slow Count" },
                    { label: "Slow Min(ms)", value: "Slow Min(ms)" },
                    { label: "Slow Max(ms)", value: "Slow Max(ms)" },
                    { label: "Average", value: "Average" }
                ]
            },
            "Errors": {
                relativePath: this.vectorArray.length <= 1 ? "ddr/bt-trend/bt-trend-error.json" : "ddr/bt-trend/bt-trend-error-instance.json",
                columns: [
                    { label: "Error Count", value: "Error Count" },
                    { label: "Error Min(ms)", value: "Error Min(ms)" },
                    { label: "Error Max(ms)", value: "Error Max(ms)" },
                    { label: "Average", value: "Average" }
                ]
            },
            "All": {
                relativePath: this.vectorArray.length <= 1 ? "ddr/bt-trend/bt-trend-all.json" : "ddr/bt-trend/bt-trend-all-instance.json",
                columns: [
                    { label: "Overall Count", value: "Overall Count" },
                    { label: "Overall TPS", value: "Overall TPS" },
                    { label: "Overall Avg(ms)", value: "Overall Avg(ms)" },
                    { label: "Normal Count", value: "Normal Count" },
                    { label: "Normal Pct(%)", value: "Normal Pct(%)" },
                    { label: "Normal Avg", value: "Normal Avg" },
                    { label: "Slow Count", value: "Slow Count" },
                    { label: "Slow Avg(ms)", value: "Slow Avg(ms)" },
                    { label: "Very Slow Count", value: "Very Slow Count" },
                    { label: "Very Slow Avg(ms)", value: "Very Slow Avg(ms)" },
                    { label: "Error Count", value: "Error Count" },
                    { label: "Error Avg(ms)", value: "Error Avg(ms)" }
                ]
            }
        };
        this._colsOptions = [];
        const categoryMapping = categoryMappings[this.urlParam.btCategory];
        if (categoryMapping) {
            //Handling for "All" category with otelMode
            if (this.urlParam.btCategory === "All" && this._ddrData.otelMode) {
                this.relativePath = this.vectorArray.length <= 1 ?
                    "ddr/bt-trend/bt-trend-all-otel.json" :
                    "ddr/bt-trend/bt-trend-all-instance-otel.json";
            }
            else {
                this.relativePath = categoryMapping.relativePath;
            }
            this._colsOptions.push(...categoryMapping.columns);
        }
        this.setDefaultFilters();
        this.updateDateTime();
        this.getIPData();
        this.setInCommonService(this.urlParam.testRun || this.id.testRun);
    }
    setDefaultFilters() {
        this._limit = this._limits[0].value;
        this._txPattern = "*";
        const categoryMap = {
            extbt: 'Response Time(ms)',
            All: 'Overall Avg(ms)',
            Normal: 'Average',
            Slow: 'Average',
            VerySlow: 'Average',
            Errors: 'Error Count',
        };
        this._selectedColumn = categoryMap[this.urlParam.btCategory] || this._colsOptions[0].value;
    }
    getIPData() {
        this.getAggKeywordData();
        if (this.showCustomDialogforCompare) {
            this.showCustomDialogforCompare = false;
            this.showCompare = true;
        }
        const testRunForObj = this.sessionService.preSession.multiDc ? this.urlParam.testRun : this.commonService.testRun;
        const dcName = this.sessionService.preSession.multiDc ? (this._cavConfigService.getActiveDC() == "ALL" ? this._ddrData.dcName : this._cavConfigService.getActiveDC()) : "";
        this.cacheId = this.commonService.enableQueryCaching == 1 ? testRunForObj : undefined;
        if (this.sessionService.preSession.multiDc) {
            this.getVectorNamesForDC(dcName);
        }
        if (this.commonService.BtRequestType == 2) {
            const obj = {
                cctx: this.sessionService.session.cctx,
                tr: testRunForObj,
                dataFilter: [0, 1, 2, 3, 4, 5, 6],
                pk: null,
                tierName: this.urlParam.tierNameList,
                serverName: this.urlParam.serverName,
                appName: this.urlParam.appName || this.urlParam.instanceName,
                btCategory: this.urlParam.btCategory,
                reqType: "BT",
                reqVecName: this.urlParam.vectorName,
                duration: {
                    st: this.urlParam.strStartTime,
                    et: this.urlParam.strEndTime,
                    preset: this.urlParam.preset,
                    viewBy: 600
                },
                serverType: null,
                alertSevType: null,
                all: false,
                flowMapDir: null,
                flowMapName: null,
                globalRenaming: false,
                goodStore: false,
                gRAPH_KEY: null,
                opType: 11,
                resolution: null,
                storeAlertType: 0,
                storeName: null,
                user: null,
                valueType: null,
                isIncDisGraph: false,
                isCompare: false,
                isAll: false,
                dc: "",
                nonZeroIP: false,
                multiDc: false,
                btName: this.urlParam.btName,
                health: this.health,
                rt: this.rt,
                rtt: this.rtt,
                tps: this.tps,
                tpst: this.tpst,
                es: this.es,
                est: this.est,
                lastIndex: "",
                isPrevious: false,
                getData: false,
                cacheId: this.cacheId,
                txFilter: {
                    "txName": this._txPattern,
                    "top": this._limit,
                    "sortField": this._selectedColumn
                }
            };
            if (this.showCustomDialogforCompare) {
                this.showCustomDialogforCompare = false;
                this.showCompare = true;
            }
            console.log("OBJ FOR BT-Trend", obj);
            this.fetchBtTrendData(obj);
        }
    }
    fetchBtTrendData(obj) {
        this.ndDdrHttpService.getBtTrendData(obj).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__["BtTrendLoadedState"]) {
                this.assignData(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignData(res) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
        try {
            console.log("DdrBtTrendComponent ~ assignData ~ res", res);
            this.eventDateMap = JSON.parse((_a = res === null || res === void 0 ? void 0 : res.tableData) === null || _a === void 0 ? void 0 : _a.eventdaysJson);
            this.timeLabel = this.urlParam.strTimeLabel;
            this.fullJson = res;
            this.startTimetoPass = (_c = (_b = this.fullJson) === null || _b === void 0 ? void 0 : _b.tableData) === null || _c === void 0 ? void 0 : _c.startTimeStamp;
            if (this.isFilterChanged === true) {
                this.timeLabel = this.selectedValue;
            }
            this.isFilterChanged = false;
            if (this.urlParam.btCategory === 'extbt') {
                this.ipData = ((_d = res === null || res === void 0 ? void 0 : res.tableData) === null || _d === void 0 ? void 0 : _d.data) || [];
                this.showPagination = this.ipData.length === 0 ? false : true;
                if (!this.showPagination) {
                    this.showBtGraphs = false;
                    return;
                }
                if (this.urlParam.btName) {
                    this.ipData = this.ipData.filter((row) => row.bt === this.urlParam.btName);
                }
                else {
                    this.ipData = this.ipData.filter((row) => row.bt !== "AllTransactions").filter((row) => row.calls !== 0);
                }
                this.timeStampArr = this.calculateTimeStamps(res);
                this.totalCount = (_e = this.ipData) === null || _e === void 0 ? void 0 : _e.length;
                this.showBtGraphs = true;
                this.showGraphWithInfo(this.ipData[0]);
                this.showBtCompare();
            }
            else if (this.urlParam.btCategory === 'All') {
                let val = ((_f = res === null || res === void 0 ? void 0 : res.tableData) === null || _f === void 0 ? void 0 : _f.data) || [];
                this.showPagination = val.length == 0 ? false : true;
                if (!this.showPagination) {
                    this.ipData = val;
                    return;
                }
                if (this.urlParam.btName) {
                    val = val.filter((row) => row.bt === this.urlParam.btName);
                }
                else {
                    val = val.filter((row) => row.bt !== "AllTransactions").filter((row) => row.totalCount !== 0).filter((row) => row.count !== 0);
                }
                this.totalCount = val === null || val === void 0 ? void 0 : val.length;
                if (!((_h = (_g = this.fullJson) === null || _g === void 0 ? void 0 : _g.tableData) === null || _h === void 0 ? void 0 : _h.timeZone)) {
                    this.fullJson.tableData.timeZone = 'Asia/Kolkata';
                }
                this.ipData = val;
            }
            else {
                this.ipData = ((_j = res === null || res === void 0 ? void 0 : res.tableData) === null || _j === void 0 ? void 0 : _j.data) || [];
                this.showPagination = this.ipData.length == 0 ? false : true;
                if (!this.showPagination) {
                    return;
                }
                if (this.urlParam.btCategory == "VerySlow" || this.urlParam.btCategory == "Slow" || this.urlParam.btCategory == "Errors" || this.urlParam.btCategory == "Normal") {
                    this.ipData = this.ipData.filter(entry => entry.count !== 0);
                }
                if (this.urlParam.btName) {
                    this.ipData = this.ipData.filter((row) => row.bt === this.urlParam.btName);
                }
                else {
                    this.ipData = this.ipData.filter((row) => row.bt !== "AllTransactions").filter((row) => row.totalCount !== 0);
                }
                this.totalCount = (_k = this.ipData) === null || _k === void 0 ? void 0 : _k.length;
                this.showBtGraphs = false;
            }
            this.setTimeRange();
            this.createHeaderFilter();
        }
        catch (error) {
            console.error("Error in response ~ ", error);
            this.commonService.loaderForDdr = false;
        }
    }
    setTimeRange() {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
        var applieTimeKey = this.strGraphKey;
        //Adding the below condition for changing the Time Zone from UI in LRM-A9....
        if (((_b = (_a = this.fullJson) === null || _a === void 0 ? void 0 : _a.tableData) === null || _b === void 0 ? void 0 : _b.startTimeStamp) != 0 && (this.selectedValue != 'Custom Date' || this.selectedValue != 'EventDay')) {
            if (applieTimeKey.toLowerCase().includes("minutes")) {
                let timeInMin = applieTimeKey.split("_")[1];
                this.startTimetoPass = (Number((_d = (_c = this.fullJson) === null || _c === void 0 ? void 0 : _c.tableData) === null || _d === void 0 ? void 0 : _d.endTimeStamp) - Number(timeInMin) * 60 * 1000);
                this.startTime = this.sessionService.convertTimestampIntoFormattedString(Number(this.startTimetoPass), "MM/DD/YYYY HH:mm:ss");
                this.endTime = this.sessionService.convertTimestampIntoFormattedString(Number((_f = (_e = this.fullJson) === null || _e === void 0 ? void 0 : _e.tableData) === null || _f === void 0 ? void 0 : _f.endTimeStamp), "MM/DD/YYYY HH:mm:ss");
            }
            else {
                this.startTimetoPass = (_h = (_g = this.fullJson) === null || _g === void 0 ? void 0 : _g.tableData) === null || _h === void 0 ? void 0 : _h.startTimeStamp;
                this.startTime = this.sessionService.convertTimestampIntoFormattedString(Number(this.startTimetoPass), "MM/DD/YYYY HH:mm:ss");
                this.endTime = this.sessionService.convertTimestampIntoFormattedString(Number((_k = (_j = this.fullJson) === null || _j === void 0 ? void 0 : _j.tableData) === null || _k === void 0 ? void 0 : _k.endTimeStamp), "MM/DD/YYYY HH:mm:ss");
            }
        }
    }
    /**
    * Calculates the timestamp for each sample in the result object and returns an array of timestamps.
    *
    * This method iterates over the samples in the result object's data and computes a series of
    * timestamps based on the start and end times. The buffer time between each sample is calculated
    * by dividing the total time duration by the number of samples. The timestamps are then generated
    * by adding this buffer time to the previous timestamp, starting from the initial start time.
    *
    * @param {any} res - The result object containing the table data with start and end timestamps and sample data.
    * @returns {number[]} - An array of calculated timestamps for each sample.
    */
    calculateTimeStamps(res) {
        var _a;
        const timestamps = [];
        if (!((_a = res.tableData.data[0]) === null || _a === void 0 ? void 0 : _a.resData)) {
            return timestamps;
        }
        const bufferTime = (Number(res.tableData.endTimeStamp) - Number(res.tableData.startTimeStamp)) / res.tableData.data[0].resData.length;
        for (let i = 0; i < res.tableData.data[0].resData.length; i++) {
            const updatedTime = i === 0 ? this.startTimetoPass : timestamps[i - 1] + bufferTime;
            timestamps.push(updatedTime);
        }
        return timestamps;
    }
    getVectorNamesForDC(dcName) {
        try {
            return new Promise((resolve, reject) => {
                var vectorNameList = "";
                var allTierDClistArr;
                var temp;
                if (this.urlParam.tierNameList && this.urlParam.tierNameList.toString().indexOf(",") !== -1) {
                    allTierDClistArr = this.urlParam.tierNameList.split(",");
                    for (var i = 0; i < allTierDClistArr.length; i++) {
                        if (allTierDClistArr[i].startsWith(dcName)) {
                            temp = (allTierDClistArr[i]).substring(dcName.length + 1);
                            vectorNameList += temp + ",";
                        }
                    }
                    if (vectorNameList)
                        this.urlParam.vectorName = vectorNameList;
                }
            });
        }
        catch (e) {
            console.error('Exception in getVectorNamesForDC() ~ ', e);
        }
    }
    changeCompare() {
        if (this.timeLabel == 'Time Period : Whole Scenario') {
            this.isTotalTestRun = true;
        }
        else {
            this.isTotalTestRun = false;
        }
        if (this.selectedValues) {
            this.isCompare = true;
        }
        else {
            this.isCompare = false;
            this.showCompare = false;
            this.isTotalTestRun = true;
            this.selectedCompareTime = null;
            this.getIPData();
        }
    }
    showBtCompare() {
        if (this.timeLabel == "Last 1 Hour") {
            this.timePeriodForCompare = this.timeLabel;
        }
        else {
            this.timePeriodForCompare = this.timeLabel.substring(14, this.timeLabel.length);
        }
        this.timeCompareList = [];
        if (this.timePeriodForCompare == "Today" || this.timePeriodForCompare == "Whole Scenario") {
        }
        else if (this.timePeriodForCompare == "Custom Date") {
            // this.timeCompareList.push({ label: "Specified Time", value: "Compare Custom Date" });
        }
        else if (this.timePeriodForCompare != "Today" || this.timePeriodForCompare != "Whole Scenario") {
            if (this.timePeriodForCompare != "") {
                this.timeCompareList.push({ label: this.timePeriodForCompare, value: this.timePeriodForCompare });
            }
            this.timeCompareList.push({ label: "Specified Time", value: "Compare Custom Date" });
            // this.timeCompareList.push({ label: "Specified Time", value: "Compare Custom Date" });
        }
    }
    getCompareData() {
        if (this.selectedCompareTime.startsWith('Last')) {
            this.strCGraphKey = null;
            this.isCompare = true;
            this.showCompare = false;
            this.getIPData();
        }
        else if (this.selectedCompareTime.startsWith('Compare')) {
            this.showCustomDialogforCompare = true;
        }
    }
    createHeaderFilter() {
        this.headerFilter = '';
        let dcName = '';
        if (this.sessionService.preSession.multiDc) {
            dcName = this._cavConfigService.getActiveDC();
            if (dcName === 'ALL') {
                dcName = this._ddrData.dcName;
            }
        }
        if (this.urlParam.tierNameList.length > 45) {
            const tierAfterSub = this.urlParam.tierNameList.substring(0, 45) + '...';
            this.tierToolTip = this.urlParam.tierNameList;
            this.tierFilter = `Tier=${tierAfterSub}`;
        }
        else {
            this.headerFilter += `Tier=${this.urlParam.tierNameList}`;
        }
        if (this.urlParam.serverName && this.urlParam.appName) {
            this.headerFilter += `, Server=${this.urlParam.serverName}, Instance=${this.urlParam.instanceName || this.urlParam.appName}`;
        }
        if (this.startTime && this.endTime) {
            this.headerFilter += `, Start Date/Time=${this.startTime}, End Date/Time=${this.endTime}`;
        }
        this.headerFilter += `, BT Type=${this.urlParam.btCategory === 'All' || this.urlParam.btCategory === 'extbt' ? 'All' : this.urlParam.btCategory}`;
        if (this.urlParam.btName) {
            this.headerFilter += `, BT Name=${this.urlParam.btName}`;
        }
        else {
            if (this._txPattern && this._txPattern != '*') {
                this.headerFilter += `, BT by Name=${this._txPattern}`;
            }
            if (this._limit) {
                this.headerFilter += `, Top=${this._limit}`;
            }
            if (this._selectedColumn) {
                this.headerFilter += `, BT by=${this._selectedColumn}`;
            }
        }
        if (this.headerFilter.endsWith(',')) {
            this.headerFilter = this.headerFilter.slice(0, -1);
        }
    }
    /**
    * Creates chart data from the given node array by combining each node value with the corresponding timestamp.
    *
    * This method iterates over the node array and constructs an array of arrays, where each inner array contains
    * a timestamp and the corresponding node value.
    *
    * @param {any[]} node - An array of node values to be combined with timestamps.
    * @returns {any[]} - An array of arrays, each containing a timestamp and the corresponding node value.
    */
    createChartData(node) {
        const seriesArray = [];
        node.forEach((value, index) => {
            seriesArray.push([this.timeStampArr[index], value]);
        });
        return seriesArray;
    }
    createCompareChartData(node) {
        if (!this.isCompare) {
            return [];
        }
        const strCSeriesData = JSON.stringify(node);
        //Plotting Compare Data
        if ("\"[undefined]\"" != strCSeriesData) {
            // node = JSON.parse(node);
            var cseriesArray = new Array();
            for (var i = 0; i < node.length; i++) {
                var dataArray = new Array();
                dataArray.push(this.fullJson.ctsArray[i]);
                dataArray.push(node[i]);
                cseriesArray.push(dataArray);
            }
            return cseriesArray;
        }
    }
    onClickshowGraphWithInfo(event) {
        let node = event;
        this.showGraphWithInfo(node);
    }
    showGraphWithInfo(node) {
        if (node != undefined && node != "undefined") {
            this.commonService.btTrendRowData = node;
        }
        this.graphTab = true;
        let rowData = this.fullJson;
        let resseriesOptions = [];
        let callseriesOptions = [];
        let errseriesOptions = [];
        this.BtStatHeader = "BT Stats - " + node.bt;
        resseriesOptions.push({ 'type': 'line', 'data': this.createChartData(node.resData) });
        callseriesOptions.push({ 'type': 'line', 'data': this.createChartData(node.callData) });
        errseriesOptions.push({ 'type': 'line', 'data': this.createChartData(node.errorData) });
        if (this.selectedCompareTime) {
            resseriesOptions.push({ 'type': 'line', 'data': this.createCompareChartData(node.cResData), 'xAxis': 1, 'color': this.colorThemes[2] });
            callseriesOptions.push({ 'type': 'line', 'data': this.createCompareChartData(node.cCallData), 'xAxis': 1, 'color': this.colorThemes[2] });
            errseriesOptions.push({ 'type': 'line', 'data': this.createCompareChartData(node.cErrorData), 'xAxis': 1, 'color': this.colorThemes[2] });
        }
        let that = this;
        var xAxisObj = [];
        this.count = 0;
        this.countCps = 0;
        this.countEps = 0;
        xAxisObj = [{
                type: 'time',
                labels: {
                    formatter: function () {
                        var _a;
                        return moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.value, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("HH:mm:ss");
                    },
                    style: {
                        fontSize: '10px'
                    }
                }
            }];
        if (this.selectedCompareTime) {
            xAxisObj.push({
                type: 'time',
                opposite: true,
                labels: {
                    formatter: function () {
                        var _a;
                        return moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.value, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("HH:mm:ss");
                    },
                    style: {
                        fontSize: '10px'
                    }
                },
                tickInterval: 100
            });
        }
        this.options1 = {
            chart: {
                height: 200,
                width: 290,
                responsive: true,
                zoomType: 'x',
                backgroundColor: 'transparent',
                style: {
                    fontFamily: "'Roboto', sans-serif"
                }
            },
            credits: {
                enabled: false
            },
            plotOptions: {
                series: {
                    color: this.colorThemes[1]
                }
            },
            title: {
                text: 'Response Time (ms)',
                style: {
                    fontSize: '12px',
                    fontFamily: "'Roboto', sans-serif",
                    fontWeight: '500',
                    color: this.colorThemes[3]
                }
            },
            tooltip: {
                formatter: function () {
                    var _a;
                    return '<b>Time: </b>'
                        + moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.x, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("MM/DD/YY HH:mm:ss")
                        + '<br/ ><b>Value: ' + '</b>'
                        + this.y;
                }
            },
            legend: {
                itemStyle: {
                    color: 'rgb(29, 181, 18)',
                    fontWeight: '500',
                    fontSize: '10px'
                },
                itemHoverStyle: {
                    color: 'rgb(29, 220, 20)'
                },
                itemDistance: 5,
                padding: 0,
                margin: 0,
                labelFormatter: function labelFormatterFun() {
                    return that.formatterForResponse(node);
                }
            },
            exporting: {
                enabled: false
            },
            xAxis: xAxisObj,
            yAxis: {
                title: {
                    text: null,
                },
            },
            series: resseriesOptions
        };
        this.options2 = {
            chart: {
                height: 200,
                width: 290,
                responsive: true,
                zoomType: 'x',
                backgroundColor: 'transparent',
                style: {
                    fontFamily: "'Roboto', sans-serif"
                }
            },
            credits: {
                enabled: false
            },
            title: {
                text: 'TPS',
                style: {
                    fontSize: '12px',
                    fontFamily: "'Roboto', sans-serif",
                    fontWeight: '500',
                    color: this.colorThemes[3]
                }
            },
            tooltip: {
                formatter: function () {
                    var _a;
                    return '<b>Time: </b>'
                        + moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.x, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("MM/DD/YY HH:mm:ss")
                        + '<br/ ><b>Value: ' + '</b>'
                        + this.y;
                }
            },
            plotOptions: {
                series: {
                    color: this.colorThemes[1]
                }
            },
            legend: {
                itemStyle: {
                    color: 'rgb(29, 181, 18)',
                    fontWeight: '500',
                    fontSize: '10px'
                },
                itemHoverStyle: {
                    color: 'rgb(29, 220, 20)'
                },
                itemDistance: 5,
                padding: 0,
                margin: 0,
                labelFormatter: function labelFormatterFun() {
                    return that.formatterForCps(node);
                }
            },
            exporting: {
                enabled: false
            },
            xAxis: xAxisObj,
            yAxis: {
                title: {
                    text: null,
                },
            },
            series: callseriesOptions
        };
        this.options3 = {
            chart: {
                height: 200,
                width: 290,
                reponsive: true,
                zoomType: 'x',
                backgroundColor: 'transparent',
                style: {
                    fontFamily: "'Roboto', sans-serif"
                }
            },
            credits: {
                enabled: false
            },
            title: {
                text: 'Error/Sec',
                style: {
                    fontSize: '12px',
                    fontFamily: "'Roboto', sans-serif",
                    fontWeight: '500',
                    color: this.colorThemes[3]
                }
            },
            plotOptions: {
                series: {
                    color: this.colorThemes[1]
                }
            },
            xAxis: xAxisObj,
            yAxis: {
                title: {
                    text: null,
                },
            },
            tooltip: {
                formatter: function () {
                    var _a;
                    return '<b>Time: </b>'
                        + moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.x, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("MM/DD/YY HH:mm:ss")
                        + '<br/ ><b>Value: ' + '</b>'
                        + this.y;
                }
            },
            exporting: {
                enabled: false
            },
            legend: {
                itemStyle: {
                    color: 'rgb(29, 181, 18)',
                    fontWeight: '500',
                    fontSize: '10px'
                },
                itemHoverStyle: {
                    color: 'rgb(29, 220, 20)'
                },
                itemDistance: 5,
                padding: 0,
                margin: 0,
                labelFormatter: function labelFormatterFun() {
                    return that.formatterForEps(node);
                }
            },
            series: errseriesOptions
        };
        setTimeout(() => {
            this.getPieChart('piechartid', node.normalPct, node.slowPct, node.vslowPct, node.errorPct);
        }, 200);
    }
    // Formats response options for a particular metric
    formatterForResponse(resseriesOptions) {
        const formatter = (max, avg) => ` Max : ${Number(max).toFixed(1)}    Avg : ${Number(avg).toFixed(1)} `;
        if (this.count === 0) {
            this.count++;
            return formatter(resseriesOptions.resMax, resseriesOptions.res);
        }
        else {
            return formatter(resseriesOptions.cResMax, resseriesOptions.cRes);
        }
    }
    // Formats response options for CPS (Calls Per Second)
    formatterForCps(resseriesOptions) {
        const formatter = (max, avg) => ` Max : ${Number(max).toFixed(1)}    Avg : ${Number(avg).toFixed(1)} `;
        if (this.countCps === 0) {
            this.countCps++;
            return formatter(resseriesOptions.cpsMax, resseriesOptions.cps);
        }
        else {
            return formatter(resseriesOptions.cCpsMax, resseriesOptions.cCps);
        }
    }
    // Formats response options for EPS (Errors Per Second)
    formatterForEps(resseriesOptions) {
        const formatter = (max, avg) => ` Max : ${Number(max).toFixed(1)}    Avg : ${Number(avg).toFixed(1)} `;
        if (this.countEps === 0) {
            this.countEps++;
            return formatter(resseriesOptions.epsMax, resseriesOptions.eps);
        }
        else {
            return formatter(resseriesOptions.cEpsMax, resseriesOptions.cEps);
        }
    }
    openBTTrendPopup(rowData) {
        this.displayBtStatsDialog = true;
        this.loading1 = true;
        setTimeout(() => {
            var filterTitle = this.getFilterTitle(rowData.bt, rowData.health, rowData.res, rowData.calls, rowData.tps, rowData.eps, rowData.tier, rowData.server, rowData.instance, rowData.normalCount, rowData.normalAvg, rowData.normalPct, rowData.slowCount, rowData.slowAvg, rowData.slowPct, rowData.vslowCount, rowData.vslowAvg, rowData.vslowPct, rowData.errorCount, rowData.errorAvg, rowData.errorPct);
            document.getElementById('pieTable').innerHTML = filterTitle;
            this.addClickListenerToTable(rowData);
        }, 4000);
    }
    addClickListenerToTable(rowData) {
        const categoryArr = ['normal', 'slow', 'veryslow', 'error', 'total'];
        const openTransactionTracing = (category) => {
            this.openTransactionTracingForSpecific(rowData.tier, rowData.server, (rowData.app || rowData.instance), rowData.bt, category);
        };
        for (let i = 0; i < categoryArr.length; i++) {
            const elm = document.getElementById(categoryArr[i]);
            if (elm !== null && elm !== undefined) {
                elm.addEventListener("click", () => {
                    openTransactionTracing(categoryArr[i].charAt(0).toUpperCase() + categoryArr[i].slice(1));
                });
            }
        }
        this.loading1 = false;
    }
    getPieChart(id, normalPct, slowPct, vslowPct, errorPct) {
        var colorArray = Array();
        var piechartArray = new Array();
        piechartArray[0] = new Array(3);
        piechartArray[0][0] = "Normal";
        piechartArray[0][1] = parseFloat(normalPct);
        piechartArray[0][2] = "#50B432";
        piechartArray[1] = new Array(3);
        piechartArray[1][0] = "Slow";
        piechartArray[1][1] = parseFloat(slowPct);
        piechartArray[1][2] = "#330066";
        piechartArray[2] = new Array(3);
        piechartArray[2][0] = "Very Slow";
        piechartArray[2][1] = parseFloat(vslowPct);
        piechartArray[2][2] = "#FF6600";
        piechartArray[3] = new Array(3);
        piechartArray[3][0] = "Error";
        piechartArray[3][1] = parseFloat(errorPct);
        piechartArray[3][2] = "#F00";
        for (var i = 0; i < piechartArray.length; i++) {
            colorArray[i] = piechartArray[i][2];
        }
        highcharts_highcharts_src__WEBPACK_IMPORTED_MODULE_8__["setOptions"]({
            colors: colorArray
        });
        var chart = new highcharts_highcharts_src__WEBPACK_IMPORTED_MODULE_8__["Chart"]({
            navigation: {
                buttonOptions: {
                    enabled: false
                }
            },
            chart: {
                renderTo: 'piechartid',
                backgroundColor: null,
                height: 200,
                style: {
                    fontFamily: "'Roboto', sans-serif"
                }
            },
            title: {
                text: null,
                style: {
                    color: "#000",
                    fontSize: '11px',
                    fontWeight: '500',
                    fontFamily: "'Roboto', sans-serif"
                }
            },
            tooltip: {
                formatter: function () {
                    return " BT Category  : <b>" + this.point['name']
                        + "</b> <br></br>Percentage : <b>"
                        + this.point.y + "</b>";
                }
            },
            credits: {
                enabled: false
            },
            plotOptions: {
                pie: {
                    allowPointSelect: true,
                    cursor: 'pointer',
                    size: 100,
                    dataLabels: {
                        enabled: true,
                        style: {
                            fontWeight: '500',
                            fontSize: '12px',
                            textShadow: false,
                            textOutline: false + '',
                            color: this.colorThemes[3] + ''
                        },
                        format: '<b style = "fontWeight:500;">{point.name}</b>: {point.y} %'
                    },
                    shadow: false,
                }
            },
            series: [{
                    type: 'pie',
                    name: "BT Category",
                    data: piechartArray,
                }]
        });
    }
    getFilterTitle(bt, health, resp, calls, tps, eps, tier, server, instance, normalCount, normalAvg, normalPct, slowCount, slowAvg, slowPct, vslowCount, vslowAvg, vslowPct, errorCount, errorAvg, errorPct) {
        try {
            this.popupHealthIcon = health;
            var htmlText = '';
            var htmlTextforflter = "<span style='font-size:11px;'><b >BT:  </b>";
            if (bt.length > 25) {
                var btsort = bt.substring(0, 22) + "...";
                htmlTextforflter += "<span title=" + bt + ">" + btsort + "</span>";
            }
            else {
                htmlTextforflter += "<span title=" + bt + ">" + bt + "</span>";
            }
            if (server != undefined && instance != undefined)
                htmlTextforflter = +" <b>Tier:</b>" +
                    "<span title='" + tier + "'>" + tier + "</span>" + "<b style='padding-left:3px;'> Server:  </b>" +
                    "<span title='" + server + "'>" + server + "</span>" + "<b style='padding-left:3px;'>Instance:  </b>" +
                    "<span title='" + instance + "'>" + instance + "</span>" + "<b style='padding-left:3px;'> From: </b>" +
                    "<span title='" + this.startTime + "'>" + this.startTime + "</span>" + "<b style='padding-left:3px;'> To: </b>" +
                    "<span title='" + this.endTime + "'>" + this.endTime + "</span>";
            else
                htmlTextforflter += " <b >Tier:</b>" +
                    "<span title='" + tier + "'>" + tier + "</span>" + "<b style='padding-left:3px;'> From: </b>" +
                    "<span title='" + this.startTime + "'>" + this.startTime + "</span>" + "<b style='padding-left:3px;'> To: </b>" +
                    "<span title='" + this.endTime + "'>" + this.endTime + "</span>";
            document.getElementById('filter').innerHTML = htmlTextforflter;
            htmlText += "<div style='display:table;'><div style='width:100% !important;float:right;margin-top: 10px;'><table width='100%' style='height:220px;width:500px' class='newGuiTable'><thead><tr class='info headerImage' style='font-size:10px; white-space:nowrap;height: 38px;'><th style='text-align:left;font-size:12px'>BT Category</th><th style='text-align:right;font-size:12px'>Count</th><th style='text-align:right;font-size:12px'>Response Time (ms)</th><th style='text-align:right;font-size:12px'>Pct(%)</th></tr></thead><tbody >";
            if (Number(normalCount) != 0)
                htmlText += "<tr style='font-size:10px; white-space:nowrap;'><td sty>Normal</td><td style='text-align:right'><a style='text-align:right;color:blue;cursor:pointer' id='normal' title='View Flowpath'>"
                    + Number(normalCount).toLocaleString()
                    + "</a></td><td style='text-align:right'>"
                    + Number(normalAvg).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + normalPct
                    + "</td></tr>";
            else
                htmlText += "<tr style='font-size:10px; white-space:nowrap;'><td>Normal</td><td style='text-align:right'>"
                    + Number(normalCount).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + Number(normalAvg).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + normalPct
                    + "</td></tr>";
            if (Number(slowCount) != 0)
                htmlText += "<tr style='font-size:10px; white-space:nowrap;background-color:#f9f9f9;'><td>Slow</td><td style='text-align:right'><a id='slow' style='color:blue;cursor:pointer' title='View Flowpath'>"
                    + Number(slowCount).toLocaleString()
                    + "</a></td><td style='text-align:right'>"
                    + Number(slowAvg).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + slowPct
                    + "</td></tr>";
            else
                htmlText += "<tr style='font-size:10px; white-space:nowrap;background-color:#f9f9f9;'><td>Slow</td><td style='text-align:right'>"
                    + Number(slowCount).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + Number(slowAvg).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + slowPct
                    + "</td></tr>";
            if (Number(vslowCount) != 0)
                htmlText += "<tr style='font-size:10px; white-space:nowrap;'><td>Very Slow</td><td style='text-align:right'  ><a id='veryslow' title='View Flowpath' style='cursor:pointer;color:blue'>"
                    + Number(vslowCount).toLocaleString()
                    + "</a></td><td style='text-align:right'>"
                    + Number(vslowAvg).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + vslowPct
                    + "</td></tr>";
            else
                htmlText += "<tr style='font-size:10px; white-space:nowrap;'><td>Very Slow</td><td style='text-align:right'>"
                    + Number(vslowCount).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + Number(vslowAvg).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + vslowPct
                    + "</td></tr>";
            if (Number(errorCount) != 0)
                htmlText += "<tr><td>Errors</td><td style='text-align:right' ><a id='error' title='View Flowpath'  style='cursor:pointer;color:blue'>"
                    + Number(errorCount).toLocaleString()
                    + "</a></td><td style='text-align:right'></a>"
                    + Number(errorAvg).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + errorPct
                    + "</td></tr>";
            else
                htmlText += "<tr><td>Errors</td><td style='text-align:right'>"
                    + Number(errorCount).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + Number(errorAvg).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + errorPct
                    + "</td></tr>";
            if (Number(calls) != 0)
                htmlText += "<tr class='tableHighLight' style='font-size:10px; font-weight: bold;'><td>Overall</td><td style='text-align:right' ><a id='total'style='color:blue;cursor:pointer' title='View Flowpath'>"
                    + Number(calls).toLocaleString()
                    + "</a></td><td style='text-align:right'>"
                    + Number(resp).toLocaleString()
                    + "</td><td style='text-align:right'>100</td></tr></tbody></table></div>";
            else
                htmlText += "<tr class='tableHighLight' style='font-size:10px; font-weight: bold;'><td>Overall</td><td style='text-align:right'>"
                    + Number(calls).toLocaleString()
                    + "</td><td style='text-align:right'>"
                    + Number(resp).toLocaleString()
                    + "</td><td style='text-align:right'>100</td></tr></tbody></table></div>";
            htmlText += "<div style='width:50%;max-height:170px;max-width:50%;float:left' id='piechartid' ></div></div>";
            return htmlText;
        }
        catch (error) {
            console.error("Error in creating table ~ ", error);
            return "";
        }
    }
    capitalise(string) {
        return string.charAt(0).toUpperCase() + string.slice(1).toLowerCase();
    }
    openFpReport(rowData, btName) {
        var _a, _b;
        this.commonService.spinner = true;
        this.commonService.isFilterFromSideBar = false;
        this._ddrData.IPByFPFlag = false;
        this._ddrData.cmdArgsFlag = false;
        if (this.urlParam.appName) {
            rowData.server = this.urlParam.serverName;
            rowData.instance = this.urlParam.appName;
        }
        const btMap = {
            'totalcount': 'all',
            'normalcount': 'Normal',
            'slowcount': 'Slow',
            'vslowcount': 'VerySlow',
            'errorcount': 'Errors'
        };
        let bt = 'NA';
        if (this.urlParam.btCategory == 'All') {
            bt = btMap[btName.toLowerCase()];
        }
        else {
            if (btName === 'Very Slow Count')
                btName = 'vslowcount';
            bt = btMap[btName.toLowerCase().replace(/ /g, '')];
        }
        let btCategoryId = "";
        if (bt.toUpperCase() != "ALL")
            btCategoryId = this.getBTCategoryId(bt);
        let jsonstartTimeStamp = this.startTimetoPass;
        let jsonendTimeStamp = (_b = (_a = this.fullJson) === null || _a === void 0 ? void 0 : _a.tableData) === null || _b === void 0 ? void 0 : _b.endTimeStamp;
        let strGraphKey = this.strGraphKey;
        this.urlParam.strTimeLabel = this.timeLabel;
        if (strGraphKey.toLowerCase() === "wholescenario") {
            jsonstartTimeStamp = "NA";
            jsonendTimeStamp = "NA";
        }
        this._ddrData.testRun = this.commonService.testRun;
        this._ddrData.tierName = rowData.tier;
        this._ddrData.serverName = rowData.server;
        this._ddrData.appName = rowData.instance;
        this._ddrData.startTime = jsonstartTimeStamp;
        this._ddrData.endTime = jsonendTimeStamp;
        this._ddrData.vecArrForGraph = [];
        this._ddrData.urlName = rowData.bt;
        this._ddrData.btCategory = btCategoryId;
        this._ddrData.valueForCheckBox = 'true';
        this._ddrData.product = this.urlParam.product.toString().includes("/") ? this.urlParam.product.replace("/", "") : this.urlParam.product;
        if (this.commonService.enableQueryCaching) {
            this._ddrData.enableQueryCaching = this.commonService.enableQueryCaching;
        }
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_10__["BREADCRUMB_ITEMS"].BTTREND;
        this.commonService.removeAllComponentFromFlowpath();
        this._changeDetection.detectChanges();
        this._ddrData.isFromtrxFlow = false;
        this._ddrData.isFromtrxSideBar = false;
        this.commonService.spinner = false;
        this._ddrData.setInLogger('DDR::Bt Trend::Flowpath', 'Flowpath', 'Open Flowpath Report');
        this._router.navigate([this.getRoutePath() + '/flowpath'], { state: { btTrend: true } });
    }
    getBTCategoryId(btCategory) {
        return DdrBtTrendComponent_1.btType[btCategory] || "";
    }
    splitVectorId(vectorId) {
        return vectorId.trim().split(":");
    }
    openPieWindow(rowData) {
        var _a, _b;
        this.commonService.spinner = true;
        this.commonService.isFilterFromSideBar = false;
        this.urlParam.strTimeLabel = this.timeLabel;
        let strGraphKey = this.urlParam.strGraphKey;
        let jsonstartTimeStamp = this.startTimetoPass;
        let jsonendTimeStamp = (_b = (_a = this.fullJson) === null || _a === void 0 ? void 0 : _a.tableData) === null || _b === void 0 ? void 0 : _b.endTimeStamp;
        if (strGraphKey.toLowerCase() == "wholescenario") {
            jsonstartTimeStamp = "NA";
            jsonendTimeStamp = "NA";
        }
        let btCategory = this.urlParam.btCategory;
        if (btCategory != "All") {
            this._ddrData.btCategory = this.getBTCategoryId(btCategory);
        }
        this._ddrData.testRun = this.commonService.testRun;
        this._ddrData.tierName = rowData.tier;
        this._ddrData.serverName = rowData.server;
        this._ddrData.appName = rowData.instance;
        this._ddrData.startTime = jsonstartTimeStamp;
        this._ddrData.endTime = jsonendTimeStamp;
        this._ddrData.vecArrForGraph = [];
        this._ddrData.urlName = rowData.bt;
        this._ddrData.product = this.urlParam.product.toString().includes("/") ? this.urlParam.product.replace("/", "") : this.urlParam.product;
        if (this.commonService.enableQueryCaching) {
            this._ddrData.enableQueryCaching = this.commonService.enableQueryCaching;
        }
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_10__["BREADCRUMB_ITEMS"].BTTREND;
        this._ddrData.setInLogger('DDR::Bt Trend::Method Timng', 'Method Timing', 'Open Method Timing Report');
        this.commonService.spinner = false;
        this._router.navigate([this.getRoutePath() + '/methodtiming']);
    }
    openLogAndQuery(rowData) {
        var _a, _b;
        this.commonService.spinner = true;
        this.commonService.isFilterFromSideBar = false;
        var strGraphKey = this.urlParam.strGraphKey;
        this.urlParam.strTimeLabel = this.timeLabel;
        var jsonstartTimeStamp = this.startTimetoPass;
        var jsonendTimeStamp = (_b = (_a = this.fullJson) === null || _a === void 0 ? void 0 : _a.tableData) === null || _b === void 0 ? void 0 : _b.endTimeStamp;
        if (strGraphKey.toLowerCase() == "wholescenario") {
            jsonstartTimeStamp = "NA";
            jsonendTimeStamp = "NA";
        }
        this._ddrData.testRun = this.commonService.testRun;
        this._ddrData.tierName = rowData.tier;
        this._ddrData.startTime = jsonstartTimeStamp;
        this._ddrData.endTime = jsonendTimeStamp;
        this._ddrData.vecArrForGraph = [];
        this._ddrData.urlName = rowData.bt;
        this._ddrData.product = this.urlParam.product.toString().includes("/") ? this.urlParam.product.replace("/", "") : this.urlParam.product;
        if (this.commonService.enableQueryCaching) {
            this._ddrData.enableQueryCaching = this.commonService.enableQueryCaching;
        }
        this.commonService.isFromBTTrend = true;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_10__["BREADCRUMB_ITEMS"].BTTREND;
        this.commonService.spinner = false;
        this._ddrData.setInLogger('DDR::Bt Trend::DB Queries', 'Db Queries', 'Open Db Queries Report ');
        this._router.navigate([this.getRoutePath() + '/dbReport']);
    }
    openFPAnalyzer(rowData) {
        var _a, _b;
        this.commonService.spinner = true;
        let btCategory = this.urlParam.btCategory;
        let strGraphKey = this.urlParam.strGraphKey;
        this.urlParam.strTimeLabel = this.timeLabel;
        let jsonstartTimeStamp = this.startTimetoPass;
        let jsonendTimeStamp = (_b = (_a = this.fullJson) === null || _a === void 0 ? void 0 : _a.tableData) === null || _b === void 0 ? void 0 : _b.endTimeStamp;
        if (strGraphKey.toLowerCase() == "wholescenario") {
            jsonstartTimeStamp = "NA";
            jsonendTimeStamp = "NA";
        }
        let btCategoryId = "";
        if (btCategory.toUpperCase() != "ALL")
            btCategoryId = this.getBTCategoryId(btCategory);
        const obj = {};
        obj['testRun'] = this.commonService.testRun;
        obj['tierName'] = this.urlParam.tierName;
        obj['startTime'] = jsonendTimeStamp;
        obj['urlName'] = rowData.bt;
        obj['product'] = this.urlParam.product;
        obj['btCatagory'] = btCategoryId;
        obj['endTime'] = jsonendTimeStamp;
        obj['strGraphKey'] = strGraphKey;
        this.commonService.fpAnalyzeData = obj;
        this._ddrData.btCategory = btCategoryId;
        this._ddrData.testRun = this.commonService.testRun;
        this._ddrData.tierName = rowData.tier;
        this._ddrData.startTime = jsonstartTimeStamp;
        this._ddrData.endTime = jsonendTimeStamp;
        this._ddrData.strGraphKey = strGraphKey;
        this._ddrData.urlName = rowData.bt;
        this._ddrData.vecArrForGraph = [];
        this._ddrData.product = this.urlParam.product.toString().includes("/") ? this.urlParam.product.replace("/", "") : this.urlParam.product;
        if (this.commonService.enableQueryCaching) {
            this._ddrData.enableQueryCaching = this.commonService.enableQueryCaching;
        }
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_10__["BREADCRUMB_ITEMS"].BTTREND;
        this.commonService.spinner = false;
        this._ddrData.setInLogger('DDR::Bt Trend::Flowpath Analyzer', 'Flowpath Analyzer', 'Open Flowpath Analyzer Report');
        this._router.navigate([this.getRoutePath() + '/flowpathAnalyzer']);
    }
    openTransactionTracingForSpecific(tier, server, app, btName, btCategory) {
        var _a, _b;
        this.commonService.spinner = true;
        this.commonService.isFilterFromSideBar = false;
        let btCategoryId = "";
        if (btCategory.toUpperCase() != "ALL")
            btCategoryId = this.getBTCategoryId(btCategory);
        let jsonstartTimeStamp = this.startTimetoPass;
        let jsonendTimeStamp = (_b = (_a = this.fullJson) === null || _a === void 0 ? void 0 : _a.tableData) === null || _b === void 0 ? void 0 : _b.endTimeStamp;
        let strGraphKey = this.strGraphKey;
        if (strGraphKey.toLowerCase() == "wholescenario") {
            jsonstartTimeStamp = "NA";
            jsonendTimeStamp = "NA";
        }
        this._ddrData.testRun = this.commonService.testRun;
        this._ddrData.tierName = tier;
        this._ddrData.startTime = jsonstartTimeStamp;
        this._ddrData.endTime = jsonendTimeStamp;
        this._ddrData.vecArrForGraph = [];
        this._ddrData.urlName = btName;
        this._ddrData.btCategory = btCategoryId;
        this._ddrData.product = this.urlParam.product.toString().includes("/") ? this.urlParam.product.replace("/", "") : this.urlParam.product;
        if (this.commonService.enableQueryCaching) {
            this._ddrData.enableQueryCaching = this.commonService.enableQueryCaching;
        }
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_10__["BREADCRUMB_ITEMS"].BTTREND;
        this.commonService.removeAllComponentFromFlowpath();
        this._ddrData.isFromtrxFlow = false;
        this._ddrData.isFromtrxSideBar = false;
        this.commonService.spinner = false;
        this._ddrData.setInLogger('DDR::Bt Trend::Flowpath', 'Flowpath', 'Open Flowpath Report ');
        this._router.navigate([this.getRoutePath() + '/flowpath']);
    }
    formatter(val) {
        return val.toLocaleString();
    }
    formatterCPS(val) {
        return val.toFixed(2);
    }
    displayFilter() {
        this.displayFilterDialog = true;
        this.rt = '-1.0';
        this.rtt = '-1';
        this.tps = '-1.0';
        this.tpst = '-1';
        this.es = '-1.0';
        this.est = '-1';
    }
    applyFilter() {
        this.displayFilterDialog = false;
        this.getIPData();
    }
    applyDefaultValue() {
        this.rt = '-1.0';
        this.rtt = '-1';
        this.tps = '-1.0';
        this.tpst = '-1';
        this.es = '-1.0';
        this.est = '-1';
        this.urlParam.btName = "";
        this.displayFilterDialog = false;
        this.getIPData();
    }
    onTabClose(event) {
        this.graphTab = false;
    }
    onTabOpen(event) {
        this.graphTab = true;
    }
    fillDateTime() {
        let tmpStrStarDate = this.strStartDate.split(" ");
        let tmpStrStarTime = tmpStrStarDate[1].split(":");
        let tmpStrEndDate = this.strEndDate.split(" ");
        let tmpStrEndTime = tmpStrEndDate[1].split(":");
        this.startHours = tmpStrStarTime[0];
        this.startMinutes = tmpStrStarTime[1];
        this.startSeconds = tmpStrStarTime[2];
        this.endHours = tmpStrEndTime[0];
        this.endMinutes = tmpStrEndTime[1];
        this.endSeconds = tmpStrEndTime[2];
    }
    dateAjaxCall(eventDay, eventYear) {
        const url = `${this._ddrData.createHostUrl()}/dashboard/view/eventDay.jsp?eventDay=${eventDay}&year=${eventYear}`;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => {
            const response = data.trim();
            const eventDate = new Date(response);
            const currentDate = new Date();
            if (eventDate <= currentDate) {
                this.startDate = response;
                this.endDate = response;
                this.fillDateTime();
            }
            else {
                this.messageService.showInfo("Data is not available for " + eventDay + " " + eventYear);
                return;
            }
        });
    }
    updateDateTime() {
        // Get the current date and time in the timezone stored in sessionStorage
        const d = new Date(moment__WEBPACK_IMPORTED_MODULE_6__().tz(sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss'));
        // Format the current date and time
        this.currDateTime = this.getDateFormat(d);
        // Update the date and time every second
        setTimeout(() => {
            this.updateDateTime();
        }, 1000);
    }
    getDateFormat(date) {
        let day = date.getDate();
        let month = date.getMonth() + 1; // January is 0!
        const year = date.getFullYear();
        let hour = date.getHours();
        let mins = date.getMinutes();
        let secs = date.getSeconds();
        // Add leading zeros if necessary
        if (day < 10) {
            day = '0' + day;
        }
        if (month < 10) {
            month = '0' + month;
        }
        if (hour < 10) {
            hour = '0' + hour;
        }
        if (mins < 10) {
            mins = '0' + mins;
        }
        if (secs < 10) {
            secs = '0' + secs;
        }
        return month + '/' + day + '/' + year + " " + hour + ":" + mins + ":" + secs;
    }
    openDateFilter(event) {
        var value = event.value;
        this.openDateFilterOnEventDay(value);
    }
    openDateFilterOnEventDay(value) {
        switch (value) {
            case "EventDay":
                const defaultEventDay = this._eventDaysList[0].value;
                const defaultEventYear = this._yearList[0].value;
                this.dateAjaxCall(defaultEventDay, defaultEventYear);
                this._disabled = true;
                this.customFilterDisplay = false;
                this.commonFilter = true;
                this.eventDayFilter = true;
                this._selectedEventDay = defaultEventDay; // Select the default event day
                this._selectedEventDayYear = defaultEventYear; // Select the default event year
                break;
            case "Custom Date":
                this.startDate = this.currDateTime.split(' ')[0];
                this.endDate = this.currDateTime.split(' ')[0];
                this.customFilterDisplay = true;
                this.commonFilter = false;
                this.eventDayFilter = false;
                this._disabled = false;
                let tmpStrStartDate = this.strStartDate.split(" ");
                let tmpStrStartTime = tmpStrStartDate[1].split(":");
                let tmpStrEndDate = this.currDateTime.split(" ");
                let tmpStrEndTime = tmpStrEndDate[1].split(":");
                this.startHours = tmpStrStartTime[0];
                this.startMinutes = tmpStrStartTime[1];
                this.startSeconds = tmpStrStartTime[2];
                this.endHours = tmpStrEndTime[0];
                this.endMinutes = tmpStrEndTime[1];
                this.endSeconds = tmpStrEndTime[2];
                break;
            case "Yesterday":
            case "Last Week Same Day":
                this.commonFilter = true;
                this.eventDayFilter = false;
                this.customFilterDisplay = false;
                this._disabled = true;
                this.fillDateTime();
                this.fillDates(value);
                break;
            case "Whole Scenario":
                this.customFilterDisplay = false;
                this.eventDayFilter = false;
                this.commonFilter = false;
                break;
            default:
                this.customFilterDisplay = false;
                this.eventDayFilter = false;
                this.commonFilter = false;
                break;
        }
    }
    /**
     *  Allow digits (0-9), arrow keys (0), backspace (8), and delete (46)
     */
    valEnteredKeyN(event) {
        if ((event.keyCode >= 48 && event.keyCode <= 57) || event.keyCode === 0 || event.keyCode === 8 || event.keyCode === 46) {
            return true;
        }
        else {
            return false;
        }
    }
    fillDates(value) {
        this.startDate = this.eventDateMap[value];
        this.endDate = this.eventDateMap[value];
    }
    openTimeFilter() {
        this.display = true;
        this.selectedValue = this.timeLabel;
        this.customFilterDisplay = (this.selectedValue == 'Custom Date') ? true : false;
        this.timeFilterOptions = [
            { label: 'Today', value: 'Today' },
            { label: 'EventDay', value: 'EventDay' },
            { label: 'Last 5 Minutes', value: 'Last 5 Minutes' },
            { label: 'Last 10 Minutes', value: 'Last 10 Minutes' },
            { label: 'Last 15 Minutes', value: 'Last 15 Minutes' },
            { label: 'Last 30 Minutes', value: 'Last 30 Minutes' },
            { label: 'Last 1 hour', value: 'Last 1 hour' },
            { label: 'Last 2 hours', value: 'Last 2 hours' },
            { label: 'Last 4 hours', value: 'Last 4 hours' },
            { label: 'Last 8 hours', value: 'Last 8 hours' },
            { label: 'Last 12 hours', value: 'Last 12 hours' },
            { label: 'Last 24 hours', value: 'Last 24 hours' },
            { label: 'Yesterday', value: 'Yesterday' },
            { label: 'Last Week Same Day', value: 'Last Week Same Day' },
            { label: 'Custom Date', value: 'Custom Date' },
            { label: 'Whole Scenario', value: 'Whole Scenario' },
        ];
        if (this.urlParam.strGraphKey.includes("SPECIFIED_TIME")) { // When Custom Date/Time is applied in End To End.
            this.startDate = this.startTime;
            [this.startHours, this.startMinutes, this.startSeconds] = this.startTime.split(" ")[1].split(":");
            this.endDate = this.endTime;
            [this.endHours, this.endMinutes, this.endSeconds] = this.endTime.split(" ")[1].split(":");
        }
    }
    trimString(str) {
        return str.replace(/^\s+/g, '').replace(/\s+$/g, '');
    }
    compareDatesForOthers(startDate, endDate) {
        var x = new Date(startDate);
        var y = new Date(endDate);
        return (x >= y);
    }
    submitFilterValue() {
        this.display = false;
        let strStartTimeAll = '';
        let strEndTimeAll = '';
        let strStartTimeAllMs;
        let strEndTimeAllMs;
        const currentDateTime = this.currDateTime;
        if (this.selectedValue == "EventDay" || this.selectedValue == "Yesterday" || this.selectedValue == "Last Week Same Day" || this.selectedValue == "By Phase" || this.selectedValue == "Custom Date") {
            if (this.startDate.toString().includes(" ")) {
                let strDate = new Date(this.startDate);
                this.startDate = (strDate.getMonth() + 1).toString() + '/' + strDate.getDate().toString() + '/' + strDate.getFullYear().toString();
            }
            if (this.endDate.toString().includes(" ")) {
                let endDate = new Date(this.endDate);
                this.endDate = (endDate.getMonth() + 1).toString() + '/' + endDate.getDate().toString() + '/' + endDate.getFullYear().toString();
            }
            if (this.trimString(this.startDate) == "" || this.trimString(this.startHours) == "" || this.trimString(this.startMinutes) == "" || this.trimString(this.startSeconds) == "" || this.trimString(this.endDate) == "" || this.trimString(this.endHours) == "" || this.trimString(this.endMinutes) == "" || this.trimString(this.endSeconds) == "") {
                this.messageService.showError("Start/End Date/Time shouldn't be blank");
                return;
            }
            if (Number(this.startHours) >= 24 || Number(this.endHours) >= 24) {
                this.messageService.showError("Start/End hour field shouldn't be greater than or equals to 24");
                return;
            }
            if (Number(this.startMinutes) >= 60 || Number(this.endMinutes) >= 60 || Number(this.startSeconds) >= 60 || Number(this.endSeconds) >= 60) {
                this.messageService.showError("Start/End Minute/Second field shouldn't be greater than or equal to 60");
                return;
            }
            // Construct start and end date/time strings
            strStartTimeAll = `${this.trimString(this.startDate)} ${this.trimString(this.startHours)}:${this.trimString(this.startMinutes)}:${this.trimString(this.startSeconds)}`;
            strEndTimeAll = `${this.trimString(this.endDate)} ${this.trimString(this.endHours)}:${this.trimString(this.endMinutes)}:${this.trimString(this.endSeconds)}`;
            // Convert date/time strings to milliseconds
            strStartTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strStartTimeAll, "MM/DD/YYYY HH:mm:ss");
            strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strEndTimeAll, "MM/DD/YYYY HH:mm:ss");
            let timeDiff1 = Math.abs(strStartTimeAllMs - strEndTimeAllMs);
            sessionStorage.setItem('timeDiff1', timeDiff1.toString());
            if (this.compareDatesForOthers(strStartTimeAll, currentDateTime)) {
                this.messageService.showError("Start date/time cannot be greater than current date/time");
                return;
            }
            if (this.compareDatesForOthers(strEndTimeAll, currentDateTime)) {
                this.messageService.showError("End date/time cannot be greater than current date/time");
                return;
            }
            if (this.compareDatesForOthers(strStartTimeAll, strEndTimeAll)) {
                this.messageService.showError("Start date/time cannot be greater than end date/time");
                return;
            }
        }
        else if (this.selectedValue == "Whole Scenario") {
            const session = this.sessionService.session;
            this.selectedValue = "WholeScenario";
            strStartTimeAll = this.sessionService.convertTimestampIntoFormattedString(this.sessionService.session.testRun.st);
            strStartTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strStartTimeAll, "MM/DD/YYYY HH:mm:ss");
            if (session.testRun.running) {
                const currentDateTime = new Date(moment__WEBPACK_IMPORTED_MODULE_6__().tz(sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss'));
                const dateFormat = this.getDateFormat(currentDateTime);
                const currentDateTimeInMs = this.sessionService.convertFormattedStringIntoTimestamp(dateFormat);
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(currentDateTimeInMs);
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strEndTimeAll, "MM/DD/YYYY HH:mm:ss");
            }
            else {
                let endtime = this.sessionService.session.testRun.st + session.testRun.duration;
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(endtime);
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strEndTimeAll, "MM/DD/YYYY HH:mm:ss");
            }
        }
        else {
            var today = new Date(moment__WEBPACK_IMPORTED_MODULE_6__().tz(sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss'));
            var date = (today.getMonth() + 1) + '/' + today.getDate() + '/' + today.getFullYear();
            var time = today.getHours() + ":" + today.getMinutes() + ":" + today.getSeconds();
            if (this.selectedValue == "Today") {
                today.setHours(0);
                today.setMinutes(0);
                today.setSeconds(0);
                var startTime = this.getDateFormat(today);
                var stTime = this.sessionService.convertFormattedStringIntoTimestamp(startTime);
                var etTime = date + " " + time;
                strStartTimeAllMs = stTime.toString();
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(etTime);
                strStartTimeAll = this.sessionService.convertTimestampIntoFormattedString(stTime, "MM/DD/YYYY HH:mm:ss");
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(Number(strEndTimeAllMs), "MM/DD/YYYY HH:mm:ss");
            }
            else if (this.selectedValue.includes("Minutes")) {
                var etTime = date + " " + time;
                let stringVal = this.selectedValue.toString();
                let minuteVal = stringVal.replace(/^\D+/g, '');
                let timeInMs = parseInt(minuteVal) * 60 * 1000;
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(etTime);
                let strTime = Number(strEndTimeAllMs) - timeInMs;
                strStartTimeAll = this.sessionService.convertTimestampIntoFormattedString(strTime, "MM/DD/YYYY HH:mm:ss");
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(Number(strEndTimeAllMs), "MM/DD/YYYY HH:mm:ss");
                strStartTimeAllMs = strTime.toString();
            }
            else if (this.selectedValue.includes("hours") || this.selectedValue.includes("hour")) {
                var etTime = date + " " + time;
                let stringVal = this.selectedValue.toString();
                let hoursVal = stringVal.replace(/^\D+/g, '');
                let timeInMs = parseInt(hoursVal) * 60 * 60 * 1000;
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(etTime);
                let strTime = Number(strEndTimeAllMs) - timeInMs;
                strStartTimeAll = this.sessionService.convertTimestampIntoFormattedString(strTime, "MM/DD/YYYY HH:mm:ss");
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(Number(strEndTimeAllMs), "MM/DD/YYYY HH:mm:ss");
                strStartTimeAllMs = strTime.toString();
            }
        }
        const url = `graphTime=${this.selectedValue}&startTime=${strStartTimeAll}&endTime=${strEndTimeAll}`;
        // Set URL parameters
        this.startTime = strStartTimeAll;
        this.endTime = strEndTimeAll;
        this.urlParam.strStartTime = strStartTimeAllMs;
        this.urlParam.strEndTime = strEndTimeAllMs;
        this.ndDdrHttpService.getGraphKey(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__["GraphKeyLoadedState"]) {
                let data = state.data;
                if (data == 'Today') {
                    this.strGraphKey = 'LAST_DAY';
                    this.isFilterChanged = true;
                }
                else {
                    this.strGraphKey = data;
                    this.isFilterChanged = true;
                }
                this.urlParam.preset = this._ddrData.getGraphKeyID(this.strGraphKey);
                this.commonService.loaderForDdr = true;
                this.urlParam.strGraphKey = this.strGraphKey;
                this.getIPData();
            }
        });
        // Fetch graph key
        this.ndDdrHttpService.getGraphKey(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__["GraphKeyLoadedState"]) {
                let data = state.data;
                if (data.graphKey == 'Today') {
                    this.strGraphKey = 'LAST_DAY';
                    this.isFilterChanged = true;
                }
                else {
                    this.strGraphKey = data.graphKey;
                    this.isFilterChanged = true;
                }
                this.urlParam.preset = this._ddrData.getGraphKeyID(this.strGraphKey);
                this.commonService.loaderForDdr = true;
                this.urlParam.strGraphKey = this.strGraphKey;
                this.getIPData();
            }
        });
    }
    noNegativeValue(event) {
        const disallowedKeyCodes = [45, 43, 42, 47, 43]; // Key codes for '-', '+', '*', '/', '+'
        return !disallowedKeyCodes.includes(event.keyCode);
    }
    getSpecifiedData() {
        let currentDateTime = this.currDateTime;
        let strStartTimeAllMs;
        let strEndTimeAllMs;
        if (this.startCDate.toString().includes(" ")) {
            let strDate = new Date(this.startCDate);
            this.startCDate = (strDate.getMonth() + 1).toString() + '/' + strDate.getDate().toString() + '/' + strDate.getFullYear().toString();
        }
        if (this.endCDate.toString().includes(" ")) {
            let endDate = new Date(this.endCDate);
            this.endCDate = (endDate.getMonth() + 1).toString() + '/' + endDate.getDate().toString() + '/' + endDate.getFullYear().toString();
        }
        if (this.trimString(this.startCDate) == "" || this.trimString(this.startCHours) == "" || this.trimString(this.startCMinutes) == "" || this.trimString(this.startCSeconds) == "" || this.trimString(this.endCDate) == "" || this.trimString(this.endCHours) == "" || this.trimString(this.endCMinutes) == "" || this.trimString(this.endCSeconds) == "") {
            this.messageService.showError("Start/End Date/Time shouldn't be blank");
            return;
        }
        if (Number(this.startCHours) >= 24 || Number(this.endCHours) >= 24) {
            this.messageService.showError("Start/End hour field shouldn't be greater than or equals to 24");
            return;
        }
        if (Number(this.startCMinutes) >= 60 || Number(this.endCMinutes) >= 60 || Number(this.startCSeconds) >= 60 || Number(this.endCSeconds) >= 60) {
            this.messageService.showError("Start/End Minute/Second field shouldn't be greater than or equal to 60 ");
            return;
        }
        var strStartTime = this.startCHours + ":" + this.startCMinutes + ":" + this.startCSeconds;
        var strEndTime = this.endCHours + ":" + this.endCMinutes + ":" + this.endCSeconds;
        var strStartTimeAll = this.trimString(this.startCDate) + " " + this.trimString(strStartTime);
        var strEndTimeAll = this.trimString(this.endCDate) + " " + this.trimString(strEndTime);
        strStartTimeAllMs = new Date(strStartTimeAll).getTime();
        strEndTimeAllMs = new Date(strEndTimeAll).getTime();
        if (this.selectedCompareTime.startsWith('Compare')) {
            this.compareAppliedStrattime = strStartTimeAll;
            this.compareAppliedEndtime = strEndTimeAll;
        }
        var timeDiff1 = Math.abs(strStartTimeAllMs - strEndTimeAllMs);
        sessionStorage.setItem('timeDiff1', timeDiff1.toString());
        if (this.compareDatesForOthers(strStartTimeAll, currentDateTime)) {
            this.messageService.showError("Start date/time cannot be greater than current date/time");
            return;
        }
        if (this.compareDatesForOthers(strEndTimeAll, currentDateTime)) {
            this.messageService.showError("End date/time cannot be greater than current date/time");
            return;
        }
        if (this.compareDatesForOthers(strStartTimeAll, strEndTimeAll)) {
            this.messageService.showError("Start date/time cannot be greater than end date/time");
            return;
        }
        const url = 'graphTime=' + 'Custom Date' + '&startTime=' + strStartTimeAll + '&endTime=' + strEndTimeAll;
        this.startTime = strStartTimeAll;
        this.endTime = strEndTimeAll;
        this.ndDdrHttpService.getGraphKey(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__["GraphKeyLoadedState"]) {
                this.strCGraphKey = state.data;
                this.isCompare = true;
                this.commonService.loaderForDdr = true;
                this.getIPData();
            }
        });
    }
    validateQty(event) {
        if (event.charCode > 31 && (event.charCode < 48 || event.charCode > 57))
            return false;
        return true;
    }
    openBTIPSummary(rowData) {
        var _a, _b;
        this.commonService.spinner = true;
        this.commonService.isFilterFromSideBar = false;
        let btCategory = this.urlParam.btCategory;
        let strGraphKey = this.urlParam.strGraphKey;
        this.urlParam.strTimeLabel = this.timeLabel;
        let jsonstartTimeStamp = this.startTimetoPass;
        let jsonendTimeStamp = (_b = (_a = this.fullJson) === null || _a === void 0 ? void 0 : _a.tableData) === null || _b === void 0 ? void 0 : _b.endTimeStamp;
        let btCategoryId = "";
        if (btCategory.toUpperCase() != "ALL")
            btCategoryId = this.getBTCategoryId(btCategory);
        if (strGraphKey.toLowerCase() == "wholescenario") {
            jsonstartTimeStamp = "NA";
            jsonendTimeStamp = "NA";
        }
        if (btCategory != "All") {
            this._ddrData.btCategory = this.getBTCategoryId(btCategory);
        }
        let ddrData = {};
        ddrData.testRun = this.commonService.testRun;
        ddrData.tierName = rowData.tier;
        ddrData.serverName = rowData.server;
        ddrData.appName = rowData.instance;
        ddrData.startTime = jsonstartTimeStamp;
        ddrData.endTime = jsonendTimeStamp;
        ddrData.urlName = rowData.bt;
        this.commonService.ipSummaryData = ddrData;
        this._ddrData.testRun = this.commonService.testRun;
        this._ddrData.tierName = rowData.tier;
        this._ddrData.serverName = rowData.server;
        this._ddrData.appName = rowData.instance;
        this._ddrData.startTime = jsonstartTimeStamp;
        this._ddrData.endTime = jsonendTimeStamp;
        this._ddrData.urlName = rowData.bt;
        this._ddrData.vecArrForGraph = [];
        this._ddrData.splitViewFlag = false;
        this._ddrData.product = this.urlParam.product.toString().includes("/") ? this.urlParam.product.replace("/", "") : this.urlParam.product;
        if (this.commonService.enableQueryCaching) {
            this._ddrData.enableQueryCaching = this.commonService.enableQueryCaching;
        }
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_10__["BREADCRUMB_ITEMS"].BTTREND;
        this.commonService.spinner = false;
        this._ddrData.setInLogger('DDR::Bt Trend::Ip Summary', 'Ip Summary', 'Open Ip Summary Report ');
        this._router.navigate([this.getRoutePath() + '/ipsummary']);
    }
    getRoutePath() {
        if (this._ddrData.btTrendParamFromStoreView != undefined)
            return '/ddr';
    }
    getAggKeywordData() {
        this.ndDdrHttpService.getenableAggFlowmap().subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__["enableAggviewLoadedState"]) {
                let data = state.data;
                this.enableAggFlowmap = data.enableAggView;
            }
        });
    }
    gettierData(node) {
        this.commonService.spinner = true;
        this.currentNodeData = node;
        let row = this.currentNodeData;
        this.urlParam.strTimeLabel = this.timeLabel;
        if (this.startIndexForAgg < 0) {
            this.messageService.showError("Start Index should not be less than 0");
            return;
        }
        if (this.startIndexForAgg > this.lastIndexForAgg || this.startIndexForAgg == this.lastIndexForAgg) {
            this.messageService.showError("Start Index should be less than Last Index");
            return;
        }
        if (this.lastIndexForAgg < 1) {
            this.messageService.showError("Last Index should not be less than 1");
            return;
        }
        this.ndDdrHttpService.getlastIndexOfAgg().subscribe((state) => {
            var _a, _b, _c;
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_17__["lastIndexOfAggLoadedState"]) {
                if (state.data) {
                    this.lastIndexForAgg = Number(state.data.lastIndexOfAgg);
                }
                this._DdrAggFlowmapService.startTime = (_a = this.fullJson) === null || _a === void 0 ? void 0 : _a.tableData.startTimeStamp;
                this._DdrAggFlowmapService.endTime = (_c = (_b = this.fullJson) === null || _b === void 0 ? void 0 : _b.tableData) === null || _c === void 0 ? void 0 : _c.endTimeStamp;
                this._DdrAggFlowmapService.btName = row.bt;
                this._DdrAggFlowmapService.tierName = row.tier;
                const btCategory = this.getBTCategoryId(this.urlParam.btCategory);
                if (btCategory) {
                    this._ddrData.btCategory = btCategory;
                }
                const refresh = this.commonService.enableQueryCaching == 1 ? "0" : "1";
                const displayName = this._ddrData.dcName ? this._ddrData.dcName : '-';
                let url = 'testRun=' + this.urlParam.testRun + '&strStartTime=' + this._DdrAggFlowmapService.startTime + '&strEndTime=' + this._DdrAggFlowmapService.endTime + '&statusCode=-2' + '&tierName=' + this._DdrAggFlowmapService.tierName + '&btName=' + row.bt + '&start=' + this.startIndexForAgg + '&end=' + this.lastIndexForAgg + '&btCategory=' + btCategory + '&refresh=' + refresh + '&isCompress=0&isMDC=1&isSDC=1&enableIps=true&displayName=' + displayName;
                this._DdrAggFlowmapService.isRefreshCase = false;
                this.commonService.loaderForDdr = true;
                this._DdrAggFlowmapService.getKeyForView();
                this._DdrAggFlowmapService.createFirstLevelJson(url);
            }
        });
    }
};
DdrBtTrendComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_3__["CavConfigService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_5__["Router"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_5__["ActivatedRoute"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_9__["DdrBreadcrumbService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_11__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_13__["SessionService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_15__["CavMessageService"] },
    { type: _services_ddr_agg_flowmap_service__WEBPACK_IMPORTED_MODULE_12__["DdrAggFlowmapService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_14__["BreadcrumbService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_16__["NdDdrHttpService"] }
];
DdrBtTrendComponent.btType = {
    Normal: 10,
    Slow: 11,
    VerySlow: 12,
    Errors: 13,
    Stalled: 14,
    Unknown: 0
};
DdrBtTrendComponent = DdrBtTrendComponent_1 = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-bt-trend',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-bt-trend.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-bt-trend.component.scss */ "./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.scss")).default]
    })
], DdrBtTrendComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.css":
/*!************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.css ***!
  \************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.ts":
/*!***********************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.ts ***!
  \***********************************************************************/
/*! exports provided: DdrChartComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrChartComponent", function() { return DdrChartComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_3__);




let DdrChartComponent = class DdrChartComponent {
    // bgColorThemes: String[] = window['bgColorddr'] || ['rgba(255,255,255,0.2)', 'rgba(0,0,0,0)'];
    constructor(_ddrData) {
        this._ddrData = _ddrData;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_3__;
        this.colorThemes = window['arrColorddr'] || ['#3A99D9', '#F1C330', '#7CB5EC', '#434348'];
    }
    makeChartData(callData, width) {
        this.chartData = callData;
        this.makeChart(width);
    }
    ngOnInit() {
        this._ddrData.ddrThemeChangeUIObservable$.subscribe(() => {
            console.log("inside ddr chart --");
            this.colorThemes = window['arrColorddr'] || ['#3A99D9', '#F1C330', '#7CB5EC', '#434348'];
            this.makeChart();
        });
        this.makeChart();
    }
    makeChart(width) {
        // console.log("bgColorThemes===",this.bgColorThemes);
        // console.log("colorThemes==",this.colorThemes);
        this.options = {
            chart: {
                height: 30,
                width: 90,
                spacingLeft: .1,
                spacingRight: .1,
                spacingBottom: 1,
                spacingTop: .001,
                backgroundColor: 'transparent',
            },
            credits: {
                enabled: false
            },
            title: {
                text: null
            },
            xAxis: {
                title: {
                    text: null
                },
                visible: false
            },
            yAxis: {
                title: {
                    text: null,
                },
                visible: false
            },
            legend: {
                enabled: false
            },
            exporting: {
                enabled: false
            },
            plotOptions: {
                series: {
                    cursor: false,
                    enableMouseTracking: false,
                    marker: {
                        enabled: false,
                        states: {
                            hover: {
                                enabled: false
                            }
                        }
                    }
                },
            },
            enableMouseTracking: {
                enabled: false
            },
            series: [
                {
                    type: 'area',
                    data: this.chartData,
                    color: this.colorThemes[0],
                    // lineColor: 'red',
                    lineWidth: .1,
                }
            ]
        };
        if (width) {
            this.options['chart'].width = width;
        }
    }
};
DdrChartComponent.ctorParameters = () => [
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_2__["DdrDataModelService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrChartComponent.prototype, "chartData", void 0);
DdrChartComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-chart',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-chart.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-chart.component.css */ "./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.css")).default]
    })
], DdrChartComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.scss":
/*!***********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.scss ***!
  \***********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-ddr-compare-flowpath .h-90-vh {\n  height: 90vh;\n}\napp-ddr-compare-flowpath .ui-tabview-panel {\n  height: calc(100vh - 290px);\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.ts":
/*!*********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.ts ***!
  \*********************************************************************************************/
/*! exports provided: DdrCompareFlowpathComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrCompareFlowpathComponent", function() { return DdrCompareFlowpathComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/common */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");






let DdrCompareFlowpathComponent = class DdrCompareFlowpathComponent {
    constructor(commonServices, loaction, _ddrData, breadcrumb) {
        this.commonServices = commonServices;
        this.loaction = loaction;
        this._ddrData = _ddrData;
        this.showMCT = false;
        this.showHotspot = false;
        this.showDB = false;
        this.showMT = true;
        this.loading = false;
        this.showExceptions = false;
        this.cols = [];
        this.breadcrumb = breadcrumb;
    }
    ngOnInit() {
        this.commonServices.isToLoadSideBar = false;
        this._ddrData.isFromCompareFp = true;
        this.loading = false;
        this.breadcrumb.add({ label: 'Flowpath', routerLink: '/ddr/flowpath' });
        this.breadcrumb.add({ label: 'Compare Flowpath', routerLink: '/ddr/DdrCompareFlowpath' });
        this.compareFPInfo = this.commonServices.compareFlowpathData;
        this.compareFP1 = this.compareFPInfo[0].flowpathInstance;
        this.compareFP2 = this.compareFPInfo[1].flowpathInstance;
        this.compareFPInfo2 = JSON.parse(JSON.stringify(this.compareFPInfo));
        for (let i = 0; i < this.compareFPInfo2.length; i++) {
            this.compareFPInfo2[i].flowpathInstance = "FP" + (i + 1) + " " + this.compareFPInfo2[i].flowpathInstance;
        }
        this.relativePath = "ddr/compare-flowpath/compare-flowpath.json";
    }
    ngOnChanges() {
        this.loading = true;
        this.handleChange({ 'index': 0 });
    }
    handleChange(event) {
        console.log(event.index);
        this.commonServices.graphInSideBarForDB = false;
        this.commonServices.graphInSideBarForMT = false;
        if (event.index == 0)
            this.showMT = true;
        else if (event.index == 1)
            this.showDB = true;
        else if (event.index == 2)
            this.showMCT = true;
        else if (event.index == 3)
            this.showHotspot = true;
        else if (event.index == 4)
            this.showExceptions = true;
    }
    ngOnDestroy() {
        this.breadcrumb['items'].pop();
        this._ddrData.isFromCompareFp = false;
    }
};
DdrCompareFlowpathComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _angular_common__WEBPACK_IMPORTED_MODULE_4__["Location"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_2__["DdrDataModelService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["BreadcrumbService"] }
];
DdrCompareFlowpathComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-compare-flowpath',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-compare-flowpath.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-compare-flowpath.component.scss */ "./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.scss")).default]
    })
], DdrCompareFlowpathComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.css":
/*!******************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.css ***!
  \******************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("chart\r\n{\r\n    display:block;\r\n}\r\n\r\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.ts":
/*!*****************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.ts ***!
  \*****************************************************************************************************/
/*! exports provided: DdrCompareMethodtimingComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrCompareMethodtimingComponent", function() { return DdrCompareMethodtimingComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");






let DdrCompareMethodtimingComponent = class DdrCompareMethodtimingComponent {
    constructor(commonServices, ddrHttpService) {
        this.commonServices = commonServices;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_3__;
        this.loading = false;
        this.MTObjArr = [];
        this.cumSelfTimeArr = [];
        this.avgSelfTimeArr = [];
        this.avgCPUSelfTimeArr = [];
        this.countArr = [];
        this.colour = [];
        this.fQM = "";
        this.fqmstr = "";
        this.Completefqm = "";
        this.filterCriteriaStr = "";
        this.cols = [];
        this.colsForFp = [];
        this.relativePath = "ddr/compare-methodtiming/compare-methodtiming.json";
        this.colour = ['green', 'blue'];
    }
    ngOnChanges() {
        this.loading = true;
        this.globalQueryParams = this.commonServices.getData();
        this.getComparedDBData();
    }
    getComparedDBData() {
        let cmdArgs = '';
        let testRun;
        for (let i = 0; i < this.compareFPInfo.length; i++) {
            let fpDuration = 0;
            if (this.compareFPInfo[i].fpDuration == '< 1')
                fpDuration = 0;
            else if (this.compareFPInfo[i].fpDuration.toString().includes(','))
                fpDuration = this.compareFPInfo[i].fpDuration.toString().replace(/,/g, "");
            else
                fpDuration = this.compareFPInfo[i].fpDuration;
            let endTime = Number(this.compareFPInfo[i]['startTimeInMs']) + Number(fpDuration);
            if (this.commonServices.testRun)
                testRun = this.commonServices.testRun;
            else
                testRun = this.globalQueryParams['testRun'];
            cmdArgs += testRun + "," + this.compareFPInfo[i]['startTimeInMs'] + "," + endTime + "," + this.compareFPInfo[i]['urlIndex'] + "," + this.compareFPInfo[i]['tierId'] + "," + this.compareFPInfo[i]['serverId'] + "," + this.compareFPInfo[i]['appId'] + "," + this.compareFPInfo[i]['flowpathInstance'] + ",%%%,";
        }
        const queryParams = `cmdArgs=${cmdArgs}${this.commonServices.enableQueryCaching === 1 ? `&cacheId=${testRun}` : ''}&tierName=${this.compareFPInfo[0]['tierName']}`;
        this.ddrHttpService.getCompareFPInfo(queryParams, 'compareMethods').subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_5__["CompareFlowPathLoadedState"]) {
                this.doAssignValuForCompareMTdata(state.data.data);
            }
        }, (error) => {
            console.error('Error in fetching response ~ ', error);
            this.loading = false;
        });
    }
    showError(msg) {
        this.errMsg = [];
        this.errMsg.push({ severity: 'error', summary: 'Error Message', detail: msg });
    }
    doAssignValuForCompareMTdata(data) {
        this.loading = false;
        this.assignCompareMTData(data);
        this.compareMTData = data;
        if (this.MTObjArr.length > 0) {
            this.getBarChartsDataBasedOnFQM(this.MTObjArr[0]['fQM']);
            this.createCumSelfTimeBarChart();
            this.createAvgSelfTimeBarChart();
            this.createCountBarChart();
        }
    }
    clickButtonEvent(event) {
        var _a, _b, _c;
        const me = this;
        console.log('Event: ', event);
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.showMTrelatedData((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
            this.commonServices.graphInSideBarForMT = true;
        }
    }
    getBarChartsDataBasedOnFQM(fQM) {
        this.fQM = fQM;
        if (this.fQM.length > 40) {
            this.fqmstr = this.fQM.substring(0, 40) + "...";
            this.Completefqm = this.fQM;
        }
        else {
            this.fqmstr = this.fQM;
            this.Completefqm = this.fQM;
        }
        var arr = this.compareMTData[fQM];
        let cumSelfTimeArr = [];
        let avgSelfTimeArr = [];
        let countArr = [];
        arr.forEach((val, index) => {
            if (arr.length > (index + 1)) {
                if (val['avgselftime'] !== -9999.0)
                    avgSelfTimeArr.push({ "name": "FP" + (index + 1), "data": [val['avgselftime']], color: this.colour[index] });
                if (val['total_self_time_in_ms'] !== -9999.0)
                    cumSelfTimeArr.push({ "name": "FP" + (index + 1), "data": [val['total_self_time_in_ms']], color: this.colour[index] });
                if (val['executionCount'] !== -9999.0)
                    countArr.push({ "name": "FP" + (index + 1), "data": [val['executionCount']], color: this.colour[index] });
            }
        });
        this.cumSelfTimeArr = cumSelfTimeArr;
        this.avgSelfTimeArr = avgSelfTimeArr;
        this.countArr = countArr;
    }
    createCountBarChart() {
        let countArr = this.countArr;
        this.options3 = {
            chart: {
                type: 'column',
                width: 320,
                height: (3 / 3.25 * 100) + '%'
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            title: {
                text: ''
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                title: {
                    text: 'Count'
                },
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: ''
                }
            },
            plotOptions: {
                column: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    events: {
                        click: function (event) {
                        }.bind(this)
                    },
                    column: {
                        pointPadding: 0.2,
                        borderWidth: 0
                    }
                },
                series: {
                    pointWidth: 25
                }
            },
            series: countArr
        };
    }
    showMTrelatedData(node) {
        this.fQM = node['fQM'];
        this.getBarChartsDataBasedOnFQM(node['fQM']);
        this.createCumSelfTimeBarChart();
        this.createAvgSelfTimeBarChart();
        this.createCountBarChart();
    }
    createAvgCPUSelfTimeBarChart() {
        let avgCPUSelfTimeArr = this.avgCPUSelfTimeArr;
        this.options2 = {
            chart: {
                type: 'column',
                width: 320,
                height: (3 / 3.25 * 100) + '%'
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            title: {
                text: ''
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                title: {
                    text: 'AvgCPUSelfTime(ms)'
                },
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: ''
                }
            },
            plotOptions: {
                column: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    events: {
                        click: function (event) {
                        }.bind(this)
                    },
                    column: {
                        pointPadding: 0.2,
                        borderWidth: 0
                    }
                },
                series: {
                    pointWidth: 25
                }
            },
            series: avgCPUSelfTimeArr
        };
    }
    createAvgSelfTimeBarChart() {
        let avgSelfTimeArr = this.avgSelfTimeArr;
        this.options1 = {
            chart: {
                type: 'column',
                width: 320,
                height: (3 / 3.25 * 100) + '%'
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            title: {
                text: ''
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                title: {
                    text: 'AvgSelfTime(ms)'
                },
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: ''
                }
            },
            plotOptions: {
                column: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    events: {
                        click: function (event) {
                        }.bind(this)
                    },
                    column: {
                        pointPadding: 0.2,
                        borderWidth: 0
                    }
                },
                series: {
                    pointWidth: 25
                }
            },
            series: avgSelfTimeArr
        };
    }
    assignCompareMTData(data) {
        var MTObjArr = [];
        let compMTArr = Object.keys(data);
        compMTArr.forEach((val, ind) => {
            let MTObj = {};
            let compMTDataArr = data[val];
            let compMTDataLength = compMTDataArr.length;
            let lastIndex = val.lastIndexOf(".");
            let temp = val.substring(0, lastIndex);
            let secondLastindex = temp.lastIndexOf(".");
            MTObj['fQM'] = val;
            MTObj['mN'] = val.substring(lastIndex + 1, val.length);
            MTObj['cN'] = temp.substring(secondLastindex + 1, temp.length);
            MTObj['pN'] = temp.substring(0, temp.lastIndexOf("."));
            compMTDataArr.forEach((val1, index) => {
                if (compMTDataLength == (index + 1)) {
                    var objectKeys = Object.keys(val1);
                    objectKeys.forEach((val2, index2) => {
                        if (val1[val2] != "-9999")
                            MTObj[val2 + "_Changes"] = (Number(val1[val2]).toFixed(3));
                        else
                            MTObj[val2 + "_Changes"] = "-";
                    });
                }
                else {
                    var objectKeys = Object.keys(val1);
                    objectKeys.forEach((val2, index2) => {
                        if (val1[val2] != "-9999")
                            MTObj[val2 + "_FP" + (index + 1)] = (val1[val2]);
                        else
                            MTObj[val2 + "_FP" + (index + 1)] = "-";
                    });
                }
            });
            MTObjArr.push(MTObj);
        });
        this.MTObjArr = MTObjArr;
    }
    createCumSelfTimeBarChart() {
        let cumSelfTimeArr = this.cumSelfTimeArr;
        this.options = {
            chart: {
                type: 'column',
                width: 320,
                height: (3 / 3.25 * 100) + '%'
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            title: {
                text: ''
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                title: {
                    text: 'CumSelfTime(sec)'
                },
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Value'
                }
            },
            plotOptions: {
                column: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    events: {
                        click: function (event) {
                        }.bind(this)
                    },
                    column: {
                        pointPadding: 0.2,
                        borderWidth: 0
                    }
                },
                series: {
                    pointWidth: 25
                }
            },
            series: cumSelfTimeArr
        };
    }
    /* Filter Cretira */
    showFilterCriteria() {
        const validCriteria = (field) => field !== "NA" && field !== "" && field !== undefined && field !== "undefined";
        const addFilter = (field, label) => {
            if (validCriteria(this.compareFPInfo[0][field]) && validCriteria(this.compareFPInfo[1][field])) {
                if (this.compareFPInfo[0][field] === this.compareFPInfo[1][field])
                    this.filterCriteriaStr += `, ${label}=${this.compareFPInfo[0][field]}`;
                else
                    this.filterCriteriaStr += `, ${label}=${this.compareFPInfo[0][field]},${this.compareFPInfo[1][field]}`;
            }
        };
        addFilter('tierName', 'Tier');
        addFilter('serverName', 'Server');
        addFilter('appName', 'Instance');
        addFilter('urlName', 'BT');
    }
};
DdrCompareMethodtimingComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_4__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('compareFPInfo')
], DdrCompareMethodtimingComponent.prototype, "compareFPInfo", void 0);
DdrCompareMethodtimingComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-compare-methodtiming',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-compare-methodtiming.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-compare-methodtiming.component.css */ "./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.css")).default]
    })
], DdrCompareMethodtimingComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.css":
/*!********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.css ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("chart\r\n{\r\n    display:block;\r\n}\r\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.ts":
/*!*******************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.ts ***!
  \*******************************************************************************************/
/*! exports provided: DdrCompareQueriesComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrCompareQueriesComponent", function() { return DdrCompareQueriesComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs/operators */ "./node_modules/rxjs/_esm2015/operators/index.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");







let DdrCompareQueriesComponent = class DdrCompareQueriesComponent {
    constructor(commonServices, ddrHttpService) {
        this.commonServices = commonServices;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_4__;
        this.loading = false;
        this.queryObjArr = [];
        this.queryCountArr = [];
        this.avgTimeArr = [];
        this.cumTimeArr = [];
        this.errorCountArr = [];
        this.colour = [];
        this.queryName = "";
        this.query = "";
        this.Completequery = "";
        this.filterCriteriaStr = "";
        this.showDownloadOption = true;
        this.relativePath = "ddr/compare-queries/compare-queries.json";
    }
    ngOnInit() {
        this.colour = ['green', 'blue'];
    }
    ngOnChanges() {
        this.loading = true;
        console.log(this.compareFPInfo);
        this.globalQueryParams = this.commonServices.getData();
        this.getComparedDBData();
    }
    getComparedDBData() {
        let cmdArgs = '';
        let testRun;
        for (let i = 0; i < this.compareFPInfo.length; i++) {
            let fpDuration = 0;
            if (this.compareFPInfo[i].fpDuration == '< 1')
                fpDuration = 0;
            else if (this.compareFPInfo[i].fpDuration.toString().includes(','))
                fpDuration = this.compareFPInfo[i].fpDuration.toString().replace(/,/g, "");
            else
                fpDuration = this.compareFPInfo[i].fpDuration;
            let endTime = Number(this.compareFPInfo[i]['startTimeInMs']) + Number(fpDuration);
            if (this.commonServices.testRun)
                testRun = this.commonServices.testRun;
            else
                testRun = this.globalQueryParams['testRun'];
            cmdArgs += testRun + "," + this.compareFPInfo[i]['startTimeInMs'] + "," + endTime + "," + this.compareFPInfo[i]['urlIndex'] + "," + this.compareFPInfo[i]['tierId'] + "," + this.compareFPInfo[i]['serverId'] + "," + this.compareFPInfo[i]['appId'] + "," + this.compareFPInfo[i]['flowpathInstance'] + ",%%%,";
        }
        const queryParams = `cmdArgs=${cmdArgs}${this.commonServices.enableQueryCaching === 1 ? `&cacheId=${testRun}` : ''}&tierName=${this.compareFPInfo[0]['tierName']}`;
        this.ddrHttpService.getCompareFPInfo(queryParams, 'compareQueries').pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["timeout"])(this.commonServices.ajaxTimeOut)).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_5__["CompareFlowPathLoadedState"]) {
                this.doAssignValuForCompareDBdata(state.data.data);
            }
        }, (error) => {
            console.error('Error in fetching response ~ ', error);
            this.loading = false;
        });
    }
    showError(msg) {
        this.errMsg = [];
        this.errMsg.push({ severity: 'error', summary: 'Error Message', detail: msg });
    }
    doAssignValuForCompareDBdata(data) {
        this.loading = false;
        this.assignCompareQueryData(data);
        this.compareQueryData = data;
        if (this.queryObjArr.length > 0) {
            this.getBarChartsDataBasedOnQuery(this.queryObjArr[0]['query']);
            this.createQueryCountBarChart();
            this.createAvgTimeBarChart();
            this.createCumTimeBarChart();
            this.createErrorCountBarChart();
        }
    }
    clickButtonEvent(event) {
        var _a, _b, _c;
        const me = this;
        console.log('Event: ', event);
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.showQueryrelatedData((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
            this.commonServices.graphInSideBarForDB = true;
        }
    }
    getBarChartsDataBasedOnQuery(query) {
        this.query = query;
        if (this.query.length > 40) {
            this.queryName = this.query.substring(0, 40) + "...";
            this.Completequery = this.query;
        }
        else {
            this.queryName = this.query;
            this.Completequery = this.query;
        }
        var arr = this.compareQueryData[query];
        let queryCountArr = [];
        let avgTimeArr = [];
        let cumTimeArr = [];
        let errorCountArr = [];
        arr.forEach((val, index) => {
            if (arr.length > (index + 1)) {
                if (val['counts'] !== -9999.0)
                    queryCountArr.push({ "name": "FP" + (index + 1), "data": [val['counts']], color: this.colour[index] });
                if (val['avg'] !== -9999.0)
                    avgTimeArr.push({ "name": "FP" + (index + 1), "data": [val['avg']], color: this.colour[index] });
                if (val['cumTime'] !== -9999.0)
                    cumTimeArr.push({ "name": "FP" + (index + 1), "data": [val['cumTime']], color: this.colour[index] });
                if (val['errCounts'] !== -9999.0)
                    errorCountArr.push({ "name": "FP" + (index + 1), "data": [val['errCounts']], color: this.colour[index] });
            }
        });
        this.queryCountArr = queryCountArr;
        this.avgTimeArr = avgTimeArr;
        this.cumTimeArr = cumTimeArr;
        this.errorCountArr = errorCountArr;
    }
    createErrorCountBarChart() {
        let errorCountArr = this.errorCountArr;
        this.options3 = {
            chart: {
                type: 'column',
                width: 320,
                height: (3 / 3.25 * 100) + '%'
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            title: {
                text: ''
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                title: {
                    text: 'Error Count'
                },
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: ''
                }
            },
            plotOptions: {
                column: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    events: {
                        click: function (event) {
                        }.bind(this)
                    },
                    column: {
                        pointPadding: 0.2,
                        borderWidth: 0
                    }
                },
                series: {
                    pointWidth: 25
                }
            },
            series: errorCountArr
        };
    }
    showQueryrelatedData(node) {
        this.queryName = node['query'];
        this.getBarChartsDataBasedOnQuery(node['query']);
        this.createQueryCountBarChart();
        this.createAvgTimeBarChart();
        this.createCumTimeBarChart();
        this.createErrorCountBarChart();
    }
    createCumTimeBarChart() {
        let cumTimeArr = this.cumTimeArr;
        this.options2 = {
            chart: {
                type: 'column',
                width: 320,
                height: (3 / 3.25 * 100) + '%'
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            title: {
                text: ''
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                title: {
                    text: 'Cum Time(ms)'
                },
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: ''
                }
            },
            plotOptions: {
                column: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    events: {
                        click: function (event) {
                        }.bind(this)
                    },
                    column: {
                        pointPadding: 0.2,
                        borderWidth: 0
                    }
                },
                series: {
                    pointWidth: 25
                }
            },
            series: cumTimeArr
        };
    }
    createAvgTimeBarChart() {
        let avgTimeArr = this.avgTimeArr;
        this.options1 = {
            chart: {
                type: 'column',
                width: 320,
                height: (3 / 3.25 * 100) + '%'
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            title: {
                text: ''
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                title: {
                    text: 'Avg Execution Time(ms)'
                },
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: ''
                }
            },
            plotOptions: {
                column: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    events: {
                        click: function (event) {
                        }.bind(this)
                    },
                    column: {
                        pointPadding: 0.2,
                        borderWidth: 0
                    }
                },
                series: {
                    pointWidth: 25
                }
            },
            series: avgTimeArr
        };
    }
    assignCompareQueryData(data) {
        var queryObjArr = [];
        let compQueriesArr = Object.keys(data);
        compQueriesArr.forEach((val, ind) => {
            let queryObj = {};
            let compQueryDataArr = data[val];
            let compQueryDataLength = compQueryDataArr.length;
            compQueryDataArr.forEach((val1, index) => {
                if (val1['query'] != "-9999") {
                    queryObj['query'] = val1['query'];
                }
                if (compQueryDataLength == (index + 1)) {
                    var objectKeys = Object.keys(val1);
                    objectKeys.forEach((val2, index2) => {
                        if (val1[val2] != "-9999")
                            queryObj[val2 + "_Changes"] = (Number(val1[val2]).toFixed(3));
                        else
                            queryObj[val2 + "_Changes"] = "-";
                    });
                }
                else {
                    var objectKeys = Object.keys(val1);
                    objectKeys.forEach((val2, index2) => {
                        if (val1[val2] != "-9999")
                            queryObj[val2 + "_FP" + (index + 1)] = (val1[val2]);
                        else
                            queryObj[val2 + "_FP" + (index + 1)] = "-";
                    });
                }
            });
            console.log(queryObj);
            queryObjArr.push(queryObj);
        });
        this.queryObjArr = queryObjArr;
    }
    createQueryCountBarChart() {
        console.log("queryCount ", this.queryCountArr);
        let queryCountArr = this.queryCountArr;
        this.options = {
            chart: {
                type: 'column',
                width: 320,
                height: (3 / 3.25 * 100) + '%'
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            title: {
                text: ''
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                title: {
                    text: 'Query Count'
                },
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Value'
                }
            },
            plotOptions: {
                column: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    events: {
                        click: function (event) {
                        }.bind(this)
                    },
                    column: {
                        pointPadding: 0.2,
                        borderWidth: 0
                    }
                },
                series: {
                    pointWidth: 25
                }
            },
            series: queryCountArr
        };
    }
    /* Filter Cretira */
    showFilterCriteria() {
        const validCriteria = (field) => field !== "NA" && field !== "" && field !== undefined && field !== "undefined";
        const addFilter = (field, label) => {
            if (validCriteria(this.compareFPInfo[0][field]) && validCriteria(this.compareFPInfo[1][field])) {
                if (this.compareFPInfo[0][field] === this.compareFPInfo[1][field])
                    this.filterCriteriaStr += `, ${label}=${this.compareFPInfo[0][field]}`;
                else
                    this.filterCriteriaStr += `, ${label}=${this.compareFPInfo[0][field]},${this.compareFPInfo[1][field]}`;
            }
        };
        addFilter('tierName', 'Tier');
        addFilter('serverName', 'Server');
        addFilter('appName', 'Instance');
        addFilter('urlName', 'BT');
    }
};
DdrCompareQueriesComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_6__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('value')
], DdrCompareQueriesComponent.prototype, "compareFPInfo", void 0);
DdrCompareQueriesComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-compare-queries',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-compare-queries.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-compare-queries.component.css */ "./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.css")).default]
    })
], DdrCompareQueriesComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.scss":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.scss ***!
  \***************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".right-button {\n  position: absolute;\n  right: 0px;\n  top: -20px;\n}\n\n.helpButton {\n  position: absolute;\n  right: 0px;\n  top: 16px;\n  z-index: 5;\n}\n\napp-ddr-details-view .icons8-columns {\n  font-size: 18px !important;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.ts":
/*!*************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.ts ***!
  \*************************************************************************************/
/*! exports provided: DdrDetailsViewComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrDetailsViewComponent", function() { return DdrDetailsViewComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/common/http */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/http.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/platform-browser */ "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/platform-browser.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-top-panel-navigation.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-top-panel-navigation.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./../../services/ddr-txn-flowmap-data.service */ "./src/app/pages/ddr/services/ddr-txn-flowmap-data.service.ts");















let DdrDetailsViewComponent = class DdrDetailsViewComponent {
    constructor(commonService, flowmapDataService, _ddrData, _navService, _cavConfigService, http, ddrRequest, _router, breadcrumb, sessionService, sanitizer, ndDdrHttpService) {
        this.commonService = commonService;
        this.flowmapDataService = flowmapDataService;
        this._ddrData = _ddrData;
        this._navService = _navService;
        this._cavConfigService = _cavConfigService;
        this.http = http;
        this.ddrRequest = ddrRequest;
        this._router = _router;
        this.sessionService = sessionService;
        this.sanitizer = sanitizer;
        this.ndDdrHttpService = ndDdrHttpService;
        this.indexValue = new _angular_core__WEBPACK_IMPORTED_MODULE_2__["EventEmitter"]();
        this.windowToggle = new _angular_core__WEBPACK_IMPORTED_MODULE_2__["EventEmitter"]();
        this.index = 0;
        this.methodCallTabIndex = 0;
        this.display = false;
        this.showNF = false;
        this.fptypeFlag = false;
        this.errormsgObj = [{ "errorbit": "", "errmsg": "" }];
        this.otelMode = false;
        this.breadcrumb = breadcrumb;
        this.otelMode = this._ddrData.otelMode;
    }
    ngOnChanges() {
        var _a;
        if (window["logLevel"] > 1)
            console.log('inside details ngOnChanges =====', this.flowpathData);
        this.flowpathData = JSON.parse(JSON.stringify(this.flowpathData));
        this.urlParam = this.commonService.getData();
        if (this.urlParam != undefined) {
            if (window["logLevel"] > 1)
                console.log('inside details ngOnChanges =====', this.flowpathData);
            this.flowpathData.product = this.urlParam.product;
            this.flowpathData.testRun = this.urlParam.testRun;
            if ((_a = this.flowpathData.fpDuration) === null || _a === void 0 ? void 0 : _a.toString().includes(','))
                this.flowpathData.fpDuration = this.flowpathData.fpDuration.replace(',', '');
            if (window["logLevel"] > 1)
                console.log('inside details ngOnChanges =====', this.flowpathData);
        }
        this.showNFIcon();
        this.checkNVSessionIDAndNVURL();
        this.handleChange();
    }
    ngOnInit() {
        var _a;
        this.flowpathData = JSON.parse(JSON.stringify(this.flowpathData));
        this.urlParam = this.commonService.getData();
        if (window["logLevel"] > 1)
            console.log("from parent to details data====", this.flowpathData, this.urlParam);
        this.flowpathData.product = this.urlParam.product;
        this.flowpathData.testRun = this.urlParam.testRun;
        if ((_a = this.flowpathData.fpDuration) === null || _a === void 0 ? void 0 : _a.toString().includes(','))
            this.flowpathData.fpDuration = this.flowpathData.fpDuration.replace(',', '');
        if (window["logLevel"] > 1)
            console.log('this.urlParam====', this.urlParam, this.flowpathData);
    }
    handleChange() {
        if (window["logLevel"] > 1)
            console.log('handling change of tabs', this.column);
        if (this._ddrData.ndDCNameInfo && this._ddrData.ndDCNameInfo.length > 0 && this._ddrData.isFromNV && this._ddrData.isFromNV == "1") {
            for (let i = 0; i < this._ddrData.ndDCNameInfo.length; i++) {
                if (this._ddrData.ndDCNameInfo[i].displayName == this.flowpathData.dcName) {
                    this._ddrData.dcName = this.flowpathData.dcName;
                    this._ddrData.testRun = this._ddrData.ndDCNameInfo[i].ndeTestRun;
                    console.log(" test open report in Detail view", this._ddrData.testRun, " ", this._ddrData.dcName);
                    break;
                }
            }
        }
        if (this.column == 'methodsCount') {
            this.index = 0;
            this.column = '';
        }
        else if (this.column == 'btCatagory') {
            this.index = 1;
            this.column = '';
        }
        else if (this.column == 'dbCallCounts') {
            this.index = 2;
            this.column = '';
        }
        else if (this.column == 'urlQueryParamStr') {
            this.index = 3;
            this.column = '';
        }
        else if (this.column == 'totalError') {
            this.index = 4;
            this.column = '';
        }
        else if (this.column == 'fpDuration' || this.column == 'selfResponseTime') {
            this.index = 5;
            this.column = '';
        }
        else if (this.column == 'urlName') {
            this.index = 6;
            this.column = '';
        }
        else if (this.column == 'callOutCount' || this.column == 'startTimeInMs') {
            this.index = 7;
            this.column = '';
            let columnFlowpathData = JSON.parse(JSON.stringify(this.flowpathData));
            this.sessionService.setSetting("fpRowdata", columnFlowpathData);
        }
        else if (this.column == 'flowpathInstance') {
            this.index = 8;
            this.column = '';
        }
        this.indexValue.emit(this.index);
    }
    changeTab(e) {
        this.commonService.hsData = undefined;
        this.index = e.index;
        this.indexValue.emit(this.index);
        if (e.index == 7) {
            this.commonService.column = 'callOutCount';
            let columnFlowpathData = JSON.parse(JSON.stringify(this.flowpathData));
            this.sessionService.setSetting("fpRowdata", columnFlowpathData);
            if (columnFlowpathData.fpDuration == '< 1')
                columnFlowpathData.fpDuration = 0;
            this.flowmapDataService.resetFlag();
        }
        else {
            this.commonService.showTransactionFlowmap = false;
        }
    }
    changeMethodCallTab(e) {
        this.methodCallTabIndex = e.index;
    }
    openED() {
        this._router.navigate(['/exec-dashboard/main/tierStatus']);
    }
    getHostUrl() {
        var hostDcName = this._ddrData.getHostUrl();
        console.log('hostDcName =', hostDcName);
        return hostDcName;
    }
    checkNVSessionIDAndNVURL() {
        let pathParam = 'nd.netvision.querysession';
        this.ndDdrHttpService.getConfigKeywordValue(pathParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ConfigKeywordLoadedState"]) {
                this.checkNVSessionId = state.data.value;
                this.commonService.checkNVSessionId = state.data.value;
            }
        }, (error) => {
            console.error("Getting error in fetching value of nd.netvision.querysession ~~", error);
        });
        let pathParam1 = 'NetVisionUrl';
        this.ndDdrHttpService.getConfigKeywordValue(pathParam1).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ConfigKeywordLoadedState"]) {
                this.NVUrl = state.data.value;
                this.commonService.NVUrl = state.data.value;
            }
        }, (error) => {
            console.error("Getting error in fetching value of NetVisionUrl ~~", error);
        });
    }
    openNVFromND() {
        if (!this.sessionService.preSession.multiDc) {
            // if (this.NVUrl != 'NA') {
            if (this.flowpathData.length == 0) {
                alert("No Flowpath is Selected");
                return;
            }
            else if (this.flowpathData.length > 1) {
                alert("Select Only One Flowpath at a time");
                return;
            }
            else {
                let nvSessionId = 'NA';
                let nvPageId = 'NA';
                let urlForNV;
                if (this.flowpathData) {
                    if (this.flowpathData['nvSessionId'] != '-' && this.flowpathData['nvSessionId'] != '' && this.flowpathData['nvSessionId'] != "0")
                        nvSessionId = this.flowpathData['nvSessionId'];
                    else {
                        alert('NV Session Id is not Available or ' + this.flowpathData['nvSessionId']);
                        return;
                    }
                    if (this.flowpathData['nvPageId'] != '-' && this.flowpathData['nvPageId'] != '')
                        nvPageId = this.flowpathData['nvPageId'];
                    this._router.navigate(['/netvision/sessions-details'], { queryParams: { sid: nvSessionId } });
                }
            }
        }
        else {
            //Supporting for unified dashboard
            let nvSessionId = 'NA';
            let nvPageId = 'NA';
            //let urlForNV;
            // check only one fp is selected as in case of single dc
            if (this.flowpathData.length == 0) {
                alert("No Flowpath is Selected");
                return;
            }
            else if (this.flowpathData.length > 1) {
                alert("Select Only One Flowpath at a time");
                return;
            }
            if (this.flowpathData) {
                if (this.flowpathData['nvSessionId'] != '-' && this.flowpathData['nvSessionId'] != '' && this.flowpathData['nvSessionId'] != "0") {
                    nvSessionId = this.flowpathData['nvSessionId'];
                }
                else {
                    alert('NV Session Id is not Available or ' + this.flowpathData['nvSessionId']);
                    return;
                }
                if (this.flowpathData['nvPageId'] != '-' && this.flowpathData['nvPageId'] != '' && this.flowpathData['nvPageId'] != "0")
                    nvPageId = this.flowpathData['nvPageId'];
                let navigationExtras = {
                    queryParams: { 'cavNVC': nvSessionId,
                        'cavPI': nvPageId }
                };
                sessionStorage.removeItem('__nvSessionData');
                this._router.navigate(['/netvision/sessions-details'], { queryParams: { sid: nvSessionId } });
            }
        }
    }
    openErrorMsg() {
        console.log("We are inside this box for Error Message");
        const payload = { flowpathtype: this.flowpathData.flowpathtype };
        this.ndDdrHttpService.getErroneousFpBitValue(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ErroneousFlowpathLoadedState"]) {
                this.doAssignErrorBitValue(state.data.bitValue);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    doAssignErrorBitValue(res) {
        var array = res.split(',');
        var arrMsg = [];
        array.forEach(val => {
            if (val == '4') {
                arrMsg.push({ "errorbit": val, "errmsg": " This request is redirected to error JSP page due to some internal error or exception." });
            }
            else if (val == '6') {
                arrMsg.push({ "errorbit": val, "errmsg": " JIT Compilation done for some methods in context of this transaction, may impact response time." });
            }
            else if (val == '7') {
                arrMsg.push({ "errorbit": val, "errmsg": " Test stopped but current transaction found active." });
            }
            else if (val == '9') {
                arrMsg.push({ "errorbit": val, "errmsg": " Flowpath Header is missing for current  request." });
            }
            else if (val == '10') {
                arrMsg.push({ "errorbit": val, "errmsg": " This is an Incomplete Flowpath." });
            }
            else if (val == '11') {
                arrMsg.push({ "errorbit": val, "errmsg": " Current Flowpath has abnormal method entry-exit timings." });
            }
            else if (val == '12') {
                arrMsg.push({ "errorbit": val, "errmsg": " Response time of transaction is more than configured threshold value of response time (Default 5 Min) so capturing of transaction is terminated by agent." });
            }
        });
        this.errormsgObj = arrMsg;
        console.log('this.errormessageObj?>>>>>>>>>>>', this.errormsgObj);
        this.fptypeFlag = true;
    }
    showNFIcon() {
        let pathParam = 'NetForestUrl';
        this.ndDdrHttpService.getConfigKeywordValue(pathParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ConfigKeywordLoadedState"]) {
                this.netForestURL = state.data.value;
                if (this.netForestURL != undefined && this.netForestURL != 'NA') {
                    this.showNF = true;
                    let pathParam = 'NetDiagnosticsQueryTimeVariance';
                    this.ndDdrHttpService.getConfigKeywordValue(pathParam).subscribe((state) => {
                        if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ConfigKeywordLoadedState"]) {
                            this.netForestURL = state.data.value;
                        }
                    }, (error) => {
                        console.error("Getting Error in fetching value of NetDiagnosticsQueryTimeVariance ~~", error);
                    });
                }
                else {
                    this.showNF = false;
                }
            }
        }, (error) => {
            console.error("Getting Error in fetching value of NetForestUrl ~~", error);
        });
    }
    openNetForest() {
        let flowpathInstance;
        let correlationId;
        let startTimeInMs;
        let duration;
        let ndSessionId;
        let nvPageId;
        let query;
        if (this.flowpathData.length == 0) {
            alert("No Record Selected");
            return;
        }
        else if (this.flowpathData.length > 1) {
            alert("Please select only one flowpath.");
            return;
        }
        else {
            flowpathInstance = this.flowpathData["flowpathInstance"];
            correlationId = this.flowpathData["correlationId"];
            startTimeInMs = this.flowpathData["startTimeInMs"];
            duration = this.flowpathData["fpDuration"];
            ndSessionId = this.flowpathData["ndSessionId"];
            nvPageId = this.flowpathData["nvPageId"];
            // }
            query = "fpi:" + flowpathInstance;
            console.log("duration = ", duration);
            let d1 = Number(startTimeInMs) - Number(this.timeVarianceInMs(this.timeVarienceForNF));
            let d2;
            if (duration == '< 1')
                d2 = Number(startTimeInMs) + Number(this.timeVarianceInMs(this.timeVarienceForNF));
            else
                d2 = Number(startTimeInMs) + Number(duration.replace(/,/g, '')) + Number(this.timeVarianceInMs(this.timeVarienceForNF));
            console.log("start time from FP To NF = " + d1);
            console.log("end time from FP To NF = " + d2);
            let startTimeISO = d1;
            let endTimeISO = d2;
            console.log("startTimeISO = ", startTimeISO, ", endTimeISO = ", endTimeISO);
            if (correlationId != "" && correlationId != "-")
                query += "%20AND%20corrid:" + correlationId;
            if (nvPageId != "" && nvPageId != "-")
                query += "%20AND%20pageid:" + nvPageId;
            if (ndSessionId != "" && ndSessionId != "-")
                query += "%20AND%20ndsessionid:" + ndSessionId;
            query = "( " + query + " )";
            query = query.replaceAll("%20", " ");
            this._router.navigate(["/home/logs"], { queryParams: { queryStr: query, startTime: startTimeISO, endTime: endTimeISO } });
        }
    }
    timeVarianceInMs(time) {
        var timeVarianceInMs = time;
        var timeVarNum = "";
        if (/^[0-9]*h$/.test(time)) //If time is in hour formate- xh eg:2h means 2 hour variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 60 * 60 * 1000;
        }
        else if (/^[0-9]*m$/.test(time)) //If time is in minute formate- xm eg:20m means 20 minute variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 60 * 1000;
        }
        else if (/^[0-9]*s$/.test(time)) //If time is in second formate- xs eg:200s means 200 second variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 1000;
        }
        else if (/^[0-9]*ms$/.test(time)) //If time is in millisecond formate- xs eg:200ms means 200 millisecond variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 2);
            timeVarianceInMs = Number(timeVarNum);
        }
        else if (/^[0-9]*$/.test(time)) // if there is only number, it is considered as seconds 
         {
            timeVarianceInMs = Number(time) * 1000;
        }
        else {
            //alert("Please provide value of 'NetDiagnosticsQueryTimeVariance' in proper format in config.ini i.e.- Nh or Nm or Ns or Nms or N where N is a integer ");
            return Number(900000); //if value of ndQueryTimeVariance is not in desired format then NF report will open with default variance time that is 15 minutes(900000ms).
        }
        return Number(timeVarianceInMs);
    }
    closeSession() {
        this.breadcrumb.removeAll(false);
        this.breadcrumb.add({ label: 'Flowpath', routerLink: '/ddr/flowpath' });
        this._ddrData.splitViewBreadCrumbFlag = false;
        this._ddrData.dbFlag = false;
        this._ddrData.flowpathToExFlag = false;
        this.commonService.httpFlag = false;
        this.commonService.hsFlag = false;
        sessionStorage.setItem("dbFlag", 'false');
        this.windowToggle.emit(true);
    }
    closeExcpReport(event) {
        if (event === false) {
            this.closeSession();
        }
    }
};
DdrDetailsViewComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_10__["CommonServices"] },
    { type: _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_14__["DdrTxnFlowmapDataService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_9__["CavTopPanelNavigationService"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_8__["CavConfigService"] },
    { type: _angular_common_http__WEBPACK_IMPORTED_MODULE_1__["HttpClient"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_11__["DDRRequestService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["BreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_6__["SessionService"] },
    { type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_3__["DomSanitizer"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_12__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], DdrDetailsViewComponent.prototype, "flowpathData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], DdrDetailsViewComponent.prototype, "column", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Output"])()
], DdrDetailsViewComponent.prototype, "indexValue", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Output"])()
], DdrDetailsViewComponent.prototype, "windowToggle", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["ViewChild"])('trx')
], DdrDetailsViewComponent.prototype, "trx", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["ViewChild"])('trxFrame')
], DdrDetailsViewComponent.prototype, "trxFrame", void 0);
DdrDetailsViewComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Component"])({
        selector: 'app-ddr-details-view',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-details-view.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_2__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-details-view.component.scss */ "./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.scss")).default]
    })
], DdrDetailsViewComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.css":
/*!****************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.css ***!
  \****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.ts":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.ts ***!
  \***************************************************************************************/
/*! exports provided: DdrHeaderTopNavBarComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrHeaderTopNavBarComponent", function() { return DdrHeaderTopNavBarComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/common */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
/* harmony import */ var _constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../constants/ns-ddr-header.constants */ "./src/app/pages/ddr/constants/ns-ddr-header.constants.ts");





let DdrHeaderTopNavBarComponent = class DdrHeaderTopNavBarComponent {
    constructor(commonService, _location) {
        this.commonService = commonService;
        this._location = _location;
        this.isShowHelp = false;
        this.subModuleName = "";
        this.helpObject = _constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_4__["NS_DDR_HELP"];
    }
    ngOnChanges(changes) {
        this.getHelpContentSubModuleName();
    }
    ngOnInit() {
    }
    back() {
        this._location.back();
    }
    getHelpContentSubModuleName() {
        for (let key in this.helpObject) {
            if (key == this.commonService.currentReport) {
                this.isShowHelp = true;
                this.subModuleName = this.helpObject[key];
                break;
            }
            else {
                this.isShowHelp = false;
            }
        }
    }
};
DdrHeaderTopNavBarComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_common__WEBPACK_IMPORTED_MODULE_3__["Location"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrHeaderTopNavBarComponent.prototype, "currentReport", void 0);
DdrHeaderTopNavBarComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-header-top-nav-bar',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-header-top-nav-bar.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-header-top-nav-bar.css */ "./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.css")).default]
    })
], DdrHeaderTopNavBarComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.css":
/*!********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.css ***!
  \********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (":host>>>.ui-paginator{\n    border: none !important; \n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.ts":
/*!*******************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.ts ***!
  \*******************************************************************************/
/*! exports provided: DdrPaginator */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrPaginator", function() { return DdrPaginator; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");


// import { Paginator } from 'primeng/api';


//import { CavConfigService } from '../../../tools/configuration/nd-config/services/cav-config.service';
let DdrPaginator = class DdrPaginator {
    //@ViewChild('pp') paginator: Paginator;
    constructor(commonService, _ddrData) {
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this.first = 10;
        this.paginateData = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
    }
    ngOnChanges() {
        if (this.limit == 50)
            this.commonService.rowspaerpage = 50;
        if (((this.totalCount >= this.offset + this.limit) || this.totalCount > 50)
            && this._ddrData.isFromNV && this._ddrData.isFromNV != 'NA'
            && Number(this._ddrData.isFromNV) == 1 && sessionStorage.getItem("isMultiDCMode") == "true") {
            this.nvFlag = true;
            setTimeout(() => {
                if (document.getElementById("tnv")) {
                    document.getElementById("tnv").children[0].children[0].children[0].className = "";
                    document.getElementById("tnv").children[0].children[0].children[4].className = "";
                    if (document.getElementById("tnv").children[0].children[0].children[0].children[0])
                        document.getElementById("tnv").children[0].children[0].children[0].children[0].className = "";
                    if (document.getElementById("tnv").children[0].children[0].children[4].children[0])
                        document.getElementById("tnv").children[0].children[0].children[4].children[0].className = "";
                }
                //console.log('document.getElementById("tnv").children[0].children[0].children[0].className ',document.getElementById("tnv").children[0].children[0].children[0].className);
            }, 1000);
        }
        else
            this.nvFlag = false;
        console.log('this._ddrData.isFromNV total count', this._ddrData.isFromNV, this.totalCount, ' ', this.limit, ' ', this.offset);
    }
    ngOnInit() {
        // console.log('this._ddrData.isFromNV total count',this._ddrData.isFromNV, this.totalCount, ' ', this.limit, ' ', this.offset);
    }
    paginate(event) {
        // event.first = Index of the first record  (used  as offset in query) 
        // event.rows = Number of rows to display in new page  (used as limit in query)
        // event.page = Index of the new page
        // event.pageCount = Total number of pages
        console.log('paginate event====>', event);
        if (this._ddrData.isFromNV && this._ddrData.isFromNV == '1') {
            if (this.commonService.rowspaerpage != event.rows) {
                //this.paginator.changePage(0);
                //this.paginator.changePageToFirst(event);
                this._ddrData.nvFirstPage = true;
                this.commonService.rowspaerpage = event.rows;
                event.first = 0;
                this.first = 0;
            }
            else {
                this.first = 10;
                this._ddrData.nvFirstPage = false;
                this.commonService.rowspaerpage = event.rows;
            }
        }
        else {
            this.commonService.rowspaerpage = event.rows;
        }
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        if (this.limit > this.totalCount) {
            this.limit = Number(this.totalCount);
        }
        if ((this.limit + this.offset) > this.totalCount) {
            this.limit = Number(this.totalCount) - Number(this.offset);
        }
        this.commonService.fpLimit = this.limit;
        this.commonService.fpOffset = this.offset;
        this.paginateData.emit({ 'limit': this.limit, 'offset': this.offset });
    }
};
DdrPaginator.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__["DdrDataModelService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrPaginator.prototype, "limit", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrPaginator.prototype, "offset", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrPaginator.prototype, "totalCount", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"])()
], DdrPaginator.prototype, "paginateData", void 0);
DdrPaginator = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: '<app-ddr-paginator>',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-paginator.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-paginator.component.css */ "./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.css")).default]
    })
], DdrPaginator);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.css":
/*!**************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.css ***!
  \**************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("\r\n.graphDiv1 {\r\n  width: 425px;\r\n  height: 174px;\r\n  float: left;\r\n  font-size: 12px;\r\n  border-style: solid;\r\n  border-width: 1px;\r\n}\r\n\r\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.ts":
/*!*************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.ts ***!
  \*************************************************************************************************/
/*! exports provided: DdrShowRelatedGraphComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrShowRelatedGraphComponent", function() { return DdrShowRelatedGraphComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! moment */ "./node_modules/moment/moment.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! moment-timezone */ "./node_modules/moment-timezone/index.js");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_4__);


// import { ChartModule } from 'angular2-highcharts';
// import { NgGridConfig, NgGridItemConfig, NgGridItemEvent } from '../../../../../interfaces/INgGrid';



let DdrShowRelatedGraphComponent = class DdrShowRelatedGraphComponent {
    constructor() {
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_4__;
    }
    ngOnInit() {
        console.log('value-------', this.graphValue);
        console.log('json value', this.json);
        this.createChart();
    }
    createChart() {
        var jsonObj = this.json;
        var graphVal = this.graphValue;
        var jsonVal = [jsonObj.edRelatedGraphData[graphVal['grapghIndex']]];
        console.log('zone--', this.json['timeZone'], jsonVal);
        this.options = {
            chart: {
                type: 'spline',
                height: 170,
                width: 420,
                responsive: true,
                zoomType: 'x'
            },
            credits: {
                enabled: false
            },
            title: {
                text: this.graphValue['graphName'],
                style: { fontSize: '12px' }
            },
            tooltip: {
                tooltip: {
                    formatter: function () {
                        return '<b>Time: </b>' + moment__WEBPACK_IMPORTED_MODULE_2__["tz"](this.x, jsonObj['timeZone']).format('MM/DD/YY HH:mm:ss') +
                            '<br/ ><b>Value: ' + '</b>' + this.y;
                    }
                },
            },
            legend: {
                itemStyle: {
                    color: 'rgb(29, 181, 18)',
                    fontWeight: 'bold',
                    fontSize: '9px'
                },
                itemHoverStyle: {
                    color: 'rgb(29, 220, 20)'
                },
                itemDistance: 5,
                padding: 0,
                margin: 0,
                labelFormatter: function () {
                    let index = (this.name).indexOf('-');
                    if (index !== -1) {
                        return (this.name).substring(0, index) + '<br/>' + (this.name).substring(index, (this.name).length);
                    }
                    else {
                        return this.name;
                    }
                },
                enabled: false
            },
            yAxis: {
                title: {
                    text: ''
                },
                min: 0
            },
            xAxis: {
                type: 'time',
                labels: {
                    formatter: function () {
                        return moment__WEBPACK_IMPORTED_MODULE_2__["tz"](this.value, jsonObj['timeZone']).format('HH:mm:ss');
                    },
                    style: {
                        fontSize: '8px'
                    }
                },
                plotBands: [{
                        color: '#e4f9a6',
                        from: jsonObj.startTime,
                        to: jsonObj.endTime
                    }]
            },
            series: jsonVal
        };
    }
    saveChart(chartInstance) {
        this.chart = chartInstance;
    }
};
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('graphValue')
], DdrShowRelatedGraphComponent.prototype, "graphValue", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('json')
], DdrShowRelatedGraphComponent.prototype, "json", void 0);
DdrShowRelatedGraphComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-show-related-graph',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-show-related-graph.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-show-related-graph.component.css */ "./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.css")).default]
    })
], DdrShowRelatedGraphComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.scss":
/*!*******************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.scss ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-ddr-side-bar p-accordion {\n  width: 100%;\n}\napp-ddr-side-bar p-accordion .ui-accordion-content {\n  float: left;\n  width: 100%;\n  display: block;\n  padding: 0px !important;\n}\napp-ddr-side-bar .side-bar-height {\n  height: 30px;\n}\napp-ddr-side-bar .sidedbar-accordion {\n  background-color: var(--background_color_1);\n}\napp-ddr-side-bar .sidedbar-accordion .overflow {\n  height: calc(100vh - 143px);\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.ts":
/*!*****************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.ts ***!
  \*****************************************************************************/
/*! exports provided: DdrSideBarComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrSideBarComponent", function() { return DdrSideBarComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/ddr-message.service */ "./src/app/pages/ddr/services/ddr-message.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! moment */ "./node_modules/moment/moment.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_8__);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! moment-timezone */ "./node_modules/moment-timezone/index.js");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_9__);
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/ddr/services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");




//import 'rxjs/add/operator/toPromise';




// import {CommonTagRow, CommonTagSubjects, GTag, GTags, SubjectTag, TagChipsObj} from 'src/app/shared/common-Tag/service/common-tag.model'
// import { ConfigurationSettingsModule } from 'src/app/pages/tools/configuration/configuration-settings/configuration-settings.module';




let DdrSideBarComponent = class DdrSideBarComponent {
    constructor(commonServices, _router, messageService, _ddrData, ddrRequest, sessionService, ndDdrHttpService
    //private nsCommonData: NsCommonService
    ) {
        this.commonServices = commonServices;
        this._router = _router;
        this.messageService = messageService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.items = [];
        this.failure = false;
        //NV Filters
        this.isCheckedSessionId = false;
        this.isCheckedPageId = false;
        this.isCheckedNVSessionID = false;
        this.selectedGroupBy = [];
        this.groupBy = [];
        this.orderBy = [];
        this.selectedOrderBy = [];
        this.groupByFC = []; // variables for groupby Filter Criteria
        this.orderByFC = []; // variables for orderby Filter Criteria
        //Buisness Transaction 
        this.BTOptions = [];
        this.checkedBuisnessTransaction = false;
        //Integration Point
        this.IntegrationPoint = [];
        this.selectedIntegrationPoint = [];
        this.selectedIpName = [];
        this.fpInstance = "";
        this.tierId = [];
        this.tierName = [];
        this.tierNameFC = "default";
        this.serverId = [];
        this.serverName = [];
        this.serverNameFC = "default";
        this.appId = [];
        this.appName = [];
        this.appNameFC = "default";
        //url status variables
        this.selectedUrlStatus = "-2";
        this.failureIdNameObj = {};
        this.selectedFailureId = [];
        this.selectedFailureNameId = "-2";
        this.reportList = [{ label: 'Flowpath', value: 'Flowpath' }, { label: 'Flowpath GroupBy', value: 'FlowpathGroupBy' }, { label: 'DB Report', value: 'DB Report' }, { label: 'DB GroupBy', value: 'DBGroupBy' }, { label: 'Exception', value: 'Exception' }, { label: 'Method Timing', value: 'Method Timing' }, { label: 'Hotspot', value: 'Hotspot' }, { label: 'IP Summary', value: 'IP Summary' }];
        this.resCompareOptions = [{ label: '<=', value: '1' }, { label: '>=', value: '2' }, { label: '=', value: '3' }];
        this.resSelectedCompareOption = '1';
        this.showingEqualResponseBox = false;
        this.responseTimeMessage = false;
        this.corrIdModeOptions = [{ label: 'Exact', value: 1 }, { label: 'StartsWith', value: 2 }, { label: 'EndsWith', value: 3 }, { label: 'Contains', value: 4 }];
        // --correlation_mode 1  --correlation_id "34" 
        //Bt category variables
        this.BTCategory = [{ label: 'Normal', value: '10' }, { label: 'Slow', value: '11' }, { label: 'Very Slow', value: '12' }, { label: 'Errors', value: '13' }];
        this.queryData = {};
        this.selectedFP = false;
        //Query Type vriables
        this.queryTypeOptions = [{ label: 'Select', value: { id: 1 } }, { label: 'Insert', value: { id: 2 } }, { label: 'Update', value: { id: 3 } }, { label: 'Delete', value: { id: 4 } }, { label: 'Create', value: { id: 5 } }, { label: 'Drop', value: { id: 6 } }];
        this.standselect = false;
        this.custselect = false;
        //**********----NS Filter -----------*****
        this.checkedUrl = false;
        this.urlOptions = [];
        this.pageOptions = [];
        this.scriptOptions = [];
        this.transactionOptions = [];
        this.locationOptions = [];
        this.browserOptions = [];
        this.accessOptions = [];
        this.message = {};
        this.exceptionPopup = false;
        this.testRunMode = false;
        // previousReport : string ;
        //For limit and offset
        this.btLimit = 1000;
        this.btOffset = 0;
        this.nxt = false;
        this.btEndValue = 1000; // used to show the pagination in BT
        this.prev = false;
        //fp order by 
        this.fpOrderByOptions = [{ label: 'Processing Time', value: 'fpduration_desc' }, { label: 'Callout Errors', value: 'error_callout' }, { label: 'CPU Time', value: 'btcputime_desc' }];
        this.fpOrderByCheck = false;
        //db order by
        this.dbOrderByOptions = [{ label: 'Response Time', value: 'exec_time_desc' }, { label: 'Count', value: 'count_desc' }, { label: 'Error Count', value: 'query_count' }];
        this.dbOrderByCheck = false;
        //multidc
        this.isMultiDC = false;
        this.dcList = [];
        this.protocol = '//';
        this.dcProtocol = '//';
        this.host = '';
        this.port = '';
        //akshay new design test variables
        this.showReportField = true;
        this.showScriptFilter = false;
        this.showCommonFilters = true;
        this.TickOrder = false;
        this.TickGroup = false;
        this.TickScript = false;
        this.TickScriptId = false;
        this.TickPage = false;
        this.TickPageId = false;
        this.TickUrl = false;
        this.TickUrlId = false;
        this.TickTransaction = false;
        this.TickTransactionId = false;
        this.TickStrTime = false;
        this.TickEndTime = false;
        this.TickLocation = false;
        this.TickAccess = false;
        this.TickBrowser = false;
        this.TickStatus = false;
        this.checkBoxUrl = true;
        this.checkBoxPage = true;
        this.checkBoxTransaction = true;
        this.seqUrl = true;
        this.hintUrl = '';
        this.hintPage = '';
        this.hintTransaction = '';
        this.showNSFilter = false;
        this.urlFilterCount = 0;
        this.urlLimit = 8;
        this.urlOffset = 0;
        this.showUrlPagination = false;
        this.transLimit = 8;
        this.transOffset = 0;
        this.transFilterCount = 0;
        this.showTransactionPagination = false;
        this.showPagePagination = false;
        this.pageOffset = 0;
        this.pageLimit = 8;
        this.urlEndValue = 0;
        this.nxtUrl = false;
        this.prevUrl = false;
        this.scriptGroup = false;
        this.groupByFilter = [];
        this.showLAB = false;
        this.sideheight = "auto";
        this.showStartTimeError = false;
        this.showEndTimeError = false;
        this.customStartTimeError = "Please Provide Start Time";
        this.customEndTimeError = "Please Provide End Time";
        this.showSaveError = false;
        this.saveQueryError = "Please Provide Query name";
        this.showQueryError = false;
        this.QueryError = "Please enter Alphanumeric Text";
        this.endDateObj = new Date();
        this.startDateObj = new Date();
        this.customTimeError = false;
        this.customTimeErrorMessage = "Start time should be less than End time";
        this.showSaveQuery = false;
        this.savedQueriesObject = [];
        this.addDescription = '';
        this.queryName = '';
        this.selectAnyCheckBoxFlag = false;
        this.showAnyCheckBoxErrorMessage = "Please select any check option";
        this.selectCheckBoxFlag = false;
        this.showCheckBoxErrorMessage = "Please select atleast one value";
        this.selectResponseCheckBoxFlag = false;
        this.selectResponseCheckBoxFlag1 = false;
        this.showInputFieldErrorMessage = "Please provide some value";
        this.selectGroupByCheckBoxFlag = false;
        this.selectOrderByCheckBoxFlag = false;
        this.selectScriptCheckBoxFlag = false;
        this.selectTransactionCheckBoxFlag = false;
        this.selectPageCheckBoxFlag = false;
        this.selectUrlCheckBoxFlag = false;
        this.selectFailureTypeFlag = false;
        this.selectTierFlag = false;
        this.selectServerFlag = false;
        this.selectAppFlag = false;
        this.selectBTFlag = false;
        this.selectBTCategoryFlag = false;
        this.selectCheckNQuerryFlag = false;
        this.selectDBOrderByCheckFlag = false;
        this.selectIsMultiDCCheckFlag = false;
        this.selectExceptionClassFlag = false;
        this.selectedExceptionThrowingClassFlag = false;
        this.selectedExceptionThrowingMethodFlag = false;
        this.selectedExceptionCauseTypeFlag = false;
        this.selectedExceptionMessageTypeFlag = false;
        this.selectedStackFlag = false;
        this.selectfpInstanceFlag = false;
        this.selectedCorrIdModeFlag = false;
        this.selectedCorrIdModeFlag1 = false;
        this.selectedCorrIdModeFlag2 = false;
        this.selectedFpOrderByFlag = false;
        this.selectedminMethodsFlag = false;
        this.selectedTopNEntityFlag = false;
        this.selectIntegrationPointFlag = false;
        this.ndSessionIdFlag = false;
        this.nvPageIdFlag = false;
        this.nvSessionIdFlag = false;
        //DL and req/resp flag
        this.checkReqRespFlag = false;
        this.checkDLFlag = false;
        this.URLInfoLoading = false;
        this.dataChangeDetected = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        console.log("coming in constructor of  sidebar");
    }
    ngOnInit() {
        this.selectedUrlStatus = '-2';
        console.log("coming here in sidebar ngOnit");
        if (this.commonServices.currentReport == "Hotspot" ||
            this.commonServices.currentReport == "IP Summary" ||
            this.commonServices.currentReport == "DBGroupBy" ||
            this.commonServices.currentReport == "Method Timing" ||
            this.commonServices.currentReport == "FlowpathGroupBy") {
            this.sideheight = "556px";
        }
        console.log("************ddr-side-bar*********** loading");
        this.urlParam = this.commonServices.getData();
        if (sessionStorage.getItem("isMultiDCMode") !== 'true')
            this.getMultiDCInfo();
        this._ddrData.getWanEnV();
        setTimeout(() => {
            if (this._ddrData.WAN_ENV)
                this.showLAB = true;
            else
                this.showLAB = false;
        }, 2000);
        this.getTRMode();
        //  this.commonServices.nsAutoFill$.subscribe((data)=>{   console.log(data,"**********************========>");});
        //commenting this part due to migration prupose
        // need to change the below conditions for ED
        // if (this._router.url.indexOf('?') != -1) {
        //   console.log("ED case");
        //   let queryParams1 = location.href.substring(location.href.indexOf('?') + 1, location.href.length);
        //   this.urlParam = JSON.parse('{"' + decodeURI(queryParams1).replace(/"/g, '\\"').replace(/&/g, '","').replace(/=/g, '":"') + '"}');
        //   console.log("In ED case--",);
        // }
        console.log("urlParam-", this.urlParam);
        setTimeout(() => {
            this.commonServices.previousReport = this.commonServices.currentReport;
            console.log("report type inside ngonit at loading--", this.commonServices.previousReport);
        }, 2000);
        console.log('this.subscription===ngOnit==');
        this.subscription = this.messageService.getMessage().subscribe(message => {
            console.log('message====>', message);
            this.message = message;
            console.log("subscription message  =====" + this.message);
            if (this.commonServices.currentReport == 'Exception') {
                this.checkGroup = true;
                this.getGroupBy();
                this.selectedGroupBy.push('excclass');
                this.selectedGroupBy.push('excthrowingclass');
                this.selectedGroupBy.push('excthrowingmethod');
            }
            else if (this.commonServices.currentReport == 'Flowpath') {
                this.applyFilteredValueInSideBar(); // flowpath auto fill case
                this.checkGroup = false;
                this.selectedGroupBy = [];
            }
            else {
                this.checkGroup = false;
                this.selectedGroupBy = [];
            }
        });
        // this.reportType = this.commonServices.currentReport ;
        //console.log("this.urlParam--" ,this.urlParam);
        this.screenHeight = Number(this.commonServices.screenHeight) - 79;
        console.log('loading.........');
        this.id = this.urlParam;
        this.mode = this.id.product;
        console.log("not calling dc data");
        //  this.id = this.commonServices.getData();
        // if (undefined != this.commonServices.dcNameList && null != this.commonServices.dcNameList && this.commonServices.dcNameList != '') 
        // { console.log("this.commonServices.dcNameList-------",this.commonServices.dcNameList)
        //   this.getDCData().then(() => {
        //     console.log("going to call dcdata ");      
        //     console.log("after call multidc");
        //   })   
        // }
        this.checkNSFilter();
        this.showGroupBy();
        this.commonServices.nsAutoFillObservable$.subscribe(data => {
            console.log("data got sybscribed in ddr side bar ***************** ", data, " *********************", this._ddrData.nsCqmAutoFill);
            this.assignAutoFillUI(data);
        });
        this.assignAutoFillUI(this.commonServices.currentReport, 'moving forward'); // should work when ddr is destroyed and then loaded again.
        this.assignAutoFillData(this.commonServices.currentReport);
    }
    ngAfterViewInit() {
        this.getTags();
    }
    getTags() {
        if (this.commonTag)
            this.commonTag.show(1, false, -1, null);
    }
    assignAutoFillUI(currentReport, forwardFlow) {
        console.log("this._ddrData.nsCqmAutoFill ********** ", this._ddrData.nsCqmAutoFill[currentReport], "****forwardFlow****", forwardFlow);
        if (currentReport == "URL Instance" || this.selectAnyCheckBoxFlag) {
            this.showSaveQuery = false;
        }
        if (this._ddrData.nsCqmAutoFill[currentReport]) {
            let keyValue = this._ddrData.nsCqmAutoFill[currentReport];
            let keyParam = Object.keys(this._ddrData.nsCqmAutoFill[currentReport]);
            console.log("keys param are******* ", keyParam);
            if (currentReport == "URL Instance" || this.selectAnyCheckBoxFlag) {
                this.showSaveQuery = false;
            }
            else {
                this.showSaveQuery = true;
            }
            // reportVal['checkedTimeFIlter']=this.timeFilter;
            if (keyValue['checkedTimeFIlter']) {
                if (keyParam.includes('startTime') && keyParam.includes('EndTime')) {
                    this.timeFilter = true; //check box of time filter being set true.
                    this.timeOptions(); //will be called automatically.
                    if (keyValue['selectedTime'])
                        this.selectedTime = keyValue['selectedTime'];
                    if (keyValue['customStartTime'] && keyValue['customEndTime']) {
                        this.strDate = keyValue['customStartTime'];
                        this.endDate = keyValue['customEndTime'];
                        this.strTimeInDateFormat = keyValue['customStartTime'];
                        this.endTimeInDateFormat = keyValue['customEndTime'];
                    }
                    else {
                        this.strDate = null;
                        this.endDate = null;
                        this.strTimeInDateFormat = null;
                        this.endTimeInDateFormat = null;
                    }
                    //console.log("this.selectedTime **********",this.selectedTime);
                    //if(keyParam['Custom Time'])
                }
                if (keyValue['PhaseId']) {
                    this.selectedTime = 'Specified Phase';
                    this.getPhaseOptions();
                    this.selectedPhase.id = keyValue['PhaseId'];
                    this.selectedPhase.name = keyValue['PhaseName'];
                    //  console.log("selected Phase***********",this.selectedPhase);
                }
            }
            else {
                this.timeFilter = false;
                this.selectedTime = '';
            }
            if (keyValue['ResponseTime'] && keyValue['ResponseTimeMode']) {
                this.checkedResponseTime = true;
                this.responseCheck();
                this.resSelectedCompareOption = keyValue['ResponseTimeMode']; //drop down option
                this.responseTime = keyValue['ResponseTime']; //value
            }
            else {
                this.checkedResponseTime = false;
                this.responseCheck();
            }
            if (keyValue['Group']) {
                if (this.showGroupBy()) {
                    this.checkGroup = true;
                    this.getGroupBy();
                    this.selectedGroupBy = keyValue['Group'];
                    this.getOrderBy();
                    this.enableOrderBy();
                    //console.log("this.selectedGroupBy *********",this.selectedGroupBy);
                }
            }
            else {
                this.checkGroup = false;
                this.selectedGroupBy = [];
            }
            if (keyValue['Order']) {
                this.enableOrderBy();
                this.getOrderBy();
                this.checkOrder = true;
                this.selectedOrderBy = keyValue['Order'];
                //console.log("this.checkOrder *****",this.checkOrder);
            }
            if (keyValue['StrOrderBy']) { //This is the case of Nd reports AutoFill
                this.getOrderByFC();
                this.fpOrderByCheck = true;
                this.selectedFpOrderBy = keyValue['StrOrderBy'];
            }
            if (keyValue['DBOrderBy']) {
                this.dbOrderByCheck = true;
                this.selectedDbOrderBy = keyValue['DBOrderBy'];
            }
            //  StatusName StatusId (status is 0 for Success only, positive for the Failure code, -1 for all failures -2 for All (Success and all failures))
            //positive for the Failure code  
            if (keyValue['StatusName'] && keyValue['StatusId']) {
                if (keyValue['StatusId'] == -1 || keyValue['StatusId'] == 0 || keyValue['StatusId'] == -2) {
                    this.selectedUrlStatus = keyValue['StatusId'];
                    this.selectedFailureId = [];
                    this.failure = false;
                }
                else //getting +ve error codes thats for faliure codes.
                 {
                    this.selectedUrlStatus = '4'; // to make radio button of failure code get selected ****
                    this.fetchMetadata('errorcodes');
                    this.failure = true;
                    let errorCode = keyValue['StatusId'].split(',');
                    this.selectedFailureId = errorCode;
                    //  console.log('errorCode **************', errorCode);
                }
            }
            else {
                this.failure = false;
                this.selectedFailureId = [];
                this.selectedUrlStatus = "-2";
            }
            if (keyValue['TransactionName'] && keyValue['TransactionId']) {
                this.checkBoxTransaction = true;
                this.checkedTransaction = true;
                this.fetchMetadata('transaction');
                this.selectedTransaction = {};
                this.selectedTransaction['name'] = keyValue['TransactionName'];
                this.selectedTransaction['id'] = keyValue['TransactionId'];
                //console.log("this.selectedTransaction ******************** ",this.selectedTransaction);
            }
            else {
                this.checkedTransaction = false;
                this.selectedTransaction = null;
                //console.log("Transaction has been turned off *********");
            }
            if (keyValue['UrlName'] && keyValue['UrlId']) {
                this.checkBoxUrl = true;
                this.checkedUrl = true;
                this.getUrlInfo();
                this.selectedUrl = {};
                this.selectedUrl['name'] = keyValue['UrlName'];
                this.selectedUrl['id'] = keyValue['UrlId'];
                this.checkInfo();
                //console.log("this.selectedUrl ************ ",this.selectedUrl);  
            }
            else {
                this.checkedUrl = false;
                this.selectedUrl = null;
            }
            if (keyValue['PageName'] && keyValue['PageId']) {
                this.checkBoxPage = true;
                this.fetchMetadata('page');
                this.checkedPage = true;
                this.selectedPage = {};
                this.selectedPage['name'] = keyValue['PageName'];
                this.selectedPage['id'] = keyValue['PageId'];
                //console.log("this.selectedPage ********************* ",this.selectedPage);
            }
            else {
                this.checkedPage = false;
                this.selectedPage = null;
            }
            if (keyValue['ScriptName'] && keyValue['ScriptId']) {
                try {
                    this.checkedScript = true;
                    this.fetchMetadata('script');
                    this.selectedScript = {};
                    this.selectedScript['name'] = keyValue['ScriptName'];
                    this.selectedScript['id'] = keyValue['ScriptId'];
                    //console.log("this.selectedScript *************  ",this.selectedScript);
                }
                catch (error) {
                    console.log(error, " ****************error *********************");
                }
            }
            else {
                this.checkedScript = false;
                this.selectedScript = null;
            }
            if (keyValue['Location']) {
                this.fetchMetadata('location');
                this.selectedLocation.name = keyValue['Location'];
                //console.log(" this.selectedLocation.name ********** ",this.selectedLocation.name);
            }
            else {
                this.checkedLocation = false;
                this.selectedLocation = undefined;
            }
            if (keyValue['Browser']) {
                this.fetchMetadata('browser');
                this.selectedBrowser.name = keyValue['Browser'];
                // console.log("this.selectedBrowser.name ************  ",this.selectedBrowser.name);
            }
            else {
                this.checkedBrowser = false;
                this.selectedBrowser = undefined;
            }
            if (keyValue['Access']) {
                this.fetchMetadata('access');
                this.selectedAccess.name = keyValue['Access'];
                // console.log("this.selectedAccess.name ************ ",this.selectedAccess.name);
            }
            else {
                this.selectedAccess = undefined;
                this.checkedAccess = false;
            }
            var splitTier;
            var splitServer;
            var splitApp;
            if (keyValue['checkedTier']) {
                this.selectedTier = true;
                this.fetchMetadata('tier');
                splitTier = keyValue['tierName'].split(",");
                for (let i = 0; i < splitTier.length; i++) {
                    this.tierName[i] = splitTier[i];
                }
                this.tierId = keyValue["tierId"];
            }
            else {
                this.selectedTier = false;
                this.tierName = [];
            }
            if (keyValue['checkedServer']) {
                this.selectedServer = true;
                this.fetchMetadata('server');
                splitServer = keyValue['serverName'].split(",");
                for (let i = 0; i < splitServer.length; i++) {
                    for (let j = 0; j < keyValue['ServerList'].length; j++) {
                        if (keyValue['ServerList'][j].value.includes(splitServer[i]))
                            this.serverName[i] = keyValue['ServerList'][j].value;
                    }
                }
                this.serverId = keyValue['serverId'].split(",");
            }
            else {
                this.selectedServer = false;
                this.serverName = [];
            }
            if (keyValue['checkedApp']) {
                this.selectedApp = true;
                this.fetchMetadata('app');
                splitApp = keyValue['appName'].split(",");
                for (let i = 0; i < splitApp.length; i++) {
                    for (let j = 0; j < keyValue['AppList'].length; j++) {
                        if (keyValue['AppList'][j].value.includes(splitServer[i]))
                            this.appName[i] = keyValue['AppList'][j].value;
                    }
                }
                this.appId = keyValue['appId'].split(",");
            }
            else {
                this.selectedApp = false;
                this.appName = [];
            }
            if (keyValue['BtCategory']) {
                this.selectedBT = true;
                this.selectedBTCategory = keyValue['BtCategory'];
            }
            else {
                this.selectedBT = false;
                this.selectedBTCategory = "";
            }
            if (keyValue['FlowpathID']) {
                this.selectedFP = true;
                this.fpInstance = keyValue['FlowpathID'];
            }
            else {
                this.selectedFP = false;
                this.fpInstance = "";
            }
            if (keyValue['MinMethods']) {
                this.checkedMethodCount = true;
                this.methodCheck();
                this.minMethods = keyValue['MinMethods'];
            }
            else {
                this.checkedMethodCount = false;
                this.minMethods = "";
            }
            if (keyValue['CorrelationId'] && keyValue['Mode']) {
                this.checkedCorrId = true;
                this.corrId = keyValue['CorrelationId'];
                this.selectedCorrIdMode = keyValue['Mode'];
            }
            else {
                this.checkedCorrId = false;
                this.corrId = "";
                this.selectedCorrIdMode = "";
            }
            if (keyValue['responseTime'] != undefined && keyValue['resptimeqmode'] != undefined) {
                this.checkedResponseTime = true;
                this.resSelectedCompareOption = keyValue['resptimeqmode'];
                if (this.resSelectedCompareOption == '3' && keyValue['resVariance'] != undefined) {
                    this.responseEqualCase();
                    this.resVariance = keyValue['resVariance'];
                    this.responseTime = keyValue['responseTime'];
                }
                else
                    this.responseTime = keyValue['responseTime'];
            }
            if (keyValue['TopNEntities']) {
                this.checkNEntityforPie = true;
                this.selectedTopNEntity = keyValue['TopNEntities'];
            }
            else {
                this.checkNEntityforPie = false;
                this.selectedTopNEntity = "";
            }
            if (keyValue['TopNQueries']) {
                this.checkNQueryforPie = true;
                this.selectedTopNQuery = keyValue['TopNQueries'];
            }
            else {
                this.checkNQueryforPie = false;
                this.selectedTopNQuery = "";
            }
            if (keyValue['IntegrationPointName']) {
                this.selectedIP = true;
                this.fetchMetadata('integrationPoint');
                if (keyValue['IntegrationPointName'].length == 1) {
                    this.selectedIntegrationPoint[0] = { "id": "0", "name": keyValue['IntegrationPointName'][0] };
                }
                else
                    this.selectedIntegrationPoint = keyValue['IntegrationPointName'];
            }
            else {
                this.selectedIP = false;
                this.selectedIntegrationPoint = undefined;
            }
            if (keyValue['ExcStackTraceName']) {
                this.selectedStackTrace = true;
                this.selectedStack = keyValue['ExcStackTraceName'];
            }
            else {
                this.selectedStackTrace = false;
                this.selectedStack = undefined;
            }
            if (keyValue['urlName'] && keyValue['urlIndex']) { // This is used for Nd report selected BT AutoFill
                this.checkedBuisnessTransaction = true;
                this.fetchMetadata('businessTransaction');
                this.selectedBuisnessTransaction = {};
                this.selectedBuisnessTransaction['name'] = keyValue['urlName'];
                this.selectedBuisnessTransaction['id'] = keyValue['urlIndex'];
                console.log("the value inside the selected business transaction is ......", this.selectedBuisnessTransaction);
            }
            else {
                this.checkedBuisnessTransaction = false;
                this.selectedBuisnessTransaction = null;
            }
            if (keyValue['ExcclassIdFC'] && keyValue['ExcClassId']) {
                this.selectedExceptionClass = true;
                this.fetchMetadata('exceptionclassname');
                this.selectedException = {};
                this.selectedException['name'] = keyValue['ExcclassIdFC'];
                this.selectedException['id'] = keyValue['ExcClassId'];
            }
            else {
                this.selectedException = undefined;
                this.selectedExceptionClass = false;
            }
            if (keyValue['ExcThrowingClassIdFC'] && keyValue['ExcThrowingClassId']) {
                this.selectedThrowingClass = true;
                this.fetchMetadata('exceptionthrowingclassname');
                this.selectedExceptionThrowingClass = {};
                this.selectedExceptionThrowingClass['name'] = keyValue['ExcThrowingClassIdFC'];
                this.selectedExceptionThrowingClass['id'] = keyValue['ExcThrowingClassId'];
            }
            else {
                this.selectedThrowingClass = false;
                this.selectedExceptionThrowingClass = undefined;
            }
            if (keyValue['ExcThrowingMethodIdFC'] && keyValue['ExcThrowingMethodId']) {
                this.selectedThrowingMethod = true;
                this.fetchMetadata('exceptionthrowingmethodname');
                this.selectedExceptionThrowingMethod = {};
                this.selectedExceptionThrowingMethod['name'] = keyValue['ExcThrowingMethodIdFC'];
                this.selectedExceptionThrowingMethod['id'] = keyValue['ExcThrowingMethodId'];
            }
            else {
                this.selectedThrowingMethod = false;
                this.selectedExceptionThrowingMethod = undefined;
            }
            if (keyValue['ExcCauseIdFC'] && keyValue['ExcCauseId']) {
                this.selectedExceptionCause = true;
                this.fetchMetadata('exceptioncause');
                this.selectedExceptionCauseType = {};
                this.selectedExceptionCauseType['name'] = keyValue['ExcCauseIdFC'];
                this.selectedExceptionCauseType['id'] = keyValue['ExcCauseId'];
            }
            else {
                this.selectedExceptionCause = false;
                this.selectedExceptionCauseType = undefined;
            }
            if (keyValue['ExcMsgIdFC'] && keyValue['ExcMsgId']) {
                this.selectedExceptionMessage = true;
                this.fetchMetadata('exceptionmsg');
                this.selectedExceptionMessageType = {};
                this.selectedExceptionMessageType['name'] = keyValue['ExcMsgIdFC'];
                this.selectedExceptionMessageType['id'] = keyValue['ExcMsgId'];
            }
            else {
                this.selectedExceptionMessage = false;
                this.selectedExceptionMessageType = undefined;
            }
        }
        else
            console.log("*************error this._ddrData.nsCqmAutoFill[currentReport] not defined yet*************** ");
    }
    showGroupBy() {
        if (this.commonServices.currentReport == 'FlowpathGroupBy' || this.commonServices.currentReport == 'Exception' || this.commonServices.currentReport == 'DBGroupBy' || this.commonServices.currentReport == "Transaction Instance" || this.commonServices.currentReport == "Transaction Summary"
            || this.commonServices.currentReport == "Page Summary" || this.commonServices.currentReport == "Page Instance" || this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Session Instance"
            || this.commonServices.currentReport == "URL Summary" || this.commonServices.currentReport == "URL Instance")
            return true;
        else
            return false;
    }
    checkNSFilter() {
        if (this.commonServices.currentReport == "Transaction Instance" || this.commonServices.currentReport == "Transaction Summary"
            || this.commonServices.currentReport == "Page Summary" || this.commonServices.currentReport == "Page Instance" || this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Session Instance"
            || this.commonServices.currentReport == "URL Summary" || this.commonServices.currentReport == "URL Instance") {
            this.showNSFilter = true;
            this.showReportField = false;
            this.reportList = [{ label: 'Transaction Instance', value: 'Transaction Instance' }, { label: 'Transaction Summary', value: 'Transaction Summary' }, { label: 'Page Summary', value: 'Page Summary' }, { label: 'Page Instance', value: 'Page Instance' },
                { label: 'URL Summary', value: 'URL Summary' }, { label: 'URL Instance', value: 'URL Instance' }, { label: 'Session Summary', value: 'Session Summary' }, { label: 'Session Instance', value: 'Session Instance' }];
            if (this.commonServices.currentReport == "Transaction Summary" || this.commonServices.currentReport == "Transaction Instance") {
                this.checkBoxUrl = false;
                this.checkBoxPage = false;
                this.checkBoxTransaction = true;
                this.hintUrl = "This option is uselectable for the current report";
                this.hintPage = "This option is uselectable for the current report";
                this.hintTransaction = "Transaction";
            }
            if (this.commonServices.currentReport == "Page Summary" || this.commonServices.currentReport == "Page Instance") {
                this.checkBoxUrl = false;
                this.checkBoxPage = true;
                this.checkBoxTransaction = false;
                this.hintUrl = "This option is uselectable for the current report";
                this.hintPage = "Page";
                this.hintTransaction = "Transaction";
            }
            if (this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Session Instance") {
                this.checkBoxUrl = false;
                this.checkBoxPage = false;
                this.checkBoxTransaction = false;
                this.hintUrl = "This option is uselectable for the current report";
                this.hintPage = "This option is uselectable for the current report";
                this.hintTransaction = "This option is uselectable for the current report";
            }
            if (this.commonServices.currentReport == "URL Summary" || this.commonServices.currentReport == "URL Instance") {
                this.checkBoxUrl = true;
                this.checkBoxPage = true;
                this.checkBoxTransaction = false;
            }
            this.showCommonFilters = false;
            console.log("every thing finaly==> this.checkBoxTransaction =>", this.checkBoxTransaction, " this.checkBoxPage===> ", this.checkBoxPage, " this.checkBoxUrl==>", this.checkBoxUrl);
            if (this.commonServices.currentReport == 'URL Instance' || this.commonServices.currentReport == 'Page Summary' || this.commonServices.currentReport == 'Page Instance')
                this.checkBoxPage = true;
            else
                this.checkBoxPage = false;
        }
        else
            this.showNSFilter = false;
        console.log("this.showNSFilter====>", this.showNSFilter);
        if (this.commonServices.currentReport == "Transaction Summary" || this.commonServices.currentReport == "URL Summary"
            || this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Page Summary"
            || this.commonServices.currentReport == "Flowpath" || this.commonServices.currentReport == "FlowpathGroupBy"
            || this.commonServices.currentReport == 'DB Report' || this.commonServices.currentReport == 'DBGroupBy'
            || this.commonServices.currentReport == 'Exception' || this.commonServices.currentReport == 'Method Timing'
            || this.commonServices.currentReport == 'Hotspot' || this.commonServices.currentReport == 'IP Summary') {
            console.log("save query ***************************** ");
            if (this._ddrData.saveQueryField && this._ddrData.saveQueryField['queryName']) {
                this.queryName = this._ddrData.saveQueryField['queryName'];
                this.addDescription = this._ddrData.saveQueryField['description'];
            }
            else {
                this.queryName = "";
                this.addDescription = "";
            }
        }
    }
    getTRMode() {
        let queyrParam = 'testRun=' + this.urlParam.testRun + '&tierName=' + this.urlParam.tierName;
        ;
        this.ndDdrHttpService.getTestRunMode(queyrParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__["TestRunModeLoadedState"]) {
                let data = state.data;
                this.testRunMode = data.mode;
            }
        }, (error) => {
            console.error(error);
        });
    }
    isMultiDcEnable() {
        this.selectIsMultiDCCheckFlag = false;
        console.log("this.isMultiDC===", this.isMultiDC);
        if (this.isMultiDC) {
            this.getMultiDCInfo();
        }
        else {
            console.log("this.selectedDC--", this.selectedDC);
            this.selectedDC = [];
            this.dcList = [];
            this.selectedTier = false;
            this.setDefaultTierServerAppFilter();
            this.tierMetaData = undefined;
            this.serverMetaData = undefined;
            this.appMetaData = undefined;
            this.checkedBuisnessTransaction = false;
            this.BTOptions = [];
            this.selectedBuisnessTransaction = [];
        }
    }
    getMultiDCInfo() {
        if (this.dcList.length == 0) {
            let queyrParam = 'testRun=' + this.urlParam.testRun + '&tierName=' + this.urlParam.tierName;
            return this.ndDdrHttpService.getMultiDcDataForSidebar(queyrParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__["MultiDCForSidebarLoadedState"]) {
                    this.getMultiDcData(state.data);
                }
            }, (error) => {
                console.error(error);
            });
        }
    }
    getMultiDcData(res) {
        this.NDEInfoData = res;
        if (res.length == 0) {
            this.enableMultiDC = false;
        }
        else
            this.enableMultiDC = true;
        console.log("getMultiDcData-- data--", res);
        let i = 0;
        for (i = 0; i < res.length; i++) {
            console.log("res[i]--", res[i]);
            console.log("res[i].displayName--", res[i].displayName);
            this.dcList.push({ label: res[i].displayName, value: { displayName: res[i].displayName, pubicIP: res[i].pubicIP, publicPort: res[i].publicPort, ndeProtocol: res[i].ndeProtocol, isCurrent: res[i].isCurrent, ndeTestRun: res[i].ndeTestRun } });
            console.log("this.dcList--", this.dcList);
        }
        let url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", ""));
        console.log("this.urlParam.product-", this.urlParam.product);
        console.log("this.getHostUrl()--", this.getHostUrl());
        console.log("url--", url);
    }
    changeMultiDC() {
        console.log("this.selectedDC--", this.selectedDC);
        this.selectedTier = false;
        this.selectTierFlag = false;
        this.selectServerFlag = false;
        this.selectAppFlag = false;
        this.setDefaultTierServerAppFilter();
        this.tierMetaData = undefined;
        this.serverMetaData = undefined;
        this.appMetaData = undefined;
        this.checkedBuisnessTransaction = false;
        this.BTOptions = [];
        this.selectedBuisnessTransaction = [];
    }
    /*Method is used get host url*/
    getHostUrl() {
        var hostDcName;
        if (this._ddrData.isFromtrxFlow && !this._ddrData.isFromtrxSideBar) {
            hostDcName = "//" + this._ddrData.hostTr + ":" + this._ddrData.portTr;
            this.urlParam.testRun = this._ddrData.testRunTr;
            //   return hostDCName;
        }
        else {
            hostDcName = this._ddrData.getHostUrl();
            if (sessionStorage.getItem("isMultiDCMode") == "true") {
                this.urlParam.testRun = this._ddrData.testRun;
                console.log("all case test run==>", this.urlParam.testRun);
            }
        }
        console.log('hostDcName =', hostDcName);
        return hostDcName;
    }
    getDCData() {
        return new Promise((resolve, reject) => {
            //   this.isFirstTimeGetDcDataFunctionCall = true;
            //   let url = '//' + this.getHostUrl() + '/' + this.urlParam.product + '/v1/cavisson/netdiagnostics/ddr/multiDC?testRun=' + this.urlParam.testRun;
            //this.http.get(url).map(res => res.json()).subscribe(data => (this.getNDEInfo(data)));
            //    this.http.get(url).map(res => res.json()).subscribe(data => {
            let data = this.NDEInfoData;
            console.log('COMPONENT - SIdebar , METHOD - getDCData,  var dcNameList= ', this.commonServices.dcNameList + " and NDE.csv =", data, "data.length: ", data.length);
            if (data.length == 0) {
                data = this.setNDEInfoForSingleDC();
                console.log("data is ", data);
            }
            if (this.commonServices.dcNameList.indexOf(',') != -1) {
                this.getNDEInfo(data);
            }
            else {
                this.singleDCCase(data);
            }
            //  },
            resolve();
        });
    }
    setNDEInfoForSingleDC() {
        let data;
        if (this.urlParam.dcName)
            data = [{ "displayName": this.urlParam.dcName, "ndeId": 1, "ndeIPAddr": this.urlParam.dcIP, "ndeTomcatPort": this.urlParam.dcPort, "ndeCtrlrName": "", "pubicIP": this.urlParam.dcIP, "publicPort": this.urlParam.dcPort, "isCurrent": 1, "ndeTestRun": this.urlParam.testRun, "ndeProtocol": location.protocol.replace(":", "") }];
        else if (this.commonServices.host) {
            let protocol;
            if (this.commonServices.protocol && this.commonServices.protocol.endsWith("://"))
                protocol = this.commonServices.protocol.replace("://", "");
            else
                protocol = location.protocol.replace(":", "");
            data = [{ "displayName": this.commonServices.selectedDC, "ndeId": 1, "ndeIPAddr": this.commonServices.host, "ndeTomcatPort": this.commonServices.port, "ndeCtrlrName": "", "pubicIP": this.commonServices.host, "publicPort": this.commonServices.port, "isCurrent": 1, "ndeTestRun": this.commonServices.testRun, "ndeProtocol": protocol }];
        }
        return data;
    }
    getNDEInfo(res) {
        this.ndeInfoData = res;
        this.dcList = [];
        let dcName = this.commonServices.dcNameList.split(',');
        let isFirst = false;
        for (let i = 0; i < this.ndeInfoData.length; i++) {
            if (dcName[i])
                this.dcList.push({ label: dcName[i], value: dcName[i] });
            if (this.commonServices.selectedDC && this.commonServices.selectedDC !== 'ALL') {
                this.selectedDC = this.commonServices.selectedDC;
                console.log("this selected dc ", this.selectedDC);
            }
            else {
                console.log("else case");
                if (this.ndeInfoData[i].isCurrent == 1 && dcName.indexOf(this.ndeInfoData[i].displayName) != -1) {
                    this.selectedDC = this.ndeInfoData[i].displayName;
                    isFirst = true;
                    console.log("Else case this selected dc ", this.selectedDC);
                }
                else if (i == (this.ndeInfoData.length - 1) && !isFirst)
                    this.selectedDC = this.dcList[0];
                console.log("else if case isFirst false ", this.selectedDC);
            }
            if (this.selectedDC == this.ndeInfoData[i].displayName) {
                this.ndeCurrentInfo = this.ndeInfoData[i];
                console.log("if length case  ", this.selectedDC);
            }
        }
        if (dcName.length > this.ndeInfoData.length) {
            this.dcList = [];
            for (let k = 0; k < dcName.length; k++) {
                this.dcList.push({ label: dcName[k], value: dcName[k] });
            }
            console.log("this.dcList ==== ", this.dcList);
        }
        this.getSelectedDC();
    }
    getSelectedDC($event) {
        if ($event) {
            this.selectedDC = $event.value;
            console.log("calling from dcMenu select case ", $event.value);
        }
        for (let i = 0; i < this.ndeInfoData.length; i++) {
            if (this.selectedDC == this.ndeInfoData[i].displayName) {
                this.ndeCurrentInfo = this.ndeInfoData[i];
                if (this.ndeInfoData[i].ndeProtocol != undefined)
                    this.dcProtocol = this.ndeInfoData[i].ndeProtocol;
                else
                    this.dcProtocol = location.protocol.replace(":", "");
                if (this.ndeInfoData[i].ndeTestRun) {
                    this.urlParam.testRun = this.ndeInfoData[i].ndeTestRun;
                    this.testRun = this.ndeInfoData[i].ndeTestRun;
                }
                else
                    this.testRun = this.urlParam.testRun;
                this.host = this.ndeInfoData[i].ndeIPAddr;
                this.port = this.ndeInfoData[i].ndeTomcatPort;
                this.commonServices.host = this.host;
                this.commonServices.port = this.port;
                this.commonServices.protocol = this.dcProtocol;
                this.commonServices.testRun = this.testRun;
                this.commonServices.selectedDC = this.selectedDC;
                console.log('commonservece variable--------->', this.commonServices.host, '===', this.commonServices.port, '======', this.commonServices.protocol);
                break;
            }
        }
    }
    singleDCCase(res) {
        this.ndeInfoData = res;
        this.selectedDC = this.commonServices.dcNameList;
        for (let i = 0; i < this.ndeInfoData.length; i++) {
            if (this.commonServices.dcNameList == this.ndeInfoData[i].displayName) {
                if (this.ndeInfoData[i].ndeProtocol != undefined)
                    this.protocol = this.ndeInfoData[i].ndeProtocol + "://";
                else
                    this.protocol = location.protocol.replace(":", "");
                if (this.ndeInfoData[i].ndeTestRun) {
                    this.urlParam.testRun = this.ndeInfoData[i].ndeTestRun;
                    this.testRun = this.ndeInfoData[i].ndeTestRun;
                }
                else
                    this.testRun = this.urlParam.testRun;
                this.host = this.ndeInfoData[i].ndeIPAddr;
                this.port = this.ndeInfoData[i].ndeTomcatPort;
                this.commonServices.host = this.host;
                this.commonServices.port = this.port;
                this.commonServices.protocol = this.protocol;
                this.commonServices.testRun = this.testRun;
                console.log('commonServices variable============', this.commonServices.host, '===', this.commonServices.port, '======', this.commonServices.protocol);
                break;
            }
        }
    }
    applyFilteredValueInSideBar() {
        if (this.commonServices.isValidParamInObj(this.message, "tierName")) {
            this.selectedTier = true;
            let tierArr = [];
            tierArr.push(this.message.tierName);
            this.tierName = tierArr;
            this.fetchMetadata('tier');
        }
        if (this.commonServices.isValidParamInObj(this.message, "serverName")) {
            this.selectedServer = true;
            if (this.tierName.length == 1) {
                if (this.tierName[0] == this.message.tierName)
                    var serverArr = [];
                serverArr.push(this.message.tierName + ":" + this.message.serverName);
                this.serverName = serverArr;
                this.fetchMetadata('server');
            }
        }
        if (this.commonServices.isValidParamInObj(this.message, "appName")) {
            this.selectedApp = true;
            if (this.tierName.length == 1) {
                if (this.tierName[0] == this.message.tierName)
                    var appArr = [];
                appArr.push(this.message.tierName + ":" + this.message.serverName + ":" + this.message.appName);
                this.appName = appArr;
            }
            this.fetchMetadata('app');
        }
        if (this.commonServices.isValidParamInObj(this.message, "urlName")) {
            this.checkedBuisnessTransaction = true;
            this.fetchMetadata('businessTransaction');
        }
        if (this.commonServices.isValidParamInObj(this.message, "btCategory")) {
            this.selectedBT = true;
            this.selectedBTCategory = this.commonServices.getBTCategoryID(this.message.btCategory);
        }
        /* this.selectedBTCategory = this.commonServices.getBTCategoryID(this.message.btCatagory);
         this.fpInstance =  this.message.flowpathInstance;
         this.selectedBuisnessTransaction = this.message.urlName;
         
         
         if(this.selectedBuisnessTransaction.length >0)
         this.checkedBuisnessTransaction = false;
         
        // if(this.fpInstance.length >0)
        // this.commonServices.isCheckedFlowpath = true;
        /* if(this.selectedBTCategory.length >0)
           this.selectedBT = true;
    
         if(this.fpInstance.length > 0)
           this.selectedFP = true;
    
         this.selectedTierVal = ["val1"];
         this.selectedServerVal = ["val2"];
         this.selectedAppVal = ["val3"];
         this.selectedBTVal = ["val5"];
    
         this.tierInfo(true);
         setTimeout(()=>
         {
           this.serverInfo(true);
         },2000);
         
         setTimeout(()=>
         {
           this.appInfo(true);
         },2000);
         
         this.btInfo(true); */
    }
    getResponseTimeModeValue(resMode) {
        if (resMode == "1")
            return "<=";
        else if (resMode == "2")
            return ">=";
        else if (resMode == "3")
            return "==";
    }
    getCorelationmodeValue(resMode) {
        if (resMode == "1")
            return "Exact";
        else if (resMode == "2")
            return "Starts With";
        else if (resMode == "3")
            return "Ends With";
        else if (resMode == "4")
            return "Contains";
    }
    Reset(isComponentChange, method) {
        this.timeFilter = false;
        this.selectedTime = '';
        this.checkedResponseTime = false;
        this.responseCheck();
        this.checkGroup = false;
        this.selectedGroupBy = [];
        this.checkOrder = false;
        this.selectedOrderBy = [];
        this.selectedUrlStatus = '-2';
        this.selectedFailureId = undefined;
        this.selectedFailureNameId = undefined;
        this.selectedFailureName = undefined;
        this.failure = false;
        this.checkedScript = false;
        this.selectedScript = null;
        this.checkedTransaction = false;
        this.selectedTransaction = null;
        this.checkedPage = false;
        this.selectedPage = null;
        this.checkedUrl = false;
        this.selectedUrl = '';
        this.selectedTier = false;
        this.setDefaultTierServerAppFilter();
        this.selectedServer = false;
        this.setDefaultServerAppFilter();
        this.selectedApp = false;
        this.appName = [];
        this.appId = [];
        this.appNameFC = "NA";
        this.selectedFP = false;
        this.commonServices.flowpathInstance = "";
        this.fpInstance = "";
        this.checkedBuisnessTransaction = false;
        this.selectedBuisnessTransaction = "";
        this.nxt = false;
        this.prev = false;
        this.btCount = '';
        this.btLimit = 1000;
        this.btOffset = 0;
        this.selectedBT = false;
        this.selectedBTCategory = "";
        this.checkNQueryforPie = false;
        this.selectedTopNQuery = '';
        this.dbOrderByCheck = false;
        this.selectedDbOrderBy = [];
        this.isMultiDC = false;
        console.log("this.selectedDC--", this.selectedDC);
        this.selectedDC = [];
        this.dcList = [];
        this.selectedTier = false;
        this.setDefaultTierServerAppFilter();
        this.tierMetaData = undefined;
        this.serverMetaData = undefined;
        this.appMetaData = undefined;
        this.checkedBuisnessTransaction = false;
        this.BTOptions = [];
        this.selectedBuisnessTransaction = [];
        this.selectedExceptionClass = false;
        this.selectedException = null;
        this.selectedThrowingClass = false;
        this.selectedExceptionThrowingClass = null;
        this.selectedThrowingMethod = false;
        this.selectedExceptionThrowingMethod = null;
        this.selectedExceptionCause = false;
        this.selectedExceptionCauseType = null;
        this.selectedExceptionMessage = false;
        this.selectedExceptionMessageType = null;
        this.selectedStackTrace = false;
        this.selectedStack = "";
        this.checkedCorrId = false;
        this.selectedCorrIdMode = "";
        this.corrId = "";
        this.fpOrderByCheck = false;
        this.selectedFpOrderBy = [];
        this.checkedMethodCount = false;
        this.minMethods = "";
        this.checkNEntityforPie = false;
        this.selectedTopNEntity = '';
        this.selectedIP = false;
        this.selectedIntegrationPoint = [];
        this.isCheckedSessionId = false;
        this.ndSessionId = "";
        this.isCheckedPageId = false;
        this.nvPageId = "";
        this.isCheckedNVSessionID = false;
        this.nvSessionId = "";
        this.queryName = '';
        this.showQueryError = false;
        this.showSaveError = false;
        this.addDescription = '';
        this.selectAnyCheckBoxFlag = false;
        this.selectCheckBoxFlag = false;
        this.selectResponseCheckBoxFlag = false;
        this.selectResponseCheckBoxFlag1 = false;
        this.selectGroupByCheckBoxFlag = false;
        this.selectOrderByCheckBoxFlag = false;
        this.selectScriptCheckBoxFlag = false;
        this.selectTransactionCheckBoxFlag = false;
        this.selectPageCheckBoxFlag = false;
        this.selectUrlCheckBoxFlag = false;
        this.selectFailureTypeFlag = false;
        this.selectTierFlag = false;
        this.selectServerFlag = false;
        this.selectAppFlag = false;
        this.selectBTFlag = false;
        this.selectBTCategoryFlag = false;
        this.selectCheckNQuerryFlag = false;
        this.selectDBOrderByCheckFlag = false;
        this.selectIsMultiDCCheckFlag = false;
        this.selectExceptionClassFlag = false;
        this.selectedExceptionThrowingClassFlag = false;
        this.selectedExceptionThrowingMethodFlag = false;
        this.selectedExceptionCauseTypeFlag = false;
        this.selectedExceptionMessageTypeFlag = false;
        this.selectedStackFlag = false;
        this.selectfpInstanceFlag = false;
        this.selectedCorrIdModeFlag = false;
        this.selectedCorrIdModeFlag1 = false;
        this.selectedCorrIdModeFlag2 = false;
        this.selectedFpOrderByFlag = false;
        this.selectedminMethodsFlag = false;
        this.selectedTopNEntityFlag = false;
        this.selectIntegrationPointFlag = false;
        this.ndSessionIdFlag = false;
        this.nvPageIdFlag = false;
        this.nvSessionIdFlag = false;
        if (this.commonTag)
            this.commonTag.show(1, false, -1, null);
        this.gTagsStr = '';
        if (method != 'ngOnDestroy') {
            this.applyFilter(true, isComponentChange);
        }
        this.dataChangeDetected.emit();
        this.commonServices.closeUISideBar$.next();
    }
    onApply() {
        //this.fpInstance = this.commonServices.flowpathInstance;
        this.productKey = sessionStorage.getItem('productKey');
        console.log("this.isMultiDC--", this.isMultiDC);
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        //For the UI Filter when we are not selecting any time period.
        //For Multi DC
        if (this.isMultiDC == true) {
            if (!this.selectedDC || this.selectedDC == "" || this.selectedDC == null || this.selectedDC.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectIsMultiDCCheckFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectIsMultiDCCheckFlag) {
                    return;
                }
            }
            else {
                this.selectIsMultiDCCheckFlag = false;
                console.log("No Message");
            }
        }
        //TimeFilter
        if (this.timeFilter == true) {
            if (!this.selectedTime || this.selectedTime == "") {
                this.selectAnyCheckBoxFlag = false;
                this.selectCheckBoxFlag = true;
                console.log("Without Selecting any dropdown-----", this.showCheckBoxErrorMessage);
                if (this.selectCheckBoxFlag) {
                    return;
                }
            }
            else {
                this.selectCheckBoxFlag = false;
                console.log("No Message");
            }
        }
        //Response time
        if (this.checkedResponseTime == true) {
            if (this.resSelectedCompareOption == "1") {
                if (!this.responseTime || this.responseTime == "") {
                    this.selectAnyCheckBoxFlag = false;
                    this.selectResponseCheckBoxFlag = true;
                    console.log("Response Error message is ....", this.showInputFieldErrorMessage);
                    if (this.selectResponseCheckBoxFlag) {
                        return;
                    }
                }
                else {
                    this.selectResponseCheckBoxFlag = false;
                    console.log("No message");
                }
            }
            if (this.resSelectedCompareOption == "2" || this.resSelectedCompareOption == "3") {
                if (!this.responseTime || this.responseTime == "") {
                    this.selectAnyCheckBoxFlag = false;
                    this.selectResponseCheckBoxFlag = false;
                    this.selectResponseCheckBoxFlag1 = true;
                    console.log("Response Error message is ....", this.showInputFieldErrorMessage);
                    if (this.selectResponseCheckBoxFlag1) {
                        return;
                    }
                }
                else {
                    this.selectResponseCheckBoxFlag1 = false;
                    console.log("No message");
                }
            }
        }
        //Group By
        if (this.commonServices.currentReport == 'Flowpath' || this.commonServices.currentReport == 'DB Report' || this.commonServices.currentReport == 'Method Timing' || this.commonServices.currentReport == 'IP Summary' || this.commonServices.currentReport == 'Hotspot') {
            this.checkGroup = false;
            this.selectGroupByCheckBoxFlag = false;
            console.log("No Message");
        }
        else {
            if (this.checkGroup == true) {
                if (!this.selectedGroupBy || this.selectedGroupBy == null || this.selectedGroupBy.length == 0 || !this.groupBy || this.groupBy.length == 0) {
                    this.selectAnyCheckBoxFlag = false;
                    this.selectGroupByCheckBoxFlag = true;
                    console.log("Without selecting any value", this.showCheckBoxErrorMessage);
                    if (this.selectGroupByCheckBoxFlag) {
                        return;
                    }
                }
                else {
                    this.selectGroupByCheckBoxFlag = false;
                    console.log("No Message");
                }
            }
        }
        // Order By
        if (this.checkOrder == true) {
            if (!this.selectedOrderBy || this.selectedOrderBy == null || this.selectedOrderBy.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectOrderByCheckBoxFlag = true;
                console.log("Without selecting any value", this.showCheckBoxErrorMessage);
                if (this.selectOrderByCheckBoxFlag) {
                    return;
                }
            }
            else {
                this.selectOrderByCheckBoxFlag = false;
                console.log("No Message");
            }
        }
        //For script 
        if (this.checkedScript == true) {
            if (!this.selectedScript || this.selectedScript == null || this.selectedScript.length == 0 || this.selectedScript == "" || !this.selectedScript.name || this.selectedScript.name == null || !this.selectedScript.id || this.selectedScript.id == null) {
                this.selectAnyCheckBoxFlag = false;
                this.selectScriptCheckBoxFlag = true;
                console.log("Without selecting any value", this.showCheckBoxErrorMessage);
                if (this.selectScriptCheckBoxFlag) {
                    return;
                }
            }
            else {
                this.selectScriptCheckBoxFlag = false;
                console.log("No Message");
            }
        }
        //For Transaction
        if (this.checkedTransaction == true) {
            if (!this.selectedTransaction || this.selectedTransaction == null || this.selectedTransaction.length == 0 || !this.selectedTransaction.name || this.selectedTransaction.name == null || !this.selectedTransaction.id || this.selectedTransaction.id == null) {
                this.selectAnyCheckBoxFlag = false;
                this.selectTransactionCheckBoxFlag = true;
                console.log("Without selecting any value", this.showCheckBoxErrorMessage);
                if (this.selectTransactionCheckBoxFlag) {
                    return;
                }
            }
            else {
                this.selectTransactionCheckBoxFlag = false;
                console.log("No Message");
            }
        }
        //For Page
        if (this.checkedPage == true) {
            if (!this.selectedPage || this.selectedPage == null || this.selectedPage.length == 0 || !this.selectedPage.name || this.selectedPage.name == null || !this.selectedPage.id || this.selectedPage.id == null) {
                this.selectAnyCheckBoxFlag = false;
                this.selectPageCheckBoxFlag = true;
                console.log("Without selecting any value", this.showCheckBoxErrorMessage);
                if (this.selectPageCheckBoxFlag) {
                    return;
                }
            }
            else {
                this.selectPageCheckBoxFlag = false;
                console.log("No Message");
            }
        }
        //For URL
        if (this.checkedUrl == true) {
            if (!this.selectedUrl || this.selectedUrl == null || this.selectedUrl.length == 0 || this.selectedUrl.name == null || !this.selectedUrl.name || this.selectedUrl.id == null || !this.selectedUrl.id) {
                this.selectAnyCheckBoxFlag = false;
                this.selectUrlCheckBoxFlag = true;
                console.log("Without selecting any value", this.showCheckBoxErrorMessage);
                if (this.selectUrlCheckBoxFlag) {
                    return;
                }
            }
            else {
                console.log("select url", this.selectedUrl);
                this.selectUrlCheckBoxFlag = false;
                console.log("No Message");
            }
        }
        //For the case ... when any URL status has been choosen
        if (this.selectedUrlStatus == 4) {
            console.log("selected Url status", this.selectedUrlStatus);
            if (!this.selectedFailureId || this.selectedFailureId == null || this.selectedFailureId.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectFailureTypeFlag = true;
                console.log("Without selecting any value", this.showCheckBoxErrorMessage);
                if (this.selectFailureTypeFlag) {
                    return;
                }
            }
            else {
                this.selectFailureTypeFlag = false;
                console.log("No Message");
            }
        }
        //Common filters started from here..
        //Tier case
        if (this.selectedTier == true) {
            if (!this.tierName || this.tierName.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectTierFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectTierFlag) {
                    return;
                }
            }
            else {
                this.selectTierFlag = false;
                console.log("No Message");
            }
        }
        //Server case
        if (this.selectedServer == true) {
            if (!this.serverName || this.serverName.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectServerFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectServerFlag) {
                    return;
                }
            }
            else {
                this.selectServerFlag = false;
                console.log("No Message");
            }
        }
        //Instance case
        if (this.selectedApp == true) {
            if (!this.appName || this.appName.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectAppFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectAppFlag) {
                    return;
                }
            }
            else {
                this.selectAppFlag = false;
                console.log("No Message");
            }
        }
        //Flowpath Instance case
        if (this.selectedFP == true) {
            if (!this.fpInstance || this.fpInstance == "" || this.fpInstance == null) {
                this.selectAnyCheckBoxFlag = false;
                this.selectfpInstanceFlag = true;
                console.log("Without selecting any option", this.showInputFieldErrorMessage);
                if (this.selectfpInstanceFlag) {
                    return;
                }
            }
            else {
                this.selectfpInstanceFlag = false;
                console.log("No Message");
            }
        }
        //BT case
        if (this.checkedBuisnessTransaction == true) {
            if (!this.selectedBuisnessTransaction || this.selectedBuisnessTransaction == "" || this.selectedBuisnessTransaction.length == 0 || !this.selectedBuisnessTransaction.name || this.selectedBuisnessTransaction.name == null || !this.selectedBuisnessTransaction.id || this.selectedBuisnessTransaction.id == null) {
                this.selectAnyCheckBoxFlag = false;
                this.selectBTFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectBTFlag) {
                    return;
                }
            }
            else {
                this.selectBTFlag = false;
                console.log("No Message");
            }
        }
        //BT Category
        if (this.selectedBT == true) {
            if (!this.selectedBTCategory || this.selectedBTCategory == "") {
                this.selectAnyCheckBoxFlag = false;
                this.selectBTCategoryFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectBTCategoryFlag) {
                    return;
                }
            }
            else {
                this.selectBTCategoryFlag = false;
                console.log("No Message");
            }
        }
        //For Top N Querry
        if (this.checkNQueryforPie == true) {
            if (!this.selectedTopNQuery || this.selectedTopNQuery == "" || this.selectedTopNQuery == null) {
                this.selectAnyCheckBoxFlag = false;
                this.selectCheckNQuerryFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectCheckNQuerryFlag) {
                    return;
                }
            }
            else {
                this.selectCheckNQuerryFlag = false;
                console.log("No Message");
            }
        }
        //For DB OrderBy
        if (this.dbOrderByCheck == true) {
            if (!this.selectedDbOrderBy || this.selectedDbOrderBy == null || this.selectedDbOrderBy.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectDBOrderByCheckFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectDBOrderByCheckFlag) {
                    return;
                }
            }
            else {
                this.selectDBOrderByCheckFlag = false;
                console.log("No Message");
            }
        }
        //For Exception Class
        if (this.selectedExceptionClass === true) {
            if (!this.selectedException || this.selectedException == null || this.selectedException == "" || !this.selectedException.id || !this.selectedException.name) {
                this.selectAnyCheckBoxFlag = false;
                this.selectExceptionClassFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectExceptionClassFlag) {
                    return;
                }
            }
            else {
                this.selectExceptionClassFlag = false;
                console.log("No Message");
            }
        }
        //For Throwing Class
        if (this.selectedThrowingClass === true) {
            if (!this.selectedExceptionThrowingClass || this.selectedExceptionThrowingClass == null || this.selectedExceptionThrowingClass == "" || !this.selectedExceptionThrowingClass.id || !this.selectedExceptionThrowingClass.name) {
                this.selectAnyCheckBoxFlag = false;
                this.selectedExceptionThrowingClassFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectedExceptionThrowingClassFlag) {
                    return;
                }
            }
            else {
                this.selectedExceptionThrowingClassFlag = false;
                console.log("No Message");
            }
        }
        //For Throwing Method
        if (this.selectedThrowingMethod === true) {
            if (!this.selectedExceptionThrowingMethod || this.selectedExceptionThrowingMethod == null || this.selectedExceptionThrowingMethod == "" || !this.selectedExceptionThrowingClass.id || !this.selectedExceptionThrowingClass.name) {
                this.selectAnyCheckBoxFlag = false;
                this.selectedExceptionThrowingMethodFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectedExceptionThrowingMethodFlag) {
                    return;
                }
            }
            else {
                this.selectedExceptionThrowingMethodFlag = false;
                console.log("No Message");
            }
        }
        //For Exception Cause
        if (this.selectedExceptionCause === true) {
            if (!this.selectedExceptionCauseType || this.selectedExceptionCauseType == null || this.selectedExceptionCauseType == "" || !this.selectedExceptionCauseType.id || !this.selectedExceptionCauseType.name) {
                this.selectAnyCheckBoxFlag = false;
                this.selectedExceptionCauseTypeFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectedExceptionCauseTypeFlag) {
                    return;
                }
            }
            else {
                this.selectedExceptionCauseTypeFlag = false;
                console.log("No Message");
            }
        }
        //For Exception Message
        if (this.selectedExceptionMessage === true) {
            if (!this.selectedExceptionMessageType || this.selectedExceptionMessageType == null || this.selectedExceptionMessageType == "" || !this.selectedExceptionMessageType.id || !this.selectedExceptionMessageType.name) {
                this.selectAnyCheckBoxFlag = false;
                this.selectedExceptionMessageTypeFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectedExceptionMessageTypeFlag) {
                    return;
                }
            }
            else {
                this.selectedExceptionMessageTypeFlag = false;
                console.log("No Message");
            }
        }
        //For Stack Trace
        if (this.selectedStackTrace === true) {
            if (!this.selectedStack || this.selectedStack == null || this.selectedStack == "") {
                this.selectAnyCheckBoxFlag = false;
                this.selectedStackFlag = true;
                console.log("Without selecting any option", this.showInputFieldErrorMessage);
                if (this.selectedStackFlag) {
                    return;
                }
            }
            else {
                this.selectedStackFlag = false;
                console.log("No Message");
            }
        }
        //For Corr ID
        if (this.checkedCorrId == true) {
            if ((!this.selectedCorrIdMode || this.selectedCorrIdMode == null || this.selectedCorrIdMode == "") && (!this.corrId || this.corrId == null || this.corrId == "")) {
                this.selectAnyCheckBoxFlag = false;
                this.selectedCorrIdModeFlag = true;
                this.selectedCorrIdModeFlag1 = false;
                this.selectedCorrIdModeFlag2 = false;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage, this.showInputFieldErrorMessage);
                if (this.selectedCorrIdModeFlag) {
                    return;
                }
            }
            else if ((!this.selectedCorrIdMode || this.selectedCorrIdMode == null || this.selectedCorrIdMode == "") && !(!this.corrId || this.corrId == null || this.corrId == "")) {
                this.selectAnyCheckBoxFlag = false;
                this.selectedCorrIdModeFlag2 = true;
                this.selectedCorrIdModeFlag = false;
                this.selectedCorrIdModeFlag1 = false;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectedCorrIdModeFlag2) {
                    return;
                }
            }
            else if ((!this.corrId || this.corrId == null || this.corrId == "") && !(!this.selectedCorrIdMode || this.selectedCorrIdMode == null || this.selectedCorrIdMode == "")) {
                //this.selectAnyCheckBoxFlag = false;
                this.selectedCorrIdModeFlag1 = true;
                this.selectedCorrIdModeFlag = false;
                this.selectedCorrIdModeFlag2 = false;
                console.log("Without selecting any option", this.showInputFieldErrorMessage);
                if (this.selectedCorrIdModeFlag1) {
                    return;
                }
            }
            else {
                this.selectedCorrIdModeFlag = false;
                this.selectedCorrIdModeFlag1 = false;
                this.selectedCorrIdModeFlag2 = false;
                console.log("No Message");
            }
        }
        //For Order By
        if (this.fpOrderByCheck == true) {
            if (!this.selectedFpOrderBy || this.selectedFpOrderBy == null || this.selectedFpOrderBy.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectedFpOrderByFlag = true;
                console.log("Without selecting any option", this.showCheckBoxErrorMessage);
                if (this.selectedFpOrderByFlag) {
                    return;
                }
            }
            else {
                this.selectedFpOrderByFlag = false;
                console.log("No Message");
            }
        }
        //For Methods FpFilters
        if (this.checkedMethodCount == true) {
            if (!this.minMethods || this.minMethods == null || this.minMethods == "") {
                this.selectAnyCheckBoxFlag = false;
                this.selectedminMethodsFlag = true;
                console.log("Without selecting any option", this.showInputFieldErrorMessage);
                if (this.selectedminMethodsFlag) {
                    return;
                }
            }
            else {
                this.selectedminMethodsFlag = false;
                console.log("No Message");
                this.checkNEntityforPie == true;
            }
        }
        //For Method Timing  (Top N Entities for pie chart)
        if (this.checkNEntityforPie == true) {
            if (!this.selectedTopNEntity || this.selectedTopNEntity == null || this.selectedTopNEntity == "") {
                this.selectAnyCheckBoxFlag = false;
                this.selectedTopNEntityFlag = true;
                console.log("Without selecting any option", this.showInputFieldErrorMessage);
                if (this.selectedTopNEntityFlag) {
                    return;
                }
            }
            else {
                this.selectedTopNEntityFlag = false;
                console.log("No Message");
            }
        }
        //For IP
        if (this.selectedIP == true) {
            if (!this.selectedIntegrationPoint || this.selectedIntegrationPoint == null || this.selectedIntegrationPoint.length == 0) {
                this.selectAnyCheckBoxFlag = false;
                this.selectIntegrationPointFlag = true;
                console.log("When we not selecting any value", this.showCheckBoxErrorMessage);
                if (this.selectIntegrationPointFlag) {
                    return;
                }
            }
            else {
                this.selectIntegrationPointFlag = false;
                console.log("No Message");
            }
        }
        //For Session Id
        if (this.isCheckedSessionId == true) {
            if (!this.ndSessionId || this.ndSessionId == "" || this.ndSessionId == null) {
                this.selectAnyCheckBoxFlag = false;
                this.ndSessionIdFlag = true;
                console.log("When we are not selecting any value", this.showInputFieldErrorMessage);
                if (this.ndSessionIdFlag) {
                    return;
                }
            }
            else {
                this.ndSessionIdFlag = false;
                console.log("No Message");
            }
        }
        //For Page Id
        if (this.isCheckedPageId == true) {
            if (!this.nvPageId || this.nvPageId == "" || this.nvPageId == null) {
                this.selectAnyCheckBoxFlag = false;
                this.nvPageIdFlag = true;
                console.log("When we are not selecting any value", this.showInputFieldErrorMessage);
                if (this.nvPageIdFlag) {
                    return;
                }
            }
            else {
                this.nvPageIdFlag = false;
                console.log("No Message");
            }
        }
        //For NVSession Id
        if (this.isCheckedNVSessionID == true) {
            if (!this.nvSessionId || this.nvSessionId == "" || this.nvSessionId == null) {
                this.selectAnyCheckBoxFlag = false;
                this.nvSessionIdFlag = true;
                console.log("When we are not selecting any value", this.showInputFieldErrorMessage);
                if (this.nvSessionId) {
                    return;
                }
            }
            else {
                this.nvSessionIdFlag = false;
                console.log("No Message");
            }
        }
        if (this.isMultiDC == true || this.timeFilter == true || this.checkedResponseTime == true || this.checkGroup == true || this.checkOrder == true || this.checkedScript == true || this.checkedTransaction == true || this.checkedPage == true || this.checkedUrl == true || this.selectedUrlStatus == -2 || this.selectedUrlStatus == -1 || this.selectedUrlStatus == 0 || this.selectedUrlStatus == 4 || this.selectedTier == true || this.selectedServer == true || this.selectedApp == true || this.selectedFP == true || this.checkedBuisnessTransaction == true || this.selectedBT == true || this.checkNQueryforPie == true || this.dbOrderByCheck == true || this.selectedStackTrace === true || this.selectedExceptionMessage === true || this.selectedExceptionCause === true || this.selectedThrowingMethod === true || this.selectedThrowingClass === true || this.selectedExceptionClass === true || this.checkedMethodCount == true || this.checkNEntityforPie == true || this.checkedCorrId == true || this.fpOrderByCheck == true || this.selectedIP == true || this.isCheckedSessionId == true || this.isCheckedPageId == true || this.isCheckedNVSessionID == true || (this.commonTag && this.commonTag.gTags && Object.keys(this.commonTag.gTags).length != 0)) {
            this.selectAnyCheckBoxFlag = false;
        }
        else {
            this.selectAnyCheckBoxFlag = true;
            console.log("this is the message for that case when we are not selecting time filter", this.showAnyCheckBoxErrorMessage);
            if (this.selectAnyCheckBoxFlag) {
                return;
            }
        }
        //Here it's work has finished.
        if (this.selectedTime == 'Custom Time') {
            if (this.startDateObj > this.endDateObj) {
                this.customTimeError = true;
            }
            else {
                this.customTimeError = false;
            }
            if (!this.strDate) {
                this.showStartTimeError = true;
                //alert("Please Provide Start Time");
            }
            if (!this.endDate) {
                this.showEndTimeError = true;
                //alert("Please Provide End Time");
            }
            if (this.showStartTimeError || this.showEndTimeError || this.customTimeError)
                return;
            if (this.commonServices.isValidParameter(this.strTimeInDateFormat) && this.commonServices.isValidParameter(this.endTimeInDateFormat) && this.showNSFilter) {
                let url = '';
                url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + '/v1/cavisson/netdiagnostics/ddr/timeHandling?testRun=' + this.urlParam.testRun + '&startTimeInDateFormat=' + this.strTimeInDateFormat + '&endTimeInDateFormat=' + this.endTimeInDateFormat;
                console.log("url for custom time--", url);
                this.ddrRequest.getDataUsingGet(url).subscribe(data => (this.assignCustomTime(data)));
            }
            else {
                this.strTime = this.sessionService.convertFormattedStringIntoTimestamp(this.strTimeInDateFormat).toString();
                this.endTime = this.sessionService.convertFormattedStringIntoTimestamp(this.endTimeInDateFormat).toString();
                this.applyFilter();
            }
        }
        else if ( /*this.timeFilter == true && */this.commonServices.isValidParameter(this.selectedTime) && this.selectedTime != "Whole Scenario") {
            this.getStandardTime();
            /* let restDrillDownUrl = this.urlParam.restDrillDownUrl;
            console.log("restDrillDownUrl--", restDrillDownUrl);
            let timeFilterUrl = '';
            if (this.isMultiDC && this.dcList.length != 0) {
      
              timeFilterUrl = this.selectedDC.ndeProtocol + "://" + this.selectedDC.pubicIP + ":" + this.selectedDC.publicPort + '/' + this.urlParam.product + '/v1/cavisson/netdiagnostics/ddr/getTimeStamp?testRun=' + this.selectedDC.ndeTestRun;
            }
      
            else {
              timeFilterUrl = this.getHostUrl() + '/' + this.urlParam.product.replace("/", "") + '/v1/cavisson/netdiagnostics/ddr/getTimeStamp?testRun=' + this.urlParam.testRun
            }
      
            timeFilterUrl = timeFilterUrl + "&graphTimeKey=" + this.selectedTime;
            console.log("time filter call outgoing ddrsideBar", timeFilterUrl);
            this.ddrRequest.getDataUsingGet(timeFilterUrl).subscribe(data => (this.setTimeFilter(data))); */
        }
        else {
            console.log("this.selectedTime   ", this.selectedTime);
            if (this.selectedTime == "Whole Scenario") {
                this.strTime = "";
                this.endTime = "";
                console.log("start time and end time set undefined");
            }
            this.applyFilter();
        }
    }
    assignCustomTime(res) {
        this.strTime = res.strStartTime;
        this.endTime = res.strEndTime;
        this.applyFilter();
    }
    applyFilter(isFromReset, isComponentChange) {
        // this.commonServices.currentReport = this.reportType ;this.previousReport == this.commonServices.currentReport
        console.log("this.commonServices.currentReport inside apply filter--", this.commonServices.currentReport);
        console.log("this.previousReport--", this.commonServices.previousReport);
        let msg = 'Filter for ' + this.commonServices.currentReport + ' Report is applied successfully';
        this._ddrData.setInLogger('DDR::Filter', this.commonServices.currentReport, 'Filters Apply', msg);
        if (this.tierName.length != 0) //default value blank array
         {
            // if (this.tierName.toString().indexOf('Overall') !=  -1) {
            //   this.tierNameFC = 'NA';
            //   this.tierId = ['NA'];
            // }
            // else   //getID
            // {
            this.tierId = [];
            for (let i = 0; i < this.tierName.length; i++) {
                let tierid = this.tierMetaData[this.tierName[i]];
                if (this.tierId.indexOf(tierid) == -1) //for unique ids
                    this.tierId.push(tierid);
            }
            this.tierNameFC = this.tierName.toString();
            // }
        }
        if (this.serverName.length != 0) {
            // if (this.serverName.indexOf('Overall') != -1)   //if tier Overall selected
            // {
            //   this.serverNameFC = "NA";
            //   this.serverId = ["NA"];
            // }
            // else {
            this.serverId = [];
            for (let i = 0; i < this.serverName.length; i++) {
                let serverid = this.serverMetaData[this.serverName[i]];
                if (this.serverId.indexOf(serverid) == -1)
                    this.serverId.push(serverid);
                let serverNameArr = this.serverName[i].split(":");
                if (i == 0)
                    this.serverNameFC = serverNameArr[1];
                else if (this.serverNameFC.indexOf(serverNameArr[1]) == -1)
                    this.serverNameFC += "," + serverNameArr[1];
            }
            // }
        }
        if (this.appName.length != 0) {
            // if (this.appName.toString().indexOf('Overall') != -1) {
            //   this.appNameFC = "NA";
            //   this.appId = ["NA"];
            // }
            // else  //getID
            // {
            this.appId = [];
            for (let i = 0; i < this.appName.length; i++) {
                let appid = this.appMetaData[this.appName[i]];
                if (this.appId.indexOf(appid) == -1)
                    this.appId.push(appid);
                let appNameArr = this.appName[i].split(":");
                if (i == 0)
                    this.appNameFC = appNameArr[2];
                else if (this.appNameFC.indexOf(appNameArr[2]) == -1)
                    this.appNameFC += "," + appNameArr[2];
            }
            // }
        }
        if (this.selectedFailureId != undefined) {
            for (let i = 0; i < this.selectedFailureId.length; i++) {
                if (i == 0) {
                    this.selectedFailureName = this.failureIdNameObj[this.selectedFailureId[i]];
                    this.selectedFailureNameId = this.selectedFailureId[i];
                }
                else {
                    this.selectedFailureName += "," + this.failureIdNameObj[this.selectedFailureId[i]];
                    this.selectedFailureNameId += "," + this.selectedFailureId[i];
                }
            }
        }
        //variable selectedPage has default value - undefined and is -null when it's unchecked 
        if (this.selectedPage != undefined && this.selectedPage != null) {
            let scriptPage = this.selectedPage.name.split(":"); // 0-script, 1-page
            this.page = scriptPage[1];
        }
        else
            this.page = "NA";
        this.queryData['reportType'] = this.commonServices.currentReport;
        this.queryData['fpInstance'] = this.fpInstance;
        this.queryData['tierName'] = this.tierName;
        this.queryData['serverName'] = this.serverName;
        this.queryData['appName'] = this.appName;
        this.queryData['tierId'] = this.tierId;
        this.queryData['serverId'] = this.serverId;
        this.queryData['appId'] = this.appId;
        this.queryData['resCompareOption'] = this.resSelectedCompareOption;
        if (this.resVariance != null && this.resVariance != "" && this.responseTime != null && this.responseTime != '') {
            console.log("this.resVariance before---", this.resVariance);
            this.responseTime1 = parseInt(this.responseTime) - parseInt(this.resVariance);
            console.log("this.resVariance after---", this.resVariance);
            console.log("responsetime1---", this.responseTime1);
            this.responseTime2 = parseInt(this.responseTime) + parseInt(this.resVariance);
            console.log("responsetime2 is---", this.responseTime2);
            if ((Number(this.resVariance) > Number(this.responseTime))) {
                this.responseTimeMessage = true;
            }
            else
                this.responseTimeMessage = false;
        }
        else {
            this.responseTimeMessage = false;
            this.responseTime1 = this.responseTime;
            this.responseTime2 = "";
        }
        this.queryData['responseTime'] = this.responseTime;
        this.queryData['responseTime2'] = this.responseTime2;
        this.queryData['minMethods'] = this.minMethods;
        this.queryData['corrId'] = this.corrId;
        this.queryData['corrIdModeOptions'] = this.selectedCorrIdMode;
        this.queryData['selectedBTCategory'] = this.selectedBTCategory;
        this.queryData['startTime'] = this.trStartTime;
        this.queryData['endTime'] = this.trEndTime;
        this.queryData['groupBy'] = this.selectedGroupBy;
        this.queryData['orderBy'] = this.selectedOrderBy;
        this.queryData['urlId'] = this.selectedUrlStatus;
        this.queryData['FailureId'] = this.selectedFailureId;
        this.queryData['FailureName'] = this.selectedFailureName;
        this.queryData['queryText'] = this.queryText;
        this.queryData['QueryType'] = this.selectedQueryType;
        this.queryData['Exception'] = this.selectedException;
        this.queryData['ExceptionThrowingClass'] = this.selectedExceptionThrowingClass;
        this.queryData['ExceptionThrowingMethod'] = this.selectedExceptionThrowingMethod;
        this.queryData['ExceptionCauseType'] = this.selectedExceptionCauseType;
        this.queryData['Stack'] = this.selectedStack;
        this.queryData['ExceptionMessageType'] = this.selectedExceptionMessageType;
        this.queryData['selectedUrl'] = this.selectedUrl;
        this.queryData['selectedPage'] = this.selectedPage;
        this.queryData['selectedScript'] = this.selectedScript;
        this.queryData['selectedTransaction'] = this.selectedTransaction;
        this.queryData['selectedLocation'] = this.selectedLocation;
        this.queryData['selectedBrowser'] = this.selectedBrowser;
        this.queryData['selectedAccess'] = this.selectedAccess;
        this.queryData['tags'] = this.gTagsStr;
        console.log("query data for tag = ", this.queryData['tags']);
        console.log("main start time", this.trStartTime);
        console.log("main end time", this.trEndTime);
        console.log("this.tierId");
        console.log('called on apply', this.queryData);
        console.log("this.commonServices._ddrSideBarOnApply is ", this.commonServices._ddrSideBarOnApply);
        if (this.commonServices.currentReport == 'DB Report') {
            if (this.commonServices.previousReport == this.commonServices.currentReport) {
                console.log("same report case in DB Report");
                this.assignDBFilters();
                this.commonServices.sideBarUI$.next(this.queryData);
            }
            else {
                console.log("changed report case routing from DB Report");
                this.assignDBDefaultFilters();
                this.commonServices.previousReport = 'DB Report'; // doing this so that now when user comes to flowpath report and then applying others filter without changing the report type
                this.commonServices.isFilterFromSideBar = true;
                if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                    this._router.navigate(['/home/ddrCopyLink/dbReport']);
                else
                    this._router.navigate(['/ddr/dbReport']);
            }
        }
        if (this.commonServices.currentReport == "Transaction Summary") {
            this.TickStrTime = true;
            this.TickEndTime = true;
            this.TickTransaction = true;
            this.TickTransactionId = true;
            this.TickUrl = true;
            this.TickUrlId = true;
            this.TickScript = true;
            this.TickScriptId = true;
            this.TickGroup = true;
            this.TickOrder = true;
            this.TickLocation = true;
            this.TickBrowser = true;
            this.TickAccess = true;
            this.TickStatus = true;
            if (isFromReset)
                this.commonServices.nsTransactionSummary = this.assignCommonFiltersForReset(this.commonServices.nsTransactionSummary);
            else
                this.commonServices.nsTransactionSummary = this.assignCommonFilters(this.commonServices.nsTransactionSummary);
            if (!isComponentChange)
                this.commonServices.isFilterFromNSSideBar = true;
            if (!isComponentChange && !isFromReset) // skip network request on init due to ngOnChangesCalling 
                this.commonServices.sideBarUI$.next(this.queryData);
        }
        if (this.commonServices.currentReport == "Transaction Instance") {
            this.TickStrTime = true;
            this.TickEndTime = true;
            this.TickTransaction = true;
            this.TickUrl = true;
            this.TickScript = true;
            this.TickGroup = true;
            this.TickOrder = true;
            this.TickPage = true;
            this.TickLocation = true;
            this.TickAccess = true;
            this.TickBrowser = true;
            this.TickStatus = true;
            if (isFromReset)
                this.commonServices.nsTransactionInstance = this.assignCommonFiltersForReset(this.commonServices.nsTransactionInstance);
            else
                this.commonServices.nsTransactionInstance = this.assignCommonFilters(this.commonServices.nsTransactionInstance);
            if (!isComponentChange)
                this.commonServices.isFilterFromNSSideBar = true;
            if (!isComponentChange && !isFromReset) // skip network request on init due to ngOnChangesCalling 
                this.commonServices.sideBarUI$.next(this.queryData);
        }
        if (this.commonServices.currentReport == "Page Instance") {
            this.TickStrTime = true;
            this.TickEndTime = true;
            this.TickTransaction = true;
            this.TickScript = true;
            this.TickGroup = true;
            this.TickOrder = true;
            this.TickPage = true;
            this.TickLocation = true;
            this.TickAccess = true;
            this.TickBrowser = true;
            this.TickStatus = true;
            if (isFromReset)
                this.commonServices.nsPageInstance = this.assignCommonFiltersForReset(this.commonServices.nsPageInstance);
            else
                this.commonServices.nsPageInstance = this.assignCommonFilters(this.commonServices.nsPageInstance);
            if (!isComponentChange)
                this.commonServices.isFilterFromNSSideBar = true;
            if (!isComponentChange && !isFromReset) // skip network request on init due to ngOnChangesCalling 
                this.commonServices.sideBarUI$.next(this.queryData);
        }
        if (this.commonServices.currentReport == "Page Summary") {
            this.TickStrTime = true;
            this.TickEndTime = true;
            this.TickTransaction = true;
            this.TickTransactionId = true;
            this.TickScript = true;
            this.TickScriptId = true;
            this.TickGroup = true;
            this.TickOrder = true;
            this.TickPage = true;
            this.TickPageId = true;
            this.TickLocation = true;
            this.TickBrowser = true;
            this.TickAccess = true;
            this.TickStatus = true;
            if (isFromReset)
                this.commonServices.nsPageSummary = this.assignCommonFiltersForReset(this.commonServices.nsPageSummary);
            else
                this.commonServices.nsPageSummary = this.assignCommonFilters(this.commonServices.nsPageSummary);
            if (!isComponentChange)
                this.commonServices.isFilterFromNSSideBar = true;
            if (!isComponentChange && !isFromReset) // skip network request on init due to ngOnChangesCalling 
                this.commonServices.sideBarUI$.next(this.queryData);
        }
        if (this.commonServices.currentReport == "Session Summary") {
            this.TickStrTime = true;
            this.TickEndTime = true;
            this.TickTransaction = true;
            this.TickTransactionId = true;
            this.TickUrl = true;
            this.TickUrlId = true;
            this.TickScript = true;
            this.TickScriptId = true;
            this.TickGroup = true;
            this.TickOrder = true;
            this.TickPage = true;
            this.TickPageId = true;
            this.TickStatus = true;
            this.TickLocation = true;
            this.TickBrowser = true;
            this.TickAccess = true;
            if (isFromReset)
                this.commonServices.nsSessionSummary = this.assignCommonFiltersForReset(this.commonServices.nsSessionSummary);
            else
                this.commonServices.nsSessionSummary = this.assignCommonFilters(this.commonServices.nsSessionSummary);
            if (!isComponentChange)
                this.commonServices.isFilterFromNSSideBar = true;
            if (!isComponentChange && !isFromReset) // skip network request on init due to ngOnChangesCalling 
                this.commonServices.sideBarUI$.next(this.queryData);
        }
        if (this.commonServices.currentReport == "Session Instance") {
            this.TickStrTime = true;
            this.TickEndTime = true;
            this.TickTransaction = true;
            this.TickUrl = true;
            this.TickScript = true;
            this.TickGroup = true;
            this.TickOrder = true;
            this.TickPage = true;
            this.TickLocation = true;
            this.TickAccess = true;
            this.TickBrowser = true;
            this.TickStatus = true;
            if (isFromReset)
                this.commonServices.nsSessionInstance = this.assignCommonFiltersForReset(this.commonServices.nsSessionInstance);
            else
                this.commonServices.nsSessionInstance = this.assignCommonFilters(this.commonServices.nsSessionInstance);
            if (!isComponentChange)
                this.commonServices.isFilterFromNSSideBar = true;
            if (!isComponentChange && !isFromReset) // skip network request on init due to ngOnChangesCalling 
                this.commonServices.sideBarUI$.next(this.queryData);
        }
        if (this.commonServices.currentReport == "URL Summary") {
            console.log("inside url summary side bar");
            if (isFromReset)
                this.commonServices.nsURLSummary = this.assignUrlFiltersForReset(this.commonServices.nsURLSummary);
            else
                this.commonServices.nsURLSummary = this.assignUrlFilters(this.commonServices.nsURLSummary);
            if (!isComponentChange)
                this.commonServices.isFilterFromNSSideBar = true;
            if (!isComponentChange && !isFromReset) // skip network request on init due to ngOnChangesCalling 
                this.commonServices.sideBarUI$.next(this.queryData);
        }
        if (this.commonServices.currentReport == "URL Instance") {
            console.log("inside url summary side bar");
            if (isFromReset)
                this.commonServices.nsURLInstance = this.assignUrlFiltersForReset(this.commonServices.nsURLInstance);
            else
                this.commonServices.nsURLInstance = this.assignUrlFilters(this.commonServices.nsURLInstance);
            if (!isComponentChange)
                this.commonServices.isFilterFromNSSideBar = true;
            if (!isComponentChange && !isFromReset) // skip network request on init due to ngOnChangesCalling 
                this.commonServices.sideBarUI$.next(this.queryData);
        }
        if (this.commonServices.currentReport == 'Method Timing') {
            if (this.commonServices.previousReport == this.commonServices.currentReport) {
                console.log("same report case in method timing");
                this.assignMethodTimingFilters();
                this.commonServices.sideBarUI$.next(this.queryData);
            }
            else {
                console.log("changed report case routing from method timing");
                this.assignMethodTimingDefaultFilters();
                this.commonServices.previousReport = 'Method Timing'; // doing this so that now when user comes to flowpath report and then applying others filter without changing the report type
                this.commonServices.isFilterFromSideBar = true;
                if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                    this._router.navigate(['/home/ddrCopyLink/methodtiming']);
                else
                    this._router.navigate(['/ddr/methodtiming']);
            }
        }
        if (this.commonServices.currentReport == 'Hotspot') {
            if (this.commonServices.previousReport == this.commonServices.currentReport) {
                console.log("same report case in hotspot");
                this.assignHotspotFilters();
                this.commonServices.sideBarUI$.next(this.queryData);
            }
            else {
                console.log("changed report case routing from hotspot");
                this.assignHotspotDefaultFilters();
                this.commonServices.previousReport = 'Hotspot'; // doing this so that now when user comes to flowpath report and then applying others filter without changing the report type
                this.commonServices.isFilterFromSideBar = true;
                if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                    this._router.navigate(['/home/ddrCopyLink/hotspot']);
                else
                    this._router.navigate(['/ddr/hotspot']);
            }
        }
        if (this.commonServices.currentReport == 'IP Summary') {
            if (this.commonServices.previousReport == this.commonServices.currentReport) {
                console.log("same report case in ipsummary");
                this.assignIPSummaryFilters();
                this.commonServices.sideBarUI$.next(this.queryData);
            }
            else {
                console.log("changed report case routing from ipsummary");
                this.assignIPSummaryDefaultFilters();
                this.commonServices.previousReport = 'IP Summary'; // doing this so that now when user comes to flowpath report and then applying others filter without changing the report type
                this.commonServices.isFilterFromSideBar = true;
                if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                    this._router.navigate(['/home/ddrCopyLink/ipsummary']);
                else
                    this._router.navigate(['/ddr/ipsummary']);
            }
        }
        if (this.commonServices.currentReport == 'Flowpath') {
            if (this.responseTimeMessage)
                alert("Response Time Variance must be less than or equal to actual response time");
            else {
                if (this.commonServices.previousReport == this.commonServices.currentReport) {
                    if (Object.keys(this.commonTag.gTags).length != 0) {
                        let tagSideBar = this.commonTag.gTags;
                        this.createTagDetail(tagSideBar);
                    }
                    console.log("same report case");
                    this.assignFlowpathFilters();
                    this.commonServices.sideBarUI$.next(this.queryData);
                }
                else {
                    console.log("changed report case routing");
                    this.assignFlowpathDefaultFilters();
                    this.commonServices.previousReport = 'Flowpath'; // doing this so that now when user comes to flowpath report and then applying others filter without changing the report type
                    this.commonServices.isFilterFromSideBar = true;
                    if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                        this._router.navigate(['/home/ddrCopyLink/flowpath']);
                    else
                        this._router.navigate(['/ddr/flowpath']);
                }
            }
        }
        if (this.commonServices.currentReport == 'Exception') {
            if ((this.selectedExceptionClass == true && this.selectedGroupBy.indexOf("excclass") != -1) || (this.selectedThrowingClass == true && this.selectedGroupBy.indexOf("excthrowingclass") != -1) || (this.selectedThrowingMethod == true && this.selectedGroupBy.indexOf("excthrowingmethod") != -1) ||
                (this.selectedExceptionCause == true && this.selectedGroupBy.indexOf("exccause") != -1) || (this.selectedExceptionMessage == true && this.selectedGroupBy.indexOf("excmessage") != -1)) {
                this.exceptionPopup = true;
                return;
            }
            else {
                if (this.commonServices.previousReport == this.commonServices.currentReport) {
                    console.log("same report case in exception");
                    this.assignExceptionFilters();
                    this.commonServices.sideBarUI$.next(this.queryData);
                }
                else {
                    console.log("changed report case routing from exception");
                    this.assignExceptionDefaultFilters();
                    this.commonServices.previousReport = 'Exception'; // doing this so that now when user comes to flowpath report and then applying others filter without changing the report type
                    this.commonServices.isFilterFromSideBar = true;
                    // this._router.navigate(['/home/ddr/exception']);
                    if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                        this._router.navigate(['/home/ddrCopyLink/exception']);
                    else
                        this._router.navigate(['/ddr/exception']);
                }
            }
        }
        if (this.commonServices.currentReport == 'FlowpathGroupBy') {
            if (this.commonServices.previousReport == this.commonServices.currentReport) {
                console.log("same report case in flowpathgroupby");
                this.assignFlowpathGroupByFilters();
                this.commonServices.sideBarUI$.next(this.queryData);
            }
            else {
                console.log("changed report case routing from flowpathgroupby");
                this.assignFlowpathGroupByDefaultFilters();
                this.commonServices.previousReport = 'FlowpathGroupBy'; // doing this so that now when user comes to flowpath report and then applying others filter without changing the report type
                this.commonServices.isFilterFromSideBar = true;
                if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                    this._router.navigate(['/home/ddrCopyLink/Flowpathgroupby']);
                else
                    this._router.navigate(['/ddr/Flowpathgroupby']);
            }
        }
        if (this.commonServices.currentReport == 'DBGroupBy') {
            if (this.commonServices.previousReport == this.commonServices.currentReport) {
                console.log("same report case in dbgroupby");
                this.assignDBGroupByFilters();
                this.commonServices.sideBarUI$.next(this.queryData);
            }
            else {
                console.log("changed report case routing from dbgroupby");
                this.assignDBGroupByDefaultFilters();
                this.commonServices.previousReport = 'DBGroupBy'; // doing this so that now when user comes to flowpath report and then applying others filter without changing the report type
                this.commonServices.isFilterFromSideBar = true;
                if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                    this._router.navigate(['/home/ddrCopyLink/dbGroupBy']);
                else
                    this._router.navigate(['/ddr/dbGroupBy']);
            }
        }
        this.commonServices.closeUISideBar$.next();
        this.dataChangeDetected.emit();
        if (this.commonServices.currentReport == "Transaction Summary" || this.commonServices.currentReport == "URL Summary"
            || this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Page Summary"
            || this.commonServices.currentReport == "Flowpath" || this.commonServices.currentReport == "FlowpathGroupBy"
            || this.commonServices.currentReport == 'DB Report' || this.commonServices.currentReport == 'DBGroupBy'
            || this.commonServices.currentReport == 'Exception' || this.commonServices.currentReport == 'Method Timing'
            || this.commonServices.currentReport == 'Hotspot' || this.commonServices.currentReport == 'IP Summary') {
            this.showSaveQuery = true;
        }
    }
    // reportTypeChange() {
    //   this.checkGroup = false;
    //   this.selectedGroupBy = [];
    //   this.checkOrder = false;
    //   this.selectedOrderBy = [];
    // }
    changeReport() {
        this.selectAnyCheckBoxFlag = false;
        console.log("check8888888888", this.sideheight);
        if (this.commonServices.currentReport == "Hotspot" || this.commonServices.currentReport == "IP Summary" || this.commonServices.currentReport == "DBGroupBy" || this.commonServices.currentReport == "Method Timing" || this.commonServices.currentReport == "FlowpathGroupBy") {
            this.sideheight = "556px";
        }
        else {
            this.sideheight = "auto";
        }
        // this.newReport = this.commonServices.currentReport
        this.selectedGroupBy = [];
        // if(this.testRunMode)
        // { console.log("this.commonServices.currentReport ",this.commonServices.currentReport,"  this.commonServices.previousReport",this.commonServices.previousReport)
        //   if(this.commonServices.currentReport!=this.commonServices.previousReport)
        //   {
        //     this.checkNSFilter();
        //   }
        // }                        this has been commented out for future when we will support report changes.
        this.getGroupBy();
    }
    checkInfo() {
        console.log("url value--", this.selectedUrl);
    }
    getGroupBy() {
        this.selectGroupByCheckBoxFlag = false;
        this.groupBy = [];
        if (this.showNSFilter) {
            if (this.commonServices.currentReport == 'Transaction Summary' || this.commonServices.currentReport == 'Transaction Instance') {
                // this.groupBy.push({ label: 'Session', value: 'session' });
                // this.groupBy.push({ label: 'Status', value: 'status' });
                this.groupBy.push({ label: 'Generator', value: 'generator' });
            }
            if (this.commonServices.currentReport == 'Session Summary' || this.commonServices.currentReport == 'Session Instance') {
                // this.groupBy.push({ label: 'Status', value: 'status' });
                this.groupBy.push({ label: 'Generator', value: 'generator' });
            }
            if (this.commonServices.currentReport == 'Page Summary' || this.commonServices.currentReport == 'Page Instance') {
                // this.groupBy.push({ label: 'Transaction', value: 'transaction' });
                // this.groupBy.push({ label: 'Session', value: 'session' });
                // this.groupBy.push({ label: 'Status', value: 'status' });
                this.groupBy.push({ label: 'Generator', value: 'generator' });
            }
            if (this.commonServices.currentReport == 'URL Summary' || this.commonServices.currentReport == 'URL Instance') {
                // this.groupBy.push({ label: 'Transaction', value: 'transaction' });
                // this.groupBy.push({ label: 'Session', value: 'session' });
                // this.groupBy.push({ label: 'Page', value: 'page' });
                // this.groupBy.push({ label: 'Status', value: 'status' });
                this.groupBy.push({ label: 'Generator', value: 'generator' });
            }
        }
        else {
            this.groupBy.push({ label: 'BT', value: 'url' });
            //this.groupBy.push({ label: 'FlowPath Signature', value: 'flowpathsignature' });
            this.groupBy.push({ label: 'Tier', value: 'tier' });
            this.groupBy.push({ label: 'Server', value: 'server' });
            this.groupBy.push({ label: 'Instance', value: 'app' });
            if (this.commonServices.currentReport != "Exception")
                this.groupBy.push({ label: 'BT Category', value: 'btcategory' });
            //this.groupBy.push({ label: 'Generator', value: 'generator' });
            /*   if (this.commonServices.currentReport == "DB Request") {
              this.groupBy.push({ label: 'Query Type', value: 'Query Type' });
            } */
            if (this.commonServices.currentReport == "Exception") {
                this.groupBy.push({ label: 'Exception Class', value: 'excclass' });
                this.groupBy.push({ label: 'Exception Throwing Class', value: 'excthrowingclass' });
                this.groupBy.push({ label: 'Exception Throwing Method', value: 'excthrowingmethod' });
                this.groupBy.push({ label: 'Exception Message', value: 'excmessage' });
                this.groupBy.push({ label: 'Exception Cause', value: 'exccause' });
            }
        }
        if (this.checkGroup == false) {
            this.selectedGroupBy = [];
            this.selectedOrderBy = []; // because when we disable groupby , the orderby options should not contains the groupby options
            this.checkOrder = false;
            this.selectOrderByCheckBoxFlag = false;
        }
    }
    getOrderBy() {
        this.selectOrderByCheckBoxFlag = false;
        this.orderBy = [];
        this.selectedOrderBy = [];
        this.checkOrder == false;
        console.log("this.selectedGroupBy list ---", this.selectedGroupBy);
        if (this.commonServices.currentReport == "Flowpath") {
            this.orderBy.push({ label: 'Average FP Duration ASC', value: 'avgfpduration' });
            this.orderBy.push({ label: 'Average FP Duration DESC', value: 'avgfpduration_desc' });
        }
        /* else if (this.commonServices.currentReport == "Exception") {
           this.orderBy.push({ label: 'Exception Class', value: 'excclass' });
           this.orderBy.push({ label: 'Exception Throwing Class', value: 'excthrowingclass' });
           this.orderBy.push({ label: 'Exception Throwing Method', value: 'excthrowingmethod' });
           this.orderBy.push({ label: 'Exception Message', value: 'excmessage' });
           this.orderBy.push({ label: 'Exception Cause', value: 'exccause' });
         }
         else {
           //this.orderBy.push({ label: 'Start Time', value: 'Exception Class' });
          // this.orderBy.push({ label: 'Execution Time Desc', value: 'avgfpduration' });
          // this.orderBy.push({ label: 'Execution Time ASC', value: 'avgfpduration_desc' });
         }*/
        console.log("selected group by===>", this.selectedGroupBy);
        if (this.selectedGroupBy.length != 0) {
            this.checkOrder == true;
            for (let i = 0; i < this.selectedGroupBy.length; i++) {
                if (this.selectedGroupBy[i] == 'url' && this.commonServices.currentReport != 'URL Summary' && this.commonServices.currentReport != 'URL Instance')
                    this.orderBy.push({ label: 'BT', value: 'url' });
                else if (this.selectedGroupBy[i] == 'page' && this.commonServices.currentReport != 'Page Summary' && this.commonServices.currentReport != 'Page Instance')
                    this.orderBy.push({ label: 'Page', value: 'page' });
                else if (this.selectedGroupBy[i] == 'transaction' && this.commonServices.currentReport != 'Transaction Summary' && this.commonServices.currentReport != 'Transaction Instance')
                    this.orderBy.push({ label: 'Transaction', value: 'transaction' });
                else if (this.selectedGroupBy[i] == 'session' && this.commonServices.currentReport != 'Session Summary' && this.commonServices.currentReport != 'Session Instance')
                    this.orderBy.push({ label: 'Session', value: 'session' });
                else if (this.selectedGroupBy[i] == 'tier')
                    this.orderBy.push({ label: 'Tier', value: 'tier' });
                else if (this.selectedGroupBy[i] == 'server')
                    this.orderBy.push({ label: 'Server', value: 'server' });
                else if (this.selectedGroupBy[i] == 'app')
                    this.orderBy.push({ label: 'Instance', value: 'app' });
                else if (this.selectedGroupBy[i] == 'btcategory')
                    this.orderBy.push({ label: 'BT Category', value: 'btcategory' });
                else if (this.selectedGroupBy[i] == 'excclass')
                    this.orderBy.push({ label: 'Exception Class', value: 'excclass' });
                else if (this.selectedGroupBy[i] == 'excthrowingclass')
                    this.orderBy.push({ label: 'Exception Throwing Class', value: 'excthrowingclass' });
                else if (this.selectedGroupBy[i] == 'excthrowingmethod')
                    this.orderBy.push({ label: 'Exception Throwing Method', value: 'excthrowingmethod' });
                else if (this.selectedGroupBy[i] == 'excmessage')
                    this.orderBy.push({ label: 'Exception Message', value: 'excmessage' });
                else if (this.selectedGroupBy[i] == 'exccause')
                    this.orderBy.push({ label: 'Exception Cause', value: 'exccause' });
                else if (this.selectedGroupBy[i] == 'generator' && this.commonServices.currentReport != "Transaction Instance" && this.commonServices.currentReport != "Transaction Summary" && this.commonServices.currentReport != "Page Summary" && this.commonServices.currentReport != "Page Instance" && this.commonServices.currentReport != "Session Summary" && this.commonServices.currentReport != "Session Instance"
                    && this.commonServices.currentReport != "URL Summary" && this.commonServices.currentReport != "URL Instance")
                    this.orderBy.push({ label: 'Generator', value: 'generator' });
                else if (this.selectedGroupBy[i] == 'status')
                    this.orderBy.push({ label: 'Status', value: 'status' });
            }
        }
        if (this.commonServices.currentReport == 'Transaction Summary' || this.commonServices.currentReport == 'Transaction Instance') {
            this.orderBy.push({ label: 'Transaction', value: 'transaction' });
        }
        else if (this.commonServices.currentReport == 'Session Summary' || this.commonServices.currentReport == 'Session Instance') {
            this.orderBy.push({ label: 'Session', value: 'session' });
        }
        else if (this.commonServices.currentReport == 'Page Summary' || this.commonServices.currentReport == 'Page Instance') {
            this.orderBy.push({ label: 'Page', value: 'page' });
        }
        else if (this.commonServices.currentReport == 'URL Summary' || this.commonServices.currentReport == 'URL Instance') {
            this.orderBy.push({ label: 'Url', value: 'url' });
        }
        if (this.checkOrder == false) {
            this.selectedOrderBy.length = 0;
        }
    }
    getgroupByFC() {
        this.groupByFC = [];
        for (let i = 0; i < this.selectedGroupBy.length; i++) {
            if (this.selectedGroupBy[i] == 'url')
                this.groupByFC.push('BT');
            else if (this.selectedGroupBy[i] == 'page')
                this.groupByFC.push('Page');
            else if (this.selectedGroupBy[i] == 'transaction')
                this.groupByFC.push('Transaction');
            else if (this.selectedGroupBy[i] == 'session')
                this.groupByFC.push('Session');
            else if (this.selectedGroupBy[i] == 'tier')
                this.groupByFC.push('Tier');
            else if (this.selectedGroupBy[i] == 'server')
                this.groupByFC.push('Server');
            else if (this.selectedGroupBy[i] == 'app')
                this.groupByFC.push('Instance');
            else if (this.selectedGroupBy[i] == 'btcategory')
                this.groupByFC.push('BT Category');
            else if (this.selectedGroupBy[i] == 'excclass')
                this.groupByFC.push('Exception Class');
            else if (this.selectedGroupBy[i] == 'excthrowingclass')
                this.groupByFC.push('Exception Throwing Class');
            else if (this.selectedGroupBy[i] == 'excthrowingmethod')
                this.groupByFC.push('Exception Throwing Method');
            else if (this.selectedGroupBy[i] == 'excmessage')
                this.groupByFC.push('Exception Message');
            else if (this.selectedGroupBy[i] == 'exccause')
                this.groupByFC.push('Exception Cause');
        }
        console.log("groupByFC--", this.groupByFC);
    }
    getOrderByFC() {
        this.orderByFC = [];
        for (let i = 0; i < this.selectedOrderBy.length; i++) {
            if (this.selectedOrderBy[i] == 'url')
                this.orderByFC.push('BT');
            else if (this.selectedOrderBy[i] == 'page')
                this.orderByFC.push('Page');
            else if (this.selectedOrderBy[i] == 'transaction')
                this.orderByFC.push('Transaction');
            else if (this.selectedOrderBy[i] == 'session')
                this.orderByFC.push('Session');
            else if (this.selectedOrderBy[i] == 'tier')
                this.orderByFC.push('Tier');
            else if (this.selectedOrderBy[i] == 'server')
                this.orderByFC.push('Server');
            else if (this.selectedOrderBy[i] == 'app')
                this.orderByFC.push('Instance');
            else if (this.selectedOrderBy[i] == 'btcategory')
                this.orderByFC.push('BT Category');
            else if (this.selectedOrderBy[i] == 'excclass')
                this.orderByFC.push('Exception Class');
            else if (this.selectedOrderBy[i] == 'excthrowingclass')
                this.orderByFC.push('Exception Throwing Class');
            else if (this.selectedOrderBy[i] == 'excthrowingmethod')
                this.orderByFC.push('Exception Throwing Method');
            else if (this.selectedOrderBy[i] == 'excmessage')
                this.orderByFC.push('Exception Message');
            else if (this.selectedOrderBy[i] == 'exccause')
                this.orderByFC.push('Exception Cause');
        }
    }
    fpInstanceInfo() {
        this.selectfpInstanceFlag = false;
        if (this.selectedFP == false) {
            this.commonServices.flowpathInstance = "";
            this.fpInstance = "";
        }
        //else
        // this.fpInstance = this.commonServices.flowpathInstance; 
    }
    ipData(res) {
        this.IntegrationPoint = [];
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            this.IntegrationPoint.push({ label: res[keys[i]].replace(/&#46;/g, "."), value: { id: keys[i], name: res[keys[i]] } });
            console.log("InegrationPoint data", res[keys[i]]);
            //this.exceptionClassOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
        }
    }
    btData(res) {
        this.BTOptions = [];
        // console.log('BTOptions  res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            if (this.message.urlName != undefined && this.message.urlName == keys[i])
                this.message.urlIndex = res[keys[i]];
            this.BTOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
            //console.log("bt url", keys[i]);
        }
        //this.selectedBuisnessTransaction =  { id: this.message.urlIndex, name: this.message.urlName };
    }
    nvFilters(type) {
        this.ndSessionIdFlag = false;
        this.nvPageIdFlag = false;
        this.nvSessionIdFlag = false;
        if (type == 'ndSessionID') {
            if (this.isCheckedSessionId == false) {
                this.ndSessionId = "";
            }
        }
        if (type == 'nvPageID') {
            if (this.isCheckedPageId == false) {
                this.nvPageId = "";
            }
        }
        if (type == 'nvSessionID') {
            if (this.isCheckedNVSessionID == false) {
                this.nvSessionId = "";
            }
        }
    }
    setDefaultTierServerAppFilter() {
        this.tierName = [];
        this.tierId = [];
        this.tierNameFC = 'NA';
        this.setDefaultServerAppFilter();
    }
    setDefaultServerAppFilter() {
        this.selectServerFlag = false;
        this.selectAppFlag = false;
        if (this.tierName.length > 20) {
            alert("Selected Tiers must be less than or equal to 20");
            this.tierName.length = this.tierName.length - 1;
            return;
        }
        this.serverList = [];
        this.serverName = [];
        this.serverId = [];
        this.selectedServer = false;
        this.serverNameFC = 'NA';
        this.appList = [];
        this.appName = [];
        this.appId = [];
        this.selectedApp = false; //uncheck   app checkbox
        this.appNameFC = "NA";
        this.tierId = [];
        this.selectedAppVal = undefined;
        this.selectedServerVal = undefined;
    }
    setDefaultAppFilter() {
        this.selectAppFlag = false;
        if (this.serverName.length > 20) {
            alert("Selected Servers must be less than or equal to 20");
            this.serverName.length = this.serverName.length - 1;
            return;
        }
        this.appList = [];
        this.appName = [];
        this.appId = [];
        this.selectedApp = false; //uncheck   app checkbox
        this.appNameFC = "NA";
        this.selectedAppVal = undefined;
        //  this.selectedServerVal = undefined;
    }
    appFilter() {
        if (this.appName.length > 20) {
            alert("Selected Instances must be less than or equal to 20");
            this.appName.length = this.appName.length - 1;
            return;
        }
    }
    //This function is called every time Instance checkbox is clicked ( either checked or unchecked)
    tierData(res) {
        console.log("method - tierData and tierMataData =", res);
        this.tierMetaData = res;
        this.tierList = [];
        let keys = Object.keys(res);
        //this.tierList.push({ label: 'Overall', value: 'Overall' });
        for (let i = 0; i < keys.length; i++) {
            let id = res[keys[i]]; //tierId
            let tName = keys[i]; //tierName
            this.tierList.push({ label: tName, value: tName });
        }
        /*  let tierArr = [];
          tierArr.push(this.message.tierName);
            this.tierName = tierArr;
            console.log("TierName after push---",this.tierName);*/
        console.log('method - tierData and tierlist ===', this.tierList);
    }
    serverData(res) {
        console.log("method - serverData and serverMataData =", res);
        this.serverMetaData = res;
        this.serverList = [];
        let keys = Object.keys(res);
        //this.serverList.push({ label: 'Overall', value: 'Overall' });
        for (let i = 0; i < keys.length; i++) {
            let id = res[keys[i]]; // serverId
            let tsName = keys[i]; //  tierName:serverName i.e - Tier29:AppServer29
            let tierServerName = tsName.split(":"); //index  0- tierName, 1- serverName
            //this.serverIdNameObj[id] =tierServerName[1];
            if (this.tierName.indexOf(tierServerName[0]) > -1) //serverNames of only selected tiers 
             {
                this.serverList.push({ label: tsName, value: tsName });
            }
            else if (this.tierName.length == 0) //when no tier is selected , show all servers 
             {
                this.serverList.push({ label: tsName, value: tsName });
            }
        }
        /*if(this.tierName.length ==  1){
          if(this.tierName[0] ==  this.message.tierName)
          var serverArr = [];
          serverArr.push(this.message.tierName+":"+this.message.serverName);
            this.serverName =serverArr;
        }
        console.log("After push server:-->",this.serverName);*/
        console.log('method - serverData and serverlist====', this.serverList);
    }
    appData(res) {
        console.log(" method - appData and appMataData =  =", res);
        this.appMetaData = res;
        this.appList = [];
        let keys = Object.keys(res);
        //this.appList.push({ label: 'Overall', value: 'Overall' });
        for (let i = 0; i < keys.length; i++) {
            let tsaName = keys[i]; //tierName:serverName:appName
            let tsaNameArr = tsaName.split(':');
            let tsName = tsaNameArr[0] + ":" + tsaNameArr[1];
            let tName = tsaNameArr[0];
            if (this.serverName.indexOf(tsName) > -1) //show instances of only selected servres
             {
                this.appList.push({ label: tsaName, value: tsaName });
            }
            else if (this.serverName.length == 0 && this.tierName.indexOf(tName) > -1) //when no server is selected then show instances of selected Tier
             {
                this.appList.push({ label: tsaName, value: tsaName });
            }
            else if (this.serverName.length == 0 && this.tierName.length == 0) //if no tier, no server is selected, show all instances 
             {
                this.appList.push({ label: tsaName, value: tsaName });
            }
        }
        /*if(this.tierName.length ==  1)
        {
          if(this.tierName[0] ==  this.message.tierName)
          var appArr  = [];
          appArr.push(this.message.tierName+":"+this.message.serverName+":"+this.message.appName);
            this.appName = appArr;
        }*/
        console.log(' method - appData and applist ===', this.appList);
    }
    onlyNumberKey(event) {
        return (event.charCode == 8 || event.charCode == 0) ? null : event.charCode >= 48 && event.charCode <= 57;
    }
    onlyNumberKeyAndComma(event) {
        if (this.fpInstance.slice(-1) == "," && event.charCode == 44) {
            return false;
        }
        else {
            return (event.charCode == 8 || event.charCode == 0) ? null : (event.charCode >= 48 && event.charCode <= 57) || event.charCode == 44;
        }
    }
    responseCheck() {
        this.selectResponseCheckBoxFlag = false;
        this.selectResponseCheckBoxFlag1 = false;
        if (this.checkedResponseTime == false) {
            this.showingEqualResponseBox = false;
            this.resSelectedCompareOption = "1";
            this.responseTime = "";
            this.resVariance = "";
            this.responseTimeMessage = false;
        }
    }
    responseEqualCase() {
        this.selectResponseCheckBoxFlag = false;
        this.selectResponseCheckBoxFlag1 = false;
        this.responseTimeMessage = false;
        console.log("initial value is", this.resSelectedCompareOption);
        if (this.resSelectedCompareOption == "3")
            this.showingEqualResponseBox = true;
        else {
            this.showingEqualResponseBox = false;
            this.resVariance = "";
        }
    }
    methodCheck() {
        this.selectedminMethodsFlag = false;
        if (this.checkedMethodCount == false)
            this.minMethods = "";
    }
    DLCheck() {
        console.log("i am in DL change");
    }
    ReqRespCheck() {
        console.log("i am in Request responce change");
    }
    corelationcheck() {
        this.selectedCorrIdModeFlag = false;
        this.selectedCorrIdModeFlag1 = false;
        this.selectedCorrIdModeFlag2 = false;
        if (this.checkedCorrId == false)
            this.selectedCorrIdMode = "";
        this.corrId = "";
    }
    btcheck() {
        this.selectBTCategoryFlag = false;
        if (this.selectedBT == false)
            this.selectedBTCategory = "";
    }
    checkTopNQuery() {
        this.selectCheckNQuerryFlag = false;
        if (this.checkNQueryforPie == false)
            this.selectedTopNQuery = '';
    }
    checkTopNEntity() {
        this.selectedTopNEntityFlag = false;
        if (this.checkNEntityforPie == false)
            this.selectedTopNEntity = '';
    }
    urlRadioButton() {
        this.selectFailureTypeFlag = false;
        console.log("inside urlbutton function");
        this.failure = false;
        this.selectedFailureId = [];
        this.selectedFailureName = "";
        this.selectedFailureNameId = "";
        if (this.selectedUrlStatus == -1) {
            this.selectedFailureNameId = "-1";
            this.selectedFailureName = 'Failures';
        }
        else if (this.selectedUrlStatus == 0) {
            this.selectedFailureNameId = "0";
            this.selectedFailureName = 'Success';
        }
        else {
            this.selectedFailureName = 'All';
            this.selectedFailureNameId = "-2";
        }
        console.log("select radio button id is ", this.selectedUrlStatus);
    }
    failureTypeData(res) {
        this.failureTypes = [];
        console.log('failure type res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            let errorCodeId = keys[i];
            let errorCodeName = res[keys[i]];
            if (errorCodeName != '1xx' && errorCodeName != '2xx' && errorCodeName != '3xx') {
                this.failureTypes.push({ label: errorCodeName, value: errorCodeId });
                this.failureIdNameObj[errorCodeId] = errorCodeName;
            }
        }
    }
    fpOrderCheck() {
        this.selectedFpOrderByFlag = false;
        if (this.fpOrderByCheck == false)
            this.selectedFpOrderBy = [];
    }
    dbOrderBy() {
        this.selectDBOrderByCheckFlag = false;
        if (this.dbOrderByCheck == false)
            this.selectedDbOrderBy = [];
    }
    //***************************------------exception -----------------******************************
    exceptionClassData(res) {
        this.exceptionClassOptions = [];
        console.log('exception res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            this.exceptionClassOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
        }
    }
    exceptionThrowingClassData(res) {
        this.throwingClassOptions = [];
        console.log('exception throwing res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            this.throwingClassOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
        }
    }
    exceptionThrowingMethodData(res) {
        this.throwingMethodOptions = [];
        console.log('exception throwing method res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            this.throwingMethodOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
        }
    }
    exceptionCauseData(res) {
        this.exceptionCauseOptions = [];
        console.log('exception cause  res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            this.exceptionCauseOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
        }
    }
    exceptionMessageData(res) {
        this.exceptionMessageOptions = [];
        console.log('exception cause  res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            this.exceptionMessageOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
        }
    }
    stackTraceInfo() {
        this.selectedStackFlag = false;
        if (this.selectedStackTrace == false) {
            this.selectedStack = "";
        }
    }
    // ********************************NS Filters ***********************************
    getUrlInfo(page, script) {
        const queryParam = {
            metaDataType: "url",
            testRun: this.urlParam.testRun,
            tierName: this.urlParam.tierName
        };
        if (!page && !script)
            this.URLInfoLoading = true;
        this.ndDdrHttpService.getMetadata(queryParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__["MetadataLoadedState"]) {
                let data = state.data;
                this.getUrlData(data);
                if (!page && !script)
                    this.URLInfoLoading = false;
            }
        }, (error) => {
            console.log("error getting~~", error);
        });
    }
    getScriptFilterCount(url, reportType) {
        url += '&get_count=1';
        let count;
        // this.ddrRequest.getDataUsingGet(url).pipe(map(data => (count=data)).subscribe(()=>{  // did hold it here but still query processing?? time wtf
        //   count=count.Rows;
        //   console.log("count value here ****** ",count);
        //   if(reportType=="url")
        //   {
        //     this.urlFilterCount=count;
        //     this.urlLimit=8;
        //     this.urlOffset=0;
        //     this.getLimtOffsetUpdate(this.urlLimit,this.urlOffset,this.urlFilterCount,reportType);
        //   }
        //     if(reportType=="transaction")
        //     {
        //       this.transFilterCount=count;
        //       this.transLimit=8;
        //       this.transOffset=0;
        //       this.getLimtOffsetUpdate(this.transLimit,this.transOffset,this.transFilterCount,reportType);
        //     }
        // }));
        //return count;
    }
    getLimtOffsetUpdate(limit, offset, count, reportType) {
        let difference;
        if (limit >= offset) {
            console.log(" Limit Offset cond 1 ** ", limit, " ", offset);
            difference = limit - offset;
        }
        else {
            console.log(" limit offset cond 2 ** ", limit, " ", offset);
            difference = offset - limit;
        }
        if (count > difference) {
            if (reportType == "url") {
                this.showUrlPagination = true;
                if (this.urlFilterCount > this.urlLimit) {
                    this.nxtUrl = true;
                    this.prevUrl = true;
                    this.urlEndValue = this.urlLimit;
                }
                else
                    this.urlEndValue = this.btCount;
            }
            if (reportType == "transaction")
                this.showTransactionPagination = true;
            if (reportType == "page")
                this.showPagePagination = true;
        }
        else //get this condition checked.
         {
            if (reportType == "url")
                this.showUrlPagination = false;
            if (reportType == "transaction")
                this.showTransactionPagination = false;
            if (reportType == "page")
                this.showPagePagination = false;
        }
    }
    nextFilterData(reportType) {
        if (reportType == "url") {
            console.log("offset before **** ", this.urlOffset);
            this.urlOffset += this.urlLimit;
            if ((this.urlLimit + this.urlOffset) >= this.urlFilterCount) {
                this.nxtUrl = false;
                this.prevUrl = true;
                this.urlEndValue = this.urlFilterCount;
            }
            else {
                this.nxtUrl = true;
                this.prevUrl = true;
                this.urlEndValue = this.urlLimit + this.urlOffset;
            }
            console.log("offset after **** ", this.urlOffset);
            this.validateUrlCheck();
        }
        if (reportType == "page") {
            console.log("offset before **** ", this.pageOffset);
            this.pageOffset += this.pageLimit;
            console.log("offset after **** ", this.pageOffset);
            this.validatePageCheck();
        }
        if (reportType == "transaction") {
            console.log("offset before **** ", this.transOffset);
            this.transOffset += this.transLimit;
            console.log("offset after **** ", this.transOffset);
            this.validateTransactionCheck();
        }
    }
    previousFilter(reportType) {
        if (reportType == "url") {
            this.urlOffset -= this.urlLimit;
            if (this.urlOffset <= 0) {
                this.prevUrl = false;
                this.nxtUrl = true;
                this.urlEndValue = this.urlLimit;
            }
            else {
                this.prevUrl = true;
                this.nxtUrl = true;
                this.urlEndValue = this.urlLimit + this.urlOffset;
            }
        }
    }
    getUrlData(res) {
        this.urlOptions = [];
        console.log('url  res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            let val = keys[i];
            // console.log("value is ", res[keys[i]]);
            // console.log("id is", val)
            // if (val.length > 40)
            //   val = val.substring(0, 40) + "..";
            this.urlOptions.push({ label: res[keys[i]], value: { id: keys[i], name: res[keys[i]] } });
            //  console.log("substring value is ", val);
        }
    }
    getPageData(res) {
        this.pageOptions = [];
        console.log('page res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++) {
            let sessionPage = res[keys[i]];
            let data = {};
            data[sessionPage.split(":")[0]] = sessionPage.substr(sessionPage.indexOf(":") + 1);
            let dataKey = Object.keys(data);
            console.log("data ****", data);
            console.log("res[keys[i]] ", res[keys[i]]);
            if (this.checkedScript == true && this.selectedScript) {
                let script = dataKey[0];
                if (this.selectedScript.name == script) // this will show only those page snames with script whose script matches with the selected script.
                 {
                    console.log("script value in page ", script);
                    this.pageOptions.push({ label: res[keys[i]], value: { id: keys[i], name: data[dataKey[0]] } });
                }
            }
            else {
                this.pageOptions.push({ label: res[keys[i]], value: { id: keys[i], name: data[dataKey[0]] } });
                // page name will be directly page name 
            }
        }
    }
    getScriptData(res) {
        this.scriptOptions = [];
        console.log('script res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++)
            this.scriptOptions.push({ label: res[keys[i]], value: { id: keys[i], name: res[keys[i]] } });
    }
    getTransactionData(res) {
        this.transactionOptions = [];
        console.log('transaction res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++)
            this.transactionOptions.push({ label: res[keys[i]], value: { id: keys[i], name: res[keys[i]] } });
    }
    //***************************---------Other NS Filters ------------********************
    getLocationData(res) {
        this.locationOptions = [];
        console.log('location res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++)
            this.locationOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
    }
    getBrowserData(res) {
        this.browserOptions = [];
        console.log('browser res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++)
            this.browserOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
    }
    getAccessData(res) {
        this.accessOptions = [];
        console.log('access res====', res, '======res.length===', Object.keys(res).length);
        let keys = Object.keys(res);
        for (let i = 0; i < keys.length; i++)
            this.accessOptions.push({ label: keys[i], value: { id: res[keys[i]], name: keys[i] } });
    }
    //*********************----------------Time Filter-------------------------****************************
    createDropDownMenu() {
        this.standardTime = [];
        this.phaseTime = [];
        this.standardTime.push({ label: 'Last 5 minutes', value: '5' });
        this.standardTime.push({ label: 'Last 10 minutes', value: '10' });
        this.standardTime.push({ label: 'Last 30 minutes', value: '30' });
        this.standardTime.push({ label: 'Last 1 hour', value: '60' });
        this.standardTime.push({ label: 'Last 2 hours', value: '120' });
        this.standardTime.push({ label: 'Last 4 hours', value: '240' });
        this.standardTime.push({ label: 'Last 6 hours', value: '360' });
        this.standardTime.push({ label: 'Last 8 hours', value: '480' });
        this.standardTime.push({ label: 'Last 12 hours', value: '720' });
        this.standardTime.push({ label: 'Last 24 hours', value: '1440' });
        if (this.showNSFilter) {
            this.standardTime.push({ label: 'Total Test Run', value: 'Whole Scenario' });
            this.standardTime.push({ label: 'Specified Phase', value: 'Specified Phase' });
        }
        this.standardTime.push({ label: 'Custom Time', value: 'Custom Time' });
    }
    onStrDate(event) {
        // let d = new Date(Date.parse(event));
        // this.strTime = `${d.getTime()}`;
        // console.log(this.strTime);
        if (event && event['inputType'] == "insertText") {
            if (this.strDate == new Date("1/1/1970 5:30:0"))
                this.showStartTimeError = true;
            else
                this.showStartTimeError = false;
            event = this.strDate;
        }
        else
            this.showStartTimeError = false;
        let date = new Date(event);
        this.startDateObj = date;
        this.strTimeInDateFormat = date.getMonth() + 1 + '/' + date.getDate() + '/' + date.getFullYear() + ' ' + date.getHours() + ':' + date.getMinutes() + ':' + date.getSeconds();
        console.log("onStrDate(event) ", this.strTime, this.strDate, this.strTimeInDateFormat);
    }
    onEndDate(event) {
        // let d = new Date(Date.parse(event));
        // this.endTime = `${d.getTime()}`;
        // console.log(this.endTime);
        if (event && event['inputType'] == "insertText") {
            if (this.endDate == new Date("1/1/1970 5:30:0"))
                this.showEndTimeError = true;
            else
                this.showEndTimeError = false;
            event = this.endDate;
        }
        else
            this.showEndTimeError = false;
        let date = new Date(event);
        this.endDateObj = date;
        this.endTimeInDateFormat = date.getMonth() + 1 + '/' + date.getDate() + '/' + date.getFullYear() + ' ' + date.getHours() + ':' + date.getMinutes() + ':' + date.getSeconds();
        console.log("onEndDate(event)", this.endTime, this.endDate, this.endTimeInDateFormat);
    }
    /* customFilter() {
       this.standselect = false;
       this.custselect = true;
       this.selectedTime = "";
     }
   
     standardFilter() {
       this.strDate = null;
       this.endDate = null;
       this.custselect = false;
       this.standselect = true;
   
     } */
    setTimeFilter(res) {
        console.log("set time filter is ", res);
        //this.trStartTime = res.ddrStartTime;
        //this.trEndTime = res.ddrEndTime;
        this.strTime = res.ddrStartTime;
        this.endTime = res.ddrEndTime;
        // this._ddrData.startTime = this.strTime;
        // this._ddrData.endTime = this.endTime;
        this.commonServices.nsTimeFlag = true;
        //this.standselect = false;
        //this.custselect = false;
        this.strDate = null;
        this.endDate = null;
        //console.log("ddr start time", this.trStartTime);
        //console.log("ddr end time", this.trEndTime);
        //this.getStandardTime();
        this.applyFilter();
    }
    getStandardTime() {
        var today = new Date(moment__WEBPACK_IMPORTED_MODULE_8__().tz(sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss'));
        var date = (today.getMonth() + 1) + '/' + today.getDate() + '/' + today.getFullYear();
        var times = today.getHours() + ":" + today.getMinutes() + ":" + today.getSeconds();
        console.log("checking before trStartTime", this.trStartTime);
        if (this.trStartTime != '' || this.trStartTime != undefined) {
            console.log("checking trStartTime", this.trStartTime);
            console.log("checking trStartTime", this.selectedTime.name);
            let time;
            let etTime = date + " " + times;
            this.trEndTime = this.sessionService.convertFormattedStringIntoTimestamp(etTime);
            if (this.selectedTime == 5) {
                time = 300000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 5 Minutes this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 10) {
                time = 600000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 10 Minutes this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 30) {
                time = 1800000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 30 Minutes this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 60) {
                time = 3600000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 1 hour this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 120) {
                time = 7200000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 2 hour this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 240) {
                time = 14400000;
                console.log("before stsrt", this.trStartTime);
                this.trStartTime = this.trEndTime - time;
                console.log(" last 4 hour this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 360) {
                time = 21600000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 6 hour this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 480) {
                time = 28800000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 8 hour this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 720) {
                time = 43200000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 12 hour this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == 1440) {
                time = 86400000;
                this.trStartTime = this.trEndTime - time;
                console.log(" last 24 hour this.trStartTime===", this.trStartTime, "this.trEndTime===", this.trEndTime);
            }
            else if (this.selectedTime == "Total Test Run") {
                this.trStartTime = "";
                this.trEndTime = "";
            }
            // this.standselect = false;
            // this.custselect = false;
            this.strDate = null;
            this.endDate = null;
            // this.selectedTime = "";
            this.strTime = this.trStartTime;
            this.endTime = this.trEndTime;
            this.applyFilter();
            //  alert("start time inside standard filter--"+this.strTime);
        }
    }
    timeOptions() {
        this.selectCheckBoxFlag = false;
        this.createDropDownMenu();
        if (this.timeFilter == false) {
            this.selectedTime = "";
            this.standardTime = [];
        }
    }
    getPhaseOptions() {
        if (this.selectedTime == 'Specified Phase') {
            let url = decodeURIComponent(this.getHostUrl()) + "/DashboardServer/v2/web/common/getPhaseList";
            let payload = {
                duration: null,
                opType: 301,
                tr: this.urlParam.testRun,
                cctx: this.sessionService.session.cctx,
                appId: "Default",
                clientId: "Default"
            };
            this.ddrRequest.getDataUsingPost(url, payload).subscribe(data => (this.getPhaseData(data)));
        }
    }
    fetchMetadata(metaDataType) {
        if (metaDataType === 'phaseList') {
            this.getPhaseOptions();
            return;
        }
        const queryParam = {
            metaDataType,
            testRun: this.urlParam.testRun,
            tierName: this.urlParam.tierName
        };
        this.ndDdrHttpService.getMetadata(queryParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_10__["MetadataLoadedState"]) {
                const data = state.data;
                this.handleData(metaDataType, data); // Pass the metaDataType to handleData
            }
        }, (error) => {
            console.log(`Error getting metadata for ${metaDataType}~~`, error);
        });
    }
    handleData(metaDataType, data) {
        switch (metaDataType) {
            case 'integrationPoint':
                this.ipData(data);
                break;
            case 'businessTransaction':
                this.btData(data);
                break;
            case 'businessTransactionCount':
                this.btCount(data);
                break;
            case 'tier':
                this.tierData(data);
                break;
            case 'server':
                this.serverData(data);
                break;
            case 'app':
                this.appData(data);
                break;
            case 'errorcodes':
                this.failureTypeData(data);
                break;
            case 'exceptionclassname':
                this.exceptionClassData(data);
                break;
            case 'exceptionthrowingclassname':
                this.exceptionThrowingClassData(data);
                break;
            case 'exceptionthrowingmethodname':
                this.exceptionThrowingMethodData(data);
                break;
            case 'exceptioncause':
                this.exceptionCauseData(data);
                break;
            case 'exceptionmsg':
                this.exceptionMessageData(data);
                break;
            case 'url':
                this.getUrlData(data);
                break;
            case 'page':
                this.getPageData(data);
                break;
            case 'script':
                this.getScriptData(data);
                break;
            case 'transaction':
                this.getTransactionData(data);
                break;
            case 'location':
                this.getLocationData(data);
                break;
            case 'browser':
                this.getBrowserData(data);
                break;
            case 'access':
                this.getAccessData(data);
                break;
            default:
                console.info(`No handler for metadata type ${metaDataType}`);
        }
    }
    getPhaseData(res) {
        const jsonString = JSON.stringify(res);
        const parsedRes = JSON.parse(jsonString);
        for (const element of parsedRes.items) {
            this.phaseTime.push({ label: element.label, value: { id: element.id, name: element } });
        }
    }
    // *********************************Assigning default filter to open report****************************************************
    assignFlowpathDefaultFilters() {
        console.log("this.id in dfault filter--", this.id);
        let fpParams = {};
        fpParams["testRun"] = this.id.testRun;
        fpParams["tierName"] = this.id.tierName;
        fpParams["tierId"] = this.id.tierId;
        fpParams["appId"] = this.id.appId;
        fpParams["appName"] = this.id.appName;
        fpParams["serverId"] = this.id.serverId;
        fpParams["serverName"] = this.id.serverName;
        fpParams["strStartTime"] = this.id.startTime;
        fpParams["strEndTime"] = this.id.endTime;
        fpParams["urlName"] = this.id.urlName;
        this.commonServices.fpFilters = fpParams;
        console.log("fparams--", fpParams);
        this.assignFlowpathFilters();
    }
    assignHotspotDefaultFilters() {
        let hsParams = {};
        hsParams['testRun'] = this.id.testRun;
        hsParams['tierId'] = this.id.tierId;
        hsParams['appId'] = this.id.appId;
        hsParams['serverId'] = this.id.serverId;
        hsParams['appName'] = this.id.appName;
        hsParams['serverName'] = this.id.serverName;
        hsParams['tierName'] = this.id.tierName;
        hsParams['strStartTime'] = this.id.startTime;
        hsParams['strEndTime'] = this.id.endTime;
        this.commonServices.hotspotFilters = hsParams;
        this.assignHotspotFilters();
    }
    assignIPSummaryDefaultFilters() {
        let ipParams = {};
        ipParams['testRun'] = this.id.testRun;
        ipParams['tierId'] = this.id.tierId;
        ipParams['appId'] = this.id.appId;
        ipParams['serverId'] = this.id.serverId;
        ipParams['appName'] = this.id.appName;
        ipParams['serverName'] = this.id.serverName;
        ipParams['tierName'] = this.id.tierName;
        ipParams['strStartTime'] = this.id.startTime;
        ipParams['strEndTime'] = this.id.endTime;
        ipParams['strGroup'] = 'url';
        ipParams['statusCode'] = '-2';
        ipParams['showCount'] = 'false';
        this.commonServices.ipSummaryFilters = ipParams;
        this.assignIPSummaryFilters();
    }
    assignDBDefaultFilters() {
        let dbParams = {};
        dbParams['testRun'] = this.id.testRun;
        dbParams['tierId'] = this.id.tierId;
        dbParams['appId'] = this.id.appId;
        dbParams['serverId'] = this.id.serverId;
        dbParams['appName'] = this.id.appName;
        dbParams['serverName'] = this.id.serverName;
        dbParams['tierName'] = this.id.tierName;
        dbParams['strStartTime'] = this.id.startTime;
        dbParams['strEndTime'] = this.id.endTime;
        dbParams['strOrderBy'] = 'exec_time_desc';
        this.commonServices.dbFilters = dbParams;
        this.assignDBFilters();
    }
    assignMethodTimingDefaultFilters() {
        let mtParams = {};
        mtParams['testRun'] = this.id.testRun;
        mtParams['tierId'] = this.id.tierId;
        mtParams['appId'] = this.id.appId;
        mtParams['serverId'] = this.id.serverId;
        mtParams['appName'] = this.id.appName;
        mtParams['serverName'] = this.id.serverName;
        mtParams['tierName'] = this.id.tierName;
        mtParams['strStartTime'] = this.id.startTime;
        mtParams['strEndTime'] = this.id.endTime;
        mtParams['urlName'] = this.id.urlName;
        mtParams['urlIndex'] = this.id.urlIndex;
        this.commonServices.methodTimingFilters = mtParams;
        this.assignMethodTimingFilters();
    }
    assignUrlFilters(commonParam) {
        let reportVal = {};
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportVal;
        if (this.selectedTime == 'Custom Time') {
            if (this.commonServices.isValidParameter(this.strTimeInDateFormat) && this.commonServices.isValidParameter(this.endTimeInDateFormat)) {
                reportVal['customStartTime'] = this.strTimeInDateFormat;
                reportVal['customEndTime'] = this.endTimeInDateFormat;
                reportVal['checkedTimeFIlter'] = this.timeFilter;
            }
            else {
                reportVal['customStartTime'] = undefined;
                reportVal['customEndTime'] = undefined;
                reportVal['checkedTimeFIlter'] = this.timeFilter;
            }
        }
        if (this.timeFilter && this.strTime != undefined && this.strTime != null) {
            commonParam["startTime"] = this.strTime;
            reportVal['startTime'] = this.strTime;
            reportVal['selectedTime'] = this.selectedTime;
            reportVal['checkedTimeFIlter'] = this.timeFilter;
        }
        else {
            if (this.selectedTime == 'Specified Phase')
                commonParam["startTime"] = this.selectedPhase.name.st;
            else
                commonParam["startTime"] = undefined;
            reportVal['startTime'] = undefined;
            reportVal['selectedTime'] = "";
            reportVal['checkedTimeFIlter'] = "";
        }
        if (this.timeFilter && this.endTime != undefined && this.endTime != null) {
            if (this.selectedTime == 'Specified Phase')
                commonParam["endTime"] = this.selectedPhase.name.et;
            else
                commonParam["endTime"] = this.endTime;
            reportVal['EndTime'] = this.endTime;
        }
        else {
            commonParam["endTime"] = undefined;
            reportVal['EndTime'] = undefined;
        }
        console.log("this.selectedTransaction--", this.selectedTransaction);
        if (this.checkedTransaction && this.selectedTransaction != undefined && this.selectedTransaction.name !== null && this.selectedTransaction.name !== undefined) {
            commonParam["transactionName"] = this.selectedTransaction.name;
            //  commonParam["transidx"] = this.selectedTransaction.id
            reportVal['TransactionName'] = this.selectedTransaction.name;
            reportVal['TransactionId'] = this.selectedTransaction.id;
        }
        else if (this.checkedTransaction == false) {
            commonParam["transactionName"] = undefined;
            commonParam["transidx"] = undefined;
        }
        if (this.checkedUrl && this.selectedUrl != undefined && this.selectedUrl.name !== null && this.selectedUrl.name !== undefined) {
            commonParam["url"] = encodeURIComponent(this.selectedUrl.name);
            commonParam["urlidx"] = this.selectedUrl.id;
            reportVal['UrlName'] = this.selectedUrl.name;
            reportVal['UrlId'] = this.selectedUrl.id;
        }
        else if (this.checkedUrl == false) {
            commonParam["url"] = undefined;
            commonParam["urlidx"] = undefined;
        }
        if (this.checkedPage && this.selectedPage != undefined && this.selectedPage.name !== null && this.selectedPage.name !== undefined) {
            commonParam["pageName"] = this.selectedPage.name;
            commonParam["pageidx"] = this.selectedPage.id;
            reportVal['PageName'] = this.selectedPage.name;
            reportVal['PageId'] = this.selectedPage.id;
        }
        else if (this.checkedPage == false) {
            commonParam["pageName"] = undefined;
            commonParam["pageidx"] = undefined;
        }
        if (this.checkedScript && this.selectedScript != undefined && this.selectedScript.name !== null && this.selectedScript.name !== undefined) {
            commonParam["scriptName"] = decodeURIComponent(this.selectedScript.name);
            commonParam["scriptidx"] = this.selectedScript.id;
            reportVal['ScriptName'] = this.selectedScript.name;
            reportVal['ScriptId'] = this.selectedScript.id;
        }
        else {
            commonParam["scriptName"] = "";
            commonParam["scriptidx"] = "";
            reportVal['ScriptName'] = "";
            reportVal['ScriptId'] = "";
        }
        // commenting this due to migration
        // else if (this.checkedScript === false) {
        //   if (this.nsCommonData.urlsessionsummarydata && this.nsCommonData.urlsessionsummarydata.scriptName) {
        //     commonParam["ScriptName"] = this.nsCommonData.urlsessionsummarydata.scriptName;
        //   }
        //   else {
        //     commonParam["scriptName"] = undefined;
        //     commonParam["scriptidx"] = undefined;
        //   }
        // }
        console.log("this.checkedBrowser-", this.checkedBrowser);
        if (this.checkedLocation && this.selectedLocation != undefined && this.selectedLocation.name !== null && this.selectedLocation.name !== undefined) {
            commonParam["location"] = this.selectedLocation.name;
            reportVal['Location'] = this.selectedLocation.name;
        }
        else if (this.checkedLocation === false)
            delete commonParam["location"];
        if (this.checkedBrowser && this.selectedBrowser != undefined && this.selectedBrowser.name !== null && this.selectedBrowser.name !== undefined) {
            commonParam["browser"] = this.selectedBrowser.name;
            reportVal['Browser'] = this.selectedBrowser.name;
        }
        else if (this.checkedBrowser === false)
            delete commonParam["browser"];
        if (this.checkedAccess && this.selectedAccess != undefined && this.selectedAccess.name !== null && this.selectedAccess.name !== undefined) {
            commonParam["access"] = this.selectedAccess.name;
            reportVal['Access'] = this.selectedAccess.name;
        }
        else if (this.checkedAccess === false)
            delete commonParam["access"];
        if (this.selectedFailureNameId != "" && this.selectedFailureNameId != undefined) {
            commonParam["statusCode"] = this.selectedFailureNameId;
            commonParam["statusCodeFC"] = this.selectedFailureName;
            reportVal['StatusName'] = this.selectedFailureName;
            reportVal['StatusId'] = this.selectedFailureNameId;
        }
        else {
            commonParam["statusCode"] = "-2";
            commonParam["statusCodeFC"] = "";
        }
        if ((this.checkGroup && this.selectedGroupBy != undefined && this.selectedGroupBy != null && this.selectedGroupBy.length != 0)
            || this.scriptGroup) {
            let mergeGroup = [];
            mergeGroup = this.selectedGroupBy.concat(this.groupByFilter);
            //console.log("before merge ******* group ",mergeGroup);
            mergeGroup = mergeGroup.filter((e, i) => mergeGroup.indexOf(e) >= i);
            //console.log("after merge ***** group ",mergeGroup);
            commonParam['strGroupBy'] = mergeGroup;
            reportVal['Group'] = this.selectedGroupBy;
        }
        else
            commonParam["strGroupBy"] = '';
        if (this.checkOrder && this.selectedOrderBy != undefined && this.selectedOrderBy != null && this.selectedOrderBy.length != 0) {
            commonParam["order"] = this.selectedOrderBy;
            reportVal['Order'] = this.selectedOrderBy;
        }
        else
            delete commonParam["order"];
        if (this.selectedTime == 'Specified Phase' && this.timeFilter && this.selectedPhase != undefined && this.selectedPhase != null && this.selectedPhase != '') {
            commonParam["phaseidx"] = "";
            commonParam["phaseName"] = this.selectedPhase.name.label;
            reportVal['PhaseName'] = this.selectedPhase.name.label;
            reportVal['PhaseId'] = this.selectedPhase.id;
        }
        else {
            delete commonParam["phaseidx"];
            delete commonParam['phaseName'];
        }
        if (this.checkedResponseTime && this.responseTime != '' && this.checkedResponseTime == true) {
            commonParam["responsetime"] = this.responseTime;
            commonParam["resptimeqmode"] = this.resSelectedCompareOption;
            reportVal['ResponseTime'] = this.responseTime;
            reportVal['ResponseTimeMode'] = this.resSelectedCompareOption;
        }
        else {
            delete commonParam["responsetime"];
            delete commonParam["resptimeqmode"];
        }
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportVal;
        //console.log("common param for URL===>",commonParam);
        return commonParam;
    }
    assignUrlFiltersForReset(commonParam) {
        let reportVal = {};
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportVal;
        if (this.selectedTime == 'Custom Time') {
            if (this.commonServices.isValidParameter(this.strTimeInDateFormat) && this.commonServices.isValidParameter(this.endTimeInDateFormat))
                reportVal['customStartTime'] = this.strTimeInDateFormat;
            reportVal['customEndTime'] = this.endTimeInDateFormat;
            reportVal['checkedTimeFIlter'] = this.timeFilter;
        }
        commonParam["startTime"] = undefined;
        reportVal['startTime'] = undefined;
        reportVal['selectedTime'] = "";
        reportVal['checkedTimeFIlter'] = "";
        commonParam["endTime"] = undefined;
        reportVal['EndTime'] = undefined;
        reportVal['TransactionName'] = "";
        reportVal['TransactionId'] = "";
        commonParam["transactionName"] = undefined;
        commonParam["transidx"] = undefined;
        commonParam["url"] = "";
        commonParam["urlidx"] = "";
        reportVal['UrlName'] = "";
        reportVal['UrlId'] = "";
        commonParam["url"] = undefined;
        commonParam["urlidx"] = undefined;
        reportVal['PageName'] = "";
        reportVal['PageId'] = "";
        commonParam["pageName"] = undefined;
        commonParam["pageidx"] = undefined;
        commonParam["scriptName"] = "";
        commonParam["scriptidx"] = "";
        reportVal['ScriptName'] = "";
        reportVal['ScriptId'] = "";
        commonParam["location"] = "";
        reportVal['Location'] = "";
        commonParam["browser"] = "";
        reportVal['Browser'] = "";
        commonParam["access"] = "";
        reportVal['Access'] = "";
        reportVal['StatusName'] = "";
        reportVal['StatusId'] = "";
        commonParam["statusCode"] = "-2";
        commonParam["statusCodeFC"] = "";
        commonParam['strGroupBy'] = "";
        reportVal['Group'] = "";
        commonParam["order"] = "";
        reportVal['Order'] = "";
        commonParam["phaseidx"] = "";
        commonParam["phaseName"] = "";
        reportVal['PhaseName'] = "";
        reportVal['PhaseId'] = "";
        commonParam["responsetime"] = "";
        commonParam["resptimeqmode"] = "";
        reportVal['ResponseTime'] = "";
        reportVal['ResponseTimeMode'] = "";
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportVal;
        return commonParam;
    }
    assignCommonFilters(commonParam) {
        // when user click on apply button we are making a object for data i.e whatever filter he has selected as well as for the CQM user UI.
        let reportVal = {};
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportVal; //for CQM UI
        if (this.selectedTime == 'Custom Time') {
            if (this.commonServices.isValidParameter(this.strTimeInDateFormat) && this.commonServices.isValidParameter(this.endTimeInDateFormat)) {
                reportVal['customStartTime'] = this.strTimeInDateFormat;
                reportVal['customEndTime'] = this.endTimeInDateFormat;
                reportVal['checkedTimeFIlter'] = this.timeFilter;
            }
            else {
                reportVal['customStartTime'] = undefined;
                reportVal['customEndTime'] = undefined;
                reportVal['checkedTimeFIlter'] = "";
            }
        }
        if (this.commonServices.currentReport == 'Transaction Summary' || this.commonServices.currentReport == 'Transaction Instance') {
            if (this.timeFilter && this.strTime != undefined && this.strTime != null) {
                commonParam["strStartTime"] = this.strTime;
                reportVal['startTime'] = this.strTime;
                reportVal['selectedTime'] = this.selectedTime;
                reportVal['checkedTimeFIlter'] = this.timeFilter;
            }
            else {
                commonParam["strStartTime"] = undefined;
                reportVal['startTime'] = undefined;
                reportVal['selectedTime'] = "";
                reportVal['checkedTimeFIlter'] = "";
            }
            if (this.timeFilter && this.endTime != undefined && this.endTime != null) {
                commonParam["strEndTime"] = this.endTime;
                reportVal['EndTime'] = this.endTime;
            }
            else {
                commonParam["strEndTime"] = undefined;
                reportVal['EndTime'] = undefined;
            }
        }
        else {
            if (this.timeFilter && this.strTime != undefined && this.strTime != null) {
                commonParam["startTime"] = this.strTime;
                reportVal['startTime'] = this.strTime;
                reportVal['selectedTime'] = this.selectedTime;
                reportVal['checkedTimeFIlter'] = this.timeFilter;
            }
            else {
                commonParam["startTime"] = undefined;
                reportVal['startTime'] = undefined;
                reportVal['selectedTime'] = "";
                reportVal['checkedTimeFIlter'] = "";
            }
            if (this.timeFilter && this.endTime != undefined && this.endTime != null) {
                commonParam["endTime"] = undefined;
                reportVal['EndTime'] = undefined;
            }
        }
        if (this.TickTransaction && this.checkedTransaction && this.selectedTransaction != undefined && this.selectedTransaction != null) {
            commonParam["transactionName"] = this.selectedTransaction.name;
            if (this.TickTransactionId)
                commonParam["transidx"] = this.selectedTransaction.id;
            // this._ddrData.transactionName=undefined;
            reportVal['TransactionName'] = this.selectedTransaction.name;
            reportVal['TransactionId'] = this.selectedTransaction.id;
        }
        else {
            if (this._ddrData.transactionName != undefined) {
                commonParam["transactionName"] = this._ddrData.transactionName;
            }
            else {
                delete commonParam["transactionName"];
            }
            delete commonParam["transidx"];
        }
        if (this.TickUrl && this.checkedUrl && this.selectedUrl != undefined && this.selectedUrl != null) {
            commonParam["url"] = encodeURIComponent(this.selectedUrl.name);
            if (this.TickUrlId)
                commonParam["urlidx"] = this.selectedUrl.id;
            reportVal['UrlName'] = this.selectedUrl.name;
            reportVal['UrlId'] = this.selectedUrl.id;
        }
        else {
            delete commonParam["url"];
            delete commonParam["urlidx"];
        }
        if (this.TickPage && this.checkedPage && this.selectedPage != undefined && this.selectedPage != null) {
            if (this.commonServices.currentReport.indexOf("Page") != -1) { // in case of all page reports.
                commonParam["pageName"] = this.selectedPage.name;
                if (this.TickPageId)
                    commonParam["pageIndex"] = this.selectedPage.id;
            }
            else {
                commonParam["page"] = this.selectedPage.name;
                if (this.TickPageId)
                    commonParam["pageidx"] = this.selectedPage.id;
            }
            reportVal['PageName'] = this.selectedPage.name;
            reportVal['PageId'] = this.selectedPage.id;
        }
        else {
            delete commonParam["pageName"];
            delete commonParam["pageIndex"];
            delete commonParam["page"];
            delete commonParam["pageidx"];
        }
        if (this.TickScript && this.checkedScript && this.selectedScript != undefined && this.selectedScript != null) {
            if (this.commonServices.currentReport == 'Page Instance' || this.commonServices.currentReport == "Page Summary"
                || this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Session Instance")
                commonParam["scriptName"] = decodeURIComponent(this.selectedScript.name);
            else
                commonParam["script"] = decodeURIComponent(this.selectedScript.name);
            if (this.TickScriptId)
                commonParam["scriptidx"] = this.selectedScript.id;
            reportVal['ScriptName'] = this.selectedScript.name;
            reportVal['ScriptId'] = this.selectedScript.id;
        }
        else {
            delete commonParam["scriptName"];
            delete commonParam["script"];
            delete commonParam["scriptidx"];
        }
        if (this.TickLocation && this.checkedLocation && this.selectedLocation != undefined && this.selectedLocation != null) {
            commonParam["location"] = this.selectedLocation.name;
            reportVal['Location'] = this.selectedLocation.name;
        }
        else {
            delete commonParam["location"];
        }
        if (this.TickAccess && this.checkedAccess && this.selectedAccess != undefined && this.selectedAccess != null) {
            commonParam["access"] = this.selectedAccess.name;
            reportVal['Access'] = this.selectedAccess.name;
        }
        else {
            delete commonParam["access"];
        }
        if (this.TickBrowser && this.checkedBrowser && this.selectedBrowser != undefined && this.selectedBrowser != null) {
            commonParam["browser"] = this.selectedBrowser.name;
            reportVal['Browser'] = this.selectedBrowser.name;
        }
        else {
            delete commonParam["browser"];
        }
        if ((this.TickGroup && this.checkGroup && this.selectedGroupBy != undefined && this.selectedGroupBy != null && this.selectedGroupBy.length != 0)
            || this.scriptGroup) {
            let mergeGroup = [];
            mergeGroup = this.selectedGroupBy.concat(this.groupByFilter);
            //console.log("before merge ******* group ",mergeGroup);
            mergeGroup = mergeGroup.filter((e, i) => mergeGroup.indexOf(e) >= i);
            //console.log("after merge ***** group ",mergeGroup);
            if (this.commonServices.currentReport == 'Session Summary')
                commonParam["strGroupBy"] = mergeGroup[0];
            else
                commonParam["group"] = mergeGroup[0];
            reportVal['Group'] = this.selectedGroupBy; //this will store value in slected Group by as its UI filter applied by user.      
        }
        else {
            if (this.commonServices.currentReport == 'Session Summary')
                commonParam["strGroupBy"] = '';
            else
                commonParam["group"] = '';
        }
        if (this.TickOrder && this.checkOrder && this.selectedOrderBy != undefined && this.selectedOrderBy != null && this.selectedOrderBy.length != 0) {
            commonParam["order"] = this.selectedOrderBy;
            reportVal['Order'] = this.selectedOrderBy;
        }
        else {
            delete commonParam["order"];
        }
        if (this.TickStatus && this.selectedUrlStatus && this.selectedFailureNameId != undefined && this.selectedFailureNameId != null) {
            if (this.commonServices.currentReport == 'Session Instance')
                commonParam["strStatus"] = this.selectedFailureNameId;
            else {
                if (this.commonServices.currentReport == "Transaction Summary" || (this.commonServices.currentReport == "Transaction Instance") || (this.commonServices.currentReport == "URL Summary") || (this.commonServices.currentReport == "URL Instance")) {
                    if (commonParam.statusCode != undefined || commonParam.statusCode != null)
                        commonParam["statusCode"] = this.selectedFailureNameId;
                }
                else {
                    if (commonParam.status != undefined || commonParam.status != null)
                        commonParam["status"] = this.selectedFailureNameId;
                }
            }
            commonParam["statusName"] = this.selectedFailureName;
            reportVal['StatusName'] = this.selectedFailureName;
            reportVal['StatusId'] = this.selectedFailureNameId;
        }
        if (this.selectedTime == 'Specified Phase' && this.timeFilter && this.selectedPhase != undefined && this.selectedPhase != null && this.selectedPhase != '') {
            commonParam["phaseidx"] = "";
            commonParam["phaseName"] = this.selectedPhase.name.label;
            reportVal['PhaseName'] = this.selectedPhase.name.label;
            reportVal['PhaseId'] = this.selectedPhase.id;
        }
        else {
            delete commonParam["phaseName"];
            delete commonParam["phaseidx"];
        }
        if (this.checkedResponseTime && this.responseTime != '' && this.checkedResponseTime == true) {
            commonParam["responsetime"] = this.responseTime;
            commonParam["resptimeqmode"] = this.resSelectedCompareOption;
            reportVal['ResponseTime'] = this.responseTime;
            reportVal['ResponseTimeMode'] = this.resSelectedCompareOption;
            console.log("inside the response condition===>");
        }
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportVal;
        //  console.log("common param are===>",commonParam);
        return commonParam;
    }
    assignCommonFiltersForReset(commonParam) {
        let reportVal = {};
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportVal; //for CQM UI
        if (this.selectedTime == 'Custom Time') {
            if (this.commonServices.isValidParameter(this.strTimeInDateFormat) && this.commonServices.isValidParameter(this.endTimeInDateFormat))
                reportVal['customStartTime'] = this.strTimeInDateFormat;
            reportVal['customEndTime'] = this.endTimeInDateFormat;
            reportVal['checkedTimeFIlter'] = this.timeFilter;
        }
        if (this.commonServices.currentReport == 'Transaction Summary' || this.commonServices.currentReport == 'Transaction Instance') {
            commonParam["strStartTime"] = undefined;
            reportVal['startTime'] = undefined;
            reportVal['selectedTime'] = "";
            reportVal['checkedTimeFIlter'] = "";
            commonParam["strEndTime"] = undefined;
            reportVal['EndTime'] = undefined;
        }
        else {
            commonParam["startTime"] = undefined;
            reportVal['startTime'] = undefined;
            reportVal['selectedTime'] = "";
            reportVal['checkedTimeFIlter'] = "";
            commonParam["endTime"] = undefined;
            reportVal['EndTime'] = undefined;
        }
        commonParam["transactionName"] = "";
        commonParam["transidx"] = "";
        reportVal['TransactionName'] = "";
        reportVal['TransactionId'] = "";
        delete commonParam["transactionName"];
        delete commonParam["transidx"];
        commonParam["url"] = "";
        commonParam["urlidx"] = "";
        reportVal['UrlName'] = "";
        reportVal['UrlId'] = "";
        if (this.commonServices.currentReport.indexOf("Page") != -1) { // in case of all page reports.
            commonParam["pageName"] = "";
            if (this.TickPageId)
                commonParam["pageIndex"] = "";
        }
        else {
            commonParam["page"] = "";
            if (this.TickPageId)
                commonParam["pageidx"] = "";
        }
        reportVal['PageName'] = "";
        reportVal['PageId'] = "";
        if (this.commonServices.currentReport == 'Page Instance' || this.commonServices.currentReport == "Page Summary"
            || this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Session Instance")
            commonParam["scriptName"] = "";
        else
            commonParam["script"] = "";
        commonParam["scriptidx"] = "";
        reportVal['ScriptName'] = "";
        reportVal['ScriptId'] = "";
        commonParam["location"] = "";
        reportVal['Location'] = "";
        commonParam["access"] = "";
        reportVal['Access'] = "";
        commonParam["browser"] = "";
        reportVal['Browser'] = "";
        commonParam["strGroupBy"] = "";
        commonParam["group"] = "";
        reportVal['Group'] = "";
        commonParam["order"] = "";
        reportVal['Order'] = "";
        if (this.commonServices.currentReport == 'Session Instance')
            commonParam["strStatus"] = "-2";
        if (this.commonServices.currentReport == 'Session Summary' || (this.commonServices.currentReport == "Page Summary") || (this.commonServices.currentReport == "Page Instance"))
            commonParam["status"] = "-2";
        else
            commonParam["statusCode"] = "-2";
        commonParam["statusName"] = "";
        reportVal['StatusId'] = "";
        commonParam["phaseidx"] = "";
        commonParam["phaseName"] = "";
        reportVal['PhaseName'] = "";
        reportVal['PhaseId'] = "";
        commonParam["responsetime"] = "";
        commonParam["resptimeqmode"] = "";
        reportVal['ResponseTime'] = "";
        reportVal['ResponseTimeMode'] = "";
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportVal;
        return commonParam;
    }
    assignExceptionDefaultFilters() {
        console.log("inside default filter method");
        let exParams = {};
        exParams['testRun'] = this.id.testRun;
        exParams['tierId'] = this.id.tierId;
        exParams['appId'] = this.id.appId;
        exParams['serverId'] = this.id.serverId;
        exParams['appName'] = this.id.appName;
        exParams['serverName'] = this.id.serverName;
        exParams['tierName'] = this.id.tierName;
        exParams['strStartTime'] = this.id.startTime;
        exParams['strEndTime'] = this.id.endTime;
        this.checkGroup = true;
        this.getGroupBy();
        this.selectedGroupBy = [];
        this.selectedGroupBy.push('excclass');
        this.selectedGroupBy.push('excthrowingclass');
        this.selectedGroupBy.push('excthrowingmethod');
        // exParams['urlName'] = this.id.urlName
        // exParams['urlIndex'] = this.id.urlIndex
        this.commonServices.exceptionFilters = exParams;
        this.assignExceptionFilters();
        console.log("in the end this.commonServices.exceptionFilters--", this.commonServices.exceptionFilters);
    }
    assignFlowpathGroupByDefaultFilters() {
        let fpGroupByParams = {};
        fpGroupByParams["testRun"] = this.id.testRun;
        fpGroupByParams["tierName"] = this.id.tierName;
        fpGroupByParams["tierId"] = this.id.tierId;
        fpGroupByParams["appId"] = this.id.appId;
        fpGroupByParams["appName"] = this.id.appName;
        fpGroupByParams["serverId"] = this.id.serverId;
        fpGroupByParams["serverName"] = this.id.serverName;
        fpGroupByParams["strStartTime"] = this.id.startTime;
        fpGroupByParams["strEndTime"] = this.id.endTime;
        fpGroupByParams["btCategory"] = 'All';
        fpGroupByParams["strGroup"] = 'url';
        fpGroupByParams["strOrder"] = '';
        //   fpGroupByParams["strEndTime"] = this.id.endTime
        // '&btCategory=All' + '&strGroup=url' + '&strOrder=url' + "&groupByFC=BT"
        this.commonServices.fpGroupByFilters = fpGroupByParams;
        this.assignFlowpathGroupByFilters();
    }
    assignDBGroupByDefaultFilters() {
        let dbGroupByParams = {};
        dbGroupByParams["testRun"] = this.id.testRun;
        dbGroupByParams["tierName"] = this.id.tierName;
        dbGroupByParams["tierId"] = this.id.tierId;
        dbGroupByParams["appId"] = this.id.appId;
        dbGroupByParams["appName"] = this.id.appName;
        dbGroupByParams["serverId"] = this.id.serverId;
        dbGroupByParams["serverName"] = this.id.serverName;
        dbGroupByParams["strStartTime"] = this.id.startTime;
        dbGroupByParams["strEndTime"] = this.id.endTime;
        dbGroupByParams["strGroup"] = 'url';
        dbGroupByParams["strOrderBy"] = '';
        dbGroupByParams["urlName"] = 'AllTransactions';
        // this.selectedGroupBy= ['url'] ;
        this.commonServices.dbGroupByFilters = dbGroupByParams;
        console.log("inside DBGroupByDefaultFilters --", this.commonServices.dbGroupByFilters);
        this.assignDBGroupByFilters();
    }
    // ********************************end of functions used for assigning default values to open report********************************************************************
    assignMethodTimingFilters() {
        let reportUI = {};
        let mtParams = this.commonServices.methodTimingFilters;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignMethodTimingFilters mtFilters before assigning values = ", mtParams);
        if (this.tierNameFC != 'default') {
            mtParams["tierName"] = this.tierNameFC.toString();
            mtParams["tierId"] = this.tierId.toString();
            reportUI['tierName'] = this.tierNameFC.toString();
            reportUI['tierId'] = this.tierId.toString();
            reportUI['checkedTier'] = this.selectedTier;
        }
        if (this.serverNameFC != 'default') {
            mtParams["serverName"] = this.serverNameFC;
            mtParams["serverId"] = this.serverId.toString();
            reportUI['serverName'] = this.serverNameFC.toString();
            reportUI['serverId'] = this.serverId.toString();
            reportUI['checkedServer'] = this.selectedServer;
            reportUI['ServerList'] = this.serverList;
        }
        if (this.appNameFC != 'default') {
            mtParams["appName"] = this.appNameFC;
            mtParams["appId"] = this.appId.toString();
            reportUI['appName'] = this.appNameFC.toString();
            reportUI['appId'] = this.appId.toString();
            reportUI['checkedApp'] = this.selectedApp;
            reportUI['AppList'] = this.appList;
        }
        if (this.selectedBuisnessTransaction != undefined) {
            if (this.selectedBuisnessTransaction.name !== undefined) {
                mtParams["urlName"] = this.selectedBuisnessTransaction.name;
                mtParams["urlIndex"] = this.selectedBuisnessTransaction.id;
                reportUI["urlName"] = this.selectedBuisnessTransaction.name;
                reportUI["urlIndex"] = this.selectedBuisnessTransaction.id;
            }
            else if (this.checkedBuisnessTransaction === false) //if someone uncheck BT Filter, pass NA (means remove that filter)
             {
                mtParams["urlName"] = 'NA';
                mtParams["urlIndex"] = 'NA';
            }
        }
        if (this.fpInstance !== null && this.fpInstance !== undefined) {
            mtParams["flowpathInstance"] = this.fpInstance;
            reportUI['FlowpathID'] = this.fpInstance;
        }
        if (this.strTime !== null && this.strTime !== undefined) {
            mtParams["strStartTime"] = this.strTime;
            reportUI['checkedTimeFIlter'] = this.timeFilter;
            reportUI['startTime'] = this.strTime;
            reportUI['selectedTime'] = this.selectedTime;
        }
        if (this.endTime !== null && this.endTime !== undefined) {
            mtParams["strEndTime"] = this.endTime;
            reportUI['EndTime'] = this.endTime;
        }
        if (this.selectedUrl != undefined && this.selectedUrl.name !== undefined) {
            mtParams["url"] = this.selectedUrl.name;
            mtParams["nsUrlIdx"] = this.selectedUrl.id;
        }
        else if (this.checkedUrl === false) {
            mtParams["url"] = 'NA';
            mtParams["nsUrlIdx"] = 'NA';
        }
        mtParams["page"] = this.page;
        if (this.selectedScript != undefined && this.selectedScript.name !== null && this.selectedScript.name !== undefined)
            mtParams["script"] = this.selectedScript.name;
        else if (this.checkedScript === false)
            mtParams["script"] = 'NA';
        if (this.selectedTransaction != undefined && this.selectedTransaction.name !== null && this.selectedTransaction.name !== undefined)
            mtParams["transaction"] = this.selectedTransaction.name;
        else if (this.checkedTransaction === false)
            mtParams["transaction"] = 'NA';
        if (this.selectedLocation != undefined && this.selectedLocation.name !== null && this.selectedLocation.name !== undefined)
            mtParams["location"] = this.selectedLocation.name;
        else if (this.checkedLocation === false)
            mtParams["location"] = 'NA';
        if (this.selectedBrowser != undefined && this.selectedBrowser.name !== null && this.selectedBrowser.name !== undefined)
            mtParams["access"] = this.selectedBrowser.name;
        else if (this.checkedBrowser === false)
            mtParams["access"] = 'NA';
        if (this.selectedAccess != undefined && this.selectedAccess.name !== null && this.selectedAccess.name !== undefined)
            mtParams["browser"] = this.selectedAccess.name;
        else if (this.checkedAccess === false)
            mtParams["browser"] = 'NA';
        if (this.selectedBTCategory != undefined) {
            mtParams["btCatagory"] = this.selectedBTCategory;
            reportUI["BtCategory"] = this.selectedBTCategory;
        }
        if (this.selectedTopNEntity != undefined && this.selectedTopNEntity !== null) {
            mtParams['topNEntities'] = this.selectedTopNEntity;
            reportUI['TopNEntities'] = this.selectedTopNEntity;
        }
        this.commonServices.methodTimingFilters = mtParams;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        if (this.isMultiDC && this.dcList.length != 0 && this.selectedDC != undefined) {
            mtParams['pubicIP'] = this.selectedDC.pubicIP;
            mtParams['publicPort'] = this.selectedDC.publicPort;
            mtParams['ndeTestRun'] = this.selectedDC.ndeTestRun;
            mtParams['ndeProtocol'] = this.selectedDC.ndeProtocol;
        }
        else {
            mtParams['pubicIP'] = '';
            mtParams['publicPort'] = '';
            mtParams['ndeTestRun'] = '';
            mtParams['ndeProtocol'] = '';
        }
        console.log(" method - assignMethodTimingFilters mtFilters after assigning values = ", mtParams);
    }
    assignIPSummaryFilters() {
        let ipSummaryParams = this.commonServices.ipSummaryFilters;
        let reportUI = {};
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignipSummaryFilters ipSummaryFilters before assigning values = ", ipSummaryParams);
        if (this.tierNameFC != 'default') {
            ipSummaryParams["tierName"] = this.tierNameFC.toString();
            ipSummaryParams["tierId"] = this.tierId.toString();
            reportUI['tierName'] = this.tierNameFC.toString();
            console.log("data in the tier before assigning..................", this.tierName);
            reportUI['tierId'] = this.tierId.toString();
            reportUI['checkedTier'] = this.selectedTier;
        }
        if (this.serverNameFC != 'default') {
            ipSummaryParams["serverName"] = this.serverNameFC;
            ipSummaryParams["serverId"] = this.serverId.toString();
            reportUI['serverName'] = this.serverNameFC.toString();
            reportUI['serverId'] = this.serverId.toString();
            reportUI['checkedServer'] = this.selectedServer;
            console.log("the value inside the sever ;lost is ..........", this.serverList);
            reportUI['ServerList'] = this.serverList;
        }
        if (this.appNameFC != 'default') {
            ipSummaryParams["appName"] = this.appNameFC;
            ipSummaryParams["appId"] = this.appId.toString();
            reportUI['appName'] = this.appNameFC.toString();
            reportUI['appId'] = this.appId.toString();
            reportUI['checkedApp'] = this.selectedApp;
            reportUI['AppList'] = this.appList;
        }
        if (this.fpInstance !== null && this.fpInstance !== undefined) {
            ipSummaryParams["flowpathID"] = this.fpInstance;
            reportUI['FlowpathID'] = this.fpInstance;
        }
        if (this.selectedBuisnessTransaction != undefined) {
            if (this.selectedBuisnessTransaction.name !== undefined) {
                ipSummaryParams["urlName"] = this.selectedBuisnessTransaction.name;
                ipSummaryParams["urlIndex"] = this.selectedBuisnessTransaction.id;
                reportUI["urlName"] = this.selectedBuisnessTransaction.name;
                reportUI["urlIndex"] = this.selectedBuisnessTransaction.id;
            }
            else if (this.checkedBuisnessTransaction === false) //if someone uncheck BT Filter, pass NA (means remove that filter)
             {
                ipSummaryParams["urlName"] = 'NA';
                ipSummaryParams["urlIndex"] = 'NA';
            }
        }
        if (this.selectedIntegrationPoint !== null && this.selectedIntegrationPoint != undefined && this.selectedIP == true && this.selectedIntegrationPoint.length != 0) {
            this.selectedIpName = [];
            for (let i = 0; i < this.selectedIntegrationPoint.length; i++) {
                let selectedIpname = this.selectedIntegrationPoint[i].name;
                if (this.selectedIpName.indexOf(selectedIpname) == -1) //for unique ids
                    this.selectedIpName.push(selectedIpname);
            }
            // console.log("this.selectedIntegrationPoint>>>>>",this.selectedIntegrationPoint);
            ipSummaryParams["integrationPointName"] = this.selectedIpName;
            reportUI['IntegrationPointName'] = this.selectedIpName;
        }
        else {
            ipSummaryParams["integrationPointName"] = 'NA'; // for uncheck integration point 
        }
        if (this.strTime !== null && this.strTime !== undefined) {
            ipSummaryParams["strStartTime"] = this.strTime;
            reportUI['checkedTimeFIlter'] = this.timeFilter;
            reportUI['startTime'] = this.strTime;
            reportUI['selectedTime'] = this.selectedTime;
        }
        if (this.endTime !== null && this.endTime !== undefined) {
            ipSummaryParams["strEndTime"] = this.endTime;
            reportUI['EndTime'] = this.endTime;
        }
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        if (this.isMultiDC && this.dcList.length != 0 && this.selectedDC != undefined) {
            ipSummaryParams['pubicIP'] = this.selectedDC.pubicIP;
            ipSummaryParams['publicPort'] = this.selectedDC.publicPort;
            ipSummaryParams['ndeTestRun'] = this.selectedDC.ndeTestRun;
            ipSummaryParams['ndeProtocol'] = this.selectedDC.ndeProtocol;
        }
        else {
            ipSummaryParams['pubicIP'] = '';
            ipSummaryParams['publicPort'] = '';
            ipSummaryParams['ndeTestRun'] = '';
            ipSummaryParams['ndeProtocol'] = '';
        }
        this.commonServices.ipSummaryFilters = ipSummaryParams;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignHotspotFilters hotspotFilters after assigning values = ", ipSummaryParams);
        console.log("value inside the nsCqMAutoFill in the ipsummary report is ...........", reportUI);
    }
    assignHotspotFilters() {
        let hsParams = this.commonServices.hotspotFilters;
        let reportUI = {};
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignHotspotFilters hotspotFilters before assigning values = ", hsParams);
        if (this.fpInstance !== null && this.fpInstance !== undefined) {
            hsParams["flowpathInstance"] = this.fpInstance;
            reportUI['FlowpathID'] = this.fpInstance;
        }
        if (this.tierNameFC != 'default') {
            hsParams["tierName"] = this.tierNameFC.toString();
            hsParams["tierId"] = this.tierId.toString();
            reportUI['tierName'] = this.tierNameFC.toString();
            console.log("data in the tier before assigning..................", this.tierName);
            reportUI['tierId'] = this.tierId.toString();
            reportUI['checkedTier'] = this.selectedTier;
        }
        if (this.serverNameFC != 'default') {
            hsParams["serverName"] = this.serverNameFC;
            hsParams["serverId"] = this.serverId.toString();
            reportUI['serverName'] = this.serverNameFC.toString();
            reportUI['serverId'] = this.serverId.toString();
            reportUI['checkedServer'] = this.selectedServer;
            console.log("the value inside the sever ;lost is ..........", this.serverList);
            reportUI['ServerList'] = this.serverList;
        }
        if (this.appNameFC != 'default') {
            hsParams["appName"] = this.appNameFC;
            hsParams["appId"] = this.appId.toString();
            reportUI['appName'] = this.appNameFC.toString();
            reportUI['appId'] = this.appId.toString();
            reportUI['checkedApp'] = this.selectedApp;
            reportUI['AppList'] = this.appList;
        }
        if (this.strTime !== null && this.strTime !== undefined) {
            hsParams["strStartTime"] = this.strTime;
            reportUI['checkedTimeFIlter'] = this.timeFilter;
            reportUI['startTime'] = this.strTime;
            reportUI['selectedTime'] = this.selectedTime;
        }
        if (this.endTime !== null && this.endTime !== undefined) {
            hsParams["strEndTime"] = this.endTime;
            reportUI['EndTime'] = this.endTime;
        }
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        if (this.isMultiDC && this.dcList.length != 0 && this.selectedDC != undefined) {
            hsParams['pubicIP'] = this.selectedDC.pubicIP;
            hsParams['publicPort'] = this.selectedDC.publicPort;
            hsParams['ndeTestRun'] = this.selectedDC.ndeTestRun;
            hsParams['ndeProtocol'] = this.selectedDC.ndeProtocol;
        }
        else {
            hsParams['pubicIP'] = '';
            hsParams['publicPort'] = '';
            hsParams['ndeTestRun'] = '';
            hsParams['ndeProtocol'] = '';
        }
        this.commonServices.hotspotFilters = hsParams;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignHotspotFilters hotspotFilters after assigning values = ", hsParams);
        console.log("Values inside the nsCQMAUTOFILL in hotspot is ", reportUI);
    }
    assignFlowpathFilters() {
        this.commonServices.isFromCQM = true;
        let reportUI = {};
        let fpParams = this.commonServices.fpFilters;
        console.log(" method - assignFlowpathFilters fpFilters before assigning values = ", fpParams);
        fpParams["templateName"] = "NA";
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        fpParams["isContainsNSFilters"] = false;
        fpParams["customData"] = "NA";
        if (this.fpInstance !== null && this.fpInstance !== undefined) {
            fpParams["flowpathID"] = this.fpInstance;
            reportUI['FlowpathID'] = this.fpInstance;
        }
        if (this.tierNameFC != 'default') {
            fpParams["tierName"] = this.tierNameFC.toString();
            fpParams["tierId"] = this.tierId.toString();
            reportUI['tierName'] = this.tierNameFC.toString();
            reportUI['tierId'] = this.tierId.toString();
            reportUI['checkedTier'] = this.selectedTier;
        }
        if (this.serverNameFC != 'default') {
            fpParams["serverName"] = this.serverNameFC;
            fpParams["serverId"] = this.serverId.toString();
            reportUI['serverName'] = this.serverNameFC.toString();
            reportUI['serverId'] = this.serverId.toString();
            reportUI['checkedServer'] = this.selectedServer;
            reportUI['ServerList'] = this.serverList;
        }
        if (this.appNameFC != 'default') {
            fpParams["appName"] = this.appNameFC;
            fpParams["appId"] = this.appId.toString();
            reportUI['appName'] = this.appNameFC.toString();
            reportUI['appId'] = this.appId.toString();
            reportUI['checkedApp'] = this.selectedApp;
            reportUI['AppList'] = this.appList;
        }
        if (this.strTime !== null && this.strTime !== undefined) {
            fpParams["strStartTime"] = this.strTime;
            reportUI['checkedTimeFIlter'] = this.timeFilter;
            reportUI['startTime'] = this.strTime;
            reportUI['selectedTime'] = this.selectedTime;
        }
        if (this.endTime !== null && this.endTime !== undefined) {
            fpParams["strEndTime"] = this.endTime;
            reportUI['EndTime'] = this.endTime;
        }
        if (this.gTagsStr !== null && this.gTagsStr !== undefined) {
            fpParams["tags"] = this.gTagsStr;
        }
        delete (this.gTagsStr);
        if (this.selectedTime == 'Custom Time') {
            if (this.commonServices.isValidParameter(this.strTimeInDateFormat) && this.commonServices.isValidParameter(this.endTimeInDateFormat)) {
                reportUI['customStartTime'] = this.strTimeInDateFormat;
                reportUI['customEndTime'] = this.endTimeInDateFormat;
            }
        }
        if (this.selectedFailureNameId != "" && this.selectedFailureNameId != undefined) {
            fpParams["statusCode"] = this.selectedFailureNameId;
            fpParams["statusCodeFC"] = this.selectedFailureName;
            reportUI['statusCode'] = this.selectedFailureNameId;
            reportUI["statusCodeFC"] = this.selectedFailureName;
        }
        else {
            fpParams["statusCode"] = "-2";
            fpParams["statusCodeFC"] = "";
        }
        //alert("this.selectedFailureNameId---"+ this.selectedFailureNameId + "this.selectedUrlStatus --" + this.selectedUrlStatus );
        if (this.strTime !== null && this.strTime !== undefined)
            fpParams["strStartTime"] = this.strTime;
        //selectedBuisnessTransaction = undefined (default value). If this variable has default value don't update 'urlName' and 'urlIndex'
        //selectedBuisnessTransaction = ""  (uncheck value)
        if (this.selectedBuisnessTransaction != undefined) {
            if (this.selectedBuisnessTransaction.name !== undefined) {
                fpParams["urlName"] = this.selectedBuisnessTransaction.name;
                fpParams["urlIndex"] = this.selectedBuisnessTransaction.id;
                reportUI["urlName"] = this.selectedBuisnessTransaction.name;
                reportUI["urlIndex"] = this.selectedBuisnessTransaction.id;
            }
            else if (this.checkedBuisnessTransaction === false) //if someone uncheck BT Filter, pass NA (means remove that filter)
             {
                fpParams["urlName"] = 'NA';
                fpParams["urlIndex"] = 'NA';
            }
        }
        if (this.selectedBTCategory != undefined) {
            fpParams["btCategory"] = this.selectedBTCategory;
            reportUI["BtCategory"] = this.selectedBTCategory;
        }
        // changes for filter in flowpath for Dynamic logging and request response
        console.log("dl flag value==", this.checkDLFlag, "***********Req and resp flag value", this.checkReqRespFlag);
        if (this.checkDLFlag != null && this.checkDLFlag != undefined) {
            fpParams["checkDLFlag"] = this.checkDLFlag;
            reportUI['checkDLFlag'] = this.checkDLFlag;
        }
        if (this.checkReqRespFlag != null && this.checkReqRespFlag != undefined) {
            fpParams["checkReqRespFlag"] = this.checkReqRespFlag;
            reportUI['checkReqRespFlag'] = this.checkReqRespFlag;
        }
        if (this.selectedCorrIdMode != null && this.selectedCorrIdMode != "" && this.selectedCorrIdMode != undefined) {
            fpParams["correlationId"] = encodeURIComponent(this.corrId);
            reportUI['CorrelationId'] = encodeURIComponent(this.corrId);
            fpParams["mode"] = this.selectedCorrIdMode;
            fpParams["corModeValue"] = this.selectedCorrIdMode;
            reportUI['Mode'] = this.selectedCorrIdMode;
            console.log("The value inside the reportUI['CorrelationId']", reportUI['CorrelationId']);
            console.log("The value inside the reportUI['Mode']", reportUI['Mode']);
        }
        if (this.minMethods != "" && this.minMethods != undefined) {
            fpParams["minMethods"] = this.minMethods;
            reportUI['MinMethods'] = this.minMethods;
        }
        fpParams["responseTime"] = this.responseTime1;
        console.log(" ", this.responseTime1);
        //reportUI['responseTime'] = this.responseTime1;
        if (this.responseTime != undefined && this.responseTime != '') {
            console.log("value insisde the response time is ", this.responseTime);
            fpParams["resptimeqmode"] = this.resSelectedCompareOption;
            reportUI['resptimeqmode'] = this.resSelectedCompareOption;
            reportUI['responseTime'] = this.responseTime;
        }
        else
            fpParams["resptimeqmode"] = '';
        fpParams['resptimevalue'] = this.getResponseTimeModeValue(fpParams["resptimeqmode"]);
        fpParams['resVariance'] = this.resVariance;
        reportUI['resVariance'] = this.resVariance;
        if (this.resSelectedCompareOption == '3' && (this.resVariance == undefined || this.resVariance == "")) {
            fpParams['responseTime2'] = this.responseTime1;
            //reportUI['responseTime2'] = this.responseTime1;
            console.log("Value inside the responseTime1 in equal case is ............//", this.responseTime1);
        }
        else {
            fpParams['responseTime2'] = this.responseTime2;
            //reportUI['responseTime2']  = this.responseTime2;
            console.log("Value inside the responseTime2 in not equal is ...........//", this.responseTime2);
        }
        if (this.selectedFpOrderBy != undefined && this.selectedFpOrderBy.length != 0) {
            fpParams["strOrderBy"] = this.selectedFpOrderBy;
            reportUI['StrOrderBy'] = this.selectedFpOrderBy;
            console.log("the value inside the order by for the flowpath ...............", reportUI['StrOrderBy']);
        }
        else if (this.fpOrderByCheck == false) {
            fpParams['strOrderBy'] = 'fpduration_desc';
        }
        if (this.selectedUrl != undefined && this.selectedUrl.name !== undefined) {
            fpParams["url"] = this.selectedUrl.name;
            fpParams["nsUrlIdx"] = this.selectedUrl.id;
        }
        else if (this.checkedUrl === false) {
            fpParams["url"] = 'NA';
            fpParams["nsUrlIdx"] = 'NA';
        }
        fpParams["page"] = this.page;
        if (this.page != "NA")
            fpParams["isContainsNSFilters"] = true;
        /*if (this.selectedPage != undefined && this.selectedPage.name !== null && this.selectedPage.name !== undefined)
        {
          fpParams["isContainsNSFilters"] = true;
          fpParams["page"] = this.selectedPage.name;
        }
        else if (this.checkedPage === false)
          fpParams["page"] = 'NA';
        */
        if (this.selectedScript != undefined && this.selectedScript.name !== null && this.selectedScript.name !== undefined) {
            fpParams["isContainsNSFilters"] = true;
            fpParams["script"] = this.selectedScript.name;
        }
        else if (this.checkedScript === false)
            fpParams["script"] = 'NA';
        if (this.selectedTransaction != undefined && this.selectedTransaction.name !== null && this.selectedTransaction.name !== undefined) {
            fpParams["isContainsNSFilters"] = true;
            fpParams["transaction"] = this.selectedTransaction.name;
        }
        else if (this.checkedTransaction === false)
            fpParams["transaction"] = 'NA';
        if (this.selectedLocation != undefined && this.selectedLocation.name !== null && this.selectedLocation.name !== undefined) {
            fpParams["isContainsNSFilters"] = true;
            fpParams["location"] = this.selectedLocation.name;
        }
        else if (this.checkedLocation === false)
            fpParams["location"] = 'NA';
        if (this.selectedBrowser != undefined && this.selectedBrowser.name !== null && this.selectedBrowser.name !== undefined) {
            fpParams["isContainsNSFilters"] = true;
            fpParams["access"] = this.selectedBrowser.name;
        }
        else if (this.checkedBrowser === false)
            fpParams["access"] = 'NA';
        if (this.selectedAccess != undefined && this.selectedAccess.name !== null && this.selectedAccess.name !== undefined) {
            fpParams["isContainsNSFilters"] = true;
            fpParams["browser"] = this.selectedAccess.name;
        }
        else if (this.checkedAccess === false)
            fpParams["browser"] = 'NA';
        if (this.ndSessionId != undefined)
            fpParams["ndSessionId"] = this.ndSessionId;
        if (this.nvPageId != undefined)
            fpParams["nvPageId"] = this.nvPageId;
        if (this.nvSessionId != undefined)
            fpParams["nvSessionId"] = this.nvSessionId;
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        if (this.isMultiDC && this.dcList.length != 0 && this.selectedDC != undefined) {
            fpParams['pubicIP'] = this.selectedDC.pubicIP;
            fpParams['publicPort'] = this.selectedDC.publicPort;
            fpParams['ndeTestRun'] = this.selectedDC.ndeTestRun;
            fpParams['ndeProtocol'] = this.selectedDC.ndeProtocol;
        }
        else {
            fpParams['pubicIP'] = '';
            fpParams['publicPort'] = '';
            fpParams['ndeTestRun'] = '';
            fpParams['ndeProtocol'] = '';
        }
        this.commonServices.fpFilters = fpParams;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        if (this._ddrData.isFromNV == "1") {
            this._ddrData.nvCqm = true;
        }
        console.log(" method - assignFlowpathFilters fpFilters after assigning values = ", fpParams);
    }
    assignFlowpathGroupByFilters() {
        this.getgroupByFC();
        this.getOrderByFC();
        let reportUI = {};
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        let fpGroupByParams = this.commonServices.fpGroupByFilters;
        fpGroupByParams["isContainsNSFilters"] = false;
        console.log(" method - assignFlowpathGroupByFilters fpGroupByParam before assigning values = ", fpGroupByParams);
        if (this.tierNameFC != 'default') {
            fpGroupByParams["tierName"] = this.tierNameFC.toString();
            fpGroupByParams["tierId"] = this.tierId.toString();
            reportUI['tierName'] = this.tierNameFC.toString();
            console.log("data in the tier before assigning..................", this.tierName);
            reportUI['tierId'] = this.tierId.toString();
            reportUI['checkedTier'] = this.selectedTier;
        }
        if (this.serverNameFC != 'default') {
            fpGroupByParams["serverName"] = this.serverNameFC;
            fpGroupByParams["serverId"] = this.serverId.toString();
            reportUI['serverName'] = this.serverNameFC;
            reportUI['serverId'] = this.serverId.toString();
            reportUI['checkedServer'] = this.selectedServer;
            console.log("the value inside the sever ;lost is ..........", this.serverList);
            reportUI['ServerList'] = this.serverList;
        }
        if (this.appNameFC != 'default') {
            fpGroupByParams["appName"] = this.appNameFC;
            fpGroupByParams["appId"] = this.appId.toString();
            reportUI['appName'] = this.appNameFC.toString();
            reportUI['appId'] = this.appId.toString();
            reportUI['checkedApp'] = this.selectedApp;
            reportUI['AppList'] = this.appList;
        }
        if (this.strTime !== null && this.strTime !== undefined) {
            fpGroupByParams["strStartTime"] = this.strTime;
            reportUI['checkedTimeFIlter'] = this.timeFilter;
            reportUI['startTime'] = this.strTime;
            reportUI['selectedTime'] = this.selectedTime;
        }
        if (this.endTime !== null && this.endTime !== undefined) {
            fpGroupByParams["strEndTime"] = this.endTime;
            reportUI['EndTime'] = this.endTime;
        }
        if (this.selectedGroupBy.length == 0) //uncheck case or default case
         {
            fpGroupByParams["strGroup"] = 'url';
            fpGroupByParams["groupByFC"] = 'BT';
        }
        else {
            fpGroupByParams["strGroup"] = this.selectedGroupBy;
            reportUI['Group'] = this.selectedGroupBy;
            fpGroupByParams["groupByFC"] = this.groupByFC.toString();
        }
        if (this.checkOrder == false) {
            fpGroupByParams["strOrder"] = '';
            fpGroupByParams["orderByFC"] = '';
        }
        if (this.selectedOrderBy !== null && this.selectedOrderBy !== undefined && this.selectedOrderBy.length != 0) {
            fpGroupByParams["strOrder"] = this.selectedOrderBy;
            fpGroupByParams["orderByFC"] = this.orderByFC.toString();
            reportUI['Order'] = this.selectedOrderBy;
        }
        if (this.selectedFailureNameId != "" && this.selectedFailureNameId != undefined) {
            fpGroupByParams["statusCode"] = this.selectedFailureNameId;
            fpGroupByParams["statusCodeFC"] = this.selectedFailureName;
        }
        else {
            fpGroupByParams["statusCode"] = "-2";
            fpGroupByParams["statusCodeFC"] = "";
        }
        if (this.selectedBuisnessTransaction != undefined) {
            if (this.selectedBuisnessTransaction.name !== undefined) {
                fpGroupByParams["urlName"] = this.selectedBuisnessTransaction.name;
                fpGroupByParams["urlIdx"] = this.selectedBuisnessTransaction.id;
                reportUI["urlName"] = this.selectedBuisnessTransaction.name;
                reportUI["urlIndex"] = this.selectedBuisnessTransaction.id;
            }
            else if (this.checkedBuisnessTransaction === false) //if someone uncheck BT Filter, pass NA (means remove that filter)
             {
                fpGroupByParams["urlName"] = 'NA';
                fpGroupByParams["urlIdx"] = 'NA';
            }
        }
        if (this.selectedBTCategory != undefined) {
            fpGroupByParams["btCategory"] = this.selectedBTCategory;
            reportUI["BtCategory"] = this.selectedBTCategory;
        }
        if (this.selectedUrl != undefined && this.selectedUrl.name !== undefined) {
            fpGroupByParams["url"] = this.selectedUrl.name;
            fpGroupByParams["nsUrlIdx"] = this.selectedUrl.id;
        }
        else if (this.checkedUrl === false) {
            fpGroupByParams["url"] = 'NA';
            fpGroupByParams["nsUrlIdx"] = 'NA';
        }
        fpGroupByParams["page"] = this.page;
        if (this.page != "NA")
            fpGroupByParams["isContainsNSFilters"] = true;
        if (this.selectedScript != undefined && this.selectedScript.name !== null && this.selectedScript.name !== undefined) {
            fpGroupByParams["isContainsNSFilters"] = true;
            fpGroupByParams["script"] = this.selectedScript.name;
        }
        else if (this.checkedScript === false)
            fpGroupByParams["script"] = 'NA';
        if (this.selectedTransaction != undefined && this.selectedTransaction.name !== null && this.selectedTransaction.name !== undefined) {
            fpGroupByParams["isContainsNSFilters"] = true;
            fpGroupByParams["transaction"] = this.selectedTransaction.name;
        }
        else if (this.checkedTransaction === false)
            fpGroupByParams["transaction"] = 'NA';
        if (this.selectedLocation != undefined && this.selectedLocation.name !== null && this.selectedLocation.name !== undefined) {
            fpGroupByParams["isContainsNSFilters"] = true;
            fpGroupByParams["location"] = this.selectedLocation.name;
        }
        else if (this.checkedLocation === false)
            fpGroupByParams["location"] = 'NA';
        if (this.selectedBrowser != undefined && this.selectedBrowser.name !== null && this.selectedBrowser.name !== undefined) {
            fpGroupByParams["isContainsNSFilters"] = true;
            fpGroupByParams["access"] = this.selectedBrowser.name;
        }
        else if (this.checkedBrowser === false)
            fpGroupByParams["access"] = 'NA';
        if (this.selectedAccess != undefined && this.selectedAccess.name !== null && this.selectedAccess.name !== undefined) {
            fpGroupByParams["isContainsNSFilters"] = true;
            fpGroupByParams["browser"] = this.selectedAccess.name;
        }
        else if (this.checkedAccess === false)
            fpGroupByParams["browser"] = 'NA';
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        if (this.isMultiDC && this.dcList.length != 0 && this.selectedDC != undefined) {
            fpGroupByParams['pubicIP'] = this.selectedDC.pubicIP;
            fpGroupByParams['publicPort'] = this.selectedDC.publicPort;
            fpGroupByParams['ndeTestRun'] = this.selectedDC.ndeTestRun;
            fpGroupByParams['ndeProtocol'] = this.selectedDC.ndeProtocol;
        }
        else {
            fpGroupByParams['pubicIP'] = '';
            fpGroupByParams['publicPort'] = '';
            fpGroupByParams['ndeTestRun'] = '';
            fpGroupByParams['ndeProtocol'] = '';
        }
        this.commonServices.fpGroupByFilters = fpGroupByParams;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignFlowpathGroupByFilters fpFilters after assigning values = ", fpGroupByParams);
    }
    assignDBGroupByFilters() {
        let reportUI = {};
        this.getgroupByFC();
        this.getOrderByFC();
        let dbGroupByParams = this.commonServices.dbGroupByFilters;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        dbGroupByParams["isContainsNSFilters"] = false;
        console.log(" method - --assignDBGroupByFilters dbGroupByParam before assigning values = ", dbGroupByParams);
        if (this.tierNameFC != 'default') {
            dbGroupByParams["tierName"] = this.tierNameFC.toString();
            dbGroupByParams["tierId"] = this.tierId.toString();
            reportUI['tierName'] = this.tierNameFC.toString();
            reportUI['tierId'] = this.tierId.toString();
            reportUI['checkedTier'] = this.selectedTier;
        }
        if (this.serverNameFC != 'default') {
            dbGroupByParams["serverName"] = this.serverNameFC;
            dbGroupByParams["serverId"] = this.serverId.toString();
            reportUI['serverName'] = this.serverNameFC.toString();
            reportUI['serverId'] = this.serverId.toString();
            reportUI['checkedServer'] = this.selectedServer;
            reportUI['ServerList'] = this.serverList;
        }
        if (this.appNameFC != 'default') {
            dbGroupByParams["appName"] = this.appNameFC;
            dbGroupByParams["appId"] = this.appId.toString();
            reportUI['appName'] = this.appNameFC.toString();
            reportUI['appId'] = this.appId.toString();
            reportUI['checkedApp'] = this.selectedApp;
            reportUI['AppList'] = this.appList;
        }
        if (this.strTime !== null && this.strTime !== undefined) {
            dbGroupByParams["strStartTime"] = this.strTime;
            reportUI['checkedTimeFIlter'] = this.timeFilter;
            reportUI['startTime'] = this.strTime;
            reportUI['selectedTime'] = this.selectedTime;
        }
        if (this.endTime !== null && this.endTime !== undefined) {
            dbGroupByParams["strEndTime"] = this.endTime;
            reportUI['EndTime'] = this.endTime;
        }
        console.log("this.selectedGroupBy.length--", this.selectedGroupBy.length);
        if (this.selectedGroupBy.length == 0) //uncheck case or default case
         {
            dbGroupByParams["strGroup"] = 'url';
            dbGroupByParams["groupByFC"] = 'BT';
        }
        else {
            dbGroupByParams["strGroup"] = this.selectedGroupBy;
            reportUI['Group'] = this.selectedGroupBy;
            dbGroupByParams["groupByFC"] = this.groupByFC.toString();
        }
        if (this.selectedOrderBy.length == 0) //uncheck case or default case
         {
            dbGroupByParams["strOrderBy"] = '';
            dbGroupByParams["orderByFC"] = '';
        }
        else {
            dbGroupByParams["strOrderBy"] = this.selectedOrderBy;
            dbGroupByParams["orderByFC"] = this.orderByFC.toString();
            reportUI['Order'] = this.selectedOrderBy;
        }
        if (this.selectedFailureNameId != "" && this.selectedFailureNameId != undefined) {
            dbGroupByParams["statusCode"] = this.selectedFailureNameId;
            dbGroupByParams["statusCodeFC"] = this.selectedFailureName;
        }
        else {
            dbGroupByParams["statusCode"] = "-2";
            dbGroupByParams["statusCodeFC"] = "";
        }
        if (this.selectedBuisnessTransaction != undefined) {
            if (this.selectedBuisnessTransaction.name !== undefined) {
                dbGroupByParams["urlName"] = this.selectedBuisnessTransaction.name;
                dbGroupByParams["urlIndex"] = this.selectedBuisnessTransaction.id;
                reportUI["urlName"] = this.selectedBuisnessTransaction.name;
                reportUI["urlIndex"] = this.selectedBuisnessTransaction.id;
            }
            else if (this.checkedBuisnessTransaction === false) //if someone uncheck BT Filter, pass NA (means remove that filter)
             {
                dbGroupByParams["urlName"] = 'NA';
                dbGroupByParams["urlIndex"] = 'NA';
            }
        }
        if (this.selectedBTCategory != undefined) {
            dbGroupByParams["btcategoryId"] = this.selectedBTCategory;
            reportUI["BtCategory"] = this.selectedBTCategory;
        }
        if (this.selectedUrl != undefined && this.selectedUrl.name !== undefined) {
            dbGroupByParams["url"] = this.selectedUrl.name;
            dbGroupByParams["nsUrlIdx"] = this.selectedUrl.id;
        }
        else if (this.checkedUrl === false) {
            dbGroupByParams["url"] = 'NA';
            dbGroupByParams["nsUrlIdx"] = 'NA';
        }
        dbGroupByParams["page"] = this.page;
        if (this.page != "NA")
            dbGroupByParams["isContainsNSFilters"] = true;
        if (this.selectedScript != undefined && this.selectedScript.name !== null && this.selectedScript.name !== undefined) {
            dbGroupByParams["isContainsNSFilters"] = true;
            dbGroupByParams["script"] = this.selectedScript.name;
        }
        else if (this.checkedScript === false)
            dbGroupByParams["script"] = 'NA';
        if (this.selectedTransaction != undefined && this.selectedTransaction.name !== null && this.selectedTransaction.name !== undefined) {
            dbGroupByParams["isContainsNSFilters"] = true;
            dbGroupByParams["transaction"] = this.selectedTransaction.name;
        }
        else if (this.checkedTransaction === false)
            dbGroupByParams["transaction"] = 'NA';
        if (this.selectedLocation != undefined && this.selectedLocation.name !== null && this.selectedLocation.name !== undefined) {
            dbGroupByParams["isContainsNSFilters"] = true;
            dbGroupByParams["location"] = this.selectedLocation.name;
        }
        else if (this.checkedLocation === false)
            dbGroupByParams["location"] = 'NA';
        if (this.selectedBrowser != undefined && this.selectedBrowser.name !== null && this.selectedBrowser.name !== undefined) {
            dbGroupByParams["isContainsNSFilters"] = true;
            dbGroupByParams["access"] = this.selectedBrowser.name;
        }
        else if (this.checkedBrowser === false)
            dbGroupByParams["access"] = 'NA';
        if (this.selectedAccess != undefined && this.selectedAccess.name !== null && this.selectedAccess.name !== undefined) {
            dbGroupByParams["isContainsNSFilters"] = true;
            dbGroupByParams["browser"] = this.selectedAccess.name;
        }
        else if (this.checkedAccess === false)
            dbGroupByParams["browser"] = 'NA';
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        if (this.isMultiDC && this.dcList.length != 0 && this.selectedDC != undefined) {
            dbGroupByParams['pubicIP'] = this.selectedDC.pubicIP;
            dbGroupByParams['publicPort'] = this.selectedDC.publicPort;
            dbGroupByParams['ndeTestRun'] = this.selectedDC.ndeTestRun;
            dbGroupByParams['ndeProtocol'] = this.selectedDC.ndeProtocol;
        }
        else {
            dbGroupByParams['pubicIP'] = '';
            dbGroupByParams['publicPort'] = '';
            dbGroupByParams['ndeTestRun'] = '';
            dbGroupByParams['ndeProtocol'] = '';
        }
        this.commonServices.dbGroupByFilters = dbGroupByParams;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assigndbGroupByFilters fpFilters after assigning values = ", dbGroupByParams);
    }
    assignExceptionFilters() {
        let reportUI = {};
        this.getgroupByFC();
        this.getOrderByFC();
        let exceptionParams = this.commonServices.exceptionFilters;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignExceptionFilters exceptionFilters before assigning values = ", exceptionParams);
        if (this.tierNameFC != 'default') {
            exceptionParams["tierName"] = this.tierNameFC.toString();
            exceptionParams["tierid"] = this.tierId.toString();
            reportUI['tierName'] = this.tierNameFC.toString();
            console.log("data in the tier before assigning..................", this.tierName);
            reportUI['tierId'] = this.tierId.toString();
            reportUI['checkedTier'] = this.selectedTier;
        }
        if (this.serverNameFC != 'default') {
            exceptionParams["serverName"] = this.serverNameFC;
            exceptionParams["serverid"] = this.serverId.toString();
            reportUI['serverName'] = this.serverNameFC.toString();
            reportUI['serverId'] = this.serverId.toString();
            reportUI['checkedServer'] = this.selectedServer;
            console.log("the value inside the sever ;lost is ..........", this.serverList);
            reportUI['ServerList'] = this.serverList;
        }
        if (this.appNameFC != 'default') {
            exceptionParams["appName"] = this.appNameFC;
            exceptionParams["appid"] = this.appId.toString();
            reportUI['appName'] = this.appNameFC.toString();
            reportUI['appId'] = this.appId.toString();
            reportUI['checkedApp'] = this.selectedApp;
            reportUI['AppList'] = this.appList;
        }
        // exceptionParams["flowPathInstance"] = 
        if (this.strTime !== null && this.strTime !== undefined) {
            exceptionParams["strStartTime"] = this.strTime;
            reportUI['checkedTimeFIlter'] = this.timeFilter;
            reportUI['startTime'] = this.strTime;
            reportUI['selectedTime'] = this.selectedTime;
        }
        if (this.endTime !== null && this.endTime !== undefined) {
            exceptionParams["strEndTime"] = this.endTime;
            reportUI['EndTime'] = this.endTime;
        }
        if (this.selectedFailureNameId != "" && this.selectedFailureNameId != undefined) {
            exceptionParams["statusCode"] = this.selectedFailureNameId;
            exceptionParams["statusCodeFC"] = this.selectedFailureName;
        }
        else {
            exceptionParams["statusCode"] = "-2";
            exceptionParams["statusCodeFC"] = "";
        }
        if (this.selectedUrl != undefined && this.selectedUrl.name !== undefined) {
            exceptionParams["url"] = this.selectedUrl.name;
            exceptionParams["nsUrlIdx"] = this.selectedUrl.id;
        }
        else if (this.checkedUrl === false) {
            exceptionParams["url"] = 'NA';
            exceptionParams["nsUrlIdx"] = 'NA';
        }
        exceptionParams["page"] = this.page;
        if (this.selectedScript != undefined && this.selectedScript.name !== null && this.selectedScript.name !== undefined)
            exceptionParams["script"] = this.selectedScript.name;
        else if (this.checkedScript === false)
            exceptionParams["script"] = 'NA';
        if (this.selectedTransaction != undefined && this.selectedTransaction.name !== null && this.selectedTransaction.name !== undefined)
            exceptionParams["transaction"] = this.selectedTransaction.name;
        else if (this.checkedTransaction === false)
            exceptionParams["transaction"] = 'NA';
        if (this.selectedLocation != undefined && this.selectedLocation.name !== null && this.selectedLocation.name !== undefined)
            exceptionParams["location"] = this.selectedLocation.name;
        else if (this.checkedLocation === false)
            exceptionParams["location"] = 'NA';
        if (this.selectedBrowser != undefined && this.selectedBrowser.name !== null && this.selectedBrowser.name !== undefined)
            exceptionParams["access"] = this.selectedBrowser.name;
        else if (this.checkedBrowser === false)
            exceptionParams["access"] = 'NA';
        if (this.selectedAccess != undefined && this.selectedAccess.name !== null && this.selectedAccess.name !== undefined)
            exceptionParams["browser"] = this.selectedAccess.name;
        else if (this.checkedAccess === false)
            exceptionParams["browser"] = 'NA';
        if (this.selectedException != undefined && this.selectedException.id !== null && this.selectedException.id !== undefined) {
            exceptionParams["excClassId"] = this.selectedException.id;
            exceptionParams["excClassIdFC"] = this.selectedException.name;
            reportUI['ExcclassIdFC'] = this.selectedException.name;
            reportUI['ExcClassId'] = this.selectedException.id;
        }
        else if (this.selectedExceptionClass === false) {
            exceptionParams["excClassId"] = 'NA';
            exceptionParams["excClassIdFC"] = 'NA';
        }
        if (this.selectedExceptionThrowingClass != undefined && this.selectedExceptionThrowingClass.id !== null && this.selectedExceptionThrowingClass.id !== undefined) {
            exceptionParams["excThrowingClassId"] = this.selectedExceptionThrowingClass.id;
            exceptionParams["excThrowingClassIdFC"] = this.selectedExceptionThrowingClass.name;
            reportUI['ExcThrowingClassIdFC'] = this.selectedExceptionThrowingClass.name;
            reportUI['ExcThrowingClassId'] = this.selectedExceptionThrowingClass.id;
        }
        else if (this.selectedThrowingClass === false) {
            exceptionParams["excThrowingClassId"] = 'NA';
            exceptionParams["excThrowingClassIdFC"] = 'NA';
        }
        if (this.selectedExceptionThrowingMethod != undefined && this.selectedExceptionThrowingMethod.id !== null && this.selectedExceptionThrowingMethod.id !== undefined) {
            exceptionParams["excThrowingMethodId"] = this.selectedExceptionThrowingMethod.id;
            exceptionParams["excThrowingMethodIdFC"] = this.selectedExceptionThrowingMethod.name;
            reportUI['ExcThrowingMethodIdFC'] = this.selectedExceptionThrowingMethod.name;
            reportUI['ExcThrowingMethodId'] = this.selectedExceptionThrowingMethod.id;
        }
        else if (this.selectedThrowingMethod === false) {
            exceptionParams["excThrowingMethodId"] = 'NA';
            exceptionParams["excThrowingMethodIdFC"] = 'NA';
        }
        if (this.selectedStack != undefined && this.selectedStack !== null) {
            exceptionParams["excStackTraceName"] = this.selectedStack;
            reportUI['ExcStackTraceName'] = this.selectedStack;
        }
        else if (this.selectedStackTrace === false) {
            exceptionParams["excStackTraceName"] = '';
        }
        if (this.selectedExceptionCauseType != undefined && this.selectedExceptionCauseType.id !== null && this.selectedExceptionCauseType.id !== undefined) {
            exceptionParams["excCauseId"] = this.selectedExceptionCauseType.id;
            exceptionParams["excCauseIdFC"] = this.selectedExceptionCauseType.name;
            reportUI["ExcCauseIdFC"] = this.selectedExceptionCauseType.name;
            reportUI['ExcCauseId'] = this.selectedExceptionCauseType.id;
        }
        else if (this.selectedExceptionCause === false) {
            exceptionParams["excCauseId"] = 'NA';
            exceptionParams["excCauseIdFC"] = 'NA';
        }
        if (this.selectedExceptionMessageType != undefined && this.selectedExceptionMessageType.id !== null && this.selectedExceptionMessageType.id !== undefined) {
            exceptionParams["excMsgId"] = this.selectedExceptionMessageType.id;
            exceptionParams["excMsgIdFC"] = this.selectedExceptionMessageType.name;
            reportUI["ExcMsgIdFC"] = this.selectedExceptionMessageType.name;
            reportUI['ExcMsgId'] = this.selectedExceptionMessageType.id;
        }
        else if (this.selectedExceptionMessage === false) {
            exceptionParams["excMsgId"] = 'NA';
            exceptionParams["excMsgIdFC"] = 'NA';
        }
        if (this.selectedGroupBy.length == 0) //uncheck case or default case
         {
            exceptionParams["groupby"] = 'excclass';
            exceptionParams["groupByFC"] = 'Exception Class';
        }
        else {
            exceptionParams["groupby"] = this.selectedGroupBy;
            exceptionParams["groupByFC"] = this.groupByFC.toString();
            reportUI['Group'] = this.selectedGroupBy;
        }
        if (this.checkOrder == false) {
            exceptionParams["orderby"] = '';
            exceptionParams["orderByFC"] = '';
        }
        if (this.selectedOrderBy !== null && this.selectedOrderBy !== undefined && this.selectedOrderBy.length != 0) {
            exceptionParams["orderby"] = this.selectedOrderBy;
            exceptionParams["orderByFC"] = this.orderByFC.toString();
            reportUI['Order'] = this.selectedOrderBy;
        }
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        if (this.isMultiDC && this.dcList.length != 0 && this.selectedDC != undefined) {
            exceptionParams['pubicIP'] = this.selectedDC.pubicIP;
            exceptionParams['publicPort'] = this.selectedDC.publicPort;
            exceptionParams['ndeTestRun'] = this.selectedDC.ndeTestRun;
            exceptionParams['ndeProtocol'] = this.selectedDC.ndeProtocol;
        }
        else {
            exceptionParams['pubicIP'] = '';
            exceptionParams['publicPort'] = '';
            exceptionParams['ndeTestRun'] = '';
            exceptionParams['ndeProtocol'] = '';
        }
        console.log(" method - assignExceptionFilters fpFilters after assigning values = ", exceptionParams);
        this.commonServices.exceptionFilters = exceptionParams;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
    }
    assignDBFilters() {
        var _a;
        this.commonServices.isFromCQM = true;
        let reportUI = {};
        let dbParams = this.commonServices.dbFilters;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignDBFilters dbFilters before assigning values = ", dbParams);
        if (this.tierNameFC != 'default') {
            dbParams["tierName"] = this.tierNameFC.toString();
            dbParams["tierId"] = this.tierId.toString();
            reportUI['tierName'] = this.tierNameFC.toString();
            reportUI['tierId'] = this.tierId.toString();
            reportUI['checkedTier'] = this.selectedTier;
        }
        if (this.serverNameFC != 'default') {
            dbParams["serverName"] = this.serverNameFC;
            dbParams["serverId"] = this.serverId.toString();
            reportUI['serverName'] = this.serverNameFC.toString();
            reportUI['serverId'] = this.serverId.toString();
            reportUI['checkedServer'] = this.selectedServer;
            reportUI['ServerList'] = this.serverList;
        }
        if (this.appNameFC != 'default') {
            dbParams["appName"] = this.appNameFC;
            dbParams["appId"] = this.appId.toString();
            reportUI['appName'] = this.appNameFC.toString();
            reportUI['appId'] = this.appId.toString();
            reportUI['checkedApp'] = this.selectedApp;
            reportUI['AppList'] = this.appList;
        }
        dbParams["flowpathInstance"] = this.fpInstance;
        reportUI['FlowpathID'] = this.fpInstance;
        //No need as in query ,by default group is tier server instance and  query will apply
        //  if((this.fpInstance == "" ||  this.fpInstance == undefined) && !this.commonServices.isValidParamInObj(dbParams, "strGroup") )
        //    dbParams["strGroup"] ='tier';
        if (this.selectedBuisnessTransaction != undefined) {
            if (this.selectedBuisnessTransaction.name !== undefined) {
                dbParams["urlName"] = this.selectedBuisnessTransaction.name;
                dbParams["urlIdx"] = this.selectedBuisnessTransaction.id;
                reportUI["urlName"] = this.selectedBuisnessTransaction.name;
                reportUI["urlIndex"] = this.selectedBuisnessTransaction.id;
            }
            else if (this.checkedBuisnessTransaction === false) //if someone uncheck BT Filter, pass NA (means remove that filter)
             {
                dbParams["urlName"] = 'NA';
                dbParams["urlIdx"] = 'NA';
            }
        }
        if (this.selectedBTCategory != undefined) {
            dbParams["btcategoryId"] = this.selectedBTCategory;
            reportUI["BtCategory"] = this.selectedBTCategory;
        }
        if (this.strTime !== null && this.strTime !== undefined) {
            dbParams["strStartTime"] = this.strTime;
            reportUI['checkedTimeFIlter'] = this.timeFilter;
            reportUI['startTime'] = this.strTime;
            reportUI['selectedTime'] = this.selectedTime;
        }
        if (this.endTime !== null && this.endTime !== undefined) {
            dbParams["strEndTime"] = this.endTime;
            reportUI['EndTime'] = this.endTime;
        }
        if (this.selectedUrl != undefined && this.selectedUrl.name !== undefined) {
            dbParams["url"] = this.selectedUrl.name;
            dbParams["nsUrlIdx"] = this.selectedUrl.id;
        }
        else if (this.checkedUrl === false) {
            dbParams["url"] = 'NA';
            dbParams["nsUrlIdx"] = 'NA';
        }
        dbParams["page"] = this.page;
        if (this.selectedScript != undefined && this.selectedScript.name !== null && this.selectedScript.name !== undefined)
            dbParams["script"] = this.selectedScript.name;
        else if (this.checkedScript === false)
            dbParams["script"] = 'NA';
        if (this.selectedTransaction != undefined && this.selectedTransaction.name !== null && this.selectedTransaction.name !== undefined)
            dbParams["transaction"] = this.selectedTransaction.name;
        else if (this.checkedTransaction === false)
            dbParams["transaction"] = 'NA';
        if (this.selectedLocation != undefined && this.selectedLocation.name !== null && this.selectedLocation.name !== undefined)
            dbParams["location"] = this.selectedLocation.name;
        else if (this.checkedLocation === false)
            dbParams["location"] = 'NA';
        if (this.selectedBrowser != undefined && this.selectedBrowser.name !== null && this.selectedBrowser.name !== undefined)
            dbParams["browser"] = this.selectedBrowser.name;
        else if (this.checkedBrowser === false)
            dbParams["browser"] = 'NA';
        if (this.selectedAccess != undefined && this.selectedAccess.name !== null && this.selectedAccess.name !== undefined)
            dbParams["access"] = this.selectedAccess.name;
        else if (this.checkedAccess === false)
            dbParams["access"] = 'NA';
        if (this.selectedTopNQuery != undefined && this.selectedTopNQuery !== null) {
            dbParams['topNQueries'] = this.selectedTopNQuery;
            reportUI['TopNQueries'] = this.selectedTopNQuery;
            console.log("The value of the topNqueries inside the db report is", this.selectedTopNQuery);
        }
        if (this.selectedDbOrderBy != undefined && this.selectedDbOrderBy.length != 0) {
            dbParams['strOrderBy'] = this.selectedDbOrderBy;
            reportUI['DBOrderBy'] = this.selectedDbOrderBy;
        }
        else if (((_a = this.selectedDbOrderBy) === null || _a === void 0 ? void 0 : _a.length) == 0)
            dbParams['strOrderBy'] = 'exec_time_desc';
        console.log("this.dcList--", this.dcList);
        console.log("this.dcList--", this.dcList);
        console.log("this.selectedDC--", this.selectedDC);
        if (this.isMultiDC && this.dcList.length != 0 && this.selectedDC != undefined) {
            dbParams['pubicIP'] = this.selectedDC.pubicIP;
            dbParams['publicPort'] = this.selectedDC.publicPort;
            dbParams['ndeTestRun'] = this.selectedDC.ndeTestRun;
            dbParams['ndeProtocol'] = this.selectedDC.ndeProtocol;
        }
        else {
            dbParams['pubicIP'] = '';
            dbParams['publicPort'] = '';
            dbParams['ndeTestRun'] = '';
            dbParams['ndeProtocol'] = '';
        }
        this.commonServices.dbFilters = dbParams;
        this._ddrData.nsCqmAutoFill[this.commonServices.currentReport] = reportUI;
        console.log(" method - assignDBFilters dbFilters after assigning values = ", dbParams);
    }
    next() {
        this.btOffset += this.btLimit;
        if ((this.btLimit + this.btOffset) >= this.btCount) {
            this.nxt = false;
            this.prev = true;
            this.btEndValue = this.btCount;
        }
        else {
            this.nxt = true;
            this.prev = true;
            this.btEndValue = this.btLimit + this.btOffset;
        }
        this.fetchMetadata('businessTransaction');
    }
    previous() {
        this.btOffset -= this.btLimit;
        if (this.btOffset <= 0) {
            this.prev = false;
            this.nxt = true;
            this.btEndValue = this.btLimit;
        }
        else {
            this.prev = true;
            this.nxt = true;
            this.btEndValue = this.btLimit + this.btOffset;
        }
        this.fetchMetadata('businessTransaction');
    }
    enableOrderBy() {
        if (this.showNSFilter)
            return false;
        else {
            if (this.checkGroup == true && this.selectedGroupBy.length > 0)
                return false;
        }
    }
    enableGroupBy() {
        if (this.commonServices.currentReport == "Transaction Instance" || this.commonServices.currentReport == "Session Instance"
            || this.commonServices.currentReport == "Page Instance" || this.commonServices.currentReport == "URL Instance") {
            return true;
        }
        else
            return false;
    }
    enableScript() {
        if (this.commonServices.currentReport == "URL Summary" || this.commonServices.currentReport == "Transaction Summary" || this.commonServices.currentReport == "Page Summary" || this.commonServices.currentReport == "Session Summary") {
            return true;
        }
        else
            return false;
    }
    validateTransactionCheck() {
        this.selectTransactionCheckBoxFlag = false;
        if (this.checkedTransaction) {
            this.fetchMetadata('transaction');
        }
        else {
            this.transLimit = 8;
            this.transOffset = 0;
            this.showTransactionPagination = false;
            this.selectedTransaction = {};
        }
    }
    validateScriptCheck(change) {
        this.selectScriptCheckBoxFlag = false;
        this.selectPageCheckBoxFlag = false;
        this.selectUrlCheckBoxFlag = false;
        if (this.checkedScript || change) // will work if the value has been changed or chekc box got selected 
         { // also if the value or script is changed unselect the page and url
            this.scriptGroup = true;
            this.checkedUrl = false;
            this.checkedPage = false;
            this.selectPageCheckBoxFlag = false;
            this.selectUrlCheckBoxFlag = false;
            this.fetchMetadata('script');
            //adds group by session 
            if (this.checkedScript /*&& this.selectedScript*/ && this.commonServices.currentReport.indexOf("Instance") == -1) // in case user
             {
                console.log("inside group ***");
                this.scriptGroup = true;
                this.getGroupBy();
                if (this.groupByFilter.indexOf("session") == -1) //i.e push once only
                    this.groupByFilter.push("session");
            }
        }
        else {
            this.groupByFilter = []; //group array  directly setting it false cz it will unselect page filter therfore removing every elemet from array.
            this.scriptGroup = false; // setting group by option false in case if user havennt selected anyother value in group by.
            // for unselecting everything in case script filer has been unselcted
            this.selectedScript = {};
            this.checkedUrl = false;
            this.checkedPage = false;
            this.selectedUrl = {};
            this.selectedPage = undefined;
        }
    }
    validatePageCheck(change) {
        this.selectPageCheckBoxFlag = false;
        this.selectUrlCheckBoxFlag = false;
        // if value of page has been changed unselect the value of page.
        if (this.checkedPage || change) {
            this.scriptGroup = true;
            this.checkedUrl = false;
            this.selectedUrl = {};
            this.fetchMetadata('page');
            this.selectUrlCheckBoxFlag = false;
            if (this.groupByFilter.indexOf("session") == -1 && this.commonServices.currentReport.indexOf("Instance") == -1)
                this.groupByFilter.push("page"); //incase page was selected but script was not
        }
        else {
            this.selectedPage = undefined; // made undefined cz of a condition in apply filter method confilcting in case i set ={}
            if (this.scriptGroup) {
                if (this.checkedScript == false && this.checkedPage == false) {
                    this.groupByFilter = [];
                }
                else if (this.checkedPage == false) //page has been unselcted
                 {
                    this.groupByFilter = this.groupByFilter.filter(val => { return val != "page"; }); //removes page from array.
                }
            }
            // on apply button a fucntion callled applyComonParam || apylURLFilter is called and there we will merge this group filter array and the actual group UI filter array and if user has selcted session in UI 
            //and script filter was selcted then it means new merged array will have 2 session value there we will filter array once more to get all the unique value.
            this.showPagePagination = false;
            this.pageLimit = 8;
            this.pageOffset = 0;
        }
        console.log("validate page********");
    }
    validateUrlCheck() {
        this.selectUrlCheckBoxFlag = false;
        if (this.checkedUrl) {
            if (this.checkedPage && this.checkedScript)
                this.getUrlInfo(this.selectedPage, this.selectedScript); //inscase page and script were selcted before going to slect url.
            else if (this.checkedScript) {
                this.getUrlInfo(undefined, this.selectedScript); // inscase only script was selcted
            }
            else if (this.checkedPage) {
                this.getUrlInfo(this.selectedPage, undefined);
            }
            else
                this.getUrlInfo();
        }
        else {
            this.urlLimit = 8;
            this.urlOffset = 0;
            this.urlEndValue = 0;
            this.showUrlPagination = false;
            this.selectedUrl = {};
        }
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.commonServices.isToLoadSideBar = false;
        if (this.nsAutoFillSubscribe$ && !this.nsAutoFillSubscribe$.closed) {
            this.nsAutoFillSubscribe$.unsubscribe();
        }
        if (this.commonServices.currentReport == "Transaction Instance" || this.commonServices.currentReport == "Transaction Summary"
            || this.commonServices.currentReport == "Page Summary" || this.commonServices.currentReport == "Page Instance" || this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Session Instance"
            || this.commonServices.currentReport == "URL Summary" || this.commonServices.currentReport == "URL Instance" || this.commonServices.currentReport == "Flowpath" || this.commonServices.currentReport == "FlowpathGroupBy" || this.commonServices.currentReport == "DB Report" || this.commonServices.currentReport == "DBGroupBy" || this.commonServices.currentReport == "Exception" || this.commonServices.currentReport == "Method Timing" || this.commonServices.currentReport == "Hotspot" || this.commonServices.currentReport == "IP Summary") {
            this.Reset(true, 'ngOnDestroy');
        }
    }
    saveQuery() {
        let autoFill = {};
        let pattern = /^[a-zA-Z][a-zA-Z0-9]*$/;
        if (this.queryName == '') {
            this.showQueryError = false;
            console.error("enter query Name");
            this.showSaveError = true;
        }
        else if (!this.queryName.match(pattern)) {
            this.showSaveError = false;
            console.error("Please enter valid parameter name");
            this.showQueryError = true;
        }
        else {
            let msg = 'Query saved for ' + this.commonServices.currentReport + ' Report Successfully';
            this._ddrData.setInLogger('DDR::CQM_SaveQuery', this.commonServices.currentReport, 'CQM_Save_Query', msg);
            this._ddrData.saveMessage = this.queryName;
            if (this.commonServices.currentReport == "Transaction Summary") {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.nsTransactionSummary, autoFill);
            }
            if (this.commonServices.currentReport == "Session Summary") {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.nsSessionSummary, autoFill);
            }
            if (this.commonServices.currentReport == "URL Summary") {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.nsURLSummary, autoFill);
            }
            if (this.commonServices.currentReport == "Page Summary") {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.nsPageSummary, autoFill);
            }
            if (this.commonServices.currentReport == 'DB Report') {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.dbFilters, autoFill);
            }
            if (this.commonServices.currentReport == 'DBGroupBy') {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.dbGroupByFilters, autoFill);
            }
            if (this.commonServices.currentReport == 'Exception') {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.exceptionFilters, autoFill);
            }
            if (this.commonServices.currentReport == 'Method Timing') {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.methodTimingFilters, autoFill);
            }
            if (this.commonServices.currentReport == 'Hotspot') {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.hotspotFilters, autoFill);
            }
            if (this.commonServices.currentReport == 'IP Summary') {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.ipSummaryFilters, autoFill);
            }
            if (this.commonServices.currentReport == "FlowpathGroupBy") {
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.fpGroupByFilters, autoFill);
            }
            if (this.commonServices.currentReport == "Flowpath") {
                console.log("Data in the fpFilters ................", this.commonServices.fpFilters);
                autoFill = this._ddrData.nsCqmAutoFill[this.commonServices.currentReport];
                console.log("Data in autoFill...............", autoFill);
                this.saveUserDefinedQueries(this.queryName, this.urlParam.testRun, this.addDescription, this.commonServices.fpFilters, autoFill);
            }
            this.commonServices.closeUISideBar$.next();
            this.dataChangeDetected.emit();
            this.showSaveError = false;
            this.showQueryError = false;
        }
        this.queryName = '';
        this.addDescription = '';
    }
    saveUserDefinedQueries(queryName, testRun, description, data, autoFill) {
        if (this._ddrData.editQuery == false) {
            if (this.confirmUniqeQuery(queryName)) //incase same query name exist
             {
                this._ddrData.sendMessage$.next("Query Already Defined");
                return;
            }
        }
        if (description.includes("|") || queryName.includes("|")) {
            this._ddrData.sendMessage$.next("Please Remove '|' from description");
        }
        else {
            let product = sessionStorage.getItem('productType');
            if (product)
                product = product.toLowerCase();
            console.log('&openReport=  ', this.commonServices.currentReport);
            let currReport = this.commonServices.currentReport;
            let userName = "";
            if (localStorage['userName'])
                userName = localStorage['userName'];
            else
                userName = sessionStorage['sesLoginName'];
            let url = this.getHostUrl() + '/' + product + '/v1/cavisson/netdiagnostics/ddr/UserDefinedQueries?testRun=' + testRun + "&saveQuery=true&showQuery=undefined&deleteQuery=undefined&showQueryData=undefined" + "&queryName=" + queryName + "&description=" + description + "&queryData=" + JSON.stringify(data) + "&queryAutofill=" + JSON.stringify(autoFill) + "&user=" + userName + '&openReport=' + currReport;
            if (this._ddrData.editQuery == true)
                url += "&modify=true";
            this.ddrRequest.getDataUsingGet(url).subscribe(rest => {
                this.savedQueriesObject = rest['data'];
                this._ddrData.sendMessage$.next("Query Saved");
                console.log(this.savedQueriesObject, "************************************");
                //sendig show query request to update the queryname list for all the queries user have just saved so that multiple save would be restricted.
                url = this.getHostUrl() + '/' + product + '/v1/cavisson/netdiagnostics/ddr/UserDefinedQueries?testRun=' + testRun + "&saveQuery=undefined&showQuery=true&deleteQuery=undefined";
                this.ddrRequest.getDataUsingGet(url).subscribe(rest => {
                    this._ddrData.savedQueryName = rest['queryName'];
                });
            }, error => {
                this._ddrData.sendMessage$("Error While Saving Query");
            });
        }
    }
    confirmUniqeQuery(queryName) {
        console.log("this._ddrData.savedQueryName ", this._ddrData.savedQueryName, " queryName ", queryName);
        //this._ddrData.savedQueryName.includes(queryName)
        if (this._ddrData.savedQueryName && this._ddrData.savedQueryName.includes(queryName))
            return true;
        else
            return false;
    }
    createTagDetail(tagSideBar) {
        if (tagSideBar && tagSideBar.gTags) {
            let gTagArr = tagSideBar.gTags.gTag;
            if (gTagArr && gTagArr.length > 0) {
                for (let i = 0; i < gTagArr.length; i++) {
                    let tagsArr = gTagArr[i];
                    if (tagsArr && tagsArr.length > 0) {
                        for (let j = 0; j < tagsArr.length; j++) {
                            let tagObj = tagsArr[j];
                            if (this.gTagsStr == '' || this.gTagsStr == undefined) {
                                this.gTagsStr = "\'" + tagObj.key + "\'" + "=" + "\'" + tagObj.value + "\'";
                            }
                            else {
                                this.gTagsStr = this.gTagsStr + "," + "\'" + tagObj.key + "\'" + "=" + "\'" + tagObj.value + "\'";
                            }
                        }
                        this.gTagsStr = "\"" + this.gTagsStr + "\"";
                    }
                }
            }
        }
        return this.gTagsStr;
    }
    assignAutoFillData(currentReport) {
        if (this.id.tierName) {
            this.selectedTier = true;
            this.fetchMetadata('tier');
            this.tierName.push(this.id.tierName);
        }
        if (this.id.serverName) {
            this.selectedServer = true;
            this.fetchMetadata('server');
            this.serverName.push(this.id.tierName + ":" + this.id.serverName);
        }
        if (this.id.appName) {
            this.selectedApp = true;
            this.fetchMetadata('app');
            this.appName.push(this.id.tierName + ":" + this.id.serverName + ":" + this.id.appName);
        }
        if (this.id.flowpathID) {
            this.selectedFP = true;
            this.fpInstance = this.id.flowpathID;
        }
        if (this.id) {
            this.createDropDownMenu();
            let presetName;
            this.timeFilter = true;
            presetName = this.getPresetName(this.id.strGraphKey);
            this.selectedTime = presetName;
            if (presetName == "Custom Time") {
                this.timeFilter = true;
                if (this.id.startTime && this.id.endTime) {
                    const endTime = this.sessionService.convertTimestampIntoFormattedString(Number(this.id.endTime));
                    const startTime = this.sessionService.convertTimestampIntoFormattedString(Number(this.id.startTime));
                    this.strTimeInDateFormat = startTime;
                    this.endTimeInDateFormat = endTime;
                    this.strDate = new Date(startTime);
                    this.endDate = new Date(endTime);
                }
                else {
                    const endTime = this.sessionService.convertTimestampIntoFormattedString(Number(this.sessionService.session.testRun.st + this.sessionService.session.testRun.duration));
                    const startTime = this.sessionService.convertTimestampIntoFormattedString(Number(this.sessionService.session.testRun.st));
                    this.strTimeInDateFormat = startTime;
                    this.endTimeInDateFormat = endTime;
                    this.strDate = new Date(startTime);
                    this.endDate = new Date(endTime);
                }
            }
        }
        if (this.id.btCategory != undefined && this.id.btCategory != "undefined") {
            this.selectedBT = true;
            this.selectedBTCategory = this.id.btCategory;
        }
        if (this.id.urlName && this.id.urlName != "AllTransactions") {
            this.checkedBuisnessTransaction = true;
            this.fetchMetadata('businessTransaction');
            this.selectedBuisnessTransaction = {};
            let selectedBTIndex;
            setTimeout(() => {
                selectedBTIndex = this.BTOptions.filter(val => val.value.name === this.id.urlName)[0].value.id,
                    this.selectedBuisnessTransaction = { id: selectedBTIndex, name: this.id.urlName };
            }, 5000);
        }
        if (this.id.strOrderBy) {
            if (currentReport == "Flowpath") {
                this.fpOrderByCheck = true;
                this.fpOrderCheck();
                this.selectedFpOrderBy = this.id.strOrderBy;
            }
        }
        if (this.id.backendRespTime) {
            this.checkedResponseTime = true;
            this.resSelectedCompareOption = "2";
            this.responseTime = this.id.backendRespTime;
        }
    }
    getPresetName(presetId) {
        try {
            // Map presetId to presetName
            switch (presetId) {
                case "LIVE0":
                    return "5";
                case "LIVE1":
                    return "10";
                case "LIVE2":
                    return "30";
                case "LIVE3":
                    return "60";
                case "LIVE4":
                    return "120";
                case "LIVE5":
                    return "240";
                case "LIVE6":
                    return "360";
                case "LIVE7":
                    return "480";
                case "LIVE8":
                    return "720";
                case "LIVE9":
                    return "1440";
                default:
                    return "Custom Time";
            }
        }
        catch (error) {
            // Handle any errors and return an empty string
            return "";
        }
    }
    ngOnChanges(changes) {
        if (this.commonServices.currentReport == "Transaction Instance" || this.commonServices.currentReport == "Transaction Summary"
            || this.commonServices.currentReport == "Page Summary" || this.commonServices.currentReport == "Page Instance" || this.commonServices.currentReport == "Session Summary" || this.commonServices.currentReport == "Session Instance"
            || this.commonServices.currentReport == "URL Summary" || this.commonServices.currentReport == "URL Instance") {
            this.checkNSFilter();
            this.Reset(true);
            this.dataChangeDetected.emit();
        }
    }
};
DdrSideBarComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_4__["MessageService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_6__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_7__["SessionService"] },
    { type: src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrSideBarComponent.prototype, "currentReport", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"])()
], DdrSideBarComponent.prototype, "dataChangeDetected", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('commonTag')
], DdrSideBarComponent.prototype, "commonTag", void 0);
DdrSideBarComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-side-bar',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-side-bar.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-side-bar.component.scss */ "./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.scss")).default]
    })
], DdrSideBarComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.css":
/*!********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.css ***!
  \********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".ddr-side-view-div{display:flex;justify-content:space-between;position:relative;padding:5px 5px 5px 16px;border:solid 1px #ccc;border-left:none;padding-right:8px;margin-bottom:3px;height:80px; transition: all 300ms ease;}\r\n.childflex{display:flex;flex-wrap:wrap;align-items:center;width:100%;line-height:24px}\r\n.sideLine{position:absolute;width:6px;top:0;bottom:0;left:0;z-index:99}\r\n.column{justify-content:space-between;width:100%;display:flex;flex-direction:column}\r\n.fa-c:before{font-weight:700;content:'C';margin-left:8px}\r\n.fa-j:before{font-weight:700;content:'J';margin-left:8px}\r\n.scrollSideView{overflow:auto;height:calc(100vh - 110px)}\r\n.statusIcons{display:flex;flex-direction:column;align-items:flex-end;justify-content:space-between;text-align:right;margin-left:6px;height:60px}\r\n.ddr-side-view-div:hover, .ddr-active-flowpath{background-color: rgb(43 209 43 / 25%);}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.ts":
/*!*******************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.ts ***!
  \*******************************************************************************/
/*! exports provided: DdrSideViewComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrSideViewComponent", function() { return DdrSideViewComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../services/ddr-txn-flowmap-data.service */ "./src/app/pages/ddr/services/ddr-txn-flowmap-data.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/platform-browser */ "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/platform-browser.js");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_dashboard_service_req_transaction_flowmap_transaction_flowmap_component__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/pages/dashboard-service-req/transaction-flowmap/transaction-flowmap.component */ "./src/app/pages/dashboard-service-req/transaction-flowmap/transaction-flowmap.component.ts");
/* harmony import */ var src_app_pages_dashboard_service_req_transaction_flowmap_service_transaction_flowmap_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/pages/dashboard-service-req/transaction-flowmap/service/transaction-flowmap.service */ "./src/app/pages/dashboard-service-req/transaction-flowmap/service/transaction-flowmap.service.ts");
/* harmony import */ var _ddr_details_view_ddr_details_view_component__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../ddr-details-view/ddr-details-view.component */ "./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.ts");
/* harmony import */ var src_app_pages_dashboard_service_req_transaction_flowmap_service_trx_flowmap_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/dashboard-service-req/transaction-flowmap/service/trx-flowmap.service */ "./src/app/pages/dashboard-service-req/transaction-flowmap/service/trx-flowmap.service.ts");












let DdrSideViewComponent = class DdrSideViewComponent {
    constructor(commonService, flowmapDataService, _ddrData, breadcrumb, sanitizer, sessionService, refreshTrxLrm, nonExpandFlag, txFlowmapService) {
        this.commonService = commonService;
        this.flowmapDataService = flowmapDataService;
        this._ddrData = _ddrData;
        this.breadcrumb = breadcrumb;
        this.sanitizer = sanitizer;
        this.sessionService = sessionService;
        this.refreshTrxLrm = refreshTrxLrm;
        this.nonExpandFlag = nonExpandFlag;
        this.txFlowmapService = txFlowmapService;
        this.flowpathSelected = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this.breadcrumb = breadcrumb;
        this.txnToggle = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this.otelMode = this._ddrData.otelMode;
    }
    ngOnChanges() {
        if (this._ddrData.ndDCNameInfo && this._ddrData.ndDCNameInfo.length > 0 && this._ddrData.isFromNV && this._ddrData.isFromNV == "1") {
            for (let i = 0; i < this._ddrData.ndDCNameInfo.length; i++) {
                if (this._ddrData.ndDCNameInfo[i].displayName == this.selectedData.dcName) {
                    this._ddrData.dcName = this.selectedData.dcName;
                    this._ddrData.testRun = this._ddrData.ndDCNameInfo[i].ndeTestRun;
                    break;
                }
            }
        }
        if (this.sortField && this.order) {
            this.sortColumnsOnCustom(this.sortField, this.order, this.flowpathData);
        }
    }
    ngOnInit() {
        let highObj = {};
        for (let i = 0; i < this.flowpathData.length; i++) {
            if (!this.otelMode) {
                if (this.selectedData.flowpathInstance == this.flowpathData[i].flowpathInstance) {
                    highObj = this.flowpathData[i];
                    this.flowpathData.splice(i, 1);
                }
            }
            else {
                if (this.selectedData.TraceId == this.flowpathData[i].TraceId) {
                    highObj = this.flowpathData[i];
                    this.flowpathData.splice(i, 1);
                }
            }
        }
        this.flowpathData.unshift(highObj);
    }
    rowClick(rowData) {
        this.commonService.hsData = undefined;
        this._ddrData.splitViewBreadCrumbFlag = true;
        this.flowpathSelected.emit(rowData);
        this.txnToggle.emit(false);
        if (this.index == 7) {
            let columnFlowpathData = JSON.parse(JSON.stringify(rowData));
            if (columnFlowpathData.fpDuration == '< 1')
                columnFlowpathData.fpDuration = 0;
            this.flowmapDataService.resetFlag();
            if (this.pendingFlowPathInstance != columnFlowpathData.flowpathInstance) {
                this.pendingFlowPathInstance = columnFlowpathData.flowpathInstance;
                this.sessionService.setSetting("fpRowdata", columnFlowpathData);
                this.nonExpandFlag.nonExpnadMode();
                this.unsubscribeAll();
                this.refreshTrxLrm.load();
                this._ddrData.flagTrx = true;
            }
            else {
                this.commonService.loaderForDdr = false;
            }
        }
    }
    // Method to unsubscribe previous pending rest-calls of Txn flowmap on row selection from side-view
    unsubscribeAll() {
        this.txFlowmapService.subscriptions.forEach((subscription) => {
            subscription.unsubscribe();
        });
    }
    changeStyle($event) {
        this.hide = $event.type === 'mouseenter' ? false : true;
    }
    ConverIntoNumber(value) {
        if (value) {
            let numberValue = Number(value);
            return numberValue;
        }
        else {
            return value;
        }
    }
    formatter(val) {
        if (val && val.length > 18)
            return val.substring(0, 18) + "...";
        else
            return val;
    }
    formatterTSA(val) {
        if (val && val.length > 16)
            return val.substring(0, 16) + "...";
        else
            return val;
    }
    sortColumnsOnCustom(field, order, tempData) {
        //for interger type data type
        if (field == "startTime") {
            if (order == -1) {
                var temp = (field);
                order = 1;
                tempData = tempData.sort(function (a, b) {
                    var value = Date.parse(a[temp]);
                    var value2 = Date.parse(b[temp]);
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = field;
                order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    var value = Date.parse(a[temp]);
                    var value2 = Date.parse(b[temp]);
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        else if (field == "appName" || field == "correlationId") {
            if (order == -1) {
                var temp = field;
                order = 1;
                var reA = /[^a-zA-Z]/g;
                var reN = /[^0-9]/g;
                tempData = tempData.sort(function (a, b) {
                    var v1 = a[temp];
                    var v2 = b[temp];
                    let value;
                    let value2;
                    v1 = v1.replace(reA, "");
                    v2 = v2.replace(reA, "");
                    if (v1 === v2) {
                        value = parseInt(a[temp].replace(reN, ""), 10);
                        value2 = parseInt(b[temp].replace(reN, ""), 10);
                        return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                    }
                    else {
                        value = a[temp];
                        value2 = b[temp];
                        return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                    }
                });
            }
            else {
                var temp = field;
                order = -1;
                var reA = /[^a-zA-Z]/g;
                var reN = /[^0-9]/g;
                tempData = tempData.sort(function (a, b) {
                    let v1 = a[temp];
                    let v2 = b[temp];
                    let value;
                    let value2;
                    v1 = v1.replace(reA, "");
                    v2 = v2.replace(reA, "");
                    if (v1 === v2) {
                        value = parseInt(a[temp].toString().replace(reN, ""), 10);
                        value2 = parseInt(b[temp].toString().replace(reN, ""), 10);
                        return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                    }
                    else {
                        value = a[temp];
                        value2 = b[temp];
                        return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                    }
                });
            }
        }
        else if (field == "methodsCount" || field == "callOutCount" || field == "coherenceCallOut" || field == "jmsCallOut" || field == "dbCallCounts" || field == "totalError" || field == "statusCode" || field == "flowpathInstance" || field == "ndSessionId" || field == "nvPageId" || field == "syncTime" || field == "nvSessionId" || field == "btCpuTime" || field == "storeId" || field == "terminalId" || field == "QTimeInMS" || field == "suspensiontime" || field == "iotime" || field == "waitTime") {
            if (order == -1) {
                var temp = field;
                order = 1;
                tempData = tempData.sort(function (a, b) {
                    if (a[temp].startsWith('<') && b[temp].startsWith('<')) {
                        return 0;
                    }
                    else if (a[temp].startsWith('<')) {
                        return 1;
                    }
                    else if (b[temp].startsWith('<')) {
                        return -1;
                    }
                    var value = Number(a[temp].replace(/,/g, ''));
                    var value2 = Number(b[temp].replace(/,/g, ''));
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = field;
                order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    if (a[temp].startsWith('<') && b[temp].startsWith('<')) {
                        return 0;
                    }
                    else if (a[temp].startsWith('<')) {
                        return -1;
                    }
                    else if (b[temp].startsWith('<')) {
                        return 1;
                    }
                    var value = Number(a[temp].replace(/,/g, ''));
                    var value2 = Number(b[temp].replace(/,/g, ''));
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        else {
            if (order == -1) {
                var temp = field;
                order = 1;
                var reA = /[^a-zA-Z]/g;
                var reN = /[^0-9]/g;
                tempData = tempData.sort(function (a, b) {
                    let value;
                    let value2;
                    value = a[temp];
                    value2 = b[temp];
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = field;
                order = -1;
                var reA = /[^a-zA-Z]/g;
                var reN = /[^0-9]/g;
                tempData = tempData.sort(function (a, b) {
                    let value;
                    let value2;
                    value = a[temp];
                    value2 = b[temp];
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        this.flowpathData = [];
        if (tempData) {
            tempData.map((rowdata) => { this.flowpathData = this.Immutablepush(this.flowpathData, rowdata); });
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
};
DdrSideViewComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_3__["DdrTxnFlowmapDataService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["BreadcrumbService"] },
    { type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__["DomSanitizer"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_7__["SessionService"] },
    { type: src_app_pages_dashboard_service_req_transaction_flowmap_transaction_flowmap_component__WEBPACK_IMPORTED_MODULE_8__["TransactionFlowmapComponent"] },
    { type: src_app_pages_dashboard_service_req_transaction_flowmap_service_trx_flowmap_service__WEBPACK_IMPORTED_MODULE_11__["TrxFlowmapService"] },
    { type: src_app_pages_dashboard_service_req_transaction_flowmap_service_transaction_flowmap_service__WEBPACK_IMPORTED_MODULE_9__["TransactionFlowMapService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrSideViewComponent.prototype, "flowpathData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrSideViewComponent.prototype, "selectedData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrSideViewComponent.prototype, "sortField", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrSideViewComponent.prototype, "order", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrSideViewComponent.prototype, "index", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"])()
], DdrSideViewComponent.prototype, "flowpathSelected", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"])()
], DdrSideViewComponent.prototype, "txnToggle", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])(_ddr_details_view_ddr_details_view_component__WEBPACK_IMPORTED_MODULE_10__["DdrDetailsViewComponent"])
], DdrSideViewComponent.prototype, "sourceComponent", void 0);
DdrSideViewComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-side-view',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-side-view.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-side-view.component.css */ "./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.css")).default]
    })
], DdrSideViewComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.scss":
/*!***********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.scss ***!
  \***********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.ts":
/*!*********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.ts ***!
  \*********************************************************************************/
/*! exports provided: DdrSplitViewComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrSplitViewComponent", function() { return DdrSplitViewComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/pages/tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");





let DdrSplitViewComponent = class DdrSplitViewComponent {
    constructor(commonService, sessionService, _ddrData) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this._ddrData = _ddrData;
        this.buttonValue = 'icons8 icons8-minus';
        this.sortButtonHide = true;
        this.openSortPopUp = false;
        this.columnName = '';
        this.toggle = true;
        this.sortFieldName = '';
        this.sortingOrder = '';
        // @ViewChild('sideView') sideView: ElementRef;
        this.sideViewToggler = true;
        this.currentRowData = this.commonService.currentRowData;
    }
    ngOnInit() {
        this.commonService.isFromSplitView = true;
        this.sortOptions = [];
        this.sortOptions = [
            { label: 'Business Transaction', value: 'urlName' },
            { label: 'Category', value: 'btCatagory' },
            { label: 'Start Time', value: 'startTime' },
            { label: 'Process Time(ms)', value: 'fpDuration' },
            { label: 'Tier', value: 'tierName' },
            { label: 'Server', value: 'serverName' },
            { label: 'Instance', value: 'appName' },
            { label: 'Methods', value: 'methodsCount' },
            { label: 'Callouts', value: 'callOutCount' },
            { label: 'Coherence Callout', value: 'coherenceCallOut' },
            { label: 'JMS Callout', value: 'jmsCallOut' },
            { label: 'DB Callouts', value: 'dbCallCounts' },
            { label: 'Callout Errors', value: 'totalError' },
            { label: 'Status', value: 'statusCode' },
            { label: 'Flowpath Instance', value: 'flowpathInstance' },
            { label: 'URL', value: 'urlQueryParamStr' },
            { label: 'CPU Time(ms)', value: 'btCpuTime' },
            { label: 'Corr ID', value: 'correlationId' },
            { label: 'ND Session ID', value: 'ndSessionId' },
            { label: 'NV Page ID', value: 'nvPageId' },
            { label: 'NV Session ID', value: 'nvSessionId' },
            { label: 'Wait Time(ms)', value: 'waitTime' },
            { label: 'Sync Time(ms)', value: 'syncTime' },
            { label: 'IO Time(ms)', value: 'iotime' },
            { label: 'Suspension Time(ms)', value: 'suspensiontime' },
            { label: 'Store ID', value: 'storeId' },
            { label: 'Terminal ID', value: 'terminalId' },
            { label: 'QTime (ms)', value: 'QTimeInMS' },
            { label: 'Response Time(ms)', value: 'selfResponseTime' },
            { label: 'Parent FlowpathInstance', value: 'ParentFlowpathInstance' },
            { label: 'Total CPU Time(ms)', value: 'totalCpuTime' }
        ];
    }
    showHide() {
        if (this.sideViewToggler) {
            this.buttonValue = 'icons8 icons8-plus-math';
            this.buttonValueTootip = "Show Side View";
            this.sortButtonHide = false;
            this.sideViewToggler = false;
        }
        else {
            this.buttonValue = 'icons8 icons8-minus';
            this.buttonValueTootip = "Hide Side View";
            this.sortButtonHide = true;
            this.sideViewToggler = true;
        }
    }
    selectedRowData(event) {
        this.commonService.order = '';
        this.commonService.currentRowData = event;
    }
    openPopUp() {
        this.openSortPopUp = true;
        this.commonService.order = '';
    }
    setIndex(event) {
        this.commonService.index = event;
    }
    Immutablepush(flowpathData, rowdata) {
        throw new Error('Method not implemented.');
    }
    ngOnDestroy() {
        this._ddrData.splitViewFlag = false;
        this.commonService.isFromSplitView = false;
    }
};
DdrSplitViewComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_3__["SessionService"] },
    { type: src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] }
];
DdrSplitViewComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-split-view',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-split-view.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-split-view.component.scss */ "./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.scss")).default]
    })
], DdrSplitViewComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.css":
/*!********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.css ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".ui-widget-header {\r\n    border: 1px solid #aaa;\r\n    background: #ccc url('/netstorm/images/tableHeader.png') 50% 50% repeat-x !important;\r\n    color: #222;\r\n    font-weight: 700\r\n}\r\n\r\nsvg.redLine path {\r\n    stroke: red;\r\n    stroke-width: 1\r\n}\r\n\r\n#divMapimg {\r\n    display: none;\r\n    position: fixed;\r\n    z-index: 1000;\r\n    top: -130px;\r\n    left: -430px;\r\n    height: 100%;\r\n    width: 100%;\r\n    background: rgba(255, 255, 255, .8) url(/netstorm/images/ajax-loader.gif) 50% 50% no-repeat\r\n}\r\n\r\n.aLabel._jsPlumb_hover {\r\n    background-color: #5C96BC;\r\n    color: #fff;\r\n    border: .5px solid #fff\r\n}\r\n\r\n.plumbNode {\r\n    width: 60px;\r\n    height: 60px\r\n}\r\n\r\n.pImage {\r\n    background-image: url('/netstorm/images/java.png');\r\n    background-size: 60px 60px;\r\n    background-repeat: no-repeat\r\n}\r\n\r\n.node {\r\n    width: 48px;\r\n    height: 48px;\r\n    border-radius: 25px;\r\n    border: 3px solid #1695fb;\r\n    box-shadow: 0 0 15px #000;\r\n    background-color: var(--background_color_1)\r\n}\r\n\r\n.nodeImage {\r\n    float: left;\r\n    width: 38px\r\n}\r\n\r\n.tierimage {\r\n    float: left;\r\n    width: 38px;\r\n    margin-right: -4px\r\n}\r\n\r\n.nodeRight {\r\n    float: right;\r\n    width: 108px;\r\n    height: 20px\r\n}\r\n\r\n.nodeIcon {\r\n    padding-top: 1px\r\n}\r\n\r\n.nodeHeading {\r\n    text-align: center;\r\n    color: var(--success-700);\r\n    font-weight: 700;\r\n    font-size: 10px;\r\n    padding-top: 11px;\r\n    width: 185px;\r\n    height: 20px\r\n}\r\n\r\n.nodeBottom {\r\n    text-align: center;\r\n    margin-top: 6px;\r\n    font-size: 10px;\r\n    width: 183px\r\n}\r\n\r\n.flowmap-box {\r\n    overflow: auto;\r\n    position: relative;\r\n    background-color: var(--background_color_1)\r\n}\r\n\r\n.flowchart-demo .newLabel {\r\n    background-color: var(--background_color_7);\r\n    padding: .4em;\r\n    font: 10px Verdana, Arial, Helvetica, sans-serif;\r\n    color: var(--color_4);\r\n    z-index: 21;\r\n    border-radius: 12.5px;\r\n    text-overflow: ellipsis;\r\n    cursor: pointer\r\n}\r\n\r\n.tierName {\r\n    font-size: 12px;\r\n    padding-top: 11px;\r\n    color: #151313\r\n}\r\n\r\n.screen {\r\n    width: 100%;\r\n    float: right;\r\n    height: 100vh;\r\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.ts":
/*!*******************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.ts ***!
  \*******************************************************************************************/
/*! exports provided: DdrTierMergeViewComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrTierMergeViewComponent", function() { return DdrTierMergeViewComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _services_ddr_agg_flowmap_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../services/ddr-agg-flowmap.service */ "./src/app/pages/ddr/services/ddr-agg-flowmap.service.ts");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! moment-timezone */ "./node_modules/moment-timezone/index.js");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_7__);








let DdrTierMergeViewComponent = class DdrTierMergeViewComponent {
    constructor(aggFlowmapService, _router, DdrBreadcrumbService, CommonServices, _ddrData) {
        this.aggFlowmapService = aggFlowmapService;
        this._router = _router;
        this.DdrBreadcrumbService = DdrBreadcrumbService;
        this.CommonServices = CommonServices;
        this._ddrData = _ddrData;
        this.dataToDraw = []; // Array to store data for drawing nodes.
        this.setOfIDs = new Set(); //set for storing each unique ID of nodes.
        this.labelNode = '';
        this.waningPopup = false;
    }
    ngOnInit() {
        this.CommonServices.currentReport = "Aggregate Transaction Flowmap";
        this.aggFlowmapService.getData().then(data => {
            this.aggFlowmapService.jsonDataForTierMergetoView.forEach((a) => {
                if (!this.setOfIDs.has(a.id)) {
                    this.dataToDraw.push(a);
                    this.setOfIDs.add(a.id);
                }
            });
            console.log("dat", this.dataToDraw, this.aggFlowmapService.jonDataForTierMergeToDraw);
            this.CommonServices.loaderForDdr = false;
            setTimeout(() => {
                this.creteflowmap(this.aggFlowmapService.jonDataForTierMergeToDraw);
                this.showHeaderInfo();
            }, 500);
        });
        if (this._ddrData.testRunTr)
            this._ddrData.testRun = this._ddrData.testRunTr;
    }
    creteflowmap(jsonDataToDraw) {
        //passing the referrence to use with function inside function
        var that = this;
        jsPlumb.ready(() => {
            var instance = window['jsp'] = jsPlumb.getInstance({
                Container: "canvas",
                Endpoint: ["Dot", { radius: 2 }],
                EndpointStyle: { fillStyle: "#567567" },
                connector: "Straight",
            });
            var basicType = {
                connector: "Straight",
                paintStyle: { stroke: "red", strokeWidth: 4 },
                hoverPaintStyle: { stroke: "blue" },
                overlays: [
                    "Arrow"
                ]
            };
            let count;
            count = 0;
            console.log("this.aggFlowmapService.btName", this.aggFlowmapService.btName);
            instance.registerConnectionType("basic", basicType);
            jsonDataToDraw.forEach((obj) => {
                console.log("jfvhfdhvghdfv", obj);
                if (count == 0)
                    obj["sourceId"] = "root";
                obj["ID"] = count.toString();
                // suspend drawing and initialise.
                console.log("checkkk", obj["sourceId"]);
                instance.batch(function () {
                    // make all the window divs draggable
                    instance.draggable(jsPlumb.getSelector(".flowchart-demo .window"), { grid: [20, 20] });
                    if (!(obj.sourceId == obj.targetID)) {
                        if (!obj.cType) {
                            var dynamicAnchors = [[0.2, 0, 0, -1], [1, 0.2, 1, 0],
                                "Top", "Bottom"];
                            instance.connect({
                                source: obj.sourceId + "",
                                target: obj.targetID + "",
                                hoverPaintStyle: { stroke: "red" },
                                Anchor: dynamicAnchors,
                                anchors: [["Perimeter", { shape: "Rectangle" }], ["Perimeter", { shape: "Rectangle" }]],
                                deleteEndpointsOnDetach: false,
                                detachable: false,
                                connector: "Straight",
                                overlays: [
                                    ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                    ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                    ["Label", { label: "<a id='label" + obj.ID + "'>" + getBtName(obj) + "<span id='labela" + obj.ID + "'></span></a>", location: 0.5, id: "myLabel", cssClass: " greenLabel" }]
                                ],
                            });
                        }
                        else {
                            if (obj.t && obj.t != -1) {
                                instance.connect({
                                    source: obj.sourceId + "",
                                    target: obj.targetID + "",
                                    hoverPaintStyle: { stroke: "red" },
                                    anchors: [["Perimeter", { shape: "Circle" }], ["Perimeter", { shape: "Rectangle" }]],
                                    deleteEndpointsOnDetach: false,
                                    detachable: false,
                                    connector: "Straight",
                                    overlays: [
                                        ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                        ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                        ["Label", { label: "<a id='label" + obj.ID + "'><center>" + getIpName(obj.t) + ", " + obj.count + " calls, Avg. Response Time=" + timeFormatter(obj.AvgD) + " ms </br>" + "</center><span id='labela" + obj.ID + "'></span></a>", location: 0.5, id: "myLabel", cssClass: "newLabel" }]
                                    ]
                                });
                            }
                            else {
                                let element = document.getElementById(obj.targetID);
                                element.parentNode.removeChild(element);
                            }
                        }
                        count++;
                    }
                    // for tool tip on lable
                    if ((obj.sourceId != obj.targetID)) {
                        //self invoked method for creating tooltip div for label of connections
                        (function tooltipMethod() {
                            console.log("self invoked", obj, obj.id);
                            var labelID = "label" + obj.ID;
                            var innerlabelid = "labela" + obj.ID;
                            var divBox = "<div style=''>";
                            if (obj.t)
                                divBox += "<b>Type: </b>" + getIpName(obj.t) + "<br/>";
                            let len = ((obj.count).toString().split(",")).length;
                            if (len > 1) {
                                divBox += getBtName(obj, true);
                            }
                            else {
                                divBox += "<b>Total Calls: </b>" + Number(obj.count).toLocaleString() + "<br/>";
                                if (obj.erc != undefined && !isNaN(obj.erc)) {
                                    divBox += "<b>Success Calls: </b>" + Number(obj.count - obj.erc).toLocaleString() + "<br/>";
                                    divBox += "<b>Error Calls: </b>" + Number(obj.erc).toLocaleString() + "<br/>";
                                    divBox += "<b>Avg. Response Time: </b>" + timeFormatter(Number(obj.Tduration) / Number(obj.count)) + "ms " + "<br/>";
                                }
                            }
                            if (obj.callOutType == "t") //handle both cases When cumBackenduration and min is equal or not  cumBackendDuartion is max duartion
                             {
                                if (Number(obj.cumBackendDuration) == 0)
                                    divBox += "<b>Max Duration: </b>< 1 ms<br/>";
                                else
                                    divBox += "<b>Max Duration: </b>" + Number(obj.cumBackendDuration).toLocaleString() + " ms" + "<br/>";
                                if (Number(obj.min) == 0)
                                    divBox += "<b>Min Duration: </b>< 1 ms<br/>";
                                else
                                    divBox += "<b>Min Duration: </b>" + Number(obj.min).toLocaleString() + " ms" + "<br/>";
                            }
                            if (obj.callOutType == "T" && obj.backendType === 'HTTP') {
                                if (obj.totalNetworkDelay != "-1") {
                                    if (obj.totalNetworkDelay == 0)
                                        divBox += "<b>Total Network Delay : </b>< 1 ms<br/>";
                                    else
                                        divBox += "<b>Total Network Delay : </b>" + Number(obj.totalNetworkDelay).toLocaleString() + " ms<br/>";
                                    if (obj.totalNetworkDelay != obj.avgNetworkDelay)
                                        divBox += "<b>Avg. Network Delay : </b>" + Number(obj.avgNetworkDelay).toLocaleString() + " ms<br/>";
                                }
                            }
                            divBox += "</div>";
                            setTimeout(() => {
                                /*
                                 *getting element of overlay i.e anchor tag
                                 *appending tooltip div to anchor tag which is inside overlay div.
                                 *adding tooltip class to the anchor tag to show tooltip div on hover.
                                 */
                                var d = document.getElementById(innerlabelid);
                                d.innerHTML = d.innerHTML + divBox;
                                document.getElementById(labelID).classList.add("tooltipsforlabel");
                                /*
                                * getting parent element of anchor tag of overlay which is dynamically created by jsplumb
                                *adding event listener on overlays
                                * and adding z index to those div's on mouse enter and removing  on mose leave.
                                 */
                                let parentElement = document.getElementById(labelID).parentElement;
                                document.getElementById(parentElement.id).addEventListener("mouseenter", function setzindexofoverlays(obj) {
                                    document.getElementById(parentElement.id).style.zIndex = "22";
                                });
                                document.getElementById(parentElement.id).addEventListener("mouseleave", function setzindexofoverlaysonleave(obj) {
                                    document.getElementById(parentElement.id).style.zIndex = "19";
                                });
                            }, 0);
                        }());
                    }
                });
            });
            function getBtName(obj, tooltip) {
                let d = "";
                let arrBt = obj.BtID.toString().split(",");
                let arrCount = (obj.count).toString().split(",");
                let avTime = (obj.Tduration).toString().split(",");
                let arrErr = (obj.erc).toString().split(",");
                let len = arrBt.length;
                for (let k = 0; k < len; k++) {
                    if (!tooltip) {
                        if (len == 1)
                            d += "<center>BT:" + getBT(arrBt[k]) + "," + getCalls(arrCount[k]) + ",Avg. Response Time :" + timeFormatter(Number(avTime[k]) / Number(arrCount[k])) + "ms " + "</center>";
                        else {
                            let count = 0;
                            for (let i = 0; i < len; i++) {
                                count += Number(arrCount[i]);
                            }
                            d += "<center>" + len + " BT, " + count + " calls</center>";
                            break;
                        }
                    }
                    else {
                        if (!arrErr[k])
                            arrErr[k] = "0";
                        d += "<b>BT:</b>" + getBT(arrBt[k]) + "," + "<b>Success Calls:</b>" + (Number(arrCount[k]) - Number(arrErr[k])) + "," + "<b>Error Calls:</b>" + arrErr[k] + ",Avg. Response Time :" + timeFormatter(Number(avTime[k]) / Number(arrCount[k])) + "ms ";
                    }
                    if (k != len - 1)
                        d += "</br>";
                }
                return d;
            }
            function getBT(btId) {
                for (let k = 0; k < that.aggFlowmapService.initJson.length; k++) {
                    if (that.aggFlowmapService.initJson[k].bts[btId]) {
                        return that.aggFlowmapService.initJson[k].bts[btId];
                    }
                }
            }
            function getIpName(type) {
                return that.aggFlowmapService.getBackendTypeName(type);
            }
            function getCalls(count) {
                if (count < 2) {
                    let lab = count + " call";
                    return lab;
                }
                else if (count == 2 || count > 2) {
                    let lab = count + " calls";
                    return lab;
                }
            }
            function timeFormatter(value) {
                if (!isNaN(value) && value % 1 != 0) {
                    value = (Number(value)).toFixed(2).toLocaleString();
                }
                return value;
            }
        });
    }
    trimTextForLarge(text) {
        try {
            if (text.length > 12)
                text = text.substring(0, 12) + "..";
            return text;
        }
        catch (err) {
            return "";
        }
    }
    showHeaderInfo() {
        this.labelNode = '';
        console.log("date n time", this.aggFlowmapService.startTime);
        let dat = new Date(this.aggFlowmapService.startTime);
        console.log("date n time", this.aggFlowmapService.startTime, dat);
        let str = dat.toLocaleString();
        dat = new Date(this.aggFlowmapService.endTime);
        let end = dat.toLocaleString();
        if (this._ddrData.btCategory)
            this.labelNode = "<b>Tier : </b> " + this.aggFlowmapService.tierName + ",&nbsp <b>BT :</b> " + this.aggFlowmapService.btName + ",&nbsp <b>Start Date/Time :</b> " + str + ",&nbsp <b>End Date/Time :</b> " + end + ",&nbsp <b>BT Type :</b> " + this.CommonServices.getBTCategoryName(this._ddrData.btCategory);
        else
            this.labelNode = "<b>Tier : </b> " + this.aggFlowmapService.tierName + ",&nbsp <b>BT :</b> " + this.aggFlowmapService.btName + ",&nbsp <b>Start Date/Time :</b> " + str + ",&nbsp <b>End Date/Time :</b> " + end;
        setTimeout(() => {
            var d = document.getElementById('filterTier');
            d.innerHTML = this.labelNode;
        }, 400);
    }
    //to show tooltip on node on mouse enter
    ShowtooltiponHover(name) {
        document.getElementById(name.id).style.zIndex = "22";
        this.tooltipForNodes = this.fortooltipofNode(name);
    }
    fortooltipofNode(obj) {
        let tooltipStr;
        if (obj.tN && obj.tN != '-')
            tooltipStr = "Tier: " + obj.tN;
        else
            tooltipStr = "Name: " + obj.displayName;
        return tooltipStr;
    }
    //to remove tooltip on mouse leave from node
    removeTooltip(name) {
        console.log('this.conted = ', this.contextRef);
        document.getElementById(name.id).style.zIndex = "20";
    }
    showWarningMessgae() {
        this.waningPopup = true;
    }
    getMenu(obj) {
        this.ContextMenuItems = [
            {
                label: 'Flowpath Report By Response Time',
                command: (event) => {
                    this.getUrlInfo(obj).then((data) => {
                        this.openReport(obj, "fpduration_desc", data, this.btId);
                    });
                }
            },
            {
                label: 'Flowpath Report By CallOut Error',
                command: (event) => {
                    this.getUrlInfo(obj).then((data) => {
                        this.openReport(obj, "error_callout", data, this.btId);
                    });
                }
            },
            {
                label: 'DB Queries',
                command: (event) => {
                    this.getUrlInfo(obj).then((data) => {
                        this.openReport(obj, "DB", data, this.btId);
                    });
                }
            },
            {
                label: 'Hotspots',
                command: (event) => {
                    this.getUrlInfo(obj).then((data) => {
                        this.openReport(obj, "Hotspots", data, this.btId);
                    });
                }
            },
            {
                label: 'Methods By Response Time',
                command: (event) => {
                    this.getUrlInfo(obj).then((data) => {
                        this.openReport(obj, "Methods", data, this.btId);
                    });
                }
            },
            {
                label: 'Exceptions',
                command: (event) => {
                    this.getUrlInfo(obj).then((data) => {
                        this.openReport(obj, "Exceptions", data, this.btId);
                    });
                }
            },
        ];
    }
    getUrlInfo(obj) {
        const element1 = this.aggFlowmapService.jonDataForTierMergeToDraw.find(data => data["tI"] == obj.tI);
        this.btId = element1["BtID"];
        console.log("this.aggFlowmapService.jonDataForTierMergeToDraw[k] ***", this.btId);
        return new Promise((resolve, reject) => {
            const element2 = this.aggFlowmapService.initJson.find(json => Object.keys(json.tiers).includes(obj.tI));
            const result = element2["CRI"];
            if (result) {
                console.log("working *****", result);
                resolve(result);
            }
            else {
                reject("CRI not found");
            }
        });
    }
    openReport(objofCurrentnode, strOrderBy, ipData, btId) {
        this._ddrData.isFromAgg = true;
        this._ddrData.isFromtrxFlow = true;
        this.CommonServices.fpFilters = "";
        let url = [];
        url = ipData.split("/");
        this._ddrData.protocolTr = url[0].split(":")[0];
        this._ddrData.hostTr = url[2].split(":")[0];
        let displayName = url[7];
        if (sessionStorage.getItem("isMultiDCMode") == "true" && displayName != '-') {
            this._ddrData.dcNameTr = displayName;
            this._ddrData.protocolTr = location.protocol.split(":")[0];
            this._ddrData.portTr = location.host.split(":")[1] + '/tomcat/' + displayName;
            this._ddrData.hostTr = location.host.split(":")[0];
        }
        else
            this._ddrData.portTr = url[2].split(":")[1];
        if (!this._ddrData.portTr) {
            if (this._ddrData.protocolTr == "http")
                this._ddrData.portTr = "80";
            else
                this._ddrData.portTr = "443";
        }
        this._ddrData.product = url[3];
        this._ddrData.testRunTr = url[8];
        this._ddrData.testRun = url[8];
        this._ddrData.tierName = objofCurrentnode["tN"];
        let hostDcName;
        hostDcName = "//" + this._ddrData.host + ":" + this._ddrData.port;
        if (hostDcName && this._ddrData.host)
            sessionStorage.setItem("hostDcName", hostDcName);
        this._ddrData.startTime = this.aggFlowmapService.startTime;
        this._ddrData.endTime = this.aggFlowmapService.endTime;
        this.DdrBreadcrumbService.parentComponent = "DdrTierMergeViewComponent";
        this.CommonServices.isFilterFromSideBar = false;
        if (strOrderBy == 'fpduration_desc' || strOrderBy == 'error_callout') {
            this._ddrData.strOrderBy = strOrderBy;
            this._ddrData.urlIndexAgg = btId;
            if (this._router.url.indexOf("/home/ddrCopyLink/") != -1)
                this._router.navigate(['/ddrCopyLink/flowpath']);
            else if (this._router.url.indexOf("/home/ED-ddr") != -1)
                this._router.navigate(['/home/ED-ddr/flowpath']);
            else
                this._router.navigate(['/ddr/flowpath']);
        }
        else if (strOrderBy == 'DB') {
            this._ddrData.strOrderBy == "query_count";
            this._ddrData.urlIndex = btId;
            this._router.navigate(['/ddr/dbReport']);
        }
        else if (strOrderBy == 'Hotspots') {
            //this._ddrData.urlIndex =  btId;
            this._ddrData.startTime = this.aggFlowmapService.startTime;
            this._ddrData.endTime = this.aggFlowmapService.endTime;
            this._ddrData.flagForHSToFP = '1';
            this._router.navigate(['/ddr/hotspot']);
        }
        else if (strOrderBy == 'Exceptions') {
            this._ddrData.urlIndex = btId;
            this._router.navigate(['/ddr/exception']);
        }
        else if (strOrderBy == 'Methods') {
            this._ddrData.urlIndex = btId;
            this._router.navigate(['/ddr/methodtiming']);
        }
    }
    getNodeDataforRouting(event, obj) {
        console.log(" inside getnodedataforrouting");
        if (event.button == 2) {
            console.log(" inside getnodedataforrouting  222");
            this.objofCurrentnode = obj;
            this.contextRef.show();
            setTimeout(() => {
                this.contextRef.show();
                let nodes = document.getElementById('contextmenu').childNodes;
                console.log("1", nodes);
                let elmHeight = document.getElementById(obj.id).style.top.split('px')[0];
                let elmleft = document.getElementById(obj.id).style.left.split('px')[0];
                console.log("check top ", elmHeight, elmleft);
                nodes[0]['style'].top = (Number(elmHeight) + 30) + 'px';
                nodes[0]['style'].left = (Number(elmleft) + 138) + 'px';
                console.log("check top q", nodes[0]['style'].top, nodes[0]['style'].left);
                this.mainContextMenu = this.ContextMenuItems;
            }, 300);
        }
        this.getMenu(obj);
    }
};
DdrTierMergeViewComponent.ctorParameters = () => [
    { type: _services_ddr_agg_flowmap_service__WEBPACK_IMPORTED_MODULE_6__["DdrAggFlowmapService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('contextRef')
], DdrTierMergeViewComponent.prototype, "contextRef", void 0);
DdrTierMergeViewComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-tier-merge-view',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-tier-merge-view.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-tier-merge-view.component.css */ "./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.css")).default]
    })
], DdrTierMergeViewComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.css":
/*!****************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.css ***!
  \****************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".query-row{border-style:solid;word-break:break-all;border-width:1px;border-bottom:none;background-color:var(--background_color_7);font-size:12px}\r\nsvg.redLine path{stroke:red;stroke-width:1}\r\n#divMapimg{display:none;position:fixed;z-index:1000;top:-130px;left:-430px;height:100%;width:100%;background:rgba(255,255,255,.8) url(/netstorm/images/ajax-loader.gif) 50% 50% no-repeat}\r\n.circle{border-radius:50%;width:44px!important;height:44px!important;background:orange}\r\n.pTop{width:60px;height:60px;float:left}\r\n.pBottom{float:left;clear:left}\r\n.divLabel{background-color:#fff;font:10px Verdana,Arial,Helvetica,sans-serif}\r\n.aLabel._jsPlumb_hover{background-color:#5C96BC;color:#fff;border:.5px solid #fff}\r\n.plumbNode{width:60px;height:60px}\r\n.pImage{background-image:url('/netstorm/images/java.png');background-size:60px 60px;background-repeat:no-repeat}\r\n.tfDiv{position:relative;width:100%;height:518px;overflow:auto;margin-top:-15px}\r\n.w2ui-popup .w2ui-msg-buttons{text-align:right!important}\r\na.tooltips{position:relative;display:inline}\r\na.tooltips span{position:absolute;min-width:200px;color:#000;background-color:#fff;-webkit-box-shadow:0 0 12px rgba(0,0,0,0.4);-moz-box-shadow:0 1px 6px rgba(23,69,88,.5);border-radius:7px;background:-moz-linear-gradient(top,white 0%,white 55%,#D5E4F3 130%);min-height:30px;line-height:16px;overflow:hidden;text-align:left;visibility:hidden;border:1px solid #1a1a1a;z-index:99999;border:2px Solid #999;border-top-left-radius:7px 7px;border-top-right-radius:7px 7px;border-bottom-right-radius:7px 7px;border-bottom-left-radius:7px 7px;white-space:nowrap}\r\na.tooltips span:after{content:'';position:absolute;bottom:100%;left:50%;margin-left:-8px;width:0;height:0;border-bottom:8px solid #000;border-right:8px solid transparent;border-left:8px solid transparent}\r\na:hover.tooltips span{visibility:visible;top:30px;left:50%;margin-left:-76px}\r\n.err-node{width:48px;height:48px;border-radius:25px;border:3px solid red}\r\n.err-page-node{width:48px;height:48px;border-radius:25px;border:4px solid #ffbf00}\r\n.node{width:48px;height:48px;border-radius:25px;border:3px solid #1695fb;background:#f8f8ff}\r\n.nodeImage{float:left;width:32px}\r\n.nodeRight{float:right;width:108px;height:20px}\r\n.nodeHeading{text-align:center;color:#0c5207;font-weight:700;font-size:10px;padding-top:11px;width:185px;height:20px}\r\n.nodeBottom{text-align:center;margin-top:6px;font-size:10px;width:183px}\r\na{color:#000!important}\r\n.flowmap-box{margin:5px 4px;padding:1px;border-radius:4px;background:hsla(0,0%,100%,0.8);overflow:auto;position:relative}\r\n.textWrap{width:450px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}\r\n.fieldsetClass{border-color:rgba(79,79,80,0.3)}\r\n.for-filter{font-size:11px;font-weight:500}\r\n.pre_next{width:45px;height:18px;float:right;text-align:center;padding:.2rem .5rem;font-size:11px;border:solid 1px #d6d6d6;border-radius:.2rem;color:#7d7d7d;cursor:pointer}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.ts":
/*!***************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.ts ***!
  \***************************************************************************************************/
/*! exports provided: DdrTransactionFlowmapComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrTransactionFlowmapComponent", function() { return DdrTransactionFlowmapComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! jquery */ "./node_modules/jquery/dist/jquery.js");
/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../services/ddr-txn-flowmap-data.service */ "./src/app/pages/ddr/services/ddr-txn-flowmap-data.service.ts");
/* harmony import */ var _services_ddr_transactio_individual_info_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./../../services/ddr-transactio-individual-info.service */ "./src/app/pages/ddr/services/ddr-transactio-individual-info.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-top-panel-navigation.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-top-panel-navigation.service.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/common/http */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/http.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! moment */ "./node_modules/moment/moment.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_13__);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! moment-timezone */ "./node_modules/moment-timezone/index.js");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_14__);
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_16__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! src/app/pages/tools/admin/access-control-management/constants/cav-acl-features.constants */ "./src/app/pages/tools/admin/access-control-management/constants/cav-acl-features.constants.ts");





















//declare var LZString: any;
let DdrTransactionFlowmapComponent = class DdrTransactionFlowmapComponent {
    constructor(flowmapData, _render, nodeTabledataService, CommonServices, _navService, _router, _ddrData, breadcrumbService, _cavConfigService, http, el, changeDetection, ddrRequest, breadcrumb, sessionService) {
        this.flowmapData = flowmapData;
        this._render = _render;
        this.nodeTabledataService = nodeTabledataService;
        this.CommonServices = CommonServices;
        this._navService = _navService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this._cavConfigService = _cavConfigService;
        this.http = http;
        this.el = el;
        this.changeDetection = changeDetection;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_16__;
        this.tableDialogDisplay = false;
        this.nodeColor = "err-page-node"; //css class to apply on nodes
        this.popupTitle = ""; //to show tittle of dialog box on db click
        this.showClipboard = false; //to show tittle of dialog box on db click
        this.col = []; // array to hold the columns of table
        this.transactionTableArray = [];
        this.isTooltip = false;
        this.showSelfLoop = false; //to show and hide the dom element of jsPlumb  on the basis of user choice
        this.selfLoppedDataToDraw = []; //it holds the json for  data part in case of thread merging
        this.selfLoppedDataToDrawToView = []; //it holds the json for  html view in case of thread merging
        this.isFromMain = false;
        this.displayTFMPopUp = false;
        this.displayShowRelatedGraph = false;
        this.isFromContextMenu = false;
        this.ContextMenuItemsForExceeption = [];
        this.reCreateDiv = false;
        this.cols = [];
        this.cols1 = [];
        this.cols2 = [];
        this.showmore = false;
        this.showmore1 = false;
        // ColumnRowData: any;
        // ColumnRowData1: any;
        this.graphTableArray = [];
        this.tableDialogDisplay1 = false;
        this.singleMergeGraph = false;
        this.displaySamplePopup = false;
        this.startSample = '5';
        this.endSample = '5';
        this.showAutoInstrPopUp = false;
        this.aggRenameArray = {};
        this.aggColOrder = [];
        this.httpDialog = false;
        this.httpDialogTable = false;
        this.httpRequestArrBody2 = [];
        this.httpResponseArrBody2 = [];
        this.dbCalloutDetails = [];
        this.colWidth = "";
        this.colAlignment = "";
        this.sortable = "false";
        this.sortField = "";
        this.labelNode = '';
        this.maxX = 0;
        this.maxY = 0;
        this.shiftFactor = 100; //This value is added to each Y cordn as to shift transaction flow diagram downward so that space report title and filter criteria can be made
        this.arr_id_x_y = []; //this is array to store- id, x cordn, y cordn - of each node of jsonData;
        this.waningPopup = false;
        this.breadcrumb = breadcrumb;
        this.dataOfFlowpathROw = this.flowmapData.paramsForFlowMap;
        // changeDetection.detach();
        // setInterval(() => {
        //   this.changeDetection.detectChanges();
        // }, 0);
    }
    ngOnChanges() {
        try {
            if (this._ddrData.splitViewFlag)
                this._ddrData.setInLogger('DDR::Flowpath', 'Transaction Flow', "Open Transaction Flowmap");
            console.log('this.contextRef = ', this.contextRef);
            this.reCreateDiv = false;
            console.log("changeDetector =", this.changeDetection);
            this.changeDetection.detectChanges();
            this.reCreateDiv = true;
            this.CommonServices.isToLoadSideBar = false;
            // this.breadcrumbService.setBreadcrumbs(CONSTANTS.BREADCRUMB_ITEMS.TRANSACTION_FLOWMAP);
            if (sessionStorage.getItem("jsonDatatoDraw" + this.flowmapData.childFlowpatthData) != undefined) {
                this.dataToDraw = JSON.parse(_services_common_services__WEBPACK_IMPORTED_MODULE_5__["LZString"].decompress(sessionStorage.getItem("jsonDatatoDraw")));
            }
            //getting json data form service and passing to dtatTodraw
            else {
                console.log("json to draw");
                this.dataToDraw = this.flowmapData.jsonData;
                //sessionStorage.setItem("jsonDatatoDraw",LZString.compress(JSON.stringify(this.dataToDraw))) ;
            }
            //this.CommonServices.loaderForDdr = false;
            this.nodeColor = "err-page-node";
            console.log("this.ghgh", this.dataToDraw);
            this.urlParam = this.CommonServices.getData();
            let checkFlag = this.showHeaderInfo(this.dataToDraw[0]);
            if (!checkFlag)
                return;
            //this.strTitle = 'Transaction Flowmap - '+ this.urlParam.testRun;
            /**This method used for thread merging and showing js plumb connections by default */
            this.getSelfLoopJsonData();
            this.tableDialogDisplay1 = false;
            this.displayShowRelatedGraph = false;
            this.singleMergeGraph = false;
            this.displaySamplePopup = false;
            this.CommonServices.loaderForDdr = false;
            this.randomNumber();
            this.showDbParam = false;
        }
        catch (e) {
            console.log("check error ", e);
            return;
        }
    }
    ngOnInit() {
        this._ddrData.isFromTrxnFlowmap = false;
        if (!this._ddrData.splitViewFlag) {
            this.CommonServices.isToLoadSideBar = true;
            // this.breadcrumbService.setBreadcrumbs(CONSTANTS.BREADCRUMB_ITEMS.TRANSACTION_FLOWMAP);
            // this.breadcrumb.add({label: 'Transaction Flowmap', routerLink: '/ddr/Ddrtransactionflowpmap'});
            //this.CommonServices.loaderForDdr = false;
            if (sessionStorage.getItem("jsonDatatoDraw" + this.flowmapData.childFlowpatthData) != undefined) {
                this.dataToDraw = JSON.parse(_services_common_services__WEBPACK_IMPORTED_MODULE_5__["LZString"].decompress(sessionStorage.getItem("jsonDatatoDraw")));
            }
            //getting json data form service and passing to dtatTodraw
            else {
                this.dataToDraw = this.flowmapData.jsonData;
                //sessionStorage.setItem("jsonDatatoDraw",LZString.compress(JSON.stringify(this.dataToDraw))) ;
            }
            this.nodeColor = "err-page-node";
            console.log("this.ghgh", this.dataToDraw);
            this.urlParam = this.CommonServices.getData();
            this.showHeaderInfo(this.dataToDraw[0]);
            //this.strTitle = 'Transaction Flowmap - '+ this.urlParam.testRun;
            /**This method used for thread merging and showing js plumb connections by default */
            this.getSelfLoopJsonData();
            this.randomNumber();
            this.CommonServices.loaderForDdr = false;
        }
        this.cols1 = [{ field: "value", header: "Request Body" }];
        this.cols2 = [{ field: "value", header: "Response Body" }];
        this.makeDbColumns();
    }
    makeDbColumns() {
        this.colsDbParam = [
            { field: 'QueryParameter', header: 'Query Parameters', sortable: true, action: true, width: '100' },
            { field: 'ResponseTime', header: 'Duration', sortable: true, action: true, width: '100' }
        ];
    }
    creteflowmap(jsonDataToDraw) {
        console.log(jsonDataToDraw, "hfbvdhbf");
        //passing the referrence to use with function inside function
        var that = this;
        jsPlumb.ready(() => {
            // this is the paint style for the connecting lines..
            // var connectorPaintStyle = {
            //     strokeWidth: 2,
            //     stroke: "#61B7CF",
            //     joinstyle: "round",
            //     outlineStroke: "white",
            //     outlineWidth: 2,
            //     paintStyle: { stroke: "red", strokeWidth: 4 },
            //     hoverPaintStyle: { stroke: "blue" },
            //     overlays: [
            //         "Arrow"
            //     ]
            // },
            // .. and this is the hover style.
            //    var     connectorHoverStyle = {
            //             strokeWidth: 3,
            //             stroke: "#216477",
            //             outlineWidth: 5,
            //             outlineStroke: "white"
            //         },
            //         endpointHoverStyle = {
            //             fill: "#216477",
            //             stroke: "#216477"
            // }
            //creating instance of jsplumb with some default properties
            var instance = window['jsp'] = jsPlumb.getInstance({
                Container: "canvas",
                Endpoint: ["Dot", { radius: 2 }],
                EndpointStyle: { fillStyle: "#567567" },
                //Anchor: "Continuous",
                connector: "Straight",
            });
            var basicType = {
                connector: "Straight",
                paintStyle: { stroke: "red", strokeWidth: 4 },
                hoverPaintStyle: { stroke: "blue" },
                overlays: [
                    "Arrow"
                ]
            };
            let agentID;
            instance.registerConnectionType("basic", basicType);
            jsonDataToDraw.forEach((obj, index) => {
                if (obj.instanceType == 'NodeJS') {
                    agentID = obj.id;
                }
                if (index == 0) {
                    this.entryFPI = obj.flowpathInstance;
                }
                // suspend drawing and initialise.
                instance.batch(function () {
                    // make all the window divs draggable
                    instance.draggable(jsPlumb.getSelector(".flowchart-demo .window"), { grid: [20, 20] });
                    // THIS DEMO ONLY USES getSelector FOR CONVENIENCE. Use your library's appropriate selector
                    // method, or document.querySelectorAll:
                    //  jsPlumb.draggable(jsPlumb.querySelectorAll(".window"), {containment:[5,130,99999,99999]});
                    //instance.draggable(jQuery(".window"),{ containment: jQuery('flowmap-box')});
                    if (obj.sourceId != obj.id) {
                        if (agentID == obj.sourceId) {
                            console.log('coming for nodejs', obj.sourceId, agentID);
                            instance.connect({
                                source: obj.sourceId,
                                target: obj.id,
                                cssClass: getConncetionClass(),
                                anchors: [["Perimeter", { shape: "Circle" }], ["Perimeter", { shape: "Rectangle" }]],
                                hoverPaintStyle: { stroke: "red" },
                                deleteEndpointsOnDetach: false,
                                detachable: false,
                                connector: "Straight",
                                paintStyle: { strokeWidth: 2, stroke: "blue", dashstyle: "2 4" },
                                overlays: [
                                    ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                    ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                    ["Label", { label: "<div class='smallCircle'><span style='font-size:10px;'><b>" + obj.index + "</b></span></div>", id: "label", location: 0.5 }],
                                    ["Label", { label: "<a style='color:black !important' id='label" + obj.id + "'><center>" + labelForconnection() + "</center><center title='" + geturlquery() + "' >" + geturlquery() + "</center><span id='labela" + obj.id + "'></span></a>", location: 0.5, id: "myLabel", cssClass: "" + getclassForlabel() + "" }]
                                ],
                            });
                        }
                        else {
                            if (obj.backendType === 'JMS_ATG') {
                                instance.connect({
                                    source: obj.sourceId,
                                    target: obj.id,
                                    cssClass: getConncetionClass(),
                                    anchors: [["Perimeter", { shape: "Circle" }], ["Perimeter", { shape: "Rectangle" }]],
                                    hoverPaintStyle: { stroke: "#2693FF" },
                                    deleteEndpointsOnDetach: false,
                                    detachable: false,
                                    connector: "Straight",
                                    paintStyle: { strokeWidth: 2, stroke: "blue", dashstyle: "2 4" },
                                    overlays: [
                                        ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                        ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                        ["Label", { label: "<div class='smallCircle'><span style='font-size:10px;'><b>" + obj.index + "</b></span></div>", id: "label", location: 0.5 }],
                                        ["Label", { label: "<a style='color:black !important' id='label" + obj.id + "'><center>" + labelForconnection() + "</center><center title='" + geturlquery() + "' >" + geturlquery() + "</center><span id='labela" + obj.id + "'></span></a>", location: 0.5, id: "myLabel", cssClass: "" + getclassForlabel() + "" }]
                                    ],
                                });
                            }
                            else {
                                instance.connect({
                                    source: obj.sourceId,
                                    target: obj.id,
                                    cssClass: getConncetionClass(),
                                    // connectorStyle: connectorPaintStyle,
                                    hoverPaintStyle: { stroke: "red" },
                                    anchors: [["Perimeter", { shape: "Circle" }], ["Perimeter", { shape: "Rectangle" }]],
                                    deleteEndpointsOnDetach: false,
                                    detachable: false,
                                    connector: "Straight",
                                    overlays: [
                                        ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                        ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                        ["Label", { label: "<div class='smallCircle'><span style='font-size:10px;'><b>" + obj.index + "</b></span></div>", id: "label", location: 0.5 }],
                                        ["Label", { label: "<a style='color:black !important' id='label" + obj.id + "'><center>" + labelForconnection() + "</center><center title='" + geturlquery() + "' >" + geturlquery() + "</center><span id='labela" + obj.id + "'></span></a>", location: 0.5, id: "myLabel", cssClass: "" + getclassForlabel() + "" }]
                                    ],
                                });
                            }
                        }
                    }
                    if (obj.sourceId == obj.id && obj.isAsync == false && obj.callOutType == "t") {
                        instance.connect({
                            source: obj.sourceId,
                            target: obj.id,
                            cssClass: getConncetionClass(),
                            type: basicType,
                            anchor: "Continuous",
                            // connectorStyle: connectorPaintStyle,
                            hoverPaintStyle: { stroke: "red" },
                            deleteEndpointsOnDetach: false,
                            detachable: false,
                            overlays: [
                                ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                ["Label", { label: "<div class='smallCircle'><span style='font-size:10px;'><b>" + obj.index + "</b></span></div>", id: "label", location: 0.5 }],
                                ["Label", { label: "<a style='color:black !important'>  Total Thread calls = " + obj.count + " </br>  Total Response time = " + obj.fpDuration + " ms </a>", id: "myLabel", cssClass: "" + getclassForlabel() + "" }]
                            ]
                        });
                    }
                    else if (obj.sourceId == obj.id && obj.callOutType == "t" && obj.isAsync == true) {
                        instance.connect({
                            source: obj.sourceId,
                            target: obj.id,
                            cssClass: getConncetionClass(),
                            type: basicType,
                            anchor: "Continuous",
                            // connectorStyle: connectorPaintStyle,
                            hoverPaintStyle: { stroke: "red" },
                            deleteEndpointsOnDetach: false,
                            detachable: false,
                            overlays: [
                                ["Arrow", { location: 0.3, width: 6, length: 5 }],
                                ["Arrow", { location: 0.9, width: 6, length: 5 }],
                                ["Label", { label: "<div class='smallCircle'><span style='font-size:10px;'><b>" + obj.index + "</b></span></div>", id: "label", location: 0.5 }],
                                ["Label", { label: "<a style='color:black !important'> " + getLabelForAsync(obj) + " </br> " + getLabelForThread(obj) + " </a>", id: "myLabel", cssClass: "" + getclassForlabel() + "" }]
                            ]
                        });
                    }
                    function getLabelForAsync(obj) {
                        let lab = "";
                        lab = "Total Async Calls = " + obj["AsyncCount"] + ", Total Response Time = " + obj["AsyncDur"] + " ms";
                        return lab;
                    }
                    function getLabelForThread(obj) {
                        let lab = "";
                        lab = "Total Thread Calls = " + obj["count"] + ", Total Response Time = " + obj["fpDuration"] + " ms";
                        return lab;
                    }
                    if (obj.sourceId != obj.id) {
                        //self invoked method for creating tooltip div for label of connections
                        (function tooltipMethod() {
                            let bakendPercentage = "0";
                            if (obj.backendPercentage || Number(obj.backendPercentage) == 0) {
                                if (Number(obj.backendPercentage) > 100) {
                                    bakendPercentage = '100%***';
                                }
                                else {
                                    bakendPercentage = Number(obj.backendPercentage).toFixed(1) + '%';
                                }
                            }
                            console.log("self invoked");
                            var labelID = "label" + obj.id;
                            var innerlabelid = "labela" + obj.id;
                            var divBox = "<div style=''>";
                            if (obj.backendType != 'OTHER')
                                divBox += "<b>Type: </b>" + obj.backendType + "<br/>";
                            divBox += "<b>Total Calls: </b>" + Number(obj.count).toLocaleString() + "<br/>";
                            if (obj.erCount != undefined && !isNaN(obj.erCount)) {
                                divBox += "<b>Success Calls: </b>" + Number(obj.count - obj.erCount).toLocaleString() + "<br/>";
                                divBox += "<b>Error Calls: </b>" + Number(obj.erCount).toLocaleString() + "<br/>";
                            }
                            if (obj.sourceId == "root") {
                                if (Number(Math.round(obj.avgFpDuration)) == 0)
                                    divBox += "<b>Response Time : </b> < 1 ms</span>" + "<br/>";
                                else
                                    divBox += "<b>Response Time : </b>" + Number(Math.round(obj.avgFpDuration)).toLocaleString() + " ms" + "<br/>";
                            }
                            else if (obj.callOutType == "t") //handle both cases When cumBackenduration and min is equal or not  cumBackendDuartion is max duartion
                             {
                                if (Number(obj.cumBackendDuration) == 0)
                                    divBox += "<b>Max Duration: </b>< 1 ms<br/>";
                                else
                                    divBox += "<b>Max Duration: </b>" + Number(obj.cumBackendDuration).toLocaleString() + " ms" + "<br/>";
                                if (Number(obj.min) == 0)
                                    divBox += "<b>Min Duration: </b>< 1 ms<br/>";
                                else
                                    divBox += "<b>Min Duration: </b>" + Number(obj.min).toLocaleString() + " ms" + "<br/>";
                            }
                            else if (obj.cumBackendDuration != obj.avgBackendDuration) {
                                if (Number(obj.cumBackendDuration) == 0)
                                    divBox += "<b>Total Duration: </b>< 1 ms<br/>";
                                else
                                    divBox += "<b>Total Duration: </b>" + Number(obj.cumBackendDuration).toLocaleString() + " ms" + "<br/>";
                                if (Number(obj.avgBackendDuration) == 0)
                                    divBox += "<b>Avg. Callout Time : </b>< 1 ms" + "<br/>";
                                else
                                    divBox += "<b>Avg. Callout Time : </b>" + Number(obj.avgBackendDuration).toLocaleString() + " ms" + "<br/>";
                            }
                            else {
                                if (obj.avgBackendDuration == 0)
                                    divBox += "<b>Callout Time : </b>< 1 ms" + "<br/>";
                                else
                                    divBox += "<b>Callout Time : </b>" + Number(obj.avgBackendDuration).toLocaleString() + " ms" + "<br/>";
                            }
                            //               console.log(obj.backendType+"---------------backendType----");
                            if (obj.callOutType == "T" && obj.backendType === 'HTTP') {
                                if (obj.totalNetworkDelay != "-1") {
                                    if (obj.totalNetworkDelay == 0)
                                        divBox += "<b>Total Network Delay : </b>< 1 ms<br/>";
                                    else
                                        divBox += "<b>Total Network Delay : </b>" + Number(obj.totalNetworkDelay).toLocaleString() + " ms<br/>";
                                    if (obj.totalNetworkDelay != obj.avgNetworkDelay)
                                        divBox += "<b>Avg. Network Delay : </b>" + Number(obj.avgNetworkDelay).toLocaleString() + " ms<br/>";
                                }
                            }
                            if (obj.avgBackendDuration >= 0 && obj.callOutType != "t")
                                divBox += "<b>Percentage: </b>" + bakendPercentage + "<br/>";
                            divBox += "</div>";
                            setTimeout(() => {
                                /*
                                 *getting element of overlay i.e anchor tag
                                 *appending tooltip div to anchor tag which is inside overlay div.
                                 *adding tooltip class to the anchor tag to show tooltip div on hover.
                                 */
                                var d = document.getElementById(innerlabelid);
                                d.innerHTML = d.innerHTML + divBox;
                                document.getElementById(labelID).classList.add("tooltipsforlabel");
                                /*
                                * getting parent element of anchor tag of overlay which is dynamically created by jsplumb
                                *adding event listener on overlays
                                * and adding z index to those div's on mouse enter and removing  on mose leave.
                                 */
                                let parentElement = document.getElementById(labelID).parentElement;
                                document.getElementById(parentElement.id).addEventListener("mouseenter", function setzindexofoverlays(obj) {
                                    document.getElementById(parentElement.id).style.zIndex = "22";
                                });
                                document.getElementById(parentElement.id).addEventListener("mouseleave", function setzindexofoverlaysonleave(obj) {
                                    document.getElementById(parentElement.id).style.zIndex = "19";
                                });
                            }, 0);
                        }());
                    }
                    function getConncetionClass() {
                        //if((that.flowmapData.missFPId != undefined && that.flowmapData.missFPId == obj.id && that.flowmapData.isFPMissCase != false)){
                        //    if(obj.id && obj.id.includes("e")){
                        if (obj.id) {
                            var idarr = obj.id.split('_');
                            var lastid = idarr[idarr.length - 1];
                            if (lastid.includes("e") && obj.callOutType != "t") {
                                return "redLine";
                            }
                        }
                    }
                    function getConncetionClassforAsync() {
                        return "greenLine";
                    }
                    //it returns url query in shorter tooltipStrformat
                    function geturlquery() {
                        return that.flowmapData.getTruncatedURL(obj.urlQueryParmStr);
                    }
                    //it returns the label for each connection
                    function labelForconnection() {
                        var lbl = ""; //lable for showing required info
                        var dur = "";
                        var delay = "";
                        var callLabel = "call";
                        let bakendPercentage = "0";
                        if (obj.backendPercentage || Number(obj.backendPercentage) == 0) {
                            if (Number(obj.backendPercentage) > 100) {
                                bakendPercentage = '100%***';
                            }
                            else {
                                bakendPercentage = Number(obj.backendPercentage).toFixed(1) + '%';
                            }
                        }
                        if (Number(obj.count) > 1)
                            callLabel = "calls";
                        if (obj.cumBackendDuration == obj.avgBackendDuration) // if cumulative and average time equal
                         {
                            if (Number(obj.avgBackendDuration) == 0)
                                dur = "< 1 ms";
                            else
                                dur = Number(obj.avgBackendDuration).toLocaleString() + " ms";
                        }
                        else if (obj.callOutType == "t" && obj.cumBackendDuration != obj.min) {
                            if (Number(obj.cumBackendDuration) == 0 && Number(obj.min) == 0)
                                dur = "< 1 ms , < 1 ms";
                            else
                                dur = Number(obj.cumBackendDuration).toLocaleString() + " ms" + ", " + Number(obj.min).toLocaleString() + " ms";
                        }
                        else {
                            if (Number(obj.cumBackendDuration) == 0 && Number(obj.avgBackendDuration) == 0)
                                dur = "< 1 ms , < 1 ms";
                            else
                                dur = Number(obj.cumBackendDuration).toLocaleString() + " ms" + ", " + Number(obj.avgBackendDuration).toLocaleString() + " ms";
                        }
                        if (obj.totalNetworkDelay != "-1") {
                            if (obj.totalNetworkDelay == obj.avgNetworkDelay) {
                                if (Number(obj.totalNetworkDelay) == 0)
                                    delay = ", < 1 ms";
                                else
                                    delay = ", " + Number(obj.totalNetworkDelay).toLocaleString() + " ms";
                            }
                            else
                                delay = ", " + Number(obj.avgNetworkDelay).toLocaleString() + " ms";
                        }
                        if (obj.sourceId == "root") {
                            if (Number(Math.round(obj.avgFpDuration)) == 0)
                                lbl = "< 1 ms";
                            else
                                lbl = Number(Math.round(obj.avgFpDuration)).toLocaleString() + " ms";
                        }
                        else if (obj.callOutType == "t")
                            lbl = "Thread Call (" + (obj.count).toLocaleString() + "&nbsp;" + callLabel + "), " + dur;
                        else if (obj.callOutType == "A")
                            lbl = "Async Call (" + (obj.count).toLocaleString() + "&nbsp;" + callLabel + "), " + dur;
                        else if (obj.backendType == "OTHER") {
                            if (obj.avgBackendDuration >= 0)
                                lbl = (obj.count).toLocaleString() + "&nbsp;" + callLabel + ", " + dur + " (" + bakendPercentage + ")";
                            else
                                lbl = (obj.count).toLocaleString() + "&nbsp;" + callLabel;
                        }
                        else {
                            if (obj.avgBackendDuration >= 0)
                                lbl = obj.backendType + " (" + (obj.count).toLocaleString() + "&nbsp;" + callLabel + "), " + dur + " (" + bakendPercentage + ")";
                            else
                                lbl = obj.backendType + " (" + (obj.count).toLocaleString() + "&nbsp;" + callLabel + ")";
                            //console.log("obj.backendType-------------"+obj.backendType);
                            if (obj.callOutType === "T" && obj.backendType === 'HTTP')
                                lbl += delay;
                        }
                        var queryParm;
                        if (obj.urlQueryParmStr == "-" && obj.urlQueryParamStr == undefined)
                            queryParm = "";
                        else
                            queryParm = obj.urlQueryParmStr;
                        var url;
                        if (obj.url == "-")
                            url = "";
                        else
                            // var url = trimText(queryParm, 25);
                            url = queryParm;
                        return lbl;
                    }
                    //it returns the css class name for overlays
                    function getclassForlabel() {
                        /*
                         Changes for error case, if there is one or more flowpath(s) is missing in current Trx than we will indicate it by "RedLine" in GUI.
                         RedLine will represent fp is missing, we will connect child flowpath with it grand parentfp because parent fp is missing.
                         */
                        var label;
                        if ((obj.erCount != undefined && obj.erCount > 0)) //This Check is applied for error flowpaths --|| (BTCATEGORY == "Errors" && obj.sourceId == "root")
                            return label = "redLabel";
                        else
                            return label = "greenLabel";
                    }
                    //self invoked function to return the css clas for nodes
                    (function setCss() {
                        /*
                         Changes for error case, if there is one or more flowpath(s) is missing in current Trx than we will indicate it by "RedLine" in GUI.
                         RedLine will represent fp is missing, we will connect child flowpath with it grand parentfp because parent fp is missing.
                         */
                        var label;
                        if (obj.flowPathType == "4") {
                            document.getElementById(obj.id).classList.remove("node");
                            document.getElementById(obj.id).classList.add('err-page-node');
                        }
                        if (obj.exceptionCount > 0) {
                            document.getElementById(obj.id).classList.remove("node");
                            document.getElementById(obj.id).classList.add('err-node'); //This Check is applied for error flowpaths --|| (BTCATEGORY == "Errors" && obj.sourceId == "root")
                        }
                    }());
                    //This method is used to encode HTML characters
                    function encodeHTMLStr(str) {
                        var returnString = "";
                        if (str != undefined && str != "")
                            returnString = str.toString().replace(/&#044;/g, ",").replace(/&#58;/g, ":").replace(/&#46;/g, ".").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'")
                                .replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "|").replace(/&#123;/g, "{").replace(/&#125;/g, "}").replace(/&#126;/g, "~").replace(/&#11/g, "").replace(/&#12/g, "");
                        return returnString;
                    }
                    //to replace the heading name in case of thread callout with "-" mapped name
                    that.generateNodeheading(obj);
                    //listen for clicks on connections, and offer to delete connections on click.
                    if (that.flowmapData.isFPMissCase != false) {
                        //jQuery('.tableTitle').append('<div id="fpMissDiv" style="float:right;"><img id="fpMissMsg" src="/netstorm/images/warning.png" style="height:20px;width:20px;float:left;"/></div>');
                        // console.log('values',that.flowmapData.isFPMissCase,that.flowmapData.isFpCheckMiss)
                        that.popupForFpMiss();
                    }
                    else {
                        console.log('remove the warning div as it is not required');
                        let elm = document.getElementById('missFpCase');
                        if (elm) {
                            elm.innerHTML = '';
                            elm.classList.remove("warnMesgclass");
                        }
                        //  document.getElementById('dwnldbtn1').style.top = '0px'
                        //  document.getElementById('dwnldbtn2').style.top = '0px'
                    }
                    instance.bind('click', function (conn, originalEvent) {
                        // if (confirm("Delete connection from " + conn.sourceId + " to " + conn.targetId + "?"))
                        //   instance.detach(conn);
                        // conn.toggleType("basic", basicType);
                    });
                    instance.bind('connectionDrag', function (connection) {
                        console.log('connection ' + connection.id + ' is being dragged. suspendedElement is ', connection.suspendedElement, ' of type ', connection.suspendedElementType);
                        console.log("start");
                    });
                    instance.bind('connectionDragStop', function (connection) {
                        console.log('connection ' + connection.id + ' was dragged');
                        console.log("stopped");
                    });
                    instance.bind('connectionMoved', function (params) {
                        console.log('connection ' + params.connection.id + ' was moved');
                    });
                });
                jsPlumb.fire('jsPlumbDemoLoaded', instance);
            });
            // instance.draggable(jQuery(".window"),{containment:[50,110,99999,99999]});
        });
        this.ContextMenuItems = [
            {
                label: 'DB Request Report',
                command: (event) => {
                    this.openDBReports(this.objofCurrentnode);
                }
            },
            {
                label: 'Method Timing Report',
                command: (event) => {
                    this.openMethodTimingReport(this.objofCurrentnode);
                }
            },
            {
                label: 'HotSpot Thread Details',
                command: (event) => {
                    this.openHotspotReport(this.objofCurrentnode);
                }
            },
            {
                label: 'Method Call Details',
                command: (event) => {
                    this.openMethodCallingTree(this.objofCurrentnode, undefined);
                }
            },
            {
                label: 'Current Instance Log',
                command: (event) => {
                    this.openNetForest(this.objofCurrentnode.flowpathInstance, '0', this.flowmapData.paramsForFlowMap.correlationId);
                }
            },
            {
                label: 'All Instance Log',
                command: (event) => {
                    this.openNetForest(this.objofCurrentnode.flowpathInstance, '1', this.flowmapData.paramsForFlowMap.correlationId);
                }
            },
            /*This is commented due to bug - 130500 will be supported in 4.12.0*/
            // {
            //   label: 'Show Related Graph',
            //   command: (event) => {
            //     this.openShowRelatedGraph(this.objofCurrentnode);
            //   }
            // },
            {
                label: 'Http Report',
                command: (event) => {
                    this.openHttpReport(this.objofCurrentnode);
                }
            },
        ];
        this.ContextMenuItemsForExceeption = [
            {
                label: 'DB Request Report',
                command: (event) => {
                    this.openDBReports(this.objofCurrentnode);
                }
            },
            {
                label: 'Method Timing Report',
                command: (event) => {
                    this.openMethodTimingReport(this.objofCurrentnode);
                }
            },
            {
                label: 'HotSpot Thread Details',
                command: (event) => {
                    this.openHotspotReport(this.objofCurrentnode);
                }
            },
            {
                label: 'Method Call Details',
                command: (event) => {
                    this.openMethodCallingTree(this.objofCurrentnode, undefined);
                }
            },
            {
                label: 'Exception Report',
                command: (event) => {
                    this.isFromContextMenu = true;
                    this.openExceptionReport(this.objofCurrentnode);
                }
            },
            {
                label: 'Current Instance Log',
                command: (event) => {
                    this.openNetForest(this.objofCurrentnode.flowpathInstance, '0', this.flowmapData.paramsForFlowMap.correlationId);
                }
            },
            {
                label: 'All Instance Log',
                command: (event) => {
                    this.openNetForest(this.objofCurrentnode.flowpathInstance, '1', this.flowmapData.paramsForFlowMap.correlationId);
                }
            },
            {
                label: 'Show Related Graph',
                command: (event) => {
                    this.openShowRelatedGraph(this.objofCurrentnode);
                }
            },
            {
                label: 'Http Report',
                command: (event) => {
                    this.openHttpReport(this.objofCurrentnode);
                }
            },
        ];
        this.flowmapData.getNetForestLink();
    }
    //to show tooltip on node on mouse enter
    ShowtooltiponHover(name) {
        document.getElementById(name.id).style.zIndex = "22";
        this.tooltipForNodes = this.fortooltipofNode(name);
    }
    //to remove tooltip on mouse leave from node
    removeTooltip(name) {
        console.log('this.conted = ', this.contextRef);
        this.isTooltip = false;
        document.getElementById(name.id).style.zIndex = "20";
    }
    //it creates the tooltip div for nodes
    fortooltipofNode(obj) {
        var i = obj.mergedArrayIndex;
        var tooltipStr = "";
        var node = "";
        var nodeColor = "node";
        if (obj.flowPathType == "4")
            nodeColor = "err-page-node";
        if (obj.exceptionCount > 0)
            nodeColor = "err-node";
        var strEndTime = Number(obj.startTimeInMs) + Number(obj.fpDuration);
        if (obj.tierName != '-') {
            tooltipStr += "<b>Tier:</b>&nbsp;" + obj.tierName + "<br/><b>Server</b>:&nbsp;" + obj.serverName + "<br/><b>Instance:</b>&nbsp;" + obj.appName + "<br/> <b>Start Time:</b>&nbsp;" + obj.startDateTime;
            if (obj.cumFpDuration != obj.avgFpDuration) {
                //  node += "<div id='" + obj.id + "' class='" + nodeColor + " window' style='top:" + obj.top + "px; left:" + obj.left + "px;' ondblclick=openPopupTable('" + obj.key + "','" + obj.backendType + "','" + obj.depth + "','" + obj.urlName + "','" + obj.sourceId + "','" + obj.instanceType + "','" + obj.urlIndex + "','" + obj.id + "')>";
                if (Number(obj.cumFpDuration) == 0)
                    tooltipStr += "<br/><img src='./assets/images/response_legend.png' class='nodeIcon' >&nbsp;<b>Total Duration:</b>&nbsp; < 1 ms <br/><img src='./assets/images/cumulative.png' width='16' height='16' class='nodeIcon' >&nbsp;<b>Avg.Duration:</b>&nbsp;< 1 ms";
                else
                    tooltipStr += "<br/><img src='./assets/images/response_legend.png' class='nodeIcon' >&nbsp;<b>Total Duration:</b>&nbsp;" + Number(obj.cumFpDuration).toLocaleString() + "ms" + "<br/><img src='./assets/images/cumulative.png'  width='16' height='16'  class='nodeIcon' >&nbsp;<b>Avg.Duration:</b>&nbsp;" + Number(obj.avgFpDuration).toLocaleString() + " ";
            }
            else {
                // node += "<div id='" + obj.id + "' class='" + nodeColor + " window' style='top:" + obj.top + "px; left:" + obj.left + "px;'    ondblclick=openPopupTable('" + obj.key + "','" + obj.backendType + "','" + obj.depth + "','" + obj.urlName + "','" + obj.sourceId + "','" + obj.instanceType + "','" + obj.urlIndex + "','" + obj.id + "')>";
                if (Number(obj.avgFpDuration) == 0)
                    tooltipStr += "<br/><img src='./assets/images/response_legend.png' class='nodeIcon' >&nbsp;<b>Total Duration:</b>&nbsp;< 1 ms";
                else
                    tooltipStr += "<br/><img src='./assets/images/response_legend.png' class='nodeIcon' >&nbsp;<b>Total Duration:</b>&nbsp;" + Number(obj.avgFpDuration).toLocaleString() + "ms";
            }
            tooltipStr += "<br/><b>Percentage:</b>&nbsp;" + Number(obj.percentage).toFixed(1) + " %";
        }
        else if ((obj.id).startsWith("queue")) {
            // node += "<div id='" + obj.id + "' class='node window' style='top:" + obj.top + "px; left:" + obj.left + "px;'>";
            if (obj.mappedAppName != this.encodeHTMLStr(obj.backendActualName)) {
                tooltipStr += "<b>Name:</b>&nbsp;" + obj.mappedAppName + "(" + obj.backendActualName + ")";
            }
            else {
                tooltipStr += "<b>Name:</b>&nbsp;" + obj.backendActualName;
            }
        }
        else {
            // node += "<div id='" + obj.id + "' class='" + nodeColor + " window' style='top:" + obj.top + "px; left:" + obj.left + "px;' ondblclick=openPopupTable('" + obj.key + "','" + obj.backendType + "','" + obj.depth + "','" + obj.url + "','" + obj.sourceId + "','" + obj.instanceType + "','" + obj.urlIndex + "','" + obj.id + "')>";
            if (obj.mappedAppName != this.encodeHTMLStr(obj.backendActualName) && obj.mappedAppName != '-') {
                //node += "<div id='"+obj.id+"' class='node window' style='top:"+obj.top+"px; left:"+obj.left+"px;'  ondblclick=openPopupTable('"+obj.key+"','"+obj.backendType+"','"+obj.depth+"','"+obj.url+"','"+sourceId+"','"+obj.instanceType+"','"+obj.urlIndex+"','"+obj.id+"')>";
                tooltipStr += "<b>Name:</b>&nbsp;" + obj.mappedAppName + "(" + obj.backendActualName + ")";
            }
            else if (obj.mappedAppName == '-') {
                console.log('coming for tool tip', obj);
                let objForReplacement;
                this.dataToDraw.forEach((val, index) => {
                    if (val.id == obj.sourceId) {
                        objForReplacement = this.dataToDraw[index];
                    }
                });
                tooltipStr += "<b>Tier:</b>&nbsp;" + objForReplacement.tierName + "<br/><b>Server</b>:&nbsp;" + objForReplacement.serverName + "<br/><b>Instance:</b>&nbsp;" + objForReplacement.appName + "<br/>";
            }
            else {
                // node += "<div id='"+obj.id+"' class='node window' style='top:"+obj.top+"px; left:"+obj.left+"px;' ondblclick=openPopupTable('"+obj.key+"','"+obj.backendType+"','"+obj.depth+"','"+obj.url+"','"+sourceId+"','"+obj.instanceType+"','"+obj.urlIndex+"','"+obj.id+"')>";
                tooltipStr += "<b>Name:</b>&nbsp;" + obj.backendActualName;
            }
        }
        return tooltipStr;
    }
    //This method is used to encode HTML characters
    encodeHTMLStr(str) {
        var returnString = "";
        if (str != undefined && str != "")
            returnString = str.toString().replace(/&#044;/g, ",").replace(/&#58;/g, ":").replace(/&#46;/g, ".").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'")
                .replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "|").replace(/&#123;/g, "{").replace(/&#125;/g, "}").replace(/&#126;/g, "~").replace(/&#11/g, "").replace(/&#12/g, "");
        return returnString;
    }
    // headingForNodes: string = "";
    generateNodeheading(obj) {
        if (obj.mappedAppName != this.encodeHTMLStr(obj.backendActualName) && obj.mappedAppName != '-') {
            //do nothing
            return;
        }
        else if (obj.mappedAppName == '-') {
            let objForReplacement;
            this.dataToDraw.forEach((val, index) => {
                if (val.id == obj.sourceId) {
                    objForReplacement = this.dataToDraw[index];
                }
            });
            //this is to replace  the  the heading of node in this specila case
            let parentElement = document.getElementById(obj.id);
            let headingElemnet = parentElement.lastElementChild;
            headingElemnet.innerHTML = "<div class='nodeRight'>" + "<div style='text-align: center;color: #0c5207;font-weight: bold;font-size: 10px;padding-top: 11px;width: 185px;height:20px;'> " + objForReplacement.serverName + ":" + objForReplacement.mappedAppName + "</div>" + "<div style='text-align: center;margin-top:6px;font-size: 10px;width:183px;'>" + "</div></div>";
        }
        else {
            return;
        }
    }
    ;
    trimTextForLarge(text) {
        try {
            if (text.length > 12)
                text = text.substring(0, 12) + "..";
            return text;
        }
        catch (err) {
            return "";
        }
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName;
        if (this._ddrData.isFromtrxFlow) {
            hostDcName = "//" + this._ddrData.hostTr + ":" + this._ddrData.portTr;
            this.urlParam.testRun = this._ddrData.testRunTr;
            //   return hostDCName;
        }
        else if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
            // if (this._navService.getDCNameForScreen("trxFlow") === undefined)
            //   hostDcName = this._cavConfigService.getINSPrefix();
            // else
            //   hostDcName = this._cavConfigService.getINSPrefix() + this._navService.getDCNameForScreen("trxFlow");
            // if (hostDcName.length > 0) {
            //   sessionStorage.removeItem("hostDcName");
            //   sessionStorage.setItem("hostDcName", hostDcName);
            // }
            // else
            //   hostDcName = sessionStorage.getItem("hostDcName");
        }
        console.log('hostDcName =', hostDcName);
        return hostDcName;
    }
    /* Auto Instrumentation DDAI */
    openAutoInstDialog() {
        console.log('this.flowmapData.paramsForFlowMap>>>>>>>>>>>>****', this.flowmapData.paramsForFlowMap);
        let testRunStatus;
        let instanceType;
        let url = this.getHostUrl() + '/' + this.urlParam.product + '/v1/cavisson/netdiagnostics/ddr/getTestRunStatus?testRun=' + this.urlParam.testRun;
        //console.log('url *** ', url);
        this.ddrRequest.getDataUsingGet(url).subscribe(res => {
            // console.log("data for tr status === " , res);
            testRunStatus = res;
            testRunStatus = testRunStatus.data;
            if (testRunStatus.length != 0) {
                this.showAutoInstrPopUp = true;
                if (this.flowmapData.paramsForFlowMap.Instance_Type.toLowerCase() == 'java')
                    instanceType = 'Java';
                else if (this.flowmapData.paramsForFlowMap.Instance_Type.toLowerCase() == 'dotnet')
                    instanceType = 'DotNet';
                else if (this.flowmapData.paramsForFlowMap.Instance_Type.toLowerCase() == 'dotnetc')
                    instanceType = 'DotNetC';
                this.argsForAIDDSetting = [this.flowmapData.paramsForFlowMap.appName, this.flowmapData.paramsForFlowMap.appId, instanceType, this.flowmapData.paramsForFlowMap.tierName,
                    this.flowmapData.paramsForFlowMap.serverName, this.flowmapData.paramsForFlowMap.serverId, "-1", this.flowmapData.paramsForFlowMap.urlName, "DDR", testRunStatus[0].status, this.urlParam.testRun];
                console.log('this.argsForAIDDSetting>>>>>>>>>>>>****', this.argsForAIDDSetting);
            }
            else {
                this.showAutoInstrPopUp = false;
                alert("Could not start instrumentation, test is not running");
                return;
            }
        });
    }
    startInstrumentation(result) {
        this.showAutoInstrPopUp = false;
        alert(result);
    }
    closeAIDDDialog(isCloseAIDDDialog) {
        this.showAutoInstrPopUp = isCloseAIDDDialog;
    }
    createColumnArray(...argument) {
        let columnobj = [];
        for (let i = 0; i < argument.length; i++) {
            columnobj[i] = { field: argument[i], header: this.returnHeader(argument[i]), Width: this.colWidth, colAlignment: this.colAlignment, sortable: this.sortable, action: this.returnAction(argument[i]) };
        }
        console.log(columnobj);
        return columnobj;
    }
    //to dispaly the table on db click on nodes
    showDialogTable(obj) {
        this.drilInfoData = obj;
        this.popupFilter = '';
        this.popupFooter = '';
        this.popupTitle = ' ';
        this.CommonServices.loaderForDdr = true;
        let objForTable = obj;
        this.objofCurrentnode = obj;
        this.transactionTableArray = [];
        this.popupTitle = "";
        //jsonData = this.flowmapData.jsondataforTable;
        //var backendInfo = this.nodeTabledataService.getSourceDetails(obj.sourceId, obj.passedURL, obj.urlIndex, obj.id);
        //this.nodeTabledataService.showPopupFilters(backendInfo);
        let backENDType = this.flowmapData.getBackendType(obj.key, obj.backendType);
        let columns = [];
        this.col = this.createColumnArray('URL', 'Min', 'Max', 'Average', 'Count');
        let statusCodeIndex;
        console.log("backENDType", backENDType, obj.instanceType, obj.backend);
        this.showClipboard = false;
        if (backENDType == 3 || backENDType == 6) //3-coherence 5-memcache 6-cloudant
         {
            this.col = this.createColumnArray('Call', 'Min', 'Max', 'Average', 'Count');
            statusCodeIndex = -1;
            this.popupTitle = "Coherence Call Stats";
        }
        else if (backENDType == 5) //5-memcache
         {
            this.col = this.createColumnArray('Call', 'Min', 'Max', 'Average', 'Count');
            statusCodeIndex = -1;
            this.popupTitle = "Memcache Call Stats";
        }
        else if (backENDType == 2 || backENDType == 10 || backENDType == 15 || backENDType == 16 || backENDType == 18 || backENDType == 19 || backENDType == 25) {
            this.col = this.createColumnArray('Query', 'Min', 'Max', 'Average', 'Count', 'ExecutionTime', 'errorCount', 'totalTime');
            // console.log("db columnnn",this.col);
            statusCodeIndex = 8;
            this.showClipboard = true;
            this.popupTitle = "DB Requests";
        }
        else if (backENDType == 22) {
            this.col = this.createColumnArray('Command', 'Min', 'Max', 'Average', 'Count', 'ExecutionTime', 'errorCount', 'statusCODE');
            // console.log("db columnnn",this.col);
            statusCodeIndex = 7;
            this.popupTitle = "FTP Commands";
        }
        else if (backENDType == 9) {
            this.col = this.createColumnArray('Query', 'Min', 'Max', 'Average', 'Count', 'errorCount');
            statusCodeIndex = 6;
            this.popupTitle = "Cassandra DB Request Tracing";
        }
        else if (obj.instanceType == 'backend' && obj.backendType == 'HTTP') {
            this.col = this.createColumnArray('URL', 'Min', 'Max', 'Average', 'Count', 'errorCount', 'statusCODE');
            statusCodeIndex = 6;
            this.popupTitle = "Call Stats";
        }
        else if (obj.instanceType == 'backend' || backENDType == 23 || backENDType == 24 || backENDType == 26 || backENDType == 11 || backENDType == 12 || backENDType == 13 || backENDType == 14) {
            this.col = this.createColumnArray('Min', 'Max', 'Average', 'Count', 'errorCount', 'stat0usCODE');
            statusCodeIndex = 5;
            this.popupTitle = "Call Stats";
        }
        /* else if(queueName != undefined)  //jms queues
         {
            this.col = ['URL','StartTime','Duration','FPInstance','CorrID','CpuTime','errorCount','statusCODE'];
                statusCodeIndex = 7;
        }*/
        else if (backENDType == 1 || obj.passedurl != '-') {
            this.col = this.createColumnArray('URL', 'StartTime', 'Duration', 'FPInstance', 'CorrID', 'CpuTime', 'errorCount', 'statusCODE', 'gcpause', 'Action');
            statusCodeIndex = 7;
            this.popupTitle = "Transaction Tracing Detail";
            //jQuery("#ui-dialog-title-popupTable").html("<b>FlowPaths</b>");
        }
        else {
            this.col = this.createColumnArray('backendType', 'backendSubType', 'Min', 'Max', 'Average', 'Count');
            this.popupTitle = "Transaction Tracing Detail";
        }
        let urlDb = sessionStorage.getItem('ipWithProd');
        var flag = 0;
        this.nodeTabledataService.getIndividualGroupedInfo(obj.backendType, obj.depth, obj.key, this.flowmapData.transactionDataList, sessionStorage.getItem('dashboardTestRun'), this.flowmapData.hosturl || urlDb)
            .then((json) => {
            console.log("getIndividualGroupedInfo", JSON.stringify(json));
            if (backENDType == 23 || backENDType == 24 || backENDType == 26 || backENDType == 11 || backENDType == 12 || backENDType == 13 || backENDType == 14) {
                json = json.splice(0, 1);
            }
            var data = [];
            if (!JSON.stringify(json).includes("gcpause")) {
                this.col.splice(8, 1);
            }
            for (let j = 0; j < json.length; j++) {
                /*  if(json[j].url && json[j].url.startsWith("JMSC")){
                    json[j].url = json[j].url.substring(5,json[j].url.length);
                    json[j].urlQueryParmStr = json[j].urlQueryParmStr.substring(5,json[j].urlQueryParmStr.length);
                    console.log(" json[j].url " ,json[j].url)
                  }
                  else if(json[j].urlName && json[j].urlName.startsWith("JMSC")){
                    json[j].urlName = json[j].urlName.substring(5,json[j].urlName.length);
                    json[j].urlQueryParmStr = json[j].urlQueryParmStr.substring(5,json[j].urlQueryParmStr.length);
                    console.log(" json[j].urlName " ,json[j].urlName)
                  } */
                if (json[j].statusCODE != "" && json[j].statusCODE != undefined && json[j].statusCODE != "-" && json[j].statusCODE != "0" && json[j].statusCODE != "NaN")
                    flag = flag + 1;
                var obj = {};
                obj['ExecutionTime'] = (json[j].avg * json[j].count).toFixed(2);
                if (json[j].min < 0)
                    json[j].min = 0;
                if (json[j].max < 0)
                    json[j].max = 0;
                if (json[j].avg < 0)
                    json[j].avg = 0;
                if (json[j].flowPathInstance < 0)
                    json[j].flowPathInstance = 0;
                if (backENDType == 3 || backENDType == 5 || backENDType == 6) {
                    if (isNaN(Number(json[j].avg))) {
                        continue;
                    }
                    if (json[j].backendSubType == "") {
                        obj['Call'] = +json[j].backendSubType + "'>" + "get0() or fetch0()";
                    }
                    else
                        obj['Call'] = json[j].backendSubType;
                    obj['Min'] = json[j].min;
                    obj['Max'] = json[j].max;
                    obj['Average'] = Number(json[j].avg).toFixed(2);
                    if (json[j].count != undefined)
                        obj['Count'] = json[j].count.toLocaleString();
                    data.push(obj);
                    this.popupFooter = 'Minimu Execution Time = ' + json[j].min;
                    this.popupFilter = '';
                }
                else if (backENDType == 2 || backENDType == 10 || backENDType == 15 || backENDType == 16 || backENDType == 18 || backENDType == 19 || backENDType == 25) {
                    obj['Query'] = json[j].backendQuery;
                    obj['Min'] = json[j].min;
                    obj['Max'] = json[j].max;
                    obj['Average'] = Number(json[j].avg).toFixed(2);
                    /*if(json[j].backendName !=undefined )
                   obj.Backend = "<span  title = '"+json[j].backendName+"'>"+json[j].backendName+"</span>";*/
                    if (json[j].count != undefined)
                        obj['Count'] = json[j].count.toLocaleString();
                    if (json[j].errorCount > 0 && json[j].errorCount != undefined)
                        obj['errorCount'] = Number(json[j].errorCount);
                    else
                        obj['errorCount'] = " 0";
                    obj['statusCODE'] = json[j].statusCODE;
                    obj['totalTime'] = (Number(json[j].avg) * Number(json[j].count)).toFixed(2);
                    console.log(obj);
                    data.push(obj);
                    if (j == 0)
                        this.popupFooter = 'Query : ' + json[j].backendQuery;
                    this.popupFilter = '';
                }
                else if (backENDType == 22) {
                    obj['Command'] = json[j].backendQuery;
                    obj['Min'] = json[j].min;
                    obj['Max'] = json[j].max;
                    obj['Average'] = Number(json[j].avg).toFixed(2);
                    /*if(json[j].backendName !=undefined )
                   obj.Backend = "<span  title = '"+json[j].backendName+"'>"+json[j].backendName+"</span>";*/
                    if (json[j].count != undefined)
                        obj['Count'] = json[j].count.toLocaleString();
                    if (json[j].errorCount > 0 && json[j].errorCount != undefined)
                        obj['errorCount'] = Number(json[j].errorCount);
                    else
                        obj['errorCount'] = " 0";
                    obj['statusCODE'] = json[j].statusCODE;
                    console.log(obj);
                    data.push(obj);
                    if (j == 0)
                        this.popupFooter = 'Command : ' + json[j].backendQuery;
                    this.popupFilter = '';
                }
                else if (backENDType == 9) {
                    obj['Query'] = json[j].backendQuery;
                    obj['Min'] = json[j].min;
                    obj['Max'] = json[j].max;
                    obj['Average'] = Number(json[j].avg).toFixed(2);
                    obj['Count'] = json[j].count;
                    if (json[j].errorCount > 0 && json[j].errorCount != undefined)
                        obj['errorCount'] = Number(json[j].errorCount);
                    else
                        obj['errorCount'] = "0";
                    obj['statusCODE'] = json[j].statusCODE;
                    data.push(obj);
                    if (j == 0)
                        this.popupFooter = 'Query : ' + json[j].backendQuery;
                    this.popupFilter = '';
                }
                else if (objForTable.instanceType == 'backend' && backENDType == 1) {
                    obj['URL'] = json[j].resourceName;
                    obj['Min'] = json[j].min;
                    obj['Max'] = json[j].max;
                    obj['Average'] = Number(json[j].avg).toFixed(2);
                    /*if(json[j].backendName !=undefined )
                   obj.Backend = "<span title = '"+json[j].backendName+"'>"+json[j].backendName+"</span>";*/
                    obj['Count'] = json[j].count;
                    if (json[j].errorCount > 0 && json[j].errorCount != undefined)
                        obj['errorCount'] = Number(json[j].errorCount);
                    else
                        obj['errorCount'] = "0";
                    obj['statusCODE'] = json[j].statusCODE;
                    data.push(obj);
                    if (j == 0 && json[j].resourceName != '-') {
                        this.popupFooter = 'URL = ' + json[j].resourceName;
                    }
                    else if (j == 0) {
                        this.popupFooter = 'Minimum Execution Time = ' + json[j].min;
                    }
                    this.setpopupFilter();
                }
                else if (objForTable.instanceType == 'backend' || backENDType == 23 || backENDType == 24 || backENDType == 26 || backENDType == 11 || backENDType == 12 || backENDType == 13 || backENDType == 14) {
                    obj['Min'] = json[j].min;
                    obj['Max'] = json[j].max;
                    obj['Average'] = Number(json[j].avg).toFixed(2);
                    /*if(json[j].backendName !=undefined )
                   obj.Backend = "<span title = '"+json[j].backendName+"'>"+json[j].backendName+"</span>";*/
                    obj['Count'] = json[j].count;
                    if (json[j].errorCount > 0 && json[j].errorCount != undefined)
                        obj['errorCount'] = Number(json[j].errorCount);
                    else
                        obj['errorCount'] = "0";
                    obj['statusCODE'] = json[j].statusCODE;
                    data.push(obj);
                    if (j == 0)
                        this.popupFooter = 'Minimum Execution Time = ' + json[j].min;
                    this.setpopupFilter();
                }
                /* else if( queueName != undefined)
                 {
                      popupTitle = "<b>Queue:&nbsp&nbsp</b>" +queueName ;
      
                      obj.URL = "<span  title = '"+json[j].URL+"'>"+json[j].URL+"</span>";
                       if(json[j].min != undefined && json[j].min != "")
                        obj.Min = Number(json[j].min);
                       if(json[j].max != undefined && json[j].max != "")
                        obj.Max = Number(json[j].max).toLocaleString();
                        obj.Average=Number(json[j].avg).toFixed(2);
      
                        obj.FPInstance = json[j].flowPathInstance;
                        obj.StartTime = json[j].startTime;
                        obj.Duration = json[j].fpDuration.toLocaleString();
                        obj.CorrID = json[j].correlationid;
                        obj.CpuTime = Math.round(json[j].btcputime);
                        obj.URL = "<span  title = '"+json[j].urlQueryParmStr+"'>"+json[j].urlQueryParmStr+"</span>";
                        var strEndTime = Number(json[j].startTimeInMs) + Number(json[j].fpDuration);
      
                        if(json[j].errorCount > 0 && json[j].errorCount != undefined)
                          obj.errorCount= Number(json[j].errorCount).toLocaleString();
                        else
                         obj.errorCount="0&nbsp;";
      
                        if(json[j].count != undefined && json[j].count != "" )
                          obj.Count =Number(json[j].count).toLocaleString();
                        data.push(obj);
                     } */
                else if (backENDType == 1 || objForTable.passedURL != '-') {
                    this.popupTitle = "FlowPaths " + "( " + "Tier: " + json[j].tierName + ", " + "Server: " + json[j].serverName + ", " + "Instance : " + json[j].appName + " )";
                    // jQuery("#ui-dialog-title-popupTable").html("<b>FlowPaths&nbsp&nbsp</b>" +"( " +"<b>Tier: </b>" +json[j].tierName + "<b>&nbsp&nbspServer: </b>"+json[j].serverName +"<b>&nbsp&nbspInstance : </b>" +json[j].appName +" )");
                    obj['URL'] = json[j].url;
                    if (json[j].min != undefined && json[j].min != "")
                        obj['Min'] = Number(json[j].min);
                    if (json[j].max != undefined && json[j].max != "")
                        obj['Max'] = Number(json[j].max).toLocaleString();
                    obj['Average'] = Number(json[j].avg).toFixed(2);
                    /*  obj.Tier = json[j].tierName;
                     obj.Server = json[j].serverName;
                     obj.Instance = json[j].appName; */
                    obj['FPInstance'] = json[j].flowPathInstance;
                    obj['StartTime'] = json[j].startTime;
                    obj['Duration'] = json[j].fpDuration.toLocaleString();
                    if (json[j].gcpause == "1")
                        obj['gcpause'] = "Yes";
                    else
                        obj['gcpause'] = "No";
                    if (json[j].correlationid != undefined)
                        obj['CorrID'] = json[j].correlationid;
                    else
                        obj['CorrID'] = "-";
                    obj['CpuTime'] = Math.round(json[j].btcputime);
                    obj['URL'] = json[j].urlQueryParmStr;
                    var strEndTime = Number(json[j].startTimeInMs) + Number(json[j].fpDuration);
                    if (json[j].errorCount > 0 && json[j].errorCount != undefined)
                        obj['errorCount'] = Number(json[j].errorCount);
                    else
                        obj['errorCount'] = "0";
                    obj['statusCODE'] = json[j].statusCODE;
                    data.push(obj);
                    if (j == 0)
                        this.popupFooter = 'URL = ' + json[j].url;
                    this.popupFilter = '';
                }
                else {
                    //col = ['BackendType', 'BackendSubType', 'Min','Max', 'Average', 'Count'];
                    obj['BackendType'] = json[j].backendType + "'>" + json[j].backendType;
                    if (json[j].backendSubType != undefined)
                        obj['BackendSubType'] = json[j].backendSubType + "'>" + json[j].backendSubType;
                    obj['Min'] = json[j].min;
                    obj['Max'] = json[j].max;
                    obj['Average'] = Number(json[j].avg).toFixed(2);
                    /*if(json[j].backendName !=undefined )
                      obj.Backend = "<span title = '"+json[j].backendName+"'>"+json[j].backendName+"</span>";*/
                    obj['Count'] = json[j].count;
                    data.push(obj);
                    if (j == 0)
                        this.popupFooter = 'Minimum Execution Time = ' + json[j].min;
                    this.popupFilter = '';
                }
            }
            if (flag == 0 && statusCodeIndex != -1) {
                this.col.splice(statusCodeIndex, 1);
            }
            if (data[0] != undefined && data[0].FPInstance != undefined)
                this.col.splice(3, 3);
            this.tableDialogDisplay = true;
            this.tableDialogDisplay1 = false;
            this.singleMergeGraph = false;
            this.displaySamplePopup = false;
            this.dbCalloutDetails = data;
            setTimeout(() => {
                console.log("data for table", this.col, data);
                this.createTable(this.col, data);
            }, 200);
        });
        this.CommonServices.loaderForDdr = false;
    }
    returnHeader(col) {
        if (col == 'Min' || col == 'Max') {
            col = col + " (ms)"; //Name to be displayed as header
            this.colWidth = "60";
            this.colAlignment = "right";
            this.sortable = "true";
        }
        else if (col == 'ExecutionTime') {
            col = "Execution Time (ms)"; //Name to be displayed as header
            this.colWidth = "90";
            this.colAlignment = "right";
            this.sortable = "custom";
            // this.sortField = "ExecutionTime";
        }
        else if (col == 'Average') {
            col = col + " (ms)"; //Name to be displayed as header
            this.colWidth = "65";
            this.colAlignment = "right";
            this.sortable = "custom";
            this.sortField = "Average";
        }
        else if (col == 'Count') {
            col = "count(s)"; //Name to be displayed as header
            this.colWidth = "50";
            this.colAlignment = "right";
            this.sortable = "custom";
            //   this.sortField = "Count";
        }
        else if (col == 'call') {
            col = "Call Type"; //Name to be displayed as header
            this.colWidth = "50";
            this.sortable = "true";
        }
        else if (col == 'Query') {
            col = "Query   "; //Name to be displayed as header
            this.colWidth = "255";
            this.colAlignment = "left";
            this.sortable = "false";
        }
        else if (col == 'Command') {
            col = "Command   "; //Name to be displayed as header
            this.colWidth = "240";
            this.colAlignment = "left";
            this.sortable = "false";
        }
        else if (col == 'gcpause') {
            col = "GC Pause"; //Name to be displayed as header
            this.colWidth = "30";
            this.colAlignment = "right";
            this.sortable = "custom";
            //   this.sortField = "Count";
        }
        /*  else if(col == 'Tier')
         {
        col = "Tier";//Name to be displayed as header
         this.colWidth = 200;
         }
         else if(col == 'Server')
         {
        col = "Server";//Name to be displayed as header
         this.colWidth = 200;
         }
         else if(col == 'Instance')
         {
        col = "Instance";//Name to be displayed as header
         this.colWidth = 200;
         } */
        else if (col == 'FPInstance') {
            col = "Flowpath ID"; //Name to be displayed as header
            this.colWidth = "105";
            this.colAlignment = "left";
            this.sortable = "true";
        }
        else if (col == 'Duration') {
            col = "Duration(ms)"; //Name to be displayed as header
            this.colWidth = "70";
            this.colAlignment = "right";
            this.sortable = "true";
            // this.sortField = "Duration";
        }
        else if (col == 'StartTime') {
            col = "Start Time"; //Name to be displayed as header
            this.colWidth = "100";
            this.sortable = "custom";
        }
        else if (col == 'URL') {
            col = "url"; //Name to be displayed as header
            this.colWidth = "200";
            this.colAlignment = "left";
            this.sortable = "true";
        }
        else if (col == 'CpuTime') {
            col = "CPU Time(ms)"; //Name to be displayed as header
            this.colWidth = "64";
            this.colAlignment = "right";
            this.sortable = "true";
        }
        else if (col == 'CorrID') {
            col = "CorrID"; //Name to be displayed as header
            this.colWidth = "90";
            this.sortable = "true";
        }
        else if (col == 'Action') {
            col = "Action"; //Name to be displayed as header
            this.colWidth = "70";
            this.sortable = "false";
        }
        else if (col == 'errorCount') {
            col = "Error Count(s)"; //Name to be displayed as header
            this.colWidth = "75";
            this.sortable = "true";
        }
        else if (col == 'statusCODE') {
            col = "Status Code(s)"; //Name to be displayed as header
            this.colWidth = "70";
            this.sortable = "true";
        }
        else if (col == 'BackendSubType') {
            // if (json[0].backendSubType != undefined)
            //    col = "Backend Sub Type";
        }
        else if (col == 'totalTime') {
            col = 'Total Time(ms)'; //Name to be displayed as header
            this.colWidth = "90";
            this.sortable = "custom";
        }
        else {
            col = col; //Name to be displayed as header
            this.colWidth = "90";
            this.sortable = "false";
        }
        return col;
    }
    createTable(columns, data) {
        for (let i = 0; i < data.length; i++) {
            this.transactionTableArray = this.Immutablepush(this.transactionTableArray, data[i]);
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    showHeaderInfo(val) {
        this.labelNode = '';
        if (val.fpDuration || Number(val.avgFpDuration) === 0) {
            let fpDuration = val.fpDuration;
            // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
            let startDateTime = this.sessionService.convertTimestampIntoFormattedString(Number(val.startTimeInMs), "MM/DD/YYYY HH:mm:ss");
            if (val.avgFpDuration != this.flowmapData.paramsForFlowMap.fpDuration.toString().replace(/,/g, '')) {
                if (Number(this.flowmapData.paramsForFlowMap.fpDuration.toString().replace(/,/g, '')) == 0) {
                    this.labelNode = "<b>Tier=</b>" + val.tierName + ",&nbsp;<b>Server=</b>" + val.serverName + ",&nbsp;<b>Instance=</b>" + val.appName + ",&nbsp;<b>BT Type=</b>" + this.getBTCategory(this.flowmapData.paramsForFlowMap.btCatagory) + ",&nbsp;<b>Start Time=</b>" + startDateTime + ",&nbsp;<b>Response Time=</b>< 1(ms) ,&nbsp;<b>Entry Response Time=</b>< 1(ms) </label>";
                    this.headerInfo = "Tier=" + val.tierName + ", Server=" + val.serverName + ", Instance=" + val.appName + ", BT Type=" + this.getBTCategory(this.flowmapData.paramsForFlowMap.btCatagory) + ", Start Time=" + startDateTime + ", Response Time=< 1(ms), Entry Response Time=< 1(ms)";
                }
                else {
                    this.labelNode = "<b>Tier=</b>" + val.tierName + ",&nbsp;<b>Server=</b>" + val.serverName + ",&nbsp;<b>Instance=</b>" + val.appName + ",&nbsp;<b>BT Type=</b>" + this.getBTCategory(this.flowmapData.paramsForFlowMap.btCatagory) + ",&nbsp;<b>Start Time=</b>" + startDateTime + ",&nbsp;<b>Response Time=</b>" + Number(val.selfResponseTime).toLocaleString() + "&nbsp;(ms) ,&nbsp;<b>Entry Response Time=</b>" + Number(Math.round(val.avgFpDuration)).toLocaleString() + "&nbsp;(ms) </label>";
                    this.headerInfo = "Tier=" + val.tierName + ", Server=" + val.serverName + ", Instance=" + val.appName + ", BT Type=" + this.getBTCategory(this.flowmapData.paramsForFlowMap.btCatagory) + ", Start Time=" + startDateTime + ", Response Time=" + Number(val.selfResponseTime).toLocaleString() + "(ms), Entry Response Time=" + Number(Math.round(val.avgFpDuration)).toLocaleString() + "(ms)";
                }
            }
            else {
                if (Number(val.avgFpDuration) == 0) {
                    this.labelNode = "<b>Tier=</b>" + val.tierName + ",&nbsp<b>;Server=</b>" + val.serverName + ",&nbsp;<b>Instance=</b>" + val.appName + ",&nbsp;<b>BT Type=</b>" + this.getBTCategory(this.flowmapData.paramsForFlowMap.btCatagory) + ",&nbsp;<b>Start Time=</b>" + startDateTime + ",&nbsp;<b>Response Time=</b>< 1(ms) </label>";
                    this.headerInfo = "Tier=" + val.tierName + ", Server=" + val.serverName + ", Instance=" + val.appName + ", BT Type=" + this.getBTCategory(this.flowmapData.paramsForFlowMap.btCatagory) + ", Start Time=" + startDateTime + ", Response Time=< 1(ms)";
                }
                else {
                    this.labelNode = "<b>Tier=</b>" + val.tierName + ",&nbsp;<b>Server=</b>" + val.serverName + ",&nbsp;<b>Instance=</b>" + val.appName + ",&nbsp;<b>BT Type=</b>" + this.getBTCategory(this.flowmapData.paramsForFlowMap.btCatagory) + ",&nbsp;<b>Start Time=</b>" + startDateTime + ",&nbsp;<b>Response Time=</b>" + Number(val.selfResponseTime).toLocaleString() + "(ms) </label>";
                    this.headerInfo = "Tier=" + val.tierName + ", Server=" + val.serverName + ", Instance=" + val.appName + ", BT Type=" + this.getBTCategory(this.flowmapData.paramsForFlowMap.btCatagory) + ", Start Time=" + startDateTime + ", Response Time=" + Number(val.selfResponseTime).toLocaleString() + "(ms)";
                }
            }
            setTimeout(() => {
                var d = document.getElementById('forFilter');
                d.innerHTML = this.labelNode;
            }, 400);
            return true;
        }
        else
            return false;
    }
    getBTCategory(category) {
        if (category === '12') {
            category = 'Very Slow';
        }
        if (category === '11') {
            category = 'Slow';
        }
        if (category === '10') {
            category = 'Normal';
        }
        if (category === '13') {
            category = 'Errors';
        }
        if (category === '0') {
            category = 'Other';
        }
        return category;
    }
    ResponseFormatter(resTime) {
        if (Number(resTime) && Number(resTime) > 0) {
            return Number(resTime).toLocaleString();
        }
        if (Number(resTime) == 0) {
            return '< 1';
        }
        else {
            return resTime;
        }
    }
    returnAction(fieldName) {
        if (fieldName == 'Action') {
            return true;
        }
        else {
            return false;
        }
    }
    /**
     * Method to Show Related Graph
     */
    openShowRelatedGraph(objForRouting) {
        console.log('rowData-->', objForRouting, '----', this.urlParam);
        console.log('start/end sample', this.startSample, '--**--', this.endSample);
        console.log('again coming');
        try {
            this.headerForSRG = 'Related Graphs (Tier: ' + this.objofCurrentnode.tierName + ', Server: ' + this.objofCurrentnode.serverName + ', Instance: ' + this.objofCurrentnode.appName + ')';
            //this.displayShowRelatedGraph = true;
            let reqData = {};
            let endTimeInMs = 0;
            let startTimeInMS = 0;
            if (this.isFromMain) {
                this.objofCurrentnode = objForRouting;
            }
            if (this.objofCurrentnode != undefined) {
                if (objForRouting.StartTime) {
                    let dateForStart = new Date(objForRouting.StartTime);
                    startTimeInMS = dateForStart.getTime();
                    endTimeInMs = Number(startTimeInMS) + parseInt(objForRouting.Duration.replace(/,/g, ''));
                }
                else {
                    startTimeInMS = Number(objForRouting.startTimeInMs);
                    endTimeInMs = Number(startTimeInMS) + Number((objForRouting.fpDuration).toString().replace(/,/g, ''));
                }
                let flowpathInstance = objForRouting.flowpathInstance || this.objofCurrentnode.flowpathInstance;
                let urlIndex = this.objofCurrentnode.urlIndex;
                let tierId = this.objofCurrentnode.tierId;
                let tierName = this.objofCurrentnode.tierName;
                let serverId = this.objofCurrentnode.serverId;
                let serverName = this.objofCurrentnode.serverName;
                let appId = this.objofCurrentnode.appId;
                let appName = this.objofCurrentnode.appName;
                let strStartTime = startTimeInMS;
                let strEndTime = endTimeInMs;
                console.log('end time', endTimeInMs);
                let relTierName = tierName;
                let relServerName = serverName;
                let relAppName = appName;
                let relStartTime = objForRouting.startDateTime;
                let vectorName = tierName + ">" + serverName + ">" + appName;
                console.log('sample----', this.startSample, '***', this.endSample);
                let ajaxurl = this.getHostUrl() + "/DashboardServer/view/TierInfo.jsp?GRAPH_KEY=" + this.urlParam.strGraphKey + "&reqTestRunNum=" + this.urlParam.testRun +
                    "&sessLoginName=netstorm&valueType=average&requestType=edRelatedTableData&reqVecName=" + vectorName +
                    "&startDT=" + objForRouting.startDateTime + "&resTime=" + objForRouting.fpDuration + "&startSample=" + this.startSample + "&endSample=" + this.endSample;
                console.log('url___]:', ajaxurl);
                this.ddrRequest.getDataInStringUsingGet(ajaxurl).subscribe(data => {
                    let relatedGraphJSON = JSON.parse(data);
                    let parts = (relatedGraphJSON.edRelatedGraphData[0].name).replace(/\-/, '&').split('&');
                    if (relatedGraphJSON.edRelatedGraphData.length == 0) {
                        this.displayShowRelatedGraph = false;
                        this.tableDialogDisplay1 = false;
                        alert(" There is no related graph in -" + this.urlParam.testRun);
                        return 0;
                    }
                    else if (relatedGraphJSON.edRelatedGraphData.length == 1 && parts[1].trim() == vectorName) {
                        this.displayShowRelatedGraph = false;
                        this.tableDialogDisplay1 = false;
                        alert(" There is no related graph in - " + this.urlParam.testRun);
                        // this.displayShowRelatedGraph = false;
                        return 0;
                    }
                    this.displayShowRelatedGraph = true;
                    this.graphJson = relatedGraphJSON;
                    var total = relatedGraphJSON.edRelatedGraphData.length;
                    var obj = { "total": total, "start": 0, "end": 8, "type": "relatedGraphs" };
                    if (total < 9) {
                        obj.end = total;
                        this.graphMessage = 'Showing 1 to ' + obj.end + ' Graphs out of ' + total + ' Graphs';
                    }
                    else {
                        this.graphMessage = 'Showing 1 to 9 Graphs out of ' + total + ' Graphs';
                    }
                    let start = obj.start;
                    let end = obj.end;
                    jquery__WEBPACK_IMPORTED_MODULE_2__("#secondDiv").hide();
                    let flag = false;
                    jquery__WEBPACK_IMPORTED_MODULE_2__("#next").on('click', function () {
                        flag = true;
                        if (total > 9) {
                            jquery__WEBPACK_IMPORTED_MODULE_2__("#firstDiv").hide();
                            jquery__WEBPACK_IMPORTED_MODULE_2__("#secondDiv").show();
                        }
                    });
                    jquery__WEBPACK_IMPORTED_MODULE_2__("#prev").on('click', function () {
                        console.log('inside this---');
                        if (flag === true && total > 9) {
                            jquery__WEBPACK_IMPORTED_MODULE_2__("#firstDiv").show();
                            jquery__WEBPACK_IMPORTED_MODULE_2__("#secondDiv").hide();
                        }
                    });
                    let graphData = [];
                    graphData = relatedGraphJSON['edRelatedGraphData'];
                    console.log('grapghdata---', relatedGraphJSON);
                    // console.log('par******', graphData)
                    // let parts = (relatedGraphJSON.edRelatedGraphData[0].name).replace(/\-/, '&').split('&');
                    // console.log('parts-', parts)
                    console.log('tableData----', relatedGraphJSON.edRelatedTableData);
                    if (relatedGraphJSON.edRelatedTableData.length !== 0) {
                        // this.tableDialogDisplay1 = true;
                        this.graphTableArray = relatedGraphJSON.edRelatedTableData;
                        if (this.graphTableArray.length > 4) {
                            this.tabularViewPopUpHeight = 300;
                        }
                        else {
                            this.tabularViewPopUpHeight = 150;
                        }
                    }
                    let getGraphIndex = function (graphName) {
                        var idx = -1;
                        relatedGraphJSON.edRelatedGraphData.forEach((val, index) => {
                            if (val.name == graphName) {
                                idx = index;
                            }
                        });
                        return idx;
                    };
                    let graphArr = [];
                    let graphArr1 = [];
                    let count = 0;
                    console.log('eddata----', relatedGraphJSON.edRelatedTableData);
                    relatedGraphJSON.edRelatedTableData.forEach((val, index) => {
                        let name = val.graphName;
                        let obj = {};
                        // console.log('********', name);
                        obj['graphName'] = name;
                        obj['grapghIndex'] = getGraphIndex(name);
                        obj['tierName'] = tierName;
                        obj['serverName'] = serverName;
                        obj['appName'] = appName;
                        obj['startTime'] = relStartTime;
                        obj['fpDuration'] = objForRouting.fpDuration;
                        obj['KPIDuration'] = encodeURIComponent(val.graphUniqueKeyDTO);
                        obj['startSample'] = this.startSample;
                        obj['endSample'] = this.endSample;
                        obj['ndeId'] = objForRouting.ndeId;
                        count += 1;
                        // console.log('OBJ----------', obj, count)
                        if (total > 9) {
                            if (!(count >= 10)) {
                                graphArr.push(obj);
                            }
                            else {
                                graphArr1.push(obj);
                            }
                        }
                        else {
                            graphArr.push(obj);
                        }
                        // console.log('grapharr---', graphArr);
                    });
                    console.log('final arr--', graphArr.length, graphArr1.length);
                    for (var i = 0; i < total; i++) {
                        // this.cretaeChart();
                    }
                    this.grapghData = graphArr;
                    this.graphData = graphArr1;
                });
            }
        }
        catch (error) {
        }
    }
    saveChart(chartInstance) {
        this.chart = chartInstance;
    }
    /**
     * Popup For setting Samples before and after flowpath
     */
    openSamplePopUp() {
        console.log('rowData----', this.objofCurrentnode);
        // startTime, fpDuration, tierName, serverName, appName, flowpathinstance,ndeId
        this.displaySamplePopup = true;
    }
    applySamplePopUp() {
        console.log('updated Samples', this.startSample, '----', this.endSample);
        this.openShowRelatedGraph(this.objofCurrentnode);
        this.displaySamplePopup = false;
    }
    /**
     * apply default Value on Reset of Sample Time
     */
    applyDefaultValue() {
        this.startSample = '5';
        this.endSample = '5';
    }
    /**
     * Open All Graphs Case
     */
    openAllGraphs() {
        console.log('inside All Graphs case-------');
        if (this.graphTableArray.length !== 0) {
            this.displayShowRelatedGraph = true;
        }
    }
    validateQty(event) {
    }
    /**
     * open Single Graph
     */
    openSingleGraph(rowData, graphType) {
        this.singleMergeGraph = true;
        console.log('data---->?', rowData);
        console.log('jsondata', this.graphJson, '==', this.grapghData);
        var mainJson = this.graphJson;
        var index = "";
        var appName = "";
        var enableLegend = false;
        if (graphType === 'single') {
            console.log('grapghname', rowData.graphName);
            this.grapghData.forEach((val, idx) => {
                console.log(val.graphName);
                if (rowData.graphName === val.graphName) {
                    index = val.grapghIndex;
                    appName = val.appName;
                }
            });
            console.log('index---', index);
            var length = 0;
            var json = [mainJson.edRelatedGraphData[index]];
            console.log(json);
            var name = json[0].name;
        }
        if (graphType === 'single') {
            var graphUniqueKeyDTO = mainJson.edRelatedTableData[index].graphUniqueKeyDTO;
            let corelName = name.substring(0, name.indexOf("-"));
        }
        else {
            try {
                json = mainJson.edRelatedGraphData;
                json.forEach((index, val) => {
                    if (val['data'] != undefined) {
                        length += val['data'].length;
                    }
                });
                name = "All Graphs";
                enableLegend = true;
                var startSampleTime = mainJson.edRelatedGraphData[index].data[0][0];
                var endSampleTime = mainJson.edRelatedGraphData[index].data[length - 1][0];
                if (length == 0) {
                    alert('No Graph for current Samples!');
                    return;
                }
                if (json.length > 0) {
                    length = mainJson.edRelatedGraphData[index].data.length;
                }
            }
            catch (ex) {
                console.log("outer Exp...");
                if (length == 0) {
                    alert('No Graph for current Samples!');
                    return;
                }
            }
        }
        console.log('Final json and name----', json, '---', name);
        this.options = {
            chart: {
                type: 'spline',
                height: 500,
                width: 570,
                responsive: true,
                zoomType: 'x'
            },
            credits: {
                enabled: false
            },
            title: {
                text: name,
                style: { fontSize: '12px' }
            },
            tooltip: {
                tooltip: {
                    formatter: function () {
                        return '<b>Time: </b>' + moment__WEBPACK_IMPORTED_MODULE_13__["tz"](this.x, mainJson['timeZone']).format('MM/DD/YY HH:mm:ss') +
                            '<br/ ><b>Value: ' + '</b>' + this.y;
                    }
                },
            },
            legend: {
                itemStyle: {
                    color: 'rgb(29, 181, 18)',
                    fontWeight: 'bold',
                    fontSize: '9px'
                },
                itemHoverStyle: {
                    color: 'rgb(29, 220, 20)'
                },
                itemDistance: 5,
                padding: 0,
                margin: 0,
                labelFormatter: function () {
                    let index = (this.name).indexOf('-');
                    if (index !== -1) {
                        return (this.name).substring(0, index) + '<br/>' + (this.name).substring(index, (this.name).length);
                    }
                    else {
                        return this.name;
                    }
                },
                enabled: enableLegend
            },
            yAxis: {
                title: {
                    text: ''
                },
                min: 0
            },
            xAxis: {
                type: 'time',
                labels: {
                    formatter: function () {
                        return moment__WEBPACK_IMPORTED_MODULE_13__["tz"](this.value, mainJson['timeZone']).format('HH:mm:ss');
                    },
                    style: {
                        fontSize: '8px'
                    }
                },
                plotBands: [{
                        color: '#e4f9a6',
                        from: mainJson.startTime,
                        to: mainJson.endTime
                    }]
            },
            series: json
        };
    }
    onhideDialog(event) {
        console.log('event----------', event);
        this.tableDialogDisplay1 = true;
    }
    openMethodTimingReport(objForRouting) {
        this.setIpPort(objForRouting);
        this._ddrData.isFromTrxnFlowmap = true;
        this._ddrData.splitViewBreadCrumbFlag = false;
        this._ddrData.splitViewFlag = false;
        this.CommonServices.openfptoAggMT = false;
        let reqData = {};
        let endTimeInMs = 0;
        let startTimeInMS = 0;
        if (this.isFromMain) {
            this.objofCurrentnode = objForRouting;
        }
        if (this.objofCurrentnode != undefined) {
            if (objForRouting.StartTime) {
                console.log('(objForRouting.StartTime>>>>', objForRouting.StartTime);
                reqData["Duration"] = objForRouting.Duration.replace(/,/g, '');
                reqData["StartTimeDF"] = objForRouting.StartTime;
            }
            else {
                startTimeInMS = Number(objForRouting.startTimeInMs);
                endTimeInMs = Number(startTimeInMS) + Number((objForRouting.fpDuration).toString().replace(/,/g, ''));
            }
            reqData["flowpathInstance"] = objForRouting.FPInstance || this.objofCurrentnode.flowpathInstance;
            reqData["urlIndex"] = this.objofCurrentnode.urlIndex;
            reqData["tierId"] = this.objofCurrentnode.tierId;
            reqData["tierName"] = this.objofCurrentnode.tierName;
            reqData["serverId"] = this.objofCurrentnode.serverId;
            reqData["serverName"] = this.objofCurrentnode.serverName;
            reqData["appId"] = this.objofCurrentnode.appId;
            reqData["appName"] = this.objofCurrentnode.appName;
            reqData["strStartTime"] = startTimeInMS;
            reqData["strEndTime"] = endTimeInMs;
            console.log('end time', endTimeInMs);
            // reqData["btCatagory"] = this.flowmapData.paramsForFlowMap.btCatagory;
        }
        // this.breadcrumbService.parentComponent = CONSTANTS.BREADCRUMB_ITEMS.TRANSACTION_FLOWMAP;
        this.breadcrumb.add({ label: 'Method Timing' });
        this.CommonServices.mtData = reqData;
        this.CommonServices.mtFlag = true;
        if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
            this._router.navigate(['/home/ddrCopyLink/methodtiming']);
        else if (this._router.url.indexOf("/home/ED-ddr") != -1)
            this._router.navigate(['/home/ED-ddr/methodtiming']);
        else
            // this._router.navigate(['/home/ddr/methodtiming']);
            this._router.navigate(['/ddr/methodtiming']);
    }
    openDBReports(data) {
        this.breadcrumb.add({ label: 'DB Queries' });
        this.setIpPort(data);
        this._ddrData.isFromTrxnFlowmap = true;
        this._ddrData.splitViewBreadCrumbFlag = false;
        this._ddrData.splitViewFlag = false;
        console.log('data items', this.objofCurrentnode);
        if (this.isFromMain) {
            this.objofCurrentnode = data;
        }
        this.CommonServices.setFPData = this.objofCurrentnode;
        this._ddrData.dbFlag = true;
        this.CommonServices.productName = this.urlParam.product;
        this.CommonServices.testRun = this.urlParam.testRun;
        this.setInStorage(this.objofCurrentnode);
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_11__["BREADCRUMB_ITEMS"].TRANSACTION_FLOWMAP;
        if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
            this._router.navigate(['/home/ddrCopyLink/flowpathToDB']);
        else if (this._router.url.indexOf("/home/ED-ddr") != -1)
            this._router.navigate(['/home/ED-ddr/flowpathToDB']);
        else
            // this._router.navigate(['/home/ddr/flowpathToDB']);
            this._router.navigate(['/ddr/flowpathToDB']);
    }
    setInStorage(data) {
        sessionStorage.removeItem("dbData");
        sessionStorage.removeItem("dbFlag");
        sessionStorage.setItem("dbData", JSON.stringify(data));
        sessionStorage.setItem("dbFlag", "true");
    }
    openHttpReport(objForRouting) {
        this.setIpPort(objForRouting);
        this._ddrData.splitViewFlag = false;
        let reqData = {};
        let endTimeInMs = 0;
        let startTimeInMS = 0;
        if (this.objofCurrentnode != undefined) {
            if (objForRouting && objForRouting.startTimeInMs) {
                startTimeInMS = Number(objForRouting.startTimeInMs);
                endTimeInMs = Number(startTimeInMS) + Number((objForRouting.fpDuration).toString().replace(/,/g, ''));
            }
            reqData["fpInstance"] = objForRouting.FPInstance || this.objofCurrentnode.flowpathInstance;
            reqData["urlIndex"] = this.objofCurrentnode.urlIndex;
            reqData["tierId"] = this.objofCurrentnode.tierId;
            reqData["tierName"] = this.objofCurrentnode.tierName;
            reqData["serverId"] = this.objofCurrentnode.serverId;
            reqData["serverName"] = this.objofCurrentnode.serverName;
            reqData["appId"] = this.objofCurrentnode.appId;
            reqData["appName"] = this.objofCurrentnode.appName;
            reqData["startTimeInMs"] = startTimeInMS;
            reqData["strEndTime"] = endTimeInMs;
            reqData["urlQueryParamStr"] = this.objofCurrentnode.urlQueryParmStr;
            console.log('end time', endTimeInMs);
            // reqData["btCatagory"] = this.flowmapData.paramsForFlowMap.btCatagory;
        }
        // this.breadcrumbService.parentComponent = CONSTANTS.BREADCRUMB_ITEMS.TRANSACTION_FLOWMAP;
        this.breadcrumb.add({ label: 'Http Report' });
        this._ddrData.httpData = reqData;
        this.CommonServices.httpData = reqData;
        console.log("There should be reqData for Http report", reqData);
        this.CommonServices.httpFlag = true;
        if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
            this._router.navigate(['/home/ddrCopyLink/httpReqResp']);
        else if (this._router.url.indexOf("/home/ED-ddr") != -1)
            this._router.navigate(['/home/ED-ddr/httpReqResp']);
        else
            // this._router.navigate(['/home/ddr/httpReqResp']);
            this._router.navigate(['/ddr/httpReqResp']);
    }
    getNodeDataforRouting(event, obj) {
        if (event.button == 2) {
            this.objofCurrentnode = obj;
            this.drilInfoData = obj;
            setTimeout(() => {
                if (this.flowmapData.netForestURL == undefined || this.flowmapData.netForestURL == null || this.flowmapData.netForestURL == 'undefined' || this.flowmapData.netForestURL == 'NA') {
                    if (this.ContextMenuItems.length > 6 && this.ContextMenuItemsForExceeption.length > 7)
                        this.ContextMenuItems.splice(4, 2);
                    this.ContextMenuItemsForExceeption.splice(5, 2);
                }
                if ((obj.instanceType == 'java' || obj.instanceType == 'dotNet' || obj.instanceType == 'dotNetC' || obj.instanceType == 'NodeJS' || obj.instanceType == 'php' || obj.instanceType == 'go' || obj.instanceType == 'cppAgent' || obj.instanceType == 'python') && (obj['exceptionCount'] == 0 || obj['exceptionCount'] == undefined)) {
                    this.contextRef.show();
                    let nodes = document.getElementById('contextmenu').childNodes;
                    let elmHeight = document.getElementById(obj.id).style.top.split('px')[0];
                    let elmleft = document.getElementById(obj.id).style.left.split('px')[0];
                    // nodes[1]['style'].top = (Number(elmHeight)  + 30) + 'px';
                    // nodes[1]['style'].left = (Number(elmleft)  + 30 )+ 'px';
                    nodes[0]['style'].top = (Number(elmHeight) + 30) + 'px';
                    nodes[0]['style'].left = (Number(elmleft) + 30) + 'px';
                    this.mainContextMenu = this.ContextMenuItems;
                }
                else if ((obj.instanceType == 'java' || obj.instanceType == 'dotNet' || obj.instanceType == 'dotNetC' || obj.instanceType == 'NodeJS' || obj.instanceType == 'php' || obj.instanceType == 'go' || obj.instanceType == 'cppAgent' || obj.instanceType == 'python') && (obj['exceptionCount'] > 0)) {
                    this.contextRef.show();
                    let nodes = document.getElementById('contextmenu').childNodes;
                    let elmHeight = document.getElementById(obj.id).style.top.split('px')[0];
                    let elmleft = document.getElementById(obj.id).style.left.split('px')[0];
                    // nodes[1]['style'].top = (Number(elmHeight)  + 30) + 'px';
                    // nodes[1]['style'].left = (Number(elmleft)  + 30 )+ 'px';
                    nodes[0]['style'].top = (Number(elmHeight) + 30) + 'px';
                    nodes[0]['style'].left = (Number(elmleft) + 30) + 'px';
                    this.mainContextMenu = this.ContextMenuItemsForExceeption;
                }
                else {
                    return;
                }
            }, 300);
        }
    }
    /**
     * This methos is called when user clicks on the  view thread merge button.
     *
     * And we created the json for thread merge data as follows:
     */
    getSelfLoopJsonData() {
        try {
            /**First of all we cloning the main json so that the impact should not be on the main one*/
            this.selfLoppedDataToDraw = JSON.parse(JSON.stringify(this.flowmapData.jsonData));
            /**Here we are making clone object for html view as we need to show less nodes
             * as compared to original node objects due to self connection nodes
             */
            this.selfLoppedDataToDrawToView = JSON.parse(JSON.stringify(this.flowmapData.jsonData));
            /**Here we making a clone object  for comparission and  maniplation  on json*/
            if (this.selfLoppedDataToDraw) {
                /**Main loop */
                for (let i = 0; i < this.selfLoppedDataToDraw.length; i++) {
                    let mainJsonObj = this.selfLoppedDataToDraw[i];
                    /**Comparission loop*/
                    for (let j = i + 1; j < this.selfLoppedDataToDraw.length; j++) {
                        /**Rest manupulate the objects*/
                        let compareJsonObj = this.selfLoppedDataToDraw[j];
                        /**Buisness logic to create the self loop source and destiation*/
                        /**conditions for self loop
                         * - App name of both objects must be same.
                         * - CalloutType must be 't' of object which is being compared.
                         * - SourceId of main object must be same as of  id of  object being compared.
                         * - sourceId of main obj must not be same as of source id of compareing object.
                         * - In case if appName is '-' and other conditions are true then this object will be egligible for self loop.
                          */
                        if (mainJsonObj && compareJsonObj && (mainJsonObj.appName == compareJsonObj.appName || compareJsonObj.appName == '-') && compareJsonObj.callOutType == 't' && mainJsonObj.id == compareJsonObj.sourceId && mainJsonObj.sourceId != compareJsonObj.sourceId) {
                            /**Here we removing the object from the json which is used for viewing*/
                            let indexToRemove = this.getNodeIndex(this.selfLoppedDataToDrawToView, compareJsonObj.id);
                            if (this.selfLoppedDataToDrawToView[indexToRemove] && indexToRemove != -1)
                                this.selfLoppedDataToDrawToView.splice(indexToRemove, 1);
                            /**Chnaging the source id*/
                            this.chnageSourceId(this.selfLoppedDataToDraw, compareJsonObj.id, mainJsonObj.id);
                            /**Here we giving the parent to the child node*/
                            if (this.isSelfObjAlreadyAvail(this.selfLoppedDataToDraw, j, mainJsonObj.id)) {
                                this.selfLoppedDataToDraw.splice(j, 1);
                                j--;
                            }
                            else
                                compareJsonObj.id = mainJsonObj.id;
                        }
                    }
                }
                this.showSelfLoop = true;
                let data = this.flowmapData.supportAsync(this.selfLoppedDataToDraw, this.selfLoppedDataToDrawToView);
                this.selfLoppedDataToDraw = data[1];
                this.selfLoppedDataToDrawToView = data[0];
                // this.dataToDraw = this.flowmapData.asyncJsonForNonMergeCase;
                console.log("self data", this.selfLoppedDataToDraw, this.selfLoppedDataToDrawToView);
                setTimeout(() => { this.creteflowmap(this.selfLoppedDataToDraw), 0; });
            }
            else {
                console.log("Json data is not in proper formate or defined...");
            }
        }
        catch (err) {
            console.error("Not able to create self loop json because - ", err);
        }
    }
    /**This method is to increase the thread count and giving the value as true and false*/
    isSelfObjAlreadyAvail(selfLoppedDataToDraw, indexToIgnore, idToMatch) {
        try {
            if (selfLoppedDataToDraw) {
                for (let i = 0; i < selfLoppedDataToDraw.length; i++) {
                    if (i != indexToIgnore && selfLoppedDataToDraw[i].sourceId == idToMatch && selfLoppedDataToDraw[i].id == idToMatch) {
                        selfLoppedDataToDraw[i].count += selfLoppedDataToDraw[indexToIgnore].count;
                        selfLoppedDataToDraw[i].fpDuration += selfLoppedDataToDraw[indexToIgnore].fpDuration;
                        return true;
                    }
                }
            }
            return false;
        }
        catch (err) {
            console.error(err);
            return false;
        }
    }
    /**Thi method gives us the index to splice*/
    getNodeIndex(jsonData, nodeObjId) {
        try {
            if (jsonData && nodeObjId) {
                for (let i = 0; i < jsonData.length; i++) {
                    if (jsonData[i].id == nodeObjId)
                        return i;
                }
            }
            return -1;
        }
        catch (err) {
            console.error(err);
            return -1;
        }
    }
    /**This is the methos which changes the source id if we exclude an objects id*/
    chnageSourceId(jsonDataToChange, sourceId, sourceIdToChange) {
        try {
            if (jsonDataToChange) {
                jsonDataToChange.forEach(nodeObj => {
                    if (nodeObj) {
                        if (nodeObj.sourceId && sourceId && nodeObj.sourceId == sourceId)
                            nodeObj.sourceId = sourceIdToChange;
                    }
                });
            }
            return jsonDataToChange;
        }
        catch (err) {
            console.error(err);
            return jsonDataToChange;
        }
    }
    showTransactionData() {
        if (this.showSelfLoop) {
            this.showSelfLoop = false;
            this.dataToDraw = this.flowmapData.asyncJsonForNonMergeCase;
            setTimeout(() => { this.creteflowmap(this.flowmapData.asyncJsonForNonMergeCase), 0; });
        }
        else {
            this.getSelfLoopJsonData();
        }
    }
    openReqRespData(data) {
        this.setIpPort(data);
        console.log('row data-------------> in flowmap', data);
        let startTime, endTime, fpDuration, url;
        // Adding starttime, endtime,fpduration in the end after all the cases for ajaxcall.
        if (this._ddrData.isFromtrxFlow) {
            url = "testRun=" + this._ddrData.testRunTr;
            console.log("this._ddrData.testRun", this._ddrData.testRun);
        }
        else
            url = "testRun=" + this.urlParam.testRun;
        if (data !== undefined) {
            console.log("else from main", this.objofCurrentnode);
            // this.CommonServices.hsData = this.objofCurrentnode;
            startTime = this.objofCurrentnode.startTimeInMs;
            fpDuration = this.objofCurrentnode.fpDuration;
            if (!data.startTimeInMs && !startTime) {
                let dateForStart = new Date(data.StartTime);
                let startTimeInMS = dateForStart.getTime();
                if (data.Duration) {
                    fpDuration = parseInt(data.Duration.replace(/,/g, ''));
                }
                //fpDuration = parseInt(data.Duration.replace(/,/g, ''));
                startTime = startTimeInMS;
                console.log("dateForStart", dateForStart, "startTimeInMS", startTimeInMS, "fpDuration", fpDuration, "startTime", startTime);
            }
            else if (data.Duration) {
                fpDuration = parseInt(data.Duration.replace(/,/g, ''));
            }
            url += '&fpInstance=' + this.objofCurrentnode.flowpathInstance +
                '&tierName=' + this.objofCurrentnode.tierName +
                '&serverName=' + this.objofCurrentnode.serverName +
                '&appName=' + this.objofCurrentnode.appName +
                "&statusCode=" + this.objofCurrentnode.statusCode;
            if (undefined != fpDuration) {
                if (fpDuration == '< 1')
                    fpDuration = 0;
                if (fpDuration.toString().includes(','))
                    endTime = Number(startTime) + Number(fpDuration.toString().replace(/,/g, ""));
                else
                    endTime = Number(startTime) + Number(fpDuration);
            }
            url += "&strStartTime=" + startTime + "&strEndTime=" + endTime +
                '&queryId=' + this.queryId;
            //url += "&btCategory="+this.flowmapData.paramsForFlowMap.btCatagory;
        }
        this.CommonServices.httpData = this.CommonServices.makeObjectFromUrlParam(url);
        var endpoint_url = '';
        if (this._ddrData.isFromtrxFlow) {
            endpoint_url += this._ddrData.protocolTr + "://" + this._ddrData.hostTr + ":" + this._ddrData.portTr + "/" + this.urlParam.product + "/v1/cavisson/netdiagnostics/ddr/httpReportNew?" + url;
        }
        else
            endpoint_url += this.flowmapData.hosturl + this.flowmapData.urlParam.product.replace('/', "") + "/v1/cavisson/netdiagnostics/ddr/httpReportNew?" + url;
        return this.ddrRequest.getDataUsingGet(endpoint_url).subscribe(data => (this.httpData(data)));
    }
    httpData(data) {
        //this.CommonServices.hsData.btCatagory = this.flowmapData.paramsForFlowMap.btCatagory;
        console.log("data after transaction ajax", data);
        this.httpDialog = true;
        for (let i = 0; i < data.reqBodyData.length; i++) {
            this.httpRequestArrBody = data.reqBodyData[i]["ReqBody"];
        }
        for (let i = 0; i < data.respBodyData.length; i++) {
            this.httpResponseArrBody = data.respBodyData[i]["RespBody"];
        }
        console.log("print this.httpRequestArrBody value", this.httpRequestArrBody);
        console.log("print this.httpResponseArrBody value", this.httpResponseArrBody);
    }
    openReqRespDataForCallOut(data) {
        this.setIpPort(data);
        console.log('row data-------------> in flowmap', data);
        let startTime, endTime, fpDuration, url;
        // Adding starttime, endtime,fpduration in the end after all the cases for ajaxcall.
        if (this._ddrData.isFromtrxFlow) {
            url = "testRun=" + this._ddrData.testRunTr;
            console.log("this._ddrData.testRun", this._ddrData.testRun);
        }
        else
            url = "testRun=" + this.urlParam.testRun;
        if (data !== undefined) {
            console.log("else from main", this.objofCurrentnode);
            // this.CommonServices.hsData = this.objofCurrentnode;
            startTime = this.objofCurrentnode.startTimeInMs;
            fpDuration = this.objofCurrentnode.fpDuration;
            if (!data.startTimeInMs && !startTime) {
                let dateForStart = new Date(data.StartTime);
                let startTimeInMS = dateForStart.getTime();
                if (data.Duration) {
                    fpDuration = parseInt(data.Duration.replace(/,/g, ''));
                }
                //fpDuration = parseInt(data.Duration.replace(/,/g, ''));
                startTime = startTimeInMS;
                console.log("dateForStart", dateForStart, "startTimeInMS", startTimeInMS, "fpDuration", fpDuration, "startTime", startTime);
            }
            else if (data.Duration) {
                fpDuration = parseInt(data.Duration.replace(/,/g, ''));
            }
            url += '&fpInstance=' + this.objofCurrentnode.flowpathInstance +
                '&tierName=' + this.objofCurrentnode.tierName +
                '&serverName=' + this.objofCurrentnode.serverName +
                '&appName=' + this.objofCurrentnode.appName +
                "&statusCode=" + this.objofCurrentnode.statusCode;
            if (undefined != fpDuration) {
                if (fpDuration == '< 1')
                    fpDuration = 0;
                if (fpDuration.toString().includes(','))
                    endTime = Number(startTime) + Number(fpDuration.toString().replace(/,/g, ""));
                else
                    endTime = Number(startTime) + Number(fpDuration);
            }
            url += "&strStartTime=" + startTime + "&strEndTime=" + endTime +
                '&queryId=' + this.queryId;
            //url += "&btCategory="+this.flowmapData.paramsForFlowMap.btCatagory;
        }
        this.CommonServices.httpData = this.CommonServices.makeObjectFromUrlParam(url);
        var endpoint_url = '';
        if (this._ddrData.isFromtrxFlow) {
            endpoint_url += this._ddrData.protocolTr + "://" + this._ddrData.hostTr + ":" + this._ddrData.portTr + "/" + this.urlParam.product + "/v1/cavisson/netdiagnostics/ddr/httpReportNew?" + url;
        }
        else
            endpoint_url += this.flowmapData.hosturl + this.flowmapData.urlParam.product.replace('/', "") + "/v1/cavisson/netdiagnostics/ddr/httpReportNew?" + url;
        endpoint_url += "&resourceId=1";
        return this.ddrRequest.getDataUsingGet(endpoint_url).subscribe(data => (this.httpDataForCallOut(data)));
    }
    httpDataForCallOut(data) {
        //this.CommonServices.hsData.btCatagory = this.flowmapData.paramsForFlowMap.btCatagory;
        console.log("data after transaction ajax", data);
        this.httpDialogTable = true;
        if (data.ReqArray != undefined) {
            for (let i = 0; i < data.ReqArray.length; i++) {
                this.httpRequestArrBody2 = data.ReqArray[i];
            }
            this.httpRequestArrBody1 = this.createTableArr(data.ReqArray);
        }
        if (data.RespArray != undefined) {
            for (let i = 0; i < data.RespArray.length; i++) {
                this.httpResponseArrBody2 = data.RespArray[i];
            }
            this.httpResponseArrBody1 = this.createTableArr(data.RespArray);
        }
        console.log("print this.httpRequestArrBody1 value", this.httpRequestArrBody1);
        console.log("print this.httpResponseArrBody1 value", this.httpResponseArrBody1);
        console.log("print this.httpRequestArrBody2 value", this.httpRequestArrBody2);
        console.log("print this.httpResponseArrBody2 value", this.httpResponseArrBody2);
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    createTableArr(reqDataDetail) {
        let data = reqDataDetail;
        let coldata = [];
        let keys = Object.keys(data);
        for (let i = 0; i < keys.length; i++) {
            //console.log("length of data", keys.length);
            coldata[i] = { header: keys[i], value: (decodeURIComponent(data[keys[i]].substring(0, 50)).replace(/\+/g, '')) };
        }
        return coldata;
    }
    onShowMore(eventData) {
        this.showmore = true;
        //  this.ColumnRowData = node;
        //  console.log("The value of req body show more...", this.ColumnRowData);
    }
    onShowMore1(eventData) {
        this.showmore1 = true;
        //  this.ColumnRowData1 = node;
        //  console.log("The value of resp body show more...", this.ColumnRowData1);
    }
    //   openHotspotReport(data: any) {
    //   console.log('row data-------------> in flowmap', data);
    //   if (data !== undefined) {
    //     if (this.isFromMain) {
    //       this.CommonServices.hsData = data;
    //     }
    //     else {
    //       this.CommonServices.hsData = this.objofCurrentnode;
    //       if (!data.startTimeInMs) {
    //         let dateForStart = new Date(data.StartTime);
    //         let startTimeInMS = dateForStart.getTime();
    //         let fpDuration = parseInt(data.Duration.replace(/,/g, ''));
    //         this.CommonServices.hsData.startTimeInMS = startTimeInMS;
    //         this.CommonServices.hsData.fpDuration = fpDuration;
    //         this.CommonServices.hsData.flowpathInstance = data.FPInstance;
    //       }
    //     }
    //     this.CommonServices.hsData.btCatagory = this.flowmapData.paramsForFlowMap.btCatagory;
    //     this.CommonServices.hsFlag = true;
    //     this.breadcrumbService.parentComponent = CONSTANTS.BREADCRUMB_ITEMS.TRANSACTION_FLOWMAP;
    //  if(this._router.url.indexOf("/home/ddrCopyLink") != -1)
    // this._router.navigate(['/home/ddrCopyLink/hotspot']);
    // else if(this._router.url.indexOf("/home/ED-ddr") != -1)
    //  this._router.navigate(['/home/ED-ddr/hotspot']);
    // else
    //   this._router.navigate(['/home/ddr/hotspot']);
    // }
    // }
    openHotspotReport(data) {
        this.setIpPort(data);
        this._ddrData.isFromTrxnFlowmap = true;
        this._ddrData.splitViewBreadCrumbFlag = false;
        console.log('row data-------------> in flowmap', data);
        let startTime, endTime, fpDuration, url;
        // Adding starttime, endtime,fpduration in the end after all the cases for ajaxcall.
        if (this._ddrData.isFromtrxFlow) {
            url = "testRun=" + this._ddrData.testRunTr;
            console.log("this._ddrData.testRun", this._ddrData.testRun);
        }
        else
            url = "testRun=" + this.urlParam.testRun;
        if (data !== undefined) {
            if (this.isFromMain) {
                console.log("isFromMain>>>> main", data);
                startTime = data.startTimeInMs;
                fpDuration = data.fpDuration;
                url += '&tierId=' + data.tierId +
                    '&appId=' + data.appId +
                    '&serverId=' + data.serverId +
                    '&threadId=' + data.threadId +
                    // '&btCategory=' + data.btCatagory +
                    '&appName=' + data.appName +
                    '&serverName=' + data.serverName +
                    '&tierName=' + data.tierName +
                    '&flowpathInstance=' + data.flowpathInstance;
                // this.CommonServices.hsData = data;
            }
            else {
                console.log("else from main", this.objofCurrentnode);
                // this.CommonServices.hsData = this.objofCurrentnode;
                startTime = this.objofCurrentnode.startTimeInMs;
                fpDuration = this.objofCurrentnode.fpDuration;
                if (!data.startTimeInMs && !startTime) {
                    let dateForStart = new Date(data.StartTime);
                    let startTimeInMS = dateForStart.getTime();
                    fpDuration = parseInt(data.Duration.replace(/,/g, ''));
                    startTime = startTimeInMS;
                    console.log("dateForStart", dateForStart, "startTimeInMS", startTimeInMS, "fpDuration", fpDuration, "startTime", startTime);
                    // this.CommonServices.hsData.startTimeInMS = startTimeInMS;
                    // this.CommonServices.hsData.fpDuration = fpDuration;
                    //this.CommonServices.hsData.flowpathInstance = data.FPInstance;
                }
                else if (data.Duration) {
                    fpDuration = parseInt(data.Duration.replace(/,/g, ''));
                }
                url += '&tierId=' + this.objofCurrentnode.tierId +
                    '&appId=' + this.objofCurrentnode.appId +
                    '&serverId=' + this.objofCurrentnode.serverId +
                    //'&strStartTime=' + data.startTimeInMs +
                    //'&strEndTime='+ endTime +
                    '&threadId=' + this.objofCurrentnode.threadId +
                    //'&btCategory=' + this.objofCurrentnode.btCatagory +
                    '&appName=' + this.objofCurrentnode.appName +
                    '&serverName=' + this.objofCurrentnode.serverName +
                    '&tierName=' + this.objofCurrentnode.tierName +
                    '&urlIndex=' + this.objofCurrentnode.urlIndex +
                    '&instanceType=' + this.objofCurrentnode.instanceType +
                    '&flowpathInstance=' + this.objofCurrentnode.flowpathInstance;
            }
            if (undefined != fpDuration) {
                if (fpDuration == '< 1')
                    fpDuration = 0;
                if (fpDuration.toString().includes(','))
                    endTime = Number(startTime) + Number(fpDuration.toString().replace(/,/g, ""));
                else
                    endTime = Number(startTime) + Number(fpDuration);
            }
            url += "&strStartTime=" + startTime + "&strEndTime=" + endTime;
            url += "&btCategory=" + this.flowmapData.paramsForFlowMap.btCatagory;
        }
        this.CommonServices.hotspotFilters = this.CommonServices.makeObjectFromUrlParam(url);
        var endpoint_url = '';
        if (this._ddrData.isFromtrxFlow) {
            if (location.port) { // If URL doesn't contain port e.g - netcloudnoc-vm.cav-test.com
                endpoint_url += this._ddrData.protocolTr + "://" + this._ddrData.hostTr + ":" + this._ddrData.portTr + "/" + this.urlParam.product + "/v1/cavisson/netdiagnostics/ddr/hotspotDataEX?" + url;
            }
            else {
                endpoint_url += this._ddrData.protocolTr + "://" + this._ddrData.hostTr + this._ddrData.portTr + "/" + this.urlParam.product + "/v1/cavisson/netdiagnostics/ddr/hotspotDataEX?" + url;
            }
        }
        else
            endpoint_url += this.flowmapData.hosturl + this.flowmapData.urlParam.product.replace('/', "") + "/v1/cavisson/netdiagnostics/ddr/hotspotDataEX?" + url;
        return this.ddrRequest.getDataUsingGet(endpoint_url).subscribe(data => (this.hotspotData(data)));
    }
    hotspotData(data) {
        //this.CommonServices.hsData.btCatagory = this.flowmapData.paramsForFlowMap.btCatagory;
        console.log("data after transaction ajax", data);
        if (!data || !data.data || data.data.length == 0) {
            this.displayTFMPopUp = true;
            this.tableDialogDisplay1 = false;
            this.singleMergeGraph = false;
            this.displaySamplePopup = false;
            this._ddrData.isFromtrxFlow = false;
            this._ddrData.splitViewFlag = true;
        }
        else {
            this._ddrData.splitViewFlag = false;
            this.CommonServices.hsFlag = true;
            this.CommonServices.hsData = data;
            // this.breadcrumbService.parentComponent = CONSTANTS.BREADCRUMB_ITEMS.TRANSACTION_FLOWMAP;
            this.breadcrumb.add({ label: 'Hotspot' });
            if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
                this._router.navigate(['/home/ddrCopyLink/hotspot']);
            else if (this._router.url.indexOf("/home/ED-ddr") != -1)
                this._router.navigate(['/home/ED-ddr/hotspot']);
            else
                // this._router.navigate(['/home/ddr/hotspot']);
                this._router.navigate(['/ddr/hotspot']);
        }
    }
    openMethodCallingTree(data, mergeCase) {
        this.setIpPort(data);
        this._ddrData.isFromTrxnFlowmap = true;
        this._ddrData.splitViewBreadCrumbFlag = false;
        this._ddrData.splitViewFlag = false;
        console.log('data for method caalling tree', data, this.isFromMain);
        if (data != undefined) {
            console.log("main case" + this.isFromMain);
            if (this.isFromMain) {
                this.CommonServices.mctData = data;
            }
            else {
                this.objofCurrentnode['Instance_Type'] = this.objofCurrentnode['instanceType'];
                this.CommonServices.mctData = this.objofCurrentnode;
                this.CommonServices.mctData['startTime'] = this.objofCurrentnode['startDateTime'];
                this.CommonServices.mctData['mergeCase'] = mergeCase;
                if (!data.startTimeInMs) {
                    let dateForStart = new Date(data.StartTime);
                    let startTimeInMS = dateForStart.getTime();
                    let fpDuration = parseInt(data.Duration.replace(/,/g, ''));
                    this.CommonServices.mctData.startTimeInMS = startTimeInMS;
                    this.CommonServices.mctData.startTime = data.StartTime;
                    this.CommonServices.mctData.fpDuration = fpDuration;
                    this.CommonServices.mctData.flowpathInstance = data.FPInstance;
                }
                this.CommonServices.mctData.urlQueryParamStr = this.objofCurrentnode.urlQueryParmStr;
            }
            this.CommonServices.mctFlag = true;
        }
        this.CommonServices.mctData['source'] = "TransactionFlowmap";
        // this.breadcrumbService.parentComponent = CONSTANTS.BREADCRUMB_ITEMS.TRANSACTION_FLOWMAP;
        this.breadcrumb.add({ label: 'Method Call Details' });
        if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
            this._router.navigate(['/home/ddrCopyLink/methodCallingTree']);
        else if (this._router.url.indexOf("/home/ED-ddr") != -1)
            this._router.navigate(['/home/ED-ddr/methodCallingTree']);
        else
            // this._router.navigate(['/home/ddr/methodCallingTree']);
            this._router.navigate(['/ddr/methodCallingTree']);
    }
    onRowClick(event, data) {
        console.log('event of on row click', event, data);
        if (data.Query) {
            this.popupFooter = 'Query : ' + data.Query;
            var sqlDataMap1 = {};
            /*Changes for DB Query Param*/
            this.sqlDataMap = JSON.parse(JSON.stringify(this.nodeTabledataService.sqlMap));
            let sqlQueries = this.sqlDataMap;
            for (var obj in sqlQueries) {
                let query = this.decodeUrlQuery(sqlQueries[obj]);
                sqlDataMap1[obj] = query;
            }
            let query = data.Query;
            function getKeyByValue(object, value) {
                let keyss = Object.keys(object);
                let id = keyss.find(key => object[key] === value);
                return id;
            }
            this.sqlId = getKeyByValue(sqlDataMap1, query);
            let urlDbParam = "";
            this.dbPerm = this.sessionService.isFeatureWrite(src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_19__["CAV_FEATURES"].APM.NAME, src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_19__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS);
            let endTime = Number(this.flowmapData.paramsForFlowMap.startTimeInMs) + Number(this.flowmapData.paramsForFlowMap.fpDuration) + 1800000;
            urlDbParam += this.getHostUrl() + '/' + this.urlParam.product + "/v1/cavisson/netdiagnostics/ddr/getDbParam?testRun=" + this.urlParam.testRun + "&tierId=" + this.flowmapData.paramsForFlowMap.tierId +
                "&serverId=" + this.flowmapData.paramsForFlowMap.serverId + "&appId=" + this.flowmapData.paramsForFlowMap.appId + "&flowpathInstance=" + this.flowmapData.paramsForFlowMap.flowpathInstance +
                "&strStartTime=" + this.flowmapData.paramsForFlowMap.startTimeInMs + "&strEndTime=" + endTime + '&sqlIndex=' + this.sqlId;
            this.paramLoad = true;
            this.ddrRequest.getDataUsingGet(urlDbParam).subscribe(data => { this.assignDbParamData(data); });
        }
        else if (data.URL) {
            this.popupFooter = 'URL = ' + data.URL;
        }
        else {
            if (data.min) {
                this.popupFooter = 'Minimum Execution Time : ' + data.min;
            }
        }
    }
    assignDbParamData(res) {
        this.dbParamInfo = res.data;
        this.paramLoad = false;
        this.showDbParam = true;
    }
    decodeUrlQuery(val) {
        if (val)
            return val.replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
        else
            return val;
    }
    setpopupFilter() {
        this.popupFilter = " From Tier: " + this.flowmapData.paramsForFlowMap.tierName + ', ' + "From Server: " + this.flowmapData.paramsForFlowMap.serverName + ", " + " From Instance : " + this.flowmapData.paramsForFlowMap.appName + ", " + 'Start Time : ' + this.flowmapData.paramsForFlowMap.startTime;
    }
    //this is method is to open the net forest from context menu when keyword is present in config UI
    openNetForest(flowpathIns, entryInstance, correlationId) {
        this._ddrData.splitViewFlag = false;
        var corrId = "";
        var query = "";
        let NetForestUrl = this.flowmapData.netForestURL;
        let timeVar = this.timeVarianceInMs(this.flowmapData.timeVarianceForNetForest);
        console.log("Time variance from TRX To NF = " + timeVar);
        console.log("Start time in TRX  = " + this.flowmapData.paramsForFlowMap.startTimeInMs);
        var d1 = parseInt(this.flowmapData.paramsForFlowMap.startTimeInMs) - timeVar;
        var d2 = parseInt(this.flowmapData.paramsForFlowMap.startTimeInMs) + parseInt(this.flowmapData.paramsForFlowMap.fpDuration) + timeVar;
        console.log("start time from TRX To NF = " + d1);
        console.log("end time from TRX To NF = " + d2);
        var startTimeISO = new Date(d1).toISOString();
        var endTimeISO = new Date(d2).toISOString();
        //var timeStr = "from:%27"+startTimeISO+"%27,mode:absolute,to:%27"+endTimeISO+"%27";
        if (correlationId != "" && correlationId != 'undefined' && correlationId != "-")
            // corrId = "%20OR%20corRID%3A"+correlationId;
            corrId = "%20AND%20corRID:" + correlationId;
        if (entryInstance == '1') {
            //query = "%27entryFPI%3D"+entryFPI+corrId+"%27";
            query = "entryFPI:" + this.entryFPI + corrId;
        }
        else
            //query = "%27FPI%3D"+flowpathIns+corrId+"%27";
            query = "FPI:" + flowpathIns + corrId;
        // New navigation to NF from Trxn Flowmap -- A-9 migration
        query = query.replace("%20", ' ');
        console.log("The value inside the starttime and endtime and query for the netforest is .......", startTimeISO, endTimeISO, query);
        // this._router.navigate(['/sessions-details'], { queryParams: { sid: nvSessionId  } });
        this._router.navigate(["/home/logs"], { queryParams: { queryStr: query, startTime: startTimeISO, endTime: endTimeISO } });
        // Commented due to A-9 migartion.
        // if (NetForestUrl != "NA") {
        //   NetForestUrl = NetForestUrl.replace(/startTimeVal/, startTimeISO);
        //   NetForestUrl = NetForestUrl.replace(/endTimeVal/, endTimeISO);
        //   NetForestUrl = NetForestUrl.replace(/queryVal/, query);
        // }
        // else if (NetForestUrl == "NA") {
        //   alert("Please provide ' NetForestUrl ' keyword in config.ini");
        //   return;
        // }
        // console.log("url in trx flow:" + NetForestUrl);
        // window.open(NetForestUrl);
    }
    getMaxCordinate() {
        let xCor;
        let yCor;
        this.selfLoppedDataToDrawToView.forEach((val, index) => {
            xCor = parseInt(jquery__WEBPACK_IMPORTED_MODULE_2__('#' + val.id).css('left').replace('px', ''));
            yCor = parseInt(jquery__WEBPACK_IMPORTED_MODULE_2__('#' + val.id).css('top').replace('px', ''));
            if (xCor > this.maxX)
                this.maxX = xCor;
            if (yCor > this.maxY)
                this.maxY = yCor;
            this.arr_id_x_y.push([val.id, xCor, parseInt(yCor) + 100]);
        });
    }
    downloadReport(type, arg) {
        if (this.showSelfLoop) {
            alert("Please Switch to expanded mode to download.");
            return;
        }
        let minX = 1400; //default width of canvas
        let minY = 600; //default height of canvas
        this.getMaxCordinate();
        let canvas = this.el.nativeElement.querySelector('#canvasforDownload');
        if (this.maxX < minX)
            canvas['width'] = minX;
        else
            canvas['width'] = this.maxX + 300; //here 300 px is added as margin (for tooltip purpose)
        if (this.maxY < minY)
            canvas['height'] = minY + this.shiftFactor;
        else
            canvas['height'] = this.maxY + 150 + this.shiftFactor; //here 150 px is added as margin (for tooltip purpose)
        var entryX = 30; //X zxxxxxxxxxxxxxxxxxxxxxzxzxzxxxxxxzxzxxzxxxxxxxzxxzzxxxxxxzxzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzxxxxxxxxxxxxxxxxxzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzxzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzxxxzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzxzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz of entry node
        var entryY = 70; //Y cordn of entry node
        var font = 15; //font of text inside tooltip
        var padding = 5;
        if (canvas['getContext']) {
            this.ctx = canvas.getContext("2d");
            this.ctx.fillStyle = 'white';
            this.ctx.fillRect(0, 0, canvas['width'], canvas['height']);
            this.drawHeader(this.ctx);
            this.makeLines(this.ctx);
            this.makeNodes(this.ctx, arg);
        }
        if (type == 'directDownload') {
            setTimeout(() => {
                document.getElementById("trans")['download'] = "image.png";
                document.getElementById("trans")['href'] = this.el.nativeElement.querySelector("#canvasforDownload").toDataURL("image/png");
                //.replace(/^data:image\/[^;]/, 'data:application/octet-stream');
                document.getElementById("trans").click();
            }, 500);
        }
        else if (type == 'openInNewTab') {
            setTimeout(() => {
                document.getElementById("download")['download'] = "image.png";
                var url = this.el.nativeElement.document.getElementById("canvasforDownload").toDataURL("image/png");
                window.open(url, '_blank', 'drillDownReport');
            }, 500);
        }
    }
    drawHeader(ctx) {
        var wid = document.getElementById('canvasforDownload')['width'];
        this.heightHeaderBox = 45;
        ctx.strokeStyle = "blue";
        ctx.fillStyle = 'LightSteelBlue';
        ctx.fillRect(0, 0, parseInt(wid), this.heightHeaderBox);
        /*ctx.rect(0,0,wid,45);
            ctx.stroke();
        ctx.font = "15px serif";
            ctx.fillStyle = 'black';
          ctx.fillText(filterData, 0, 15); */
        var src1 = "./assets/images/logo_circle.png";
        var img = new Image();
        img.onload = function () { ctx.drawImage(img, 1, 1, 160, 40); };
        img.src = src1;
        var mode = "";
        if (sessionStorage.getItem('productType') == 'netdiagnostics')
            mode = "Netdiagnostics";
        else
            mode = "Netstorm";
        var title = mode + " - Transaction Flow - Test Run Number : " + this.urlParam.testRun;
        ctx.font = "bold 22px serif";
        ctx.fillStyle = 'Navy';
        ctx.fillText(title, parseInt(wid) / 3, 2 * this.heightHeaderBox / 3);
    }
    makeLines(ctx) {
        var entryX = 30; //X cordn of entry node
        var entryY = 110 + this.shiftFactor; //Y cordn of entry node
        var arr = [];
        var x1, y1; //(x1,y1) cordn of source of line connecting two nodes
        var padding = 5;
        var font = 15;
        this.dataToDraw.forEach((val, index) => {
            //  if(index == 0)
            //    {
            //    if(DCNAME != "NA")
            // //       filterData =" DC :"+DCNAME;
            //     filterData += " Tier :"+val.tierName+"  Server: "+val.serverName+"  Instance:"+val.appName+"  BT: "+this.flowmapData.paramsForFlowMap.urlName +"  Start Time: "+val.startDateTime;
            //  if(this.flowmapData.paramsForFlowMap.urlName)
            //     filterData += "  BT Type: "+ this.flowmapData.paramsForFlowMap.btCatagory;
            //  if(val.avgFpDuration != '<%=responseTime%>')
            //  {
            //     if(Number(<%=responseTime%>).toLocaleString() == 0)
            //       filterData += " Response Time: < 1(ms) Entry Response Time: < 1(ms)";
            //     else
            //   filterData += " Response Time: "+Number(<%=responseTime%>).toLocaleString()+"(ms) Entry Response Time: "+Number(Math.round(val.avgFpDuration)).toLocaleString()+"(ms)";
            //  }
            //  else
            //  {
            // if (Number(val.avgFpDuration) == 0)
            //   filterData += "  Response Time: < 1(ms)";
            // else
            //   filterData += "  Response Time: " + Number(val.avgFpDuration).toLocaleString() + "(ms)";
            // //}
            var filterBoxY = this.heightHeaderBox + 10; //filterBox is used for filter criteria
            var filterBoxWidth = document.getElementById('canvas')['width'];
            var filterBoxHeight = 25;
            ctx.strokeStyle = "blue";
            ctx.lineWidth = 1;
            ctx.rect(0, filterBoxY, filterBoxWidth, filterBoxHeight);
            ctx.stroke();
            ctx.font = "17px serif";
            ctx.fillStyle = 'black';
            ctx.fillText(this.headerInfo, 1, filterBoxY + filterBoxHeight - 5);
            var x = parseInt(jquery__WEBPACK_IMPORTED_MODULE_2__('#' + val.id).css('left').replace('px', ''));
            var y = parseInt(jquery__WEBPACK_IMPORTED_MODULE_2__('#' + val.id).css('top').replace('px', '')) + 100;
            var id = val.id;
            var source = val.sourceId;
            // arr.push([id, x, y]);                // push id, x , y cordn in array
            if (val.sourceId == "root") {
                x1 = entryX;
                y1 = entryY;
            }
            else {
                for (var i in this.arr_id_x_y) {
                    if (this.arr_id_x_y[i][0] == source) {
                        x1 = this.arr_id_x_y[i][1];
                        y1 = this.arr_id_x_y[i][2];
                    }
                }
            }
            //make lines connecting nodes
            ctx.beginPath();
            ctx.strokeStyle = 'blue';
            ctx.moveTo(x1, y1);
            ctx.lineTo(x, y);
            ctx.stroke();
            //----------- making content of tooltip box of connecting lines to node ---------------
            var lbl = ""; //text for showing on line connecting line
            var dur = "";
            var callLabel = "call";
            if (Number(val.count) > 1)
                callLabel = "calls";
            if (val.cumBackendDuration == val.avgBackendDuration) // if cumulative and average time equal
             {
                if (Number(val.avgBackendDuration) == 0)
                    dur = "< 1 ms";
                else
                    dur = Number(val.avgBackendDuration).toLocaleString() + " ms";
            }
            else {
                if (Number(val.cumBackendDuration) == 0)
                    dur = "< 1 ms , < 1 ms";
                else
                    dur = Number(val.cumBackendDuration).toLocaleString() + " ms" + ", " + Number(val.avgBackendDuration).toLocaleString() + " ms";
            }
            if (val.sourceId == "root") {
                if (Number(Math.round(val.avgFpDuration)) == 0)
                    lbl = "< 1 ms";
                else
                    lbl = Number(Math.round(val.avgFpDuration)).toLocaleString() + " ms";
            }
            else if (val.callOutType == "t")
                lbl = "Thread Call (" + (val.count).toLocaleString() + " " + callLabel + "), " + dur + " (" + Number(val.backendPercentage).toFixed(1) + "%)";
            else if (val.backendType == "OTHER") {
                if (val.avgBackendDuration >= 0)
                    lbl = (val.count).toLocaleString() + " " + callLabel + ", " + dur + " (" + Number(val.backendPercentage).toFixed(1) + "%)";
                else
                    lbl = (val.count).toLocaleString() + " " + callLabel;
            }
            else {
                if (val.avgBackendDuration >= 0)
                    lbl = val.backendType + " (" + (val.count).toLocaleString() + " " + callLabel + "), " + dur + " (" + Number(val.backendPercentage).toFixed(1) + "%)";
                else
                    lbl = val.backendType + " (" + (val.count).toLocaleString() + " " + callLabel + ")";
            }
            let queryParm;
            if (val.urlQueryParmStr == "-")
                queryParm = "";
            else
                queryParm = val.urlQueryParmStr;
            var url = this.flowmapData.getTruncatedURL(queryParm);
            //--------------- setting width and height of box according to content -----------------------
            if (ctx.measureText(url).width > ctx.measureText(lbl).width)
                this.widthOfTooltip = ctx.measureText(url).width + padding;
            else
                this.widthOfTooltip = ctx.measureText(lbl).width + padding;
            if (index == 0)
                this.widthOfTooltip -= 40; //need to remove
            if (val.urlQueryParmStr == "-")
                this.heightOfTooltip = font + padding;
            else
                this.heightOfTooltip = 2 * font + padding;
            var X = ((x + x1) - this.widthOfTooltip) / 2;
            var Y = (y + y1) / 2 - font;
            var borderColor = "black";
            if (val.erCount != undefined && val.erCount > 0)
                borderColor = "red";
            else
                borderColor = "green";
            this.roundedRect(ctx, X, Y, this.widthOfTooltip, this.heightOfTooltip, 10, borderColor, ''); // make toottip box on line connecting nodes
            //write text in the tooltip box
            ctx.font = "15px serif";
            ctx.fillStyle = 'black';
            if (val.sourceId == "root") {
                ctx.fillText(lbl, ((x + x1) - this.widthOfTooltip) / 2, (y + y1) / 2, this.widthOfTooltip);
            }
            else
                ctx.fillText(lbl, ((x + x1) - this.widthOfTooltip) / 2, (y + y1) / 2, this.widthOfTooltip);
            ctx.fillText(url, ((x + x1) - this.widthOfTooltip) / 2, (y + y1) / 2 + font, this.widthOfTooltip);
            // ctx.fillText(parseInt(index)+1, (X+widthOfTooltip/2), Y);
        });
    }
    makeNodes(ctx, arg) {
        var padding = 5;
        var font = 15;
        var entryX = 30; //X cordn of entry node
        var entryY = 110 + 100; //Y cordn of entry node
        var radius = 25;
        var startAngle = 0;
        var endAngle = 2 * Math.PI;
        ctx.beginPath();
        ctx.strokeStyle = "orange";
        ctx.fillStyle = 'orange';
        ctx.arc(entryX, entryY, radius, startAngle, endAngle, false);
        ctx.stroke();
        ctx.fill();
        ctx.font = "bold 12px serif";
        ctx.fillStyle = 'white';
        ctx.fillText("ENTRY", entryX - radius + 3, entryY);
        this.dataToDraw.forEach((val, index) => {
            ctx.beginPath();
            var x = parseInt(jquery__WEBPACK_IMPORTED_MODULE_2__('#' + val.id).css('left').replace('px', '')); // x coordinate
            var y = parseInt(jquery__WEBPACK_IMPORTED_MODULE_2__('#' + val.id).css('top').replace('px', '')) + 100; // y coordinate
            if (val.instanceTypeTopology != "-" && val.instanceTypeTopology != undefined) {
                var src1 = "./assets/images/" + (val.instanceTypeTopology).toLowerCase() + ".png";
            }
            else
                var src1 = "./assets/images/" + val.icon;
            var img = new Image();
            img.onload = function () { ctx.drawImage(img, x - 17, y - 17, 35, 35); };
            img.src = src1;
            //----------------------------------- make circlular nodes  ------------------------------
            ctx.lineWidth = 5;
            ctx.strokeStyle = "blue";
            ctx.fillStyle = 'white';
            ctx.arc(x, y, radius, startAngle, endAngle, false);
            ctx.stroke();
            ctx.fill();
            //----------------------------------  write names of nodes ----------------------------------
            var txt = this.trimTextForLarge(val.mappedAppName); //node name
            if (txt == '-') {
                var sourceNodeInfo = this.getSourceNodeInfo(val.sourceId).split("%%");
                txt = sourceNodeInfo[0];
                var tierN = sourceNodeInfo[1];
                var serverN = sourceNodeInfo[2];
                var appN = sourceNodeInfo[3];
            }
            ctx.font = "bold 15px serif";
            ctx.fillStyle = "green";
            ctx.fillText(txt, (x - radius), (y + radius + 17));
            if (arg != "lessDetail") {
                //-------------------------  forming content of tooltip box of node ------------------------
                ctx.font = font + "px serif";
                ctx.fillStyle = "black";
                var Str = [];
                var heightOfTooltip = 0;
                var widthOfTooltip = 190;
                if (val.tierName != '-') {
                    Str.push("Tier: " + val.tierName);
                    Str.push("Server: " + val.serverName);
                    Str.push("Instance: " + val.appName);
                    Str.push("Start Time: " + val.startDateTime);
                    heightOfTooltip += font * 4; //for three rows
                    if (val.cumFpDuration != val.avgFpDuration) {
                        Str.push("Total Duration: " + Number(val.cumFpDuration).toLocaleString() + "ms");
                        Str.push("Avg.Duration: " + Number(val.avgFpDuration).toLocaleString() + " ms");
                        heightOfTooltip += font * 2;
                    }
                    else {
                        Str.push("Total Duration: " + Number(val.avgFpDuration).toLocaleString() + "ms");
                        heightOfTooltip += font * 1;
                    }
                    Str.push("Percentage: " + Number(val.percentage).toFixed(1) + " %");
                    heightOfTooltip += font;
                }
                else if (val.mappedAppName == '-') //in case of Thread Call
                 {
                    Str.push("Tier: " + tierN);
                    Str.push("Server: " + serverN);
                    Str.push("Instance: " + appN);
                    heightOfTooltip = 3 * font;
                }
                else {
                    if (val.mappedAppName != this.encodeHTMLStr(val.backendActualName)) {
                        Str.push("Name: " + val.mappedAppName + "(" + this.encodeHTMLStr(val.backendActualName) + ")");
                    }
                    else {
                        Str.push("Name: " + this.encodeHTMLStr(val.backendActualName));
                    }
                    widthOfTooltip = ctx.measureText(Str[Str.length - 1]).width;
                    heightOfTooltip = font;
                }
                //---------------------------- making tooltip box -----------------------------------
                var dx = x - radius;
                var dy = y + radius + 17;
                var borderColor = "black";
                this.roundedRect(ctx, dx - 5, dy + 2, widthOfTooltip + padding, heightOfTooltip + padding, 10, borderColor, "nodeTooltip");
                //--------------------- writing text inside tooltip box of node --------------------
                dy += 15;
                ctx.font = " 15px serif";
                ctx.fillStyle = "black";
                for (var j = 0; j < Str.length; j++) {
                    ctx.fillText(Str[j], dx, dy, widthOfTooltip);
                    dy += 15;
                }
            }
        });
    }
    roundedRect(ctx, x, y, width, height, radius, borderColor, boxInfo) {
        ctx.beginPath();
        ctx.strokeStyle = borderColor;
        ctx.lineWidth = 1;
        ctx.fillStyle = "white";
        if (boxInfo == "nodeTooltip") {
            var gradient = ctx.createLinearGradient(x, y, x, y + height);
            gradient.addColorStop(0.6, '#ffffff');
            // if(borderColor == "red")
            //   gradient.addColorStop(1, 'red');
            //else
            gradient.addColorStop(1, 'rgb(100,200,255)');
            ctx.fillStyle = gradient;
        }
        // if(borderColor == "red")
        //  ctx.fillStyle = "red";
        //ctx.fillStyle = gradient;
        //ctx.fillStyle = "white";
        ctx.moveTo(x, y + radius);
        ctx.lineTo(x, y + height - radius);
        ctx.arcTo(x, y + height, x + radius, y + height, radius);
        ctx.lineTo(x + width - radius, y + height);
        ctx.arcTo(x + width, y + height, x + width, y + height - radius, radius);
        ctx.lineTo(x + width, y + radius);
        ctx.arcTo(x + width, y, x + width - radius, y, radius);
        ctx.lineTo(x + radius, y);
        ctx.arcTo(x, y, x, y + radius, radius);
        ctx.restore();
        ctx.fill();
        ctx.stroke();
        //ctx.fill();
    }
    getSourceNodeInfo(sourceId) {
        var returnStr = "";
        var sID = '#' + sourceId + ' .nodeHeading';
        var heading = jquery__WEBPACK_IMPORTED_MODULE_2__(sID).text();
        var returnStr = heading;
        var spn = jquery__WEBPACK_IMPORTED_MODULE_2__("#" + sourceId + " .tooltips  span").html(); //get the html tooltip content inside <span> of source
        var last = jquery__WEBPACK_IMPORTED_MODULE_2__("#" + sourceId + " .tooltips  span").html().indexOf("<b>Start");
        spn = spn.substring(0, last);
        var arr = spn.split("<br>");
        for (var i = 0; i < arr.length - 1; i++) {
            var ar = arr[i].split("&nbsp;");
            returnStr += "%%" + ar[1];
        }
        return returnStr;
    }
    timeVarianceInMs(time) {
        var timeVarianceInMs = time;
        var timeVarNum = "";
        if (/^[0-9]*h$/.test(time)) //If time is in hour formate- xh eg:2h means 2 hour variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = parseInt(timeVarNum) * 60 * 60 * 1000;
        }
        else if (/^[0-9]*m$/.test(time)) //If time is in minute formate- xm eg:20m means 20 minute  variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = parseInt(timeVarNum) * 60 * 1000;
        }
        else if (/^[0-9]*s$/.test(time)) //If time is in second formate- xs eg:200s means 200 second  variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = parseInt(timeVarNum) * 1000;
        }
        else if (/^[0-9]*ms$/.test(time)) //If time is in millisecond formate- xs eg:200ms means 200 millisecond  variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 2);
            timeVarianceInMs = parseInt(timeVarNum);
        }
        else if (/^[0-9]*$/.test(time)) // if there is only number, it is considered as seconds
         {
            timeVarianceInMs = parseInt(time) * 1000;
        }
        else {
            alert("Please provide value of 'NetDiagnosticsQueryTimeVariance' in proper format in config.ini i.e.- Nh or Nm or Ns or Nms or N where N is a integer ");
            return parseInt('900000'); //if value of ndQueryTimeVariance is not in desired format then NF report will open with default variance time that is 15 minutes(900000ms).
        }
        return parseInt(timeVarianceInMs);
    }
    openExceptionReport(rowData) {
        this._ddrData.splitViewFlag = false;
        console.log('rowData-->', rowData);
        if (rowData !== undefined) {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_11__["BREADCRUMB_ITEMS"].TRANSACTION_FLOWMAP;
            if (rowData.fpDuration == '< 1') {
                this.CommonServices.flowpathToExData = this.objofCurrentnode;
                // this.CommonServices.flowpathToExData.failedQuery = rowData.Query;
                // this.CommonServices.flowpathToExData.exceptionClassId = this.objofCurrentnode.exceptionClassId;
                this.CommonServices.flowpathToExData.fpDuration = 0;
                //this.CommonServices.flowpathToExData
            }
            else {
                this.CommonServices.flowpathToExData = this.objofCurrentnode;
                // this.CommonServices.flowpathToExData = rowData.;
                // this.CommonServices.flowpathToExData.failedQuery = rowData.Query;
                //  this.CommonServices.flowpathToExData.exceptionClassId = this.objofCurrentnode.exceptionClassId;
            }
        }
        if (this._router.url.indexOf('/home/ddrCopyLink/') != -1) {
            this._router.navigate(['/home/ddrCopyLink/exception']);
        }
        else if (this._router.url.indexOf('/home/ED-ddr') != -1) {
            this._router.navigate(['/home/ED-ddr/exception']);
        }
        else {
            this._router.navigate(['/ddr/exception']);
        }
    }
    sortColumnsOnCustom(event, tempData) {
        //for interger type data type
        if (event["field"] == "StartTime") {
            if (event.order == -1) {
                var temp = (event["field"]);
                event.order = 1;
                tempData = tempData.sort(function (a, b) {
                    var value = Date.parse(a[temp]);
                    var value2 = Date.parse(b[temp]);
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = (event["field"]);
                event.order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    var value = Date.parse(a[temp]);
                    var value2 = Date.parse(b[temp]);
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        else if (event["field"] == "Average") {
            if (event.order == -1) {
                var temp = (event["field"]);
                event.order = 1;
                tempData = tempData.sort(function (a, b) {
                    var value = Number(a[temp]);
                    var value2 = Number(b[temp]);
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = (event["field"]);
                event.order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    var value = Number(a[temp]);
                    var value2 = Number(b[temp]);
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        else {
            if (event.order == -1) {
                var temp = (event["field"]);
                event.order = 1;
                tempData = tempData.sort(function (a, b) {
                    var value = Number(a[temp].replace(/,/g, ''));
                    var value2 = Number(b[temp].replace(/,/g, ''));
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = (event["field"]);
                event.order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    var value = Number(a[temp].replace(/,/g, ''));
                    var value2 = Number(b[temp].replace(/,/g, ''));
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        this.transactionTableArray = [];
        //console.log(JSON.stringify(tempData));
        if (tempData) {
            tempData.map((rowdata) => { this.transactionTableArray = this.Immutablepush(this.transactionTableArray, rowdata); });
        }
    }
    popupForFpMiss() {
        var errMsg = "";
        if (this.flowmapData.isFPMissCase != false)
            errMsg = "Warning: One or more flow paths are not captured in the path shown by Red arrow(s).";
        //  if(this.flowmapData.isFpCheckMiss == false)
        //  errMsg ="WARNING: Since entry flowpath is missing hence showing flowmap for only current and it's child flowpaths."
        // this.showErrorNotificationForFpMiss(errMsg);
        // jQuery('#fpMissMsg').on('click',function(){
        //   if (jQuery('.notifyjs-wrapper').length<=0)
        //   showErrorNotificationForFpMiss(errMsg);
        //);
    }
    handleChange(event) {
        console.log('event', event);
        this.flowmapData.showOrigFlowmap = event.checked;
        this.CommonServices.loaderForDdr = true;
        this.flowmapData.isFirstRoot = true;
        console.log('val', this.flowmapData.showOrigFlowmap);
        if (this.flowmapData.showOrigFlowmap) {
            this.flowmapData.isFpCheckMiss = true;
            this.flowmapData.getDataForTxnFlowpath(this.flowmapData.paramsForFlowMap.flowpathInstance, this.flowmapData.paramsForFlowMap);
        }
        else {
            this.flowmapData.isFpCheckMiss = false;
            this.flowmapData.getDataForTxnFlowpath(this.flowmapData.paramsForFlowMap.flowpathInstance, this.flowmapData.paramsForFlowMap);
        }
    }
    showWarningMessgae() {
        this.waningPopup = true;
    }
    downloadReportForAgg(reportType) {
        let popuptitle = this.popupTitle;
        console.log('columns are--', this.col);
        this.aggRenameArray = {};
        this.aggColOrder = [];
        this.aggDownloadJson = JSON.parse(JSON.stringify(this.dbCalloutDetails));
        for (let i = 0; i < this.col.length; i++) {
            this.aggRenameArray[this.col[i]['field']] = this.col[i]['header'];
            this.aggColOrder.push(this.col[i]['header']);
        }
        let fieldKeys = Object.keys(this.aggRenameArray);
        this.aggDownloadJson.forEach((val, index) => {
            let keys = Object.keys(val);
            keys.forEach((val1) => {
                if (!fieldKeys.includes(val1)) {
                    delete val[val1];
                }
            });
        });
        if (reportType == 'excel') {
            popuptitle = popuptitle.replace(/:/g, '-');
        }
        let downloadObj = {
            downloadType: reportType,
            strSrcFileName: 'DBQueries',
            strRptTitle: popuptitle,
            renameArray: JSON.stringify(this.aggRenameArray),
            colOrder: this.aggColOrder.toString(),
            jsonData: JSON.stringify(this.aggDownloadJson),
            varFilterCriteria: this.popupFilter
        };
        console.log('download Obj---', downloadObj);
        let downloadFileUrl = '';
        // downloadFileUrl = this.flowmapData.hosturl + this.flowmapData.urlParam.product.replace('/', ""); // Due to A-9 migration check- download case..
        if (this.sessionService.preSession.multiDc === true) {
            downloadFileUrl = this.getHostUrl(true);
        }
        else {
            downloadFileUrl = this.getHostUrl(true) + "/";
        }
        downloadFileUrl += this.flowmapData.urlParam.product.replace('/', "") + '/v1/cavisson/netdiagnostics/ddr/downloadAngularReport';
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && (downloadFileUrl.includes("/tomcat") || downloadFileUrl.includes("/node"))) {  // Due to A-9 migration check- multiDc..
        if (this.sessionService.preSession.multiDc === true || (downloadFileUrl.includes("/tomcat") || downloadFileUrl.includes("/node"))) {
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, (downloadObj)).subscribe(res => (this.openDownloadReports(res)));
        }
        else {
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, JSON.stringify(downloadObj)).subscribe(res => (this.openDownloadReports(res)));
        }
    }
    openDownloadReports(res) {
        console.log('file name generate ===', res);
        let downloadFileUrl = '';
        downloadFileUrl = (this.flowmapData.hosturl.substring(0, this.flowmapData.hosturl.lastIndexOf("/")) + '/common/' + res);
        window.open(downloadFileUrl);
    }
    showNotification() {
        this.CommonServices.showSuccess('Query has been copied successfully');
    }
    setIpPort(objForRouting) {
        if (this.flowmapData.ndeInfoData.length > 0) {
            for (var i = 0; i < this.flowmapData.ndeInfoData.length; i++) {
                var val = this.flowmapData.ndeInfoData[i];
                if (val.ndeId == this.drilInfoData.ndeId) {
                    if (this._ddrData.nodeKey == '1') {
                        this._ddrData.protocolTr = location.protocol.split(":")[0];
                        this._ddrData.hostTr = location.host.split(":")[0];
                        this._ddrData.portTr = location.host.includes(":") ? location.host.split(":")[1] + "/tomcat/" + val.displayName : "/tomcat/" + val.displayName;
                        this._ddrData.dcNameTr = val.displayName;
                        if (location.host.includes(":")) {
                            if (!location.host.split(":")[1]) {
                                if (location.protocol.includes("https"))
                                    this._ddrData.portTr = "443" + "/" + val.displayName;
                                else
                                    this._ddrData.portTr = "80" + "/" + val.displayName;
                            }
                        }
                        if (val.ndeTestRun)
                            this._ddrData.testRunTr = val.ndeTestRun;
                        else
                            this._ddrData.testRunTr = this._ddrData.testRun;
                    }
                    else {
                        this._ddrData.hostTr = val.ndeIPAddr;
                        this._ddrData.portTr = val.ndeTomcatPort;
                        this._ddrData.protocolTr = val.ndeProtocol;
                        if (val.ndeTestRun)
                            this._ddrData.testRunTr = val.ndeTestRun;
                        else
                            this._ddrData.testRunTr = this._ddrData.testRun;
                        this._ddrData.dcNameTr = val.displayName;
                    }
                    this._ddrData.isFromtrxFlow = true;
                    this.CommonServices.host = undefined;
                    this.CommonServices.testRun = undefined;
                }
            }
        }
    }
};
DdrTransactionFlowmapComponent.ctorParameters = () => [
    { type: _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_3__["DdrTxnFlowmapDataService"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Renderer2"] },
    { type: _services_ddr_transactio_individual_info_service__WEBPACK_IMPORTED_MODULE_4__["DdrTransactioIndividualInfoService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_5__["CommonServices"] },
    { type: _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_6__["CavTopPanelNavigationService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_7__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_9__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["DdrBreadcrumbService"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_8__["CavConfigService"] },
    { type: _angular_common_http__WEBPACK_IMPORTED_MODULE_12__["HttpClient"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_15__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_17__["BreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_18__["SessionService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], DdrTransactionFlowmapComponent.prototype, "columnData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('contextRef')
], DdrTransactionFlowmapComponent.prototype, "contextRef", void 0);
DdrTransactionFlowmapComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ddr-transaction-flowmap',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr-transaction-flowmap.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr-transaction-flowmap.component.css */ "./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.css")).default]
    })
], DdrTransactionFlowmapComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/exception-report/exception-report.component.scss":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/exception-report/exception-report.component.scss ***!
  \***************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("exception-report a.activeLink {\n  pointer-events: none;\n}\nexception-report .customPaginator {\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  border-style: solid;\n  border-width: 1px;\n  border-top: none;\n  padding-left: 5px;\n}\nexception-report .customPaginator .ui-paginator {\n  border: none;\n}\nexception-report .butPosition {\n  position: absolute;\n  right: 8px;\n  top: 21px;\n  z-index: 5;\n  display: inline-block;\n}\nexception-report .monaco-highlighted-line {\n  background-color: rgba(255, 255, 0, 0.3) !important;\n  border-left: 3px solid yellow !important;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/exception-report/exception-report.component.ts":
/*!*************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/exception-report/exception-report.component.ts ***!
  \*************************************************************************************/
/*! exports provided: ExceptionReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ExceptionReportComponent", function() { return ExceptionReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_configuration_nd_config_services_timer_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/timer.service */ "./src/app/pages/tools/configuration/nd-config/services/timer.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_9__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");















let ExceptionReportComponent = class ExceptionReportComponent {
    constructor(commonService, _router, _ddrData, messageService, _timerService, breadcrumbService, sessionService, ddrRequest, breadcrumb, ndDdrHttpService) {
        this.commonService = commonService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.messageService = messageService;
        this._timerService = _timerService;
        this.breadcrumbService = breadcrumbService;
        this.sessionService = sessionService;
        this.ddrRequest = ddrRequest;
        this.ndDdrHttpService = ndDdrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_9__; // Reference to Highcharts library
        this.toggleWindow = new _angular_core__WEBPACK_IMPORTED_MODULE_2__["EventEmitter"](); // Event emitter for toggling window
        this.exceptionDetail = [{ timeStamp: "", flowPathInstance: "", exceptionClassName: "", message: "", throwingClassName: "", throwingMethodName: "", lineNumber: "", stackTrace: "", stackTraceID: "", exceptionClassId: "", messageId: "", tierName: "", serverName: "", appName: "", tierId: 0, serverId: 0, appId: 0, cause: "", causeId: "", backendId: "", startTime: "", throwingClassId: "", throwingMethodId: "", startTimeInMS: "" }];
        this.aggHeaderInfo = ""; // Header information for aggregated exceptions
        this.filteredexceptionInfo = []; // Filtered exception information
        this.stackData = ""; // Stack data information
        this.showCode = false; // Flag indicating if code is shown
        this.exClassName = ""; // Exception class name
        this.cls = ""; // Class name
        this.classVariables = ""; // Class variables information
        this.localVariables = ""; // local variables information
        this.methodVariables = ""; // method variables information
        this.dialogHeaderName = ""; // Header name for dialog
        this.showChart = false; // Flag indicating if chart is shown
        this.expClassName = ""; // Exception class name
        this.expMethodName = ""; // Exception method name
        this.expLineNo = ""; // Exception line number
        this.headerInfo = ""; // Header information
        this.tableHeader = ""; // Table header
        this.stackTraceHeader = ""; // Stack trace header
        this.stackTraceHeaderTooltip = ""; // Tooltip for stack trace header
        this.showAllOption = false; // Flag indicating if all options are shown
        this.showInsideObjPopup = false; // Flag indicating if inside object popup is shown
        this.totalIndex = "";
        this.headerInsideObj = ""; // Header for inside object
        this.classFileName = ""; // Class file name
        this.classMethodFileName = ""; // Class method file name
        this.classVarArgsArr = []; // Array of class variable arguments
        this.methodVarArgsArr = []; // Array of method variable arguments
        this.localVarArgsArr = []; // Array of local variable arguments
        this.ThreadLocalVarArgsArr = []; // Array of thread local variable arguments
        this.lastNLogsStr = ""; // String representation of last N logs
        this.stackTraceHeaderInfo = ""; // Header information for stack trace
        this.showDownLoadReportIcon = false;
        this.showDownloadSourceCodeIcon = true; // Flag indicating if download source code icon is shown
        this.totalMethodVars = 0; // Total method variables count
        this.toalClassVars = 0; // Total class variables count
        this.totalLocalVars = 0; // Total local variables count
        this.totalThreadVars = 0; // Total thread variables count
        this.toolTipText = ""; // Tooltip text
        this.loader = false; // Flag indicating if loader is active
        this.value = 1;
        this.limit = 50;
        this.offset = 0;
        this.agglimit = 50; // Aggregated limit
        this.aggoffset = 0; // Aggregated offset
        this.totalCount = 0; // Total count
        this.rowChangeKey = "NA"; // Row change key
        this.paginatorArr = [10]; // Array of paginator values
        this.paginatorArrST = [10]; // Array of paginator values for stack traces
        this.lastNLogJson = []; // Array of last N log JSON objects
        this.classVarArgsJson = []; // Array of class variable arguments JSON objects
        this.methodVarArgsJson = []; // Array of method variable arguments JSON objects
        this.localVarArgsJson = []; // Array of local variable arguments JSON objects
        this.ThreadLocalVarArgsJson = []; // Array of thread local variable arguments JSON objects
        this.isFilterFromSideBar = false; // Flag indicating if filter is applied from sidebar
        this.filterTierName = ''; // Filter for tier name
        this.filterServerName = ''; // Filter for server name
        this.filterInstanceName = ''; // Filter for instance name
        this.filterGroupBy = ''; // Filter for group by
        this.filterOrderByStr = ''; // Filter for order by string
        this.completeTier = ''; // Variable is used for Complete tier information
        this.completeServer = ''; // Variable is used for Complete server information
        this.completeInstance = ''; // Variable is used for Complete instance information
        this.completeGroupBy = ''; // Complete group by
        this.filterGroupByStr = ''; // Complete group by string
        this.completeOrderBy = ''; // Complete order by
        this.relativePathForException = "ddr/exception-report/exception.json"; // Relative path for exception report JSON
        this.relativePathForStackTrace = "ddr/exception-report/stacktrace.json"; // Relative path for stack trace JSON
        this.relativePathForLastNLog = "ddr/exception-report/logs.json"; // Relative path for last N log JSON
        this.relativePathForClassVar = "ddr/exception-report/classVariables.json"; // Relative path for class variables JSON
        this.relativePathForMethodVar = "ddr/exception-report/methodArguments.json"; // Relative path for method variables JSON
        this.relativePathForLocalVar = "ddr/exception-report/localVariables.json"; // Relative path for local variables JSON
        this.relativePathForThreadLocal = "ddr/exception-report/threadLocalVariables.json"; // Relative path for threadlocal variables JSON
        this.timeVarienceForNF = "900";
        this.showPagination = false; // Flag indicating if pagination is shown
        this.showPaginationEX = false; // Flag indicating if pagination for exceptions is shown
        this.isCancelQuery = false; // Flag indicating if query cancellation is active
        this.isCancelQuerydata = false; // Flag indicating if data query cancellation is active
        this.monacoEditorContent = ''; // holds the code to display
        this.highlightedLine = -1; // stores which line to highlight
        this.monacoHighlightDecorationIds = [];
        this.compareFPInfo = {};
        this.AggData = [{ "exceptionclassid": "", "ExceptionClassName": "", "exceptionmessageid": "", "Message": "", "exceptioncauseid": "", "Cause": "", "StackTraceCount": "", "ExceptionCount": "", "TierName": "", "Tierid": "", "ServerName": "", "Serverid": "", "AppName": "", "Appid": "", "TransactionName": "", "TransactionIndex": "", "PageName": "", "PageIndex": "", "SessionName": "", "SessionIndex": "", "URLName": "", "URLIndex": "", "FlowPathSignature": "", "exceptionthrowingclassid": "", "ThrowingClassName": "", "exceptionthrowingmethodid": "", "ThrowingMethodName": "" }];
        this.showLink = true;
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.firstException = { first: 0 };
        this.rowsException = { rows: 50 };
        this.breadcrumb = breadcrumb;
        let tableConfigAggExc = {
            config: {
                globalFilter: true,
                toggleFilter: true,
                rowSelection: true
            },
            "tableAction": [
                {
                    "iconType": "icon",
                    "iconClass": "las-undo-alt-solid",
                    "toolTip": "Show All data",
                    "action": "showalldata",
                    "needRowData": true
                }
            ]
        };
        this.tableConfigAgg = tableConfigAggExc;
    }
    ngOnInit() {
        var _a, _b;
        this.fromhstoExpFlag = this.commonService.fromhstoExpFlag;
        this.hstoexData = this.commonService.hstoexData;
        this.seqDiagToExpData = this.commonService.seqDiagToExceptionData;
        this.first.first = 0;
        this.rows.rows = 50;
        this.firstException.first = 0;
        this.rowsException.rows = 50;
        this.queryId1 = this.randomNumber();
        if (!this._ddrData.isFromCompareFp) {
            this.breadcrumb.add({ label: 'Exceptions', routerLink: '/ddr/exception' });
        }
        if (this.breadcrumbService.parentComponent == _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].IPSTAT && this._ddrData.splitViewFlag == false) {
            this.commonService.isToLoadSideBar = false;
            this.tableHeader = "";
            this.stackTraceHeader = "";
        }
        if (this.commonService.exceptionFilters['source'] != "FlowpathReport")
            this.commonService.currentReport = "Exception";
        if (this._ddrData.splitViewFlag == false)
            this.screenHeight = Number(this.commonService.screenHeight) - 135;
        else
            this.screenHeight = Number(this.commonService.screenHeight) - 235;
        if (Object.keys(this.compareFPInfo).length == 0 && this._ddrData.splitViewFlag == false) {
            this.id = this.commonService.getData();
        }
        if (this.commonService.testRun != undefined && this.commonService.testRun != null && this.commonService.testRun != '') {
            this.id.testRun = this.commonService.testRun;
        }
        if (this.id.product == undefined && this.commonService.seqDiagToExceptionFlag == false)
            this.id.product = this.id.ipWithProd.split("%2F")[1];
        this.reportHeader = 'Exception Report- ' + this.id.testRun;
        if (Object.keys(this.compareFPInfo).length == 0 && this._ddrData.splitViewFlag == false) {
            this.commonService.isToLoadSideBar = true;
            this.fillData();
        }
        if (this._ddrData.splitViewFlag) {
            this.fillData();
        }
        this.setTestRunInHeader();
        if (this._ddrData.isFromTrxnFlowmap) {
            this.relativePathForException = "ddr/exception-report/exception_to_Logs.json";
        }
        this.sideBarException = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Exception") {
                this.commonService.isFilterFromSideBar = true;
                let keys = Object.keys(temp);
                this.agglimit = 50;
                this.offset = 0;
                this.getaggregatedData();
            }
        });
        const langType = (_b = (_a = this.id.Instance_Type) !== null && _a !== void 0 ? _a : this.columnData.Instance_Type) !== null && _b !== void 0 ? _b : 'java';
        this.monacoEditorOptions = {
            theme: 'vs-light',
            language: this.getMonacoLanguage(langType),
            readOnly: true,
            automaticLayout: true,
            scrollBeyondLastLine: false,
            minimap: { enabled: false },
            fontSize: 13,
            wordWrap: 'on',
            scrollbar: {
                vertical: 'auto',
                horizontal: 'auto'
            }
        };
    }
    updateIdParam() {
        let endTime = 0;
        if (undefined != this.compareFPInfo.fpDuration) {
            if (this.compareFPInfo.fpDuration.toString().includes(','))
                endTime = Number(this.compareFPInfo.startTimeInMs) + Number(this.compareFPInfo.fpDuration.toString().replace(/,/g, ""));
            else if (this.compareFPInfo.fpDuration == '< 1')
                endTime = Number(this.compareFPInfo.startTimeInMs) + Number(0);
            else
                endTime = Number(this.compareFPInfo.startTimeInMs) + Number(this.compareFPInfo.fpDuration);
        }
        this.id['startTime'] = this.compareFPInfo['startTimeInMs'];
        this.id['endTime'] = endTime + "";
        this.id['tierId'] = this.compareFPInfo['tierId'];
        this.id['serverId'] = this.compareFPInfo['serverId'];
        this.id['appId'] = this.compareFPInfo['appId'];
        this.id['tierName'] = this.compareFPInfo['tierName'];
        this.id['serverName'] = this.compareFPInfo['serverName'];
        this.id['appName'] = this.compareFPInfo['appName'];
        this.id['flowPathInstance'] = this.compareFPInfo['flowpathInstance'];
    }
    ngOnChanges(changes) {
        if (this._ddrData.splitViewBreadCrumbFlag && this._ddrData.splitViewFlag) {
            if (this.columnData) {
                this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            }
            this.breadcrumb.add({ label: 'Exceptions' });
        }
        else if (!this._ddrData.isFromCompareFp) {
            if (this.columnData) {
                this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            }
            this.breadcrumb.add({ label: 'Exceptions' });
            this._ddrData.splitViewBreadCrumbFlag = true;
        }
        if (this._ddrData.splitViewFlag)
            this._ddrData.setInLogger('DDR::Flowpath', "Exception", "Open Exception Summary Report");
        this.queryId1 = this.randomNumber();
        if (this.columnData != undefined) {
            this.tableHeader = "";
            this.stackTraceHeader = "";
            this.commonService.flowpathToExData = JSON.parse(JSON.stringify(this.columnData));
            this._ddrData.flowpathToExFlag = true;
            this.id = JSON.parse(JSON.stringify(this.columnData));
            this.commonService.enableQueryCaching = this.commonService.enableQueryCaching;
            this.getaggregatedData();
        }
        else {
            this.id = this.commonService.getData();
            this.updateIdParam();
            if (Object.keys(this.compareFPInfo).length > 0)
                this.fillData();
        }
        this.showCode = false;
        // this.dt1.selection = [];
    }
    fillData() {
        if (this._ddrData.splitViewFlag == false)
            this.getaggregatedData();
    }
    createDynamicColumns() {
        this.colsForAggException = [];
        this.colsForAggException[0] = {
            cols: []
        };
        let exParam = this.commonService.exceptionFilters;
        const columnMapping = {
            'url': { label: 'Business Transaction', key: 'URLName' },
            'tier': { label: 'Tier', key: 'tierName' },
            'server': { label: 'Server', key: 'serverName' },
            'app': { label: 'Instance', key: 'appName' },
            'page': { label: 'Page', key: 'pageName' },
            'session': { label: 'Session', key: 'sessionName' },
            'transaction': { label: 'Transaction', key: 'transactionName' },
            'excclass': { label: 'Exception Class', key: 'exceptionClassName' },
            'excthrowingclass': { label: 'Throwing Class', key: 'throwingClassName' },
            'excthrowingmethod': { label: 'Throwing Method', key: 'throwingMethodName' },
            'excmessage': { label: 'Message', key: 'message' },
            'exccause': { label: 'Cause', key: 'cause' }
        };
        let newColumns = [];
        // Add columns based on groupby
        for (let groupKey in columnMapping) {
            if (exParam['groupby'].indexOf(groupKey) !== -1) {
                newColumns.push({
                    label: columnMapping[groupKey].label,
                    selected: true,
                    key: columnMapping[groupKey].key,
                    width: '80px',
                    type: 0
                });
            }
        }
        // Always include Exception Count column
        newColumns.push({
            label: 'Exception Count',
            selected: true,
            key: 'exceptionCount',
            width: '80px',
            type: 1
        });
        // Update the columns array
        this.colsForAggException[0].cols = newColumns;
    }
    //For Aggregate table
    getaggregatedData() {
        var _a;
        if (this.agglimit == 0)
            this.agglimit = 50;
        let url = '';
        let finalUrl = '';
        let urlAjaxParam = '';
        let flag = '';
        let testRun;
        if (this.commonService.testRun)
            testRun = this.commonService.testRun; //Handling multi dc side bar case
        else
            testRun = this.id.testRun;
        if (this.commonService.enableQueryCaching == 1) {
            url += "cacheId=" + testRun + "&testRun=" + testRun;
        }
        else {
            url += "testRun=" + testRun;
        }
        if (this.commonService.isFilterFromSideBar && Object.keys(this.commonService.exceptionFilters).length != 0) // sidebar filters to Exception
         {
            this.isFilterFromSideBar = true;
            let exParam = this.commonService.exceptionFilters;
            if (this.commonService.isValidParamInObj(exParam, 'pubicIP') && this.commonService.isValidParamInObj(exParam, 'publicPort') && this.commonService.isValidParamInObj(exParam, 'ndeTestRun')) {
                if (this.commonService.enableQueryCaching == 1) {
                    url = 'cacheId=' + exParam['ndeTestRun'] + '&testRun=' + exParam['ndeTestRun'];
                }
                else {
                    url = 'testRun=' + exParam['ndeTestRun'];
                }
            }
            urlAjaxParam = this.commonService.makeParamStringFromObj(exParam);
            this.limit = 50; // setting limit for second table
        }
        else {
            if (this._ddrData.flowpathToExFlag === true) {
                if (this.commonService.flowpathToExData.totalError && Number(this.commonService.flowpathToExData.totalError) > 0) {
                    this.commonService.flowpathToExData.failedQuery = 1;
                }
                let endTime = Number(this.commonService.flowpathToExData.startTimeInMs) + Number((_a = this.commonService.flowpathToExData.fpDuration) === null || _a === void 0 ? void 0 : _a.toLocaleString().replace(/,/g, ""));
                endTime = endTime + 1000;
                let startTime = Number(this.commonService.flowpathToExData.startTimeInMs);
                urlAjaxParam += "&flowPathInstance=" + this.commonService.flowpathToExData.flowpathInstance +
                    "&tierName=" + this.commonService.flowpathToExData.tierName + "&tierid=" + this.commonService.flowpathToExData.tierId +
                    "&serverName=" + this.commonService.flowpathToExData.serverName + "&serverid=" + this.commonService.flowpathToExData.serverId +
                    "&appName=" + this.commonService.flowpathToExData.appName + "&appid=" + this.commonService.flowpathToExData.appId +
                    "&strStartTime=" + startTime + "&strEndTime=" + endTime +
                    "&backendName=" + this.id.backendNameQuery + "&backendSubType=" + this.id.backendSubType +
                    "&exceptionClassId=" + this.id.exceptionClassId + "&failedQuery=" + this.commonService.flowpathToExData.failedQuery +
                    "&backendid=" + this.id.backendid;
                this.id.failedQuery = this.commonService.flowpathToExData.failedQuery; //updating as because of no case for flowpathToExFlag in exception report rest call
                this.id.flowPathInstance = this.commonService.flowpathToExData.flowpathInstance;
                this.id.serverId = this.commonService.flowpathToExData.serverId;
                this.id.appId = this.commonService.flowpathToExData.appId;
                this.id.startTime = startTime;
                this.id.endTime = endTime;
                this.limit = 50; // setting limit for second table
            }
            else if (this.commonService.fromDBtoExpFlag == true) {
                urlAjaxParam += "&flowPathInstance=" + this.commonService.fromDBtoExpData.flowpathInstance +
                    "&tierName=" + this.commonService.fromDBtoExpData.tierName + "&tierid=" + this.commonService.fromDBtoExpData.tierId +
                    "&serverName=" + this.commonService.fromDBtoExpData.serverName + "&serverid=" + this.commonService.fromDBtoExpData.serverId +
                    "&appName=" + this.commonService.fromDBtoExpData.appName + "&appid=" + this.commonService.fromDBtoExpData.appId +
                    "&strStartTime=" + this.id.startTime + "&strEndTime=" + (Number(this.id.endTime) + 1000) +
                    "&backendName=" + this.id.backendNameQuery + "&backendSubType=" + this.commonService.fromDBtoExpData.sqlIndex +
                    "&exceptionClassId=" + this.id.exceptionClassId + "&failedQuery=1" +
                    "&backendid=" + this.id.backendid;
            }
            else if (this.fromhstoExpFlag) {
                urlAjaxParam += "&tierName=" + this.hstoexData.tierName + "&tierid=" + this.hstoexData.tierId +
                    "&serverName=" + this.hstoexData.serverName + "&serverid=" + this.hstoexData.serverId +
                    "&appName=" + this.hstoexData.appName + "&appid=" + this.hstoexData.appId + "&flowPathInstance=" + this.hstoexData.fpInst +
                    "&strStartTime=" + this.hstoexData.startTime + "&strEndTime=" + (Number(this.hstoexData.endTime) + 1000) +
                    "&backendid=" + this.hstoexData.backendId + "&seqno=" + this.hstoexData.seqno + "&groupby=excthrowingclass,excthrowingmethod,excclass" + "&calloutError=true";
                this.id.startTime = this.hstoexData.startTime;
                this.id.endTime = this.hstoexData.endTime;
            }
            else if (this.commonService.seqDiagToExceptionFlag == true) {
                urlAjaxParam += "&flowPathInstance=" + this.seqDiagToExpData.flowpathInstance + "&tierName="
                    + this.seqDiagToExpData.tierName + "&serverName=" + this.seqDiagToExpData.serverName + "&appName=" + this.seqDiagToExpData.appName +
                    "&tierid=" + this.seqDiagToExpData.tierId + "&serverid=" + this.seqDiagToExpData.serverId + "&appid=" + this.seqDiagToExpData.appId +
                    "&strStartTime=" + this.seqDiagToExpData.startTimeInMs + "&strEndTime=" + Number((this.seqDiagToExpData.endTimeInMs) + 1000) + "&failedQuery=" + this.seqDiagToExpData.failedQuery +
                    "&backendid=" + this.seqDiagToExpData.backendid + "&seqno=" + this.seqDiagToExpData.seqNo + "&backendSubType=" + this.seqDiagToExpData.backendSubType;
            }
            else {
                urlAjaxParam += "&flowPathInstance=" + this.id.flowPathInstance + "&tierName=" + this.id.tierName + "&serverName=" +
                    this.id.serverName + "&appName=" + this.id.appName + "&tierid=" + this.id.tierid + "&serverid=" + this.id.serverid +
                    "&appid=" + this.id.appid + "&strStartTime=" + this.id.startTime + "&strEndTime=" + (Number(this.id.endTime) + 1000) +
                    "&failedQuery=" + this.id.failedQuery + "&backendid=" + this.id.backendid + "&backendName=" +
                    this.id.backendNameQuery + "&backendSubType=" + this.id.backendSubType + "&exceptionClassId=" +
                    this.id.exceptionClassId;
            }
            urlAjaxParam += "&groupby=excthrowingclass,excthrowingmethod,excclass" + "&groupByFC=Exception Class,Throwing Class,Throwing Method";
            if (this._ddrData.exceptionClsName)
                urlAjaxParam += "&excepClsName=" + this._ddrData.exceptionClsName;
            this.urlAjaxParamObject = this.commonService.makeObjectFromUrlParam(urlAjaxParam);
            this.commonService.exceptionFilters = this.urlAjaxParamObject;
        }
        finalUrl = url + urlAjaxParam + "&limit=" + this.agglimit + "&offset=" + this.aggoffset + "&queryId=" + this.queryId1;
        this.isCancelQuerydata = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        this.ndDdrHttpService.getGroupedExceptionReportData(finalUrl).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["GroupedExceptionReportLoadedState"]) {
                this.getAggData(state.data);
            }
        }, (error) => {
            console.error('Error loading: ', error);
            this.loader = false;
            this.messageService.showError(error);
        });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName;
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.id.testRun = this._ddrData.testRun;
            this.testRun = this._ddrData.testRun;
            if (hostDcName.lastIndexOf('ALL/') !== -1)
                hostDcName = hostDcName.substring(0, hostDcName.lastIndexOf('/'));
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        return hostDcName;
    }
    createPieChart(res) {
        let groupChart = '';
        if (res.startTime && !isNaN(res.startTime))
            this.commonService.exceptionFilters['startTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.startTime), "MM/DD/YYYY HH:mm:ss");
        if (res.endTime && !isNaN(res.endTime))
            this.commonService.exceptionFilters['endTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.endTime), "MM/DD/YYYY HH:mm:ss");
        this.chartData = res.data;
        let exParam = this.commonService.exceptionFilters;
        if (this.chartData.length == 0) {
            this.showChart = false;
        }
        else {
            this.showChart = true;
        }
        if (res.hasOwnProperty('Status')) {
            this.messageService.showError(res.Status);
        }
        var exceptionInfoArr = [];
        for (var j = 0; j < this.chartData.length; j++) {
            groupChart = '';
            if (exParam['groupby'].indexOf('excclass') != -1) {
                groupChart = this.chartData[j]["ExceptionClassName"] + ",";
            }
            if (exParam['groupby'].indexOf('excthrowingclass') != -1) {
                groupChart += this.chartData[j]["ThrowingClassName"] + ",";
            }
            if (exParam['groupby'].indexOf('excthrowingmethod') != -1) {
                groupChart += this.chartData[j]["ThrowingMethodName"] + ",";
            }
            if (exParam['groupby'].indexOf('tier') != -1) {
                groupChart += this.chartData[j]["TierName"] + ",";
            }
            if (exParam['groupby'].indexOf('server') != -1) {
                groupChart += this.chartData[j]["ServerName"] + ",";
            }
            if (exParam['groupby'].indexOf('app') != -1) {
                groupChart += this.chartData[j]["appName"] + ",";
            }
            if (exParam['groupby'].indexOf('url') != -1) {
                groupChart += this.chartData[j]["URLName"] + ",";
            }
            if (exParam['groupby'].indexOf('AppName') != -1) {
                groupChart += this.chartData[j]["BTCategory"] + ",";
            }
            if (exParam['groupby'].indexOf('page') != -1)
                groupChart += this.chartData[j]["PageName"] + ",";
            if (exParam['groupby'].indexOf('session') != -1)
                groupChart += this.chartData[j]["SessionName"] + ",";
            if (exParam['groupby'].indexOf('transaction') != -1)
                groupChart += this.chartData[j]["TransactionName"] + ",";
            if (exParam['groupby'].indexOf('excmessage') != -1)
                groupChart += this.chartData[j]["Message"] + ",";
            if (exParam['groupby'].indexOf('exccause') != -1)
                groupChart += this.chartData[j]["Cause"];
            if (groupChart.endsWith(',')) {
                groupChart = groupChart.substring(0, groupChart.length - 1);
            }
            var exClass = this.chartData[j]["ExceptionClassName"];
            exceptionInfoArr.push({ "name": groupChart, "y": Number(this.chartData[j]["ExceptionCount"]) });
        }
        this.options = {
            chart: {
                type: 'pie',
            },
            credits: {
                enabled: false
            },
            title: { text: 'Group By Exceptions', style: { 'fontSize': '13px' } },
            legend: {
                itemWidth: 400
            },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>, Count: <b> {point.y}</b>'
            },
            plotOptions: {
                pie: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    dataLabels: {
                        enabled: false,
                        format: '<b> {point.name} </b>: {point.percentage:.2f} %',
                    },
                    showInLegend: true
                }
            },
            exporting: {
                enabled: false
            },
            series: [
                {
                    name: 'Percentage',
                    data: exceptionInfoArr,
                    enableMouseTracking: true
                }
            ]
        };
    }
    showExceptions(nodeData) {
        this.showCode = false;
        if (nodeData.data != undefined)
            nodeData = nodeData.data;
        this.getExceptionData(nodeData);
        this.getExceptionDataCount(nodeData);
        this.tableHeader = '';
        this.stackTraceHeader = '';
        if (nodeData['exceptionClassName'] != 'NA') {
            this.tableHeader = ":" + nodeData['exceptionClassName'];
            this.stackTraceHeader = "Exception: " + nodeData['exceptionClassName'];
        }
        if (nodeData['throwingClassName'] != 'NA') {
            this.tableHeader += ", Throwing Class: " + nodeData['throwingClassName'];
            this.stackTraceHeader += ", Throwing Class: " + nodeData['throwingClassName'];
        }
        if (nodeData['throwingMethodName'] != 'NA') {
            this.tableHeader += ", Throwing Method: " + nodeData['throwingMethodName'];
            this.stackTraceHeader += ", Throwing Method: " + nodeData['throwingMethodName'];
        }
        if (nodeData['URLName'] != 'NA') {
            this.tableHeader += ", BT: " + nodeData['URLName'];
            this.stackTraceHeader += ", BT: " + nodeData['URLName'];
        }
        if (nodeData['message'] && nodeData['message'] != 'NA' && nodeData['message'] != "-") {
            this.tableHeader += ", Message: " + nodeData['message'];
        }
        if (this.tableHeader.startsWith(','))
            this.tableHeader = this.tableHeader.substring(1);
        if (this.stackTraceHeader.startsWith(','))
            this.stackTraceHeader = this.stackTraceHeader.substring(1);
    }
    createSplineChart(data, type) {
        data = this.exceptionInfo;
        let items = {};
        var key;
        for (var k = 0; k < data.length; k++) {
            var key = data[k]['startTimeInMS'];
            if (!items[key]) {
                items[key] = 1;
            }
            else
                items[key] = items[key] + 1;
        }
        let outputArr = [];
        let timestamp = [];
        timestamp = Object.keys(items);
        timestamp.forEach((val, index) => {
            outputArr.push([+val, items[val]]);
        });
        outputArr.sort(function (a, b) {
            var value = a[0];
            var value1 = b[0];
            return (value > value1) ? 1 : ((value < value1) ? -1 : 0);
        });
        this.options1 = {
            chart: {
                type: 'spline',
                zoomType: 'x'
            },
            title: {
                text: 'Exceptions',
                style: { 'fontSize': '13px' }
            },
            credits: {
                enabled: false
            },
            xAxis: {
                type: 'datetime',
                title: {
                    text: 'Exception By Time'
                }
            },
            yAxis: {
                title: {
                    text: 'Exception By Count'
                },
                allowDecimals: false,
                min: 0
            },
            tooltip: {
                headerFormat: '<b>{series.name}:</b>{point.x:%m/%d/%y %H:%M:%S}<br>',
                pointFormat: '<b>Count:</b> {point.y}'
            },
            time: {
                timezoneOffset: this.timeZoneOffset
            },
            plotOptions: {
                spline: {
                    marker: {
                        enabled: true
                    }
                }
            },
            exporting: {
                enabled: false
            },
            series: [{
                    showInLegend: false,
                    name: 'StartTime',
                    data: outputArr,
                    tooltip: { xDateFormat: '%d-%m-%Y %H:%M:%S', valueSuffix: '' }
                }]
        };
    }
    showAllAggData() {
        this.filteredAggregateExceptionInfo = this.aggregateExceptionInfo;
        this.aggHeaderInfo = "";
        this.showAllOption = false;
    }
    getExceptionData(nodeData) {
        this.nodeDataInfo = nodeData;
        let exParam = this.commonService.exceptionFilters;
        let commonParam = '';
        let ajaxParam = '';
        var url = '';
        if (this.limit === 0) {
            this.limit = 50;
        }
        if (this.rowChangeKey == "NA")
            this.rowChangeKey = nodeData.exceptionclassid + "_" + nodeData.throwingClassId + "_" + nodeData.throwingMethodId;
        if (this.rowChangeKey != "NA") {
            var newKey = nodeData.exceptionclassid + "_" + nodeData.throwingClassId + "_" + nodeData.throwingMethodId;
            if (this.rowChangeKey != newKey) {
                this.rowChangeKey = newKey;
                this.limit = 50;
                this.offset = 0;
            }
        }
        if (this.id.strGraphKey == "WholeScenario") {
            this.id.startTime = "NA";
            this.id.endTime = "NA";
        }
        if (this.commonService.enableQueryCaching == 1) {
            url += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun;
        }
        else {
            url += "testRun=" + this.id.testRun;
        }
        if (nodeData.Tierid && nodeData.Tierid != "NA") {
            commonParam += "&tierid=" + nodeData.Tierid + "&tierName=" + nodeData.TierName;
        }
        else {
            commonParam += "&tierid=" + this.id.tierId + "&tierName=" + this.id.tierName;
        }
        if (nodeData.Serverid && nodeData.Serverid != "NA") {
            commonParam += "&serverid=" + nodeData.Serverid + "&serverName=" + nodeData.ServerName;
        }
        else {
            commonParam += "&serverid=" + this.id.serverId + "&serverName=" + this.id.serverName;
        }
        if (nodeData.Appid && nodeData.Appid != "NA") {
            commonParam += "&appid=" + nodeData.Appid + "&appName=" + nodeData.AppName;
        }
        else {
            commonParam += "&appid=" + this.id.appId + "&appName=" + this.id.appName;
        }
        commonParam += "&exceptionClassId=" + nodeData.exceptionclassid + "&throwingMethodId=" +
            nodeData.throwingMethodId + "&throwingClassId=" + nodeData.throwingClassId + "&pagination= --limit " +
            this.limit + " --offset " + this.offset;
        if (this.isFilterFromSideBar) {
            if (this.commonService.isValidParamInObj(exParam, 'pubicIP') && this.commonService.isValidParamInObj(exParam, 'publicPort') && this.commonService.isValidParamInObj(exParam, 'ndeTestRun')) {
                if (this.commonService.enableQueryCaching == 1) {
                    url = 'cacheId=' + exParam['ndeTestRun'] + '&testRun=' + exParam['ndeTestRun'];
                }
                else {
                    url = 'testRun=' + exParam['ndeTestRun'];
                }
            }
            commonParam = "";
            let group = exParam['groupby'];
            if (group.indexOf("tier") != -1)
                commonParam = "&tierid=" + nodeData.Tierid + "&tierName=" + nodeData.tierName;
            else
                commonParam = "&tierid=" + exParam.tierid + "&tierName=" + exParam.tierName;
            if (group.indexOf("server") != -1)
                commonParam += "&serverid=" + nodeData.Serverid + "&serverName=" + nodeData.serverName;
            else if (exParam.ServerName)
                commonParam += "&serverid=" + exParam.serverid + "&serverName=" + exParam.ServerName;
            else
                commonParam += "&serverid=" + exParam.serverid + "&serverName=" + exParam.serverName;
            if (group.indexOf("app") != -1)
                commonParam += "&appid=" + nodeData.Appid + "&appName=" + nodeData.appName;
            else
                commonParam += "&appid=" + exParam.appid + "&appName=" + exParam.appName;
            if (group.indexOf("excclass") != -1)
                commonParam += "&exceptionClassId=" + nodeData.exceptionclassid;
            else
                commonParam += "&exceptionClassId=" + exParam.excClassId;
            if (group.indexOf("excthrowingclass") != -1)
                commonParam += "&throwingClassId=" + nodeData.throwingClassId;
            else
                commonParam += "&throwingClassId=" + exParam.excThrowingClassId;
            if (group.indexOf("excthrowingmethod") != -1)
                commonParam += "&throwingMethodId=" + nodeData.throwingMethodId;
            else
                commonParam += "&throwingMethodId=" + exParam.excThrowingMethodId;
            if (group.indexOf("excmessage") != -1)
                commonParam += "&excMsgId=" + nodeData.exceptionmessageid;
            else
                commonParam += "&excMsgId=" + exParam.excMsgId;
            if (group.indexOf("exccause") != -1)
                commonParam += "&excCauseId=" + nodeData.exceptioncauseid;
            else
                commonParam += "&excCauseId=" + exParam.excCauseId;
            if (group.indexOf("url") != -1)
                commonParam += "&urlIdx=" + nodeData.URLIndex;
            if (group.indexOf("page") != -1)
                commonParam += "&page=" + nodeData.pageName;
            else
                commonParam += "&page=" + exParam.page;
            if (group.indexOf("session") != -1)
                commonParam += "&session=" + nodeData.sessionName;
            else
                commonParam += "&session=" + exParam.session;
            if (group.indexOf("transaction") != -1)
                commonParam += "&transaction=" + nodeData.transactionName;
            else
                commonParam += "&transaction=" + exParam.transaction;
            commonParam += "&pagination= --limit " + this.limit + " --offset " + this.offset;
            ajaxParam = "&strStartTime=" + exParam['strStartTime'] + "&strEndTime=" + (Number(exParam['strEndTime']) + 1000);
        }
        else if (this.commonService.fromDBtoExpFlag == true) {
            ajaxParam = "&failedQuery=1" + "&backendid=" + this.id.backendid + "&backendName=" + this.id.backendNameQuery +
                "&backendSubType=" + this.commonService.fromDBtoExpData.sqlIndex + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime;
        }
        else if (this.commonService.fromhstoExpFlag == true) {
            ajaxParam += "&flowPathInstance=" + this.hstoexData.fpInst +
                "&backendid=" + this.hstoexData.backendId + "&seqno=" + this.hstoexData.seqno + "&calloutError=true" + "&strStartTime=" + this.id.startTime + "&strEndTime=" + (Number(this.id.endTime) + 1000);
        }
        else if (this.commonService.seqDiagToExceptionFlag == true) {
            ajaxParam += "&flowPathInstance=" + this.seqDiagToExpData.flowpathInstance + "&strStartTime=" + this.seqDiagToExpData.startTimeInMs +
                "&strEndTime=" + (Number(this.seqDiagToExpData.endTimeInMs) + 1000) + "&failedQuery=" + this.seqDiagToExpData.failedQuery + "&backendid=" + this.seqDiagToExpData.backendid +
                "&seqno=" + this.seqDiagToExpData.seqNo + "&backendSubType=" + this.seqDiagToExpData.backendSubType;
        }
        else {
            ajaxParam = "&flowPathInstance=" + this.id.flowPathInstance + "&failedQuery=" + this.id.failedQuery +
                "&backendid=" + this.id.backendid + "&backendName=" + this.id.backendNameQuery +
                "&backendSubType=" + this.id.backendSubType + "&strStartTime=" + this.id.startTime + "&strEndTime=" + (Number(this.id.endTime) + 1000);
        }
        this.finalUrlException = url + commonParam + ajaxParam + "&queryId=" + this.queryId2;
        url = this.finalUrlException + "&showCount=false";
        this.isCancelQuerydata = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        this.ndDdrHttpService.getExceptionReportData(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ExceptionReportLoadedState"]) {
                this.doAssignExceptionValue(state.data);
            }
        }, (error) => {
            this.loader = false;
            if (error.hasOwnProperty('message')) {
                this.messageService.showError(error);
            }
        });
    }
    getExceptionDataCount(nodeData) {
        let url = this.finalUrlException + "&showCount=true";
        this.ndDdrHttpService.getExceptionReportCount(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ExceptionCountLoadedState"]) {
                this.assignExceptionCountValue(state.data);
            }
        });
    }
    assignExceptionCountValue(res) {
        this.totalCount = res.totalCount;
        if (this.totalCount > 10)
            this.showPagination = true;
        else
            this.showPagination = false;
        this.paginatorArr = this.dynamicPaginator(res.totalCount);
        if (this.limit > this.totalCount)
            this.limit = Number(this.totalCount);
    }
    paginateAgg(event) {
        this.aggoffset = event.first;
        this.agglimit = event.rows;
        if (this.agglimit > this.totalCountEx)
            this.agglimit = Number(this.totalCountEx);
        if ((this.agglimit + this.aggoffset) > this.totalCountEx)
            this.agglimit = Number(this.totalCountEx) - Number(this.aggoffset);
        this.commonService.isFilterFromSideBar = true;
        this.getaggregatedData();
    }
    loadExceptionPagination(event) {
        this.offset = event.first;
        this.limit = event.rows;
        if (this.limit > this.totalCount)
            this.limit = Number(this.totalCount);
        if ((this.limit + this.offset) > this.totalCount)
            this.limit = Number(this.totalCount) - Number(this.offset);
        this.getExceptionData(this.nodeDataInfo);
    }
    dynamicPaginator(length) {
        let paginatorArr = [];
        if (length == 0)
            this.limit = 0;
        if (length >= 0 && length <= 100) {
            if (length <= 10) {
                paginatorArr = [10];
                this.rowValue = 10;
            }
            else if (length <= 20) {
                paginatorArr = [10, 20];
                this.rowValue = 20;
            }
            else if (length <= 30) {
                paginatorArr = [10, 20, 30];
                this.rowValue = 30;
            }
            else if (length <= 50) {
                paginatorArr = [10, 20, 30, 50];
                this.rowValue = 50;
            }
            else if (length <= 100) {
                paginatorArr = [10, 30, 50, 100];
                this.rowValue = 50;
            }
        }
        else if (length > 100 && length <= 400) {
            if (length <= 200) {
                paginatorArr = [10, 50, 100, 200];
                this.rowValue = 50;
            }
            else if (length <= 300) {
                paginatorArr = [10, 50, 100, 200, 300];
                this.rowValue = 50;
            }
            else if (length <= 400) {
                paginatorArr = [10, 50, 100, 200, 400];
                this.rowValue = 50;
            }
        }
        else if (length > 400) {
            paginatorArr = [10, 50, 100, 200, 400];
            this.rowValue = 50;
        }
        return paginatorArr;
    }
    getProgressBar() {
        this.progress = this._timerService.getTimerSubscription().subscribe(value => { this.calculateProgress(value); });
    }
    calculateProgress(tick) {
        if (this.value < 50) {
            this.value += 3;
        }
        else if (this.value < 70) {
            this.value += 2;
        }
        else if (this.value < 99) {
            this.value += 1;
        }
        if (this.loader == false) {
            this.progress.unsubscribe();
            this.value = 0;
        }
    }
    getAggData(data) {
        this.isCancelQuerydata = true;
        this.createDynamicColumns();
        this.commonService.isFilterFromSideBar = false;
        this.createPieChart(data);
        this.AggData = data.data;
        this.queryId1 = undefined;
        this.queryId2 = this.randomNumber();
        this.filteredAggregateExceptionInfo = this.getagginfo();
        this.aggregateExceptionInfo = this.filteredAggregateExceptionInfo;
        this.totalCountEx = data.totalCount;
        if (this.totalCountEx > 10)
            this.showPaginationEX = true;
        else
            this.showPaginationEX = false;
        if (this.agglimit > this.totalCountEx)
            this.agglimit = Number(this.totalCountEx);
        if (this.aggregateExceptionInfo.length > 0)
            this.showDownLoadReportIcon = true;
        if (this.aggregateExceptionInfo.length == 0) {
            this.loader = false;
        }
        this.paginatorArrEx = this.dynamicPaginatorEx(this.totalCountEx);
    }
    dynamicPaginatorEx(length) {
        let paginatorArrEx = [];
        if (length == 0)
            this.agglimit = 0;
        if (length >= 0 && length <= 100) {
            if (length <= 10) {
                paginatorArrEx = [10];
                this.rowValueEx = 10;
            }
            else if (length <= 20) {
                paginatorArrEx = [10, 20];
                this.rowValueEx = 20;
            }
            else if (length <= 30) {
                paginatorArrEx = [10, 20, 30];
                this.rowValueEx = 30;
            }
            else if (length <= 50) {
                paginatorArrEx = [10, 20, 30, 50];
                this.rowValueEx = 50;
            }
            else if (length <= 100) {
                paginatorArrEx = [10, 30, 50, 100];
                this.rowValueEx = 50;
            }
        }
        else if (length > 100 && length <= 400) {
            if (length <= 200) {
                paginatorArrEx = [10, 50, 100, 200];
                this.rowValueEx = 50;
            }
            else if (length <= 300) {
                paginatorArrEx = [10, 50, 100, 200, 300];
                this.rowValueEx = 50;
            }
            else if (length <= 400) {
                paginatorArrEx = [10, 50, 100, 200, 400];
                this.rowValueEx = 50;
            }
        }
        else if (length > 400) {
            paginatorArrEx = [10, 50, 100, 200, 400];
            this.rowValueEx = 50;
        }
        return paginatorArrEx;
    }
    clickHandler(event) {
        this.aggHeaderInfo = ": " + event.point.name;
        this.showAllOption = true;
        let filteredAggExArr = [];
        for (let k = 0; k < this.chartData.length; k++) {
            if (event.point.y == this.chartData[k]['ExceptionCount']) {
                filteredAggExArr.push({ exceptionClassName: this.chartData[k]["ExceptionClassName"], throwingClassName: this.chartData[k]["ThrowingClassName"], throwingMethodName: this.chartData[k]["ThrowingMethodName"], exceptionCount: this.chartData[k]["ExceptionCount"], throwingMethodId: this.chartData[k]["exceptionthrowingmethodid"], throwingClassId: this.chartData[k]["exceptionthrowingclassid"], exceptionclassid: this.chartData[k]["exceptionclassid"], tierName: this.chartData[k]["TierName"], serverName: this.chartData[k]["ServerName"], appName: this.chartData[k]["AppName"], URLName: this.chartData[k]["URLName"], pageName: this.chartData[k]["PageName"], sessionName: this.chartData[k]["SessionName"], transactionName: this.chartData[k]["TransactionName"], message: this.chartData[k]["Message"], cause: this.chartData[k]["Cause"], exceptionmessageid: this.chartData[k]["exceptionmessageid"], Tierid: this.chartData[k]["Tierid"], Serverid: this.chartData[k]["Serverid"], Appid: this.chartData[k]["Appid"] });
                break;
            }
        }
        if (filteredAggExArr.length == 0) {
            this.stackObj = [];
            this.filteredexceptionInfo = [];
        }
        if (filteredAggExArr.length > 0)
            this.showExceptions(filteredAggExArr[0]); // When click on a particular exp - that exception spline chart should be generate
        this.filteredAggregateExceptionInfo = filteredAggExArr;
    }
    doAssignExceptionValue(res) {
        this.isCancelQuerydata = true;
        this.backendObj = res.backendidandName;
        setTimeout(() => {
            this.loader = false;
        }, 500);
        this.showHeaderInfo();
        if (res.hasOwnProperty('Status')) {
            this.messageService.showError(res.Status);
        }
        this.exceptionDetail = res.data;
        if (this.exceptionDetail.length == 0) {
            this.showDownLoadReportIcon = false;
            this.stackObj = [];
        }
        this.exceptionInfo = this.getExceptionInfo();
        this.timeZoneOffset = res.timeZoneOffset;
        this.createSplineChart(this.exceptionInfo, 0);
        setTimeout(() => {
            this.firstException = { first: this.offset };
            this.rowsException = { rows: this.limit };
        }, 1000);
    }
    getagginfo() {
        var arrAggData = [];
        if (this.AggData.length == 0) {
            this.showHeaderInfo();
            this.exceptionInfo = [];
            this.stackObj = [];
            this.totalCount = 0;
            this.limit = 0;
        }
        for (var i = 0; i < this.AggData.length; i++) {
            arrAggData[i] = { exceptionClassName: this.AggData[i]["ExceptionClassName"], throwingClassName: this.AggData[i]["ThrowingClassName"], throwingMethodName: this.AggData[i]["ThrowingMethodName"], exceptionCount: this.AggData[i]["ExceptionCount"], throwingMethodId: this.AggData[i]["exceptionthrowingmethodid"], throwingClassId: this.AggData[i]["exceptionthrowingclassid"], exceptionclassid: this.AggData[i]["exceptionclassid"], tierName: this.AggData[i]["TierName"], serverName: this.AggData[i]["ServerName"], appName: this.AggData[i]["AppName"], URLName: this.AggData[i]["URLName"], URLIndex: this.AggData[i]["URLIndex"], pageName: this.AggData[i]["PageName"], sessionName: this.AggData[i]["SessionName"], transactionName: this.AggData[i]["TransactionName"], message: this.AggData[i]["Message"], cause: this.AggData[i]["Cause"], exceptioncauseid: this.AggData[i]["exceptioncauseid"], exceptionmessageid: this.AggData[i]["exceptionmessageid"], Tierid: this.AggData[i]["Tierid"], Serverid: this.AggData[i]["Serverid"], Appid: this.AggData[i]["Appid"] };
            if (i == 0) {
                this.showExceptions({ exceptionClassName: this.AggData[i]["ExceptionClassName"], throwingClassName: this.AggData[i]["ThrowingClassName"], throwingMethodName: this.AggData[i]["ThrowingMethodName"], exceptionCount: this.AggData[i]["ExceptionCount"], throwingMethodId: this.AggData[i]["exceptionthrowingmethodid"], throwingClassId: this.AggData[i]["exceptionthrowingclassid"], exceptionclassid: this.AggData[i]["exceptionclassid"], tierName: this.AggData[i]["TierName"], serverName: this.AggData[i]["ServerName"], appName: this.AggData[i]["AppName"], URLName: this.AggData[i]["URLName"], URLIndex: this.AggData[i]["URLIndex"], pageName: this.AggData[i]["PageName"], sessionName: this.AggData[i]["SessionName"], transactionName: this.AggData[i]["TransactionName"], message: this.AggData[i]["Message"], cause: this.AggData[i]["Cause"], exceptioncauseid: this.AggData[i]["exceptioncauseid"], exceptionmessageid: this.AggData[i]["exceptionmessageid"], Tierid: this.AggData[i]["Tierid"], Serverid: this.AggData[i]["Serverid"], Appid: this.AggData[i]["Appid"] });
            }
        }
        return arrAggData;
    }
    showHeaderInfo() {
        let excFilters = this.commonService.exceptionFilters;
        this.headerInfo = "";
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        this.completeGroupBy = '';
        this.filterGroupByStr = '';
        this.filterOrderByStr = '';
        this.completeOrderBy = '';
        if (this.commonService.isValidParamInObj(excFilters, "groupByFC")) {
            if (excFilters['groupByFC'].length > 32) {
                this.filterGroupByStr = ' GroupBy=' + excFilters['groupByFC'].substring(0, 32) + '..' + ' ,';
                this.completeGroupBy = excFilters['groupByFC'];
            }
            else
                this.filterGroupByStr = ' GroupBy=' + excFilters['groupByFC'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(excFilters, "orderByFC")) {
            let orderExc = excFilters['orderByFC'];
            if (orderExc.length > 40) {
                this.filterOrderByStr = ' OrderBy=' + orderExc.substring(0, 40) + ".." + ",";
                this.completeOrderBy = orderExc;
            }
            else {
                this.filterOrderByStr = ' OrderBy=' + orderExc + ",";
                this.completeOrderBy = orderExc;
            }
        }
        if (this.commonService.isValidParamInObj(excFilters, "tierName")) {
            if (excFilters['tierName'].length > 32) {
                this.filterTierName += 'Tier=' + excFilters['tierName'].substring(0, 32) + '...' + ",";
                this.completeTier = excFilters['tierName'];
            }
            else
                this.filterTierName += 'Tier=' + excFilters['tierName'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "serverName")) {
            if (excFilters['serverName'].length > 32) {
                this.filterServerName = ' Server=' + excFilters['serverName'].substring(0, 32) + '...' + ",";
                this.completeServer = excFilters['serverName'];
            }
            else
                this.filterServerName = ' Server=' + excFilters['serverName'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "appName")) {
            if (excFilters['appName'].length > 32) {
                this.filterInstanceName = ' Instance=' + excFilters['appName'].substring(0, 32) + '...' + ",";
                this.completeInstance = excFilters['appName'];
            }
            else
                this.filterInstanceName = ' Instance=' + excFilters['appName'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "startTimeInDateFormat")) {
            this.headerInfo += ' StartTime=' + excFilters['startTimeInDateFormat'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "endTimeInDateFormat") && this._ddrData.isFromAgg) {
            let endT = excFilters['endTimeInDateFormat'];
            endT = endT + 1000;
            this.headerInfo += ' EndTime=' + endT + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "endTimeInDateFormat")) {
            this.headerInfo += ' EndTime=' + excFilters['endTimeInDateFormat'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "statusCodeFC")) {
            this.headerInfo += ' Status =' + excFilters['statusCodeFC'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "url")) {
            let val = excFilters['url'];
            if (val.length > 40) {
                this.URLstr = ', URL=' + val.substring(0, 40) + ".." + ",";
                this.CompleteURL = val;
            }
            else {
                this.URLstr = ', URL=' + val + ",";
                this.CompleteURL = val;
            }
        }
        if (this.commonService.isValidParamInObj(excFilters, "excepClsName")) {
            this.headerInfo += ' Exception Class=' + excFilters['excepClsName'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "excClassIdFC")) {
            this.headerInfo += ' Exception Class=' + excFilters['excClassIdFC'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "excThrowingClassIdFC")) {
            this.headerInfo += ' Throwing Class=' + excFilters['excThrowingClassIdFC'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "excThrowingMethodIdFC")) {
            this.headerInfo += ' Throwing Method=' + excFilters['excThrowingMethodIdFC'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "excCauseIdFC")) {
            this.headerInfo += ' Cause=' + excFilters['excCauseIdFC'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "excMsgIdFC")) {
            this.headerInfo += ' Exception Message=' + excFilters['excMsgIdFC'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "excStackTraceName")) {
            this.headerInfo += ' Stack Trace=' + excFilters['excStackTraceName'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "page")) {
            this.headerInfo += ' Page=' + excFilters['page'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "script")) {
            this.headerInfo += ' Script=' + excFilters['script'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "transaction")) {
            this.headerInfo += ' Transaction=' + excFilters['transaction'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "browser")) {
            this.headerInfo += ' Browser=' + excFilters['browser'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "access")) {
            this.headerInfo += ' Access=' + excFilters['access'] + ",";
        }
        if (this.commonService.isValidParamInObj(excFilters, "location")) {
            this.headerInfo += ' Location=' + excFilters['location'];
        }
        if (this.headerInfo.endsWith(","))
            this.headerInfo = this.headerInfo.substring(0, this.headerInfo.length - 1);
    }
    setTestRunInHeader() {
        if (decodeURIComponent(this.id.ipWithProd).indexOf("netstorm") != -1)
            this.strTitle = "Netstorm - Exceptions - Test Run : " + this.id.testRun;
        else
            this.strTitle = "Netdiagnostics Enterprise - Exceptions - Session : " + this.id.testRun;
    }
    /**
     * This method is used to open Flowpath report from advance exception report
     * @param data
     */
    openFPReport(rowData) {
        this._ddrData.splitViewFlag == false;
        this.toggleWindow.emit(false);
        let reqData = {};
        if (rowData != undefined) {
            reqData["flowPathInstance"] = rowData.flowPathInstance;
            reqData["tierId"] = rowData.tierId;
            reqData["serverId"] = rowData.serverId;
            reqData["appId"] = rowData.appId;
            reqData["tierName"] = rowData.tierName;
            reqData["serverName"] = rowData.serverName;
            reqData["appName"] = rowData.appName;
            reqData["startTime"] = this.id.startTime;
            reqData["endTime"] = this.id.endTime;
        }
        this.commonService.openFlowpath = true;
        this.commonService.exptoFpData = reqData;
        this._ddrData.FromexpFlag = 'true';
        this._ddrData.IPByFPFlag = false;
        this.commonService.isFilterFromSideBar = false;
        if (this._router.url.indexOf('/home/ddrCopyLink') != -1) {
            this._router.navigate(['/home/ddrCopyLink/flowpath']);
        }
        else
            this._router.navigate(['/ddr/flowpath']);
    }
    openStackTrace(nodeData) {
        this.showCode = false;
        if (nodeData['timeStamp'] && nodeData['timeStamp'] != 'NA' && nodeData['timeStamp'] != "-") {
            if (this.stackTraceHeader && this.stackTraceHeader.includes(",Time =")) {
                this.stackTraceHeader = this.stackTraceHeader.substring(0, this.stackTraceHeader.indexOf(",Time ="));
            }
            this.stackTraceHeader += ",Time =" + this.sessionService.convertTimestampIntoFormattedString(this._ddrData.ConverIntoNumber(nodeData["timeStamp"]), "MM/DD/YYYY HH:mm:ss");
        }
        if (nodeData['message'] && nodeData['message'] != 'NA' && nodeData['message'] != "-") {
            if (nodeData['message'] && nodeData['message'] != 'NA' && nodeData['message'] != "-") {
                if (this.stackTraceHeader && this.stackTraceHeader.includes(", Message:")) {
                    this.stackTraceHeader = this.stackTraceHeader.substring(0, this.stackTraceHeader.indexOf(", Message:"));
                }
                this.stackTraceHeader += ", Message: " + nodeData['message'];
            }
        }
        this.expClassName = nodeData.exceptionClassName.toString();
        this.expMethodName = nodeData.throwingMethodName.toString();
        this.expLineNo = nodeData.lineNumber.toString();
        this.stackData = "Tier:" + nodeData.tierName + ",Server:" + nodeData.serverName + ",Instance:" + nodeData.appName + ",Exception Class:" + nodeData.exceptionClassName;
        if (nodeData.stackTrace.indexOf("%7C") != -1) {
            this.stackArr = nodeData.stackTrace.split("%7C");
        }
        else {
            this.stackArr = Array(nodeData.stackTrace);
        }
        this.cls = nodeData.exceptionClassName;
        this.exClassName = this.cls.substring(this.cls.lastIndexOf('.') + 1, this.cls.length);
        this.agent = nodeData['instanceType'].toLowerCase();
        this.createStackJson(this.stackArr, this.expClassName, this.expMethodName, this.expLineNo, this.agent);
    }
    getSourceCode(nodeInfo, type) {
        var fqm;
        if (type == '%40')
            fqm = nodeInfo.substring(nodeInfo.indexOf("%50") + 3, nodeInfo.indexOf("%40"));
        else
            fqm = nodeInfo.substring(0, nodeInfo.indexOf('%70')) + "." + nodeInfo.substring(nodeInfo.indexOf('%70') + 3, nodeInfo.length);
        var pcm = fqm.substring(0, fqm.indexOf("(")); //com.cavisson.nsecom.localVariablesServlet.methodWithLocalVarsUCE
        var pkgCls = pcm.substring(0, pcm.lastIndexOf(".")); //com.cavisson.nsecom.localVariablesServlet
        var method = pcm.substring(pcm.lastIndexOf(".") + 1, pcm.length); //Method
        var cls = pkgCls.substring(pkgCls.lastIndexOf(".") + 1, pkgCls.length); //Class
        var pac = pkgCls.substring(0, pkgCls.lastIndexOf("."));
        var fileName = fqm.substring(fqm.indexOf("(") + 1, fqm.indexOf(")"));
        this.classFileName = cls + ".rtf";
        this.classMethodFileName = cls + "_" + method + ".rtf";
        this.stackTraceHeaderInfo = " [" + cls + "." + method + "(" + fileName + ")" + "]";
        if (type == '%40') {
            var uidArr = nodeInfo.split("%4");
            var uid = uidArr[1].substring(1);
        }
        this.showCode = true;
        this.fullyQualifiedMethod = fqm;
        var secUrl = '';
        let tName = this.stackData.split(",")[0].split(":")[1];
        let sName = this.stackData.split(",")[1].split(":")[1];
        let aName = this.stackData.split(",")[2].split(":")[1];
        if (this.commonService.enableQueryCaching == 1) {
            secUrl += "cacheId=" + this.id.testRun + "&fqm=" + fqm + "&j_uid=" + uid + "&tierName=" + tName + "&serverName=" + sName + "&instanceName=" + aName + "&testRun=" + this.id.testRun;
        }
        else {
            secUrl += "fqm=" + fqm + "&j_uid=" + uid + "&tierName=" + tName + "&serverName=" + sName + "&instanceName=" + aName + "&testRun=" + this.id.testRun;
        }
        this.loader = true;
        this.getProgressBar();
        this.ndDdrHttpService.getreadMethodBody(secUrl).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ReadMethodBodyLoadedState"]) {
                this.assignValue(state.data, nodeInfo);
            }
        });
    }
    getMonacoLanguage(agent) {
        const languageMap = {
            'java': 'java',
            'dotnet': 'csharp',
            'nodejs': 'javascript',
            'python': 'python',
            'php': 'php'
        };
        return languageMap[agent === null || agent === void 0 ? void 0 : agent.toLowerCase()] || 'java';
    }
    //Ajax call for getting value and arguments of method stacktrace
    getVariableAndArguments(stackTraceRow) {
        const payload = {
            stackTrace: stackTraceRow,
            tierName: this.id.tierName
        };
        this.ndDdrHttpService.getVariableAndArguments(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["GetVariableArgumentsLoadedState"]) {
                this.assignValueForVariables(state.data);
            }
        });
    }
    //Assigning the values of varibales and arguments to the local field and update
    assignValueForVariables(data) {
        const me = this;
        me.classVarArgs = data.classVariables;
        me.classVarArgsSs = me.classVarArgs.substring(0, me.classVarArgs.length - 1);
        me.classVarArgsArr = me.classVarArgsSs.split(/\r?\n/);
        me.classVarArgsJson = me.classVarArgsArr.map(item => ({ classVar: item }));
        me.methodVarArgs = data.methodVariables;
        me.methodVarArgsSs = me.methodVarArgs.substring(0, me.methodVarArgs.length - 1);
        me.methodVarArgsArr = me.methodVarArgsSs.split(/\r?\n/);
        me.methodVarArgsJson = me.methodVarArgsArr.map(item => ({ methodArg: item }));
        me.localVarArgs = data.localVariables;
        me.localVarArgsSs = me.localVarArgs.substring(0, me.localVarArgs.length - 1);
        me.localVarArgsArr = me.localVarArgsSs.split(/\r?\n/);
        me.localVarArgsJson = me.localVarArgsArr.map(item => ({ localVar: item }));
        me.ThreadLocalVarArgs = data.threadLocalVariables;
        me.ThreadLocalVarArgsSs = me.ThreadLocalVarArgs.substring(0, me.ThreadLocalVarArgs.length - 1);
        me.ThreadLocalVarArgsArr = me.ThreadLocalVarArgsSs.split(/\r?\n/);
        me.ThreadLocalVarArgsJson = me.ThreadLocalVarArgsArr.map(item => ({ threadLocalVar: item }));
        if (data.logs) {
            me.lastNLogsStr = data.logs;
        }
        else {
            me.lastNLogsStr = "";
        }
        me.totalMethodVars = me.countArgs(me.methodVarArgs, '\n');
        me.toalClassVars = me.countArgs(me.classVarArgs, '\n');
        me.totalLocalVars = me.countArgs(me.localVarArgs, '\n');
        me.totalThreadVars = me.countArgs(me.ThreadLocalVarArgs, '\n');
        this.getLastNlogs(me.lastNLogsStr);
    }
    getLastNlogs(data) {
        const me = this;
        me.lastNLogs = [];
        if (data.lastIndexOf('\n') > 0) {
            me.lastNLogs = data.split('\n');
            if (me.lastNLogs[me.lastNLogs.length - 1] == '') {
                me.lastNLogs.splice(me.lastNLogs.length - 1, 1);
            }
            me.lastNLogJson = me.lastNLogs.map(item => ({ logs: item }));
            me.totalLogs = me.lastNLogs.length;
        }
        else {
            me.totalLogs = 0;
            me.lastNLogs.push("No Logs Found");
        }
    }
    copySourceCode(data) {
        const selBox = document.createElement('textarea');
        selBox.style.position = 'fixed';
        selBox.style.left = '0';
        selBox.style.top = '0';
        selBox.style.opacity = '0';
        selBox.value = data;
        document.body.appendChild(selBox);
        selBox.focus();
        selBox.select();
        document.execCommand('copy');
        document.body.removeChild(selBox);
        this.messageService.showSuccess("Copy source code successfully");
    }
    countArgs(data, word) {
        return data.split(word).length - 1;
    }
    assignValue(dataVal, nodeInfo) {
        setTimeout(() => {
            this.loader = false;
        }, 500);
        if (dataVal.methodBody.startsWith("Unable") || dataVal.methodBody.startsWith("Something") || dataVal.methodBody.startsWith("Error"))
            this.showDownloadSourceCodeIcon = false;
        else
            this.showDownloadSourceCodeIcon = true;
        let preStart = '<pre class="prettyprint lang-java">';
        let preEnd = '</pre>';
        this.methodBody = preStart + dataVal.methodBody + preEnd;
        this.highlightedLine = this.findHighlightedLine(dataVal.methodBody);
        this.newMethodBody = this.replaceAll(dataVal.methodBody, "<mark>", "");
        this.newMethodBody = this.replaceAll(this.newMethodBody, "</mark>", "");
        this.newMethodBody = this.replaceAll(this.newMethodBody, "&lt;", "<");
        this.newMethodBody = this.replaceAll(this.newMethodBody, "&gt;", ">");
        this.monacoEditorContent = this.newMethodBody;
        // Apply highlight after content is set
        this.loadEditorLineHighlight();
        this.getVariableAndArguments(nodeInfo); //fetching varibales and arguments for that stacktrace
    }
    findHighlightedLine(rawBody) {
        const lines = rawBody.split('\n');
        for (let i = 0; i < lines.length; i++) {
            if (lines[i].includes('<mark>')) {
                return i + 1;
            }
        }
        return -1;
    }
    onMonacoEditorInit(editor) {
        this.monacoEditor = editor; // store editor instance
        // Handles FIRST TIME case
        this.loadEditorLineHighlight();
    }
    loadEditorLineHighlight(delay = 200) {
        if (this.highlightedLine <= 0 || !this.monacoEditor) {
            return;
        }
        setTimeout(() => this.applyMonacoLineHighlight(), delay);
    }
    applyMonacoLineHighlight() {
        const monaco = window.monaco;
        if (!monaco || this.highlightedLine <= 0 || !this.monacoEditor) {
            return;
        }
        this.monacoHighlightDecorationIds = this.monacoEditor.deltaDecorations(this.monacoHighlightDecorationIds, [{
                range: new monaco.Range(this.highlightedLine, 1, this.highlightedLine, 1),
                options: {
                    isWholeLine: true,
                    className: 'monaco-highlighted-line'
                }
            }]);
        this.monacoEditor.revealLineInCenter(this.highlightedLine);
    }
    replaceAll(str, find, replace) {
        return str.replace(new RegExp(find.replace(/[-\/\\^$*+?.()|[\]{}]/g, '\\$&'), 'g'), replace);
    }
    downLoadSourceCode(type) {
        let codeDownloadURL;
        if (type == 1) // For Method Body
         {
            codeDownloadURL = "/common/" + this.classMethodFileName;
            const param = {
                downloadFileName: this.classMethodFileName,
                downloadType: type,
                tierName: this.id.tierName
            };
            this.ndDdrHttpService.getExcepctionDownloadSoucecode(param).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["DownloadSourceLoadedState"]) {
                    this.downloadFromBackend(codeDownloadURL);
                }
            }, (error) => {
                console.error('Error loading: ', error);
            });
        }
        else // For whole class file
         {
            codeDownloadURL = "/common/" + this.classFileName;
            const param = {
                downloadFileName: this.classFileName,
                downloadType: type,
                tierName: this.id.tierName
            };
            this.ndDdrHttpService.getExcepctionDownloadSoucecode(param).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["DownloadSourceLoadedState"]) {
                    this.downloadFromBackend(codeDownloadURL);
                }
            }, (error) => {
                console.error('Error loading: ', error);
            });
        }
    }
    downloadFromBackend(codeDownloadURL) {
        window.open(codeDownloadURL);
    }
    getExceptionInfo() {
        var arrException = [];
        for (var i = 0; i < this.exceptionDetail.length; i++) {
            if (i == 0) {
                this.stackTraceHeaderTooltip = `Exception Class: ${this.exceptionDetail[i]['exceptionClassName']} \nThrowing Class: ${this.exceptionDetail[i]['throwingClassName']} \nThrowing Method: ${this.exceptionDetail[i]['throwingMethodName']} \n Message: ${this.exceptionDetail[i]["message"]}`;
                this.stackData = "Tier:" + this.exceptionDetail[i]["tierName"] + ",Server:" + this.exceptionDetail[i]["serverName"] + ",Instance:" + this.exceptionDetail[i]["appName"] + ",Exception Class:" + this.exceptionDetail[i]["exceptionClassName"];
                if (this.stackTraceHeader && this.stackTraceHeader.includes(",Time =")) {
                    this.stackTraceHeader = this.stackTraceHeader.substring(0, this.stackTraceHeader.indexOf(",Time ="));
                }
                this.stackTraceHeader += ",Time =" + this.sessionService.convertTimestampIntoFormattedString(this._ddrData.ConverIntoNumber(this.exceptionDetail[i]["timeStamp"]), "MM/DD/YYYY HH:mm:ss");
                if (this.exceptionDetail[i]["stackTrace"].indexOf("%7C") != -1)
                    this.stackArr = this.exceptionDetail[i]["stackTrace"].split("%7C");
                else
                    this.stackArr = Array(this.exceptionDetail[i]["stackTrace"]);
                this.cls = this.exceptionDetail[i]["exceptionClassName"];
                this.exClassName = this.cls.substring(this.cls.lastIndexOf('.') + 1, this.cls.length);
                if (this.exceptionDetail[i]['message'] && this.exceptionDetail[i]['message'] != 'NA' && this.exceptionDetail[i]['message'] != "-") {
                    if (this.stackTraceHeader && this.stackTraceHeader.includes(", Message:")) {
                        this.stackTraceHeader = this.stackTraceHeader.substring(0, this.stackTraceHeader.indexOf(", Message:"));
                    }
                    this.stackTraceHeader += ", Message: " + this.exceptionDetail[i]['message'];
                }
                this.agent = this.exceptionDetail[i]["instanceType"].toLowerCase();
                this.createStackJson(this.stackArr, this.exceptionDetail[i]["exceptionClassName"], this.exceptionDetail[i]["throwingMethodName"], this.exceptionDetail[i]["lineNumber"], this.agent);
            }
            if (this.exceptionDetail[i]["backendId"] != "-" && this.backendObj != null && this.backendObj != undefined) {
                this.exceptionDetail[i]["backendId"] = this.backendObj[this.exceptionDetail[i]["backendId"]];
            }
            arrException[i] = { timeStamp: this.exceptionDetail[i]["timeStamp"], exceptionClassName: this.exceptionDetail[i]["exceptionClassName"], message: this.exceptionDetail[i]["message"], throwingClassName: this.exceptionDetail[i]["throwingClassName"], throwingMethodName: this.exceptionDetail[i]["throwingMethodName"], lineNumber: this.exceptionDetail[i]["lineNumber"], stackTrace: this.exceptionDetail[i]["stackTrace"], flowPathInstance: this.exceptionDetail[i]["flowPathInstance"], stackTraceID: this.exceptionDetail[i]["stackTraceID"], exceptionClassId: this.exceptionDetail[i]["exceptionClassId"], messageId: this.exceptionDetail[i]["messageId"], tierName: this.exceptionDetail[i]["tierName"], serverName: this.exceptionDetail[i]["serverName"], appName: this.exceptionDetail[i]["appName"], tierId: this.exceptionDetail[i]["tierId"], serverId: this.exceptionDetail[i]["serverId"], appId: this.exceptionDetail[i]["appId"], cause: this.exceptionDetail[i]["cause"], causeId: this.exceptionDetail[i]["causeId"], backendId: this.exceptionDetail[i]["backendId"], startTime: this.exceptionDetail[i]["startTime"], throwingClassId: this.exceptionDetail[i]["throwingClassId"], throwingMethodId: this.exceptionDetail[i]["throwingMethodId"], startTimeInMS: this.exceptionDetail[i]["startTimeInMS"] };
        }
        return arrException;
    }
    createStackJson(res, expClassName, expMethodName, expLineNo, agent) {
        var arr = [];
        var clsWithMethod = "-";
        var method;
        var cls;
        var fileName = "";
        if (agent.toLowerCase() === "java") {
            for (var m = 0; m < res.length; m++) {
                if (res[m] == "-") {
                    arr.push({ "stack": "%70No Stack Trace Found" });
                }
                else {
                    if (res[m].indexOf("(") != -1) {
                        var lastBracket = res[m].substring(0, res[m].indexOf("("));
                        fileName = res[m].substring(res[m].indexOf("("), res[m].indexOf(")") + 1);
                        method = lastBracket.substring(lastBracket.lastIndexOf(".") + 1, lastBracket.length) + fileName;
                        var pc = lastBracket.substring(0, lastBracket.lastIndexOf("."));
                        var packg = pc.substring(0, pc.lastIndexOf("."));
                        cls = pc.substring(pc.lastIndexOf(".") + 1, pc.length);
                    }
                    if (res[m].indexOf('%40') == -1) {
                        if (cls != undefined && method != undefined)
                            clsWithMethod = packg + "%70" + cls + "." + method;
                    }
                    else {
                        clsWithMethod = cls + "." + method + "%50" + res[m];
                    }
                    arr.push({ "stack": clsWithMethod });
                }
            }
        }
        else {
            for (var m = 0; m < res.length; m++) {
                let stackLine = decodeURIComponent(res[m]);
                if (stackLine == "-") {
                    arr.push({ "stack": "No Stack Trace Found", "tooltip": "No Stack Trace Found" });
                }
                else {
                    arr.push({ "stack": stackLine.replace(/\s/g, '&nbsp;'), "tooltip": stackLine });
                }
            }
        }
        this.stackObj = arr;
        this.totalCountST = this.stackObj.length;
        this.paginatorArrST = this.dynamicPaginatorST(this.totalCountST);
        this.createStackTraceJSONForDownload(res, agent);
        //Making dynamic popup header
        this.dialogHeaderName = "Exception:  " + expClassName + " , Method:  " + expMethodName;
    }
    dynamicPaginatorST(length) {
        let paginatorArrST = [];
        if (length == 0)
            this.limit = 0;
        if (length >= 0 && length <= 100) {
            if (length <= 10) {
                paginatorArrST = [10];
                this.rowValueST = 10;
            }
            else if (length <= 20) {
                paginatorArrST = [10, 20];
                this.rowValueST = 20;
            }
            else if (length <= 30) {
                paginatorArrST = [10, 20, 30];
                this.rowValueST = 30;
            }
            else if (length <= 50) {
                paginatorArrST = [10, 20, 30, 50];
                this.rowValueST = 50;
            }
            else if (length <= 100) {
                paginatorArrST = [10, 30, 50, 100];
                this.rowValueST = 100;
            }
        }
        else if (length > 100 && length <= 400) {
            if (length <= 200) {
                paginatorArrST = [10, 50, 100, 200];
                this.rowValueST = 200;
            }
            else if (length <= 300) {
                paginatorArrST = [10, 50, 100, 200, 300];
                this.rowValueST = 300;
            }
            else if (length <= 400) {
                paginatorArrST = [10, 50, 100, 200, 400];
                this.rowValueST = 400;
            }
        }
        else if (length > 400) {
            paginatorArrST = [10, 50, 100, 200, 400];
            this.rowValueST = 400;
        }
        return paginatorArrST;
    }
    createStackTraceJSONForDownload(res, agent) {
        this.stackTraceJson = "[";
        try {
            if (agent.toLowerCase() == "java") {
                for (var m = 0; m < res.length; m++) {
                    if (res[m] != "-") {
                        if (res[m].indexOf("%40") != -1)
                            res[m] = res[m].substring(0, res[m].indexOf("%40"));
                        this.stackTraceJson += '{"stackTrace":"' + res[m] + '"}';
                        if (m < res.length - 1)
                            this.stackTraceJson += ',';
                    }
                    else
                        this.stackTraceJson += '{"stackTrace":"No Stack Trace Found"}';
                }
            }
            else {
                for (var m = 0; m < res.length; m++) {
                    let stackLine = decodeURIComponent(res[m]);
                    if (stackLine != "-") {
                        this.stackTraceJson += '{"stackTrace":"' + stackLine + '"}';
                        if (m < res.length - 1)
                            this.stackTraceJson += ',';
                    }
                    else
                        this.stackTraceJson += '{"stackTrace":"No Stack Trace Found"}';
                }
            }
            this.stackTraceJson += ']';
        }
        catch (e) {
            console.log("Exception in createStackTraceJSONForDownload ", e);
        }
    }
    showToolTipForValueLength(type, valLength) {
        var title;
        if (valLength == undefined || type == "Integer" || type == "Boolean" || type == "Byte" || type == "Short" || type == "Long" || type == "Double") {
            title = "";
        }
        else {
            title = "Total Length: " + valLength;
        }
        return title;
    }
    ngOnDestroy() {
        this.breadcrumb['items'].pop();
        if (this.sideBarException) {
            this.sideBarException.unsubscribe();
        }
        this._ddrData.isFromTrxnFlowmap = false;
    }
    randomNumber() {
        var queryId = (Math.random() * 1000000).toFixed(0);
        return queryId;
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        let queryId = "";
        if (this.queryId1) {
            queryId = this.queryId1;
        }
        else {
            queryId = this.queryId2;
        }
        url = "testRun=" + this.id.testRun + "&queryId=" + queryId + "&tierName=" + this.id.tierName;
        this.isCancelQuery = false;
        this.ndDdrHttpService.getCancelQueryResult(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["CancelQueryLoadedState"]) {
                return state.data;
            }
        });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    clickButtonEventStackTrace(event) {
        var _a, _b;
        const me = this;
        const row = event.cavEventExt.row['stack'];
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "onRowSelect") {
            if (me.agent == 'java') {
                if (row.indexOf('%40') != -1) {
                    me.getSourceCode(row, '%40');
                }
                else {
                    me.getSourceCode(row, '%70');
                }
            }
        }
    }
    clickButtonEventExcepction(event) {
        var _a, _b, _c, _d, _e, _f;
        console.log(event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.openFPReport(event.cavEventExt.row);
        }
        if (((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.action) === "onRowSelect") {
            me.openStackTrace(event.cavEventExt.row);
        }
        if (((_f = (_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.actionConfig) === null || _f === void 0 ? void 0 : _f.action) === "openLogs") {
            me.openLogs(event.cavEventExt.row);
        }
    }
    clickButtonEventAggExcepction(event) {
        var _a, _b, _c, _d;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "onRowSelect") {
            me.showExceptions(event.cavEventExt.row);
        }
        if (((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.action) === "showalldata") {
            me.showAllAggData();
        }
    }
    timeVarianceInMs(time) {
        var timeVarianceInMs = time;
        var timeVarNum = "";
        if (/^[0-9]*h$/.test(time)) //If time is in hour formate- xh eg:2h means 2 hour variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 60 * 60 * 1000;
        }
        else if (/^[0-9]*m$/.test(time)) //If time is in minute formate- xm eg:20m means 20 minute variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 60 * 1000;
        }
        else if (/^[0-9]*s$/.test(time)) //If time is in second formate- xs eg:200s means 200 second variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 1000;
        }
        else if (/^[0-9]*ms$/.test(time)) //If time is in millisecond formate- xs eg:200ms means 200 millisecond variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 2);
            timeVarianceInMs = Number(timeVarNum);
        }
        else if (/^[0-9]*$/.test(time)) // if there is only number, it is considered as seconds 
         {
            timeVarianceInMs = Number(time) * 1000;
        }
        else {
            alert("Please provide value of 'NetDiagnosticsQueryTimeVariance' in proper format in config.ini i.e.- Nh or Nm or Ns or Nms or N where N is a integer ");
            return Number(900000); //if value of ndQueryTimeVariance is not in desired format then NF report will open with default variance time that is 15 minutes(900000ms).
        }
        return Number(timeVarianceInMs);
    }
    openLogs(rowData) {
        let flowpathInstance;
        let startTimeInMS;
        let startTimeISO;
        let endTimeISO;
        let query;
        this._ddrData.isFromFlowpath = true;
        if (rowData.length == 0) {
            alert("No Record Selected");
            return;
        }
        query = "";
        flowpathInstance = rowData["flowPathInstance"];
        startTimeInMS = rowData["startTimeInMS"];
        query = "fpi:" + flowpathInstance;
        let d1 = Number(startTimeInMS) - Number(this.timeVarianceInMs(this.timeVarienceForNF));
        let d2;
        d2 = Number(startTimeInMS) + Number(this.timeVarianceInMs(this.timeVarienceForNF));
        startTimeISO = d1;
        endTimeISO = d2;
        query = "( " + query + " )";
        console.log("query>>>>>>>>>>", query);
        query = query.replaceAll("%20", " ");
        this._router.navigate(["/home/logs"], { queryParams: { queryStr: query, startTime: startTimeISO, endTime: endTimeISO } });
    }
};
ExceptionReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_6__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_1__["DdrDataModelService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_14__["CavMessageService"] },
    { type: _tools_configuration_nd_config_services_timer_service__WEBPACK_IMPORTED_MODULE_7__["TimerService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__["SessionService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_12__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], ExceptionReportComponent.prototype, "columnData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Output"])()
], ExceptionReportComponent.prototype, "toggleWindow", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])('value')
], ExceptionReportComponent.prototype, "compareFPInfo", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], ExceptionReportComponent.prototype, "showLink", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["ViewChild"])('dt1')
], ExceptionReportComponent.prototype, "dt1", void 0);
ExceptionReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Component"])({
        selector: 'exception-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./exception-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/exception-report/exception-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_2__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./exception-report.component.scss */ "./src/app/pages/ddr/components/exception-report/exception-report.component.scss")).default]
    })
], ExceptionReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.css":
/*!****************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.css ***!
  \****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.ts":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.ts ***!
  \***************************************************************************************/
/*! exports provided: FlowpathAnalyzerComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FlowpathAnalyzerComponent", function() { return FlowpathAnalyzerComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");












let FlowpathAnalyzerComponent = class FlowpathAnalyzerComponent {
    constructor(commonService, _router, _ddrData, breadcrumbService, sessionService, ddrHttpService, breadcrumb) {
        this.commonService = commonService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.sessionService = sessionService;
        this.ddrHttpService = ddrHttpService;
        this.breadcrumb = breadcrumb;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_7__; // Initialize Highcharts for component use
        this.topMethodData = []; // Top N Method Table Data
        this.colsForTopMethods = []; // Columns for Top N Method Table
        this.noOfpattern = 5; // Number of pattern to be displayed
        this.signatureData = []; // Signature Table Data
        this.timeData = '';
        this.ajaxUrl = ''; // url for ajax call
        this.showWarning = false; // Flag to show warning message
        this.patternHeader = ""; // accordion header for pattern
        this.signatureHeaderRelativePath = ""; // Relative path of signature header
        this.patternHeaderRelativePath = ""; // Relative path of pattern header
        this.topNMethodHeaderRelativePath = ""; // Relative path of top N method header
        let tableConfigForTopMethods = {
            config: {
                globalFilter: true,
                hideColumnOptions: true
            }
        };
        this.tableConfigForTopMethods = tableConfigForTopMethods;
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false; // setting isToLoadSideBar to false in order to hide side bar(CQM)
        this.breadcrumb.add({ label: 'Flowpaths Analyzer', routerLink: '/ddr/flowpathAnalyzer' });
        this.urlParam = this.commonService.getData(); // getting selected filter object from service
        this.commonService.removeFromStorage(); // removing old filters from sessionStorage
        this.commonService.setInStorage = this.urlParam; // setting new filters in sessionStorage
        if (this.commonService.fpAnalyzeData) {
            sessionStorage.removeItem("fpAnalyzeData");
            sessionStorage.setItem("fpAnalyzeData", JSON.stringify(this.commonService.fpAnalyzeData));
        }
        else {
            this.commonService.fpAnalyzeData = JSON.parse(sessionStorage.getItem("fpAnalyzeData"));
        }
        if (this._router.url.indexOf('?') !== -1 && (this._router.url.indexOf('/home/ddrCopyLink/flowpath') !== -1
            || this._router.url.indexOf('/home/ED-ddr/flowpath') !== -1)) {
            let queryParams1 = location.href.substring(location.href.indexOf('?') + 1, location.href.length);
            this.urlParam = JSON.parse('{"' + decodeURI(queryParams1).replace(/"/g, '\\"').replace(/&/g, '","').replace(/=/g, '":"') + '"}');
            this.commonService.removeFromStorage();
            this.commonService.setInStorage = this.urlParam;
        }
        this.createColumns();
        this.getJsonData();
        this.createFilterCriteria(this.timeData);
    }
    clickEventOnSignatureTable(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.openFPReport(event.cavEventExt.row, 'Signature');
        }
    }
    clickEventOnPatternTable(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.openFPReport(event.cavEventExt.row, 'pattern');
        }
    }
    /**
     * Filter Criteria
     */
    createFilterCriteria(timePeriod) {
        this.filterCriteria = "";
        let fpAHeader = this.urlParam;
        if (this.commonService.isValidParamInObj(fpAHeader, 'tierName')) {
            if (fpAHeader['tierName'].length > 32) {
                this.filterCriteria += 'Tier=' + fpAHeader['tierName'].substring(0, 32) + '...';
            }
            else
                this.filterCriteria += 'Tier=' + fpAHeader['tierName'];
        }
        if (this.commonService.isValidParamInObj(fpAHeader, 'serverName')) {
            this.filterCriteria += ', Server=' + fpAHeader['serverName'];
        }
        if (this.commonService.isValidParamInObj(fpAHeader, 'appName')) {
            this.filterCriteria += ', Instance=' + fpAHeader['appName'];
        }
        if (this.commonService.isValidParamInObj(fpAHeader, 'urlName')) {
            this.filterCriteria += ', BT=' + fpAHeader['urlName'];
        }
        if (timePeriod.length !== 0 && timePeriod.length > 1) {
            this.filterCriteria += ', StartTime=' + this.sessionService.convertTimestampIntoFormattedString(Number(timePeriod[0]), "MM/DD/YYYY HH:mm:ss") + ', EndTime =' + this.sessionService.convertTimestampIntoFormattedString(Number(timePeriod[1]), "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
        }
        else {
            if (this.urlParam.strGraphKey !== 'WholeScenario') {
                if (this.commonService.isValidParamInObj(fpAHeader, 'startTime')) {
                    if (fpAHeader['startTime']) {
                        var strTime = Number(fpAHeader['startTime']);
                        var StrTimeDateFrmt = this.sessionService.convertTimestampIntoFormattedString(strTime, "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
                        this.filterCriteria += ', StartTime=' + StrTimeDateFrmt;
                    }
                }
                if (this.commonService.isValidParamInObj(fpAHeader, 'endTime')) {
                    if (fpAHeader['endTime']) {
                        var edTime = Number(fpAHeader['endTime']);
                        var EndTimeDateFrmt = this.sessionService.convertTimestampIntoFormattedString(edTime, "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9.... 
                        this.filterCriteria += ', EndTime=' + EndTimeDateFrmt;
                    }
                }
            }
        }
        if (this.commonService.isValidParamInObj(fpAHeader, 'btCategory')) {
            if (this.commonService.fpAnalyzeData.btCatagory === 'extbt') {
                this.filterCriteria += ', BT Type= All';
            }
            else {
                this.filterCriteria += ', BT Type=' + this.getBTCategory(fpAHeader['btCategory']);
            }
        }
    }
    /**
    * Function to allow only numeric key inputs.
    * @param {Event} event - The event object representing the key press.
    * @returns {boolean|null} - Returns true if the key press is a number key (0-9), false if not, and null if the key is backspace or non-printable.
    */
    onlyNumberKey(event) {
        return (event.charCode === 8 || event.charCode === 0) ? null : event.charCode >= 48 && event.charCode <= 57;
    }
    /**
    * Function to apply custom number of pattern.
    * Checks if the number of patterns is greater than or equal to 11.
    * If true, displays a popup with an information message.
    * If false, creates columns and fetches JSON data.
    */
    applyPattern() {
        if (this.noOfpattern >= 11) {
            this.displayPopUp = true;
            this.infoHeader = 'Number of Pattern';
            this.strInfoMessage = 'Number of Pattern should not be greater than 10';
        }
        else {
            this.createColumns();
            this.getJsonData();
        }
    }
    createColumns() {
        this.signatureHeaderRelativePath = "ddr/flowpath-analyzer/signature-table.json";
        this.patternHeaderRelativePath = "ddr/flowpath-analyzer/pattern-table.json";
        this.colsForTopMethods = [
            {
                "cols": [
                    { "label": "Package", "key": "package", "width": "180px", "type": 0 },
                    { "label": "Method Name", "key": "classWithMethod", "width": "180px", "type": 0 },
                    { "label": "OverAll", "child": [
                            { "label": "Time (ms)", "key": "overallCummST", "type": 3 },
                            { "label": "Count", "key": "overallCount", "type": 3 }
                        ], "width": "180px"
                    }
                ]
            }
        ];
        let obj = {};
        for (let i = 0; i < this.noOfpattern; i++) {
            obj[i] = { "label": 'Pattern' + (i + 1), "key": 'pattern' + i, "width": "200px" };
            obj[i]['child'] = [];
            obj[i]['child'].push({ "label": "Time (ms)", "key": 'C' + i + '_cummST', "width": "180px", "type": 3 }, { "label": "Count", "key": 'C' + i + '_methodCount', "width": "180px", "type": 3 });
        }
        // Merge obj into columnForTopMethods
        for (let i = 0; i < this.noOfpattern; i++) {
            this.colsForTopMethods[0].cols.push(obj[i]);
        }
    }
    converToJSON(data) {
        let arr = [];
        let count = 0;
        Object.keys(data).forEach(function eachKey(key) {
            let obj = {};
            count += 1;
            obj['signature'] = 'Signature' + count;
            obj['fpIds'] = data[key]['fpinstances'];
            obj['fpCount'] = data[key]['count'];
            obj['min'] = (data[key]['min']);
            obj['max'] = (data[key]['max']);
            obj['avg'] = (data[key]['avg']);
            arr.push(obj);
        });
        this.signatureData = arr;
    }
    //Pattern Table Data 
    getJsonData() {
        this.queryParams = `testRun=${this.urlParam.testRun}${this.commonService.enableQueryCaching === 1 ? `&cacheId=${this.urlParam.testRun}` : ''}&tierId=${this.commonService.fpAnalyzeData.tierId}&serverId=${this.commonService.fpAnalyzeData.serverId}&appId=${this.commonService.fpAnalyzeData.appId}&urlIndex=${this.urlParam.urlIndex}&strStartTime=${this.urlParam.startTime}&strEndTime=${this.urlParam.endTime}&numOfPatterns=${this.noOfpattern}&tierName=${this._ddrData.tierName}&serverName=${this._ddrData.serverName}&appName=${this._ddrData.appName}&urlName=${this._ddrData.urlName}`;
        if (this.commonService.fpAnalyzeData.btCatagory !== 'extbt') {
            this.queryParams += `&btcategoryId=${this.urlParam.btCategory}`;
        }
        this.ddrHttpService.getFlowpathAnalyzerData(this.queryParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["FlowpathAnalyzerLoadedState"]) {
                this.assignFlowpathAnalyzerJsonData(state.data);
                this.converToJSON(state.data.signature);
            }
        }, (error) => {
            console.error('Error in getting FlowpathAnalyzer Data ~ ', error);
        });
    }
    getBTCategory(categoryId) {
        const categories = {
            '10': 'Normal',
            '11': 'Slow',
            '12': 'Very Slow',
            '13': 'Error',
        };
        return categories[categoryId] || 'Unknown';
    }
    /**
     * assigning the server data to the variables
     */
    assignFlowpathAnalyzerJsonData(resData) {
        try {
            if (resData.clusterInfo.length === 0) {
                return;
            }
            let patternAnalyzeData = []; // Array to store pattern analyze data
            const clusterLen = resData.clusterInfo.length;
            const overallFpCount = resData.clusterInfo[clusterLen - 1]['fpCountOverall'];
            this.showWarning = overallFpCount >= 10000;
            const totalavg = resData.clusterInfo[clusterLen - 1]['AverageFPTimeOverall'];
            const totalfp = overallFpCount;
            if (totalavg && totalfp) {
                this.patternHeader = "(Flowpath Avg Time=" + this.avgFormatter(totalavg) + "ms" + ", Flowpath Count=" + totalfp + ")";
            }
            // Process data for each pattern
            for (let i = 0; i < clusterLen - 1; i++) {
                let obj = {};
                const fpCount = resData.clusterInfo[i]['fpCountC' + i];
                let fqm = resData.clusterInfo[i]['topContributorC' + i];
                if (fqm && fqm.indexOf('_') != -1) { //condition for Integrations Point appear in topContributors
                    obj['topContributor'] = decodeURIComponent((fqm + '()').replace(/&#46;/g, "."));
                }
                else {
                    const m = fqm.substring(fqm.lastIndexOf('.') + 1, fqm.length);
                    const tmp = m.split('(');
                    const pc = fqm.substring(0, fqm.lastIndexOf('.'));
                    const cls = pc.substring(pc.lastIndexOf('.') + 1, pc.length);
                    if (cls !== '') {
                        obj['topContributor'] = decodeURIComponent((cls + '.' + tmp[0] + '()').replace(/&#46;/g, "."));
                    }
                    else {
                        obj['topContributor'] = decodeURIComponent((tmp[0] + '()').replace(/&#46;/g, "."));
                    }
                }
                obj['pattern'] = 'Pattern' + (i + 1);
                obj['avgTime'] = resData.clusterInfo[i]['AverageFPTimeC' + i];
                obj['fpCount'] = fpCount;
                obj['percentageFp'] = (parseFloat(fpCount) / parseFloat(overallFpCount) * 100).toFixed(2);
                obj['fpIds'] = resData.clusterInfo[i]['fpIdsC' + i];
                patternAnalyzeData.push(obj);
            }
            this.patternData = patternAnalyzeData;
            this.topMethodData = this.topMethodsData(resData);
            this.dbCallout = this.topMethodData.filter(r => r['methodName'].indexOf('DB Callouts') != -1);
            this.numberMethods = this.topMethodData.filter(r => r['methodName'].indexOf('Number of Methods') != -1);
            this.topMethodData = this.topMethodData.filter(r => r['methodName'].indexOf('DB Callouts') == -1 && r['methodName'].indexOf('Number of Methods') == -1);
            for (const obj of this.topMethodData) {
                // Loop through keys in the object
                for (const key in obj) {
                    if (obj[key] === 'NaN') {
                        obj[key] = '0'; // Replace 'NaN' with '0'
                    }
                }
            }
            for (var i = 0; i < this.patternData.length; i++) {
                if (this.dbCallout) {
                    this.patternData[i]['dbCallout'] = (this.dbCallout[0]['C' + i + '_cummST']);
                    if (i == 0) {
                        this.patternHeaderRelativePath = "ddr/flowpath-analyzer/pattern-table-db-method.json";
                    }
                }
                if (this.numberMethods) {
                    this.patternData[i]['numberMethods'] = (this.numberMethods[0]['C' + i + '_cummST']);
                    if (i == 0) {
                        this.patternHeaderRelativePath = "ddr/flowpath-analyzer/pattern-table-db-method.json";
                    }
                }
                if (this.patternData[i]['pattern'] === 'Overall') {
                    this.patternData[i]['time'] = '-';
                    this.patternData[i]['count'] = '-';
                }
                const topC = this.patternData[i].topContributor;
                for (var j = 0; j < this.topMethodData.length; j++) {
                    if (topC.indexOf("DB Callouts") != -1) {
                        this.patternData[i]['time'] = this.dbCallout[0]['C' + (i) + '_cummST'];
                        this.patternData[i]['count'] = this.dbCallout[0]['C' + (i) + '_methodCount'];
                    }
                    else if (topC === this.topMethodData[j]['classWithMethod']) {
                        this.patternData[i]['time'] = this.topMethodData[j]['C' + (i) + '_cummST'];
                        this.patternData[i]['count'] = this.topMethodData[j]['C' + (i) + '_methodCount'];
                    }
                }
            }
            this.timeData = resData.timePeriod;
            this.createChart(this.patternData);
        }
        catch (error) {
            console.error('Error ~ assignFlowpathAnalyzerJsonData() ~ ', error);
        }
    }
    /**
     * modifying the second table data from server data
     */
    topMethodsData(data) {
        const jsonData = data.data;
        let tmpData = [...jsonData];
        tmpData = tmpData.filter(r => r['methodName'] !== '_cavissionMetric_Status');
        tmpData.forEach((value, index) => {
            if (value.methodName) {
                const fqm = value.methodName;
                if (fqm && fqm.indexOf('_') != -1) { //condition for decoding Integration Point methodName in TopMethodData
                    value['classWithMethod'] = decodeURIComponent((fqm + '()').replace(/&#46;/g, "."));
                    value['package'] = '';
                    if (!value['package'] || value['package'].trim() === '') {
                        value['package'] = '-';
                    }
                }
                else {
                    const m = fqm.substring(fqm.lastIndexOf('.') + 1, fqm.length);
                    const tmp = m.split('(');
                    const pc = fqm.substring(0, fqm.lastIndexOf('.'));
                    const cls = pc.substring(pc.lastIndexOf('.') + 1, pc.length);
                    value['package'] = pc.substring(0, pc.lastIndexOf('.'));
                    if (cls !== '') {
                        value['classWithMethod'] = cls + '.' + tmp[0] + '()';
                    }
                    else {
                        value['classWithMethod'] = tmp[0] + '()';
                    }
                    if (!value['package'] || value['package'].trim() === '') {
                        value['package'] = '-';
                    }
                }
            }
        });
        return tmpData;
    }
    avgFormatter(value) {
        let numStr = parseFloat(parseFloat(value).toFixed()).toLocaleString('en-IN');
        return numStr;
    }
    /**
     * creating Pie-Cahrt and Bar-Chart
     */
    createChart(piData) {
        let pieArr = [];
        let barArr = [];
        if (piData.length !== 0) {
            for (let i = 0; i < piData.length; i++) {
                if (piData[i].topContributor !== '-') {
                    pieArr.push({
                        'name': piData[i].topContributor, 'y': Number(piData[i].percentageFp), 'z': piData[i].pattern,
                        'time': piData[i].time, 'count': piData[i].count
                    });
                }
            }
        }
        if (piData.length !== 0) {
            for (let i = 0; i < piData.length; i++) {
                if (piData[i].topContributor !== '-') {
                    barArr.push({ 'name': piData[i].pattern, 'y': Number(piData[i].fpCount) });
                }
            }
        }
        this.options = {
            chart: {
                type: 'pie',
            },
            credits: {
                enabled: false
            }, exporting: {
                enabled: false
            },
            title: { text: 'Top Contributors', style: { 'fontSize': '13px' } },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>, <br/> Pattern: <b>{point.z}<\b>,<br/>Time: <b>{point.time}</b>,<br/>Count: <b>{point.count}</b>'
            },
            plotOptions: {
                pie: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    dataLabels: {
                        enabled: false,
                        format: '<b> {point.name} </b>: {point.percentage:.2f} %',
                    },
                    showInLegend: true,
                    borderWidth: 0
                }
            },
            legend: {
                enabled: true,
                layout: 'horizental',
                align: 'right',
                width: 400,
                verticalAlign: 'middle',
                labelFormat: '{name} {y}%',
            },
            series: [
                {
                    name: 'Percentage',
                    data: pieArr,
                    enableMouseTracking: true
                }
            ]
        };
        this.options1 = {
            chart: {
                type: 'column'
            },
            title: { text: 'Pattern Flowpath Count', style: { 'fontSize': '13px' } },
            credits: {
                enabled: false
            },
            exporting: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                labels: {
                    enabled: false
                },
                title: {
                    text: ' '
                }
            },
            yAxis: {
                min: 0,
                allowDecimals: false,
                title: {
                    text: 'Flowpath Count'
                }
            },
            tooltip: {
                headerFormat: '<table><tr><td style="padding:0">Pattern:</td>' +
                    '<td style="padding:0"><b>{point.key}</b></td></tr>',
                pointFormat: '<tr><td style="padding:0">Flowpaths: </td>' +
                    '<td style="padding:0"><b>{point.y}</b></td></tr>',
                footerFormat: '</table>',
                shared: true,
                useHTML: true
            },
            plotOptions1: {
                column: {
                    pointPadding: 0.2,
                    borderWidth: 0
                }
            },
            series: [
                {
                    name: 'Pattern',
                    enableMouseTracking: true,
                    data: barArr,
                    colorByPoint: true,
                    pointWidth: 25
                }
            ],
        };
    }
    /**
     * Method to open Flowpath report for Signature and Pattern table...
     * @param rowData
     * @param report pattern or Signature
     */
    openFPReport(rowData, report) {
        try {
            let obj = {};
            if (report === 'pattern')
                obj = rowData;
            obj['tierName'] = this.urlParam.tierName;
            obj['tierId'] = this.urlParam.tierId;
            obj['serverName'] = this.urlParam.serverName;
            obj['serverId'] = this.urlParam.serverId;
            obj['appName'] = this.urlParam.appName;
            obj['appId'] = this.urlParam.appId;
            obj['btName'] = this.urlParam.btName;
            obj['urlIndex'] = this.urlParam.urlIndex;
            obj['fpIds'] = rowData.fpIds;
            if (report === 'Signature')
                obj['fpCount'] = rowData.fpCount;
            let cmdArgs1 = ' --testrun ' + this.urlParam.testRun;
            if (this.urlParam.tierId !== '' && this.urlParam.tierId !== 'NA' && this.urlParam.tierId !== 'undefined'
                && this.urlParam.tierId !== undefined) {
                cmdArgs1 += ' --tierid ' + +this.urlParam.tierId;
            }
            if (this.urlParam.serverId !== '' && this.urlParam.serverId !== 'NA' && this.urlParam.serverId !== 'undefined'
                && this.urlParam.serverId !== undefined) {
                cmdArgs1 += ' --serverid ' + this.urlParam.serverId;
            }
            if (this.urlParam.appId !== '' && this.urlParam.appId !== 'NA' && this.urlParam.appId !== 'undefined'
                && this.urlParam.appId !== undefined) {
                cmdArgs1 += ' --appid ' + this.urlParam.appId;
            }
            if (rowData.fpIds !== '' && rowData.fpIds !== 'NA' && rowData.fpIds !== 'undefined' && rowData.fpIds !== undefined) {
                cmdArgs1 += ' --fpinstance ' + rowData.fpIds;
            }
            if (this.urlParam.startTime !== '' && this.urlParam.startTime !== 'NA' && this.urlParam.startTime !== 'undefined'
                && this.urlParam.startTime !== undefined) {
                cmdArgs1 += ' --abs_starttime ' + this.urlParam.startTime;
            }
            if (this.urlParam.endTime !== '' && this.urlParam.endTime !== 'NA' && this.urlParam.endTime !== 'undefined'
                && this.urlParam.endTime !== undefined) {
                cmdArgs1 += ' --abs_endtime ' + this.urlParam.endTime;
            }
            cmdArgs1 += ' --status -2';
            obj['cmdArgs'] = cmdArgs1;
            obj['btName'] = this.urlParam.urlName;
            obj['testRun'] = this.urlParam.testRun;
            obj['btCatagory'] = this.commonService.fpAnalyzeData.btCatagory;
            obj['startTime'] = this.urlParam.startTime;
            obj['endTime'] = this.urlParam.endTime;
            this._ddrData.cmdArgsFlag = true;
            this.commonService.fpAnalyzeData = obj;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].FPANALYZER;
            if (this._router.url.indexOf('/home/ddrCopyLink/') !== -1) {
                this._router.navigate(['/home/ddrCopyLink/flowpath']);
            }
            else {
                this._router.navigate(['/ddr/flowpath']);
            }
        }
        catch (error) {
            console.error('Error while opening Flowpath report:- ', error);
        }
    }
    encodeHTMLStr(str) {
        let returnString = '';
        if (str !== null && str !== '') {
            returnString = str.toString().replaceAll('&#044;', ',').replaceAll("&#58;", ":").replaceAll("&#46;", ".").replaceAll("&#010", "\n").replaceAll("&#039;", "\'").replaceAll("&#034;", "\"").replaceAll("&#092;", "\\").replaceAll("&#124;", "|").replaceAll("&#123;", "{").replaceAll("&#125;", "}").replaceAll("&#126;", "~").replaceAll("&#11", "").replaceAll("&#12", "");
        }
        return returnString;
    }
};
FlowpathAnalyzerComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__["NdDdrHttpService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__["BreadcrumbService"] }
];
FlowpathAnalyzerComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-flowpath-analyzer',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./flowpath-analyzer.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./flowpath-analyzer.component.css */ "./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.css")).default]
    })
], FlowpathAnalyzerComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.css":
/*!****************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.css ***!
  \****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".ddr-box {\r\n    margin: 10px 8px;\r\n    min-height: 82vh;\r\n    padding: 2px 4px;\r\n    border-radius: 4px;\r\n}\r\n.my-graph{\r\n    overflow: hidden;\r\n    width: 100%;\r\n    height: 350px;\r\n    display: flex;\r\n    transform: scale(1.08);\r\n    justify-content: center;\r\n    padding: 10px 0px;\r\n}\r\n@media screen and (max-width: 1366px){\r\n    .my-graph{\r\n        transform: scale(1);\r\n\r\n    }\r\n}\r\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.ts":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.ts ***!
  \***************************************************************************************/
/*! exports provided: FlowpathGroupByComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FlowpathGroupByComponent", function() { return FlowpathGroupByComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ddr-message.service */ "./src/app/pages/ddr/services/ddr-message.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_9__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");














let FlowpathGroupByComponent = class FlowpathGroupByComponent {
    constructor(commonService, _router, _ddrData, breadcrumbService, messageService, sessionService, ddrRequest, breadcrumb, ddrHttpService) {
        this.commonService = commonService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.messageService = messageService;
        this.sessionService = sessionService;
        this.ddrRequest = ddrRequest;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_9__;
        this.loading = false; // ajax-loader
        this.headerInfo = ''; // filter-criteria
        this.showDownLoadReportIcon = true; // variable to show download report icon
        this.fpLimit = 50; // specifies the maximum number of records to be retrieved from the server
        this.fpOffset = 0; // represents the offset value used in pagination for fetching Flowpath data.
        this.showAllOption = false; // variable to show all option button
        this.showBarChart = false; // variable to show bar chart
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.filterGroupByStr = '';
        this.filterOrderByStr = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        this.completeGroupBy = '';
        this.completeOrderBy = '';
        this.downloadHeaderInfo = ''; // filter-criteria for download report
        this.isEnabledColumnFilter = false; // variable to enable/disable column filter
        this.toggleFilterTitle = 'Show Column Filters'; // tooltip title for column filter
        this.ajaxUrlParams = ''; // contains ajax url params
        this.showPagination = false; // variable to show/hide pagination
        this.isCancelQuery = false; // variable to toggle cancel query dialog
        this.isCancelQuerydata = false; // variable to disable cancel query button or not
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.breadcrumb = breadcrumb;
    }
    ngOnInit() {
        this.loading = true;
        this.first.first = 0;
        this.rows.rows = 50;
        this.commonService.isToLoadSideBar = true;
        this.commonService.currentReport = "FlowpathGroupBy";
        this.breadcrumb.add({ label: 'Flowpaths Group By BT', routerLink: '/ddr/Flowpathgroupby' });
        if (this._ddrData.tagData) {
            this.tagInfo = this._ddrData.createGtagsIntoStr(this._ddrData.tagData);
        }
        this.commonService.enableQueryCaching = this._ddrData.enableQueryCaching;
        this.urlParam = this.commonService.getData();
        this.trStartTime = this.urlParam.startTime;
        this.trEndTime = this.urlParam.endTime;
        this.sideBarFlowpathGroupBy = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "FlowpathGroupBy") {
                this.commonService.isFilterFromSideBar = true;
                this.fpLimit = 50;
                this.loading = true;
                this.fillData();
            }
        });
        this.fillData();
    }
    fillData() {
        try {
            this.randomNumber();
            // getting table data from server
            this.getFlowpathData();
            this.getFlowpathDataCount();
            this.createDynamicColumn();
        }
        catch (error) {
            console.log('error in intialization compaonent --> ', error);
        }
    }
    createDynamicColumn() {
        this.colsForFpGroupByBT = [];
        this.colsForFpGroupByBT[0] = {
            cols: []
        };
        let fpParam = this.commonService.fpGroupByFilters;
        const columnMapping = {
            'url': { label: 'Business Transaction', key: 'urlName' },
            'tier': { label: 'Tier', key: 'tierName' },
            'server': { label: 'Server', key: 'serverName' },
            'app': { label: 'Instance', key: 'appName' },
            'btcategory': { label: 'BT Category', key: 'btCatagory' },
            'page': { label: 'Page', key: 'page' },
            'session': { label: 'Session', key: 'session' },
            'transaction': { label: 'Transaction', key: 'transaction' }
        };
        // Create a new array to store the columns that should be kept
        let newColumns = [];
        // Add columns based on strGroup
        for (let groupKey in columnMapping) {
            if (fpParam['strGroup'].indexOf(groupKey) !== -1) {
                newColumns.push({
                    label: columnMapping[groupKey].label,
                    selected: true,
                    key: columnMapping[groupKey].key,
                    width: '80px',
                    type: 0
                });
            }
        }
        // Always include Flowpath Count column
        newColumns.push({
            label: 'Flowpath Count',
            selected: true,
            key: 'fpCount',
            width: '80px',
            click: true,
            type: 1
        });
        // Update the columns array
        this.colsForFpGroupByBT[0].cols = newColumns;
        let tableConfig = {
            config: {
                globalFilter: true,
                toggleFilter: true
            },
            tableAction: []
        };
        this.tableConfig = tableConfig;
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d;
        const me = this;
        console.log('Event: ', event);
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.openFlowPathCount(event.cavEventExt.row);
        }
        else if (((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.action) === "showalldata") {
            me.showAllData();
        }
    }
    getFlowpathData() {
        let queryParams = '';
        let finalQueryParams = '';
        this.ajaxUrlParams = '';
        const cacheParam = this.commonService.enableQueryCaching === 1 ? `cacheId=${this.urlParam.testRun}&` : '';
        queryParams += `${cacheParam}testRun=${this.urlParam.testRun}`;
        if (this.commonService.isFilterFromSideBar && Object.keys(this.commonService.fpGroupByFilters).length != 0) { // sidebar filters to flowpath  groupby
            let fpParam = this.commonService.fpGroupByFilters;
            if (this.commonService.isValidParamInObj(fpParam, 'ndeProtocol') && this.commonService.isValidParamInObj(fpParam, 'pubicIP') && this.commonService.isValidParamInObj(fpParam, 'publicPort') && this.commonService.isValidParamInObj(fpParam, 'ndeTestRun')) {
                const cacheParam = this.commonService.enableQueryCaching === 1 ? `cacheId=${fpParam['ndeTestRun']}&` : '';
                queryParams += `${cacheParam}testRun=${fpParam['ndeTestRun']}`;
            }
            this.urlAjaxParam = this.commonService.makeParamStringFromObj(fpParam);
            console.log(" COMPONENT - Flowpath group by, METHOD -  getFlowpathData, After making queryParams from fpGroupByFilters= " + this.urlAjaxParam);
        }
        else {
            this.urlAjaxParam = `&flowPathInstance=${this.urlParam.flowPathInstance}&tierName=${this.urlParam.tierName}&serverName=${this.urlParam.serverName}&appName=${this.urlParam.appName}&tierId=${this.urlParam.tierid}&serverId=${this.urlParam.serverid}&appId=${this.urlParam.appid}&urlName=${this.urlParam.urlName}&strStartTime=${this.trStartTime}&strEndTime=${this.trEndTime}&statusCode=-2&btCategory=All&strGroup=url&groupByFC=BT`;
            if (this.tagInfo && this.tagInfo.length != 0) {
                this.urlAjaxParam += "&tags=" + this.tagInfo;
            }
            this.urlAjaxParamObject = this.commonService.makeObjectFromUrlParam(this.urlAjaxParam);
            this.commonService.fpGroupByFilters = this.urlAjaxParamObject;
            setTimeout(() => {
                this.messageService.sendMessage(this.commonService.fpGroupByFilters);
            }, 2000);
        }
        finalQueryParams += `${queryParams}${this.urlAjaxParam}&limit=${this.fpLimit}&offset=${this.fpOffset}&showCount=false&shellForNDFilters=1&queryId=${this.queryId}`;
        this._ddrData.urlFlag = false;
        this.ajaxUrlParams = queryParams + this.urlAjaxParam;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        // making POST request to get data
        this.ddrHttpService.getFlowpathReportData(finalQueryParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["FlowpathReportLoadedState"]) {
                this.assignFlowpathData(state.data);
                this.loading = false;
            }
        }, (error) => {
            console.error('Error in fetching data ~ ', error);
            this.commonService.showError(error);
            this.loading = false;
        });
    }
    catch(error) {
        console.log('error in getting data from rest call', error);
    }
    assignFlowpathData(res) {
        this.commonService.isFilterFromSideBar = false;
        this.loading = false;
        this.isCancelQuerydata = true;
        try {
            if (res === null || res === undefined) {
                return;
            }
            this.commonService.fpGroupByFilters['startTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.strStartTime), "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
            this.commonService.fpGroupByFilters['endTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.strEndTime), "MM/DD/YYYY HH:mm:ss"); // Converting timeStap to format, due to changing Time Zone from UI in LRM-A9....
            this.showHeaderInfo();
            // updating data in component variable
            this.flowpathData = res.data;
            this.flowpathData.forEach((val, index) => {
                val.btCatagory = this.commonService.getBTCategoryName(val.btCatagory);
            });
            this.fpDataBackup = this.flowpathData;
            this.showDownLoadReportIcon = this.flowpathData.length === 0 ? false : true;
            this.createChart(this.flowpathData);
            setTimeout(() => {
                this.first = { first: this.fpOffset };
                this.rows = { rows: this.fpLimit };
            }, 1000);
        }
        catch (error) {
            console.log(error);
        }
    }
    getFlowpathDataCount() {
        try {
            const queryParamStr = this.ajaxUrlParams + '&limit=' + this.fpLimit + '&offset=' + this.fpOffset + '&showCount=true&shellForNDFilters=1';
            this.ddrHttpService.getFlowpathCountData(queryParamStr).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["FlowpathCountLoadedState"]) {
                    this.assignFlowpathDataCount(state.data);
                }
            }, (error) => {
                console.error('Error return from getFlowpathCountData ~ ', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    assignFlowpathDataCount(res) {
        this.fpTotalCount = res.totalCount;
        this.showPagination = this.fpTotalCount > 50 ? true : false;
        if (this.fpLimit > this.fpTotalCount)
            this.fpLimit = Number(this.fpTotalCount);
    }
    /**used to open Flowpath Report from Flowpath by BT report */
    openFlowPathCount(rowData) {
        this._ddrData.fpByBTFlag = true;
        this._ddrData.dbTofpflag = false;
        this.commonService.fpByBTData = rowData;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].FLOWPATHGROUPBY;
        if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
            this._router.navigate(['/home/ddrCopyLink/flowpath']);
        else
            this._router.navigate(['/ddr/flowpath']);
    }
    getHostUrl(isDownloadCase) {
        var hostDcName = (this.sessionService.preSession.multiDc === true) ? this._ddrData.getHostUrlMultiDC(isDownloadCase) : this._ddrData.getHostUrl(isDownloadCase);
        if (hostDcName.lastIndexOf('ALL/') !== -1)
            hostDcName = hostDcName.substring(0, hostDcName.lastIndexOf('/'));
        return hostDcName;
    }
    paginate(event) {
        this.fpOffset = parseInt(event.first);
        this.fpLimit = parseInt(event.rows);
        if (this.fpLimit > this.fpTotalCount) {
            this.fpLimit = Number(this.fpTotalCount);
        }
        if ((this.fpLimit + this.fpOffset) > this.fpTotalCount) {
            this.fpLimit = Number(this.fpTotalCount) - Number(this.fpOffset);
        }
        this.commonService.isFilterFromSideBar = true;
        this.loading = true;
        this.commonService.isFilterFromSideBar = true;
        this.getFlowpathData();
    }
    createChart(res) {
        let fpParam = this.commonService.fpGroupByFilters;
        let dataFP = [];
        let dataCategories = [];
        this.showBarChart = res.length == 0 ? false : true;
        this.barData = res;
        for (let i = 0; i < this.barData.length; i++) {
            let groupChart = '';
            const groupKeys = {
                'url': 'urlName',
                'tier': 'tierName',
                'server': 'serverName',
                'app': 'appName',
                'btcategory': 'btCatagory',
                'page': 'page',
                'session': 'session',
                'transaction': 'transaction'
            };
            let groupChartArr = [];
            for (let key in groupKeys) {
                if (fpParam['strGroup'].includes(key)) {
                    groupChartArr.push(this.barData[i][groupKeys[key]]);
                }
            }
            groupChart = groupChartArr.join(',');
            let count = res[i]["fpCount"].replace(/\,/g, '');
            dataCategories.push(groupChart);
            dataFP.push({ "name": groupChart, "y": Number(count) });
        }
        this.chartOptions = {
            chart: {
                type: 'column',
                width: 1350
            },
            title: {
                text: 'Grouped Flowpath Counts'
            },
            exporting: {
                enabled: false
            },
            xAxis: {
                categories: dataCategories
            },
            yAxis: {
                min: 0,
                title: {
                    text: ""
                }
            },
            legend: {
                title: {
                    style: {
                        fontStyle: 'italic'
                    }
                }
            },
            tooltip: {
                headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
                pointFormat: '<tr><td style="color:{series.color};padding:0"></td></tr> ' +
                    '<tr><td style="padding:0">{series.nae}:<b>{point.y} </b></td></tr>',
            },
            credits: {
                enabled: false
            },
            plotOptions: {
                column: {
                    pointPadding: 0.2,
                    borderWidth: 0
                },
                events: {
                    click: function (event) {
                        this.clickHandler(event);
                    }.bind(this)
                },
                series: {
                    borderWidth: 0,
                    dataLabels: {
                        enabled: true
                    }
                }
            },
            series: [
                {
                    name: " Count",
                    data: dataFP,
                    enableMouseTracking: true,
                    colorByPoint: true,
                }
            ]
        };
    }
    clickHandler(event) {
        console.log("event --", event);
        this.showAllOption = true;
        let tableConfig = {
            config: {
                globalFilter: true,
                toggleFilter: true
            },
            tableAction: [
                {
                    "iconType": "icon",
                    "iconClass": "las-undo-alt-solid",
                    "toolTip": "Show All data",
                    "action": "showalldata",
                }
            ]
        };
        this.tableConfig = tableConfig;
        let filteredData = [];
        for (let k = 0; k < this.barData.length; k++) {
            let count = this.barData[k]['fpCount'].toString();
            count = count.replace(/\,/g, '');
            if (event.point.y == count) {
                filteredData.push(this.barData[k]);
                break;
            }
        }
        this.flowpathData = filteredData;
        // Traverse filteredData and replace ',' in fpCount
        this.flowpathData.forEach(item => {
            item.fpCount = item.fpCount.replace(/,/g, '');
        });
    }
    showAllData() {
        this.showAllOption = false;
        let tableConfig = {
            config: {
                globalFilter: true,
                toggleFilter: true
            },
            tableAction: []
        };
        this.tableConfig = tableConfig;
        this.flowpathData = this.fpDataBackup;
    }
    showHeaderInfo() {
        let fpGroupByFilters = this.commonService.fpGroupByFilters;
        this.headerInfo = "";
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.filterGroupByStr = '';
        this.filterOrderByStr = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        this.completeGroupBy = '';
        this.completeOrderBy = '';
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "tierName")) {
            if (fpGroupByFilters['tierName'].length > 32) {
                this.filterTierName += 'Tier=' + fpGroupByFilters['tierName'].substring(0, 32) + '..' + ' ,';
                this.completeTier = fpGroupByFilters['tierName'];
            }
            else
                this.filterTierName += 'Tier=' + fpGroupByFilters['tierName'] + ' ,';
            this.downloadHeaderInfo += 'Tier=' + fpGroupByFilters['tierName'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "serverName")) {
            if (fpGroupByFilters['serverName'].length > 32) {
                this.filterServerName = 'Server=' + fpGroupByFilters['serverName'].substring(0, 32) + '..' + ' ,';
                this.completeServer = fpGroupByFilters['serverName'];
            }
            else
                this.filterServerName = 'Server=' + fpGroupByFilters['serverName'] + ' ,';
            this.downloadHeaderInfo += 'Server=' + fpGroupByFilters['serverName'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "appName")) {
            if (fpGroupByFilters['appName'].length > 32) {
                this.filterInstanceName = ', Instance=' + fpGroupByFilters['appName'].substring(0, 32) + '..' + ' ,';
                this.completeInstance = fpGroupByFilters['appName'];
            }
            else
                this.filterInstanceName = 'Instance=' + fpGroupByFilters['appName'] + ' ,';
            this.downloadHeaderInfo += 'Instance=' + fpGroupByFilters['appName'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "groupByFC")) {
            if (fpGroupByFilters['groupByFC'].length > 32) {
                this.filterGroupByStr = 'Group By=' + fpGroupByFilters['groupByFC'].substring(0, 32) + '..' + ' ,';
                this.completeGroupBy = fpGroupByFilters['groupByFC'];
            }
            else
                this.filterGroupByStr = 'Group By=' + fpGroupByFilters['groupByFC'] + ' ,';
            this.downloadHeaderInfo += 'Group By=' + fpGroupByFilters['groupByFC'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "orderByFC")) {
            if (fpGroupByFilters['orderByFC'].length > 32) {
                this.filterOrderByStr = 'Order By=' + fpGroupByFilters['orderByFC'].substring(0, 32) + '..' + ' ,';
                this.completeOrderBy = fpGroupByFilters['orderByFC'];
            }
            else
                this.filterOrderByStr = 'Order By=' + fpGroupByFilters['orderByFC'] + ' ,';
            this.downloadHeaderInfo += 'Order By=' + fpGroupByFilters['orderByFC'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "startTimeInDateFormat") && !(fpGroupByFilters['startTimeInDateFormat'] == 'Invalid date')) {
            this.headerInfo += 'StartTime=' + fpGroupByFilters['startTimeInDateFormat'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "endTimeInDateFormat") && !(fpGroupByFilters['endTimeInDateFormat'] == 'Invalid date')) {
            this.headerInfo += 'EndTime=' + fpGroupByFilters['endTimeInDateFormat'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "btCategory"))
            this.headerInfo += 'BT Type=' + this.commonService.getBTCategoryName(fpGroupByFilters['btCategory']) + ' ,';
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "urlName")) {
            this.headerInfo += 'BT=' + decodeURIComponent((fpGroupByFilters['urlName']).toString()) + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "url")) {
            let val = fpGroupByFilters['url'];
            if (val.length > 40) {
                this.URLstr = 'URL=' + val.substring(0, 40) + ".." + ' ,';
                this.CompleteURL = val;
            }
            else {
                this.URLstr = 'URL=' + val + ' ,';
                this.CompleteURL = val;
            }
            this.downloadHeaderInfo += 'URL=' + fpGroupByFilters['url'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "statusCodeFC")) {
            this.headerInfo += 'Status =' + fpGroupByFilters['statusCodeFC'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "page")) {
            this.headerInfo += 'Page=' + fpGroupByFilters['page'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "script")) {
            this.headerInfo += 'Script=' + fpGroupByFilters['script'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "transaction")) {
            this.headerInfo += 'Transaction=' + fpGroupByFilters['transaction'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "browser")) {
            this.headerInfo += 'Browser=' + fpGroupByFilters['browser'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "access")) {
            this.headerInfo += 'Access=' + fpGroupByFilters['access'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "location")) {
            this.headerInfo += 'Location=' + fpGroupByFilters['location'] + ' ,';
        }
        if (this.commonService.isValidParamInObj(fpGroupByFilters, "tags")) {
            this.headerInfo += 'Tag:' + fpGroupByFilters['tags'];
            this.headerInfo = this.headerInfo.replace(/["']/g, "");
        }
        if (this.headerInfo.startsWith(',')) {
            this.headerInfo = this.headerInfo.substring(1);
        }
        if (this.headerInfo.endsWith(',')) {
            this.headerInfo = this.headerInfo.substring(0, this.headerInfo.length - 1);
        }
    }
    ngOnDestroy() { this.sideBarFlowpathGroupBy.unsubscribe(); }
    randomNumber() { this.queryId = (Math.random() * 1000000).toFixed(0); }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = "testRun=" + this.urlParam.testRun + "&queryId=" + this.queryId + "&tierName=" + this.urlParam.tierName;
        this.isCancelQuery = false;
        this.ddrHttpService.getCancelQueryResult(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["CancelQueryLoadedState"]) {
                return (state.data.status);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
FlowpathGroupByComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_7__["MessageService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__["SessionService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["NdDdrHttpService"] }
];
FlowpathGroupByComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-flowpath-group-by',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./flowpath-group-by.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./flowpath-group-by.component.css */ "./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.css")).default]
    })
], FlowpathGroupByComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/flowpath/flowpath.component.css":
/*!**********************************************************************!*\
  !*** ./src/app/pages/ddr/components/flowpath/flowpath.component.css ***!
  \**********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".ddr-paginator{position: fixed;\r\n  width: 100%;\r\n  right: 0px;\r\n  padding: 4px;}    ");

/***/ }),

/***/ "./src/app/pages/ddr/components/flowpath/flowpath.component.ts":
/*!*********************************************************************!*\
  !*** ./src/app/pages/ddr/components/flowpath/flowpath.component.ts ***!
  \*********************************************************************/
/*! exports provided: FlowpathComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FlowpathComponent", function() { return FlowpathComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! rxjs/operators */ "./node_modules/rxjs/_esm2015/operators/index.js");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_dashboard_service_req_transaction_flowmap_service_trx_flowmap_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/pages/dashboard-service-req/transaction-flowmap/service/trx-flowmap.service */ "./src/app/pages/dashboard-service-req/transaction-flowmap/service/trx-flowmap.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./../../services/ddr-txn-flowmap-data.service */ "./src/app/pages/ddr/services/ddr-txn-flowmap-data.service.ts");
















let FlowpathComponent = class FlowpathComponent {
    constructor(commonService, _router, flowmapDataService, _ddrData, messageService, nonExpandFlag, ddrHttpService, elasticSearchService, sessionService, breadcrumb) {
        this.commonService = commonService;
        this._router = _router;
        this.flowmapDataService = flowmapDataService;
        this._ddrData = _ddrData;
        this.messageService = messageService;
        this.nonExpandFlag = nonExpandFlag;
        this.ddrHttpService = ddrHttpService;
        this.elasticSearchService = elasticSearchService;
        this.sessionService = sessionService;
        //List of reports for the Delete Cache dialog
        this.reportList = [{ label: 'Flowpath', value: '2' }, { label: 'DB Report', value: '6' }, { label: 'Exception', value: '7,71' }, { label: 'Method Timing', value: '9' }, { label: 'Service Method Timing', value: '91' }, { label: 'Hotspot', value: '8,81,82' }, { label: 'IP Summary', value: '11' }, { label: 'Http Report', value: '10' }, { label: 'Method Details', value: '3' }, { label: 'Sequence Diagram', value: '5' }, { label: 'Transaction Flowmap', value: '4' }];
        this.deleteCachedFlag = false; //Used toggle delete cache dialog
        this.selectedReport = ""; //Used to store report-ID's to delete cached reports from server
        this.columnName = ''; //contains columnName of clicked cell of table for Split-view
        this.index = ''; //contains index of clicked cell of table for Split-view
        this.order = ''; //split-view variable
        this.flowBack = false;
        this.flowpathData = []; //flowpath table data
        this.loading = false; //control cavTable loading
        this.fpLimit = 50; //specifies the maximum number of records to be retrieved from the server
        this.fpOffset = 0; // represents the offset value used in pagination for fetching Flowpath data.
        this.tableOptions = true;
        this.paginationFlag = true;
        this.customFlag = false;
        this.tierId = "NA";
        this.serverId = "NA";
        this.appId = "NA";
        this.correlationId = "NA";
        this.tierName = "NA";
        this.serverName = "NA";
        this.appName = "NA";
        this.urlName = "NA";
        this.urlIndex = "NA";
        this.strGroupBy = "NA";
        this.strOrderBy = "NA";
        this.flowpathSignature = "NA";
        this.shellForNDFilters = 1;
        this.showNF = false;
        this.timeVarienceForNF = "900";
        this.selectedRowInfo = [];
        this.subscriptions = []; // Array to store subscriptions for managing the lifecycle of HTTP requests in the Flowpath report.
        this.nvtondReport = false; // go back to nvtondReport
        this.compareFPInfo = []; //Array to store flowpaths for compare Flowpath report
        this.showAutoInstrPopUp = false;
        this.fptypeErrorFlag = false;
        this.errormsgObj = [{ "errorbit": "", "errmsg": "" }];
        this.nvArr = [];
        this.nvIndex = 0;
        this.nvndData = [];
        this.isCancelQuery = false; //Variable to toggle Cancel Query Dialog
        this.isCancelQuerydata = false; //variable to disable cancel query Button
        this.nvndCount = [];
        this.pageNo = 1; //Page Handling for NV-ND
        this.nvPageIndex = {}; //Store index
        this.firstPageNo = 0; // Index of the first page in pagination for the Flowpath table.
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.filtercriteria = '';
        this.filterCriteriaArray = [];
        this.elasticFPHitsData = [];
        this.totalElasticRecords = [];
        this.flowpathDataArray = [];
        const me = this;
        me.breadcrumb = breadcrumb;
        this.otelMode = this._ddrData.otelMode;
        me.fromBtTrend = me._router.getCurrentNavigation().extras.state;
        me.menuItems = [
            { label: "Log Monitoring", command: (event) => { me.openNetForest(); } },
            { label: "UX Monitoring", command: (event) => { me.openNVFromND(); } },
            { label: "Start Dynamic Diagnostics", command: (event) => { me.openAutoInstDialog(); } },
            { label: "Copy Flowpath Link", command: (event) => { me.copyLink(); } },
            { label: "Show All Session Flowpaths", command: (event) => { me.openFlowpathWithNvFilter('session'); } },
            { label: "Show All NVSession Flowpaths", command: (event) => { me.openFlowpathWithNvFilter('nvsession'); } },
            { label: "Compare Flowpaths", command: (event) => { me.compareFlowpaths(); } },
            { label: "Open Aggregate Method Timing", command: (event) => { me.openAggregateMethodTiming(); } }
        ];
        // Add "Delete Cached Data" menu option only when otelMode is disabled 
        if (!this.otelMode) {
            me.menuItems.push({ label: "Delete Cached Data", command: (event) => { me.openDeleteCache(); } });
        }
        if (!this.otelMode) {
            this.relativePath = "ddr/flowpathReport/flowpathreport.json";
        }
        else {
            this.relativePath = "ddr/flowpathReport/flowpathreport-elasticSearch.json";
        }
        if (me.showNF) {
            this.menuItems.push({ label: "Show All Flowpaths of selected Flowpath's PageInstance", command: (event) => { me.openFlowpathWithNvFilter('page'); } });
        }
    }
    ngOnInit() {
        this.commonService.isFromCQM = false;
        this._ddrData.getConfigUIPermission();
        this.loading = true;
        this._ddrData.splitViewBreadCrumbFlag = false;
        this.first.first = 0;
        this.rows.rows = 50;
        if (this._ddrData.paginationFlag == true) {
            this.setFpLimitOffset(50, 0, false);
            this.commonService.rowspaerpage = 50;
            this._ddrData.paginationFlag = false;
        }
        if (!this.commonService.fpLimit) {
            this.setFpLimitOffset(this.fpLimit, this.fpOffset, false);
        }
        this.commonService.currentReport = "Flowpath";
        this.commonService.isIntegratedFlowpath = true;
        this.commonService.enableQueryCaching = this._ddrData.enableQueryCaching;
        this.fpLimit = this.commonService.rowspaerpage;
        this.urlParam = this.commonService.getData();
        if (!this.fromBtTrend) {
            this.urlParam.urlIndex = undefined;
        }
        this.urlParam.testRun = this.sessionService.session.testRun.id;
        if (this.urlParam.product)
            this.urlParam.product = this.urlParam.product.replace("/", "");
        if (this._ddrData.tagData) {
            this.tagInfo = this._ddrData.createGtagsIntoStr(this._ddrData.tagData);
        }
        this.commonFpCode();
        this.commonService.isToLoadSideBar = true;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    fillData() {
        try {
            if (this._ddrData.cmdArgsFlag === true) {
                this.getFlowpthDataForFPAnalyzer();
            }
            else {
                this.getFlowpathData();
                if (!this.otelMode) {
                    if (this._ddrData.FromhsFlag != 'true') {
                        if (!(this.urlParam && this.urlParam.isFromNV && this.urlParam.isFromNV == "1" && (this.urlParam.flowpathID || this.urlParam.flowpathID === "NA") && this.sessionService.preSession.multiDc === true))
                            this.getFlowpathDataCount();
                    }
                }
            }
            this.createLinkForCopy();
            if (this.urlParam.backendName && this.urlParam.backendName != "NA" && this.urlParam.backendName != "undefined") {
                if (this.checkrespTime()) {
                    this.cols[0].cols.push({ valueField: 'backendMaxDur', label: 'Max IP Res time(ms)', "selected": true, width: '130' });
                    this.visibleCols.push('backendMaxDur');
                }
            }
            if (this.urlParam && this.urlParam.isFromNV && this.urlParam.isFromNV == "1" && (!this.urlParam.flowpathID || this.urlParam.flowpathID === "NA") && this.sessionService.preSession.multiDc === true) { //NV-ND ALL case 
                this.cols[0].cols.push({ valueField: 'dcName', label: 'DC Name', "selected": false, width: '75' });
            }
            this._ddrData.passMesssage$.subscribe((message) => {
                if (message == "Query Saved") {
                    this.showNotification('success', `Query Saved as${this._ddrData.saveMessage}`);
                }
                else
                    this.showNotification('error', message);
            });
        }
        catch (error) {
            console.error("Error: ", error);
        }
    }
    checkrespTime() {
        if (this.urlParam && (this.urlParam.backendRespTime || this.urlParam.backendRespTime >= 0)
            && this.urlParam.backendRespTime != "undefined" && this.urlParam.backendRespTime != "NA") {
            return true;
        }
        else
            return false;
    }
    createLinkForCopy() {
        let url = `${window.location.protocol}//${window.location.host}`;
        let dcParams = '';
        if (this.sessionService.preSession.multiDc === true) {
            dcParams = `&dcIp=${this._ddrData.host}&dcPort=${this._ddrData.port}&dcProtocol=${this._ddrData.protocol}`;
        }
        else {
            dcParams = `&dcIp=&dcPort=&dcProtocol=`;
        }
        let nvCopyLinkParam = this.generateNvCopyLinkParam();
        let dcName = this.sessionService.preSession.multiDc === true ? (this._ddrData.isFromNV === '1' || this.urlParam.isFromNV === '1' ? 'ALL' : this._ddrData.dcName) : this.selectedDC;
        if (this._ddrData.IPByFPFlag === true) {
            this.urlParam.tierName = this.commonService.IPByFPData.tierName;
            this.commonService.fpFilters.appName = this.commonService.IPByFPData.appName;
            this.commonService.fpFilters.serverName = this.commonService.IPByFPData.serverName;
            this.urlParam.tierId = this.commonService.IPByFPData.tierId;
            this.urlParam.startTime = this.commonService.IPByFPData.startTime;
            this.urlParam.endTime = this.commonService.IPByFPData.endTime;
        }
        else if (this._ddrData.FromhsFlag == 'true') {
            this.urlParam.tierName = this.commonService.hstofpData.tierName;
            this.commonService.fpFilters.serverName = this.commonService.hstofpData.serverName;
            this.commonService.fpFilters.appName = this.commonService.hstofpData.appName;
            this.urlParam.tierId = this.commonService.hstofpData.tierid;
            this.urlParam.serverId = this.commonService.hstofpData.serverid;
            this.urlParam.appId = this.commonService.hstofpData.appid;
            this.urlParam.startTime = this.commonService.hstofpData.hsTimeInMs;
            this.strEndTime = this.commonService.hstofpData.hsEndTime;
            this.threadId = this.commonService.hstofpData.threadId;
            this.urlParam.endTime = this.commonService.hstofpData.hsEndTime;
            this.flowpathEndTime = this.commonService.hstofpData.flowpathEndTime;
            this.paginationFlag = false;
        }
        this.copyFlowpathLink = this.constructCopyFlowpathLink(url, dcParams, nvCopyLinkParam, dcName);
    }
    generateNvCopyLinkParam() {
        if (this.urlParam && this.urlParam.isFromNV && this.urlParam.isFromNV === '1') {
            let nvFilter = this.nvFilter || this.urlParam.nvFilter || '';
            nvFilter = nvFilter.replace('=', 'Z');
            return this.nvArr[this.nvIndex] ? `${this.nvArr[this.nvIndex]}&nvIndex=${this.nvIndex}&isFromNV=1&nvFilter=${nvFilter}` :
                `&nvIndex=${this.nvIndex}&isFromNV=1&nvFilter=${nvFilter}`;
        }
        return '';
    }
    constructCopyFlowpathLink(url, dcParams, nvCopyLinkParam, dcName) {
        return `${url}/UnifiedDashboard/ddrcopylink.html?requestFrom=DDRA9&testRun=${this.urlParam.testRun}&tierName=${this.urlParam.tierName}&serverName=${this.commonService.fpFilters.serverName}&appName=${this.commonService.fpFilters.appName}&tierId=${this.urlParam.tierId}&startTime=${this.urlParam.startTime}&endTime=${this.urlParam.endTime}&product=${decodeURIComponent(this.urlParam.product)}&btCategory=${this.commonService.fpFilters.btCategory}&urlName=${this.urlParam.urlName}&statusCode=-2&timeZoneId=${this.urlParam.timeZoneId}&userName=${sessionStorage.getItem('sesLoginName')}&strOrderBy=${this.commonService.fpFilters.strOrderBy}&strGroupBy=${this.commonService.fpFilters.strGroupBy}&ajaxTimeout=${this.commonService.ajaxTimeOut}&flowpathID=${this.commonService.fpFilters.flowpathID}${nvCopyLinkParam}&correlationId=${encodeURIComponent(this.urlParam.correlationId)}&mode=${this.urlParam.mode}&sqlIndex=${this.commonService.fpFilters.sqlIndex}&dcName=${dcName}&backendId=${this.urlParam.backendId}&backendRespTime=${this.urlParam.backendRespTime}&backendName=${this.urlParam.backendName}&flowpathEndTime=${this.flowpathEndTime}&threadId=${this.threadId}&paginationFlag=${this.paginationFlag}&path=/home/ddrCopyLink/flowpath${dcParams}&verifyUser=${_services_common_services__WEBPACK_IMPORTED_MODULE_9__["LZString"].compressToEncodedURIComponent(sessionStorage.getItem('sesLoginName'))}`;
    }
    getFlowpthDataForFPAnalyzer() {
        const payload = {
            cmdArgs: this.commonService.fpAnalyzeData.cmdArgs,
            pagination: ' --limit 50 --offset 0',
            btName: this.commonService.fpAnalyzeData.btName,
            testRun: this.urlParam.testRun,
            startTime: this.commonService.fpAnalyzeData.startTime,
            endTime: this.commonService.fpAnalyzeData.endTime,
            FileName: this.urlParam.FileName,
            fpCount: this.commonService.fpAnalyzeData.fpCount
        };
        this.ddrHttpService.getFlowpathreportForFPAnalyser(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["FlowpathreportForFPAnalyserLoadedState"]) {
                this.assignFlowpathData(state.data);
                this.loading = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.flowpathData = [];
            // this.commonService.showError(error);
            this.loading = false;
        });
    }
    setDefaultSort(fpParam) {
        if (fpParam != undefined && Object.keys(fpParam).length != 0) {
            if (fpParam.strOrderBy == 'btcputime_desc')
                this.commonService.sortedField = 'btCpuTime';
            else if (fpParam.strOrderBy == 'error_callout')
                this.commonService.sortedField = 'totalError';
            else if (this.checkrespTime())
                this.commonService.sortedField = 'backendMaxDur';
            else if (this.urlParam.isFromNV && this.urlParam.isFromNV === "1") {
                this.commonService.sortedField = "startTime";
                this.commonService.sortedOrder = "1";
            }
            else
                this.commonService.sortedField = 'fpDuration';
        }
    }
    getFlowpathData() {
        this.urlAjaxParam = "";
        let pagination = "";
        let ajaxFlags = "";
        let customDataFilter = "";
        let finalUrl = "";
        if (this._ddrData.FromhsFlag != 'true') {
            pagination = '&limit=' + this.fpLimit + '&offset=' + this.fpOffset;
            ajaxFlags = '&customFlag=' + this.customFlag;
        }
        this.url = this.commonService.enableQueryCaching === 1 ? `cacheId=${this.urlParam.testRun}&testRun=${this.urlParam.testRun}` : `testRun=${this.urlParam.testRun}&sort_order=duration_desc`;
        try {
            if (this._ddrData.nvCqm) {
                this.nvndData = [];
                this.nvndCount = [];
                this.nvPageIndex = [];
                this.pageNo = 1;
                this._ddrData.nvCqm = false;
            }
            // sidebar filters to flowpath
            if (this.commonService.isFilterFromSideBar && Object.keys(this.commonService.fpFilters).length != 0) {
                this.fpLimit = this.setFpLimitOffset(this.commonService.fpLimit, this.commonService.fpOffset, true)[0];
                let fpParam = this.commonService.fpFilters;
                this.selectedRowInfo = []; //Changes regarding bug id--49272
                if (fpParam["isContainsNSFilters"] == true)
                    this.shellForNDFilters = 0;
                else
                    this.shellForNDFilters = 1;
                fpParam["testRun"] = this.urlParam.testRun;
                this.urlAjaxParam = this.commonService.makeParamStringFromObj(this.commonService.fpFilters, true);
                if (this.commonService.fpFilters['tags'] != undefined && this.commonService.fpFilters['tags'] != null) {
                    this.urlAjaxParam += "&tags=" + this.commonService.fpFilters['tags'];
                }
            }
            else {
                this.commonService.fpFilters = {};
                let fpParam = this.urlParam;
                if (fpParam["isContainsNSFilters"] == 'true') {
                    this.shellForNDFilters = 0;
                }
                else {
                    this.shellForNDFilters = 1;
                }
                this.makeAjaxParameter();
                this.tierName = !this.tierName ? (this.urlParam && this.urlParam.tierName ? this.urlParam.tierName : sessionStorage.getItem("tierName")) : this.tierName;
                // making url for Ajax Call
                this.urlAjaxParam = `&flowpathSignature=${this.flowpathSignature}&strGroup=${this.strGroupBy}&tierName=${this.tierName}&serverName=${this.serverName}&appName=${this.appName}&tierId=${this.tierId}&serverId=${this.serverId}&appId=${this.appId}&strStartTime=${this.strStartTime}&strEndTime=${this.strEndTime}&threadId=${this.threadId}&sqlIndex=${this.sqlIndex}&btCategory=${this.btCategory}&flowpathEndTime=${this.flowpathEndTime}&statusCode=-2&object=4&checkBoxValForURLIndexFromURLName=${this._ddrData.valueForCheckBox}`;
                this.urlAjaxParam += this.urlParam.urlIndex ? ("&urlIndex=" + this.urlParam.urlIndex) : ('&urlName=' + this.urlName);
                this.urlAjaxParam += this.commonService.fpFilters['tags'] ? ("&tags=" + this.commonService.fpFilters['tags']) : '';
                if (this.urlParam.isFromNV && this.urlParam.isFromNV === "1") {
                    this.urlAjaxParam += "&strOrderBy=stime";
                    this.commonService.sortedField = "startTime";
                    this.commonService.sortedOrder = "1";
                    document.title = "Cavisson Netdiagnostics Enterprise";
                }
                else
                    this.urlAjaxParam += "&strOrderBy=" + this.strOrderBy;
                if (this._ddrData.customToFlowpathFlag === true) {
                    this.urlAjaxParam += '&urlIndex=' + this.urlIndex;
                    this.urlAjaxParam += (this.commonService.patternflag === true && !this._ddrData.dbTofpflag) ? '&customData=' + this.customData + '&customFilter=' + this.CustomFilter + '&templateName=FP' : '';
                }
                if (((this.urlParam.resTimeFlagforCustomData === '1' && this._ddrData.nvFiltersFlag !== true) || sessionStorage.getItem('resTimeFlagforCustomData') === '1') && this.urlParam.searchByCustomDataOptions !== "NA" && !this._ddrData.dbTofpflag) {
                    this.urlAjaxParam += '&templateName=FP';
                }
                let mode = this.urlParam.mode || sessionStorage.getItem('mode');
                if (mode && mode !== 'NA' && this.urlParam.mode !== 'undefined') {
                    this.urlAjaxParam += '&mode=' + this.urlParam.mode;
                }
                if (this.urlParam && Object.keys(this.urlParam).length > 0 && this.urlParam != "undefined") {
                    this.urlAjaxParam += '&pageIdx=' + this.urlParam.pageIdx + '&pageName=' + this.urlParam.pageName + '&transtx=' + this.urlParam.transtx +
                        '&script=' + this.urlParam.script + '&sessionIndex=' + this.urlParam.sessionIndex + '&nsUrlIdx=' + this.urlParam.nsUrlIdx +
                        '&location=' + this.urlParam.location + '&access=' + this.urlParam.access + '&userBrowserIndex=' + this.urlParam.userBrowserIndex +
                        '&strStatus=' + this.urlParam.strStatus + '&generatorId=' + this.urlParam.generatorId + '&generatorName=' + this.urlParam.generatorName +
                        '&urlNameFC=' + this.urlParam.urlNameFC;
                }
                if (this.urlParam.customData && this.urlParam.customData !== "NA" && this.urlParam.customData !== "undefined" && !this._ddrData.dbTofpflag) {
                    this.urlAjaxParam += '&customData=' + this.customData + '&templateName=FP';
                }
                if (this.urlParam.correlationId && this.urlParam.correlationId !== "NA") {
                    this.urlAjaxParam += '&correlationId=' + this.correlationId;
                }
                if (this.urlParam.flowpathID && this.urlParam.flowpathID !== "NA") {
                    this.urlAjaxParam += '&flowpathID=' + this.flowpathID;
                }
                if (this.validateField(this._ddrData.flowpathID)) {
                    this.urlAjaxParam += '&flowpathID=' + this._ddrData.flowpathID;
                }
                if (this._ddrData.FromexpFlag == 'true') {
                    this.urlAjaxParam += '&flowpathID=' + this.flowpathID;
                }
                if (this._ddrData.fpIdFromNSSession) {
                    this.urlAjaxParam += '&flowpathID=' + this.flowpathID;
                }
                if (this._ddrData.urlIndexAgg && this._ddrData.isFromtrxFlow) {
                    this.urlAjaxParam += '&urlIndex=' + this._ddrData.urlIndexAgg;
                }
                if (this._ddrData.FromexpFlag != 'true') {
                    let nvParamAll = "", nvParamNdNv = "", nvParamNd = "";
                    if (this.urlParam.nvPageId && this.urlParam.nvPageId !== "NA") {
                        nvParamAll = "&nvPageId=" + this.urlParam.nvPageId;
                    }
                    else if (this.nvIndex == 0) {
                        this.nvIndex = 1;
                    }
                    if (this.urlParam.nvSessionId && this.urlParam.nvSessionId !== "NA") {
                        nvParamAll += "&nvSessionId=" + this.urlParam.nvSessionId;
                    }
                    else {
                        this.nvIndex = 2;
                    }
                    if (this.urlParam.ndSessionId && this.urlParam.ndSessionId !== "NA") {
                        nvParamAll += "&ndSessionId=" + this.urlParam.ndSessionId;
                        nvParamNd = "&ndSessionId=" + this.urlParam.ndSessionId;
                        nvParamNdNv = "&nvSessionId=" + this.urlParam.nvSessionId + nvParamNd;
                    }
                    this.nvArr = [nvParamAll, nvParamNdNv, nvParamNd];
                }
                if (this.urlParam && this.urlParam.isFromNV && this.urlParam.isFromNV == "1" && !(this.sessionService.preSession.multiDc === true && (!this.urlParam.flowpathID || this.urlParam.flowpathID == "NA"))) {
                    if (this.urlParam.nvIndex && this.urlParam.nvIndex != "undefined")
                        this.nvIndex = Number(this.urlParam.nvIndex);
                    this.urlAjaxParam += (this.nvArr[this.nvIndex] && this.nvArr.length > 0) ? (this.nvArr[this.nvIndex] + "&nvIndex=" + this.nvIndex + "&isFromNV=" + this.urlParam.isFromNV) : ("&isFromNV=" + this.urlParam.isFromNV);
                }
                if (this._ddrData.nvFiltersFlag == true) {
                    this.urlAjaxParam += "&ndSessionId=" + this.urlParam.ndSessionId + "&nvSessionId=" + this.urlParam.nvSessionId + "&nvPageId=" + this.urlParam.nvPageId + "&NVtoNDFilterForAngular=1";
                }
                if (this.tagInfo && this.tagInfo.length != 0) {
                    this.urlAjaxParam += "&tags=" + this.tagInfo;
                }
                this.urlAjaxParamObject = this.commonService.makeObjectFromUrlParam(this.urlAjaxParam);
                this.commonService.fpFilters = this.urlAjaxParamObject;
                this.commonService.fpFilters['corModeValue'] = this.urlParam.mode;
                if (this.commonService.isValidParamInObj(this.urlAjaxParamObject, 'flowpathID')) {
                    this.commonService.isCheckedFlowpath = true;
                    this.commonService.flowpathInstance = this.flowpathID;
                }
            }
            if (this._ddrData.IPByFPFlag === true) {
                this.urlParam.backendId = this.commonService.IPByFPData.backendId;
                this.urlParam.backendRespTime = this.commonService.IPByFPData.maxresTimeOfBackend;
                this.urlParam.backendName = this.commonService.IPByFPData.backendName;
                this.urlAjaxParam += '&urlIndex=' + this._ddrData.urlIndex;
                this.urlName = this.commonService.IPByFPData.urlNameIP;
            }
            const backendId = this.urlParam['backendId'];
            if (this.urlParam && backendId && backendId != "undefined" && backendId != "NA") {
                this.urlAjaxParam += '&backenId=' + backendId + '&backendResTime=' + this.urlParam.backendRespTime;
            }
            this.setDefaultSort(this.commonService.fpFilters);
            if (!this.urlAjaxParam.startsWith('&')) {
                this.urlAjaxParam = '&' + this.urlAjaxParam;
            }
            finalUrl = `${this.url}${this.urlAjaxParam}${pagination}${ajaxFlags}${customDataFilter}&showCount=false&shellForNDFilters=${this.shellForNDFilters}&queryId=${this.queryId}`;
            if (this.urlParam && this.urlParam.isFromNV && this.urlParam.isFromNV == "1" && (!this.urlParam.flowpathID || this.urlParam.flowpathID === "NA") && this.sessionService.preSession.multiDc === true) { //NV-ND ALL case
                console.log("nv case");
                this.getNVtoNDForAll(this.urlAjaxParam + ajaxFlags + customDataFilter + '&queryId=' + this.queryId).then(() => {
                    console.log("Done resolving");
                    this.processingInterval = setInterval(() => {
                        if (this.checkIntervalFlag == this.ndeInfoData.length || Object.keys(this.nvPageIndex).length > 0)
                            this.callFlowPathFromNVNForAllDC();
                        console.log("checking Interval ", this.checkIntervalFlag, " k ", Object.keys(this.nvPageIndex).length);
                    }, 300);
                });
            }
            else {
                //commenting for now TBD: Query Cancellation
                // setTimeout(() => {
                //   this.openpopup();
                // }, this._ddrData.guiCancelationTimeOut);
                if (!this.otelMode) {
                    this.fetchDataFromPsql(finalUrl);
                }
                else {
                    if (this._ddrData.otelServiceName) {
                        finalUrl += `&serviceName=${this._ddrData.otelServiceName}`;
                    }
                    this.fetchDataFromElasticSearch(finalUrl);
                }
            }
            this.customFlag = false;
        }
        catch (error) {
            console.error('error in getting data from rest call', error);
        }
    }
    /**
     * Makes a REST call to get flowpath report data from PostgreSQL.
     * @param url the URL to fetch the data from
     */
    fetchDataFromPsql(url) {
        const dataSubscription = this.ddrHttpService.getFlowpathReportData(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["FlowpathReportLoadedState"]) {
                this.assignFlowpathData(state.data);
                this.loading = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.flowpathData = [];
            // this.commonService.showError(error);
            this.loading = false;
        });
        this.subscriptions.push(dataSubscription);
    }
    /**
     * Fetches flowpath data from Elasticsearch using the specified URL.
     * Constructs a query with necessary fields and subscribes to the search results.
     * Processes the retrieved data or handles errors appropriately.
     *
     * @param url The URL to build the query payload for fetching data.
     */
    fetchDataFromElasticSearch(url) {
        const reqPayload = this.ddrHttpService.createPayloadForPOSTCall(url);
        if (window['logLevel'] > 1) {
            console.log("********reqPayload******", reqPayload);
        }
        const resFields = [
            "trace_id",
            "span_id",
            "@timestamp",
            "duration",
            "attributes.url.path",
            "attributes.http.response.status_code",
            "attributes.cav.tier",
            "attributes.cav.server",
            "attributes.cav.instance",
            "attributes.cav.BT",
            "attributes.http.url",
            "attributes.http.target",
            "attributes.http.status_code",
            "attributes.cav.TR",
            "resource.attributes.service.name",
            "resource.attributes.host.name",
            "resource.attributes.service.instance.id",
            "resource.attributes.process.pid",
            "resource.attributes.telemetry.sdk.language"
        ];
        const elasticQuery = this.elasticSearchService.buildElasticSearchQuery(reqPayload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_13__["BREADCRUMB_ITEMS"].FLOWPATH);
        if (window['logLevel'] > 1) {
            console.log("********elasticQuery******", elasticQuery);
        }
        const dataSubscription = this.elasticSearchService.search(elasticQuery).subscribe(res => {
            this.elasticFPData = res;
            if (window['logLevel'] > 1) {
                console.log('Search results from Elasticsearch:', this.elasticFPData);
            }
            this.processElasticData(this.elasticFPData);
        }, error => {
            console.error('Error searching Elasticsearch:', error);
            this.flowpathData = [];
            this.fpTotalCount = 0;
            this.loading = false;
        });
        this.subscriptions.push(dataSubscription);
    }
    processElasticData(elasticData) {
        this.commonService.isFilterFromSideBar = false;
        if (elasticData && elasticData.hits && elasticData.hits.hits) {
            this.elasticFPHitsData = elasticData.hits.hits;
            this.totalElasticRecords = elasticData.hits.total.value;
            this.flowpathDataArray = this.elasticFPHitsData.map((record) => {
                var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
                // Creating new FlowpathData object and assign properties for every record from elastic search
                let source = record._source;
                let attributes = source.attributes;
                let resourceAttributes = source.resource.attributes;
                // Calculate the duration in milliseconds
                const durationInMs = Number(source["duration"]) / 1000000;
                return {
                    tierName: (_a = attributes["cav.tier"]) !== null && _a !== void 0 ? _a : resourceAttributes["service.name"],
                    serverName: (_b = attributes["cav.server"]) !== null && _b !== void 0 ? _b : resourceAttributes["host.name"],
                    appName: (_d = (_c = attributes["cav.instance"]) !== null && _c !== void 0 ? _c : resourceAttributes["service.instance.id"]) !== null && _d !== void 0 ? _d : resourceAttributes["process.pid"],
                    urlName: (_e = attributes["cav.BT"]) !== null && _e !== void 0 ? _e : "-",
                    urlQueryParamStr: (_h = (_g = (_f = attributes["url.path"]) !== null && _f !== void 0 ? _f : attributes["http.url"]) !== null && _g !== void 0 ? _g : attributes["http.target"]) !== null && _h !== void 0 ? _h : "-",
                    startTimeInMs: (_j = Number(source["@timestamp"])) !== null && _j !== void 0 ? _j : "",
                    statusCode: Number(attributes["http.response.status_code"]) || Number(attributes["http.status_code"]) || "",
                    selfResponseTime: isNaN(durationInMs) ? "" : durationInMs,
                    TraceId: (_k = source["trace_id"]) !== null && _k !== void 0 ? _k : "-",
                    spanId: (_l = source["span_id"]) !== null && _l !== void 0 ? _l : "-",
                    Instance_Type: (_m = resourceAttributes["telemetry.sdk.language"]) !== null && _m !== void 0 ? _m : "-",
                    serviceName: (_o = resourceAttributes["service.name"]) !== null && _o !== void 0 ? _o : "-"
                };
            });
            this.fpTotalCount = this.totalElasticRecords;
            this.flowpathData = this.flowpathDataArray;
            if (this.fpTotalCount > 0 && this.fpLimit > this.fpTotalCount) {
                this.fpLimit = Number(this.fpTotalCount);
            }
            this.first = { first: this.fpOffset };
            this.rows = { rows: this.fpLimit };
            this.loading = false;
            this.filtercriteria = this.elasticSearchService.filtercriteria;
            // Split by comma, trim spaces, and filter out empty values
            this.filterCriteriaArray = this.filtercriteria
                .split(',')
                .map(item => item.trim())
                .filter(item => item.length > 0);
            if (window['logLevel'] > 1) {
                console.log("Elasticsearch processed Flowpath Final Data", this.flowpathDataArray);
            }
        }
        else {
            this.flowpathData = [];
            this.fpTotalCount = 0;
            this.loading = false;
        }
    }
    validateField(validateParam) {
        const invalidValues = [null, "null", "undefined", undefined, "NA", "", "NaN", "-"];
        return !invalidValues.includes(validateParam);
    }
    /**
     * Setting common parameters when flowpath report is open from different reports.
     * Used in makeAjaxParameter.
     * @param commonObject
     */
    setCommonParameters(commonObject) {
        this.tierName = commonObject.tierName;
        this.serverName = commonObject.serverName;
        this.appName = commonObject.appName;
        this.tierId = commonObject.tierid;
        this.serverId = commonObject.serverid;
        this.appId = commonObject.appid;
        this.strStartTime = commonObject.startTime || commonObject.hsTimeInMs || this.trStartTime;
        this.strEndTime = commonObject.endTime || commonObject.hsEndTime || this.trEndTime;
    }
    makeAjaxParameter() {
        if (this._ddrData.FromexpFlag == 'true') {
            this.flowpathID = this.commonService.exptoFpData.flowPathInstance;
            this.setCommonParameters(this.commonService.exptoFpData);
        }
        else if (this._ddrData.FromhsFlag == 'true') {
            this.setCommonParameters(this.commonService.hstofpData);
            this.threadId = this.commonService.hstofpData.threadId;
            this.flowpathEndTime = this.commonService.hstofpData.flowpathEndTime;
            this.paginationFlag = false;
        }
        else if (this._ddrData.IPByFPFlag === true) {
            this.setCommonParameters(this.commonService.IPByFPData);
        }
        else if (this._ddrData.dbTofpflag == true) {
            this.setCommonParameters(Object.assign(Object.assign({}, this.commonService._dbflowpathdata), { strStartTime: this.trStartTime, strEndTime: this.trStartTime }));
            this.sqlIndex = this.commonService._dbflowpathdata.sqlIndex;
            this.btCategory = this.urlParam.btCategory;
            this.urlParam.strOrderBy = 'fpduration_desc';
            this.strOrderBy = this.urlParam.strOrderBy;
        }
        else if (this._ddrData.fpIdFromNSSession) {
            //From Session Timing Detail 
            this.flowpathID = this._ddrData.fpIdFromNSSession;
            this.strStartTime = this.urlParam.startTime;
            this.strEndTime = this.urlParam.endTime;
        }
        else {
            this.flowpathID = this.urlParam.flowPathInstance;
            this.setCommonParameters(Object.assign(Object.assign({}, this.urlParam), { strStartTime: this.trStartTime, strEndTime: this.trStartTime }));
            this.urlName = this.urlParam.urlName;
            this.strOrderBy = this.urlParam.strOrderBy;
            if (this.urlParam.customData && this.urlParam.customData !== 'NA') {
                this.customData = this.urlParam.customData;
            }
            if (this.urlParam.correlationId && this.urlParam.correlationId !== 'NA') {
                this.correlationId = this.urlParam.correlationId;
            }
            if (this.urlParam.flowpathID && this.urlParam.flowpathID !== 'NA' && this.urlParam.flowpathID !== "undefined") {
                this.flowpathID = this.urlParam.flowpathID;
            }
            if (this.validateField(this._ddrData.flowpathID)) {
                this.flowpathID = this._ddrData.flowpathID;
            }
            if (this.urlParam.sqlIndex && this.urlParam.sqlIndex !== 'NA') {
                this.sqlIndex = this.urlParam.sqlIndex;
            }
            if (this._ddrData.urlFlag === true) {
                this.btCategory = 'All';
                this.strGroupBy = 'url';
                this.tableOptions = false;
                this._ddrData.urlFlag = false;
            }
            else {
                this.btCategory = this.urlParam.btCategory;
                this.tableOptions = true;
            }
            if (this._ddrData.fpByBTFlag === true) {
                this.urlIndex = this.commonService.fpByBTData.urlIndex;
                this.urlName = this.commonService.fpByBTData.urlName;
                this.btCategory = this.commonService.getBTCategoryID(this.commonService.fpByBTData.btCatagory);
                this._ddrData.fpByBTFlag = false;
            }
            if (this._ddrData.fpSignatureflag == true) {
                this.strGroupBy = 'flowpathsignature';
            }
            if (this.commonService.signatureTofpFlag === true) {
                this.flowpathSignature = this.commonService.signatureTofpData.flowpathSignature;
            }
        }
    }
    getFlowpathDataCount() {
        try {
            const queryParam = this.url + this.urlAjaxParam + '&limit=' + this.fpLimit + '&offset=' + this.fpOffset + '&showCount=true&shellForNDFilters=' + this.shellForNDFilters;
            const countSubscription = this.ddrHttpService.getFlowpathCountData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["FlowpathCountLoadedState"]) {
                    this.assignFlowpathDataCount(state.data);
                }
            }, (error) => {
                console.error('Error return from getFlowpathCountData ~ ', error);
            });
            this.subscriptions.push(countSubscription);
        }
        catch (error) {
            console.error('error getFlowapthDatacount Method ~ ', error);
        }
    }
    assignFlowpathDataCount(res) {
        if (res && res.totalCount && Number(res.totalCount > 0)) {
            this.fpTotalCount = res.totalCount;
            if (this.fpTotalCount > 0 && this.fpLimit > this.fpTotalCount) {
                this.fpLimit = Number(this.fpTotalCount);
            }
        }
        else if (this._ddrData.isFromNV !== "1") {
            this.fpTotalCount = 0;
        }
    }
    assignFlowpathData(res) {
        this.isCancelQuerydata = true;
        this.commonService.isFilterFromSideBar = false;
        try {
            if (res === "[]") {
                this.loading = false;
            }
            if (res === null || res === undefined) {
                return;
            }
            this.commonService.cmdFileName = res.fileName;
            this.commonService.edStrStartDate = this.sessionService.convertTimestampIntoFormattedString(Number(res.strStartTime), "MM/DD/YYYY HH:mm:ss");
            this.commonService.edStrEndDate = this.sessionService.convertTimestampIntoFormattedString(Number(res.strEndTime), "MM/DD/YYYY HH:mm:ss");
            if (res.hasOwnProperty('nodeName')) {
                this._ddrData.dcName = res.nodeName;
            }
            if (!this.otelMode) {
                this.filtercriteria = this.commonService.createFilterCriteria(this.commonService.fpFilters, this.nvFilter);
            }
            this.createLinkForCopy();
            if (res.hasOwnProperty('Status')) {
                if (this._ddrData.isFromNV !== "1" || ((this._ddrData.isFromNV === "1") && (this.nvIndex == 2 || (this.urlParam.flowpathID && this.urlParam.flowpathID != "NA")) && (this.sessionService.preSession.multiDc != true || (this.sessionService.preSession.multiDc === true))))
                    this.commonService.showError(res.Status);
                else if (this._ddrData.isFromNV === "1" && (this.nvIndex == 2 || (this.urlParam.flowpathID && this.urlParam.flowpathID != "NA")))
                    this.commonService.showError(res.Status);
            }
            this.fpData = res.data || [];
            if (this.fpData.length > 0) {
                this.flowpathData = this.addFlagDetails(this.fpData);
            }
            else {
                this.flowpathData = this.fpData;
            }
            this.loading = false;
            if (!JSON.stringify(this.flowpathData).includes("gcPause") && this.cols[31] && this.cols[31]["field"] == "gcPause") {
                this.cols[0].cols.splice(31, 1);
            }
            if (res.hasOwnProperty('totalCount')) {
                this.fpTotalCount = res.totalCount;
                if (this.fpTotalCount > 0 && this.fpLimit > this.fpTotalCount)
                    this.fpLimit = Number(this.fpTotalCount);
            }
            if (this.flowpathData.length !== 0) {
                this.flowpathData.forEach((val, index) => {
                    if (val['correlationId'] === '') {
                        val['correlationId'] = '-';
                    }
                    if (val['waitTime'] === '' || val['syncTime'] === '' || val['iotime'] === '' || val['suspensiontime'] === '') {
                        val['waitTime'] = '0';
                        val['syncTime'] = '0';
                        val['iotime'] = '0';
                        val['suspensiontime'] = '0';
                    }
                    if (val['QTimeInMS'] === '-1') {
                        val['QTimeInMS'] = '-';
                    }
                });
            }
            if (this.tableOptions === true && this.flowpathData.length !== 0) {
                this.flowpathData.forEach((val, index) => {
                    // val.selfResponseTime = this.formatter(val.selfResponseTime, true);
                    // val.fpDuration = this.formatter(val.fpDuration, true);
                    val.methodsCount = this.formatter(val.methodsCount);
                    val.callOutCount = this.formatter(val.callOutCount);
                    val.dbCallCounts = this.formatter(val.dbCallCounts);
                    val.btCatagory = this.commonService.getBTCategoryName(val.btCatagory);
                    val.startTimeInMs = Number(val.startTimeInMs);
                    if (val.backendMaxDur)
                        val.backendMaxDur = this.formatter(val.backendMaxDur);
                });
            }
            this.fillSelection(); //select the rows based on the urlParam (NV-ND)
            setTimeout(() => {
                this.first = { first: this.fpOffset };
                this.rows = { rows: this.fpLimit };
            }, 1000);
        }
        catch (error) {
            console.error('Error in assigning flowpaht data ~ ', error);
        }
    }
    formatter(value, showLessThanOne = false) {
        const numericValue = Number(value);
        if (numericValue && numericValue > 0) {
            return numericValue.toString();
        }
        else if (numericValue === 0 && showLessThanOne) {
            return '< 1';
        }
        else {
            return value;
        }
    }
    openNetForest() {
        let flowpathInstance;
        let correlationId;
        let startTimeInMs;
        let duration;
        let ndSessionId;
        let nvPageId;
        let StartTimeArr = [];
        let EndTimeArr = [];
        let startTimeISO;
        let endTimeISO;
        let query;
        this._ddrData.isFromFlowpath = true;
        if (this.selectedRowInfo.length == 0) {
            this.showNotification("error", "No Record Selected");
            return;
        }
        if (this.selectedRowInfo.length > 1) {
            query = "";
            for (let i = 0; i < this.selectedRowInfo.length; i++) {
                flowpathInstance = this.selectedRowInfo[i]["flowpathInstance"];
                startTimeInMs = this.selectedRowInfo[i]["startTimeInMs"];
                duration = this.selectedRowInfo[i]["fpDuration"];
                let d1 = Number(startTimeInMs) - Number(this.timeVarianceInMs(this.timeVarienceForNF));
                let d2;
                if (duration == '< 1')
                    d2 = Number(startTimeInMs) + Number(this.timeVarianceInMs(this.timeVarienceForNF));
                else
                    d2 = Number(startTimeInMs) + Number(duration.replace(/,/g, '')) + Number(this.timeVarianceInMs(this.timeVarienceForNF));
                StartTimeArr.push(d1);
                EndTimeArr.push(d2);
                query += "fpi:" + flowpathInstance + '%20OR%20';
            }
            / to get shortest timestamp as start time /;
            StartTimeArr = StartTimeArr.sort(function (a, b) {
                var value = Number(a);
                var value2 = Number(b);
                return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
            });
            / to get highest timestamp as end time /;
            EndTimeArr = EndTimeArr.sort(function (a, b) {
                var value = Number(a);
                var value2 = Number(b);
                return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
            });
            if (query.endsWith('20')) {
                query = query.substring(0, query.length - 8);
                query = "( " + query + " )";
            }
            startTimeISO = StartTimeArr[0];
            endTimeISO = EndTimeArr[0];
        }
        else {
            query = "";
            flowpathInstance = this.selectedRowInfo[0]["flowpathInstance"];
            correlationId = this.selectedRowInfo[0]["correlationId"];
            startTimeInMs = this.selectedRowInfo[0]["startTimeInMs"];
            duration = this.selectedRowInfo[0]["fpDuration"];
            ndSessionId = this.selectedRowInfo[0]["ndSessionId"];
            nvPageId = this.selectedRowInfo[0]["nvPageId"];
            query = "fpi:" + flowpathInstance;
            let d1 = Number(startTimeInMs) - Number(this.timeVarianceInMs(this.timeVarienceForNF));
            let d2;
            if (duration == '< 1')
                d2 = Number(startTimeInMs) + Number(this.timeVarianceInMs(this.timeVarienceForNF));
            else
                d2 = Number(startTimeInMs) + Number(duration.replace(/,/g, '')) + Number(this.timeVarianceInMs(this.timeVarienceForNF));
            startTimeISO = d1;
            endTimeISO = d2;
            if (correlationId != "" && correlationId != "-")
                query += "%20AND%20corrid:\"" + correlationId + "\"";
            if (nvPageId != "" && nvPageId != "-")
                query += "%20AND%20pageid:" + nvPageId;
            if (ndSessionId != "" && ndSessionId != "-")
                query += "%20AND%20ndsessionid:" + ndSessionId;
            query = "( " + query + " )";
            console.log("query>>>>single case>>>>>>", query);
        }
        query = query.replaceAll("%20", " ");
        this._router.navigate(["/home/logs"], { queryParams: { queryStr: query, startTime: startTimeISO, endTime: endTimeISO } });
    }
    //This function will convert time in miliseconds. Time should be provided in formats- Nh or Nm or Ns or N or Nms where N is integer
    timeVarianceInMs(time) {
        var timeVarianceInMs = time;
        var timeVarNum = "";
        if (/^[0-9]*h$/.test(time)) //If time is in hour formate- xh eg:2h means 2 hour variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 60 * 60 * 1000;
        }
        else if (/^[0-9]*m$/.test(time)) //If time is in minute formate- xm eg:20m means 20 minute variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 60 * 1000;
        }
        else if (/^[0-9]*s$/.test(time)) //If time is in second formate- xs eg:200s means 200 second variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 1);
            timeVarianceInMs = Number(timeVarNum) * 1000;
        }
        else if (/^[0-9]*ms$/.test(time)) //If time is in millisecond formate- xs eg:200ms means 200 millisecond variance is appliend in configuration file
         {
            timeVarNum = time.substring(0, time.length - 2);
            timeVarianceInMs = Number(timeVarNum);
        }
        else if (/^[0-9]*$/.test(time)) // if there is only number, it is considered as seconds 
         {
            timeVarianceInMs = Number(time) * 1000;
        }
        else {
            this.showNotification("error", "Please provide value of 'NetDiagnosticsQueryTimeVariance' in proper format in config.ini i.e.- Nh or Nm or Ns or Nms or N where N is a integer ");
            return Number(900000); //if value of ndQueryTimeVariance is not in desired format then NF report will open with default variance time that is 15 minutes(900000ms).
        }
        return Number(timeVarianceInMs);
    }
    openNVFromND() {
        if (!this.sessionService.preSession.multiDc) {
            if (this.selectedRowInfo.length !== 1) {
                this.showNotification("error", this.selectedRowInfo.length === 0 ? "No Flowpath is Selected" : "Select Only One Flowpath at a time");
                return;
            }
            else {
                let nvSessionId = 'NA';
                let nvPageId = 'NA';
                if (this.selectedRowInfo[0]['nvSessionId'] != '-' && this.selectedRowInfo[0]['nvSessionId'] != '' && this.selectedRowInfo[0]['nvSessionId'] != "0")
                    nvSessionId = this.selectedRowInfo[0]['nvSessionId'];
                else {
                    this.showNotification("error", 'NV Session Id is not Available for ' + this.selectedRowInfo[0]['nvSessionId']);
                    return;
                }
                if (this.selectedRowInfo[0]['nvPageId'] != '-' && this.selectedRowInfo[0]['nvPageId'] != '')
                    nvPageId = this.selectedRowInfo[0]['nvPageId'];
                this._router.navigate(['/netvision/sessions-details'], { queryParams: { sid: nvSessionId } });
            }
        }
        else {
            let nvSessionId = 'NA';
            let nvPageId = 'NA';
            if (this.selectedRowInfo.length !== 1) {
                this.showNotification("error", this.selectedRowInfo.length === 0 ? "No Flowpath is Selected" : "Select Only One Flowpath at a time");
                return;
            }
            if (this.selectedRowInfo[0]['nvSessionId'] != '-' && this.selectedRowInfo[0]['nvSessionId'] != '' && this.selectedRowInfo[0]['nvSessionId'] != "0") {
                nvSessionId = this.selectedRowInfo[0]['nvSessionId'];
            }
            else {
                this.showNotification("error", 'NV Session Id is not Available for ' + this.selectedRowInfo[0]['nvSessionId']);
                return;
            }
            if (this.selectedRowInfo[0]['nvPageId'] != '-' && this.selectedRowInfo[0]['nvPageId'] != '' && this.selectedRowInfo[0]['nvPageId'] != "0")
                nvPageId = this.selectedRowInfo[0]['nvPageId'];
            if (this.flowBack) {
                this._ddrData.isFromtrxFlow = false;
            }
            sessionStorage.removeItem('__nvSessionData');
            this._router.navigate(['/netvision/sessions-details'], { queryParams: { sid: nvSessionId } });
        }
    }
    openFlowpathWithNvFilter(filter) {
        if (this.selectedRowInfo.length == 0) {
            this.showNotification('error', 'No Record Selected');
            return;
        }
        else {
            let ndSessionId = '';
            let nvPageId = '';
            let nvSessionId = '';
            for (let k = 0; k < this.selectedRowInfo.length; k++) {
                if (filter == 'session') {
                    let currentSessionId = this.selectedRowInfo[k]["ndSessionId"];
                    if (k == 0 && currentSessionId != '-' && currentSessionId != '')
                        ndSessionId = currentSessionId;
                    else if (currentSessionId != '-' && currentSessionId != '' && ndSessionId.indexOf(currentSessionId) == -1)
                        ndSessionId += ',' + currentSessionId;
                }
                else if (filter == 'page') {
                    let currentNVSessionId = this.selectedRowInfo[k]['nvSessionId'];
                    if (k == 0 && currentNVSessionId != '' && currentNVSessionId != '-')
                        nvSessionId = currentNVSessionId;
                    else if (currentNVSessionId != '' && currentNVSessionId != '-' && nvSessionId.indexOf(currentNVSessionId) == -1)
                        nvSessionId += "," + currentNVSessionId;
                    let currentPageId = this.selectedRowInfo[k]["nvPageId"];
                    if (k == 0 && currentPageId != "" && currentPageId != "-")
                        nvPageId = currentPageId;
                    else if (currentPageId != "" && currentPageId != "-" && nvPageId.indexOf(currentPageId) == -1)
                        nvPageId += "," + currentPageId;
                }
                else if (filter == 'nvsession') {
                    let currentNVSessionId = this.selectedRowInfo[k]['nvSessionId'];
                    if (k == 0 && currentNVSessionId != '' && currentNVSessionId != '-')
                        nvSessionId = currentNVSessionId;
                    else if (currentNVSessionId != '' && currentNVSessionId != '-' && nvSessionId.indexOf(currentNVSessionId) == -1)
                        nvSessionId += "," + currentNVSessionId;
                }
            }
            if (filter == 'session') {
                if (ndSessionId != '-') {
                    this._ddrData.nvPageId = "";
                    this._ddrData.nvSessionId = "";
                    this.urlParam.nvPageId = "";
                    this.urlParam.nvSessionId = "";
                    this._ddrData.ndSessionId = ndSessionId;
                    this.urlParam.ndSessionId = ndSessionId;
                }
                else {
                    this.showNotification("error", "ND SessionId not available");
                    return;
                }
            }
            else if (filter == 'nvsession') {
                if (nvSessionId == '0') {
                    this.showNotification("error", "Invalid NV SessionId");
                    return;
                }
                else if (nvSessionId != '-') {
                    this._ddrData.ndSessionId = "";
                    this.urlParam.ndSessionId = "";
                    this._ddrData.nvPageId = "";
                    this._ddrData.nvSessionId = "";
                    this.urlParam.nvSessionId = nvSessionId;
                    this._ddrData.nvSessionId = nvSessionId;
                }
                else {
                    this.showNotification("error", "NV SessionId not available");
                    return;
                }
            }
            else if (filter == 'page') {
                if (nvPageId != '-') {
                    this._ddrData.ndSessionId = "";
                    this.urlParam.ndSessionId = "";
                    this._ddrData.nvPageId = nvPageId;
                    this._ddrData.nvSessionId = nvSessionId;
                    this.urlParam.nvPageId = nvPageId;
                    this.urlParam.nvSessionId = nvSessionId;
                }
                else {
                    this.showNotification("error", "NV PageId not available");
                    return;
                }
            }
            this.prevLimit = this.fpLimit;
            this.prevOffset = this.fpOffset;
            this.fpLimit = 50;
            this.fpOffset = 0;
            this._ddrData.nvFiltersFlag = true;
            this.nvtondReport = true;
            this.menuItems.push({ label: "View Previous Flowpaths", command: (event) => { this.clickBack(); } });
            this.loading = true;
            this.getFlowpathData();
            this.getFlowpathDataCount();
            this._ddrData.setInLogger('DDR::Flowpath', 'Filter', 'NvFilter Apply');
        }
    }
    clickBack() {
        this.nvtondReport = false;
        this._ddrData.nvFiltersFlag = false;
        this.urlParam.nvSessionId = '';
        this.urlParam.nvPageId = '';
        this.urlParam.ndSessionId = '';
        this.fpLimit = this.prevLimit;
        this.fpOffset = this.prevOffset;
        this.loading = true;
        this.getFlowpathData();
        this.getFlowpathDataCount();
    }
    openAggregateMethodTiming() {
        this.commonService.splitView = false;
        let flowpathInstance = "";
        let tierName = "";
        let serverName = "";
        let appName = "";
        let tierId = "";
        let serverId = "";
        let appId = "";
        if (this.selectedRowInfo.length == 0) {
            this.showNotification("error", "No Record Selected");
            return;
        }
        else {
            for (let i = 0; i < this.selectedRowInfo.length; i++) {
                flowpathInstance += this.selectedRowInfo[i]["flowpathInstance"] + ",";
                if (tierName.indexOf(this.selectedRowInfo[i]["tierName"]) == -1)
                    tierName += this.selectedRowInfo[i]["tierName"] + ",";
                if (serverName.indexOf(this.selectedRowInfo[i]["serverName"]) == -1)
                    serverName += this.selectedRowInfo[i]["serverName"] + ",";
                if (appName.indexOf(this.selectedRowInfo[i]["appName"]) == -1)
                    appName += this.selectedRowInfo[i]["appName"] + ",";
                if (tierId.indexOf(this.selectedRowInfo[i]["tierId"]) == -1)
                    tierId += this.selectedRowInfo[i]["tierId"] + ",";
                if (serverId.indexOf(this.selectedRowInfo[i]["serverId"]) == -1)
                    serverId += this.selectedRowInfo[i]["serverId"] + ",";
                if (appId.indexOf(this.selectedRowInfo[i]["appId"]) == -1)
                    appId += this.selectedRowInfo[i]["appId"] + ",";
            }
        }
        const reqData = {};
        reqData['tierName'] = tierName.substring(0, tierName.length - 1);
        reqData['serverName'] = serverName.substring(0, serverName.length - 1);
        reqData['appName'] = appName.substring(0, appName.length - 1);
        reqData['tierId'] = tierId.substring(0, tierId.length - 1);
        reqData['serverId'] = serverId.substring(0, serverId.length - 1);
        reqData['appId'] = appId.substring(0, appId.length - 1);
        reqData['flowpathInstance'] = flowpathInstance.substring(0, flowpathInstance.length - 1);
        if (this._ddrData.fpByBTFlag) {
            reqData['urlName'] = this.urlName;
        }
        reqData['strStartTime'] = this.strStartTime;
        reqData['strEndTime'] = this.strEndTime;
        this.commonService.openfptoAggMT = true;
        this.commonService.mtData = reqData;
        if (this.flowBack) {
            this._ddrData.isFromtrxFlow = false;
        }
        this._ddrData.setInLogger('DDR::Flowpath', 'Aggregate MethodTiming', 'Open AggregateMethodTiming Report');
        if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
            this._router.navigate(['/home/ddrCopyLink/methodtiming']);
        else
            this._router.navigate(['/ddr/methodtiming']);
    }
    fillSelection() {
        if ((this.urlParam.urlParam != undefined && this.urlParam.urlParam != "")
            && (this.urlParam.isFromNV != undefined && this.urlParam.isFromNV == "1")) {
            this.urlParam.urlParam = decodeURIComponent(this.urlParam.urlParam);
            let index = 0;
            if (this.flowpathData) {
                this.flowpathData.forEach((itemObj) => {
                    if (itemObj.urlQueryParamStr && itemObj.urlQueryParamStr.includes(this.urlParam.urlParam)) {
                        this.selectedRowInfo[index] = itemObj;
                        index++;
                    }
                });
            }
        }
        else if (this.commonService.selectedData !== undefined && this.commonService.selectedData !== null) {
            this.selectedRowInfo[0] = this.commonService.selectedData;
        }
    }
    compareFlowpaths() {
        if (this.selectedRowInfo.length !== 2) {
            this.showNotification(this.selectedRowInfo.length < 2 ? "warn" : "error", this.selectedRowInfo.length < 2 ? "Please select two flowpaths." : "Only two flowpaths can be compared.");
            return;
        }
        this._ddrData.setInLogger('DDR::Flowpath', 'Compare Flowpaths', 'Open compareFlowpaths Reports');
        this.commonService.openCurrentFlowpathTab = true;
        this.commonService.showAllTabs = false;
        this.commonService.mctData = {};
        this.commonService.openFlowpath = false;
        this.compareFPInfo = this.selectedRowInfo;
        this.commonService.mctFlag = false;
        this._ddrData.isCompFlowpath = true;
        this.commonService.compareFlowpathData = this.compareFPInfo;
        this._router.navigate(['/ddr/DdrCompareFlowpath']);
    }
    currentRowData(event) {
        this.order = '';
        this.currentRowData = event;
    }
    setPaginateData(offset, limit) {
        this.nvndData = [];
        if (this.urlParam.isFromNV == "1") {
            if (offset != 0) {
                if (this.commonService.rowspaerpage > 50) {
                    this.pageNo = Math.floor(offset / this.commonService.rowspaerpage) + 1;
                }
                else
                    this.pageNo = Math.floor(offset / 50) + 1;
            }
            else if (this._ddrData.nvFirstPage) {
                for (let j = 0; j < this.nvndCount.length; j++) {
                    this.nvndCount[j]['count'] = undefined;
                }
                this.pageNo = 1;
                this.nvPageIndex = {};
            }
            else
                this.pageNo = 1;
        }
        this.fpLimit = limit;
        this.fpOffset = offset;
        this.commonService.fpLimit = this.fpLimit;
        this.commonService.fpOffset = this.fpOffset;
        this.loading = true;
        this.commonService.isFilterFromSideBar = true;
        if (this._ddrData.cmdArgsFlag === true) {
            this.getFlowpthDataForFPAnalyzer();
        }
        else {
            this.getFlowpathData();
        }
    }
    openAutoInstDialog() {
        if (this.selectedRowInfo.length !== 1) {
            this.showNotification(this.selectedRowInfo.length === 0 ? "warn" : "error", this.selectedRowInfo.length === 0 ? "Please select at least one row" : "Select only one row");
            return;
        }
        else if (this.selectedRowInfo[0]['Instance_Type'].toLowerCase() != 'java' && this.selectedRowInfo[0]['Instance_Type'].toLowerCase() != 'dotnet') {
            this.showNotification('warn', 'Dynamic Diagnostics is not supported for ' + this.selectedRowInfo[0]['Instance_Type'] + ' agent');
            return;
        }
        else if (this.selectedRowInfo[0]['Instance_Type'].toLowerCase() != 'java' && this.selectedRowInfo[0]['Instance_Type'].toLowerCase() != 'dotnetc') {
            this.showNotification('warn', 'Dynamic Diagnostics is not supported for ' + this.selectedRowInfo[0]['Instance_Type'] + ' agent');
            return;
        }
        else {
            let testRunStatus;
            let instanceType;
            const payload = { testRun: this.urlParam.testRun };
            // let payload = this._ddrData.checkMultiDcMode({ testRun: this.urlParam.testRun, subject: { "tags": [{ "key": "Tier", "value": this.tierName, "mode": 1 }] } });
            this.ddrHttpService.getTRStatus(payload).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["TestRunStatusLoadedState"]) {
                    testRunStatus = state.data;
                    testRunStatus = testRunStatus.data;
                    if (testRunStatus.length != 0) {
                        if (this.selectedRowInfo[0]['Instance_Type'].toLowerCase() == 'java')
                            instanceType = 'Java';
                        else if (this.selectedRowInfo[0]['Instance_Type'].toLowerCase() == 'dotnet')
                            instanceType = 'DotNet';
                        else if (this.selectedRowInfo[0]['Instance_Type'].toLowerCase() == 'dotnetc')
                            instanceType = 'DotNetC';
                        this.argsForAIDDSetting = [this.selectedRowInfo[0]['appName'], this.selectedRowInfo[0]['appId'], instanceType,
                            this.selectedRowInfo[0]['tierName'], this.selectedRowInfo[0]['serverName'], this.selectedRowInfo[0]['serverId'], '-1',
                            this.selectedRowInfo[0]['urlName'], 'DDR', testRunStatus[0].status, this.urlParam.testRun];
                        this.showAutoInstrPopUp = true;
                    }
                    else {
                        this.showAutoInstrPopUp = false;
                        this.showNotification('error', 'Could not start instrumentation, test is not running');
                        return;
                    }
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
    }
    startInstrumentaion(result) {
        this.showAutoInstrPopUp = false;
        const severity = result.includes('Could not start') ? 'error' : 'success';
        this.showNotification(severity, result);
    }
    closeAIDDDialog(isCloseAIDDDialog) {
        this.showAutoInstrPopUp = isCloseAIDDDialog;
    }
    openReport(flag, nodeData, field) {
        this.breadcrumb.add({ label: nodeData.flowpathInstance });
        if (this.urlParam && this.urlParam.isFromNV && this.urlParam.isFromNV == "1"
            && (!this.urlParam.flowpathID || this.urlParam.flowpathID === "NA")
            && sessionStorage.getItem("isMultiDCMode") == "true") {
            for (let i = 0; i < this._ddrData.ndDCNameInfo.length; i++) {
                if (this._ddrData.ndDCNameInfo[i].displayName == nodeData.dcName) {
                    this._ddrData.dcName = nodeData.dcName;
                    this._ddrData.testRun = this._ddrData.ndDCNameInfo[i].ndeTestRun;
                    break;
                }
            }
        }
        this.commonService.mctFlag = true;
        this.commonService.dbFilters['fromDBCallByBT'] = 'false';
        this._ddrData.splitViewFlag = true;
        this.commonService.httpFlag = true;
        this.commonService.hsFlag = true;
        if (this.flowBack) {
            this._ddrData.isFromtrxFlow = false;
        }
        this.commonService.hsData = undefined;
        this._ddrData.dbFlag = true;
        this._ddrData.flowpathToExFlag = true;
        this.commonService.seqDiagToExceptionFlag = false;
        if (field == 'totalError') {
            nodeData['failedQuery'] = 1;
            this._ddrData.failedQuery = 1;
        }
        else {
            this._ddrData.failedQuery = 0;
        }
        this.commonService.isToLoadSideBar = false;
        sessionStorage.setItem("dbFlag", 'true');
        this.currentRowData = nodeData;
        this.columnName = field;
        if (field == 'callOutCount') {
            this.breadcrumb.add({ label: 'Transaction Flowmap' });
            this.commonService.isFromFpInstance = false;
            let columnFlowpathData = JSON.parse(JSON.stringify(nodeData));
            if (columnFlowpathData.fpDuration == '< 1')
                columnFlowpathData.fpDuration = 0;
            this.flowmapDataService.resetFlag();
            this.flowmapDataService.jsonData = [];
            this.sessionService.setSetting("fpRowdata", columnFlowpathData);
            this.nonExpandFlag.nonExpnadMode();
        }
        if (field == 'startTimeInMs') {
            this.breadcrumb.add({ label: 'Transaction Flowmap' });
            this.commonService.isFromFpInstance = true;
            let columnFlowpathData = JSON.parse(JSON.stringify(nodeData));
            if (columnFlowpathData.fpDuration == '< 1')
                columnFlowpathData.fpDuration = 0;
            this.flowmapDataService.resetFlag();
            this.sessionService.setSetting("fpRowdata", columnFlowpathData);
            this.nonExpandFlag.nonExpnadMode();
        }
        this.commonService.currentReport = '';
        this.commonService.isToLoadSideBar = false;
        this.commonService.column = this.columnName;
        this.commonService.flowpathData = this.flowpathData;
        this.commonService.index = this.index;
        this.commonService.currentRowData = this.currentRowData;
        this.commonService.order = this.order;
        this._router.navigate(['/ddr/DdrSplitview']);
    }
    openFpTypeError(rawData) {
        const payload = { flowpathtype: rawData.flowpathtype };
        this.ddrHttpService.getErroneousFpBitValue(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["ErroneousFlowpathLoadedState"]) {
                this.doAssignErrorBitValue(state.data.bitValue);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    doAssignErrorBitValue(res) {
        const errorMessages = {
            '4': " This request is redirected to error JSP page due to some internal error or exception.",
            '6': " JIT Compilation done for some methods in context of this transaction, may impact response time.",
            '7': " Test stopped but current transaction found active.",
            '9': " Flowpath Header is missing for current  request.",
            '10': " This is an Incomplete Flowpath.",
            '11': " Current Flowpath has abnormal method entry-exit timings.",
            '12': " Response time of transaction is more than configured threshold value of response time (Default 5 Min) so capturing of transaction is terminated by agent."
        };
        this.errormsgObj = res.split(',').map(val => ({ "errorbit": val, "errmsg": errorMessages[val] || "Unknown error" }));
        this.fptypeErrorFlag = true;
    }
    ngAfterViewInit() {
        sessionStorage.removeItem("DDRA9COPYLINK");
    }
    ngOnDestroy() {
        this.sideBarFlowpath.unsubscribe();
        this.unsubscribeAll();
        this.commonService.fpLimit = 0;
        if (this.flowBack) {
            this._ddrData.isFromtrxSideBar = false;
        }
        this.breadcrumb['items'].pop();
    }
    deletCachedData() {
        // let payload= this._ddrData.checkMultiDcMode({testRun:this.urlParam.testRun,REPORT_ID:this.selectedReport,subject: { "tags": [{ "key": "Tier", "value": this.tierName, "mode": 1 }] }})
        const payload = { testRun: this.urlParam.testRun, reportId: this.selectedReport };
        this.ddrHttpService.getDeleteCacheFile(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["DeleteCacheFileLoadedState"]) {
                this.doAssigndelete(state.data.status);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    openDeleteCache() {
        this.deleteCachedFlag = true;
        this.selectedReport = "";
    }
    onApply() {
        this.deletCachedData();
        this.deleteCachedFlag = false;
    }
    onselectAll() {
        this.selectedReport = this.reportList.map(item => item.value).join(',');
    }
    doAssigndelete(res) {
        if (res) {
            this.showNotification('success', 'Cached data deleted successfully');
        }
        else {
            this.showNotification('error', 'No data to delete from cache');
        }
    }
    showNotification(severity, detail) {
        this.messageService.add({ key: 'add-notification', severity, detail });
    }
    commonFpCode() {
        //code for copy flowpath link
        if (sessionStorage.getItem("DDRA9COPYLINK")) {
            this.urlParam = JSON.parse(sessionStorage.getItem('DDRA9COPYLINK')); // Retrieve queryParams from session storage
            sessionStorage.setItem('hostDcName', location.host);
            if (this.urlParam.enableQueryCaching) {
                this.commonService.enableQueryCaching = this.urlParam.enableQueryCaching;
            }
            if (this.urlParam.FileName) {
                this._ddrData.cmdArgsFlag = true;
            }
            if (this.urlParam.product)
                this.urlParam.product = this.urlParam.product.replace("/", "");
            if (this.urlParam.sesLoginName)
                sessionStorage.setItem('sesLoginName', this.urlParam.sesLoginName);
            sessionStorage.setItem('port', location.port);
            sessionStorage.setItem('timeZoneId', this.urlParam.timeZoneId);
            // Remove items from storage
            this.commonService.removeFromStorage();
            sessionStorage.setItem("resTimeFlagforCustomData", this.urlParam.resTimeFlagforCustomData);
            sessionStorage.setItem("mode", this.urlParam.mode);
            // Set parameters into common service
            this.commonService.setParameterIntoStorage = this.urlParam;
            this.commonService.strGraphKey = this.urlParam.strGraphKey;
            this.commonService.dcNameList = this.urlParam.dcNameList;
            this.commonService.isAllCase = this.urlParam.isAll;
            this.commonService.tierNameList = this.urlParam.tierNameList;
            this.commonService.selectedDC = this.urlParam.dcName;
            this.selectedDC = this.urlParam.dcName;
            this.commonService.ajaxTimeOut = this.urlParam.ajaxTimeout;
            if (this.urlParam.isIntegratedFlowpath == 'true') {
                this.commonService.isIntegratedFlowpath = true;
            }
        }
        if (this.urlParam.FileName) {
            this._ddrData.cmdArgsFlag = true;
        }
        if (this.urlParam.threadId)
            this.threadId = this.urlParam.threadId;
        if (this.urlParam.flowpathEndTime)
            this.flowpathEndTime = this.urlParam.flowpathEndTime;
        if (this.urlParam.paginationFlag === "false")
            this.paginationFlag = false;
        this.commonService.removeFromStorage();
        this.commonService.setInStorage = this.urlParam;
        this.trStartTime = this.urlParam.startTime;
        this.trEndTime = this.urlParam.endTime;
        this.breadcrumb.add({ label: 'Flowpath', routerLink: '/ddr/flowpath' });
        this.randomNumber();
        //Flowpath from Sidebar
        this.sideBarFlowpath = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Flowpath") {
                this.commonService.isFilterFromSideBar = true;
                this.loading = true;
                [this.fpLimit, this.fpOffset] = this.setFpLimitOffset(this.commonService.fpLimit, this.commonService.fpOffset, true);
                this.getFlowpathData();
                if (!(this.urlParam && this.urlParam.isFromNV && this.urlParam.isFromNV == "1" && (this.urlParam.flowpathID || this.urlParam.flowpathID === "NA")
                    && this.sessionService.preSession.multiDc === true))
                    this.getFlowpathDataCount();
            }
        });
        this.fillData();
        this.fillSelection(); //Method to select the rows based on the urlParam (NV-ND)
        this.commonService.openFlowpath = true;
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        // const payload = this._ddrData.checkMultiDcMode({testRun:this.urlParam.testRun,queryId:this.queryId,subject: { "tags": [{ "key": "Tier", "value": this.tierName, "mode": 1 }] }});
        const payload = { testRun: this.urlParam.testRun, queryId: this.queryId };
        this.isCancelQuery = false;
        this.unsubscribeAll();
        this.loading = false;
        this.isCancelQuerydata = true;
        this.ddrHttpService.getCancelQueryResult(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["CancelQueryLoadedState"]) {
                return (state.data.status);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    getNVtoNDForAll(param) {
        return new Promise((resolve, reject) => {
            try {
                console.log("getNVtoNDForALLLL");
                let exCount = 0;
                let countRest = 0;
                let url = "";
                this._ddrData.getDcNameInfoFromRest().then(() => {
                    this.ndeInfoData = this._ddrData.ndDCNameInfo;
                    if (this.urlParam.nvIndex && this.urlParam.nvIndex != "undefined")
                        this.nvIndex = Number(this.urlParam.nvIndex);
                    if (this.nvArr[this.nvIndex] && this.nvArr.length > 0)
                        url += this.nvArr[this.nvIndex] + "&nvIndex=" + this.nvIndex + "&isFromNV=" + this.urlParam.isFromNV;
                    else
                        url += "&isFromNV=" + this.urlParam.isFromNV;
                    try {
                        this.ndeInfoData.forEach((val, index) => {
                            const pagination = (this.pageNo > 1 && this.nvPageIndex[val.displayName] && this.nvPageIndex[val.displayName][this.pageNo] && this.nvPageIndex[val.displayName][this.pageNo]['limit'] && this.nvPageIndex[val.displayName][this.pageNo]['offset'])
                                ? `&limit=${this.nvPageIndex[val.displayName][this.pageNo]['limit']}&offset=${this.nvPageIndex[val.displayName][this.pageNo]['offset']}`
                                : `&limit=${this.fpLimit}&offset=${this.fpOffset}`;
                            const queryParams = 'testRun=' + val.ndeTestRun + param + url;
                            const dataQueryParam = queryParams + '&showCount=false&shellForNDFilters=' + this.shellForNDFilters + pagination;
                            const countQueryParam = queryParams + '&showCount=true&shellForNDFilters=' + this.shellForNDFilters + pagination;
                            if (this.pageNo == 1 && Object.keys(this.nvPageIndex).length == 0 && !this._ddrData.nvFirstPage) {
                                const nvTondCountUrl = this.ddrHttpService.getFlowpathReportData(countQueryParam).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_4__["timeout"])(this.commonService.ajaxTimeOut)).subscribe((state) => {
                                    if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["FlowpathReportLoadedState"]) {
                                        countRest++;
                                        this.HandleNVNDMultiDCFirstPageCount(state.data, val.displayName, countRest);
                                    }
                                }, (error) => {
                                    countRest++;
                                    this.HandleNVNDMultiDCFirstPageCount(undefined, val.displayName, countRest);
                                    if (index == this.ndeInfoData.length) {
                                        this.loading = false;
                                    }
                                    if (countRest == this.ndeInfoData.length && !this.nvCountFlag) {
                                        const totalCount = this.nvndCount.reduce((total, item) => total + Number(item.totalCount), 0);
                                        this.assignFlowpathDataCount({ totalCount });
                                    }
                                    console.error('Error loading:', error);
                                });
                                this.subscriptions.push(nvTondCountUrl);
                            }
                            setTimeout(() => {
                                this.openpopup();
                            }, this._ddrData.guiCancelationTimeOut);
                            // let payload= this._ddrData.updatePayload(dataQueryParam);
                            const nvTondDataUrl = this.ddrHttpService.getFlowpathReportData(dataQueryParam).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_4__["timeout"])(this.commonService.ajaxTimeOut)).subscribe((state) => {
                                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["FlowpathReportLoadedState"]) {
                                    this.HandleNVNDMultiDCFirstPageData(state.data, val.displayName);
                                    exCount++;
                                    if ((exCount == this.ndeInfoData.length) && (this.nvndData.length > 0 || this.nvIndex == 2)) {
                                        console.log("Done Successfully from here ");
                                        resolve(state.data);
                                    }
                                    else if ((exCount == this.ndeInfoData.length) && this.nvndData.length == 0 && this.nvIndex != 2) {
                                        this.nvIndex += 1;
                                        this.getNVtoNDForAll(param).then(() => { resolve(this.nvIndex); });
                                    }
                                }
                            }, (error) => {
                                exCount++;
                                if (index == this.ndeInfoData.length) {
                                    this.loading = false;
                                }
                                if ((exCount == this.ndeInfoData.length) && (this.nvndData.length > 0 || this.nvIndex == 2)) {
                                    console.log("Done Successfully from here error");
                                    resolve("Done Successfully from here error");
                                }
                                else if ((exCount == this.ndeInfoData.length) && this.nvndData.length == 0 && this.nvIndex != 2) {
                                    this.nvIndex += 1;
                                    this.getNVtoNDForAll(param).then(() => { resolve(this.nvIndex); });
                                }
                            });
                            this.subscriptions.push(nvTondDataUrl);
                        });
                    }
                    catch (error) {
                        console.error('error in getting data from rest call', error);
                    }
                });
            }
            catch (error) {
                console.error('error in getting data from rest call', error);
            }
        });
    }
    HandleNVNDMultiDCFirstPageCount(res, dcName, countRest) {
        try {
            this.checkIntervalFlag = countRest;
            if (res && Number(res.totalCount) > 0) {
                this.nvndCount.push({ "dcName": dcName, "totalCount": res.totalCount });
            }
            if (countRest == this.ndeInfoData.length && !this.nvCountFlag) {
                const totalCount = this.nvndCount.reduce((total, item) => total + Number(item.totalCount), 0);
                this.assignFlowpathDataCount({ totalCount });
            }
        }
        catch (error) {
            console.error('Getting error in handling NV-ND ~ ', error);
        }
    }
    HandleNVNDMultiDCFirstPageData(res, dcName) {
        try {
            this.selectedDC = "ALL";
            if (res && res.data && res.data.length > 0) {
                for (let i = 0; i < res.data.length; i++) {
                    res.data[i]["dcName"] = dcName;
                }
                this.nvndData.push({ 'dcName': dcName, 'data': res.data, 'strStartTime': res.strStartTime, 'strEndTime': res.strEndTime });
                if (this.nvIndex == 0) {
                    this.nvFilter = "Data Filter=NDSessionID, NVSessionID, NVPageID";
                }
                else if (this.nvIndex == 1) {
                    this.nvFilter = "Data Filter=NDSessionID, NVSessionID";
                }
                else {
                    this.nvFilter = "Data Filter=NDSessionID";
                }
            }
            else {
                console.log("HandleNVNDMultiDCFirst Page Data ~ Not getting data ~ ", res);
            }
        }
        catch (error) {
            console.error("Error in handling NV-ND", error);
        }
    }
    callFlowPathFromNVNForAllDC() {
        try {
            clearInterval(this.processingInterval);
            console.log("Start callFlowPathFromNVNForAllDC");
            const res = {};
            res['data'] = [];
            let totalCount = 0;
            if (this.nvndData.length > 0) {
                res['data'] = this.nvndData[0]['data'];
                if (this.pageNo == 1 && Object.keys(this.nvPageIndex).length === 0) {
                    totalCount = res['data'].length;
                    this.nvCountFlag = true;
                }
                res['strStartTime'] = this.nvndData[0].strStartTime;
                res['strEndTime'] = this.nvndData[0].strEndTime;
            }
            this.assignFlowpathData(res);
            if (this.pageNo == 1 && Object.keys(this.nvPageIndex).length === 0 && this.nvCountFlag) {
                this.assignFlowpathDataCount({ totalCount });
            }
        }
        catch (error) {
            console.error("error in callFlowPathFromNVNForAllDC ~ ", error);
        }
    }
    unsubscribeAll() {
        this.subscriptions.forEach((subscription) => { subscription.unsubscribe(); });
    }
    copyLink() {
        navigator.clipboard.writeText(this.copyFlowpathLink)
            .then(() => { this.showNotification('success', 'FlowPath Link has been copied successfully.'); })
            .catch((err) => {
            this.showNotification('error', 'Unable to copy the FlowPath Link. Please try again.');
            console.error('Unable to copy text to clipboard', err);
        });
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d;
        const me = this;
        this._ddrData.selectedFPRowData = {};
        switch ((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) {
            case "clickable":
                me.openReport(true, event.cavEventExt.row, event.cavEventExt.columnClicked.key);
                break;
            case "menu-items":
                me.selectedRowInfo = event.cavEventExt.rowData;
                this.menuRef.toggle(event); //toggle menu-list
                break;
            case 'onChangeColumnCheckbox':
                const rowSelected = (_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.ngModel;
                me.selectedRowInfo = [...rowSelected];
                break;
            case 'toggleHelp':
                me.help.show('flowpathReport', 'Flowpath Report', 'ns-ddr');
                break;
            case 'traceViewer':
                this._ddrData.selectedFPRowData = event.cavEventExt.row;
                me._router.navigate(['/ddr/trace-viewer']);
                break;
            case 'traceFlamegraph':
                this._ddrData.selectedFPRowData = event.cavEventExt.row;
                me._router.navigate(['/ddr/trace-flamegraph']);
                break;
            default:
                break;
        }
    }
    loadFlowPathPagination(event) {
        this.loading = true;
        this.setPaginateData(event.first, event.rows);
    }
    /**
     * Reusable method to set fpLimit and fpOffset
     * @param fpLimit
     * @param fpOffset
     * @param fpCheck
     * @returns fpLimit and fpOffset value from commonservice
     */
    setFpLimitOffset(fpLimit = 50, fpOffset = 0, fpCheck) {
        if (fpCheck && this.commonService.fpLimit < 50) {
            this.commonService.fpLimit = 50;
        }
        this.commonService.fpLimit = fpLimit;
        this.commonService.fpOffset = fpOffset;
        return [this.commonService.fpLimit, this.commonService.fpOffset];
    }
    addFlagDetails(data) {
        data.forEach(obj => {
            let traceRequest = parseInt(obj.traceRequest, 10);
            let flags = [];
            if (traceRequest & 1) {
                flags.push({
                    "iconCls": "cav http-data",
                    "tooltip": "Trace Request"
                });
            }
            if (traceRequest & 2) {
                flags.push({
                    "iconCls": "cav4 dl",
                    "tooltip": "Dynamic Logging"
                });
            }
            if (traceRequest & 4) {
                flags.push({
                    "iconCls": "cav nethavok",
                    "tooltip": "Havoc",
                });
            }
            obj.flagDetails = flags.length > 0 ? (flags.length === 1 ? flags[0] : flags) : [];
        });
        return data;
    }
};
FlowpathComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_9__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] },
    { type: _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_14__["DdrTxnFlowmapDataService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_3__["MessageService"] },
    { type: src_app_pages_dashboard_service_req_transaction_flowmap_service_trx_flowmap_service__WEBPACK_IMPORTED_MODULE_7__["TrxFlowmapService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["NdDdrHttpService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_10__["ElasticsearchQueryService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_6__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["BreadcrumbService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('menuRef')
], FlowpathComponent.prototype, "menuRef", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('help')
], FlowpathComponent.prototype, "help", void 0);
FlowpathComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-flowpath',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./flowpath.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/flowpath/flowpath.component.html")).default,
        providers: [primeng__WEBPACK_IMPORTED_MODULE_3__["MessageService"]],
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./flowpath.component.css */ "./src/app/pages/ddr/components/flowpath/flowpath.component.css")).default]
    })
], FlowpathComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.scss":
/*!*******************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.scss ***!
  \*******************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-fp-to-db-component .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-fp-to-db-component .group-left {\n  float: left;\n  padding-top: 4px;\n}\napp-fp-to-db-component .group-right {\n  float: right;\n  padding-top: 4px;\n}\napp-fp-to-db-component .highcharts-legend-item.highcharts-pie-series text {\n  font-size: 10px !important;\n}\napp-fp-to-db-component .firstColWidth col:first-child {\n  width: 35px !important;\n}\napp-fp-to-db-component .scrollArea {\n  line-height: 24px;\n  border-style: solid;\n  border-width: 1px;\n  padding: 6px;\n  margin: 6px 0px;\n  max-height: 140px;\n  overflow: auto;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.ts":
/*!*****************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.ts ***!
  \*****************************************************************************************/
/*! exports provided: FpToDbComponentComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FpToDbComponentComponent", function() { return FpToDbComponentComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/pages/tools/admin/access-control-management/constants/cav-acl-features.constants */ "./src/app/pages/tools/admin/access-control-management/constants/cav-acl-features.constants.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");













let FpToDbComponentComponent = class FpToDbComponentComponent {
    constructor(commonService, _ddrData, ddrRequest, breadcrumb, sessionService, ndDdrHttpService, elasticSearchService) {
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.elasticSearchService = elasticSearchService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_2__;
        this.queryDetail = [{
                "tiername": "", "tierid": "", "servername": "", "serverid": "", "appname": "", "appid": "", "urlName": "", "count": "", "min": "", "max": "", "cumsqlexectime": "", "mincumsqlexectime": "", "maxcumsqlexectime": "", "avg": "", "failedcount": "", "sqlindex": "", "sqlQuery": "", "urlIndex": "", "id": 0, "sqlbegintimestamp": "", "sqlendtimestamp": "", "sqlquery": ""
            }];
        this.cols = [];
        this.loading = false;
        this.limit = 50;
        this.offset = 0;
        this.showChart = false;
        this.topNQueries = 0;
        this.showAllOption = false;
        this.showDownloadOption = false;
        this.pieChartMessage = "No Pie Chart found based on current Filter Settings.";
        this.rowData = {};
        this.clientConnectionKey = null;
        this.selectedRowInfo = [];
        this.hostIndex = 2;
        this.showPagination = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.empty = true;
        this.temDataLength = 0;
        this.dbHideData = true;
        this.headerRelativePath2 = "ddr/fp-to-db-report/fp-to-db-report3.json";
        this.showTable = false;
        this.showHideChart = true;
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.breadcrumb = breadcrumb;
        this.otelMode = this._ddrData.otelMode;
    }
    ngOnChanges() {
        if (this._ddrData.splitViewBreadCrumbFlag && this._ddrData.splitViewFlag) {
            this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            this.breadcrumb.add({ label: 'DB Queries' });
        }
        else {
            this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            this.breadcrumb.add({ label: 'DB Queries' });
            this._ddrData.splitViewBreadCrumbFlag = true;
        }
        if (this._ddrData.splitViewFlag)
            this._ddrData.setInLogger("DDR::Flowpath", "DB Query", "Open DB Query Report");
        // columnData is FpRow data...
        if (this.columnData != undefined) {
            this.loading = true;
            this.id = JSON.parse(JSON.stringify(this.columnData));
            this.commonService.setFPData = JSON.parse(JSON.stringify(this.columnData));
        }
        this.limit = 50;
        this.offset = 0;
        this.first.first = 0;
        this.rows.rows = 50;
        this.randomNumber();
        this.getData();
        this.setReportHeader();
        this.showDbParam = false;
    }
    ngOnInit() {
        var _a;
        if (this.commonService.seqDiagToDBFlag == true) {
            this.headerRelativePath = "ddr/fp-to-db-report/fp-to-db-report1.json";
        }
        else {
            this.headerRelativePath = "ddr/fp-to-db-report/fp-to-db-report2.json";
        }
        if (this.otelMode) {
            this.headerRelativePath = "ddr/fp-to-db-report/fp-to-db-report-elastic.json";
        }
        this.loading = true;
        this.commonService.isToLoadSideBar = false;
        if (this._ddrData.splitViewFlag == false) {
            this.breadcrumb.add({ label: 'DB Queries', routerLink: '/ddr/flowpathToDB' });
            this.screenHeight = Number(this.commonService.screenHeight) - 97;
        }
        else
            this.screenHeight = Number(this.commonService.screenHeight) - 157;
        if (this.commonService.seqDiagToDBFlag == true)
            this.id = this.commonService.seqDiagToDBData;
        else {
            this.id = this.commonService.getFPData;
            if (this.id.testRun == undefined || this.id.product == undefined) {
                this.id.testRun = this.commonService.testRun;
                this.id.product = (_a = this.commonService.productName) !== null && _a !== void 0 ? _a : this.sessionService.session.cctx.prodType.toLowerCase().replace("/", "");
            }
        }
        if (this._ddrData.splitViewFlag == false) {
            this.getData();
            this.setReportHeader();
        }
        this.first.first = 0;
        this.rows.rows = 50;
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "onRowSelect") {
            me.showRowInfo((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        }
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.actionConfig) === null || _e === void 0 ? void 0 : _e.action) === "showalldata") {
            me.showAllData();
        }
        if (((_g = (_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.actionConfig) === null || _g === void 0 ? void 0 : _g.action) === "showhidechart") {
            me.showHideChart = !me.showHideChart;
        }
    }
    setReportHeader() {
        if (decodeURIComponent(this.id.ipWithProd).indexOf("netstorm") != -1)
            this.strTitle = "Netstorm - DB Queries Report - Test Run : " + this.id.testRun;
        else
            this.strTitle = "Netdiagnostics Enterprise - DB Queries Report - Session : " + this.id.testRun;
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName;
        if (this._ddrData.isFromtrxFlow) {
            hostDcName = "//" + this._ddrData.hostTr + ":" + this._ddrData.portTr;
            this.id.testRun = this._ddrData.testRunTr;
        }
        else if (this.sessionService.preSession.multiDc === true) {
            this.id.testRun = this._ddrData.testRun;
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            if (hostDcName.lastIndexOf('ALL/') !== -1)
                hostDcName = hostDcName.substring(0, hostDcName.lastIndexOf('/'));
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        return hostDcName;
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    getData() {
        let finalQueryParams;
        let paginationParams = '&limit=' + this.limit + '&offset=' + this.offset;
        this.url = '';
        if (!this.otelMode) {
            if (this.id.fpDuration) {
                if (this.id.fpDuration.toString() == '< 1')
                    this.endTimeInMs = (Number(this.id.startTimeInMs) + Number(0)).toString();
                else if (this.id.fpDuration.toString().includes(','))
                    this.endTimeInMs = (Number(this.id.startTimeInMs) + Number(this.id.fpDuration.toString().replace(/,/g, ""))).toString();
                else
                    this.endTimeInMs = (Number(this.id.startTimeInMs) + Number(this.id.fpDuration)).toString();
            }
        }
        else {
            this.endTimeInMs = this.id.startTimeInMs + Math.ceil(this.id.selfResponseTime);
        }
        if (this.commonService.enableQueryCaching == 1) {
            this.url += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&object=6" + "&tierId=" + this.id.tierId +
                "&serverId=" + this.id.serverId + "&appId=" + this.id.appId + "&flowpathInstance=" + this.id.flowpathInstance + "&statusCode=-2" +
                "&strStartTime=" + this.id.startTimeInMs + "&strEndTime=" + (Number(this.endTimeInMs) + 1000) + '&sqlIndex=' + this.id.sqlIndex + '&tierName=' + this.id.tierName;
        }
        else {
            this.url += "testRun=" + this.id.testRun + "&object=6" + "&tierId=" + this.id.tierId +
                "&serverId=" + this.id.serverId + "&appId=" + this.id.appId + "&flowpathInstance=" + this.id.flowpathInstance + "&statusCode=-2" +
                "&strStartTime=" + this.id.startTimeInMs + "&strEndTime=" + (Number(this.endTimeInMs) + 1000) + '&sqlIndex=' + this.id.sqlIndex + '&tierName=' + this.id.tierName;
        }
        this.url += '&queryId=' + this.queryId;
        finalQueryParams = this.url + paginationParams + "&showCount=false";
        if (this.otelMode) {
            finalQueryParams += `&traceId=${this.id.TraceId}&serviceName=${this.id.serviceName}`;
        }
        this.isCancelQuerydata = false;
        //commenting for now TBD: Query Cancellation
        // setTimeout(() => {
        //   this.openpopup();
        // }, this._ddrData.guiCancelationTimeOut);
        if (!this.otelMode) {
            this.fetchDataFromPsql(finalQueryParams);
        }
        else {
            this.fetchDataFromElasticSearch(finalQueryParams);
        }
    }
    /**
       * Fetches data from psql using the specified query parameters.
       *
       * @param finalQueryParams The query parameters has the final query parameters which is converted to post call body to get data
       */
    fetchDataFromPsql(finalQueryParams) {
        this.ndDdrHttpService.getdbRequestExReportData(finalQueryParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["dbRequestExLoadedState"]) {
                this.doAssignValue(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.commonService.showError(error);
        });
    }
    /**
       * Fetches data from Elasticsearch using the specified query parameters.
       *
       * @param finalQueryParams The query parameters to use when constructing the query.
       */
    fetchDataFromElasticSearch(finalQueryParams) {
        const reqPayload = this.ndDdrHttpService.createPayloadForPOSTCall(finalQueryParams);
        if (window['logLevel'] > 1) {
            console.log("********reqPayload******", reqPayload);
        }
        const resFields = [
            "trace_id",
            "span_id",
            "@timestamp",
            "duration",
            "attributes.cav.*",
            "attributes.db.*"
        ];
        const elasticQuery = this.elasticSearchService.buildElasticSearchQuery(reqPayload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_12__["BREADCRUMB_ITEMS"].DB_QUERIES);
        if (window['logLevel'] > 1) {
            console.log('Elasticsearch Query for FP-to-DB:', elasticQuery);
        }
        this.elasticSearchService.search(elasticQuery).subscribe(res => {
            this.elasticSearchData = res;
            if (window['logLevel'] > 1) {
                console.log('FP-to-DB ES response:', res);
            }
            this.processElasticData(this.elasticSearchData);
        }, err => {
            console.error('Error in fetching data for FP-to-DB from Elasticsearch query:', err);
            this.queryInfo = [];
            this.totalCount = 0;
            this.loading = false;
        });
    }
    /**
    * Processes the data returned from Elasticsearch
    * and assigns it to the required variables for UI rendering.
    *
    * @param elasticData The response from Elasticsearch
    */
    processElasticData(elasticData) {
        var _a, _b, _c, _d, _e;
        this.queryInfo = [];
        this.totalCount = 0;
        this.fullQueryName = '';
        // Check for valid aggregation structure
        if (((_b = (_a = elasticData === null || elasticData === void 0 ? void 0 : elasticData.hits) === null || _a === void 0 ? void 0 : _a.total) === null || _b === void 0 ? void 0 : _b.value) && ((_e = (_d = (_c = elasticData === null || elasticData === void 0 ? void 0 : elasticData.aggregations) === null || _c === void 0 ? void 0 : _c.statements) === null || _d === void 0 ? void 0 : _d.buckets) === null || _e === void 0 ? void 0 : _e.length)) {
            this.elasticDBData = elasticData.aggregations.statements.buckets;
            this.totalElasticRecords = Number(elasticData.hits.total.value);
            // Transform data as per fp-to-db-report2.json config
            this.DbReportDataArray = this.elasticDBData.map((record) => {
                var _a, _b, _c;
                const durationStats = record.duration_stats;
                // Duration conversions
                const avgInMs = Number(durationStats === null || durationStats === void 0 ? void 0 : durationStats.avg) / 1000000;
                const minInMs = Number(durationStats === null || durationStats === void 0 ? void 0 : durationStats.min) / 1000000;
                const maxInMs = Number(durationStats === null || durationStats === void 0 ? void 0 : durationStats.max) / 1000000;
                const sumInMs = Number(durationStats === null || durationStats === void 0 ? void 0 : durationStats.sum) / 1000000;
                return {
                    sqlquery: record.key,
                    tiername: (_a = this.id.tierName) !== null && _a !== void 0 ? _a : '',
                    servername: (_b = this.id.serverName) !== null && _b !== void 0 ? _b : '',
                    appname: (_c = this.id.appName) !== null && _c !== void 0 ? _c : '',
                    count: record.doc_count,
                    mincumsqlexectime: isNaN(minInMs) ? "" : minInMs,
                    maxcumsqlexectime: isNaN(maxInMs) ? "" : maxInMs,
                    avg: isNaN(avgInMs) ? "" : avgInMs,
                    cumsqlexectime: isNaN(sumInMs) ? "" : sumInMs,
                };
            });
            // Assign transformed data
            this.queryInfo = this.DbReportDataArray;
            this.totalCount = this.totalElasticRecords;
            this.filterInfo = this.elasticSearchService.filtercriteria;
            // For pie chart & UI summary
            if (this.queryInfo.length > 0) {
                this.showTable = true;
                this.fullQueryName = this.queryInfo[0]['sqlquery'];
            }
            else {
                this.fullQueryName = 'No Query is present.';
            }
            this.loading = false;
        }
        else {
            // No data fallback
            this.queryInfo = [];
            this.totalCount = 0;
            this.fullQueryName = 'No Query is present.';
            this.loading = false;
        }
        // Render the pie chart
        this.createPieChart(this.queryInfo);
    }
    doAssignValue(res) {
        this.isCancelQuerydata = true;
        this.loading = false;
        if (res.hasOwnProperty('Status')) {
            this.commonService.showError(res.Status);
        }
        this.queryDetail = res.data;
        if (this.queryDetail.length == 0) {
            this.fullQueryName = 'No Query is present';
            this.showDownloadOption = false;
            this.empty = true;
            this.queryInfo = [];
            this.dbParamInfo = [];
        }
        else {
            this.showDownloadOption = true;
            this.queryInfo = this.getQueryInfo();
            this.showRowInfo(res.data[0]);
        }
        this.getDataCount();
        this.first = { first: this.offset };
        this.rows = { rows: this.limit };
        this.createPieChart(res);
        let startTimeInFormat = this.sessionService.convertTimestampIntoFormattedString(Number(res.startTime), "MM/DD/YYYY HH:mm:ss");
        let endTimeInFormat = this.sessionService.convertTimestampIntoFormattedString(Number(res.endTime), "MM/DD/YYYY HH:mm:ss");
        this.createFilterCriteria(startTimeInFormat, endTimeInFormat);
    }
    getDataCount() {
        this.url += '&showCount=true';
        this.ndDdrHttpService.getdbRequestExReportCount(this.url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["dbRequestExCountLoadedState"]) {
                this.doAssignCountValue(state.data);
            }
        });
    }
    doAssignCountValue(res) {
        this.totalCount = res.totalCount;
        if (this.totalCount > 50) { //If data is less then 50 then no pagination .
            this.showPagination = true;
        }
        else {
            this.showPagination = false;
        }
        if (this.limit > Number(this.totalCount))
            this.limit = Number(this.totalCount);
    }
    loadFpToDbPagination(event) {
        this.loading = true;
        this.offset = event.first;
        this.limit = event.rows;
        if (this.limit > this.totalCount) {
            this.limit = Number(this.totalCount);
        }
        if ((this.limit + this.offset) > this.totalCount) {
            this.limit = Number(this.totalCount) - Number(this.offset);
        }
        this.getData();
    }
    getRowInfo(event) {
        this.rowData = event.data;
    }
    createFilterCriteria(startTime, endTime) {
        this.filterInfo = '';
        if (this.validateField(this.id.tierName))
            this.filterInfo += " Tier= " + this.id.tierName;
        if (this.validateField(this.id.serverName))
            this.filterInfo += ", Server= " + this.id.serverName;
        if (this.validateField(this.id.appName))
            this.filterInfo += ", Instance= " + this.id.appName;
        if (this.validateField(startTime))
            this.filterInfo += ", From= " + startTime;
        if (this.validateField(endTime))
            this.filterInfo += ", To= " + endTime;
        if (this.validateField(this.id.urlName))
            this.filterInfo += ", BT= " + decodeURIComponent(this.id.urlName);
        if (this.validateField(this.id.btCatagory))
            this.filterInfo += ", BT Type= " + this.getBTCategory(this.id.btCatagory);
        if (this.filterInfo && this.filterInfo.startsWith(','))
            this.filterInfo = this.filterInfo.substring(1);
    }
    getBTCategory(category) {
        if (category === '12') {
            category = 'Very Slow';
        }
        if (category === '11') {
            category = 'Slow';
        }
        if (category === '10') {
            category = 'Normal';
        }
        if (category === '13') {
            category = 'Errors';
        }
        if (category === '0') {
            category = 'Other';
        }
        return category;
    }
    validateField(param) {
        if (param == null || param == 'NA' || param == '' || param == 'undefined' || param == undefined || param == '-')
            return false;
        else
            return true;
    }
    createPieChart(res) {
        this.pieChartMessage = "No Pie Chart found based on current Filter Settings.";
        if (res.isAvgTotalZero) {
            this.pieChartMessage = "No Pie chart is found as Avg Response Time of query is zero";
            this.showChart = false;
            return;
        }
        if (this.topNQueries == 0)
            this.topNQueries = 5;
        if (!this.otelMode)
            this.chartData = res.data;
        else
            this.chartData = res;
        this.wholeData = this.chartData;
        let dataArr = [];
        let restDataArr = [];
        let queryName;
        let totalResTime = 0;
        let pieText;
        if (this.chartData.length != 0) {
            this.showChart = true;
            for (let i = 0; i < this.chartData.length; i++) {
                if (i < this.topNQueries) {
                    pieText = 'Top ' + this.topNQueries + ' DB Queries By Response Time';
                    queryName = this.chartData[i]['sqlquery'];
                    dataArr.push({ 'name': queryName, 'y': Number(this.chartData[i]['avg']) });
                }
                else
                    restDataArr.push(this.chartData[i]);
            }
            this.restDataArrOfPie = restDataArr;
            if (this.chartData.length > this.topNQueries) {
                queryName = 'Other';
                for (let j = 0; j < restDataArr.length; j++) {
                    totalResTime += Number(restDataArr[j]['avg']);
                }
                dataArr.push({ 'name': queryName, 'y': Number(totalResTime.toFixed(3)) });
            }
            this.options = {
                chart: {
                    type: "pie",
                    width: 330,
                    height: 350
                },
                credits: {
                    enabled: false
                },
                title: {
                    text: pieText,
                    style: { 'fontSize': '12px' }
                },
                legend: {
                    itemWidth: 330
                },
                tooltip: {
                    style: { fontSize: '11px', width: '250px' },
                    formatter: function () {
                        let tooltip = "";
                        let pointName = this.point.name;
                        if (pointName.length > 60)
                            tooltip += pointName.substring(0, 60) + "...";
                        else
                            tooltip += pointName;
                        tooltip += " Percentage: " + "<b>" + this.point.percentage.toFixed(2) + "%" + "</b>" + ", Response Time: " + "<b>" + this.point.y + "</b>";
                        return tooltip;
                    }
                },
                plotOptions: {
                    pie: {
                        allowPointSelect: true,
                        cursor: 'pointer',
                        dataLabels: {
                            enabled: false
                        },
                        showInLegend: true
                    }
                },
                exporting: {
                    enabled: false
                },
                series: [
                    {
                        name: "Percentage",
                        data: dataArr,
                        enableMouseTracking: true
                    }
                ]
            };
        }
        else
            this.showChart = false;
    }
    getQueryInfo() {
        let dataArr = [];
        for (let i = 0; i < this.queryDetail.length; i++) {
            if (this.queryDetail[i]['sqlQuery'] != undefined)
                this.queryDetail[i]['sqlQuery'] = this.queryDetail[i]['sqlQuery'].replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
            else
                this.queryDetail[i]['sqlquery'] = this.queryDetail[i]['sqlquery'].replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
            if (i == 0) {
                this.fullQueryName = this.queryDetail[i]['sqlQuery'] || this.queryDetail[i]['sqlquery'];
            }
            dataArr[i] = {
                tiername: this.queryDetail[i]["tiername"], tierid: this.queryDetail[i]["tierid"], servername: this.queryDetail[i]["servername"],
                serverid: this.queryDetail[i]["serverid"], appname: this.queryDetail[i]["appname"], appid: this.queryDetail[i]["appid"],
                count: this.queryDetail[i]["count"], min: this.queryDetail[i]["min"], max: this.queryDetail[i]["max"], avg: this.queryDetail[i]["avg"],
                failedcount: this.queryDetail[i]["failedcount"], sqlQuery: this.queryDetail[i]["sqlQuery"], sqlindex: this.queryDetail[i]["sqlindex"], sqlIndex: this.queryDetail[i]["sqlIndex"],
                mincumsqlexectime: this.queryDetail[i]["mincumsqlexectime"], maxcumsqlexectime: this.queryDetail[i]["maxcumsqlexectime"],
                urlName: this.queryDetail[i]["urlName"], urlIndex: this.queryDetail[i]["urlIndex"], sqlquery: this.queryDetail[i]["sqlquery"],
                sqlbegintimestamp: this.queryDetail[i]["sqlbegintimestamp"], sqlendtimestamp: this.queryDetail[i]["sqlendtimestamp"],
                cumsqlexectime: this.queryDetail[i]["cumsqlexectime"]
            };
        }
        return dataArr;
    }
    showRowInfo(rowData) {
        this.sqlIndex = rowData.sqlindex;
        this.dbPerm = this.sessionService.isFeatureWrite(src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_5__["CAV_FEATURES"].APM.NAME, src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_5__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS);
        if (rowData.sqlQuery == undefined)
            this.fullQueryName = rowData.sqlquery;
        else
            this.fullQueryName = rowData.sqlQuery;
        if (!this.otelMode) {
            let urlDbParam = "";
            urlDbParam += "testRun=" + this.id.testRun + "&tierId=" + this.id.tierId + "&tierName=" + this.id.tierName +
                "&serverId=" + this.id.serverId + "&appId=" + this.id.appId + "&flowpathInstance=" + this.id.flowpathInstance +
                "&strStartTime=" + this.id.startTimeInMs + "&strEndTime=" + String(Number(this.endTimeInMs) + 1000) + '&sqlIndex=' + this.sqlIndex;
            this.paramLoad = true;
            this.ndDdrHttpService.getDBParamData(urlDbParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["DBQueryParamLoadedState"]) {
                    this.assignDbParamData(state.data);
                }
            });
        }
        this.showTable = true;
    }
    assignDbParamData(res) {
        this.dbParamInfo = res.data;
        this.paramLoad = false;
        this.showDbParam = true;
    }
    clickHandler(event) {
        this.showAllOption = true;
        let filteredDataArr = [];
        if (event.point.name == 'Other')
            this.queryInfo = this.restDataArrOfPie;
        else {
            for (let j = 0; j < this.chartData.length; j++) {
                if (this.chartData[j]['sqlquery'] == event.point.name || this.chartData[j]['sqlQuery'] == event.point.name)
                    filteredDataArr.push(this.chartData[j]);
            }
            this.queryInfo = filteredDataArr;
        }
        this.showRowInfo(this.queryInfo[0]);
    }
    showAllData() {
        this.showAllOption = false;
        this.queryInfo = this.wholeData;
    }
    deleteObjProp(json, arr) {
        json.forEach((val, index) => {
            arr.forEach((key, i) => {
                if (val.hasOwnProperty(key))
                    delete val[key];
            });
        });
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = "testRun=" + this.id.testRun + "&queryId=" + this.queryId + "&tierName=" + this.id.tierName;
        this.isCancelQuery = false;
        this.ndDdrHttpService.getCancelQueryResult(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["CancelQueryLoadedState"]) {
                return state.data;
            }
        });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    ngOnDestroy() {
        if (this.commonService.isFromSplitView) {
            this._ddrData.splitViewFlag = true;
            this.commonService.isToLoadSideBar = false;
        }
    }
};
FpToDbComponentComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_7__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__["BreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_4__["SessionService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__["NdDdrHttpService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_9__["ElasticsearchQueryService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], FpToDbComponentComponent.prototype, "columnData", void 0);
FpToDbComponentComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-fp-to-db-component',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./fp-to-db-component.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./fp-to-db-component.component.scss */ "./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.scss")).default]
    })
], FpToDbComponentComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.css":
/*!**********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.css ***!
  \**********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\r\n    height: 50px;\r\n    margin-left: 50%;\r\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.ts":
/*!*********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.ts ***!
  \*********************************************************************************************/
/*! exports provided: GroupByCustomDataComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "GroupByCustomDataComponent", function() { return GroupByCustomDataComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-top-panel-navigation.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-top-panel-navigation.service.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_12__);


// import { DataTableModule, BlockUIModule, MultiSelectModule, GrowlModule } from 'primeng/primeng';








// import { forEach } from '@angular/router/src/utils/collection';



let GroupByCustomDataComponent = class GroupByCustomDataComponent {
    constructor(_router, _ddrData, commonService, _navService, _cavConfig, _cavConfigService, breadcrumbService, ddrRequest, sessionService, activatedRoute, breadcrumb) {
        this._router = _router;
        this._ddrData = _ddrData;
        this.commonService = commonService;
        this._navService = _navService;
        this._cavConfig = _cavConfig;
        this._cavConfigService = _cavConfigService;
        this.breadcrumbService = breadcrumbService;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.activatedRoute = activatedRoute;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_12__;
        this.loading = false;
        this.dataValue = [];
        this.dataValue1 = [];
        this.filterCriteria = '';
        this.showChart = false;
        this.showBarChart = false;
        this.chartData = [];
        this.countFlag = false;
        this.commonColumns = [];
        this.showDownLoadReportIcon = true;
        this.showDownLoadReportIcon1 = true;
        this.showAllOption = false;
        this.paginationFlag = true;
        this.customOffset = 0;
        this.customLimit = 50;
        this.msgs = [];
        this.tooltipArr = [];
        this.customOptions = [];
        this.breadcrumb = breadcrumb;
        this.activatedRoute.queryParams.subscribe((params) => {
            this.stateID = params['state'];
        });
    }
    ngOnInit() {
        this.loading = true;
        this.breadcrumb.add({ label: 'Custom Data By BT Splitting', routerLink: '/ddr/CustomDataByBTSplitting', queryParams: { state: this.stateID } });
        this.commonService.isToLoadSideBar = false;
        this.commonService.isFilterFromSideBar = false;
        this.urlParam = this.commonService.getData();
        console.log('commonService data----->', this.urlParam);
        this.screenHeight = Number(this.commonService.screenHeight) - 120;
        /* if (this.urlParam.customOptions) {       //commenting as it is not supported yet.
          console.log('*********true**********');
          this.customOptions = this.urlParam.customOptions.split(',');
        } else {
          this.customOptions = this._ddrData.customOptions;
        }
        console.log('data options*******', this._ddrData.customOptions, this.urlParam.customOptions, this.customOptions); */
        this.fillData();
        this.fillDataForCustomData();
        this.createFilterCriteria();
        Promise.all([
            this.getTableData(),
            this.getTableDataCount()
        ]).then(() => {
            this.strTitle = 'Custom Data By BT Splitting';
            this.CustomTable = `Tabular View [Group By = ${this.customOptions}]`;
        });
    }
    createFilterCriteria() {
        if (this.sessionService.preSession.multiDc) {
            let dcName = this._cavConfigService.getActiveDC();
            if (dcName === "ALL") {
                dcName = this._ddrData.dcName;
            }
            this.filterCriteria = `DC=${dcName}, `;
        }
        if (this.urlParam.tierName && this.urlParam.tierName !== 'NA') {
            this.filterCriteria += `Tier=${this.urlParam.tierName}`;
        }
        if (this.urlParam.serverName && this.urlParam.serverName !== 'NA') {
            this.filterCriteria += `, Server=${this.urlParam.serverName}`;
        }
        if (this.urlParam.appName && this.urlParam.appName !== 'NA') {
            this.filterCriteria += `, Instance=${this.urlParam.appName}`;
        }
        if (this.urlParam.startTime && this.urlParam.startTime !== 'NA') {
            this.filterCriteria += `, StartTime=${this.sessionService.convertTimestampIntoFormattedString(Number(this.urlParam.startTime), "MM/DD/YYYY HH:mm:ss")}`;
        }
        if (this.urlParam.endTime && this.urlParam.endTime !== 'NA') {
            this.filterCriteria += `, EndTime=${this.sessionService.convertTimestampIntoFormattedString(Number(this.urlParam.endTime), "MM/DD/YYYY HH:mm:ss")}`;
        }
        if (this.urlParam.urlName && this.urlParam.urlName !== 'NA') {
            this.filterCriteria += `, BT=${this.urlParam.urlName}`;
        }
    }
    fillData() {
        let bt = [
            { field: 'BusinesTransaction', header: 'BusinessTransaction', sortable: true, action: true, tooltip: 'BusinessTransaction' }
        ];
        this.commonColumns = [
            { field: 'TotalOverallCount', header: 'Overall', sortable: 'custom', action: true, tooltip: 'Total Overall Count' },
            { field: 'TotalOverAllDur', header: 'Sum', sortable: 'custom', action: false, tooltip: 'Total OverAll Duration (ms)' },
            { field: 'MinOverallDur', header: 'Min', sortable: 'custom', action: false, tooltip: 'Min Overall Dur (ms)' },
            { field: 'MaxOverallDur', header: 'Max', sortable: 'custom', action: true, tooltip: 'Max Overall Duration (ms)' },
            { field: 'AvgOverallDur', header: 'Avg', sortable: 'custom', action: true, tooltip: 'Avg Overall Dur (ms)' },
            { field: 'TotalNormalCount', header: 'Normal', sortable: 'custom', action: true, tooltip: 'Total Normal Count' },
            { field: 'TotalNormalCountPct', header: 'Normal %', sortable: 'custom', action: true, tooltip: 'Normal Percentage' },
            { field: 'TotalNormalDur', header: 'Sum', sortable: 'custom', action: false, tooltip: 'Total Normal Duration (ms)' },
            { field: 'MinNormalDur', header: 'Min', sortable: 'custom', action: false, tooltip: 'Min Normal Duration (ms)' },
            { field: 'MaxNormalDur', header: 'Max', sortable: 'custom', action: true, tooltip: 'Max Normal Duration (ms)' },
            { field: 'AvgNormalDur', header: 'Avg', sortable: 'custom', action: true, tooltip: 'Avg Normal Duration (ms)' },
            { field: 'TotalSlowCount', header: 'Slow', sortable: 'custom', action: true, tooltip: 'Total Slow Count' },
            { field: 'TotalSlowCountPct', header: 'Slow %', sortable: 'custom', action: true, tooltip: 'Slow Percentage' },
            { field: 'TotalSlowDur', header: 'Sum', sortable: 'custom', action: false, tooltip: 'Total Slow Duration (ms)' },
            { field: 'MinSlowDur', header: 'Min', sortable: 'custom', action: false, tooltip: 'Min Slow Duration (ms)' },
            { field: 'MaxSlowDur', header: 'Max', sortable: 'custom', action: true, tooltip: 'Max Slow Duration (ms)' },
            { field: 'AvgSlowDur', header: 'Avg', sortable: 'custom', action: true, tooltip: 'Avg Slow Duration (ms)' },
            { field: 'TotalVerySlowCount', header: 'VerySlow', sortable: 'custom', action: true, tooltip: 'Total Very Slow Count' },
            { field: 'TotalVerySlowCountPct', header: 'VerySlow %', sortable: 'custom', action: true, tooltip: 'Very Slow Percentage' },
            { field: 'TotalVerySlowDur', header: 'Sum', sortable: 'custom', action: false, tooltip: 'Total Very Slow Duration (ms)' },
            { field: 'MinVerySlowDur', header: 'Min', sortable: 'custom', action: false, tooltip: 'Min VerySlow Duration (ms)' },
            { field: 'MaxVerySlowDur', header: 'Max', sortable: 'custom', action: true, tooltip: 'Max VerySlow Duration (ms)' },
            { field: 'AvgVerySlowDur', header: 'Avg', sortable: 'custom', action: true, tooltip: 'Avg Very Slow Duration (ms)' },
            { field: 'TotalErrorCount', header: 'Error)', sortable: 'custom', action: true, tooltip: 'Total Error Count' },
            { field: 'TotalErrorCountPct', header: 'Error %', sortable: 'custom', action: true, tooltip: 'Error Percentage' },
            { field: 'TotalErrorDur', header: 'Sum', sortable: 'custom', action: false, tooltip: 'Total Error Duration (ms)' },
            { field: 'MinErrorDur', header: 'Min', sortable: 'custom', action: false, tooltip: 'Min Error Duration (ms)' },
            { field: 'MaxErrorDur', header: 'Max', sortable: 'custom', action: true, tooltip: 'Max Error Duration' },
            { field: 'AvgErrorDur', header: 'Avg', sortable: 'custom', action: true, tooltip: 'Avg Error Duration (ms)' }
        ];
        this.btCols = bt.concat(this.commonColumns);
        this.visibleCols = [
            'BusinesTransaction', 'TotalOverallCount', 'MaxOverallDur', 'AvgOverallDur', 'TotalNormalCount', 'TotalNormalCountPct',
            'MaxNormalDur', 'AvgNormalDur', 'TotalSlowCount', 'TotalSlowCountPct', 'MaxSlowDur', 'AvgSlowDur', 'TotalVerySlowCount',
            'TotalVerySlowCountPct', 'MaxVerySlowDur', 'AvgVerySlowDur', 'TotalErrorCount', 'TotalErrorCountPct', 'MaxErrorDur',
            'AvgErrorDur'
        ];
        this.columnOptions = this.btCols.map(col => ({ label: col.header, value: col.field }));
    }
    fillDataForCustomData() {
        try {
            let custom = [];
            let bt = [
                { field: 'BusinesTransaction', header: 'BusinessTransaction', sortable: true, action: true }
            ];
            /* console.log('columnotions----***>', this.customOptions, this.customOptions.length)
            for (let i = 0; i < this.customOptions.length; i++) {
              custom.push(
                { field: this.customOptions[i], header: this.customOptions[i], sortable: true, action: true, tooltip: this.customOptions[i] }
                );
            } */
            let mergeArray = bt.concat(custom);
            this.cols = mergeArray.concat(this.commonColumns);
            let btCol = ['BusinesTransaction'];
            let merge = btCol.concat(this.customOptions);
            this.visibleCols1 = merge.concat([
                'TotalOverallCount', 'MaxOverallDur', 'AvgOverallDur', 'TotalNormalCount', 'TotalNormalCountPct', 'MaxNormalDur',
                'AvgNormalDur', 'TotalSlowCount', 'TotalSlowCountPct', 'MaxSlowDur', 'AvgSlowDur', 'TotalVerySlowCount',
                'TotalVerySlowCountPct', 'MaxVerySlowDur', 'AvgVerySlowDur', 'TotalErrorCount', 'TotalErrorCountPct', 'MaxErrorDur',
                'AvgErrorDur'
            ]);
            this.columnOptions1 = [];
            for (let i = 0; i < this.cols.length; i++) {
                this.columnOptions1.push({ label: this.cols[i].header, value: this.cols[i].field });
            }
        }
        catch (error) {
            console.log('error in intialization component --> ', error);
        }
    }
    /**
     * @Handling column toggle for aggrgate table
     */
    showHideColumn(data) {
        if (this.visibleCols.length === 1) {
            this.prevColumn = this.visibleCols[0];
        }
        if (this.visibleCols.length === 0) {
            this.visibleCols.push(this.prevColumn);
        }
        if (this.visibleCols.length !== 0) {
            for (let i = 0; i < this.btCols.length; i++) {
                for (let j = 0; j < this.visibleCols.length; j++) {
                    if (this.btCols[i].field === this.visibleCols[j]) {
                        this.btCols[i].action = true;
                        break;
                    }
                    else {
                        this.btCols[i].action = false;
                    }
                }
            }
        }
        data.value.sort(function (a, b) {
            return parseFloat(a.index) - parseFloat(b.index);
        });
    }
    /**
     *  Coolumn toggler for Custom Data Table
     */
    showHideColumnForCustomData(data) {
        if (this.visibleCols1.length === 1) {
            this.prevColumn = this.visibleCols1[0];
        }
        if (this.visibleCols1.length === 0) {
            this.visibleCols1.push(this.prevColumn);
        }
        if (this.visibleCols1.length !== 0) {
            for (let i = 0; i < this.cols.length; i++) {
                for (let j = 0; j < this.visibleCols1.length; j++) {
                    if (this.cols[i].field === this.visibleCols1[j]) {
                        this.cols[i].action = true;
                        break;
                    }
                    else {
                        this.cols[i].action = false;
                    }
                }
            }
        }
        data.value.sort(function (a, b) {
            return parseFloat(a.index) - parseFloat(b.index);
        });
    }
    /**
     *  Rest call for Aggrgate BT Data
     */
    getTableData() {
        const { product, testRun, tierName, serverName, appName, urlName, startTime, endTime } = this.urlParam;
        this.btUrl = `${this.getHostUrl()}/${product}/v1/cavisson/netdiagnostics/ddr/GroupByCustomDataForAngular?testRun=${testRun}&tierName=${tierName}&serverName=${serverName}&appName=${appName}&urlName=${urlName}&abs_startTime=${startTime}&abs_endTime=${endTime}&customDataOptions=NA&limit=${this.customLimit}&offset=${this.customOffset}`;
        const ajaxUrl = `${this.btUrl}&showCount=false`;
        this.ddrRequest.getDataUsingGet(ajaxUrl).subscribe(this.doAssignValueAggregate.bind(this));
    }
    /**
     * assigning aggregate data
     */
    doAssignValueAggregate(data) {
        if (data.Status) {
            this.loading = false;
            this.showError(data.Status);
            return;
        }
        if (data.data.length === 0) {
            this.showDownLoadReportIcon = false;
        }
        else {
            this.dataValue = data.data;
            const firstDataValue = this.dataValue[0];
            // this.getSecondTableData(firstDataValue.urlindex);
            // this.getSecondTableDataCount();
            this.createPieChart(Number(firstDataValue.TotalNormalCountPct), Number(firstDataValue.TotalSlowCountPct), Number(firstDataValue.TotalVerySlowCountPct), Number(firstDataValue.TotalErrorCountPct));
            this.createBarChart(Number(firstDataValue.TotalNormalCount), Number(firstDataValue.TotalSlowCount), Number(firstDataValue.TotalVerySlowCount), Number(firstDataValue.TotalErrorCount));
        }
        this.loading = false;
    }
    /**
    * @param error notification
    */
    showError(msg) {
        this.msgs = [];
        this.msgs.push({ severity: 'error', summary: 'Error Message', detail: msg });
    }
    /**
     * Count rest call for aggregate bt table
     */
    getTableDataCount() {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            const countUrl = `${this.btUrl}&showCount=true`;
            console.log('Custom Data Url Count****', countUrl);
            try {
                const data = yield this.ddrRequest.getDataUsingGet(countUrl).toPromise();
                this.doAssignValueAggregateCountData(data);
            }
            catch (error) {
                console.error(error);
            }
        });
    }
    /**
     * @assigning count rest data
     */
    doAssignValueAggregateCountData(data) {
        try {
        }
        catch (error) {
        }
    }
    /**
     * @rest call for Custom data Table
     */
    getSecondTableData(urlindex) {
        console.log('urlidx********', urlindex);
        this.CustomUrl = this.getHostUrl();
        // let options = this.custom
        const queryParams = new URLSearchParams({
            testRun: this.urlParam.testRun,
            tierName: this.urlParam.tierName,
            serverName: this.urlParam.serverName,
            appName: this.urlParam.appName,
            urlName: this.urlParam.urlName,
            urlindex,
            abs_startTime: this.urlParam.startTime,
            abs_endTime: this.urlParam.endTime,
            customDataOptions: this.customOptions.join(','),
            limit: this.customLimit.toString(),
            offset: this.customOffset.toString(),
        });
        this.CustomUrl = `${this.CustomUrl}/${this.urlParam.product}/v1/cavisson/netdiagnostics/ddr/GroupByCustomDataForAngular?${queryParams}`;
        const ajaxUrl = `${this.CustomUrl}&showCount=false`;
        console.log('Custom Data Url****', ajaxUrl);
        this.ddrRequest.getDataUsingGet(ajaxUrl)
            .subscribe(data => this.doAssignValueGroup(data), error => console.error('Error fetching data for getSecondTableData', error));
    }
    /**
     * @assigning custom rest data
     */
    doAssignValueGroup(data) {
        this.loading = false;
        this.dataValue1 = data['data'];
        if (this.dataValue1.length === 0) {
            this.showDownLoadReportIcon1 = false;
        }
        const TableData = [];
        for (let val of this.dataValue1) {
            if (val === 'null') {
                val = this.formatter(val);
            }
            const obj = val.CustomDataColumns;
            delete val['CustomDataColumns'];
            const TableDatavalue = Object.assign(val, obj);
            TableData.push(TableDatavalue);
        }
    }
    /**
     * custom count rest call
     */
    getSecondTableDataCount() {
        const countUrl = `${this.CustomUrl}&showCount=true`;
        this.ddrRequest.getDataUsingGet(countUrl)
            .subscribe(data => this.doAssignValueGroupByCustomCount(data), error => console.error('Error fetching data for getSecondTableDataCount', error));
    }
    /**
     * @assigning custom count data
     */
    doAssignValueGroupByCustomCount(res) {
        this.customTotalCount = res.totalCount;
        if (this.customLimit > this.customTotalCount) {
            this.customLimit = Number(this.customTotalCount);
        }
    }
    /**
       * @Custom Sorting on data for BT Table
     */
    CustomsortOnColumnsforbtTable(event, tempData) {
        if (event.field === "BusinesTransaction") {
            const reA = /[^a-zA-Z]/g; // Regular expression to remove non-alphabetic characters and forward slashes
            const reN = /[^0-9]/g; // Regular expression to remove non-numeric characters
            const fieldValue = event.field;
            if (event.order == -1) {
                event.order = 1;
                tempData.sort(function (a, b) {
                    const v1 = a[fieldValue].replace(reA, "");
                    const v2 = b[fieldValue].replace(reA, "");
                    if (v1 === v2) {
                        let value1 = parseInt(a[fieldValue].replace(reN, ""), 10);
                        let value2 = parseInt(b[fieldValue].replace(reN, ""), 10);
                        return (value2 > value1) ? 1 : ((value2 < value1) ? -1 : 0);
                    }
                    else {
                        let value1 = a[fieldValue];
                        let value2 = b[fieldValue];
                        return (value2 > value1) ? 1 : ((value2 < value1) ? -1 : 0);
                    }
                });
            }
            else {
                event.order = -1;
                tempData.sort(function (a, b) {
                    const v1 = a[fieldValue].replace(reA, "");
                    const v2 = b[fieldValue].replace(reA, "");
                    if (v1 === v2) {
                        let value1 = parseInt(a[fieldValue].toString().replace(reN, ""), 10);
                        let value2 = parseInt(b[fieldValue].toString().replace(reN, ""), 10);
                        return (value1 > value2) ? 1 : ((value1 < value2) ? -1 : 0);
                    }
                    else {
                        let value1 = a[fieldValue];
                        let value2 = b[fieldValue];
                        return (value1 > value2) ? 1 : ((value1 < value2) ? -1 : 0);
                    }
                });
            }
        }
        else {
            const fieldValue = event.field;
            const order = (event.order === -1) ? 1 : -1;
            tempData.sort((a, b) => {
                const value1 = parseFloat(a[fieldValue].replace('-', 0));
                const value2 = parseFloat(b[fieldValue].replace('-', 0));
                return order * ((value1 > value2) ? 1 : ((value1 < value2) ? -1 : 0));
            });
        }
        this.dataValue = [...tempData];
    }
    /**
   * @Custom Sorting on data for Custom Table
   */
    CustomsortOnColumnsforCustom(event, tempData) {
        console.log(event);
        console.log(JSON.stringify(tempData));
        let fieldValue = event['field'];
        if (event.order === -1) {
            event.order = 1;
            tempData = tempData.sort(function (a, b) {
                var value = parseFloat(a[fieldValue].replace('-', 0));
                var value2 = parseFloat(b[fieldValue].replace('-', 0));
                return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
            });
        }
        else {
            event.order = -1;
            // asecding order
            tempData = tempData.sort(function (a, b) {
                var value = parseFloat(a[fieldValue].replace('-', 0));
                var value2 = parseFloat(b[fieldValue].replace('-', 0));
                return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
            });
        }
        this.dataValue1 = [];
        // console.log(JSON.stringify(tempData));
        if (tempData) {
            tempData.map((rowdata) => { this.dataValue1 = this.Immutablepush(this.dataValue1, rowdata); });
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    /*This Method is used for handle the Column Filter Flag*/
    toggleColumnFilterforbtTable() {
        // if (this.isEnabledColumnFilterForbtTable) {
        //   this.isEnabledColumnFilterForbtTable = false;
        // } else {
        //   this.isEnabledColumnFilterForbtTable = true;
        // }
        // this.changeColumnFilterForbtTable();
    }
    toggleColumnFilterforCustom() {
        // if (this.isEnabledColumnFilterForCustom) {
        //   this.isEnabledColumnFilterForCustom = false;
        // } else {
        //   this.isEnabledColumnFilterForCustom = true;
        // }
        this.changeColumnFilterForCustom();
    }
    /*This method is used to Enable/Disabled Column Filter*/
    changeColumnFilterForbtTable() {
        // try {
        //   let tableColumns = this.btCols;
        //   if (this.isEnabledColumnFilterForbtTable) {
        //     this.toggleFilterTitleForbtTable = 'Show Column Filters';
        //     for (let i = 0; i < tableColumns.length; i++) {
        //       tableColumns[i].filter = false;
        //     }
        //   } else {
        //     this.toggleFilterTitleForbtTable = 'Hide Column Filters';
        //     for (let i = 0; i < tableColumns.length; i++) {
        //       tableColumns[i].filter = true;
        //     }
        //   }
        // } catch (error) {
        //   console.log('Error while Enable/Disabled column filters', error);
        // }
    }
    changeColumnFilterForCustom() {
        // try {
        //   let tableColumns = this.cols;
        //   if (this.isEnabledColumnFilterForCustom) {
        //     this.toggleFilterTitleForCustom = 'Show Column Filters';
        //     for (let i = 0; i < tableColumns.length; i++) {
        //       tableColumns[i].filter = false;
        //     }
        //   } else {
        //     this.toggleFilterTitleForCustom = 'Hide Column Filters';
        //     for (let i = 0; i < tableColumns.length; i++) {
        //       tableColumns[i].filter = true;
        //     }
        //   }
        // } catch (error) {
        //   console.log('Error while Enable/Disabled column filters', error);
        // }
    }
    //Pagination
    paginate(event) {
        // event.first = Index of the first record  (used  as offset in query) 
        // event.rows = Number of rows to display in new page  (used as limit in query)
        // event.page = Index of the new page
        // event.pageCount = Total number of pages
        this.customOffset = parseInt(event.first);
        this.customLimit = parseInt(event.rows);
        console.log('Limit and Offset---', this.customLimit, this.customOffset);
        if (this.customLimit > this.customTotalCount) {
            this.customLimit = Number(this.customTotalCount);
        }
        if ((this.customLimit + this.customOffset) > this.customTotalCount) {
            this.customLimit = Number(this.customTotalCount) - Number(this.customOffset);
        }
    }
    formatter(value) {
        if (value === 'null') {
            return '-';
        }
    }
    //Update PieChart on click BT
    oenPieChart(node) {
        console.log('node**********', node);
        this.createPieChart(Number(node.TotalNormalCountPct), Number(node.TotalSlowCountPct), Number(node.TotalVerySlowCountPct), Number(node.TotalErrorCountPct));
        this.createBarChart(Number(node.TotalNormalCount), Number(node.TotalSlowCount), Number(node.TotalVerySlowCount), Number(node.TotalErrorCount));
        // this.loading = true;
        this.customLimit = 50;
        this.customOffset = 0;
        // this.getSecondTableData(node.urlindex);
        // this.getSecondTableDataCount();
    }
    //Creating pie-Chart oon basis of response time of bt category
    createPieChart(normal, slow, verySlow, error) {
        normal = normal !== null && normal !== void 0 ? normal : 0;
        slow = slow !== null && slow !== void 0 ? slow : 0;
        verySlow = verySlow !== null && verySlow !== void 0 ? verySlow : 0;
        error = error !== null && error !== void 0 ? error : 0;
        const infoArr = [];
        if (normal > 0) {
            infoArr.push({ name: 'Normal', y: normal });
        }
        if (slow > 0) {
            infoArr.push({ name: 'Slow', y: slow });
        }
        if (verySlow > 0) {
            infoArr.push({ name: 'VerySlow', y: verySlow });
        }
        if (error > 0) {
            infoArr.push({ name: 'Error', y: error });
        }
        console.log('arr', infoArr);
        this.showChart = (infoArr.length > 0); // Check if we have valid data points or not.
        this.options = {
            chart: {
                plotBackgroundColor: null,
                plotBorderWidth: null,
                plotShadow: false,
                type: 'pie',
            },
            credits: {
                enabled: false
            },
            title: { text: 'Response Time', style: { 'fontSize': '13px' } },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
            },
            plotOptions: {
                pie: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    dataLabels: {
                        enabled: true,
                        format: '<b> {point.name} </b>: {point.percentage:.1f} %',
                    },
                }
            },
            series: [
                {
                    name: 'Percentage',
                    data: infoArr,
                    enableMouseTracking: true
                }
            ]
        };
    }
    //Creating bar chart on basis of count of Aggregate table btcategory total count
    createBarChart(normalCount, slowCount, verySlowCount, errorCount) {
        normalCount = normalCount !== null && normalCount !== void 0 ? normalCount : 0;
        slowCount = slowCount !== null && slowCount !== void 0 ? slowCount : 0;
        verySlowCount = verySlowCount !== null && verySlowCount !== void 0 ? verySlowCount : 0;
        errorCount = errorCount !== null && errorCount !== void 0 ? errorCount : 0;
        const infoArr = [];
        if (normalCount > 0) {
            infoArr.push({ name: 'Normal', y: normalCount });
        }
        if (slowCount > 0) {
            infoArr.push({ name: 'Slow', y: slowCount });
        }
        if (verySlowCount > 0) {
            infoArr.push({ name: 'VerySlow', y: verySlowCount });
        }
        if (errorCount > 0) {
            infoArr.push({ name: 'Error', y: errorCount });
        }
        console.log('arr', infoArr);
        this.showBarChart = (infoArr.length > 0); // Check if we have valid data points or not.
        this.options1 = {
            chart: {
                type: 'column'
            },
            title: {
                text: 'Flowpaths By BT Category',
                style: { 'fontSize': '13px' }
            },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                labels: {
                    enabled: false
                }
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Count'
                }
            },
            tooltip: {
                headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
                pointFormat: '{series.name}: <b> {point.y} </b>',
                footerFormat: '</table>',
                shared: true,
                useHTML: true
            },
            plotOptions: {
                column: {
                    pointPadding: 0.2,
                    borderWidth: 0
                }
            },
            series: [
                {
                    name: 'Counts',
                    enableMouseTracking: true,
                    data: infoArr
                }
            ]
        };
    }
    // Method is used get host url
    getHostUrl(isDownloadCase) {
        var hostDcName;
        if (this.sessionService.preSession.multiDc) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.urlParam.testRun = this._ddrData.testRun;
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        return hostDcName;
    }
    //Flowpath Report Method
    openFlowpathReport(rowData, btCategory) {
        this._ddrData.dbTofpflag = false; // for bug 50806
        const reqData = {
            tierName: this.urlParam.tierName,
            serverName: this.urlParam.serverName,
            appName: this.urlParam.appName,
            BusinesTransaction: rowData.BusinesTransaction,
            urlindex: rowData.urlindex,
            startTime: this.urlParam.startTime,
            endTime: this.urlParam.endTime,
            btCategory: btCategory,
            customData: '',
            customFilter: ''
        };
        if ('CustomDataColumns' in rowData) {
            this._ddrData.customToFlowpathFlag = true;
            this.commonService.customToFlowpathData = reqData;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_9__["BREADCRUMB_ITEMS"].BTSPLITTING;
            if (this._router.url.includes('/home/ED-ddr')) {
                this._router.navigate(['/home/ED-ddr/flowpath']);
            }
            else {
                this._router.navigate(['/ddr/flowpath']);
            }
        }
        else {
            let customdataFilter = '';
            let http = '';
            for (let i = 0; i < this.customOptions.length; i++) {
                const customheader = this.customOptions[i];
                const valueOfCustomHeader = rowData[customheader];
                if (i === 0) {
                    http = `${customheader}:-:${valueOfCustomHeader}:-`;
                    customdataFilter = `${customheader}: ${valueOfCustomHeader}`;
                }
                else {
                    http += `:1:${customheader}:-:${valueOfCustomHeader}:-`;
                    customdataFilter += `, ${customheader}: ${valueOfCustomHeader}`;
                }
            }
            reqData.customData = http;
            reqData.customFilter = customdataFilter;
            this._ddrData.customToFlowpathFlag = true;
            this.commonService.patternflag = true;
            this.commonService.customToFlowpathData = reqData;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_9__["BREADCRUMB_ITEMS"].BTSPLITTING;
            if (this._router.url.includes('/home/ED-ddr')) {
                this._router.navigate(['/home/ED-ddr/flowpath']);
            }
            else {
                this._router.navigate(['/home/ddr/flowpath']);
            }
        }
    }
    //Download Report Method
    downloadReports(downloadType, Index) {
        let renameArray;
        let colOrder;
        let downloadData;
        if (Index === '1') {
            renameArray = { "BusinesTransaction": "BusinesTransaction", "TotalOverallCount": "Total Overall Count",
                "TotalOverAllDur": "Total OverAll Duration (ms)", "MinOverallDur": "Min Overall Dur (ms)",
                "MaxOverallDur": "Max Overall Duration (ms)", "AvgOverallDur": "Avg Overall Dur (ms)", "TotalNormalCount": "Total Normal Count",
                "TotalNormalCountPct": "Normal Percentage", "TotalNormalDur": "Total Normal Duration (ms)", "MinNormalDur": "Min Normal Duration (ms)",
                "MaxNormalDur": "Max Normal Duration (ms)", "AvgNormalDur": "Avg Normal Duration (ms)", "TotalSlowCount": "Total Slow Count",
                "TotalSlowCountPct": "Slow Percentage", "TotalSlowDur": "Total Slow Duration (ms)", "MinSlowDur": "Min Slow Duration (ms)",
                "MaxSlowDur": "Max Slow Duration (ms)", "AvgSlowDur": "Avg Slow Duration (ms)", "TotalVerySlowCount": "Total Very Slow Count",
                "TotalVerySlowCountPct": "Very Slow Percentage", "TotalVerySlowDur": "Total Very Slow Duration (ms)",
                "MinVerySlowDur": "Min VerySlow Duration (ms)", "MaxVerySlowDur": "Max Very Slow Duration (ms)",
                "AvgVerySlowDur": "Avg Very Slow Duration (ms)", "TotalErrorCount": "Total Error Count", "TotalErrorCountPct": "Error Percentage",
                "TotalErrorDur": "Total Error Duration (ms)", "MinErrorDur": "Min Error Duration (ms)", "MaxErrorDur": "Max Error Duration",
                "AvgErrorDur": "Avg Error Duration (ms)" };
            colOrder = ['BusinesTransaction', 'Total Overall Count', 'Total OverAll Duration (ms)', 'Min Overall Dur (ms)',
                'Max Overall Duration (ms)', 'Avg Overall Dur (ms)', 'Total Normal Count', 'Normal Percentage', 'Total Normal Duration (ms)',
                'Min Normal Duration (ms)', 'Max Normal Duration (ms)', 'Avg Normal Duration (ms)', 'Total Slow Count', 'Slow Percentage',
                'Total Slow Duration (ms)', 'Min Slow Duration (ms)', 'Max Slow Duration (ms)', 'Avg Slow Duration (ms)', 'Total Very Slow Count',
                'Very Slow Percentage', 'Total Very Slow Duration (ms)', 'Min VerySlow Duration (ms)', 'Max Very Slow Duration (ms)',
                'Avg Very Slow Duration (ms)', 'Total Error Count', 'Error Percentage', 'Total Error Duration (ms)', 'Min Error Duration (ms)',
                'Max Error Duration', 'Avg Error Duration (ms)'];
            this.dataValue.forEach((val, index) => {
                delete val['id'];
                delete val['urlindex'];
                delete val['CustomDataColumns'];
                delete val['TotalStalledCount'];
                delete val['TotalStalledCountPct'];
                delete val['TotalStalledDur'];
                delete val['MinStalledDur'];
                delete val['MaxStalledDur'];
                delete val['AvgStalledDur'];
            });
            downloadData = this.dataValue;
        }
        else if (Index === '2') {
            renameArray = { "BusinesTransaction": "BusinesTransaction" };
            for (var i = 0; i < this.customOptions.length; i++) {
                renameArray[this.customOptions[i]] = this.customOptions[i];
            }
            renameArray = Object.assign(renameArray, { "TotalOverallCount": "Total Overall Count",
                "TotalOverAllDur": "Total OverAll Duration (ms)", "MinOverallDur": "Min Overall Dur (ms)", "MaxOverallDur": "Max Overall Duration (ms)",
                "AvgOverallDur": "Avg Overall Dur (ms)", "TotalNormalCount": "Total Normal Count", "TotalNormalCountPct": "Normal Percentage",
                "TotalNormalDur": "Total Normal Duration (ms)", "MinNormalDur": "Min Normal Duration (ms)", "MaxNormalDur": "Max Normal Duration (ms)",
                "AvgNormalDur": "Avg Normal Duration (ms)", "TotalSlowCount": "Total Slow Count", "TotalSlowCountPct": "Slow Percentage",
                "TotalSlowDur": "Total Slow Duration (ms)", "MinSlowDur": "Min Slow Duration (ms)", "MaxSlowDur": "Max Slow Duration (ms)",
                "AvgSlowDur": "Avg Slow Duration (ms)", "TotalVerySlowCount": "Total Very Slow Count", "TotalVerySlowCountPct": "Very Slow Percentage",
                "TotalVerySlowDur": "Total Very Slow Duration (ms)", "MinVerySlowDur": "Min VerySlow Duration (ms)",
                "MaxVerySlowDur": "Max Very Slow Duration (ms)", "AvgVerySlowDur": "Avg Very Slow Duration (ms)", "TotalErrorCount": "Total Error Count",
                "TotalErrorCountPct": "Error Percentage", "TotalErrorDur": "Total Error Duration (ms)", "MinErrorDur": "Min Error Duration (ms)",
                "MaxErrorDur": "Max Error Duration", "AvgErrorDur": "Avg Error Duration (ms)" });
            colOrder = ["BusinesTransaction"];
            for (var i = 0; i < this.customOptions.length; i++) {
                colOrder.push(this.customOptions[i]);
            }
            colOrder = colOrder.concat(["Total Overall Count", "Total OverAll Duration (ms)", "Min Overall Dur (ms)", "Max Overall Duration (ms)",
                "Avg Overall Dur (ms)", "Total Normal Count", "Normal Percentage", "Total Normal Duration (ms)", "Min Normal Duration (ms)",
                "Max Normal Duration (ms)", "Avg Normal Duration (ms)", "Total Slow Count", "Slow Percentage", "Total Slow Duration (ms)",
                "Min Slow Duration (ms)", "Max Slow Duration (ms)", "Avg Slow Duration (ms)", "Total Very Slow Count", "Very Slow Percentage",
                "Total Very Slow Duration (ms)", "Min VerySlow Duration (ms)", "Max Very Slow Duration (ms)", "Avg Very Slow Duration (ms)",
                "Total Error Count", "Error Percentage", "Total Error Duration (ms)", "Min Error Duration (ms)", "Max Error Duration",
                "Avg Error Duration (ms)"]);
            this.dataValue1.forEach((val, index) => {
                delete val['id'];
                delete val['urlindex'];
                delete val['CustomDataColumns'];
                delete val['TotalStalledCount'];
                delete val['TotalStalledCountPct'];
                delete val['TotalStalledDur'];
                delete val['MinStalledDur'];
                delete val['MaxStalledDur'];
                delete val['AvgStalledDur'];
            });
            downloadData = this.dataValue1;
        }
        const downloadObj = {
            downloadType: downloadType,
            varFilterCriteria: this.filterCriteria,
            strSrcFileName: 'FlowpathReport',
            strRptTitle: this.strTitle,
            renameArray: JSON.stringify(renameArray),
            colOrder: colOrder.toString(),
            jsonData: JSON.stringify(downloadData)
        };
        let downloadFileUrl = '';
        if (this.host !== undefined && this.host !== '' && this.host != null) {
            downloadFileUrl = this.protocol + this.host + ':' + this.port + '/' + this.urlParam.product;
        }
        else {
            if (this.sessionService.preSession.multiDc) {
                downloadFileUrl = decodeURIComponent(this._ddrData.getHostUrl(true) + '/tomcat' + '/ALL' + '/' + this.urlParam.product);
            }
            else {
                downloadFileUrl = decodeURIComponent(this.getHostUrl(true) + '/' + this.urlParam.product);
            }
        }
        downloadFileUrl += '/v1/cavisson/netdiagnostics/ddr/downloadAngularReport';
        if (this.sessionService.preSession.multiDc === true && (downloadFileUrl.includes("/tomcat") || downloadFileUrl.includes("/node"))) {
            if (downloadFileUrl.includes("/tomcat"))
                downloadFileUrl = downloadFileUrl.replace("/tomcat", "/node");
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, downloadObj).subscribe(res => (this.openDownloadReports(res)));
        }
        else {
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, JSON.stringify(downloadObj)).subscribe(res => (this.openDownloadReports(res)));
        }
    }
    openDownloadReports(res) {
        var _a;
        let downloadFileUrl = this.sessionService.preSession.multiDc
            ? `${location.protocol}//${location.host}/tomcat/ALL/common/${(_a = JSON.parse(res)) === null || _a === void 0 ? void 0 : _a.tierData}`
            : `${decodeURIComponent(this.getHostUrl(true))}/common/${res}`;
        window.open(downloadFileUrl);
    }
};
GroupByCustomDataComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_3__["CavTopPanelNavigationService"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_5__["CavConfigService"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_5__["CavConfigService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_7__["DdrBreadcrumbService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_11__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["ActivatedRoute"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__["BreadcrumbService"] }
];
GroupByCustomDataComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-group-by-custom-data',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./group-by-custom-data.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./group-by-custom-data.component.css */ "./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.css")).default]
    })
], GroupByCustomDataComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/hotspot/hotspot.component.css":
/*!********************************************************************!*\
  !*** ./src/app/pages/ddr/components/hotspot/hotspot.component.css ***!
  \********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/hotspot/hotspot.component.ts":
/*!*******************************************************************!*\
  !*** ./src/app/pages/ddr/components/hotspot/hotspot.component.ts ***!
  \*******************************************************************/
/*! exports provided: HotspotComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "HotspotComponent", function() { return HotspotComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_8__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/ddr/services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");














let HotspotComponent = class HotspotComponent {
    constructor(commonService, messageService, breadcrumbService, _router, _ddrData, ddrRequest, breadcrumb, sessionService, ndDdrHttpService) {
        this.commonService = commonService;
        this.messageService = messageService;
        this.breadcrumbService = breadcrumbService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_8__; // Variable is used for refrence of highcharts library
        this.tableHeight = 180; // Variable is used for  Height of the table
        this.hotSpotInfo = []; // Used to hold the information about hotspot report 
        this.mergeData = []; // Initialize an empty array named mergeData to store data for merging
        this.showAllOption = false; // Flag to show refresh button
        this.stackdepth = []; //// Initialize an empty array to store stack depth information
        this.chartData = []; // Stores the chart data
        this.filterCriteria = ''; // Initialize filter criteria
        this.filterCriteriaArray = []; // Initialize filter criteria array
        this.displayPopUp = false; // Set initial state of popup
        this.colsForHotspot = []; // Initialize columns for hotspot for tree-table
        this.colsForStackTrace = []; // Initialize columns for stack trace
        this.isFilterFromSideBar = false; // Set filter flag from sidebar
        this.mergeFlag = false; // Set merge flag 
        this.HSToFP = false; // Set hotspot FP flag
        this.isEnabledColumnFilterForHotspot1 = false; // Flag to enable column filter for Hotspot
        this.downloadJSON = []; // Array to store downloaded JSON data
        // DC variables'
        this.host = ''; // Host information 
        this.filterTierName = ''; // Variable is used for filtering tier names
        this.filterServerName = ''; // Variable is used for filtering server name 
        this.filterInstanceName = ''; // Variable is used for filtering server name 
        this.completeTier = ''; // Variable is used for Complete tier information
        this.completeServer = ''; // Variable is used for Complete server information 
        this.completeInstance = ''; // Variable is used for Complete instance information 
        this.compareFPInfo = {}; // Input to compare FP Info
        this.filterDCName = ''; // Filter for dc name
        this.second_url = ''; // using these variables for making common url for multidc support in CQM
        this.IP_url = ''; // URL for IP
        this.aggCase = true; // Flag for agg case 
        this.aggIpInfo = []; // Array to store the aggIP information 
        this.filterCriteriaagg = ''; // Filter criteria is used for agg-ip- table
        this.showPagination = false; // Flag to show/hide pagination
        this.showPaginationIP = false; // Flag to show/hide pagination for IP
        this.mergeDataDownloadFlag = false;
        this.empty = true; // Flag indicating if the data is empty in tree-table
        this.relativePathForHotspot = "ddr/hotspot-report/hotspot.json"; // Variable to store the relative path of hotspot report cav-table table
        this.relativePathForIP = "ddr/hotspot-report/ip.json"; // Variable to store the relative path of ip-table cav-table table
        this.loader = false;
        this.breadcrumb = breadcrumb;
    }
    ngOnInit() {
        if (this._ddrData.splitViewFlag == false)
            this.commonService.isToLoadSideBar = true;
        if (this.commonService.hotspotFilters['source'] != "FlowpathReport")
            this.commonService.currentReport = "Hotspot";
        this.commonService.hotspotFilters['source'] = "NA";
        if (!this._ddrData.isFromCompareFp) {
            this.breadcrumb.add({ label: 'HotSpot Thread Details', routerLink: '/ddr/hotspot' });
        }
        if (!this.commonService.enableQueryCaching)
            this.commonService.enableQueryCaching = this._ddrData.enableQueryCaching;
        if (this._ddrData.splitViewFlag == false) {
            this.id = this.commonService.getData();
            this.screenHeight = Number(this.commonService.screenHeight) - 135;
            if (this.commonService.hsFlag == false)
                this._ddrData.flagForHSToFP = '1';
            if (this._ddrData.flagForHSToFP === '1')
                this.commonService.hsFlag = false;
        }
        else
            this.screenHeight = Number(this.commonService.screenHeight) - 235;
        this.sideBarHotspot = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Hotspot") {
                this.commonService.isFilterFromSideBar = true;
                let keys = Object.keys(temp);
                this.getHotspotData();
            }
        });
        if ((this._router.url.indexOf('?') != -1) && (this._router.url.indexOf('/home/ED-ddr/hotspot') != -1)) {
            let queryParams1 = location.href.substring(location.href.indexOf('?') + 1, location.href.length);
            this.id = JSON.parse('{"' + decodeURI(queryParams1).replace(/"/g, '\\"').replace(/&/g, '","').replace(/=/g, '":"') + '"}');
            this.id.strEndTime = this.id.endTime;
            sessionStorage.setItem('hostDcName', location.host);
            if (this.id.enableQueryCaching) {
                this.commonService.enableQueryCaching = this.id.enableQueryCaching;
            }
            this.commonService.removeFromStorage();
            this.commonService.setInStorage = this.id;
            this.commonService.hsDataFromED = this.id;
            this.commonService.strGraphKey = this.id.strGraphKey;
            this.commonService.dcNameList = this.id.dcNameList;
            this.commonService.isAllCase = this.id.isAll;
            this.commonService.tierNameList = this.id.tierNameList;
            this.commonService.selectedDC = this.id.dcName;
            this.commonService.ajaxTimeOut = this.id.ajaxTimeout;
            sessionStorage.setItem("flagForHSToFP", this.id.flagForHSToFP || this._ddrData.flagForHSToFP);
        }
        if (this._ddrData.flagForHSToFP === '1') {
            this.HSToFP = true;
        }
        else if (sessionStorage.getItem("flagForHSToFP") === '1') {
            this.HSToFP = true;
        }
        else {
            this.HSToFP = false;
        }
        if (this.commonService.testRun != undefined && this.commonService.testRun != null && this.commonService.testRun != '') {
            this.id.testRun = this.id.testRun;
        }
        if (this.commonService.hsFlag == false && this.commonService.hsDataFromED != undefined) {
            this.id = this.commonService.hsDataFromED;
        }
        if (Object.keys(this.compareFPInfo).length > 0) {
            this.commonService.isToLoadSideBar = false;
            this.updateIdParam();
        }
        else {
            this.fillData();
            this.getGraphKey();
        }
        if (this.HSToFP) {
            this.relativePathForHotspot = "ddr/hotspot-report/hotspotToFp.json";
        }
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.passDataForStackTrace(event.cavEventExt.row);
        }
        if (((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.action) === "showalldata") {
            me.Refresh();
        }
        if (((_f = (_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.actionConfig) === null || _f === void 0 ? void 0 : _f.action) === "FPByIP") {
            me.openFPByIntegrationReport(event.cavEventExt.row, 'FPByIP');
        }
        if (((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.actionConfig) === null || _h === void 0 ? void 0 : _h.action) === "FPByResTime") {
            me.openFPByIntegrationReport(event.cavEventExt.row, 'FPByResTime');
        }
        if (((_k = (_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.actionConfig) === null || _k === void 0 ? void 0 : _k.action) === "renamebackendIPname") {
            me.openIPHealthScreen(event.cavEventExt.row.node);
        }
        if (((_m = (_l = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _l === void 0 ? void 0 : _l.actionConfig) === null || _m === void 0 ? void 0 : _m.action) === "Query") {
            me.Querypop(event.cavEventExt.row.node);
        }
        if (((_p = (_o = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _o === void 0 ? void 0 : _o.actionConfig) === null || _p === void 0 ? void 0 : _p.action) === "errorCount") {
            me.viewExceptionReport(event.cavEventExt.row.node);
        }
        if (((_r = (_q = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _q === void 0 ? void 0 : _q.columnClicked) === null || _r === void 0 ? void 0 : _r.key) === "hotspotduration") {
            me.openFPReport(event.cavEventExt.row);
        }
    }
    onClick(rowNode, event) {
        event.stopPropagation();
        this.selectedNode = rowNode;
        if (this.columnData.Instance_Type.toLowerCase() == "java") {
            if (this._ddrData.getAdminCapablities()) {
                this.onNodeSelect(rowNode);
            }
            else {
                this.messageService.add({ severity: 'error', detail: "You don't have permission to view Source Code" });
            }
        }
        else {
            this.messageService.add({ severity: 'warn', detail: `View Source Code feature is not supported for ${this.columnData.Instance_Type} agent` });
        }
    }
    onNodeSelect(event) {
        let queryParam = '';
        let className = event.node.data.className;
        let lineNumber = event.node.data.lineNo;
        let packName = event.node.data.packageName;
        let methName = event.node.data.methName;
        let fqm = `${className}.${methName}(${packName}:${lineNumber})`;
        queryParam += "fqm=" + fqm + "&j_uid=" + "" + "&tierName=" + this.columnData.tierName + "&serverName=" + this.columnData.serverName + "&instanceName=" + this.columnData.appName + "&testRun=" + this.columnData.testRun + "&classSourceCode=" + true;
        this.loader = true;
        this.ndDdrHttpService.getreadMethodBody(queryParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["ReadMethodBodyLoadedState"]) {
                this.methodBody = this.commonService.htmlEncode(state.data.methodBody);
                this.loader = false;
                this.showSourceCode = true;
            }
        }, (error) => {
            console.error('Error in fetching response ~ ', error);
            this.loader = false;
        });
    }
    updateIdParam() {
        let endTime = 0;
        if (undefined != this.compareFPInfo.fpDuration && !this._ddrData.otelMode) {
            if (this.compareFPInfo.fpDuration.toString().includes(','))
                endTime = Number(this.compareFPInfo.startTimeInMs) + Number(this.compareFPInfo.fpDuration.toString().replace(/,/g, ""));
            else if (this.compareFPInfo.fpDuration == '< 1')
                endTime = Number(this.compareFPInfo.startTimeInMs) + Number(0);
            else
                endTime = Number(this.compareFPInfo.startTimeInMs) + Number(this.compareFPInfo.fpDuration);
        }
        else {
            endTime = Number(this.compareFPInfo.startTimeInMs) + Math.ceil(this.compareFPInfo.selfResponseTime);
        }
        this.id['startTimeInMS'] = this.compareFPInfo['startTimeInMs'];
        this.id['strEndTimeMS'] = endTime + "";
        this.id['tierId'] = this.compareFPInfo['tierId'];
        this.id['serverId'] = this.compareFPInfo['serverId'];
        this.id['appId'] = this.compareFPInfo['appId'];
        this.id['tierName'] = this.compareFPInfo['tierName'];
        this.id['serverName'] = this.compareFPInfo['serverName'];
        this.id['appName'] = this.compareFPInfo['appName'];
    }
    ngOnChanges(changes) {
        var _a, _b;
        if (this._ddrData.splitViewFlag)
            this._ddrData.setInLogger("DDR:Flowpath", "Hotspot", "Open Hotspot Report");
        if (this._ddrData.splitViewBreadCrumbFlag && this._ddrData.splitViewFlag) {
            if (this.columnData) {
                this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            }
            this.breadcrumb.add({ label: 'HotSpot Thread Details' });
        }
        else if (!this._ddrData.isFromCompareFp) {
            if (this.columnData) {
                this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            }
            this.breadcrumb.add({ label: 'HotSpot Thread Details' });
            this._ddrData.splitViewBreadCrumbFlag = true;
        }
        if (this.columnData != undefined) {
            this.commonService.enableQueryCaching = this.commonService.enableQueryCaching;
            if ((_a = this.columnData.fpDuration) === null || _a === void 0 ? void 0 : _a.toString().includes(','))
                this.columnData.fpDuration = (_b = this.columnData.fpDuration) === null || _b === void 0 ? void 0 : _b.replace(',', '');
            this.id = JSON.parse(JSON.stringify(this.columnData));
            this.getHotspotData();
        }
        else {
            this.id = this.commonService.getData();
        }
        if (Object.keys(this.compareFPInfo).length > 0) {
            this.updateIdParam();
            this.fillData();
        }
        this.getGraphKey();
    }
    fillData() {
        this.colsForStackTrace = [
            { field: 'methodName', header: 'Method', sortable: false, action: true, align: 'left', width: '110' },
            { field: 'className', header: 'Class', sortable: false, action: true, align: 'left', width: '120' },
            { field: 'lineNo', header: 'Line', sortable: false, action: true, align: 'right', width: '100' },
            { field: 'packageName', header: 'Source File', sortable: false, action: true, align: 'left', width: '110' },
            { field: 'elapsedTime', header: 'Elapsed Time (ms)', sortable: false, action: true, align: 'right', width: '150' },
            { field: 'frameNo', header: 'Frame', sortable: false, action: true, align: 'right', width: '100' },
            { field: 'action', header: 'Action', sortable: false, action: true, align: 'left', width: '30' }
        ];
        if ((this.commonService.showIPSummary == false || this.commonService.hsFlag == false) && this._ddrData.splitViewFlag == false && this.commonService.openCurrentFlowpathTab == false) {
            this.relativePathForIP = "ddr/hotspot-report/agg-ip.json";
        }
        this.visibleColsForStackTrace = [
            'frameNo', 'className', 'lineNo', 'methodName', 'packageName', 'elapsedTime'
        ];
        this.columnOptionsForStackTrace = this.colsForStackTrace;
        if (this._ddrData.splitViewFlag == false)
            this.getHotspotData();
    }
    openFPByIntegrationReport(rowData, flag) {
        try {
            let fpdata = {};
            fpdata['tierId'] = this.selectedHotspot.tierid;
            fpdata['serverId'] = this.selectedHotspot.serverid;
            fpdata['appId'] = this.selectedHotspot.appid;
            fpdata['tierName'] = this.selectedHotspot.tierName;
            fpdata['serverName'] = this.selectedHotspot.serverName;
            fpdata['appName'] = this.selectedHotspot.appName;
            fpdata['backendId'] = rowData.backendId;
            fpdata['fpInst'] = rowData.fpInstance;
            fpdata['seqno'] = rowData.seqNumber;
            fpdata['backendSubType'] = rowData.backendSubType;
            if (this.id.startTimeInMs != undefined) {
                fpdata['startTime'] = this.id.startTimeInMs - 90000;
                if (!this._ddrData.otelMode) {
                    fpdata['endTime'] = Number(this.id.startTimeInMs) + Number(this.id.fpDuration) + 90000;
                }
                else {
                    fpdata['endTime'] = Number(this.id.startTimeInMs) + Math.ceil(this.id.selfResponseTime) + 90000;
                }
            }
            else {
                fpdata['startTime'] = this.id.startTime;
                fpdata['endTime'] = this.id.endTime;
            }
            if (flag === 'FPByResTime') {
                if (this._ddrData.otelMode)
                    fpdata['maxresTimeOfBackend'] = Number(this.id.fpDuration);
                else
                    fpdata['maxresTimeOfBackend'] = Math.ceil(this.id.selfResponseTime);
            }
            this._ddrData.splitViewFlag = false;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].FLOWPATH;
            this._ddrData.IPByFPFlag = true;
            this.commonService.IPByFPData = fpdata;
            if (this._router.url.indexOf('/home/ddrCopyLink/') != -1) {
                this._router.navigate(['/home/ddrCopyLink/flowpath']);
            }
            else {
                this._router.navigate(['/ddr/flowpath']);
            }
        }
        catch (error) {
            console.log('Error in opening FP Report---', error);
        }
    }
    getGraphKey() {
        if (this.id.restDrillDownUrl == undefined || this.id.restDrillDownUrl == 'undefined') {
            this.graphKey = this.commonService.strGraphKey;
        }
        else {
            return this.ddrRequest.getDataUsingGet(this.id.restDrillDownUrl).subscribe(data => (this.doAssigngraphKey(data)));
        }
    }
    doAssigngraphKey(res) {
        this.graphKey = res.graphTimeKey;
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName;
        if (this._ddrData.isFromtrxFlow) {
            hostDcName = "//" + this._ddrData.hostTr + ":" + this._ddrData.portTr;
            this.id.testRun = this._ddrData.testRunTr;
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        return hostDcName;
    }
    getHotspotData() {
        let rowData;
        if (this.commonService.hsFlag === true) {
            rowData = this.commonService.hsData;
        }
        let queryParam = '';
        if (this.commonService.enableQueryCaching == 1) {
            queryParam += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun;
        }
        else {
            queryParam += "testRun=" + this.sessionService.session.testRun.id;
        }
        let urlParam = "";
        if (this.commonService.isFilterFromSideBar && Object.keys(this.commonService.hotspotFilters).length != 0) // sidebar filters to hotspot 
         {
            let hsParam = this.commonService.hotspotFilters;
            if (this.commonService.isValidParamInObj(hsParam, 'pubicIP') && this.commonService.isValidParamInObj(hsParam, 'publicPort') && this.commonService.isValidParamInObj(hsParam, 'ndeTestRun')) {
                if (this.commonService.enableQueryCaching == 1) {
                    queryParam = 'cacheId=' + hsParam['ndeTestRun'] + '&testRun=' + hsParam['ndeTestRun'];
                }
                else {
                    queryParam = 'testRun=' + hsParam['ndeTestRun'];
                }
            }
            urlParam = this.commonService.makeParamStringFromObj(hsParam);
            queryParam += urlParam;
            this.ndDdrHttpService.getHotSpotData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["HotspotDataLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                if (error.hasOwnProperty('message')) {
                    this.messageService.showError(error);
                }
                else {
                    if (error.hasOwnProperty('statusText')) {
                        this.messageService.showError(error);
                        console.error("error in getting data from rest call", error);
                    }
                }
            });
        }
        else if (this.id.fromSession === '1' || (this._ddrData.isFromtrxFlow && (!rowData || !rowData.data || rowData.data.length == 0))) {
            let hsParam = this.id;
            if (hsParam["startTime"] || hsParam["endTime"]) {
                hsParam["strStartTime"] = hsParam["startTime"];
                hsParam["strEndTime"] = hsParam["endTime"];
                delete hsParam["startTime"];
                delete hsParam["endTime"];
            }
            urlParam = this.commonService.makeParamStringFromObj(hsParam);
            this.commonService.hotspotFilters = hsParam;
            queryParam += urlParam;
            return this.ndDdrHttpService.getHotSpotData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["HotspotDataLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                if (error.hasOwnProperty('message')) {
                    this.messageService.showError(error);
                }
                else {
                    if (error.hasOwnProperty('statusText')) {
                        this.messageService.showError(error);
                        console.error(error);
                    }
                }
            });
        }
        // ED TO HOTSPOT
        else if (rowData == undefined) // ED TO DDR CASE - ROWDATA WILL BE UNDEFINED
         {
            if (this.id.fpDuration) {
                if (this.id.fpDuration.toString().includes(','))
                    this.id.strEndTime = Number(this.id.startTimeInMs) + Number(this.id.fpDuration.toString().replace(/,/g, ""));
                else if (this.id.fpDuration == '< 1') {
                    this.id.strEndTime = Number(this.id.startTimeInMs) + Number(0);
                }
                else
                    this.id.strEndTime = Number(this.id.startTimeInMs) + Number(this.id.fpDuration);
            }
            else {
                if (this._ddrData.otelMode && this.commonService.isFromSplitView) {
                    this.id.strEndTime = Number(this.id.startTimeInMs) + Math.ceil(this.id.selfResponseTime);
                }
                else {
                    this.id.startTimeInMs = this.id.startTime;
                    this.id.strEndTime = this.id.endTime;
                }
            }
            urlParam = '&tierId=' + this.id.tierId +
                '&appId=' + this.id.appId +
                '&serverId=' + this.id.serverId +
                '&appName=' + this.id.appName +
                '&serverName=' + this.id.serverName +
                '&tierName=' + this.id.tierName +
                '&strStartTime=' + (this.id.startTimeInMS || this.id.startTimeInMs) +
                '&strEndTime=' + (Number(this.id.strEndTimeMS) + 1000 || Number(this.id.strEndTime) + 1000);
            if (this.columnData == undefined) {
                urlParam += '&threadId=' + this.compareFPInfo['threadId'] +
                    '&btCategory=' + this.compareFPInfo['btCatagory'] +
                    '&urlName=' + this.compareFPInfo['urlName'] +
                    '&urlIndex=' + this.compareFPInfo['urlIndex'] +
                    '&flowpathInstance=' + this.compareFPInfo['flowpathInstance'];
            }
            else {
                urlParam += '&btCategory=' + this.id.btCatagory +
                    '&urlName=' + this.id.urlName +
                    '&urlIndex=' + this.id.urlIndex +
                    '&flowpathInstance=' + this.id.flowpathInstance;
                let instanceType = this.id.instanceType || this.columnData.Instance_Type;
                if (instanceType) {
                    if (instanceType === "NodeJS") {
                        urlParam += '&instanceType=' + this.id.Instance_Type || false;
                    }
                    if (instanceType.toLowerCase() !== "dotnet" || instanceType.toLowerCase() !== "dotnetc") {
                        urlParam += '&threadId=' + this.id.threadId;
                    }
                }
                else
                    urlParam += '&threadId=' + this.id.threadId;
            }
            this.commonService.hotspotFilters = this.commonService.makeObjectFromUrlParam(urlParam);
            queryParam += urlParam;
            if (this._ddrData.isFromOtelTrxnServiceMap) {
                this._ddrData.isFromOtelTrxnServiceMap = false;
                queryParam = "";
                queryParam = this._ddrData.otelTrxnServMapHSParam;
                this._ddrData.otelTrxnServMapHSParam = "";
            }
            return this.ndDdrHttpService.getHotSpotData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["HotspotDataLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                if (error.hasOwnProperty('message')) {
                    this.messageService.showError(error);
                }
                else {
                    if (error.hasOwnProperty('statusText')) {
                        this.messageService.showError(error);
                        console.error(error);
                    }
                }
            });
        }
        else {
            //hsData from common service could be data from flowpath-hotspot or transactionflowmap-hotspot.
            return this.doAssignValueHotspot(rowData);
        }
    }
    doAssignValueHotspot(res) {
        this.commonService.isFilterFromSideBar = false;
        this.commonService.hotspotFilters['startTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.startTime), "MM/DD/YYYY HH:mm:ss");
        this.commonService.hotspotFilters['endTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(res.endTime), "MM/DD/YYYY HH:mm:ss");
        if (res.hasOwnProperty('Status')) {
            this.messageService.showError(res.Status);
        }
        this.hotspotData = res.data;
        if (this.hotspotData.length == 0) {
        }
        this.hotspotDataCount = this.hotspotData.length;
        if (this.hotspotData.length != 0) {
            this.mergeData = this.hotspotData;
        }
        if (this.mergeData.length > 1 && (this.commonService.hsFlag == true || Object.keys(this.compareFPInfo).length > 0)) {
            this.mergeFlag = true;
            sessionStorage.setItem("isMerged", "false");
        }
        this.StateCount = res.threadStateCount;
        this.stackDepthCount = res.stackDepthCount;
        if (this.hotspotData.length > 10) { //If data is less then 10 then no pagination .
            this.showPagination = true;
        }
        else {
            this.showPagination = false;
        }
        if (this.hotspotData.length == 0) //If no data found. blank stack trace table
         {
            this.hotSpotInfo = [];
            this.hotSpotSecInfo = [];
            this.IPInfo = [];
            this.aggIpInfo = [];
            this.stackTraceFilter = "";
            this.empty = true;
        }
        else {
            this.ShowFilterCriteria();
            this.hotSpotInfo = this.getHotspotInfo();
            this.threadinfo = this.hotSpotInfo;
            this.createPieChart(this.StateCount);
            this.createBarChart(this.stackDepthCount);
        }
    }
    createPieChart(data) {
        this.chartData = data;
        var ThreadInfoArr = [];
        var keys = Object.keys(this.chartData[0]);
        var count = this.chartData[0];
        for (var j = 0; j < keys.length; j++) {
            if (count[keys[j]] != 0) {
                if (keys[j] == 'WAITING') {
                    ThreadInfoArr.push({
                        color: '#FFFF00',
                        "name": keys[j],
                        "y": Number(count[keys[j]])
                    });
                }
                else if (keys[j] == 'RUNNABLE' || keys[j] == 'Running') {
                    ThreadInfoArr.push({
                        color: '#00FF00',
                        "name": keys[j],
                        "y": Number(count[keys[j]])
                    });
                }
                else if (keys[j] == 'BLOCKED') {
                    ThreadInfoArr.push({
                        color: '#FF0000',
                        "name": keys[j],
                        "y": Number(count[keys[j]])
                    });
                }
                else if (keys[j] == 'TIMED_WAITING') {
                    ThreadInfoArr.push({
                        color: '#FFD700',
                        "name": keys[j],
                        "y": Number(count[keys[j]])
                    });
                }
                else if (keys[j] == 'NEW') {
                    ThreadInfoArr.push({
                        color: '#ADFF2F',
                        "name": keys[j],
                        "y": Number(count[keys[j]])
                    });
                }
                else if (keys[j] == 'TERMINATED') {
                    ThreadInfoArr.push({
                        color: '#8B0000',
                        "name": keys[j],
                        "y": Number(count[keys[j]])
                    });
                }
            }
        }
        this.options = {
            chart: {
                type: 'pie',
            },
            credits: {
                enabled: false
            },
            legend: {
                itemWidth: 300,
            },
            title: { text: 'Hotspot Threads By State', style: { 'fontSize': '13px' } },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
            },
            plotOptions: {
                pie: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    dataLabels: {
                        enabled: false,
                        format: '<b> {point.name} </b>: {point.percentage:.2f} %',
                    },
                    showInLegend: true
                }
            },
            exporting: {
                enabled: false
            },
            series: [
                {
                    name: 'Percentage',
                    data: ThreadInfoArr,
                    enableMouseTracking: true
                }
            ]
        };
    }
    clickHandler(event) {
        this.showAllOption = true;
        let filteredhotspotdata = [];
        this.threadinfo.forEach((val, index) => {
            if (val['threadstate'] == event.point.name) {
                filteredhotspotdata.push(val);
            }
        });
        if (filteredhotspotdata.length > 0) {
            this.hotSpotInfo = filteredhotspotdata;
            this.passDataForStackTrace(filteredhotspotdata[0]);
            this.selectItem = filteredhotspotdata[0];
        }
    }
    createBarChart(data) {
        this.Barinfo = data;
        let Stackdeptharr = [];
        let xaxisarr = [];
        let keys = Object.keys(this.Barinfo);
        for (let i = 0; i < keys.length; i++) {
            Stackdeptharr.push({ "name": keys[i], "y": Number(this.Barinfo[keys[i]]) });
            xaxisarr.push(keys[i]);
        }
        this.options1 = {
            chart: {
                type: 'column'
            },
            title: { text: 'Hotspot Threads By Stack Depth', style: { 'fontSize': '13px' } },
            credits: {
                enabled: false
            },
            subtitle: {
                text: ''
            },
            xAxis: {
                crosshair: true,
                categories: xaxisarr,
                title: {
                    text: 'StackDepth'
                }
            },
            yAxis: {
                min: 0,
                allowDecimals: false,
                title: {
                    text: 'Count'
                }
            },
            tooltip: {
                headerFormat: '<table><tr><td style="color:{series.color};padding:0">StackDepth:</td>' + '<td style="padding:0"><b>{point.key}</b></td></tr>',
                pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
                    '<td style="padding:0"><b>{point.y}</b></td></tr>',
                footerFormat: '</table>',
                shared: true,
                useHTML: true
            },
            plotOptions1: {
                column: {
                    pointPadding: 0.2,
                    borderWidth: 0
                }
            },
            exporting: {
                enabled: false
            },
            series: [
                {
                    name: 'Count',
                    enableMouseTracking: true,
                    data: Stackdeptharr,
                    pointWidth: 25
                }
            ],
        };
    }
    Refresh() {
        this.showAllOption = false;
        this.hotSpotInfo = this.threadinfo;
        this.createPieChart(this.StateCount);
        this.passDataForStackTrace(this.hotSpotInfo[0]);
        this.selectItem = this.hotSpotInfo[0];
        this.createBarChart(this.stackDepthCount);
    }
    getHotspotInfo() {
        let arrHotSpotData = [];
        let totalHSDuration = "0";
        let tempTierId = "";
        let tempServerId = "";
        let tempAppId = "";
        let tempid = 0;
        for (let i = 0; i < this.hotspotData.length; i++) {
            if (i == 0) //for first time thread header information in table
             {
                this.passDataForStackTrace(this.hotspotData[i]);
                this.selectItem = this.hotspotData[i];
            }
            if (tempid == 0) {
                tempTierId = this.hotspotData[i]["tierid"];
                tempServerId = this.hotspotData[i]["serverid"];
                tempAppId = this.hotspotData[i]["appid"];
                tempid = this.hotspotData[i]["threadid"];
            }
            if (tempTierId == this.hotspotData[i]["tierid"] && tempServerId == this.hotspotData[i]["serverid"] && tempAppId == this.hotspotData[i]["appid"] && tempid == this.hotspotData[i]["threadid"]) {
                totalHSDuration = (Number(totalHSDuration) + Number(this.hotspotData[i]["hotspotduration"])).toFixed(3);
            }
            else {
                totalHSDuration = "0";
                tempTierId = this.hotspotData[i]["tierid"];
                tempServerId = this.hotspotData[i]["serverid"];
                tempAppId = this.hotspotData[i]["appid"];
                tempid = this.hotspotData[i]["threadid"];
                totalHSDuration = (Number(totalHSDuration) + Number(this.hotspotData[i]["hotspotduration"])).toFixed(3);
            }
            let totalhsDuration = totalHSDuration;
            let hsDur = this.hotspotData[i]["hotspotduration"];
            arrHotSpotData[i] = { tierid: this.hotspotData[i]["tierid"], serverid: this.hotspotData[i]["serverid"], appid: this.hotspotData[i]["appid"], threadid: this.hotspotData[i]["threadid"], hotspotstarttimestamp: this.sessionService.convertTimestampIntoFormattedString(Number(this.hotspotData[i]["hsTimeInMs"]), "MM/DD/YYYY HH:mm:ss"), hotspotduration: Number(hsDur), threadstate: this.hotspotData[i]["threadstate"], threadpriority: this.hotspotData[i]["threadpriority"], threadstackdepth: this.hotspotData[i]["threadstackdepth"], FlowPathInstance: this.hotspotData[i]["FlowPathInstance"], threadname: this.hotspotData[i]["threadname"], hsTimeInMs: this.hotspotData[i]["hsTimeInMs"], toolTipTextForHsDur: this.hotspotData[i]["toolTipTextForHsDur"], hsDurationInMs: this.hotspotData[i]["hsDurationInMs"], hotspotElapsedTime: this.hotspotData[i]["hotspotElapsedTime"], strStartTime: this.hotspotData[i]["strStartTime"], strEndTime: this.hotspotData[i]["strEndTime"], instanceType: this.hotspotData[i]["instanceType"], tierName: this.hotspotData[i]["tierName"], serverName: this.hotspotData[i]["serverName"], appName: this.hotspotData[i]["appName"], totalDuration: Number(totalhsDuration) };
        }
        return arrHotSpotData;
    }
    passDataForStackTrace(data) {
        this.removeColField();
        this.selectedHotspot = data;
        //dynamic creation for stack trace header info
        this.stackTraceFilter = `( Thread Id: ${data.threadid}, Hotspot EntryTime: ${this.sessionService.convertTimestampIntoFormattedString(Number(data.hsTimeInMs), "MM/DD/YYYY HH:mm:ss")} , Hotspot Duration: ${data.hotspotduration} seconds)`;
        this.stackTraceFilterToolTip = `Thread Id: ${data.threadid} \nThread Name: ${data.threadname} \nHotSpot EntryTime: ${this.sessionService.convertTimestampIntoFormattedString(Number(data.hsTimeInMs), "MM/DD/YYYY HH:mm:ss")} \nHotspot Duration: ${data.hotspotduration} seconds`;
        this.filterCriteriaagg = this.stackTraceFilter;
        let second_queryParam = '';
        let IP_queryParam = '';
        if (this.commonService.enableQueryCaching == 1) {
            second_queryParam += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierId=" + data.tierid + "&serverId=" +
                data.serverid + "&appId=" + data.appid + "&threadId=" + data.threadid + "&hsTimeInMs=" + data.hsTimeInMs +
                "&hotSpotDuration=" + data.hsDurationInMs + '&instanceType=' + data.instanceType + '&tierName=' + data.tierName;
            IP_queryParam += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierId=" + data.tierid + "&serverId=" + data.serverid + "&appId=" + data.appid + "&startTime=" + this.sessionService.convertTimestampIntoFormattedString(Number(data.hsTimeInMs), "MM/DD/YYYY HH:mm:ss") + "&hsDuration=" + data.hsDurationInMs + "&strStartTime=" + this.id.startTime + "&strEndTime=" + (Number(this.id.endTime) + 1000) + '&tierName=' + data.tierName;
        }
        else {
            second_queryParam += "testRun=" + this.id.testRun + "&tierId=" + data.tierid + "&serverId=" +
                data.serverid + "&appId=" + data.appid + "&threadId=" + data.threadid + "&hsTimeInMs=" + data.hsTimeInMs +
                "&hotSpotDuration=" + data.hsDurationInMs + '&instanceType=' + data.instanceType + '&tierName=' + data.tierName;
            IP_queryParam += "testRun=" + this.sessionService.session.testRun.id + "&tierId=" + data.tierid + "&serverId=" + data.serverid + "&appId=" + data.appid + "&startTime=" + this.sessionService.convertTimestampIntoFormattedString(Number(data.hsTimeInMs), "MM/DD/YYYY HH:mm:ss") + "&hsDuration=" + data.hsDurationInMs + "&strStartTime=" + this.id.startTime + "&strEndTime=" + (Number(this.id.endTime) + 1000) + '&tierName=' + data.tierName;
        }
        if ((data.instanceType && data.instanceType.toLowerCase() !== "dotnet") || (data.instanceType && data.instanceType.toLowerCase() !== "dotnetc")) {
            IP_queryParam += '&threadId=' + data.threadid + '&tierName=' + data.tierName;
        }
        if (data.instanceType && data.instanceType == "NodeJS") {
            IP_queryParam += '&flowpathInstance=' + data.FlowPathInstance + '&tierName=' + data.tierName;
            second_queryParam += '&flowpathInstance=' + data.FlowPathInstance + '&tierName=' + data.tierName;
        }
        else if (this._ddrData.splitViewFlag || this.commonService.hsFlag) {
            IP_queryParam += '&flowpathInstance=' + this.commonService.hotspotFilters['flowpathInstance'] + '&tierName=' + this.commonService.hotspotFilters['tierName'];
            second_queryParam += '&flowpathInstance=' + this.commonService.hotspotFilters['flowpathInstance'] + '&tierName=' + this.commonService.hotspotFilters['tierName'];
        }
        this.getHotspotSecData(second_queryParam); // Pass the URL to get Response from Rest service
        this.getbackendData(IP_queryParam);
    }
    removeColField() {
        if (this.colsForStackTrace[4]) {
            this.colsForStackTrace[4].width = '250';
        }
        if (this.colsForStackTrace[6] != undefined) {
            this.colsForStackTrace.pop();
        }
    }
    getHotspotSecData(queryParam) {
        this.ndDdrHttpService.getStackTraceData(queryParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["StackTraceDataLoadedState"]) {
                this.doAssignValueSecHotspot(state.data);
            }
        }, (error) => {
            if (error.hasOwnProperty('message')) {
                this.messageService.showError(error);
            }
            else {
                if (error.hasOwnProperty('statusText')) {
                    this.messageService.showError(error);
                    console.error(error);
                }
            }
        });
    }
    doAssignValueSecHotspot(res) {
        this.hotspotSecData = res.treedata;
        this.hotSpotSecInfo = res.treedata;
        this.downloadJSON = res.downloadJSON;
        this.mergeDataDownloadFlag = false;
    }
    // Store value fot thread stack trace data
    getHotspotSecInfo() {
        var arrHotSpotSecData = [];
        for (let i = 0; i < this.hotspotSecData.length; i++) {
            arrHotSpotSecData[i] = { 0: this.hotspotSecData[i]["0"], 1: this.hotspotSecData[i]["1"], 2: this.hotspotSecData[i]["2"], 3: this.hotspotSecData[i]["3"], 4: (i + 1), 5: this.hotspotSecData[i]["5"], 6: this.hotspotSecData[i]["6"], 7: this.hotspotSecData[i]["7"] };
        }
        return arrHotSpotSecData;
    }
    getbackendData(queryParam) {
        this.ndDdrHttpService.getBackendNameHotspot(queryParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["BackendNameHotspotLoadedState"]) {
                this.doAssignValueBackendData(state.data);
            }
        }, (error) => {
            if (error.hasOwnProperty('message')) {
                this.messageService.showError(error);
            }
            else {
                if (error.hasOwnProperty('statusText')) {
                    this.messageService.showError(error);
                    console.error('Error return from getBackendNameHotspot ~ ', error);
                }
            }
        });
    }
    doAssignValueBackendData(data) {
        this.renamebackendNameMap = data.renamebackendNameMap;
        this.actualBackendNameMap = data.actualBackendNameMap;
        this.backendSubTypeNameMap = data.backendSubTypeNameMap;
        let backendInfoList = data.backendInfoList;
        this.backendData = backendInfoList;
        if (data.aggDataForBackends && Object.keys(data.aggDataForBackends).length != 0) {
            this.aggCase = true;
            this.aggIpInfo = data.aggDataForBackends;
        }
        else {
            this.aggCase = false;
            this.IPInfo = this.getIPinfo();
            if (this.IPInfo.length > 10) { //If data is less then 10 then no pagination .
                this.showPaginationIP = true;
            }
            else {
                this.showPaginationIP = false;
            }
        }
    }
    getIPinfo() {
        var arrbackendData = [];
        for (var i = 0; i < this.backendData.length; i++) {
            arrbackendData[i] = {
                renamebackendIPname: this.renamebackendNameMap[this.backendData[i]["backendId"]],
                actualbackendIPname: this.actualBackendNameMap[this.backendData[i]["backendId"]].replace(/&#46;/g, '.'),
                backendType: this.BackendTypeName(this.backendData[i]["backendType"]),
                backendDuration: this.backendData[i]["backendDuration"],
                backendStartTime: this.backendData[i]["backendStartTime"],
                errorCount: this.HotspotStatus(this.backendData[i]["errorCount"]),
                Query: this.commonService.getBackendSubType(this.backendData[i]["backendSubType"], this.backendSubTypeNameMap),
                starttimeInMs: this.backendData[i]["starttimeInMs"],
                fpInstance: this.backendData[i]["fpInstance"],
                seqNumber: this.backendData[i]["seqNumber"],
                backendId: this.backendData[i]["backendId"],
                backendSubType: this.backendData[i]["backendSubType"],
                networkreq: this.commonService.formatterFixed(this.backendData[i]["networkreq"]),
                networkres: this.commonService.formatterFixed(this.backendData[i]["networkres"]),
            };
        }
        return arrbackendData;
    }
    openIPHealthScreen(nodeData) {
        this.commonService.hotspotToIP = true;
        this._ddrData.splitViewFlag = false;
        this.commonService.hotspotToIPData = nodeData;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].HOTSPOT;
        if (this._router.url.indexOf('/home/ddrCopyLink') != -1) {
            this._router.navigate(['/home/ddrCopyLink/IpStatComponent']);
        }
        else {
            this._router.navigate(['/ddr/IpStatComponent']);
        }
    }
    openFPReport(rowData) {
        let reqData = {};
        if (rowData != undefined) {
            let threadId = "NA";
            if (rowData.instanceType.toLowerCase() != 'dotnet' || rowData.instanceType.toLowerCase() != 'dotnetc')
                threadId = rowData.threadid;
            var flowpathEndTime = (Number(rowData.hsTimeInMs) + Number(rowData.hsDurationInMs)).toString();
            reqData["hsEndTime"] = (Number(rowData.hsTimeInMs) + Number(rowData.hsDurationInMs) + 900000).toString();
            reqData["tierId"] = rowData.tierid;
            reqData["serverId"] = rowData.serverid;
            reqData["appId"] = rowData.appid;
            reqData["tierName"] = this.id.tierName;
            reqData["serverName"] = this.id.serverName;
            reqData["appName"] = this.id.appName;
            reqData["threadId"] = threadId;
            reqData["hsTimeInMs"] = rowData.hsTimeInMs;
            reqData["flowpathEndTime"] = flowpathEndTime;
        }
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].HOTSPOT;
        this.commonService.hstofpData = reqData;
        this._ddrData.FromhsFlag = 'true';
        if (this._router.url.indexOf("/home/ddrCopyLink/") != -1)
            this._router.navigate(['/home/ddrCopyLink/flowpath']);
        else
            this._router.navigate(['/ddr/flowpath']);
    }
    //This function is used to set backendtype according to the type
    BackendTypeName(backendType) {
        var backendTypeName = "OTHER";
        if (backendType == 1)
            return "HTTP";
        else if (backendType == 2)
            return "JDBC";
        else if (backendType == 3)
            return "COHERENCE";
        else if (backendType == 4)
            return "RMI";
        else if (backendType == 5)
            return "MemCache";
        else if (backendType == 6)
            return "CLOUDANT";
        else if (backendType == 7)
            return "HADOOP";
        else if (backendType == 9)
            return "CASSANDRA";
        else if (backendType == 10)
            return "DB";
        else if (backendType == 14)
            return "JMSP";
        else if (backendType == 15)
            return "DATABASE";
        else if (backendType == 16)
            return "DATABASE";
        return backendTypeName;
    }
    // This Function is used to set value in Status
    HotspotStatus(errorCount) {
        if (errorCount == false)
            return 'Success';
        else
            return 'Error';
    }
    viewExceptionReport(rowData) {
        let errorData = {};
        errorData["tierId"] = this.selectedHotspot.tierid;
        errorData["serverId"] = this.selectedHotspot.serverid;
        errorData["appId"] = this.selectedHotspot.appid;
        errorData["tierName"] = this.selectedHotspot.tierName;
        errorData["serverName"] = this.selectedHotspot.serverName;
        errorData["appName"] = this.selectedHotspot.appName;
        errorData["backendId"] = rowData.backendId;
        errorData["fpInst"] = rowData.fpInstance;
        errorData["seqno"] = rowData.seqNumber;
        errorData["backendSubType"] = rowData.backendSubType;
        if (this.id.startTimeInMs != undefined) {
            errorData["startTime"] = this.id.startTimeInMs - 90000;
            if (!this._ddrData.otelMode)
                errorData['endTime'] = Number(this.id.startTimeInMs) + Number(this.id.fpDuration) + 90000;
            else
                errorData['endTime'] = Number(this.id.startTimeInMs) + Math.ceil(this.id.selfResponseTime) + 90000;
        }
        else {
            errorData["startTime"] = this.id.startTime;
            errorData['endTime'] = this.id.endTime;
        }
        this._ddrData.splitViewFlag = false;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].HOTSPOT;
        this.commonService.hstoexData = errorData;
        this._ddrData.flowpathToExFlag = false;
        this.commonService.fromhstoExpFlag = true;
        this.commonService.hsDataFromED = this.id;
        if (this._router.url.indexOf("/home/ddrCopyLink/") != -1)
            this._router.navigate(['/home/ddrCopyLink/exception']);
        else
            this._router.navigate(['/ddr/exception']);
    }
    /**
     * Merge All StackTrace
     */
    mergeAllStackTrace() {
        if (this.colsForStackTrace[6] == undefined) {
            this.colsForStackTrace.push({ field: 'count', header: 'Count', sortable: false, action: true, align: 'right', width: '20' });
            this.visibleColsForStackTrace.push('count');
            this.columnOptionsForStackTrace = this.colsForStackTrace;
        }
        if (sessionStorage.getItem("isMerged") == "true") {
        }
        else {
            let timeArr = [];
            let durArr = [];
            for (let i = 0; i < this.mergeData.length; i++) {
                timeArr.push(this.sessionService.convertTimestampIntoFormattedString(Number(this.mergeData[i].hsTimeInMs), "MM/DD/YYYY HH:mm:ss"));
                durArr.push(this.mergeData[i].hsDurationInMs);
            }
            let startTime = timeArr.toString();
            let hsDuration = durArr.toString();
            let cmdArgs = "";
            cmdArgs = "--testrun " + this.id.testRun +
                " --TierID " + this.mergeData[0].tierid +
                " --ServerID " + this.mergeData[0].serverid +
                " --AppID " + this.mergeData[0].appid +
                " --ThreadId " + this.mergeData[0].threadid;
            let queryParam = "";
            queryParam += "cmdArgs=" + cmdArgs + "&hsStartTime=" + startTime + "&hsDuration=" + hsDuration;
            this.ndDdrHttpService.getHotspotMergeData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["HotspotMergeDataLoadedState"]) {
                    this.doAssignMergeAllStackTraceData(state.data);
                }
            }, (error) => {
                this.messageService.showError(error);
                console.error(error);
            });
        }
    }
    doAssignMergeAllStackTraceData(data) {
        this.hotspotSecData = data.treedata;
        this.hotSpotSecInfo = data.treedata;
        this.downloadJSON = data.downloadJSON;
        this.mergeDataDownloadFlag = true;
    }
    ShowFilterCriteria() {
        this.filterCriteria = "";
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        this.filterDCName = '';
        let hsParams = this.commonService.hotspotFilters;
        let dcName = "";
        dcName = this.selectedDC;
        if (this.commonService.isValidParamInObj(hsParams, "tierName")) {
            if (hsParams['tierName'].length > 32) {
                this.filterTierName += 'Tier=' + hsParams['tierName'].substring(0, 32) + '...';
                this.completeTier = hsParams['tierName'];
            }
            else
                this.filterTierName += 'Tier=' + hsParams['tierName'];
        }
        if (this.commonService.isValidParamInObj(hsParams, "serverName")) {
            if (hsParams['serverName'].length > 32) {
                this.filterServerName = ', Server=' + hsParams['serverName'].substring(0, 32) + '...';
                this.completeServer = hsParams['serverName'];
            }
            else
                this.filterServerName = ', Server=' + hsParams['serverName'];
        }
        if (this.commonService.isValidParamInObj(hsParams, "appName")) {
            if (hsParams['appName'].length > 32) {
                this.filterInstanceName = ', Instance=' + hsParams['appName'].substring(0, 32) + '...';
                this.completeInstance = hsParams['appName'];
            }
            else
                this.filterInstanceName = ', Instance=' + hsParams['appName'];
        }
        if (this.commonService.isValidParamInObj(hsParams, "startTimeInDateFormat")) {
            this.filterCriteria += ', StartTime=' + hsParams['startTimeInDateFormat'];
        }
        if (this.commonService.isValidParamInObj(hsParams, "endTimeInDateFormat")) {
            this.filterCriteria += ', EndTime=' + hsParams['endTimeInDateFormat'];
        }
        if (this.commonService.isValidParamInObj(hsParams, "script")) {
            this.filterCriteria += ', Script Name=' + hsParams['script'];
        }
        if (this.commonService.isValidParamInObj(hsParams, "pageName")) {
            this.filterCriteria += ', Page Name=' + hsParams['pageName'];
        }
        if (this.commonService.isValidParamInObj(hsParams, "transactionName")) {
            this.filterCriteria += ', Transaction Name=' + hsParams['transactionName'];
        }
        if (this.commonService.isValidParamInObj(hsParams, "generatorName")) {
            this.filterCriteria += ', Generator Name=' + hsParams['generatorName'];
        }
        if (!this.commonService.isValidParamInObj(hsParams, "tierName") && !this.commonService.isValidParamInObj(hsParams, "serverName") && !this.commonService.isValidParamInObj(hsParams, "appName") && this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
        this.filterCriteriaArray = this.filterCriteria
            .split(',')
            .map(item => item.trim())
            .filter(item => item.length > 0);
        console.log('filterCriteriaArray:', this.filterCriteriaArray);
        console.log('filterCriteria after substring:', this.filterCriteria);
    }
    Querypop(nodeInfo) {
        var arr = [];
        this.displayPopUp = true;
        arr.push({ "IPname": nodeInfo.renamebackendIPname, "DiscoveredIPName": nodeInfo.actualbackendIPname, "Type": nodeInfo.backendType, "StartTime": nodeInfo.backendStartTime, "Duration": nodeInfo.backendDuration, "Status": nodeInfo.errorCount, "Query": nodeInfo.Query });
        this.rowData = arr;
    }
    //this toggle is used for tree -table
    toggleColumnFilterForHotspot1() {
        this.isEnabledColumnFilterForHotspot1 = !this.isEnabledColumnFilterForHotspot1;
        this.changeColumnFilterForHotSpot1();
    }
    // this columnfilter is used for tree-table
    changeColumnFilterForHotSpot1() {
        try {
            let tableColumns = this.colsForHotspot;
            if (!this.isEnabledColumnFilterForHotspot1) {
                this.toggleFilterTitleForHotSpot1 = 'Show Column Filters';
                for (let i = 0; i < tableColumns.length; i++) {
                    tableColumns[i].filter = false;
                }
            }
            else {
                this.toggleFilterTitleForHotSpot1 = 'Hide Column Filters';
                for (let i = 0; i < tableColumns.length; i++) {
                    tableColumns[i].filter = true;
                }
            }
        }
        catch (error) {
            console.log('Error while Enable/Disabled column filters', error);
        }
    }
    ngOnDestroy() {
        if (this.commonService.isFromSplitView) {
            this._ddrData.splitViewFlag = true;
            this.commonService.isToLoadSideBar = false;
        }
        this.breadcrumb['items'].pop();
        this.sideBarHotspot.unsubscribe();
    }
    onTabOpen(event) {
        if (this._ddrData.splitViewFlag == true)
            this.tableHeight = this.tableHeight - 190;
        else
            this.tableHeight = this.tableHeight - 230;
    }
    onTabClose(event) {
        if (this._ddrData.splitViewFlag == true)
            this.tableHeight = this.tableHeight + 190;
        else
            this.tableHeight = this.tableHeight + 230;
    }
};
HotspotComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_4__["CommonServices"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_13__["CavMessageService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_1__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_9__["BreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__["SessionService"] },
    { type: src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_12__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], HotspotComponent.prototype, "columnData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])('value')
], HotspotComponent.prototype, "compareFPInfo", void 0);
HotspotComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Component"])({
        selector: 'app-hotspot',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./hotspot.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/hotspot/hotspot.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./hotspot.component.css */ "./src/app/pages/ddr/components/hotspot/hotspot.component.css")).default]
    })
], HotspotComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.scss":
/*!*********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.scss ***!
  \*********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.ts":
/*!*******************************************************************************!*\
  !*** ./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.ts ***!
  \*******************************************************************************/
/*! exports provided: HttpReqRespComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "HttpReqRespComponent", function() { return HttpReqRespComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! moment */ "./node_modules/moment/moment.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! moment-timezone */ "./node_modules/moment-timezone/index.js");
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");












let HttpReqRespComponent = class HttpReqRespComponent {
    constructor(commonService, _ddrData, sessionService, breadcrumb, ndDdrHttpService, elasticSearchService) {
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.elasticSearchService = elasticSearchService;
        this.filterCriteria = "";
        this.filterCriteriaArray = [];
        this.filterCriteriaToolTip = "";
        this.ForFooterUrl = "";
        this.httpInfoArr = [];
        this.httpRequestArr = [];
        this.httpRequestArrBody = [];
        this.httpResponseArr = [];
        this.httpResponseArrBody = [];
        this.httpDerivedArr = [];
        this.httpSessionArr = [];
        this.httpConditionArr = [];
        this.colshttpInfoArr = [];
        this.isHttpInfoData = true;
        this.isSessionData = true;
        this.isRequestHeaders = true;
        this.isRequestBody = true;
        this.isResponseHeaders = true;
        this.isResponseBody = true;
        this.isCustomData = true;
        this.isConditionData = true;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.rows = '10';
        this.breadcrumb = breadcrumb;
        this.otelMode = this._ddrData.otelMode;
        this.relativePath = "ddr/httpReport/httpInfoArr.json";
    }
    ngOnChanges() {
        var _a;
        if (this._ddrData.splitViewBreadCrumbFlag && this._ddrData.splitViewFlag) {
            this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            this.breadcrumb.add({ label: 'HTTP' });
        }
        else {
            this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            this.breadcrumb.add({ label: 'HTTP' });
            this._ddrData.splitViewBreadCrumbFlag = true;
        }
        if (this._ddrData.splitViewFlag)
            this._ddrData.setInLogger("DDR:Flowpath", "Http Request and Response", "Open Http Request and Response Report");
        if (this.columnData != undefined) {
            this.loading = true;
            this.commonService.httpData = JSON.parse(JSON.stringify(this.columnData));
            this.id = this.commonService.getData();
            if (this.id.enableQueryCaching)
                this.commonService.enableQueryCaching = this.id.enableQueryCaching;
            this.commonService.httpData.fpInstance = this.commonService.httpData.flowpathInstance;
            if (this.commonService.httpData['fpDuration'] == '< 1') {
                this.commonService.httpData.fpDuration = 0;
            }
            else if ((_a = this.commonService.httpData['fpDuration']) === null || _a === void 0 ? void 0 : _a.toString().includes(',')) {
                this.commonService.httpData.fpDuration = this.commonService.httpData.fpDuration.toString().replace(/,/g, "");
            }
            this.commonService.httpData.strEndTime = Number(this.commonService.httpData.startTimeInMs) + Number(this.commonService.httpData.fpDuration);
            if (!this.otelMode) {
                this.commonService.httpData.strEndTime = Number(this.commonService.httpData.startTimeInMs) + Number(this.commonService.httpData.fpDuration);
            }
            else {
                this.commonService.httpData.strEndTime = Number(this.commonService.httpData.startTimeInMs) + Math.ceil(this.commonService.httpData.selfResponseTime);
            }
            this.randomNumber();
            this.gethttpReportData();
        }
    }
    ngOnInit() {
        this.loading = true;
        this.screenHeight = Number(this.commonService.screenHeight) - 140;
        if (this._ddrData.splitViewFlag == false) {
            this.breadcrumb.add({ label: 'HTTP', routerLink: '/ddr/httpReqResp' });
            this.id = this.commonService.getData();
        }
        this.commonService.isToLoadSideBar = false;
        if (this.commonService.testRun != undefined && this.commonService.testRun != null && this.commonService.testRun != '') {
            this.id.testRun = this.id.testRun;
        }
        this.relativePathForCols = "ddr/httpReport/httpReportCol.json";
        this.randomNumber();
        if (this._ddrData.splitViewFlag == false)
            this.gethttpReportData();
    }
    /**
     * Rest call for getting http Report data
     */
    gethttpReportData() {
        let queryParams;
        let startTime;
        let endTime;
        if (this.commonService.httpFlag === true) {
            if (!this.commonService.httpData) {
                this.commonService.httpData = this._ddrData.httpData;
            }
            queryParams = this.commonService.httpData;
            startTime = queryParams.startTimeInMs;
            endTime = queryParams.strEndTime;
        }
        else {
            queryParams = this.id;
            startTime = this.id.startTime;
            endTime = this.id.endTime;
        }
        let urlParams = '';
        if (this.commonService.enableQueryCaching == 1) {
            urlParams += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&fpInstance=" + queryParams.fpInstance + "&tierName=" + queryParams.tierName + "&serverName=" + queryParams.serverName + "&appName=" + queryParams.appName + "&statusCode=" + queryParams.statusCode +
                '&strStartTime=' + startTime + '&strEndTime=' + (Number(endTime) + 1000) + '&queryId=' + this.queryId;
        }
        else {
            urlParams += "testRun=" + this.id.testRun + "&fpInstance=" + queryParams.fpInstance + "&tierName=" + queryParams.tierName + "&serverName=" + queryParams.serverName + "&appName=" + queryParams.appName + "&statusCode=" + queryParams.statusCode +
                '&strStartTime=' + startTime + '&strEndTime=' + (Number(endTime) + 1000) + '&queryId=' + this.queryId;
        }
        if (this.otelMode) {
            urlParams += `&traceId=${queryParams.TraceId}&serviceName=${queryParams.serviceName}`;
        }
        this.isCancelQuerydata = false;
        //commenting for now TBD: Query Cancellation
        // setTimeout(() => {
        //   this.openpopup();
        // }, this._ddrData.guiCancelationTimeOut);
        if (!this.otelMode) {
            this.fetchDataFromPsql(urlParams);
        }
        else {
            this.fetchDataFromElasticSearch(urlParams);
        }
    }
    fetchDataFromPsql(urlParams) {
        this.ndDdrHttpService.getHttpReqResData(urlParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["HttpReportLoadedState"]) {
                this.doAssignHttpReportValue(state.data);
                this.loading = false;
            }
        }, (error) => {
            console.error('Error fetching HTTP Report response ~ ', error);
            this.httpInfoArr = [];
            this.httpRequestArr = [];
            this.httpResponseArr = [];
            this.loading = false;
        });
    }
    /**
    * Fetches data from Elasticsearch using the specified query parameters.
    *
    * @param urlParams The query parameters to use when constructing the query.
    */
    fetchDataFromElasticSearch(urlParams) {
        let reqPayload = {};
        if (this.elasticSearchService.isFromOtelTrxnServiceMap) {
            this.elasticSearchService.isFromOtelTrxnServiceMap = false;
            reqPayload = this.elasticSearchService.getTrxServiceMapPayload();
        }
        else {
            reqPayload = this.ndDdrHttpService.createPayloadForPOSTCall(urlParams);
        }
        if (window['logLevel'] > 1) {
            console.log("********reqPayload******", reqPayload);
        }
        const resFields = [
            "trace_id",
            "span_id",
            "@timestamp",
            "duration",
            "attributes.cav.*",
            "attributes.http.*",
            "resource.attributes.service.name",
            "resource.attributes.host.name",
            "resource.attributes.service.instance.id",
            "resource.attributes.process.pid"
        ];
        const elasticQuery = this.elasticSearchService.buildElasticSearchQuery(reqPayload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_11__["BREADCRUMB_ITEMS"].HTTPREPORT);
        if (window['logLevel'] > 1) {
            console.log("********elasticQuery******", elasticQuery);
        }
        const dataSubscription = this.elasticSearchService.search(elasticQuery).subscribe(res => {
            this.elasticSearchData = res;
            if (window['logLevel'] > 1) {
                console.log('Search results from Elasticsearch:', res);
            }
            this.processElasticData(this.elasticSearchData);
        }, error => {
            console.error('Error searching Elasticsearch:', error);
            this.httpInfoArr = [];
            this.loading = false;
        });
    }
    /**
    * Processes the Elasticsearch response for the HTTP report (OTEL Mode).
    * It extracts request and response headers from the first hit in the ES result.
    */
    processElasticData(elasticData) {
        this.commonService.isFilterFromSideBar = false;
        this.ForFooterUrl = '';
        this.ForFooterUrl += "URL=" + this.commonService.httpData.urlQueryParamStr.replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
        // Ensure data exists and contains hits
        if (elasticData && elasticData.hits && elasticData.hits.hits && elasticData.hits.hits.length > 0) {
            // Get the first _source object from the hits array
            const source = elasticData.hits.hits[0]._source;
            if (this.otelMode && source) {
                // Use OTEL-based methods to extract headers
                this.httpRequestArr = this.buildRequestHeadersFromES(source);
                this.httpResponseArr = this.buildResponseHeadersFromES(source);
                this.httpInfoArr = this.buildHttpInfoFromES(source);
                this.filterCriteria = this.elasticSearchService.filtercriteria;
                // Split by comma, trim spaces, and filter out empty values
                this.filterCriteriaArray = this.filterCriteria
                    .split(',')
                    .map(item => item.trim())
                    .filter(item => item.length > 0);
            }
            else {
                // Fallback if OTEL is disabled or no source found
                this.httpRequestArr = [];
                this.httpResponseArr = [];
                this.httpInfoArr = [];
            }
            // Final state updates
            this.loading = false;
            // Optional debug logs
            if (window['logLevel'] > 1) {
                console.log("HTTP Request Headers (OTEL):", this.httpRequestArr);
                console.log("HTTP Response Headers (OTEL):", this.httpResponseArr);
                console.log("HTTP Info (OTEL):", this.httpInfoArr);
            }
        }
        else {
            // No valid hits in response
            this.httpRequestArr = [];
            this.httpResponseArr = [];
            this.loading = false;
        }
    }
    doAssignHttpReportValue(res) {
        var _a, _b, _c, _d, _e, _f, _g;
        this.isCancelQuerydata = true;
        if (res === null || res === undefined) {
            this.loading = false;
            return;
        }
        if (res.hasOwnProperty('Status')) {
            if (res.Status !== "" && res.Status !== "NA" && res.Status !== 'undefined' && res.Status !== undefined) {
                this.commonService.showError(res.Status);
            }
        }
        this.mainData = res;
        this.loading = false;
        this.httpInfoArr = res.httpInfo;
        this.httpInfoArr.forEach((val, index) => {
            val.StatusCode = val.StatusCode === '0' ? '-' : val.StatusCode;
        });
        let startTimeFormat = this.sessionService.convertTimestampIntoFormattedString(Number(res.strStartTime), "MM/DD/YYYY HH:mm:ss");
        let endTimeFormat = this.sessionService.convertTimestampIntoFormattedString(Number(res.strEndTime), "MM/DD/YYYY HH:mm:ss");
        this.createFilterCriteria(startTimeFormat, endTimeFormat);
        if (res.httpInfo[0]["Http Info"] == undefined) {
            this.httpInfoArr = res.httpInfo;
        }
        else {
            this.httpInfoArr = [];
        }
        this.httpRequestArr = this.createTableArr(res.reqData[0]);
        this.httpResponseArr = this.createTableArr(res.respData[0]);
        this.httpDerivedArr = this.createTableArr(res.deriveData[0]);
        this.httpSessionArr = this.createTableArr(res.sessionData[0]);
        this.httpConditionArr = this.createTableArr(res.conditionData[0]);
        this.httpRequestArrBody = this.createTableArrBody(res.reqBodyData[0]);
        this.httpResponseArrBody = this.createTableArrBody(res.respBodyData[0]);
        // Check if arrays are empty and set flags accordingly
        this.isHttpInfoData = this.httpInfoArr.length == 0 ? false : true;
        // Update array values and flags based on conditions
        ((_a = this.httpRequestArr[0]) === null || _a === void 0 ? void 0 : _a.header) === "Request Headers" && (this.httpRequestArr[0].value = "No Config Found", this.isRequestHeaders = false);
        ((_b = this.httpRequestArrBody[0]) === null || _b === void 0 ? void 0 : _b.header) === "ReqBody" && this.httpRequestArrBody[0].value === "No Records Found" && (this.httpRequestArrBody[0].value = "No Config Found", this.isRequestBody = false, this.rows = '1');
        ((_c = this.httpResponseArrBody[0]) === null || _c === void 0 ? void 0 : _c.header) === "RespBody" && this.httpResponseArrBody[0].value === "No Records Found" && (this.httpResponseArrBody[0].value = "No Config Found", this.isResponseBody = false, this.rows = '1');
        ((_d = this.httpResponseArr[0]) === null || _d === void 0 ? void 0 : _d.header) === "Response Headers" && (this.httpResponseArr[0].value = "No Config Found", this.isResponseHeaders = false);
        ((_e = this.httpDerivedArr[0]) === null || _e === void 0 ? void 0 : _e.header) === "Custom Data" && (this.httpDerivedArr[0].value = "No Config Found", this.isCustomData = false);
        ((_f = this.httpSessionArr[0]) === null || _f === void 0 ? void 0 : _f.header) === "Session Data" && (this.httpSessionArr[0].value = "No Config Found", this.isSessionData = false);
        ((_g = this.httpConditionArr[0]) === null || _g === void 0 ? void 0 : _g.header) === "Condition Data" && (this.httpConditionArr[0].value = "No Config Found", this.isConditionData = false);
    }
    /**
     * Extracts HTTP Info details from the ElasticSearch attributes object.
     * Mimics legacy structure: [ { ServerName, TierName, StatusCode, AppName } ]
     *
     * @param source The _source object from an Elasticsearch hit.
     * @returns Array with a single object containing HTTP info fields.
     */
    buildHttpInfoFromES(source) {
        var _a, _b, _c, _d, _e, _f, _g;
        const attributes = (source === null || source === void 0 ? void 0 : source.attributes) || {};
        const resourceAttributes = source.resource.attributes;
        const httpInfo = {
            ServerName: (_b = (_a = attributes['cav.server']) !== null && _a !== void 0 ? _a : resourceAttributes["host.name"]) !== null && _b !== void 0 ? _b : "-",
            TierName: (_d = (_c = attributes['cav.tier']) !== null && _c !== void 0 ? _c : resourceAttributes["service.name"]) !== null && _d !== void 0 ? _d : "-",
            StatusCode: attributes['http.response.status_code'] !== undefined
                ? attributes['http.response.status_code'].toString()
                : "-",
            AppName: (_g = (_f = (_e = attributes['cav.instance']) !== null && _e !== void 0 ? _e : resourceAttributes["service.instance.id"]) !== null && _f !== void 0 ? _f : resourceAttributes["process.pid"]) !== null && _g !== void 0 ? _g : "-"
        };
        return [httpInfo];
    }
    /**
   * Extracts request headers from the ElasticSearch attributes object.
   * Only includes keys that match the pattern "http.request.header.*"
   * and have a non-empty array as their value.
   */
    buildRequestHeadersFromES(source) {
        let requestHeaders = [];
        const attributes = (source === null || source === void 0 ? void 0 : source.attributes) || {};
        // Use generic extraction for request headers
        requestHeaders = this.extractHeaders(attributes, 'http.request.header.');
        return requestHeaders;
    }
    /**
     * Extracts response headers from the ElasticSearch attributes object.
     * Only includes keys that match the pattern "http.response.header.*"
     * and have a non-empty array as their value.
     */
    buildResponseHeadersFromES(source) {
        let responseHeaders = [];
        const attributes = (source === null || source === void 0 ? void 0 : source.attributes) || {};
        // Use generic extraction for response headers
        responseHeaders = this.extractHeaders(attributes, 'http.response.header.');
        return responseHeaders;
    }
    // Generic header extraction for both array and string values
    extractHeaders(attributes, prefix) {
        const headers = [];
        for (const key in attributes) {
            if (key.startsWith(prefix)) {
                const headerKey = key.replace(prefix, '');
                const value = attributes[key];
                if (Array.isArray(value) && value.length > 0) {
                    value.forEach(v => {
                        headers.push({ header: headerKey, value: v });
                    });
                }
                else if (typeof value === 'string') {
                    headers.push({ header: headerKey, value });
                }
            }
        }
        return headers;
    }
    createTableArr(reqDataDetail) {
        return Object.keys(reqDataDetail).map(key => {
            try {
                let value = decodeURIComponent(reqDataDetail[key]).replace(/\+/g, ' ').replace(/&#95;/g, '_');
                return { header: key, value };
            }
            catch (error) {
                let value = '';
                if (reqDataDetail[key] && reqDataDetail[key].substring(reqDataDetail[key].length - 2, reqDataDetail[key].length - 1) === "%") {
                    value = decodeURIComponent(reqDataDetail[key].substring(0, reqDataDetail[key].lastIndexOf("%2"))).replace(/\+/g, ' ');
                }
                else {
                    value = reqDataDetail[key].replace(/\+/g, ' ');
                }
                return { header: key, value };
            }
        });
    }
    createTableArrBody(reqDataDetail) {
        return Object.keys(reqDataDetail).map(key => {
            try {
                return {
                    header: key, value: decodeURIComponent(reqDataDetail[key].substring(0, 120)).replace(/\+/g, '')
                };
            }
            catch (error) {
                return {
                    header: key, value: "Body is not in textual format, so not displaying"
                };
            }
        });
    }
    createFilterCriteria(startTime, endTime) {
        this.ForFooterUrl = '';
        this.filterCriteria = '';
        let strstartTime = Number(this.id.startTime);
        let strendTime = Number(this.id.endTime);
        if (this.commonService.httpFlag == true) {
            if (this.commonService.httpData.tierName != "NA" && this.commonService.httpData.tierName != "" && this.commonService.httpData.tierName != "undefined" && this.commonService.httpData.tierName != undefined) {
                this.filterCriteria += "Tier=" + this.commonService.httpData.tierName;
            }
            if (this.commonService.httpData.serverName != "NA" && this.commonService.httpData.serverName != "" && this.commonService.httpData.serverName != "undefined" && this.commonService.httpData.serverName != undefined) {
                this.filterCriteria += ", Server=" + this.commonService.httpData.serverName;
            }
            if (this.commonService.httpData.appName != "NA" && this.commonService.httpData.appName != "" && this.commonService.httpData.appName != "undefined" && this.commonService.httpData.appName != undefined) {
                this.filterCriteria += ", Instance=" + this.commonService.httpData.appName;
            }
        }
        else {
            if (this.id.tierName != "NA" && this.id.tierName != "" && this.id.tierName != "undefined" && this.id.tierName != undefined) {
                this.filterCriteria += "Tier=" + this.id.tierName;
            }
            if (this.id.serverName != "NA" && this.id.serverName != "" && this.id.serverName != "undefined" && this.id.serverName != undefined) {
                this.filterCriteria += ", Server=" + this.id.serverName;
            }
            if (this.id.appName != "NA" && this.id.appName != "" && this.id.appName != "undefined" && this.id.appName != undefined) {
                this.filterCriteria += ", Instance=" + this.id.appName;
            }
        }
        if (startTime != "NA" && startTime != "" && startTime != undefined && startTime != 'undefined') {
            this.filterCriteria += ", StartTime=" + startTime;
        }
        else if (this.id.startTime != "NA" && this.id.startTime != "" && this.id.startTime != 'undefined' && this.id.startTime != undefined) {
            let startTimeInDateFormat = moment__WEBPACK_IMPORTED_MODULE_4__(strstartTime).tz(sessionStorage.getItem('timeZoneId')).format("MM/DD/YY hh:mm:ss");
            this.filterCriteria += ', StartTime=' + startTimeInDateFormat;
        }
        if (endTime != "NA" && endTime != "" && endTime != 'undefined' && endTime != undefined) {
            this.filterCriteria += ", EndTime=" + endTime;
        }
        else if (this.id.endTime != "NA" && this.id.endTime != "" && this.id.endTime != 'undefined' && this.id.endTime != undefined) {
            let endTimeInDateFormat = moment__WEBPACK_IMPORTED_MODULE_4__(strendTime).tz(sessionStorage.getItem('timeZoneId')).format("MM/DD/YY hh:mm:ss");
            this.filterCriteria += ', EndTime=' + endTimeInDateFormat;
        }
        if (this.id.pageName != null && this.id.pageName != undefined && this.id.pageName != "" && this.id.pageName != "NA") {
            this.filterCriteria += ", Page=" + this.id.pageName;
        }
        if (this.id.transtx != null && this.id.transtx != undefined && this.id.transtx != "" && this.id.transtx != "NA") {
            this.filterCriteria += ", Transaction=" + this.id.transtx;
        }
        if (this.id.script != null && this.id.script != undefined && this.id.script != "" && this.id.script != "NA") {
            this.filterCriteria += ", Script=" + this.id.script;
        }
        if (this.commonService.httpData.urlQueryParamStr && this.commonService.httpData.urlQueryParamStr != 'NA') {
            if (this.commonService.httpData.urlQueryParamStr.length > 45) {
                this.filterCriteriaToolTip = this.filterCriteria + ", URL=" + this.commonService.httpData.
                    urlQueryParamStr.replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
                let wholeUrl = this.commonService.httpData.urlQueryParamStr.replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
                this.filterCriteria += ", URL=" + wholeUrl.substring(0, 45) + "...";
            }
            else {
                this.filterCriteria += ", URL=" + this.commonService.httpData.urlQueryParamStr.replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
            }
        }
        if (this.filterCriteria.startsWith(",")) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
        if (this.filterCriteria.endsWith(",")) {
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
        }
        this.ForFooterUrl += "URL=" + this.commonService.httpData.urlQueryParamStr.replace(/&#038;/g, "&").replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n").replace(/&#094;/g, "^");
    }
    ngOnDestroy() {
        if (this.commonService.isFromSplitView) {
            this._ddrData.splitViewFlag = true;
            this.commonService.isToLoadSideBar = false;
        }
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "testRun=" + this.id.testRun + "&queryId=" + this.queryId + "&tierName=" + this.id.tierName;
        this.isCancelQuery = false;
        this.ndDdrHttpService.getCancelQueryResult(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["CancelQueryLoadedState"]) {
                return (state.data.status);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
HttpReqRespComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__["DdrDataModelService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_7__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__["BreadcrumbService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_9__["NdDdrHttpService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_10__["ElasticsearchQueryService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], HttpReqRespComponent.prototype, "columnData", void 0);
HttpReqRespComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'http-req-resp',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./http-req-resp.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./http-req-resp.component.scss */ "./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.scss")).default]
    })
], HttpReqRespComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ip-stat/ip-stat.component.scss":
/*!*********************************************************************!*\
  !*** ./src/app/pages/ddr/components/ip-stat/ip-stat.component.scss ***!
  \*********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".flowmap-box {\n  height: 90vh;\n  overflow: auto;\n  position: relative;\n}\n\n.loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ip-stat/ip-stat.component.ts":
/*!*******************************************************************!*\
  !*** ./src/app/pages/ddr/components/ip-stat/ip-stat.component.ts ***!
  \*******************************************************************/
/*! exports provided: IpStatComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "IpStatComponent", function() { return IpStatComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! moment */ "./node_modules/moment/moment.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");
/* harmony import */ var src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! src/app/shared/cavLoggerService/cav-logging.service */ "./src/app/shared/cavLoggerService/cav-logging.service.ts");

















let IpStatComponent = class IpStatComponent {
    constructor(commonService, messageService, _cavConfigService, _ddrData, ndDdrHttpService, router, breadcrumbService, ddrRequest, sessionService, breadcrumb, logger) {
        this.commonService = commonService;
        this.messageService = messageService;
        this._cavConfigService = _cavConfigService;
        this._ddrData = _ddrData;
        this.ndDdrHttpService = ndDdrHttpService;
        this.router = router;
        this.breadcrumbService = breadcrumbService;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.logger = logger;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_10__;
        this.loading = false; // ajax-loader
        this.display = false; // toggle time filter dialog
        this.ipData = []; // table data
        this.strGraphKey = ''; // graph key
        this.timeLabel = ''; // label for selected value from time-filter dropdown
        this.strStartDate = '00/00/00 00:00:00'; // default start time
        this.strEndDate = '00/00/00 23:59:59'; // default end time
        this.showGraph = true; // flag to toggle Highcharts accordion based on data
        this.graphTab = true; // flag to set accordionTab selected
        this.customFilterDisplay = false;
        this.headerFilter = ''; // filter criteria
        this.tierName = "";
        this.timeStampArr = []; // timestamp array for each sample
        this.isFilterChanged = false; // flag to check if time period state changed or not
        this.eventDayFilter = false; // flag to toggle event day filters
        this.commonFilter = false; // flag for common filters to be used for Yesterday, Last Week same days time period...
        this._disabled = false; // flag to disable p-calendar
        this._yearList = []; // year list for event day filter's
        this._eventDaysList = []; // event day list for event day filter
        this._selectedEventDay = ""; // selected event day from event day filter
        this._selectedEventDayYear = ""; // selected year from event day filter
        this.IPStatHeader = ''; // accordion tab header
        this.breadcrumb = breadcrumb;
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g;
        const me = this;
        this.logger.debug(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__["DDR"], "clickButtonEvent called with ", event);
        const action = (_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action;
        switch (action) {
            case "VIEWFPRBYBN":
                me.openFPByIntegrationReport((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row, "FPByID");
                break;
            case "VIEWFPRBYBRT":
                me.isIPByResp(event.cavEventExt.row);
                break;
            case "clickable":
                ((_e = (_d = event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.key) === "dispalyName" ? me.onClickshowGraphWithInfo((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row) : me.openExceptionInstanceReport((_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.row);
                break;
            default:
                break;
        }
    }
    setInCommonService(trun) {
        if (trun)
            this.commonService.testRun = trun;
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.id = this.commonService.getData();
        if (this.router.url.indexOf('/home/ED-ddr/IpStatComponent') != -1 || this.router.url.indexOf('/ddr/IpStatComponent') != -1) {
            this.urlParam = this._ddrData.btTrendParamFromStoreView;
            if (this.router.url.indexOf('?') != -1) {
                let queryParams1 = location.href.substring(location.href.indexOf('?') + 1, location.href.length);
                this.urlParam = JSON.parse('{"' + decodeURI(queryParams1).replace(/"/g, '\\"').replace(/&/g, '","').replace(/=/g, '":"') + '"}');
            }
            if (this.urlParam != undefined) {
                this.setInCommonService(this.urlParam.testRun);
                this.commonService.removeFromStorage();
                if (this.urlParam.strStartDate != undefined)
                    this.strStartDate = this.urlParam.strStartDate;
                if (this.urlParam.strEndDate != undefined)
                    this.strEndDate = this.urlParam.strEndDate;
                this.urlParam.product = decodeURIComponent(this.urlParam.product);
                this.commonService.setInStorage = this.urlParam;
                this.commonService.paramsForBtTrend = this.urlParam;
                sessionStorage.setItem("vectorName", this.urlParam.vectorName);
                if (this.urlParam.dcNameList && this.urlParam.dcNameList != 'undefined') {
                    this.commonService.dcNameList = this.urlParam.dcNameList;
                    this.commonService.selectedDC = this.urlParam.dcName;
                    this.commonService.isAllCase = this.urlParam.isAll;
                    this.commonService.testRun = this.urlParam.testRun;
                    this.commonService.tierNameList = this.urlParam.tierNameList;
                    sessionStorage.setItem("dcNameList", this.urlParam.dcNameList);
                    sessionStorage.setItem("tierNameList", this.urlParam.tierNameList);
                    sessionStorage.setItem("isAllCase", this.urlParam.isAll);
                }
                this.commonService.enableQueryCaching = this.urlParam.enableQueryCaching;
            }
            else {
                if (this.commonService.paramsForBtTrend != undefined) {
                    this.urlParam = this.commonService.paramsForBtTrend;
                }
                else {
                    this.urlParam = this.commonService.getData();
                    this.urlParam.vectorName = sessionStorage.getItem('vectorName');
                }
                this.setInCommonService(this.urlParam.testRun);
            }
        }
        else {
            if (this.commonService.paramsForBtTrend != undefined) {
                this.urlParam = this.commonService.paramsForBtTrend;
            }
            else {
                this.urlParam = this.commonService.getData();
                this.urlParam.vectorName = sessionStorage.getItem('vectorName');
            }
            this.setInCommonService(this.urlParam.testRun);
        }
        if (this.urlParam.strGraphKey != undefined) {
            this.strGraphKey = this.urlParam.strGraphKey;
        }
        else if (this.id.strGraphKey != undefined) {
            this.strGraphKey = this.id.strGraphKey;
        }
        this.breadcrumb.add({ label: 'IP Stat', routerLink: '/ddr/IpStatComponent' });
        this.loading = true;
        this.fillData();
    }
    onClickshowGraphWithInfo(event) { this.showGraphWithInfo(event); }
    fillData() {
        const EVENT_DAYS = {
            BLACK_FRIDAY: "Black Friday",
            CHRISTMAS_DAY: "Christmas Day",
            CYBER_MONDAY: "Cyber Monday",
            GOOD_FRIDAY: "Good Friday",
            NEW_YEARS_DAY: "New Years Day",
            PRESIDENTS_DAY: "President's Day",
            THANKS_GIVING_DAY: "Thanks Giving Day",
            VALENTINES_DAY: "Valentines Day"
        };
        // Create _eventDaysList array
        this._eventDaysList = Object.values(EVENT_DAYS).map(element => ({ label: element, value: element }));
        // Create _yearList array
        for (let year = 2014; year <= new Date().getFullYear(); year++) {
            this._yearList.push({ label: year.toString(), value: year });
        }
        this.updateDateTime();
        this.relativePath = 'ddr/ip-stat/ip-stat.json';
        this.getIPData();
        this.commonService.host = '';
        this.commonService.port = '';
        this.commonService.protocol = '';
        this.commonService.selectedDC = '';
        this.setInCommonService(this.urlParam.testRun || this.id.testRun);
    }
    fetchTierServerAppId() {
        const payload = {
            testRun: this.commonService.testRun,
            tierName: this.urlParam.vectorName,
            serverName: this.urlParam.serverName,
            appName: this.urlParam.appName
        };
        const url = this._ddrData.createHostUrl() + '/DashboardServer/v2/ddr/getTierServerAppId';
        return this.ddrRequest.getDataInStringUsingPost(url, payload);
    }
    openFPByIntegrationReport(rowData, flag) {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            try {
                var backendId = '';
                const backendIdUrl = 'testRun=' + this.urlParam.testRun + '&backendName=' + rowData.discoverName;
                // Get the backend ID
                const result = yield this.ndDdrHttpService.getBackendId(backendIdUrl);
                if (!result.success) {
                    this.messageService.showError(result.errorMessage);
                    return;
                }
                backendId = result.data;
                if (!backendId || backendId.startsWith('Error')) {
                    this.messageService.showError(backendId);
                    return;
                }
                this.fetchTierServerAppId().subscribe(data => {
                    const response = JSON.parse(data);
                    this.urlParam.strTimeLabel = this.timeLabel;
                    let fpdata = {};
                    fpdata['tierId'] = response.tierId;
                    fpdata['serverId'] = response.serverId;
                    fpdata['appId'] = response.appId;
                    fpdata['tierName'] = this.id.tierName || this.urlParam.vectorName;
                    fpdata['serverName'] = this.id.serverName;
                    fpdata['appName'] = this.id.appName;
                    fpdata['backendId'] = backendId;
                    fpdata['backendSubType'] = rowData.backendSubType;
                    fpdata['minresTimeOfBackend'] = rowData.resMin;
                    if (flag === 'FPByResTime') {
                        fpdata['maxresTimeOfBackend'] = this.responseTime;
                    }
                    fpdata['avgresTimeOfBackend'] = rowData.avgResponseTime;
                    fpdata['startTime'] = this.id.startTime || this.urlParam.strStartTime;
                    fpdata['endTime'] = this.id.endTime || this.urlParam.strEndTime;
                    fpdata['backendName'] = rowData['discoverName'];
                    this.logger.debug(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__["DDR"], 'openFPByIntegrationReport', 'Flow Path Data', fpdata);
                    this._ddrData.splitViewFlag = false;
                    if (this.commonService.enableQueryCaching) {
                        this._ddrData.enableQueryCaching = this.commonService.enableQueryCaching;
                    }
                    this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_8__["BREADCRUMB_ITEMS"].IPSTAT;
                    this.commonService.IPByFPData = fpdata;
                    this._ddrData.backendName = rowData['discoverName'];
                    this._ddrData.IPByFPFlag = true;
                    this._ddrData.isFromtrxFlow = false;
                    this._ddrData.isFromtrxSideBar = false;
                    this.commonService.isFilterFromSideBar = false;
                    this._ddrData.FromexpFlag = 'false';
                    this._ddrData.setInLogger('DDR::IP Stat::Flowpath', 'Flowpath', 'Open Flowpath Report');
                    if (this.router.url.indexOf('/home/ddrCopyLink/') != -1) {
                        this.router.navigate(['/home/ddrCopyLink/flowpath']);
                    }
                    else if (this.router.url.indexOf('/home/ED-ddr') != -1) {
                        this.router.navigate(['/home/ED-ddr/flowpath']);
                    }
                    else {
                        this.router.navigate(['/ddr/flowpath']);
                    }
                });
            }
            catch (error) {
                this.logger.error(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__["DDR"], 'openFPByIntegrationReport', 'Error in opening FP Report', error);
            }
        });
    }
    createHeaderFilter() {
        this.headerFilter = '';
        if (this.urlParam.vectorName) {
            this.headerFilter += " Tier=" + this.urlParam.vectorName;
        }
        else if (this.id.tierName && this.id.tierName != "undefined") {
            this.headerFilter += " Tier=" + this.id.tierName;
        }
        if (this.startTime != undefined && this.endTime != undefined) {
            this.headerFilter += ", " + "Start Date/Time=" + this.startTime;
            this.headerFilter += ", " + "End Date/Time=" + this.endTime;
        }
    }
    getIPData() {
        const testRunForObj = this.sessionService.preSession.multiDc ? this.urlParam.testRun : this.commonService.testRun;
        const payload = {
            cctx: this.sessionService.session.cctx,
            tr: testRunForObj,
            dataFilter: [0, 1, 2, 3, 4, 5, 6],
            pk: null,
            tierName: this.commonService.hotspotToIP ? this.id.tierName : this.urlParam.tierNameList,
            serverName: this.urlParam.serverName,
            appName: this.urlParam.appName || this.urlParam.instanceName,
            btCategory: "intHealth",
            reqType: "BT",
            reqVecName: this.urlParam.vectorName,
            duration: {
                st: this.urlParam.strStartTime,
                et: this.urlParam.strEndTime,
                preset: this.urlParam.preset,
                viewBy: 600
            },
            serverType: null,
            alertSevType: null,
            all: false,
            flowMapDir: null,
            flowMapName: null,
            globalRenaming: false,
            goodStore: false,
            gRAPH_KEY: null,
            opType: 11,
            resolution: null,
            storeAlertType: 0,
            storeName: null,
            user: null,
            valueType: null,
            isIncDisGraph: false,
            isCompare: false,
            isAll: false,
            dc: "",
            nonZeroIP: false,
            multiDc: false,
            btName: "",
            health: "",
            rt: "-1.0",
            rtt: "-1",
            tps: "-1.0",
            tpst: "-1",
            es: "-1.0",
            est: "-1",
            lastIndex: "",
            isPrevious: false,
            getData: false,
        };
        this.fetchIPStatData(payload);
    }
    fetchIPStatData(payload) {
        this.ndDdrHttpService.getIPStatData(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_14__["IPStatLoadedState"]) {
                this.assignData(state.data);
            }
        }, (error) => {
            this.logger.error(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__["DDR"], 'getIPData', 'Error in fetching response', error);
            this.loading = false;
            this.commonService.loaderForDdr = false;
        });
    }
    assignData(res) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
        this.commonService.loaderForDdr = false;
        try {
            let data;
            try {
                data = res;
                this.logger.debug(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__["DDR"], 'assignData', 'res data in Ipstat', data);
                this.eventDateMap = JSON.parse((_a = data === null || data === void 0 ? void 0 : data.tableData) === null || _a === void 0 ? void 0 : _a.eventdaysJson);
                this.fullJson = data;
            }
            catch (error) {
                this.logger.debug(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__["DDR"], 'assignData', 'Error in parsing res data in Ipstat', error);
                this.loading = false;
            }
            if (!((_b = data === null || data === void 0 ? void 0 : data.tableData) === null || _b === void 0 ? void 0 : _b.serverOffset) || !((_c = data === null || data === void 0 ? void 0 : data.tableData) === null || _c === void 0 ? void 0 : _c.timeZone))
                this.loading = false;
            this.timeLabel = this.urlParam.strTimeLabel;
            this.ipData = ((_d = data === null || data === void 0 ? void 0 : data.tableData) === null || _d === void 0 ? void 0 : _d.data) || [];
            if (this.ipData.length == 0) {
                this.showGraph = false;
                this.loading = false;
                return;
            }
            this.timeStampArr = this.calculateTimeStamps(data);
            if (this.fullJson && ((_f = (_e = this.fullJson) === null || _e === void 0 ? void 0 : _e.tableData) === null || _f === void 0 ? void 0 : _f.startTimeStamp) != 0 && ((_h = (_g = this.fullJson) === null || _g === void 0 ? void 0 : _g.tableData) === null || _h === void 0 ? void 0 : _h.timeZone)) {
                this.startTime = this.sessionService.convertTimestampIntoFormattedString(Number((_k = (_j = this.fullJson) === null || _j === void 0 ? void 0 : _j.tableData) === null || _k === void 0 ? void 0 : _k.startTimeStamp), "MM/DD/YYYY HH:mm:ss");
                this.endTime = this.sessionService.convertTimestampIntoFormattedString(Number((_m = (_l = this.fullJson) === null || _l === void 0 ? void 0 : _l.tableData) === null || _m === void 0 ? void 0 : _m.endTimeStamp), "MM/DD/YYYY HH:mm:ss");
            }
            else
                this.loading = false;
            this.createHeaderFilter();
            if (this.isFilterChanged === true) {
                this.timeLabel = this.selectedValue;
            }
            this.showGraph = true;
            this.ipData.forEach((val) => {
                val.available = val.available === "0" ? './images/reddown.png' : val.available === "1" ? './images/greenup.png' : "NA";
                val.health = `./images/${val.health}`;
            });
            this.isFilterChanged = false;
            this.loading = false;
            this.showGraphWithInfo(this.ipData[0]);
        }
        catch (error) {
            this.loading = false;
        }
    }
    /**
    * Calculates the timestamp for each sample in the result object and returns an array of timestamps.
    *
    * This method iterates over the samples in the result object's data and computes a series of
    * timestamps based on the start and end times. The buffer time between each sample is calculated
    * by dividing the total time duration by the number of samples. The timestamps are then generated
    * by adding this buffer time to the previous timestamp, starting from the initial start time.
    *
    * @param {any} res - The result object containing the table data with start and end timestamps and sample data.
    * @returns {number[]} - An array of calculated timestamps for each sample.
    */
    calculateTimeStamps(res) {
        var _a;
        const timestamps = [];
        if (!((_a = res.tableData.data[0]) === null || _a === void 0 ? void 0 : _a.resData)) {
            return timestamps;
        }
        const bufferTime = (Number(res.tableData.endTimeStamp) - Number(res.tableData.startTimeStamp)) / res.tableData.data[0].resData.length;
        for (let i = 0; i < res.tableData.data[0].resData.length; i++) {
            const updatedTime = i === 0 ? res.tableData.startTimeStamp : timestamps[i - 1] + bufferTime;
            timestamps.push(updatedTime);
        }
        return timestamps;
    }
    /**
    * Creates chart data from the given node array by combining each node value with the corresponding timestamp.
    *
    * This method iterates over the node array and constructs an array of arrays, where each inner array contains
    * a timestamp and the corresponding node value.
    *
    * @param {any[]} node - An array of node values to be combined with timestamps.
    * @returns {any[]} - An array of arrays, each containing a timestamp and the corresponding node value.
    */
    createChartData(node) {
        const seriesArray = [];
        node.forEach((value, index) => {
            seriesArray.push([this.timeStampArr[index], value]);
        });
        return seriesArray;
    }
    fillDateTime() {
        let tmpStrStarDate = this.strStartDate.split(" ");
        let tmpStrStarTime = tmpStrStarDate[1].split(":");
        let tmpStrEndDate = this.strEndDate.split(" ");
        let tmpStrEndTime = tmpStrEndDate[1].split(":");
        this.startHours = tmpStrStarTime[0];
        this.startMinutes = tmpStrStarTime[1];
        this.startSeconds = tmpStrStarTime[2];
        this.endHours = tmpStrEndTime[0];
        this.endMinutes = tmpStrEndTime[1];
        this.endSeconds = tmpStrEndTime[2];
    }
    dateAjaxCall(eventDay, eventYear) {
        const url = `${this._ddrData.createHostUrl()}/dashboard/view/eventDay.jsp?eventDay=${eventDay}&year=${eventYear}`;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => {
            const response = data.trim();
            const eventDate = new Date(response);
            const currentDate = new Date();
            if (eventDate <= currentDate) {
                this.startDate = response;
                this.endDate = response;
                this.fillDateTime();
            }
            else {
                this.messageService.showError("Data is not available for " + eventDay + " " + eventYear);
                return;
            }
        });
    }
    updateDateTime() {
        // Get the current date and time in the timezone stored in sessionStorage
        const d = new Date(moment__WEBPACK_IMPORTED_MODULE_6__().tz(sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss'));
        // Format the current date and time
        this.currDateTime = this.getDateFormat(d);
        // Update the date and time every second
        setTimeout(() => {
            this.updateDateTime();
        }, 1000);
    }
    getDateFormat(date) {
        let day = date.getDate();
        let month = date.getMonth() + 1; // January is 0!
        const year = date.getFullYear();
        let hour = date.getHours();
        let mins = date.getMinutes();
        let secs = date.getSeconds();
        // Add leading zeros if necessary
        if (day < 10) {
            day = '0' + day;
        }
        if (month < 10) {
            month = '0' + month;
        }
        if (hour < 10) {
            hour = '0' + hour;
        }
        if (mins < 10) {
            mins = '0' + mins;
        }
        if (secs < 10) {
            secs = '0' + secs;
        }
        return month + '/' + day + '/' + year + " " + hour + ":" + mins + ":" + secs;
    }
    openDateFilter(event) {
        var value = event.value;
        this.openDateFilterOnEventDay(value);
    }
    openDateFilterOnEventDay(value) {
        switch (value) {
            case "EventDay":
                const defaultEventDay = this._eventDaysList[0].value;
                const defaultEventYear = this._yearList[0].value;
                this.dateAjaxCall(defaultEventDay, defaultEventYear);
                this._disabled = true;
                this.customFilterDisplay = false;
                this.commonFilter = true;
                this.eventDayFilter = true;
                this._selectedEventDay = defaultEventDay; // Select the default event day
                this._selectedEventDayYear = defaultEventYear; // Select the default event year
                break;
            case "Custom Date":
                this.startDate = this.currDateTime.split(' ')[0];
                this.endDate = this.currDateTime.split(' ')[0];
                this.customFilterDisplay = true;
                this.commonFilter = false;
                this.eventDayFilter = false;
                this._disabled = false;
                let tmpStrStartDate = this.strStartDate.split(" ");
                let tmpStrStartTime = tmpStrStartDate[1].split(":");
                let tmpStrEndDate = this.currDateTime.split(" ");
                let tmpStrEndTime = tmpStrEndDate[1].split(":");
                this.startHours = tmpStrStartTime[0];
                this.startMinutes = tmpStrStartTime[1];
                this.startSeconds = tmpStrStartTime[2];
                this.endHours = tmpStrEndTime[0];
                this.endMinutes = tmpStrEndTime[1];
                this.endSeconds = tmpStrEndTime[2];
                break;
            case "Yesterday":
            case "Last Week Same Day":
                this.commonFilter = true;
                this.eventDayFilter = false;
                this.customFilterDisplay = false;
                this._disabled = true;
                this.fillDateTime();
                this.fillDates(value);
                break;
            case "Whole Scenario":
                this.customFilterDisplay = false;
                this.eventDayFilter = false;
                this.commonFilter = false;
                break;
            default:
                this.customFilterDisplay = false;
                this.eventDayFilter = false;
                this.commonFilter = false;
                break;
        }
    }
    /**
    *  Allow digits (0-9), arrow keys (0), backspace (8), and delete (46)
    */
    valEnteredKeyN(event) {
        if ((event.keyCode >= 48 && event.keyCode <= 57) || (event.keyCode == 0) || (event.keyCode == 8))
            return true;
        else
            return false;
    }
    fillDates(value) {
        this.startDate = this.eventDateMap[value];
        this.endDate = this.eventDateMap[value];
    }
    showGraphWithInfo(node) {
        const me = this;
        this.graphTab = true;
        let rowData = this.fullJson;
        this.IPStatHeader = "IP Stats - " + node.dispalyName;
        let resArray = this.createChartData(node.resData);
        let callArray = this.createChartData(node.callData);
        let errArray = this.createChartData(node.errorData);
        this.res = {
            chart: {
                height: 200,
                width: 400,
                responsive: true,
                zoomType: 'x',
                resetZoomButton: {
                    position: {
                        x: 0,
                        y: -45
                    }
                }
            },
            credits: {
                enabled: false
            },
            title: {
                text: 'Response Time (ms)',
                style: {
                    fontSize: '15px'
                }
            },
            tooltip: {
                formatter: function () {
                    var _a;
                    return '<b>Time: </b>'
                        + moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.x, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("MM/DD/YY HH:mm:ss")
                        + '<br/ ><b>Value: ' + '</b>'
                        + this.y;
                }
            },
            legend: {
                itemStyle: {
                    color: 'rgb(29, 181, 18)',
                    fontWeight: 'bold',
                    fontSize: '10px'
                },
                itemHoverStyle: {
                    color: 'rgb(29, 220, 20)'
                },
                itemDistance: 5,
                padding: 0,
                margin: 0,
                labelFormatter: function labelFormatterFun() {
                    return me.labelFormatter(node, 'res');
                }
            },
            exporting: {
                enabled: false
            },
            xAxis: {
                type: 'time',
                labels: {
                    formatter: function () {
                        var _a;
                        return moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.value, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("HH:mm:ss");
                    },
                    style: {
                        fontSize: '10px'
                    }
                },
                allowDecimals: false
            },
            yAxis: {
                title: {
                    text: null,
                },
                min: 0
            },
            series: [
                {
                    type: 'line',
                    data: resArray
                }
            ]
        };
        this.cps = {
            chart: {
                height: 200,
                width: 400,
                responsive: true,
                zoomType: 'x',
                resetZoomButton: {
                    position: {
                        x: 0,
                        y: -45
                    }
                }
            },
            credits: {
                enabled: false
            },
            title: {
                text: 'CPS',
                style: {
                    fontSize: '15px'
                }
            },
            xAxis: {
                type: 'time',
                labels: {
                    formatter: function () {
                        var _a;
                        return moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.value, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("HH:mm:ss");
                    },
                    style: {
                        fontSize: '10px'
                    }
                },
                allowDecimals: false
            },
            yAxis: {
                title: {
                    text: null,
                },
                min: 0
            },
            tooltip: {
                formatter: function () {
                    var _a;
                    return '<b>Time: </b>'
                        + moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.x, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("MM/DD/YY HH:mm:ss")
                        + '<br/ ><b>Value: ' + '</b>'
                        + this.y;
                }
            },
            exporting: {
                enabled: false
            },
            legend: {
                itemStyle: {
                    color: 'rgb(29, 181, 18)',
                    fontWeight: 'bold',
                    fontSize: '10px'
                },
                itemHoverStyle: {
                    color: 'rgb(29, 220, 20)'
                },
                itemDistance: 5,
                padding: 0,
                margin: 0,
                labelFormatter: function labelFormatterFun() {
                    return me.labelFormatter(node, 'cps');
                }
            },
            series: [
                {
                    type: 'line',
                    data: callArray
                }
            ]
        };
        this.err = {
            chart: {
                height: 200,
                width: 400,
                responsive: true,
                zoomType: 'x',
                resetZoomButton: {
                    position: {
                        x: 0,
                        y: -45
                    }
                }
            },
            credits: {
                enabled: false
            },
            title: {
                text: 'Errors',
                style: {
                    fontSize: '15px'
                }
            },
            xAxis: {
                type: 'time',
                labels: {
                    formatter: function () {
                        var _a;
                        return moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.value, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("HH:mm:ss");
                    },
                    style: {
                        fontSize: '10px'
                    }
                },
                allowDecimals: false
            },
            yAxis: {
                title: {
                    text: null,
                },
                min: 0
            },
            tooltip: {
                formatter: function () {
                    var _a;
                    return '<b>Time: </b>' + moment__WEBPACK_IMPORTED_MODULE_6__["tz"](this.x, (_a = rowData === null || rowData === void 0 ? void 0 : rowData.tableData) === null || _a === void 0 ? void 0 : _a.timeZone).format("MM/DD/YY HH:mm:ss") + '<br/ ><b>Value: ' + '</b>' + this.y;
                }
            },
            exporting: {
                enabled: false
            },
            legend: {
                itemStyle: {
                    color: 'rgb(29, 181, 18)',
                    fontWeight: 'bold',
                    fontSize: '10px'
                },
                itemHoverStyle: {
                    color: 'rgb(29, 220, 20)'
                },
                itemDistance: 5,
                padding: 0,
                margin: 0,
                labelFormatter: function labelFormatterFun() {
                    return me.labelFormatter(node, 'error');
                }
            },
            series: [
                {
                    type: 'line',
                    data: errArray
                }
            ]
        };
    }
    // Formats response options for a particular metric
    labelFormatter(resseriesOptions, type) {
        const formatter = (max, avg) => ` Max : ${Number(max).toFixed(1)}    Avg : ${Number(avg).toFixed(1)} `;
        if (type === 'res') {
            return formatter(resseriesOptions.resMax, resseriesOptions.res);
        }
        else if (type === 'cps') {
            return formatter(resseriesOptions.cpsMax, resseriesOptions.cps);
        }
        else {
            return formatter(resseriesOptions.epsMax, resseriesOptions.eps);
        }
    }
    openExceptionInstanceReport(node) {
        this.fetchTierServerAppId().subscribe(data => {
            const response = JSON.parse(data);
            var jsonstartTimeStamp = this.fullJson.startTimeStamp;
            var jsonendTimeStamp = this.fullJson.endTimeStamp;
            var strGraphKey = this.strGraphKey;
            this.urlParam.strTimeLabel = this.timeLabel;
            if (strGraphKey.toLowerCase() == "wholescenario") {
                jsonstartTimeStamp = "NA";
                jsonendTimeStamp = "NA";
            }
            this._ddrData.vecArrForGraph = [];
            this._ddrData.testRun = this.urlParam.testRun;
            this._ddrData.tierName = this.urlParam.vectorName || this.id.tierName;
            this._ddrData.product = this.urlParam.product.replace("/", "");
            this.urlParam.tierid = response.tierId;
            this.urlParam.serverid = response.serverId;
            this.urlParam.appid = response.appId;
            this.urlParam.backendNameQuery = node.discoverName;
            this.urlParam.tierName = this.urlParam.vectorName || this.id.tierName;
            this.urlParam.startTime = this.id.startTime || this.urlParam.strStartTime;
            this.urlParam.endTime = this.id.endTime || this.urlParam.strEndTime;
            this.commonService.setInStorage = this.urlParam;
            this.commonService.expDataFromED = this.urlParam;
            this.commonService.ipstatToExceptionFlag = true;
            this.commonService.fromDBtoExpFlag = false;
            this.commonService.fromhstoExpFlag = false;
            this._ddrData.flowpathToExFlag = false;
            if (this.commonService.enableQueryCaching) {
                this._ddrData.enableQueryCaching = this.commonService.enableQueryCaching;
            }
            this.logger.debug(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__["DDR"], 'openExceptionInstanceReport', 'url params ', this.urlParam);
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_8__["BREADCRUMB_ITEMS"].IPSTAT;
            this.commonService.isFilterFromSideBar = false;
            this._ddrData.isFromtrxFlow = false;
            this._ddrData.isFromtrxSideBar = false;
            this._ddrData.setInLogger('DDR::Ip Stat::Exception', 'Exception', 'Open Exception Report');
            if (this.router.url.indexOf("/home/ddrCopyLink/") != -1) {
                this.router.navigate(['/home/ddrCopyLink/exception']);
            }
            else if (this.router.url.indexOf('/home/ED-ddr') != -1) {
                this.router.navigate(['/home/ED-ddr/exception']);
            }
            else {
                this.router.navigate(['/ddr/exception']);
            }
        });
    }
    getIdFortier(data) { return data.trim().split(":"); }
    openTimeFilter() {
        this.display = true;
        this.selectedValue = this.timeLabel;
        this.customFilterDisplay = (this.selectedValue == 'Custom Date') ? true : false;
        this.timeFilterOptions = [
            { label: 'Today', value: 'Today' },
            { label: 'EventDay', value: 'EventDay' },
            { label: 'Last 5 Minutes', value: 'Last 5 Minutes' },
            { label: 'Last 10 Minutes', value: 'Last 10 Minutes' },
            { label: 'Last 15 Minutes', value: 'Last 15 Minutes' },
            { label: 'Last 30 Minutes', value: 'Last 30 Minutes' },
            { label: 'Last 1 hour', value: 'Last 1 hour' },
            { label: 'Last 2 hours', value: 'Last 2 hours' },
            { label: 'Last 4 hours', value: 'Last 4 hours' },
            { label: 'Last 8 hours', value: 'Last 8 hours' },
            { label: 'Last 12 hours', value: 'Last 12 hours' },
            { label: 'Last 24 hours', value: 'Last 24 hours' },
            { label: 'Yesterday', value: 'Yesterday' },
            { label: 'Last Week Same Day', value: 'Last Week Same Day' },
            { label: 'Custom Date', value: 'Custom Date' },
            { label: 'Whole Scenario', value: 'Whole Scenario' }
        ];
        if (this.urlParam.strGraphKey.includes("SPECIFIED_TIME")) { // When Custom Date/Time is applied in End To End.
            this.startDate = this.startTime;
            [this.startHours, this.startMinutes, this.startSeconds] = this.startTime.split(" ")[1].split(":");
            this.endDate = this.endTime;
            [this.endHours, this.endMinutes, this.endSeconds] = this.endTime.split(" ")[1].split(":");
        }
    }
    trimString(str) { return str.replace(/^\s+/g, '').replace(/\s+$/g, ''); }
    compareDatesForOthers(startDate, endDate) {
        var x = new Date(startDate);
        var y = new Date(endDate);
        return (x >= y);
    }
    submitFilterValue() {
        this.display = false;
        this.loading = true;
        var strStartTimeAll = '';
        var strEndTimeAll = '';
        var strStartTimeAllMs;
        var strEndTimeAllMs;
        let currentDateTime = this.currDateTime;
        if (this.selectedValue == "EventDay" || this.selectedValue == "Yesterday" || this.selectedValue == "Last Week Same Day" || this.selectedValue == "By Phase" || this.selectedValue == "Custom Date") {
            if (this.startDate.toString().includes(" ")) {
                let strDate = new Date(this.startDate);
                this.startDate = (strDate.getMonth() + 1).toString() + '/' + strDate.getDate().toString() + '/' + strDate.getFullYear().toString();
            }
            if (this.endDate.toString().includes(" ")) {
                let endDate = new Date(this.endDate);
                this.endDate = (endDate.getMonth() + 1).toString() + '/' + endDate.getDate().toString() + '/' + endDate.getFullYear().toString();
            }
            if (this.trimString(this.startDate) == "" || this.trimString(this.startHours) == "" || this.trimString(this.startMinutes) == "" || this.trimString(this.startSeconds) == "" || this.trimString(this.endDate) == "" || this.trimString(this.endHours) == "" || this.trimString(this.endMinutes) == "" || this.trimString(this.endSeconds) == "") {
                this.messageService.showError("Start/End Date/Time shouldn't be blank");
                this.loading = false;
                return;
            }
            if (Number(this.startHours) >= 24 || Number(this.endHours) >= 24) {
                this.messageService.showError("Start/End hour field shouldn't be greater than or equals to 24");
                this.loading = false;
                return;
            }
            if (Number(this.startMinutes) >= 60 || Number(this.endMinutes) >= 60 || Number(this.startSeconds) >= 60 || Number(this.endSeconds) >= 60) {
                this.messageService.showError("Start/End Minute/Second field shouldn't be greater than or equal to 60");
                this.loading = false;
                return;
            }
            var strStartTime = this.startHours + ":" + this.startMinutes + ":" + this.startSeconds;
            var strEndTime = this.endHours + ":" + this.endMinutes + ":" + this.endSeconds;
            var strStartTimeAll = this.trimString(this.startDate) + " " + this.trimString(strStartTime);
            var strEndTimeAll = this.trimString(this.endDate) + " " + this.trimString(strEndTime);
            strStartTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strStartTimeAll, "MM/DD/YYYY HH:mm:ss");
            strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strEndTimeAll, "MM/DD/YYYY HH:mm:ss");
            var timeDiff1 = Math.abs(strStartTimeAllMs - strEndTimeAllMs);
            sessionStorage.setItem('timeDiff1', timeDiff1.toString());
            if (this.compareDatesForOthers(strStartTimeAll, currentDateTime)) {
                this.messageService.showError("Start date/time cannot be greater than current date/time");
                this.loading = false;
                return;
            }
            if (this.compareDatesForOthers(strEndTimeAll, currentDateTime)) {
                this.messageService.showError("End date/time cannot be greater than current date/time");
                this.loading = false;
                return;
            }
            if (this.compareDatesForOthers(strStartTimeAll, strEndTimeAll)) {
                this.messageService.showError("Start date/time cannot be greater than end date/time");
                this.loading = false;
                return;
            }
        }
        else if (this.selectedValue == "Whole Scenario") {
            const session = this.sessionService.session;
            this.selectedValue = "WholeScenario";
            strStartTimeAll = this.sessionService.convertTimestampIntoFormattedString(this.sessionService.session.testRun.st, "MM/DD/YYYY HH:mm:ss");
            strStartTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strStartTimeAll, "MM/DD/YYYY HH:mm:ss");
            if (session.testRun.running) {
                const currentDateTime = new Date(moment__WEBPACK_IMPORTED_MODULE_6__().tz(sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss'));
                const dateFormat = this.getDateFormat(currentDateTime);
                const currentDateTimeInMs = this.sessionService.convertFormattedStringIntoTimestamp(dateFormat);
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(currentDateTimeInMs);
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strEndTimeAll, "MM/DD/YYYY HH:mm:ss");
            }
            else {
                let endtime = this.sessionService.session.testRun.st + session.testRun.duration;
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(endtime);
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(strEndTimeAll, "MM/DD/YYYY HH:mm:ss");
            }
        }
        else {
            var today = new Date(moment__WEBPACK_IMPORTED_MODULE_6__().tz(sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss'));
            var date = (today.getMonth() + 1) + '/' + today.getDate() + '/' + today.getFullYear();
            var time = today.getHours() + ":" + today.getMinutes() + ":" + today.getSeconds();
            if (this.selectedValue == "Today") {
                today.setHours(0);
                today.setMinutes(0);
                today.setSeconds(0);
                var startTime = this.getDateFormat(today);
                var stTime = this.sessionService.convertFormattedStringIntoTimestamp(startTime);
                var etTime = date + " " + time;
                strStartTimeAllMs = stTime.toString();
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(etTime);
                strStartTimeAll = this.sessionService.convertTimestampIntoFormattedString(stTime, "MM/DD/YYYY HH:mm:ss");
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(Number(strEndTimeAllMs), "MM/DD/YYYY HH:mm:ss");
            }
            else if (this.selectedValue.includes("Minutes")) {
                var etTime = date + " " + time;
                let minuteVal = this.selectedValue.toString().replace(/^\D+/g, '');
                let timeInMs = parseInt(minuteVal) * 60 * 1000;
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(etTime);
                let strTime = Number(strEndTimeAllMs) - timeInMs;
                strStartTimeAll = this.sessionService.convertTimestampIntoFormattedString(strTime, "MM/DD/YYYY HH:mm:ss");
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(Number(strEndTimeAllMs), "MM/DD/YYYY HH:mm:ss");
                strStartTimeAllMs = strTime.toString();
            }
            else if (this.selectedValue.includes("hours") || this.selectedValue.includes("hour")) {
                var etTime = date + " " + time;
                let hoursVal = this.selectedValue.toString().replace(/^\D+/g, '');
                let timeInMs = parseInt(hoursVal) * 60 * 60 * 1000;
                strEndTimeAllMs = this.sessionService.convertFormattedStringIntoTimestamp(etTime);
                let strTime = Number(strEndTimeAllMs) - timeInMs;
                strStartTimeAll = this.sessionService.convertTimestampIntoFormattedString(strTime, "MM/DD/YYYY HH:mm:ss");
                strEndTimeAll = this.sessionService.convertTimestampIntoFormattedString(Number(strEndTimeAllMs), "MM/DD/YYYY HH:mm:ss");
                strStartTimeAllMs = strTime.toString();
            }
        }
        const url = `graphTime=${this.selectedValue}&startTime=${strStartTimeAll}&endTime=${strEndTimeAll}`;
        // Set URL parameters
        this.startTime = strStartTimeAll;
        this.endTime = strEndTimeAll;
        this.urlParam.strStartTime = strStartTimeAllMs;
        this.urlParam.strEndTime = strEndTimeAllMs;
        // Fetch graph key
        this.ndDdrHttpService.getGraphKey(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_14__["GraphKeyLoadedState"]) {
                let data = state.data;
                if (data.graphKey == 'Today') {
                    this.strGraphKey = 'LAST_DAY';
                    this.isFilterChanged = true;
                }
                else {
                    this.strGraphKey = data.graphKey;
                    this.isFilterChanged = true;
                }
                this.urlParam.preset = this._ddrData.getGraphKeyID(this.strGraphKey);
                this.commonService.loaderForDdr = true;
                this.urlParam.strGraphKey = this.strGraphKey;
                this.getIPData();
            }
        });
    }
    onTabClose(event) { this.graphTab = false; }
    onTabOpen(event) { this.graphTab = true; }
    formatter(val) { return val.toFixed(2); }
    /* Validating Number input */
    validateQty(event) {
        if ((event.charCode > 31 && (event.charCode < 48 || event.charCode > 57)) &&
            (event.target.value.includes('.'))) {
            return false;
        }
        else
            return true;
    }
    isIPByResp(rowData) {
        this.isIPByRespTime = true;
        this.responseTime = rowData.res;
        this.resData = rowData;
        this.urlParam.strTimeLabel = this.timeLabel;
    }
};
IpStatComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_15__["CavMessageService"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_4__["CavConfigService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__["DdrDataModelService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["NdDdrHttpService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_7__["DdrBreadcrumbService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_12__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_11__["BreadcrumbService"] },
    { type: src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_16__["CavLoggingService"] }
];
IpStatComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ip-stat',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ip-stat.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ip-stat/ip-stat.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ip-stat.component.scss */ "./src/app/pages/ddr/components/ip-stat/ip-stat.component.scss")).default]
    })
], IpStatComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ip-summary/ip-summary.component.css":
/*!**************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ip-summary/ip-summary.component.css ***!
  \**************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\r\n    height: 50px;\r\n    margin-left: 50%;\r\n    \r\n}\r\n\r\n:host>>>.ui-accordion .ui-accordion-content{\r\n    border: none !important; \r\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ip-summary/ip-summary.component.ts":
/*!*************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ip-summary/ip-summary.component.ts ***!
  \*************************************************************************/
/*! exports provided: IpSummaryComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "IpSummaryComponent", function() { return IpSummaryComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ddr-message.service */ "./src/app/pages/ddr/services/ddr-message.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/shared/cavLoggerService/cav-logging.service */ "./src/app/shared/cavLoggerService/cav-logging.service.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");















let IpSummaryComponent = class IpSummaryComponent {
    constructor(_router, commonService, _ddrData, breadcrumbService, messageService, ddrRequest, breadcrumb, sessionService, ndDdrHttpService, logger, elasticSearchService) {
        this._router = _router;
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.messageService = messageService;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.logger = logger;
        this.elasticSearchService = elasticSearchService;
        this.btCallOutInfoAgg = []; //BT Callout Summary Table Data
        this.btCalloutInfoInd = []; //BT Callout Details Table Data
        this.urlParam = {}; //Object to store filters like tierName, serverName, testRun, etc...
        this.queryParams = {}; // contains flowpath row-data(split-view case) or urlParam (ED-Case)
        this.loading = false;
        this.isAgent = true; // show DDAI Setting icon
        this.filterCriteria = ""; //used to show filter-criteria at top
        this.filterCriteriaArray = []; //used to show filter-criteria as array
        this.selectedBT = ""; //used to show selected BT name on BT Callout Details accordion
        this._maxFlowpathToProcess = 10000; //maximum number of flowpath to process
        this.showWarning = false; //used to show message when flowpath-count > _maxFlowpathToProcess
        this.showFPConfDia = false; //used to toggle Flowpath-configuration dialog 
        this.msgs = [];
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.filterIpName = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        this.completeIpName = '';
        this.isFilterFromSideBar = false; //check whether come from sidebar(cqm)
        this.showAutoInstrPopUp = false; // toggle DDAI dialog...
        this.displayAutoInst = false;
        this.ipUrl = '';
        this.aggCase = true;
        this.aggIpInfo = [];
        this.renamebackendNameMap = {};
        this.actualBackendNameMap = {};
        this.backendSubTypeNameMap = {};
        this.showMessage = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.breadcrumb = breadcrumb;
        this.otelMode = this._ddrData.otelMode;
    }
    ngOnChanges() {
        this.screenHeight = Number(this.commonService.screenHeight) - 235;
        if (this._ddrData.splitViewFlag) {
            this._ddrData.setInLogger("DDR::Flowpath", "IP Summary", "Open IP Summary Report");
            this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            this.breadcrumb.add({ label: 'BT IP Summary' });
            this._ddrData.splitViewBreadCrumbFlag = true;
        }
        if (this.columnData != undefined) { // columnData is Flowpath Row Data
            this.loading = true;
            this.urlParam = this.commonService.getData();
            if (this.urlParam.enableQueryCaching)
                this.commonService.enableQueryCaching = this.urlParam.enableQueryCaching;
            this.commonService.ipSummaryData = JSON.parse(JSON.stringify(this.columnData));
            this.queryParams = JSON.parse(JSON.stringify(this.columnData));
            if (this.queryParams) {
                if (!this.otelMode) {
                    let fpDuration = 0;
                    if (this.queryParams['fpDuration'] == '< 1')
                        fpDuration = 0;
                    else if (this.queryParams['fpDuration'].toString().includes(','))
                        fpDuration = this.queryParams.fpDuration.toString().replace(/,/g, "");
                    else
                        fpDuration = this.queryParams.fpDuration;
                    this.strEndTime = (Number(this.queryParams.startTimeInMs) + Number(fpDuration)).toString();
                }
                else {
                    this.strEndTime = (this.queryParams.startTimeInMs) + Math.ceil(this.queryParams.selfResponseTime);
                }
                this.strStartTime = this.queryParams.startTimeInMs;
            }
            this.queryId1 = this.randomNumber();
            this.getAggBTCallOutInfo();
        }
        /** Condition whether to show DDAI Icon */
        if (this.queryParams.instanceType == 'Java' || this.queryParams.instanceType == 'DotNet' || this.queryParams.instanceType == 'DotNetC' || this.queryParams.Instance_Type == 'Java' || this.queryParams.Instance_Type == 'DotNet' || this.queryParams.Instance_Type == 'DotNetC') {
            this.isAgent = true;
        }
        else {
            this.isAgent = false;
        }
    }
    ngOnInit() {
        this.screenHeight = Number(this.commonService.screenHeight) - 135;
        this.commonService.currentReport = "IP Summary";
        this.queryId1 = this.randomNumber();
        if (this._ddrData.splitViewFlag == false) { //ED, BT-Trend case...
            this.breadcrumb.add({ label: 'BT IP Summary', routerLink: '/ddr/ipsummary' });
            this.urlParam = this.commonService.getData();
            this.commonService.isToLoadSideBar = true;
            this.queryParams = this.urlParam;
            if (this.queryParams == undefined) {
                this.queryParams = this.commonService.ipSummaryFilters;
            }
            if (this.queryParams && this.queryParams.fpDuration != undefined) {
                let fpDuration = 0;
                if (this.queryParams['fpDuration'] == '< 1')
                    fpDuration = 0;
                else if (this.queryParams['fpDuration'].toString().includes(','))
                    fpDuration = this.queryParams.fpDuration.toString().replace(/,/g, "");
                else
                    fpDuration = this.queryParams.fpDuration;
                this.strEndTime = this.queryParams.startTimeInMs + Number(fpDuration);
                this.strStartTime = this.queryParams.startTimeInMs;
            }
            else if (this.queryParams) {
                this.strEndTime = this.queryParams.endTime;
                this.strStartTime = this.queryParams.startTime;
            }
            this.getAggBTCallOutInfo();
        }
        this.sideBarIpSummary = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "IP Summary") {
                this.commonService.isFilterFromSideBar = true;
                this.getAggBTCallOutInfo();
            }
        });
        /**cav-table header path */
        if (!this.otelMode) {
            this.relativePathForCalloutSummaryTable = "ddr/ip-summary/ip-summary.json";
            this.relativePathForCalloutDetailTable = "ddr/ip-summary/bt-callout-detail.json";
        }
        else {
            this.relativePathForCalloutSummaryTable = "ddr/ip-summary/ip-summary-elasticSearch.json";
            this.relativePathForCalloutDetailTable = "ddr/ip-summary/bt-callout-detail-elasticSearch.json";
        }
        this._ddrData.passMesssage$.subscribe((mssg) => { this.showMessageSave(mssg); });
        /** Check whether to show Dynamic Diagnostic icon or not */
        this.isAgent = (this.queryParams.instanceType == 'Java' || this.queryParams.instanceType == 'DotNet' || this.queryParams.instanceType == 'DotNetC' || this.queryParams.Instance_Type == 'Java' || this.queryParams.Instance_Type == 'DotNet' || this.queryParams.Instance_Type == 'DotNetC');
    }
    clickButtonEvent(event) {
        var _a, _b, _c;
        this.logger.debug(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_13__["DDR"], 'clickButtonEvent', 'event ', event);
        const action = (_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action;
        const row = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row;
        if (action === "clickable") {
            this.openIndIP(row);
        }
        if (action === "FPByIP" || action === "FPByResTime") {
            this.openFPByIntegrationReport(row, action);
        }
    }
    createFilterCriteria() {
        this.filterCriteria = '';
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.filterIpName = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        this.completeIpName = '';
        let ipFilters = this.commonService.ipSummaryFilters;
        let dcName = "";
        if (this.sessionService.preSession.multiDc === true)
            dcName = this._ddrData.dcName;
        if (this.columnData != undefined) {
            if (this.queryParams.tierName)
                this.filterCriteria += " Tier=" + this.queryParams.tierName;
            if (this.queryParams.serverName && this.queryParams.serverName != "NA")
                this.filterCriteria += ", Server=" + this.queryParams.serverName;
            if (this.queryParams.appName && this.queryParams.appName != "NA")
                this.filterCriteria += ", Instance=" + this.queryParams.appName;
        }
        else {
            if (this.commonService.isValidParamInObj(ipFilters, "tierName")) {
                if (ipFilters['tierName'].length > 32) {
                    this.filterTierName += 'Tier=' + ipFilters['tierName'].substring(0, 32) + '...';
                    this.completeTier = ipFilters['tierName'];
                }
                else
                    this.filterTierName += 'Tier=' + ipFilters['tierName'];
            }
            if (this.commonService.isValidParamInObj(ipFilters, "serverName")) {
                if (ipFilters['serverName'].length > 32) {
                    this.filterServerName = ', Server=' + ipFilters['serverName'].substring(0, 32) + '...';
                    this.completeServer = ipFilters['serverName'];
                }
                else
                    this.filterServerName = ', Server=' + ipFilters['serverName'];
            }
            if (this.commonService.isValidParamInObj(ipFilters, "appName")) {
                if (ipFilters['appName'].length > 32) {
                    this.filterInstanceName = ', Instance=' + ipFilters['appName'].substring(0, 32) + '...';
                    this.completeInstance = ipFilters['appName'];
                }
                else
                    this.filterInstanceName = ', Instance=' + ipFilters['appName'];
            }
        }
        if (this.commonService.isValidParamInObj(ipFilters, "startTimeInDateFormat")) {
            this.filterCriteria += ', Start Time=' + ipFilters['startTimeInDateFormat'];
        }
        if (this.commonService.isValidParamInObj(ipFilters, "endTimeInDateFormat")) {
            this.filterCriteria += ', End Time=' + ipFilters['endTimeInDateFormat'];
        }
        if (this.commonService.isValidParamInObj(ipFilters, "urlName")) {
            this.filterCriteria += ', BT=' + decodeURIComponent(ipFilters['urlName']);
        }
        if (this.commonService.isValidParamInObj(ipFilters, "integrationPointName")) {
            let ipSummaryIntegationPoint = ipFilters['integrationPointName'].toString().replace(/&#46;/g, ".");
            if (ipSummaryIntegationPoint.length > 32) {
                this.filterIpName = ', IntegrationPoint=' + ipSummaryIntegationPoint.substring(0, 32) + '...';
                this.completeIpName = ipSummaryIntegationPoint;
            }
            else
                this.filterIpName = ', IntegrationPoint=' + ipSummaryIntegationPoint;
        }
        if (!this.commonService.isValidParamInObj(ipFilters, "tierName") && !this.commonService.isValidParamInObj(ipFilters, "serverName") && !this.commonService.isValidParamInObj(ipFilters, "appName") && this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
    }
    openFPByIntegrationReport(rowData, flag) {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            try {
                let backendIdUrl = '';
                backendIdUrl += 'testRun=' + this.urlParam.testRun + '&backendName=' + rowData.backendName;
                // Get the backend ID
                const result = yield this.ndDdrHttpService.getBackendId(backendIdUrl);
                if (!result.success) {
                    this.commonService.showError(result.errorMessage);
                    return;
                }
                this.backendId = result.data;
                this.commonService.IPByFPData.backendName = rowData.backendName;
                let fpdata = {};
                fpdata["tierId"] = this.commonService.ipSummaryData.tierId || this.queryParams.tierId;
                fpdata["serverId"] = this.commonService.ipSummaryData.serverid || this.queryParams.serverId;
                fpdata["appId"] = this.commonService.ipSummaryData.appid || this.queryParams.appId;
                fpdata["tierName"] = this.commonService.ipSummaryData.tierName || this.queryParams.tierName;
                fpdata["serverName"] = this.commonService.ipSummaryData.serverName || this.queryParams.serverName;
                fpdata["appName"] = this.commonService.ipSummaryData.appName || this.queryParams.appName;
                fpdata["backendId"] = this.backendId;
                fpdata['minresTimeOfBackend'] = rowData.minRespTime;
                if (flag === 'FPByResTime') {
                    fpdata['maxresTimeOfBackend'] = rowData.maxRespTime;
                }
                fpdata['avgresTimeOfBackend'] = rowData.avgResponseTime;
                fpdata["startTime"] = this.commonService.ipSummaryData.startTime || this.queryParams.startTime;
                fpdata['endTime'] = this.commonService.ipSummaryData.endTime || this.queryParams.endTime;
                this._ddrData.splitViewFlag = false;
                this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].IPSUMMARY;
                this._ddrData.IPByFPFlag = true;
                this._ddrData.isFromtrxFlow = false;
                this._ddrData.isFromtrxSideBar = false;
                this.commonService.isFilterFromSideBar = false;
                this._ddrData.FromexpFlag = 'false';
                this.commonService.IPByFPData = fpdata;
                if (this._router.url.indexOf("/home/ddrCopyLink/") != -1)
                    this._router.navigate(['/home/ddrCopyLink/flowpath']);
                else
                    this._router.navigate(['/ddr/flowpath']);
            }
            catch (error) {
                this.logger.error(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_13__["DDR"], 'openFPByIntegrationReport', 'Error in opening FP Report ', error);
            }
        });
    }
    getAggBTCallOutInfo() {
        this.loading = true;
        let rowData;
        if (this.commonService.openIPSummary === true) {
            rowData = this.commonService.ipSummaryData;
        }
        let url = '';
        if (this.commonService.enableQueryCaching == 1) {
            url += "cacheId=" + this.urlParam.testRun + "&testRun=" + this.urlParam.testRun;
            this.ipUrl += "cacheId=" + this.urlParam.testRun + "&testRun=" + this.urlParam.testRun;
        }
        else {
            url += "testRun=" + this.urlParam.testRun;
            this.ipUrl += "testRun=" + this.urlParam.testRun;
        }
        let urlParam1 = "";
        if (this.commonService.isFilterFromSideBar && Object.keys(this.commonService.ipSummaryFilters).length != 0) { // sidebar filters to Ip Summary 
            let ipSummaryParam = this.commonService.ipSummaryFilters;
            if (this.commonService.isValidParamInObj(ipSummaryParam, 'ndeProtocol') && this.commonService.isValidParamInObj(ipSummaryParam, 'pubicIP') && this.commonService.isValidParamInObj(ipSummaryParam, 'publicPort') && this.commonService.isValidParamInObj(ipSummaryParam, 'ndeTestRun')) {
                if (this.commonService.enableQueryCaching == 1) {
                    url = 'cacheId=' + ipSummaryParam['ndeTestRun'] + '&testRun=' + ipSummaryParam['ndeTestRun'];
                    this.ipUrl = "cacheId=" + ipSummaryParam['ndeTestRun'] + "&testRun=" + ipSummaryParam['ndeTestRun'];
                }
                else {
                    url = 'testRun=' + ipSummaryParam['ndeTestRun'];
                    this.ipUrl = "testRun=" + ipSummaryParam['ndeTestRun'];
                }
            }
            urlParam1 = this.commonService.makeParamStringFromObj(ipSummaryParam);
            url += urlParam1;
        }
        else if (rowData == undefined) { // ED TO DDR CASE - ROWDATA WILL BE UNDEFINED
            urlParam1 = "&tierId=" + this.queryParams.tierId + "&serverId=" + this.queryParams.serverId + "&appId=" + this.queryParams.appId +
                "&tierName=" + this.queryParams.tierName + "&serverName=" + this.queryParams.serverName + "&appName=" + this.queryParams.appName +
                "&strStartTime=" + this.strStartTime + "&strEndTime=" + (Number(this.strEndTime) + 1000) +
                "&flowpathID=" + this.queryParams.flowpathInstance + "&strGroup=url&statusCode=-2" + "&showCount=false" +
                "&urlIndex=undefined" + "&urlName=" + this.queryParams.urlName + "&integrationPointName=NA" + "&integrationPointId=NA";
            this.commonService.ipSummaryFilters = this.commonService.makeObjectFromUrlParam(urlParam1);
            setTimeout(() => {
                this.messageService.sendMessage(this.commonService.ipSummaryFilters);
            }, 2000);
            url += urlParam1 + '&queryId=' + this.queryId1;
        }
        this.isCancelQuerydata = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        //toggle for otelMode
        if (!this.otelMode) {
            this.fetchDataFromPsql(url);
        }
        else {
            url += `&traceId=${this.columnData.TraceId}&serviceName=${this.columnData.serviceName}`;
            this.fetchDataFromElasticSearch(url);
        }
    }
    fetchDataFromPsql(url) {
        this.ndDdrHttpService.getBTCallOutInfoAGGReportData(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["BTCallOutInfoAGGLoadedState"]) {
                this.assignAggBTCalOutInfo(state.data);
                this.loading = false;
            }
        }, (error) => {
            this.logger.error(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_13__["DDR"], 'getAggBTCallOutInfo', 'Error in getBTCallOutInfoAGGReportData ', error);
            this.commonService.showError(error);
            this.loading = false;
        });
    }
    /**
       * Fetches data from Elasticsearch using the specified query parameters.
       *
       * @param url The query parameters to use when constructing the query.
       */
    fetchDataFromElasticSearch(url) {
        const reqPayload = this.ndDdrHttpService.createPayloadForPOSTCall(url);
        if (window['logLevel'] > 1) {
            console.log("********reqPayload******", reqPayload);
        }
        const resFields = [];
        const elasticQuery = this.elasticSearchService.buildElasticSearchQuery(reqPayload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].IPSUMMARY);
        if (window['logLevel'] > 1) {
            console.log("********elasticQuery******", elasticQuery);
        }
        this.elasticSearchService.search(elasticQuery).subscribe(res => {
            this.elasticSearchData = res;
            if (window['logLevel'] > 1) {
                console.log('Search results from Elasticsearch:', res);
            }
            this.processElasticData(this.elasticSearchData);
            this.btCallOutInfoAgg = this.calloutSummaryData;
            this.btCalloutInfoInd = this.calloutDetailDataArray;
            this.filterCriteria = this.elasticSearchService.filtercriteria;
            // Split by comma, trim spaces, and filter out empty values
            this.filterCriteriaArray = this.filterCriteria
                .split(',')
                .map(item => item.trim())
                .filter(item => item.length > 0);
            this.loading = false;
        }, error => {
            console.error('Error in getting data from Elasticsearch:', error);
            this.btCallOutInfoAgg = [];
            this.btCalloutInfoInd = [];
        });
    }
    /**
        * Processes the data returned from Elasticsearch
        * and assigns it to the local variables.
        *
        * @param elasticData The response from Elasticsearch
        */
    processElasticData(elasticData) {
        if (elasticData && elasticData.aggregations) {
            this.elasticIPSummaryDBAggData = elasticData.aggregations.span_types.buckets.db;
            this.elasticIPSummaryHttpAggData = elasticData.aggregations.span_types.buckets.http;
            if (this.relativePathForCalloutSummaryTable) {
                this.calloutSummaryData = (this.BTCalloutSummary(this.elasticIPSummaryDBAggData, this.elasticIPSummaryHttpAggData));
            }
            if (this.relativePathForCalloutDetailTable) {
                this.calloutDetailDataArray = (this.BTCalloutDetails(elasticData));
            }
        }
    }
    //process elastic Data for BtCalloutSummary
    BTCalloutSummary(dbData, httpData) {
        const minHttpCalloutDuration = (httpData.duration_stats.min) / 1000000 || 0;
        const minDBCalloutDuration = (dbData.duration_stats.min) / 1000000 || 0;
        return [{
                url: this.columnData["urlQueryParamStr"],
                minHttpCalloutDuration: minHttpCalloutDuration,
                maxHttpCalloutDuration: (httpData.duration_stats.max) / 1000000 || 0,
                totalHttpCalloutCount: (httpData.duration_stats.count) / 1000000 || 0,
                minDBCalloutDuration: minDBCalloutDuration,
                maxDBCalloutDuration: (dbData.duration_stats.max) / 1000000 || 0,
                totalDBCalloutCount: dbData.duration_stats.count || 0,
                avgCalloutDuration: (minHttpCalloutDuration + minDBCalloutDuration) / 2 || 0
            }];
    }
    //process elastic Data for BTCalloutDetails
    BTCalloutDetails(data) {
        let key;
        let avg;
        let count;
        let max;
        let min;
        let sum;
        let backendKey;
        const spanTypes = ["db", "http", "messaging", "others"];
        const results = [];
        for (const type of spanTypes) {
            const buckets = data.aggregations.span_types.buckets[type];
            const ipStats = buckets.by_ip.buckets;
            for (const ipItem of ipStats) {
                backendKey = ipItem.key;
                key = ipItem.key.includes('_') ? ipItem.key.split('_')[0] : ipItem.key;
                avg = (ipItem.ip_duration_stats.avg) / 1000000;
                count = ipItem.ip_duration_stats.count;
                max = (ipItem.ip_duration_stats.max) / 1000000;
                min = (ipItem.ip_duration_stats.min) / 1000000;
                sum = (ipItem.ip_duration_stats.sum) / 1000000;
                results.push({
                    renamebackendIPname: backendKey || "-",
                    backendType: key || "-",
                    totalDuration: sum || 0,
                    avgDuration: avg || 0,
                    maxDuration: max || 0,
                    minDuration: min || 0,
                    count: count || 0,
                    ipType: type
                });
            }
        }
        return results;
    }
    assignAggBTCalOutInfo(data) {
        this.loading = false;
        this.commonService.isFilterFromSideBar = false;
        this.isCancelQuerydata = true;
        if (data.hasOwnProperty('Status')) {
            if (data.Status !== "" && data.Status !== "NA" && data.Status !== undefined) {
                this.commonService.showError(data.Status);
            }
        }
        this.btCallOutInfoAgg = data.data;
        if (this.btCallOutInfoAgg.length !== 1 && !this.otelMode) {
            this.relativePathForCalloutSummaryTable = "ddr/ip-summary/ip-summary-agg.json";
        }
        else if (this.btCallOutInfoAgg.length !== 1 && this.otelMode) {
            this.relativePathForCalloutSummaryTable = "ddr/ip-summary/ip-summary-agg-elasticSearch.json";
        }
        if (this.queryParams && this.queryParams.Instance_Type) {
            this.displayAutoInst = true;
        }
        else {
            this.getVectorIds();
        }
        this.defaultSort(this.btCallOutInfoAgg, 'maxCalloutCount', '-1');
        this.commonService.ipSummaryFilters['startTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(data.strStartTime), "MM/DD/YYYY HH:mm:ss");
        this.commonService.ipSummaryFilters['endTimeInDateFormat'] = this.sessionService.convertTimestampIntoFormattedString(Number(data.strEndTime), "MM/DD/YYYY HH:mm:ss");
        this.createFilterCriteria();
        if (this.btCallOutInfoAgg.length > 0) {
            this.queryId1 = undefined;
            this.queryId2 = this.randomNumber();
            this.openIndIP(this.btCallOutInfoAgg[0]);
        }
        else if (this.btCallOutInfoAgg.length == 0) {
            this.loading = false;
            this.btCalloutInfoInd = [];
            this.selectedBT = '';
            this.TotalCalloutcount = '';
        }
    }
    openIndIP(rowData) {
        this.isCancelQuerydata = false;
        this.selectedBT = ` [ BT= ${rowData.url}`;
        this.loading = true;
        this.selectedRowInfo = rowData;
        /** Message:- Displaying only the top 10,000 Flowpaths' Data */
        this.showWarning = Number(rowData.fpCount) >= Number(this._maxFlowpathToProcess);
        /** Shows a dialog if 'fpCount' >= 10000 to alert about operation duration to the user */
        this.showMessage = Number(rowData.fpCount) >= 10000;
        if (this.showMessage) {
            setTimeout(() => {
                this.showMessage = false;
            }, 5000);
        }
        let queryParams = "";
        let indiBTCallOutInfo_url = this.ipUrl;
        this.limit = this._maxFlowpathToProcess;
        this.offset = 0;
        this.urlNameIP = rowData.url;
        this.urlIndexIP = rowData.urlID;
        if (this.commonService.isFilterFromSideBar) { // side bar applied filter
            const ipSummaryParam = this.commonService.ipSummaryFilters;
            const endTime = (Number(ipSummaryParam.strEndTime) + 1000);
            queryParams = "&tierName=" + ipSummaryParam.tierName + "&tierId=" + ipSummaryParam.tierId + "&serverId=" + ipSummaryParam.serverId + "&appId=" + ipSummaryParam.appId + "&strStartTime=" + ipSummaryParam.strStartTime + "&strEndTime=" + endTime + "&statusCode=-2" + "&showCount=false&urlIndex=" + rowData.urlID + "&flowpathRange=" + this._maxFlowpathToProcess + "&limit=" + this.limit + "&offset=" + this.offset + "&flowpathID=" + rowData['flowpathInstance'];
        }
        else {
            const endTime = (Number(this.strEndTime) + 1000);
            queryParams = "&tierName=" + this.queryParams.tierName + "&tierId=" + this.queryParams.tierId + "&serverId=" + this.queryParams.serverId + "&appId=" + this.queryParams.appId + "&strStartTime=" + this.strStartTime + "&strEndTime=" + endTime + "&statusCode=-2" + "&showCount=false&urlIndex=" + rowData.urlID + "&flowpathRange=" + this._maxFlowpathToProcess + "&limit=" + this.limit + "&offset=" + this.offset + "&flowpathID=" + this.queryParams.flowpathInstance;
        }
        indiBTCallOutInfo_url = this.ipUrl + queryParams + '&queryId=' + this.queryId2;
        this.isCancelQuerydata = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        this.ndDdrHttpService.getBTCallOutInfoINDReportData(indiBTCallOutInfo_url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["BTCallOutInfoINDLoadedState"]) {
                this.assignIndBTCallOutData(state.data);
            }
        });
    }
    assignIndBTCallOutData(res) {
        let data = this.removeEmptyDurationProperties(res);
        this.showMessage = false;
        this.loading = false;
        this.isCancelQuerydata = true;
        if (this.aggCase == true) {
            this.TotalCalloutcount = `, Total Callout = ${this.formatter((Object.keys(data['actualBackendNameMap'])).length)} ]`;
            this.filterCriteriaagg = this.selectedBT + this.TotalCalloutcount;
        }
        if (data.hasOwnProperty('Status')) {
            if (data.Status !== "" && data.Status !== "NA" && data.Status !== undefined) {
                this.commonService.showError(data.Status);
            }
        }
        this.commonService.isFilterFromSideBar = false;
        let backendCalloutInfo = data.dataObj;
        let actualBackendNameMap = data.actualBackendNameMap;
        if (data.aggDataForBackends && Object.keys(data.aggDataForBackends).length > 0) {
            this.aggCase = true;
            this.renamebackendNameMap = data.renamebackendNameMap;
            this.actualBackendNameMap = data.actualBackendNameMap;
            this.backendSubTypeNameMap = data.backendSubTypeNameMap;
            this.aggIpInfo = data.aggDataForBackends;
        }
        else {
            this.aggCase = false;
            this.btCalloutInfoInd = this.convertMaptoArr(backendCalloutInfo, actualBackendNameMap);
        }
    }
    removeEmptyDurationProperties(data) {
        const aggData = data.aggDataForBackends;
        for (const key in aggData) {
            if (aggData[key].duration.length === 0) {
                delete aggData[key];
            }
        }
        return data;
    }
    convertMaptoArr(backendCalloutInfo, actualBackendNameMap) {
        let arr = Object.keys(backendCalloutInfo);
        let bakendCallInfoModified = [];
        let count = 0;
        arr.forEach((val, index) => {
            let backend = backendCalloutInfo[val];
            if (this.commonService.ipSummaryFilters['integrationPointName'] !== 'NA' && this.commonService.ipSummaryFilters['integrationPointName'] !== undefined) {
                this.commonService.ipSummaryFilters['integrationPointName'].forEach((val, index) => {
                    let IPname = this.commonService.ipSummaryFilters['integrationPointName'][index];
                    if (IPname == actualBackendNameMap[backend['backendID']]) {
                        bakendCallInfoModified.push({
                            "backendName": actualBackendNameMap[backend['backendID']].replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n"),
                            "minCount": backend['minCount'],
                            "maxCount": backend['maxCount'], "totalCount": backend['totalCount'], "minRespTime": backend['minRespTime'],
                            "maxRespTime": backend['maxRespTime'], "avgResponseTime": backend['avgResponseTime'], "totalRespTime": backend['totalRespTime'],
                            "minNetworkDelay": this.formatterFixed(backend['minNetworkDelay']), "maxNetworkDelay": this.formatterFixed(backend['maxNetworkDelay']),
                            "AverageNetworkDelay": this.formatterFixed(backend['AverageNetworkDelay']), "totalNetworkDelay": this.formatterFixed(backend['totalNetworkDelay'])
                        });
                        count += backend['totalCount'];
                    }
                });
            }
            else {
                bakendCallInfoModified.push({
                    "backendName": actualBackendNameMap[backend['backendID']].replace(/&#044;/g, ",").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'").replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "\|").replace(/&#46;/g, ".").replace(/&#58/g, ":").replace(/&#011;/g, "\r\n"), "minCount": backend['minCount'], "maxCount": backend['maxCount'], "totalCount": backend['totalCount'], "minRespTime": backend['minRespTime'], "maxRespTime": backend['maxRespTime'], "avgResponseTime": backend['avgResponseTime'], "totalRespTime": backend['totalRespTime'],
                    "minNetworkDelay": this.formatterFixed(backend['minNetworkDelay']), "maxNetworkDelay": this.formatterFixed(backend['maxNetworkDelay']),
                    "AverageNetworkDelay": this.formatterFixed(backend['AverageNetworkDelay']), "totalNetworkDelay": this.formatterFixed(backend['totalNetworkDelay'])
                });
                count += backend['totalCount'];
            }
        });
        if (this.aggCase == false)
            this.TotalCalloutcount = ", Total Callout = " + this.formatter(count) + " ]";
        return bakendCallInfoModified;
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        let hostDcName;
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.urlParam.testRun = this._ddrData.testRun;
            if (hostDcName.lastIndexOf('ALL/') !== -1)
                hostDcName = hostDcName.substring(0, hostDcName.lastIndexOf('/'));
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        this.logger.debug(src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_13__["DDR"], 'getHostUrl', 'hostDcName = ', hostDcName);
        return hostDcName;
    }
    formatter(data) {
        if (Number(data) && Number(data) > 0) {
            return Number(data).toLocaleString();
        }
        else {
            return data;
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    defaultSort(tempData, field, order) {
        if (order == -1) {
            var temp = (field);
            order = 1;
            tempData = tempData.sort(function (a, b) {
                var value = Number(a[temp]);
                var value2 = Number(b[temp]);
                return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
            });
        }
        else {
            var temp = (event["field"]);
            order = -1;
            //asecding order
            tempData = tempData.sort(function (a, b) {
                var value = Number(a[temp]);
                var value2 = Number(b[temp]);
                return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
            });
        }
        this.btCallOutInfoAgg = [];
        if (tempData) {
            tempData.map((rowdata) => { this.btCallOutInfoAgg = this.Immutablepush(this.btCallOutInfoAgg, rowdata); });
        }
    }
    valEnteredKeyN(event) {
        if ((event.keyCode >= 48 && event.keyCode <= 57) || (event.keyCode == 0) || (event.keyCode == 8))
            return true;
        else
            return false;
    }
    showflowpathConfDialogue() {
        this.showFPConfDia = true;
    }
    applyFlowpathConfiguration() {
        this.showFPConfDia = false;
        this.openIndIP(this.selectedRowInfo);
    }
    closeDialog() {
        this.showFPConfDia = false;
    }
    formatterFixed(value) {
        if (!isNaN(value)) {
            value = (Number(value)).toFixed(3).toLocaleString();
            if (value == 0)
                value = "0";
            return value;
        }
        else
            return value;
    }
    /** Auto Instrumentation DDAI */
    getIdFortier(data) {
        return data.trim().split(":");
    }
    getVectorIds() {
        let ipFilter = this.commonService.ipSummaryFilters;
        if (this.commonService.isValidParameter(ipFilter['serverName']) && this.commonService.isValidParameter(ipFilter['appName'])) {
            this.displayAutoInst = true;
            let urlForid = this.getHostUrl() + "/" + this.urlParam.product + "/analyze/drill_down_queries/" + "NDAjaxController.jsp?strOperName=getTSAname&testRun=" + this.urlParam.testRun + "&tierName=" + ipFilter['tierName'] + "&serverName=" + ipFilter['serverName'] + "&appName=" + ipFilter['appName'];
            return this.ddrRequest.getDataUsingGet(urlForid).subscribe(data => {
                this.getAgentInfo(data);
            });
        }
        else {
            this.displayAutoInst = false;
        }
    }
    getAgentInfo(res) {
        this.vecId = this.getIdFortier(res['_body']);
        this.commonService.ipSummaryFilters['tierId'] = this.vecId[0].trim();
        this.commonService.ipSummaryFilters['serverId'] = this.vecId[1].trim();
        this.commonService.ipSummaryFilters['appId'] = this.vecId[2].trim();
        let url = '';
        url = "testRun=" + this.urlParam.testRun +
            "&tierId=" + this.vecId[0].trim() + "&serverId=" + this.vecId[1].trim() + "&appId=" + this.vecId[2].trim();
        this.ndDdrHttpService.getAgentType(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["AgentTypeLoadedState"]) {
                this.agentType = state.data;
            }
        });
    }
    openAutoInstDialog() {
        let testRunStatus;
        let AgentType;
        let ipFilter = this.commonService.ipSummaryFilters;
        let url;
        url = 'testRun=' + this.urlParam.testRun;
        this.ndDdrHttpService.getTRStatus(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["TestRunStatusLoadedState"]) {
                testRunStatus = state.data;
                testRunStatus = testRunStatus.data;
                if (testRunStatus.length != 0) {
                    if (this.queryParams && this.queryParams.Instance_Type) {
                        this.agentType = this.queryParams.Instance_Type;
                    }
                    else {
                        this.agentType = this.agentType;
                    }
                    if (this.agentType == undefined) {
                        this.agentType = localStorage.getItem("Instance_type_BT");
                        localStorage.removeItem("Instance_type_BT");
                    }
                    AgentType = this.agentType.toLowerCase() === 'java' ? 'Java' : this.agentType.toLowerCase() === 'dotnet' ? 'DotNet' : this.agentType.toLowerCase() === 'dotnetc' ? 'DotNetC' : AgentType;
                    this.showAutoInstrPopUp = true;
                    this.argsForAIDDSetting = [ipFilter['appName'], ipFilter['appId'], AgentType, ipFilter['tierName'],
                        ipFilter['serverName'], ipFilter['serverId'], "-1", ipFilter['urlName'], "DDR", testRunStatus[0].status, this.urlParam.testRun];
                }
                else {
                    this.showAutoInstrPopUp = false;
                    alert("Could not start instrumentation, test is not running");
                    return;
                }
            }
        });
    }
    startInstrumentation(result) {
        this.showAutoInstrPopUp = false;
        alert(result);
    }
    closeAIDDDialog(isCloseAIDDDialog) {
        this.showAutoInstrPopUp = isCloseAIDDDialog;
    }
    ngOnDestroy() {
        this.sideBarIpSummary.unsubscribe();
    }
    assignCallOutCount(event) {
        this.TotalCalloutcount = ", Total Callout = " + this.formatter(event) + " ]";
        this.filterCriteriaagg = this.selectedBT + this.TotalCalloutcount;
    }
    closeMessageDialog() {
        this.showMessage = false;
    }
    randomNumber() {
        return (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        let queryId = "";
        if (this.queryId1) {
            queryId = this.queryId1;
        }
        else {
            queryId = this.queryId2;
        }
        url = "testRun=" + this.urlParam.testRun + "&queryId=" + queryId + "&tierName=" + this.queryParams.tierName;
        this.isCancelQuery = false;
        this.ndDdrHttpService.getCancelQueryResult(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["CancelQueryLoadedState"]) {
                return state.data;
            }
        });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    showMessageSave(mssg) {
        this.msgs = [];
        if (mssg == "Query Saved") {
            let smsg = "Query Saved as " + this._ddrData.saveMessage;
            this.msgs.push({ severity: 'success', summary: 'Success Message', detail: smsg });
        }
        else if (mssg == "Query Already Defined")
            this.msgs.push({ severity: 'error', summary: 'Error Message', detail: mssg });
        else
            this.msgs.push({ severity: 'error', summary: 'Error Message', detail: mssg });
    }
};
IpSummaryComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_7__["MessageService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_9__["BreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__["SessionService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["NdDdrHttpService"] },
    { type: src_app_shared_cavLoggerService_cav_logging_service__WEBPACK_IMPORTED_MODULE_13__["CavLoggingService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_14__["ElasticsearchQueryService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], IpSummaryComponent.prototype, "columnData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('downloadMenu')
], IpSummaryComponent.prototype, "downloadMenu", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('cavTableRef')
], IpSummaryComponent.prototype, "cavTableRef", void 0);
IpSummaryComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ip-summary',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ip-summary.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ip-summary/ip-summary.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ip-summary.component.css */ "./src/app/pages/ddr/components/ip-summary/ip-summary.component.css")).default]
    })
], IpSummaryComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/metadata/metadata.component.css":
/*!**********************************************************************!*\
  !*** ./src/app/pages/ddr/components/metadata/metadata.component.css ***!
  \**********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\r\n    height: 50px;\r\n    margin-left: 50%;\r\n}\r\n\r\n\r\n.group-left{\r\n    float:left;\r\n    padding-top: 4px;\r\n}\r\n\r\n\r\n.group-right{\r\n    float:right;\r\n    padding-top: 4px;\r\n}\r\n\r\n\r\n\r\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/metadata/metadata.component.ts":
/*!*********************************************************************!*\
  !*** ./src/app/pages/ddr/components/metadata/metadata.component.ts ***!
  \*********************************************************************/
/*! exports provided: MetadataComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MetadataComponent", function() { return MetadataComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs */ "./node_modules/rxjs/_esm2015/index.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");


//import { Http, Response } from '@angular/http';
//import { Observable } from 'rxjs';

//import { Http } from '@angular/http';

//import { Router } from '@angular/router';




let MetadataComponent = class MetadataComponent {
    constructor(commonService, breadcrumbService, _router, ddrRequest) {
        this.commonService = commonService;
        this.breadcrumbService = breadcrumbService;
        this._router = _router;
        this.ddrRequest = ddrRequest;
        this.loading = false;
        this.metadataAccordion = false;
        this.mappingAccordion = false;
    }
    ngOnInit() {
        this.loading = true;
        this.urlParam = this.commonService.getData();
        this.mappingAccordion = true;
        this.topologyEntity(0);
        if (this._router.url.indexOf('/home/ED-ddr/flowpath') != -1)
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].BTTREND;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].FLOWPATH);
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].FPTOMD);
        this.fillData();
        this.commonService.isToLoadSideBar = false;
        this.screenHeight = Number(this.commonService.screenHeight) - 130;
    }
    topologyEntity(type) {
        var url = '';
        if (this.commonService.host != undefined && this.commonService.host != '' && this.commonService.host != null) {
            if (this.commonService.protocol && this.commonService.protocol.endsWith("://"))
                url = this.commonService.protocol + this.commonService.host + ':' + this.commonService.port;
            else if (this.commonService.protocol)
                url = this.commonService.protocol + "://" + this.commonService.host + ':' + this.commonService.port;
            else
                url = "// " + this.commonService.host + ':' + this.commonService.port;
        }
        else {
            url = this.commonService.getHostUrl();
        }
        url += '/' + this.urlParam['product'] + '/v1/cavisson/netdiagnostics/webddr/fetchAllMetaData/' + (this.urlParam['testRun'] || sessionStorage.getItem("testRun")) + '?&flag=' + type;
        this.ddrRequest.getDataUsingGet(url).subscribe((data) => {
            this.topologyData = data;
            this.mData();
            if (this.mappingAccordion) {
                this.onMappingTabOpen();
            }
            if (this.metadataAccordion) {
                this.onTopologyEntityTab();
            }
        });
    }
    mData() {
        this.tierMdata = this.topologyData['tiers'];
        this.serverMdata = this.topologyData['servers'];
        this.instanceMdata = this.topologyData['instances'];
        this.methodMdata = this.topologyData['methods'];
        this.backendMdata = this.topologyData['backends'];
        this.classMdata = this.topologyData['class'];
        this.packageMdata = this.topologyData['packages'];
        this.btMdata = this.topologyData['bt'];
        this.pqMdata = this.topologyData['pq'];
        this.tableMdata = this.topologyData['table_records'];
        this.mapMdata = this.topologyData['T_S_I'];
        this.loading = false;
    }
    fillData() {
        this.screenHeight = Number(this.commonService.screenHeight) - 130;
        this.pquery = [
            { field: 'query', header: 'Query', sortable: true, action: true },
            { field: 'pId', header: 'PId', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.metaTier = [
            { field: 'tierName', header: 'Tier Name', sortable: true, action: true },
            { field: 'tierid', header: 'Tier Id', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.metaServer = [
            { field: 'serverName', header: 'Server Name', sortable: true, action: true },
            { field: 'serverId', header: 'Server Id', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.metaInstance = [
            { field: 'instanceName', header: 'Instance Name', sortable: true, action: true },
            { field: 'instanceId', header: 'Instance Id', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.backend = [
            { field: 'backendName', header: 'Backend Name', sortable: true, action: true },
            { field: 'backendId', header: 'Backend Id', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.method = [
            { field: 'methodName', header: 'Method Name', sortable: true, action: true },
            { field: 'methodId', header: 'Method Id', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.businessT = [
            { field: 'btId', header: 'Url Name', sortable: true, action: true },
            { field: 'btName', header: 'Url Index', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.classM = [
            { field: 'className', header: 'Class Name', sortable: true, action: true },
            { field: 'classId', header: 'Class Id', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.packageM = [
            { field: 'packageName', header: 'Package Name', sortable: true, action: true },
            { field: 'packageId', header: 'Package Id', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.metaTable = [
            { field: 'tableName', header: 'Table Name', sortable: true, action: true },
            { field: 'rowCount', header: 'Row Count', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.tsiTier = [
            { field: 'tierName', header: 'Tier Name', sortable: true, action: true },
            { field: 'tierid', header: 'Tier Id', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.tsiServer = [
            { field: 'serverName', header: 'Server Name', sortable: true, action: true },
            { field: 'serverId', header: 'Server Id', sortable: true, action: true, align: 'right', width: '81' },
            { field: 'agentPort', header: 'Agent Port', sortable: true, action: true, align: 'right', width: '81' }
        ];
        this.tsiInstance = [
            { field: 'instanceName', header: 'Instance Name', sortable: true, action: true },
            { field: 'instanceId', header: 'Instance Id', sortable: true, action: true, align: 'right', width: '81' },
            { field: 'port', header: 'Port', sortable: true, action: true, align: 'right', width: '81' }
        ];
    }
    onTopologyEntityTab() {
        this.mappingAccordion = false;
        this.metadataAccordion = true;
        //tier
        let keys = Object.keys(this.tierMdata);
        this.tierMetadata = [];
        for (let i = 0; i < keys.length; i++) {
            this.tierMetadata.push({ 'tierid': this.tierMdata[keys[i]], 'tierName': keys[i] });
        }
        this.tierRecord = this.tierMetadata.length;
        //server
        let keys2 = Object.keys(this.serverMdata);
        this.serverMetadata = [];
        for (let i = 0; i < keys2.length; i++) {
            this.serverMetadata.push({ 'serverName': keys2[i], 'serverId': this.serverMdata[keys2[i]] });
        }
        this.serverRecord = this.serverMetadata.length;
        //instance
        let keys3 = Object.keys(this.instanceMdata);
        this.instanceMetadata = [];
        for (let i = 0; i < keys3.length; i++) {
            this.instanceMetadata.push({ 'instanceName': keys3[i], 'instanceId': this.instanceMdata[keys3[i]] });
        }
        this.instanceRecord = this.instanceMetadata.length;
        //table records
        let keys10 = Object.keys(this.tableMdata);
        this.tableMetadata = [];
        for (let i = 0; i < keys10.length; i++) {
            this.tableMetadata.push({ 'tableName': keys10[i], 'rowCount': this.tableMdata[keys10[i]] });
        }
        this.tRecord = this.tableMetadata.length;
        //method
        let keys4 = Object.keys(this.methodMdata);
        this.methodMetadata = [];
        for (let i = 0; i < keys4.length; i++) {
            this.methodMetadata.push({ 'methodName': keys4[i], 'methodId': this.methodMdata[keys4[i]] });
        }
        this.mRecord = this.methodMetadata.length;
        //backend
        let keys5 = Object.keys(this.backendMdata);
        this.backendMetadata = [];
        for (let i = 0; i < keys5.length; i++) {
            this.backendMetadata.push({ 'backendName': keys5[i], 'backendId': this.backendMdata[keys5[i]] });
        }
        this.bRecord = this.backendMetadata.length;
        //class
        let keys6 = Object.keys(this.classMdata);
        this.classMetadata = [];
        for (let i = 0; i < keys6.length; i++) {
            this.classMetadata.push({ 'className': keys6[i], 'classId': this.classMdata[keys6[i]] });
        }
        this.cRecord = this.classMetadata.length;
        //package
        let keys7 = Object.keys(this.packageMdata);
        this.packageMetadata = [];
        for (let i = 0; i < keys7.length; i++) {
            this.packageMetadata.push({ 'packageName': keys7[i], 'packageId': this.packageMdata[keys7[i]] });
        }
        this.ptRecord = this.packageMetadata.length;
        //BT
        let keys8 = Object.keys(this.btMdata);
        this.btMetadata = [];
        for (let i = 0; i < keys8.length; i++) {
            this.btMetadata.push({ 'btName': keys8[i], 'btId': this.btMdata[keys8[i]] });
        }
        this.btRecord = this.btMetadata.length;
        //PQuery
        let keys9 = Object.keys(this.pqMdata);
        this.pqMetadata = [];
        for (let i = 0; i < keys9.length; i++) {
            this.pqMetadata.push({ 'pId': keys9[i], 'query': this.pqMdata[keys9[i]] });
        }
        this.qRecord = this.pqMetadata.length;
    }
    onMappingTabOpen() {
        //mapping of tier ,server and instance 
        this.metadataAccordion = false;
        let keys = Object.keys(this.mapMdata);
        this.tsiTierMapdata = [];
        this.tsiServerMapdata = [];
        this.tsiInstanceMapdata = [];
        for (let i = 0; i < keys.length; i++) {
            this.tsiTierMapdata.push({ 'tierName': this.mapMdata[keys[i]].name, 'tierid': this.mapMdata[keys[i]].id, 'server': this.mapMdata[keys[i]].sdMap });
        }
        this.selectedTierRow = this.tsiTierMapdata[0];
        let serkey = Object.keys(this.mapMdata[keys[0]].sdMap);
        for (let i = 0; i < serkey.length; i++) {
            this.tsiServerMapdata.push({ "serverName": this.mapMdata[keys[0]].sdMap[serkey[i]].name, "serverId": this.mapMdata[keys[0]].sdMap[serkey[i]].id, "agentPort": this.mapMdata[keys[0]].sdMap[serkey[i]].agentPort, "instance": this.mapMdata[keys[0]].sdMap[serkey[i]].iObjM });
            let inskey = Object.keys(this.mapMdata[keys[0]].sdMap[serkey[i]].iObjM);
            if (i == 0) {
                for (let j = 0; j < inskey.length; j++) {
                    this.tsiInstanceMapdata.push({ "instanceName": this.mapMdata[keys[0]].sdMap[serkey[i]].iObjM[inskey[j]].name, "instanceId": this.mapMdata[keys[0]].sdMap[serkey[i]].iObjM[inskey[j]].id, "port": this.mapMdata[keys[0]].sdMap[serkey[i]].iObjM[inskey[j]].port });
                }
            }
        }
        this.selectedServerRow = this.tsiServerMapdata[0];
        this.tsitRecord = this.tsiTierMapdata.length;
        this.tsisRecord = this.tsiServerMapdata.length;
        this.tsiiRecord = this.tsiInstanceMapdata.length;
        //this.mappingAccordion = false;
    }
    onRowClickTier(event) {
        this.mapSdata = event.data.server;
        this.tsiServerMapdata = [];
        this.tsiInstanceMapdata = [];
        let keys = Object.keys(this.mapSdata);
        for (let i = 0; i < keys.length; i++) {
            //  console.log("keys[i]****",keys[i]);
            //  console.log("obj[keys[i]]*****",this.mapSdata[keys[i]]);
            this.tsiServerMapdata.push({ "serverName": this.mapSdata[keys[i]].name, "serverId": this.mapSdata[keys[i]].id, "agentPort": this.mapSdata[keys[i]].agentPort, "instance": this.mapSdata[keys[i]].iObjM });
        }
        if (keys.length >= 1) {
            this.tsisRecord = this.tsiServerMapdata.length;
            this.selectedServerRow = this.tsiServerMapdata[0];
            this.mapIdata = this.mapSdata[keys[0]].iObjM;
            let instancekey = Object.keys(this.mapIdata);
            // console.log("&&&&Inst",this.mapIdata);
            for (let j = 0; j < instancekey.length; j++) {
                this.tsiInstanceMapdata.push({ "instanceName": this.mapIdata[instancekey[j]].name, "instanceId": this.mapIdata[instancekey[j]].id, "port": this.mapIdata[instancekey[j]].port });
                // console.log("+++++++++++++",this.tsiInstanceMapdata[j]);
            }
            if (instancekey.length >= 1) {
                this.tsiiRecord = this.tsiInstanceMapdata.length;
            }
            else {
                this.tsiiRecord = 0;
            }
        }
        else {
            this.tsisRecord = 0;
            this.tsiiRecord = 0;
        }
    }
    onRowClickServer(event) {
        this.mapIdata = event.data.instance;
        this.tsiInstanceMapdata = [];
        let keys = Object.keys(this.mapIdata);
        //console.log("instance.......",   this.mapIdata);
        //console.log("key*****ins",keys)      
        for (let i = 0; i < keys.length; i++) {
            //  console.log("keys[i]****",keys[i]);
            //  console.log("obj[keys[i]]*****", this.mapIdata[keys[i]]);
            this.tsiInstanceMapdata.push({ "instanceName": this.mapIdata[keys[i]].name, "instanceId": this.mapIdata[keys[i]].id, "port": this.mapIdata[keys[i]].port });
        }
        if (keys.length >= 1) {
            this.tsiiRecord = this.tsiInstanceMapdata.length;
        }
        else {
            this.tsiiRecord = 0;
        }
    }
    refreshTSI() {
        this.loading = true;
        this.metadataAccordion = true;
        this.mappingAccordion = false;
        this.topologyEntity(2);
        this.loading = false;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].FPTOMD);
    }
    refreshPCMB() {
        console.log("********");
        this.loading = true;
        this.metadataAccordion = true;
        this.topologyEntity(3);
        this.loading = false;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].FPTOMD);
    }
    refreshTC() {
        this.loading = true;
        this.metadataAccordion = true;
        this.topologyEntity(6);
        this.loading = false;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].FPTOMD);
    }
    refreshBT() {
        this.loading = true;
        this.metadataAccordion = true;
        this.topologyEntity(4);
        this.loading = false;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].FPTOMD);
    }
    refreshQP() {
        this.loading = true;
        this.metadataAccordion = true;
        this.topologyEntity(5);
        this.loading = false;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].FPTOMD);
    }
    onCloseMetadataTab() {
        this.metadataAccordion = false;
        this.onMappingTabOpen();
        this.mappingAccordion = true;
    }
    onCloseMappingTab() {
        this.mappingAccordion = false;
    }
};
MetadataComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_6__["Router"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__["DDRRequestService"] }
];
MetadataComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-metadata',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./metadata.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/metadata/metadata.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./metadata.component.css */ "./src/app/pages/ddr/components/metadata/metadata.component.css")).default]
    })
], MetadataComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/method-call-info/method-call-info.component.scss":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/method-call-info/method-call-info.component.scss ***!
  \***************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/method-call-info/method-call-info.component.ts":
/*!*************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/method-call-info/method-call-info.component.ts ***!
  \*************************************************************************************/
/*! exports provided: MethodCallInfoComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MethodCallInfoComponent", function() { return MethodCallInfoComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/common/http */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/http.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs/operators */ "./node_modules/rxjs/_esm2015/operators/index.js");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/pages/tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");









let MethodCallInfoComponent = class MethodCallInfoComponent {
    constructor(messageService, ddrData, elasticsearchQueryService, sessionService, commonService, http) {
        this.messageService = messageService;
        this.ddrData = ddrData;
        this.elasticsearchQueryService = elasticsearchQueryService;
        this.sessionService = sessionService;
        this.commonService = commonService;
        this.http = http;
        this.filterCriteriaArray = [];
        this.completeSpanMap = {}; // map to stores complete span details
        this.isAllExpanded = false; //flag to toggle expanded view button
        this.serviceColorMap = {};
    }
    ngOnInit() {
        this.loader = true;
        console.log('Inside ngOnInit');
        if (!this.columnData && this.hasSelectedRowData(this.ddrData.selectedFPRowData)) {
            this.loadMethodCallInfo(this.ddrData.selectedFPRowData);
        }
    }
    ngOnChanges() {
        this.loader = true;
        this.isAllExpanded = false;
        this.closeSelectedTask();
        if (this.columnData) {
            this.loadMethodCallInfo(this.columnData);
        }
    }
    loadMethodCallInfo(selectedRowData) {
        this.buildTree(selectedRowData).then((data) => {
            this.nodes = data;
            this.expandToDepth(this.nodes, 0, 5); // auto-expand 5 levels
            console.log('Tree Nodes', this.nodes);
        });
    }
    hasSelectedRowData(selectedRowData) {
        return !!selectedRowData && Object.keys(selectedRowData).length > 0;
    }
    buildTree(selectedRowData) {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            this.traceDetails = yield this.ddrData.getTraceDataById(selectedRowData || this.columnData);
            console.log('Trace Details ', this.traceDetails);
            let spans = this.traceDetails || [];
            const spanMap = {};
            const roots = [];
            // First pass → create all nodes
            spans.forEach(span => {
                var _a, _b;
                spanMap[span.span_id] = {
                    data: {
                        name: span.kind == 'Client' ? `${this.elasticsearchQueryService.detectCalloutType(span).toUpperCase()} : ${span.name}` : span.name,
                        startTime: this.sessionService.convertTimeToSelectedTimeZone(Number(span["@timestamp"])),
                        threadId: span.attributes["thread.id"],
                        threadName: span.attributes["thread.name"],
                        kind: span.kind,
                        duration: (span.duration / 1000000).toFixed(3),
                        traceId: span.trace_id,
                        spanId: span.span_id,
                        parentSpanId: span.parent_span_id || null,
                        service: ((_b = (_a = span.resource) === null || _a === void 0 ? void 0 : _a.attributes) === null || _b === void 0 ? void 0 : _b['service.name']) || ''
                    },
                    children: []
                };
                this.completeSpanMap[span.span_id] = span;
            });
            console.log("Span Map :", spanMap);
            // Second pass → assign children to parents
            spans.forEach(span => {
                var _a;
                const node = spanMap[span.span_id];
                if (span.parent_span_id && spanMap[span.parent_span_id]) {
                    (_a = spanMap[span.parent_span_id].children) === null || _a === void 0 ? void 0 : _a.push(node);
                }
                else {
                    roots.push(node);
                }
            });
            if (this.subscription) {
                this.subscription.unsubscribe();
            }
            //filterCriteria
            this.subscription = this.elasticsearchQueryService.filterCriteriaDetails.subscribe(criteria => {
                this.filterCriteria = criteria;
                console.log("Filter Criteria in TSM component:", this.filterCriteria);
                this.filterCriteriaArray = this.filterCriteria
                    .split(',')
                    .map(item => item.trim())
                    .filter(item => item.length > 0);
            });
            this.loader = false;
            return roots;
        });
    }
    ngOnDestroy() {
        var _a;
        (_a = this.subscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
    }
    nodeSelect(event) {
        var _a;
        const node = event === null || event === void 0 ? void 0 : event.node;
        console.log('Selected Node Data:', node === null || node === void 0 ? void 0 : node.data);
        const selected = this.completeSpanMap[node.data.spanId];
        if (selected) {
            this.selectedRowData = selected;
            this.selectedTask = true;
            this.spanAttributes = selected.attributes;
            this.resourceAttributes = (_a = selected.resource) === null || _a === void 0 ? void 0 : _a.attributes;
            this.scope = selected.scope;
        }
    }
    closeSelectedTask() {
        this.selectedTask = false;
        this.selectedNode = null;
        this.selectedRowData = null;
    }
    flattenObject(obj, parentKey = '') {
        if (!obj)
            return [];
        const result = [];
        const recurse = (subObj, parent) => {
            for (const key in subObj) {
                if (!subObj.hasOwnProperty(key))
                    continue;
                const fullKey = parent ? `${parent}.${key}` : key;
                const value = subObj[key];
                if (typeof value === 'object' && value !== null && !Array.isArray(value)) {
                    recurse(value, fullKey);
                }
                else {
                    result.push({ key: fullKey, value });
                }
            }
        };
        recurse(obj, parentKey);
        return result;
    }
    trackByKey(index, item) {
        return item.key;
    }
    // Expand nodes up to a given depth
    expandToDepth(nodes, currentDepth, maxDepth) {
        if (!nodes || currentDepth >= maxDepth)
            return;
        nodes.forEach(node => {
            if (node.children && node.children.length > 0) {
                node.expanded = true;
                this.expandToDepth(node.children, currentDepth + 1, maxDepth);
            }
        });
    }
    // Expand ALL nodes recursively
    expandAll() {
        this.expandAllNodes(this.nodes);
        this.nodes = [...this.nodes]; // trigger change detection
    }
    expandAllNodes(nodes) {
        if (!nodes)
            return;
        nodes.forEach(node => {
            if (node.children && node.children.length > 0) {
                node.expanded = true;
                this.expandAllNodes(node.children);
            }
        });
    }
    // Collapse all nodes
    collapseAll() {
        this.collapseAllNodes(this.nodes);
        this.nodes = [...this.nodes];
    }
    collapseAllNodes(nodes) {
        if (!nodes)
            return;
        nodes.forEach(node => {
            node.expanded = false;
            if (node.children)
                this.collapseAllNodes(node.children);
        });
    }
    toggleExpandAll() {
        if (this.isAllExpanded) {
            this.collapseAllNodes(this.nodes);
        }
        else {
            this.expandAllNodes(this.nodes);
        }
        this.isAllExpanded = !this.isAllExpanded;
        this.nodes = [...this.nodes];
    }
    formatDuration(duration) {
        duration = duration / 1000000;
        if (duration < 1000) {
            return `${(duration).toFixed(3)}ms`;
        }
        else {
            return `${(duration / 1000).toFixed(3)}s`;
        }
    }
    copyToClipboard(value) {
        const textArea = document.createElement('textarea');
        textArea.value = value;
        textArea.style.position = 'fixed'; // Prevent scrolling to bottom of page in MS Edge
        document.body.appendChild(textArea);
        textArea.focus();
        textArea.select();
        try {
            document.execCommand('copy');
            this.messageService.showSuccess("Attribute's value copied to clipboard");
        }
        catch (err) {
            this.messageService.showError('Copy Failed:', err);
        }
        document.body.removeChild(textArea);
    }
    downloadReports(type) {
        var _a, _b;
        const rowData = [];
        let index = 1;
        const flattenNodes = (nodes) => {
            nodes.forEach(node => {
                var _a;
                const d = node.data;
                rowData.push([
                    index++,
                    d.name,
                    d.kind,
                    d.startTime,
                    d.duration,
                    d.threadName
                ]);
                if ((_a = node.children) === null || _a === void 0 ? void 0 : _a.length)
                    flattenNodes(node.children);
            });
        };
        flattenNodes(this.nodes);
        const payload = {
            cctx: this.sessionService.session.cctx,
            testRun: this.sessionService.session.testRun.id,
            type: type,
            title: 'Method Call Info',
            header: ['S.no', 'Name', 'Kind', 'Start Time', 'Duration (ms)', 'Thread Name'],
            rowData: rowData,
            skipColumn: '',
            timeZone: ((_a = this.sessionService.selectedTimeZone) === null || _a === void 0 ? void 0 : _a.zoneLabel) || 'Asia/Kolkata'
        };
        const hostDcName = window.location.protocol + '//' + window.location.host;
        const downloadUrl = ((_b = this.sessionService.preSession) === null || _b === void 0 ? void 0 : _b.multiDc) ? `${hostDcName}/node/ALL/DashboardServer/v2/web/download/data`
            : `${hostDcName}/DashboardServer/v2/web/download/data`;
        this.http.post(downloadUrl, payload).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(res => res)).subscribe(res => (this.openDownloadReports(res)));
    }
    /* for open download reports*/
    openDownloadReports(res) {
        var hostDcName = window.location.protocol + '//' + window.location.host;
        window.open(hostDcName + "/common/" + res['path']);
    }
    // Add this method to generate colors
    getServiceColor(serviceName) {
        if (!serviceName)
            return 'transparent';
        if (!this.serviceColorMap[serviceName]) {
            const hue = this.hashCode(serviceName) % 360;
            // Check if dark mode is active (adjust based on your dark mode detection)
            const isDarkMode = document.body.classList.contains('dark-theme'); // or however you detect dark mode
            if (isDarkMode) {
                // Dark mode: low saturation, low lightness
                this.serviceColorMap[serviceName] = `hsl(${hue}, 35%, 20%)`;
            }
            else {
                // Light mode: low saturation, high lightness
                this.serviceColorMap[serviceName] = `hsl(${hue}, 40%, 88%)`;
            }
        }
        return this.serviceColorMap[serviceName];
    }
    // Hash function to generate consistent colors for same service names
    hashCode(str) {
        let hash = 0;
        for (let i = 0; i < str.length; i++) {
            const char = str.charCodeAt(i);
            hash = ((hash << 5) - hash) + char;
            hash = hash & hash; // Convert to 32-bit integer
        }
        return Math.abs(hash);
    }
};
MethodCallInfoComponent.ctorParameters = () => [
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_6__["CavMessageService"] },
    { type: src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__["DdrDataModelService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_8__["ElasticsearchQueryService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_4__["SessionService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_7__["CommonServices"] },
    { type: _angular_common_http__WEBPACK_IMPORTED_MODULE_1__["HttpClient"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], MethodCallInfoComponent.prototype, "columnData", void 0);
MethodCallInfoComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Component"])({
        selector: 'app-method-call-info',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./method-call-info.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/method-call-info/method-call-info.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./method-call-info.component.scss */ "./src/app/pages/ddr/components/method-call-info/method-call-info.component.scss")).default]
    })
], MethodCallInfoComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.scss":
/*!*****************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.scss ***!
  \*****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".methDetais {\n  height: 425px;\n  font-weight: bolder;\n}\n\n.ddr-method-detail {\n  width: 120px;\n  height: 20px;\n  text-align: left;\n}\n\n.ddr-method-textarea {\n  width: 320px;\n  height: 40px;\n  resize: none;\n}\n\n.butTop {\n  top: 7px;\n  position: absolute;\n}\n\n.tabList {\n  display: flex;\n  align-items: center;\n  width: 100%;\n}\n\n.tabList > .cusTabs {\n  flex-basis: 100% !important;\n  padding: 0.3em;\n  border: solid 1px var(--darkBlue);\n  color: var(--darkBlue);\n  text-align: center;\n  cursor: pointer;\n}\n\n.tabList > .cusTabs.active {\n  background-color: var(--darkBlue);\n  color: var(--white);\n}\n\n.cusTabsContent {\n  height: 200px;\n  overflow: auto;\n  padding: 0.35em;\n}\n\n.incrementList {\n  list-style: none;\n  counter-reset: item;\n  padding: 0;\n  margin: 0;\n}\n\n.incrementList > li {\n  counter-increment: item;\n  margin: 0.25rem;\n  position: relative;\n  cursor: pointer;\n}\n\n.incrementList > li::before {\n  content: counter(item);\n  width: 24px;\n  height: 24px;\n  display: inline-flex;\n  text-align: center;\n  margin: 0.15em 0.25em 0.15em 0.15em;\n  background-color: var(--header3);\n  color: var(--white);\n  border-radius: 50%;\n  font-weight: 500;\n  justify-content: center;\n  align-items: center;\n}\n\n.dnone {\n  display: none;\n}\n\n.xmlHead {\n  box-shadow: 0 0 3px 0 rgba(0, 0, 0, 0.2);\n  position: relative;\n  z-index: 999;\n  margin: 0;\n  padding: 0.25rem;\n  font-weight: 600;\n}\n\n.xmlCode {\n  height: 201px;\n  overflow: auto;\n}\n\n.bottomTabs {\n  margin-left: 0.35rem;\n  margin-right: 0.35rem;\n  margin-top: -0.45rem;\n  height: 250px;\n  overflow: auto;\n  box-shadow: 0 3px 3px rgba(0, 0, 0, 0.2);\n  width: 644px;\n}\n\n.circleText {\n  display: inline-flex;\n  width: 24px;\n  height: 24px;\n  background-color: var(--danger);\n  color: var(--white);\n  font-weight: 500;\n  justify-content: center;\n  align-items: center;\n  border-radius: 50%;\n}\n\n.tabsSearch {\n  width: 150px;\n  position: absolute;\n  right: 15px;\n  top: 50px;\n  z-index: 453;\n}\n\n.adonbtn {\n  background-color: var(--bg1);\n  border: solid 1px var(--gray);\n}\n\n.circleText {\n  display: inline-flex;\n  width: 18px;\n  height: 18px;\n  background-color: var(--danger);\n  color: var(--white);\n  font-weight: 500;\n  justify-content: center;\n  align-items: center;\n  border-radius: 50%;\n}\n\n.ddr-table-left, .ddr-table-left {\n  color: blue !important;\n  cursor: pointer !important;\n}\n\n.ui-panel-contents {\n  overflow: auto;\n}\n\n.ddruiscroll {\n  overflow-y: auto;\n  overflow-x: hidden;\n  height: calc(100vh - 100px);\n}\n\n@media (max-width: 1366px) {\n  .ddruiscroll {\n    height: calc(100vh - 210px);\n  }\n}\n\npre {\n  margin: 0;\n  font-family: monospace;\n  white-space: pre-wrap;\n  /* Makes sure the text wraps */\n  word-wrap: break-word;\n  /* Breaks long words to avoid overflow */\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.ts":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.ts ***!
  \***************************************************************************************/
/*! exports provided: MethodcallingtreeComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MethodcallingtreeComponent", function() { return MethodcallingtreeComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! rxjs/operators */ "./node_modules/rxjs/_esm2015/operators/index.js");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! src/app/pages/tools/admin/access-control-management/constants/cav-acl-features.constants */ "./src/app/pages/tools/admin/access-control-management/constants/cav-acl-features.constants.ts");















let MethodcallingtreeComponent = class MethodcallingtreeComponent {
    constructor(ddrRequest, commonService, _ddrData, breadcrumbService, _router, _ChangeDetectorRef, breadcrumb, sessionService, ddrHttpService, messageService) {
        this.ddrRequest = ddrRequest;
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this._router = _router;
        this._ChangeDetectorRef = _ChangeDetectorRef;
        this.sessionService = sessionService;
        this.ddrHttpService = ddrHttpService;
        this.messageService = messageService;
        this.repeatedMethodsDatapop = [];
        this.limit = 10;
        this.offset = 0;
        this.startTime = "";
        this.filterCriteria = ""; //To show filter criteria
        this.downloadFilterCriteria = "";
        this.loading = false; //Loading ajax loader icon
        this.tableLoading = false;
        this.showDownLoadReportIcon = true;
        this.showDownLoadReportIconMct = true;
        this.showParent = false;
        this.dataCount = 0;
        this.isAgent = true;
        this.loader = false;
        this.value = 1;
        this.host = '';
        this.toggleFilterTitle = '';
        this.isEnabledColumnFilter = false;
        this.count = 0;
        this.count1 = 0;
        this.filterDialog = false;
        this.txtThresholdWallTime = 1500;
        this.txtThresholdelapsedTime = 1000;
        this.txtFilterWallTime = 0;
        this.txtFilterSelfTime = 0;
        this.txtFlterMethodLevel = 100;
        this.showExpandBtn = false;
        this.fpInstanceInfoKeys = [];
        this.mctAppliedFilter = "";
        this.selectedPackageList = [];
        this.selectedClassList = [];
        this.selectedMethodList = [];
        this.uniqueMethodSignature = [];
        this.selectedActClss = [];
        this.selectedActMethod = [];
        this.msgs = [];
        this.compareFPInfo = {};
        this.methodDetails = false;
        this.showColumnMCT = true;
        this.isEnabledQAS = true;
        this.ignoreFilterCallOuts = ['T,E', 'D', 'J,j', 'e', 't', 'a,A'];
        this.showAutoInstrPopUp = false;
        this.repeatedMethodData = [];
        this.showRepeatedDialogue = false;
        this.colsForRepeatedData = [];
        this.repeatedFQM = "";
        this.isExpandCount = false;
        this.txtExpandCount = 25;
        this.countIndex = 0;
        this.enableMergeCase = false;
        this.empty = true;
        this.list1 = [];
        this.list2 = [];
        this.showColumnReorderDialog = false;
        this.filterMethods = "0"; //Note 0 means not filtered, 1 means filtered
        this.childrenObj = {};
        this.preNode = {};
        this.substringFQM = "";
        this.MCTDialogFilters = false;
        this.values = [];
        this.childMCTPositionTop = 20;
        this.asyncExitMap = {};
        this.methodDetailsHeaderName = "";
        this.showColor = false;
        this.visibleArr = [];
        this.minWidth = 1500;
        this.toggleCallout = false;
        this.mctHeaderNote = 'Note: Only instrumented methods shown in method call tree. There may be other non-instrumented methods called in between methods having parent child relationship in method call tree.';
        this.showPaginationRepeat = true;
        this.downloadRepeatMethod = [];
        this.expandCollapseHint = "Show Callouts Expanded form";
        this.showErrorMessage = false;
        this.rowRepeatedMethodInfo = [];
        this.textAreaRepeatedMethod = "";
        this.contextMenu = false;
        this.loader2 = false;
        this.downloadExcelEnable = false;
        this.downloadWordEnable = false;
        this.downloadPdfEnable = false;
        this.dynTierName = "";
        this.dynServerName = "";
        this.dynAppName = "";
        this.ShowCommonDLModule = false;
        this.openDLDialogFromButton = false;
        this.show = true;
        this.isReorder = false;
        this.breadcrumb = breadcrumb;
    }
    ngOnChanges(changes) {
        if (this._ddrData.splitViewFlag)
            this._ddrData.setInLogger("DDR::Flowpath", "Method Calling Tree", "Open Method Calling Tree");
        if (this._ddrData.splitViewBreadCrumbFlag && this._ddrData.splitViewFlag) {
            if (this.columnData) {
                this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            }
            this.breadcrumb.add({ label: 'Method Calls Details' });
        }
        else if (!this._ddrData.isFromCompareFp) {
            if (this.columnData) {
                this.breadcrumb.add({ label: this.columnData.flowpathInstance });
                this.breadcrumb.add({ label: 'Method Calls Details' });
            }
            this._ddrData.splitViewBreadCrumbFlag = true;
        }
        this.loading = true;
        this.loader2 = true;
        this.value = 1;
        this.commonService.showMethodCallingTree = true;
        this.id = this.commonService.getData();
        this.commonService.mctData = this.columnData;
        if (this.columnData != undefined) {
            this.queryParams = JSON.parse(JSON.stringify(this.columnData));
            if (this.queryParams['fpDuration'] != undefined) {
                if (this.queryParams['fpDuration'] == '< 1') {
                    this.queryParams.fpDuration = 0;
                    this.fpDuration = 0;
                }
                else if (this.queryParams['fpDuration'].toString().includes(',')) {
                    this.queryParams.fpDuration = this.queryParams.fpDuration.toString().replace(/,/g, "");
                    this.fpDuration = this.queryParams.fpDuration.toString().replace(/,/g, "");
                }
                else {
                    this.fpDuration = this.queryParams.fpDuration;
                }
            }
            this.trStartTime = this.queryParams.startTimeInMs;
            this.trEndTime = Number(this.queryParams.startTimeInMs) + Number(this.queryParams.fpDuration);
        }
        else {
            this.queryParams = this.compareFPInfo;
        }
        this.mctData = null;
        this.selectedNode = null;
        this.txtExpandCount = 25;
        this.createFilterCriteria();
        this.setTestRunInHeader();
        this.toggleCallout = false;
        this.expandCollapseHint = "Show Callouts Expanded form";
        this.getMCTDataFunc();
        this.isAgent = (this.queryParams.instanceType == 'Java' || this.queryParams.instanceType == 'DotNet' || this.queryParams.instanceType == 'DotNetC' || this.queryParams.Instance_Type == 'Java' || this.queryParams.Instance_Type == 'DotNet' || this.queryParams.Instance_Type == 'DotNetC') ? true : false;
    }
    ngOnInit() {
        this.loading = true;
        this.screenHeight = Number(this.commonService.screenHeight) - 120;
        if (this._ddrData.splitViewFlag == true || !this._ddrData.isFromCompareFp) {
            this.breadcrumb.add({ label: 'Method Calls Details', routerLink: '/ddr/methodCallingTree' });
            this.id = this.commonService.getData();
        }
        this.assignMCTColumns();
        if (this.commonService.mctFlag === true) {
            this.queryParams = this.commonService.mctData;
        }
        if (this.queryParams['source'] == 'Flowpath')
            this.commonService.isToLoadSideBar = true;
        else
            this.commonService.isToLoadSideBar = false;
        if (this.queryParams['source'] == 'TransactionFlowmap' && this._ddrData.splitViewFlag == false)
            this.commonService.showMethodCallingTree = false;
        else
            this.commonService.showMethodCallingTree = true;
        if (this._ddrData.splitViewFlag == false) {
            if (Object.keys(this.compareFPInfo).length == 0) {
                this.selectedNode = null;
                this.createFilterCriteria();
                this.getMCTDataFunc();
                this.getMethodSummaryData();
                this.setTestRunInHeader();
            }
        }
        if (this.id.startTimeInDateFormat != "NA" && this.id.startTimeInDateFormat != "" && this.id.startTimeInDateFormat != undefined) {
            this.startTimeInDateFormat = this.id.startTimeInDateFormat;
        }
        if (this.id.endTimeInDateFormat != "NA" && this.id.endTimeInDateFormat != "" && this.id.endTimeInDateFormat != undefined) {
            this.endTimeInDateFormat = this.id.endTimeInDateFormat;
        }
        if (this.commonService.testRun) {
            this.id.testrun = this.commonService.testRun;
        }
        this.relativePathforMethodSummary = "ddr/method-calling-tree/method_summary/mehod_summary.json";
        this.visibleCols = ['mN', 'percent', 'avgST', 'sT', 'totWT', 'avgWT', 'cumCPUST', 'avgCPUST', 'eC', 'waitTime', 'syncTime'];
        this.columnOptions = [];
        for (let i = 0; i < this.cols.length; i++) {
            this.columnOptions.push({ label: this.cols[i].header, value: this.cols[i].field });
        }
        if (this.queryParams.instanceType == 'Java' || this.queryParams.instanceType == 'DotNet' || this.queryParams.instanceType == 'DotNetC' || this.queryParams.Instance_Type == 'Java' || this.queryParams.Instance_Type == 'DotNet' || this.queryParams.Instance_Type == 'DotNetC') {
            this.isAgent = true;
        }
        else {
            this.isAgent = false;
        }
    }
    clickButtonEvent(event) {
        var _a;
        console.log("event~", event);
        const me = this;
        me.rowSelection((_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.row);
    }
    /*This method is used to give the detail of parent from which child methods called*/
    getParentInfo(rowNode) {
        const me = this;
        me.showParent = true;
        me.tableLoading = true;
        me.getMCTData().subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["MethodCallDetailsLoadedState"]) {
                const mctData = state.data;
                me.tableLoading = false;
                me.parentDataArray = me.createTree(mctData['parentMethod'].reverse());
                me.parentDataArray.forEach((val, idx) => {
                    if (idx == 0) {
                        let node = me.parentDataArray[idx];
                        me.expandChildren(node);
                        me.count = 0;
                    }
                });
            }
        }, (error) => {
            console.error(' Error in Fetching Method Call Tree Data !!', error);
        });
    }
    /*Method to assign fields and header for method calling tree table*/
    assignMCTColumns() {
        var _a, _b, _c, _d, _e, _f;
        this.colsForMCT = [];
        this.colsForMCT = [
            { field: 'methodName', header: 'Methods', sortable: true, action: true, align: 'left', width: '300px' },
            { field: 'dynLogFlag', header: 'Flag', sortable: false, action: false, align: 'left', width: '90px' },
            { field: 'api', header: 'API', sortable: false, action: false, align: 'left', width: '80px' },
            { field: 'timeStamp', header: 'ElapsedTime(ms)', sortable: false, action: true, align: 'right', width: '130px' }
        ];
        this.colsForMCT.push({ field: 'wallTime', header: 'WallTime(ms)', sortable: false, action: true, align: 'right', width: '120px' });
        this.colsForMCT.push({ field: 'percentage', header: 'Percentage', sortable: false, action: true, align: 'right', width: '120px' });
        this.colsForMCT.push({ field: 'cpuTime', header: 'CPUTime(ms)', sortable: false, action: false, align: 'right', width: '120px' });
        if (this.isEnabledQAS) {
            if (((_a = this.queryParams) === null || _a === void 0 ? void 0 : _a.instanceType) == 'Java' || ((_b = this.queryParams) === null || _b === void 0 ? void 0 : _b.Instance_Type) == 'Java' || this.commonService.currentRowData["Instance_Type"] == 'Java') {
                this.colsForMCT.push({ field: 'queueTime', header: 'ThreadQueueTime(ms)', sortable: false, action: false, align: 'right', width: '180px' });
            }
            this.colsForMCT.push({ field: 'selfTime', header: 'SelfTime(ms)', sortable: false, action: true, align: 'right', width: '120px' });
        }
        this.colsForMCT.push({ field: 'waitTime', header: 'WaitTime(ms)', sortable: false, action: false, align: 'right', width: '120px' });
        this.colsForMCT.push({ field: 'syncTime', header: 'SyncTime(ms)', sortable: false, action: false, align: 'right', width: '120px' });
        this.colsForMCT.push({ field: 'ioTime', header: 'IOTime(ms)', sortable: false, action: false, align: 'right', width: '120px' });
        this.colsForMCT.push({ field: 'suspensionTime', header: 'SuspensionTime(ms)', sortable: false, action: false, align: 'right', width: '150px' });
        this.colsForMCT.push({ field: 'sourceNetwork', header: 'Network Delay in Req(ms)', sortable: false, action: false, align: 'right', width: '180px' });
        this.colsForMCT.push({ field: 'destNetwork', header: 'Network Delay in Resp(ms)', sortable: false, action: false, align: 'right', width: '220px' });
        if (((_c = this.queryParams) === null || _c === void 0 ? void 0 : _c.instanceType) != 'php' && ((_d = this.queryParams) === null || _d === void 0 ? void 0 : _d.Instance_Type) != 'php' && this.commonService.currentRowData["Instance_Type"] != 'php') {
            this.colsForMCT.push({ field: 'threadId', header: 'ThreadId', sortable: false, action: true, align: 'right', width: '100px' });
        }
        if (((_e = this.queryParams) === null || _e === void 0 ? void 0 : _e.instanceType) == 'Java' || ((_f = this.queryParams) === null || _f === void 0 ? void 0 : _f.Instance_Type) == 'Java' || this.commonService.currentRowData["Instance_Type"] == 'Java') {
            this.colsForMCT.push({ field: 'threadName', header: 'Thread', sortable: false, action: false, align: 'left', width: '100px' });
        }
        this.colsForMCT.push({ field: 'methodArgument', header: 'Arguments', sortable: false, action: false, align: 'left', width: '100px' });
        this.colsForMCT.push({ field: 'instanceType', header: 'InstanceType', sortable: false, action: false, align: 'left', width: '100px' });
        this.colsForMCT.push({ field: 'appName', header: 'Instance', sortable: false, action: false, align: 'left', width: '100px' });
        this.colsForMCT.push({ field: 'tierName', header: 'Tier', sortable: false, action: false, align: 'left', width: '90px' });
        this.colsForMCT.push({ field: 'serverName', header: 'Server', sortable: false, action: false, align: 'left', width: '90px' });
        this.colsForMCT.push({ field: 'className', header: 'Class', sortable: false, action: false, align: 'left', width: '90px' });
        this.colsForMCT.push({ field: 'pacName', header: 'Package', sortable: false, action: false, align: 'left', width: '90px' });
        this.colsForMCT.push({ field: 'pageName', header: 'PageName', sortable: false, action: false, align: 'left', width: '90px' });
        this.colsForMCT.push({ field: 'asyncCall', header: 'Async_call', sortable: false, action: false, align: 'left', width: '100px' });
        this.colsForMCT.push({ field: 'lineNumber', header: 'Seq No.', sortable: true, action: true, align: 'right', width: '100px' });
        this.colsForMCT.push({ field: 'level', header: 'Depth', sortable: true, action: false, align: 'right', width: '100px' });
        this.origcolsForMCT = JSON.parse(JSON.stringify(this.colsForMCT));
        this.visibleColsForMCT = ['methodName', 'timeStamp', 'wallTime', 'percentage', 'selfTime', 'threadId', 'lineNumber'];
        this.columnOptionsForMCT = [];
        for (let i = 0; i < this.colsForMCT.length; i++) {
            if (this.colsForMCT[i].field != "methodName") {
                if (this.colsForMCT[i].action)
                    this.list1.push(this.colsForMCT[i]);
                if ((this.colsForMCT[i].field == "queueTime" || this.colsForMCT[i].field == "selfTime") && this.isEnabledQAS)
                    this.columnOptionsForMCT.push({ label: this.colsForMCT[i].header, value: this.colsForMCT[i].field });
                else if (this.colsForMCT[i].field != "queueTime" && this.colsForMCT[i].field != "selfTime")
                    this.columnOptionsForMCT.push({ label: this.colsForMCT[i].header, value: this.colsForMCT[i].field });
            }
        }
    }
    /*This method is used to get the data from server for MCT and set the menus for respective callout and methods to get their details*/
    getMCTDataFunc() {
        this.trStartTime = this.queryParams['startTimeInMs'];
        if (this.queryParams['fpDuration'] != undefined) {
            if (this.queryParams['fpDuration'] == '< 1')
                this.fpDuration = 0;
            else if (this.queryParams['fpDuration'].toString().includes(','))
                this.fpDuration = this.queryParams.fpDuration.toString().replace(/,/g, "");
            else
                this.fpDuration = this.queryParams.fpDuration;
        }
        this.menuIte = [
            { label: 'Method Details', command: (event) => this.viewMethodDetail(this.selectedNode) },
            { label: 'Call Stack', command: (event) => this.getParentInfo(this.selectedNode) }
        ];
        this.menuIteCallOut = [
            { label: 'Method Details', command: (event) => this.viewMethodDetail(this.selectedNode) },
            { label: 'Call Stack', command: (event) => this.getParentInfo(this.selectedNode) }
        ];
        this.menuIteMethod = [
            { label: 'Method Details', command: (event) => this.viewMethodDetail(this.selectedNode) },
            { label: 'Call Stack', command: (event) => this.getParentInfo(this.selectedNode) },
        ];
        if (this._ddrData.getAdminCapablities() && (this.queryParams.Instance_Type === 'Java' || this.queryParams.instanceType === 'Java')) {
            this.menuIteMethod.push({ label: 'View Source Code', command: (event) => this.getSourceCode(this.selectedNode) });
            this.menuIteMethod.push({ label: 'Initiate Dynamic Logging', command: (event) => this.commonModuleCall(this.selectedNode) });
        }
        this.getMCTData().subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["MethodCallDetailsLoadedState"]) {
                let mctData = state.data;
                this.loader = false;
                this.loading = false;
                this.loader2 = false;
                this.mctData = mctData.treedata.data;
                this.downloadMctData = mctData.data;
                this.uniqueMethodSignature = mctData.uniqueMethods;
                this.repeatedMethodData[0] = mctData.repeatMethodsData;
                this.asyncExitMap = mctData.asynCallMap;
                this.addPackageClassmethodList();
                let fpMap = new Map();
                fpMap = mctData.fpsInfo;
                this.queueTime = mctData.totalQueueTime;
                this.selfTime = mctData.totalSelfTime;
                this.maxRepeatedMethod = mctData.maxRepeatedMethod;
                this.mctAppliedFilter = "(Max Depth=" + this.formatter(this.txtFlterMethodLevel) + ", Min Wall Time=" + this.formatter(this.txtFilterWallTime) + "ms, Threshold=" + this.formatter(this.txtThresholdWallTime) + "ms" + ", Elapsed Threshold=" + this.formatter(this.txtThresholdelapsedTime);
                if (this.isEnabledQAS) {
                    this.mctAppliedFilter += " ,Total Thread Queue Time=" + this.formatter(this.queueTime) + "ms";
                    this.mctAppliedFilter += " ,Total Self Time=" + this.formatter(this.selfTime) + "ms";
                }
                this.mctAppliedFilter += ")";
                this.fpInstanceInfoKeys = Object.keys(fpMap);
                this.fpInstanceInfo = fpMap;
                if (this.downloadMctData.length == 0)
                    this.showDownLoadReportIconMct = false;
                else
                    this.showDownLoadReportIconMct = true;
                this.mctData.forEach((val, index) => {
                    if (index == 0) {
                        let node = this.mctData[index];
                        this.expandChildren(node);
                        this.count = 0;
                    }
                });
                this.repeatedMethodMsg = "Showing details of only " + this.maxRepeatedMethod + " occurances of this method";
                this.mctData = [...mctData];
                setTimeout(() => {
                    this.loader = false;
                }, 300);
                this._ddrData.getCalloutExpandCount();
            }
        }, (error) => {
            console.error('Error in fetching MCT Data ~ ', error);
        });
    }
    /*This method is used to create the tree for call stack recursively*/
    createTree(data, parentLevel = 1) {
        const tree = [];
        for (const item of data) {
            if (item.level === parentLevel) {
                const node = {
                    data: item,
                    children: this.createTree(data, item.level + 1) // Pass the current item's level as the parentLevel
                };
                tree.push(node);
            }
        }
        return tree;
    }
    // End 92301- Method to support the flow of data between method calling tree and dynamic logging component
    commonModuleCall(rowData) {
        this.dynFqm = rowData.fqm || rowData.data.fqm; //to support both cases form DL icon as well as from right click menu
        this.dynTierName = rowData.tierName || rowData.data.tierName;
        this.dynServerName = rowData.serverName || rowData.data.serverName;
        this.dynAppName = rowData.appName || rowData.data.appName;
        this.dynEntrySeqNum = rowData.entrySeqNum || rowData.data.entrySeqNum;
        this.dynFpInstance = this.fpInstanceInfo[this.fpInstanceInfoKeys[0]][0];
        this.argsForDynamicLogging = [this.dynTierName, this.dynServerName, this.dynAppName, this.dynFqm, this.id.product, this.id.testRun, this.dynEntrySeqNum, this.dynFpInstance, "0"];
        this.ShowCommonDLModule = true;
    }
    closeDynamicLogging(isCloseDLDialog) {
        this.ShowCommonDLModule = isCloseDLDialog;
    }
    openDLDialog() {
        this.openDLDialogFromButton = true;
    }
    /*This method is used to open Dynamic Logging based on Fully Qualified Method*/
    openDLbasedOnFQC() {
        if (this.isFullyQualifiedClassName(this.FQCforDL)) {
            this.dynFqm = this.FQCforDL;
            this.dynFpInstance = this.fpInstanceInfo[this.fpInstanceInfoKeys[0]][0];
            this.dynTierName = this.downloadMctData[0].tierName;
            this.dynServerName = this.downloadMctData[0].serverName;
            this.dynAppName = this.downloadMctData[0].appName;
            this.argsForDynamicLogging = [this.dynTierName, this.dynServerName, this.dynAppName, this.dynFqm, this.sessionService.session.cctx.prodType.toLowerCase().replace("/", ""), this.id.testRun, "", this.dynFpInstance, "1"];
            this.ShowCommonDLModule = true;
            this.openDLDialogFromButton = false;
        }
        else {
            this.showError('Please enter a fully qualified class name, e.g., package.ClassName');
            this.openDLDialogFromButton = false;
        }
    }
    /*This method is used to assign columns for method calling tree*/
    assignColsForMCT() {
        if (this.isEnabledQAS) {
            this.visibleColsForMCT.push('queueTime');
            this.list1.push({ field: 'queueTime', header: 'Thread QueueTime', sortable: true, action: true, align: 'right', width: '20' });
            this.visibleColsForMCT.push('selfTime');
            this.list1.push({ field: 'selfTime', header: 'Self Time(ms)', sortable: 'custom', action: true, align: 'right', width: '20' });
        }
        else {
            let index = this.visibleColsForMCT.indexOf("queueTime");
            if (index > -1) {
                this.visibleColsForMCT.splice(index, 1);
            }
            let index1 = this.visibleColsForMCT.indexOf("selfTime");
            if (index1 > -1) {
                this.visibleColsForMCT.splice(index1, 1);
            }
        }
        if (!this.isReorder) {
            this.showHideColumnForMCT({});
            this.columnOptionsForMCT = [];
            for (let i = 0; i < this.colsForMCT.length; i++) {
                if (this.colsForMCT[i].field != 'methodName') {
                    if ((this.colsForMCT[i].field == "queueTime" || this.colsForMCT[i].field == "selfTime") && this.isEnabledQAS)
                        this.columnOptionsForMCT.push({ label: this.colsForMCT[i].header, value: this.colsForMCT[i].field });
                    else if (this.colsForMCT[i].field != "queueTime" && this.colsForMCT[i].field != "selfTime")
                        this.columnOptionsForMCT.push({ label: this.colsForMCT[i].header, value: this.colsForMCT[i].field });
                }
            }
        }
        else {
            if (this.list2.length != this.list1.length) {
                for (let i = 0; i <= this.list1.length - 1; i++) {
                    this.list2.push(this.list1[i]);
                }
            }
            let tempArray1 = [];
            let dummyArray = [];
            tempArray1 = JSON.parse(JSON.stringify(this.list2));
            for (let i = 0; i < this.list2.length; i++) {
                for (let j = 0; j < this.colsForMCT.length; j++) {
                    if (this.list2[i].field == this.colsForMCT[j].field) {
                        dummyArray.push(this.colsForMCT[j]);
                        this.colsForMCT.splice(j, 1);
                        break;
                    }
                }
            }
            for (let i = 0; i < this.colsForMCT.length; i++) {
                if (this.colsForMCT[i].field == 'methodName') {
                    continue;
                }
                else {
                    tempArray1.push(this.colsForMCT[i]);
                }
            }
            this.show = false;
            this.colsForMCT = [];
            this.colsForMCT = JSON.parse(JSON.stringify(tempArray1));
            this.colsForMCT.unshift({ field: 'methodName', header: 'Methods', sortable: true, action: true, align: 'left', width: '100' });
            this.visibleColsForMCT = [];
            this.show = true;
            for (let i = 0; i < this.list2.length; i++) {
                this.visibleColsForMCT.push(this.list2[i].field);
            }
            this.columnOptionsForMCT = [];
            for (let i = 0; i < this.colsForMCT.length; i++) {
                if (this.colsForMCT[i].field != 'methodName') {
                    if ((this.colsForMCT[i].field == "queueTime" || this.colsForMCT[i].field == "selfTime") && this.isEnabledQAS)
                        this.columnOptionsForMCT.push({ label: this.colsForMCT[i].header, value: this.colsForMCT[i].field });
                    else if (this.colsForMCT[i].field != "queueTime" && this.colsForMCT[i].field != "selfTime")
                        this.columnOptionsForMCT.push({ label: this.colsForMCT[i].header, value: this.colsForMCT[i].field });
                }
            }
        }
        if (!this.isReorder) {
            for (let i = 0; i < this.colsForMCT.length; i++) {
                if (this.colsForMCT[i].action == true && this.colsForMCT[i].field !== 'methodName') {
                    this.list1.push(this.colsForMCT[i]);
                }
            }
        }
        else {
            this.list1 = [];
            this.list1 = JSON.parse(JSON.stringify(this.list2));
            this.list2 = [];
        }
        this.list1 = this.removeDuplicates(this.list1, 'field');
    }
    removeDuplicates(myArr, prop) {
        return myArr.filter((obj, pos, arr) => {
            return arr.map(mapObj => mapObj[prop]).indexOf(obj[prop]) === pos;
        });
    }
    openColumnOrdderDialog() {
        this.showColumnReorderDialog = true;
        this.list2 = [];
    }
    reOrderColumns() {
        this.isReorder = true;
        this.assignColsForMCT();
        this._ChangeDetectorRef.detectChanges();
        this.showColumnReorderDialog = false;
    }
    resetReorderlist() {
        this.showColumnReorderDialog = false;
        this.list1 = [];
        for (let i = 0; i < this.colsForMCT.length - 1; i++) {
            if (this.colsForMCT[i].action == true && this.colsForMCT[i].field != 'methodName') {
                this.list1.push(this.colsForMCT[i]);
            }
        }
        this.list2 = [];
    }
    /**Used to hyper link method for opening service method timing report
      This is used to check codition of package and class based on which method name is appended with %40 to show hyperlink on table */
    doHyperLinkOnMethod(val) {
        let doHyperLink = false;
        for (let i = 0; i < val.length; i++) {
            if (val[i]["pN"] == "weblogic.servlet.internal" && val[i]["cN"] == "FilterChainImpl")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "javax.servlet.http" && val[i]["cN"] == "HttpServlet")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "com.sun.jersey.spi.container.servlet" && val[i]["cN"] == "WebComponent")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "org.glassfish.jersey.servlet" && val[i]["cN"] == "ServletContainer")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "weblogic.servlet.jsp" && val[i]["cN"] == "JspBase")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "org.apache.jasper.runtime" && val[i]["cN"] == "HttpJspBase")
                val[i]["mN"] = val[i]["mN"] + "%40";
        }
        return val;
    }
    /*This method is used to show method detail while clicking right on any method in method calling tree*/
    viewMethodDetail(node) {
        var _a, _b;
        this.dbPerm = this.sessionService.isFeatureWrite(src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_14__["CAV_FEATURES"].APM.NAME, src_app_pages_tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_14__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS);
        this.methodname = this._ddrData.decodeHTMLString(node.data.methodName);
        this.tiername = node.data.tierName;
        this.servername = node.data.serverName;
        this.appname = node.data.appName;
        this.servername = node.data.serverName;
        this.tiername = node.data.tierName;
        this.packagename = node.data.pacName;
        this.classname = node.data.className;
        if (node.data.methodArgument)
            this.argument = this._ddrData.decodeHTMLString(node.data.methodArgument);
        this.pagename = node.data.pageName;
        if (this.pagename === "")
            this.pagename = "-";
        if (node.data.threadName)
            this.threadname = this._ddrData.decodeHTMLString(node.data.threadName);
        if (((_a = this.queryParams) === null || _a === void 0 ? void 0 : _a.instanceType) != 'php' && ((_b = this.queryParams) === null || _b === void 0 ? void 0 : _b.Instance_Type) != 'php' && this.commonService.currentRowData["Instance_Type"] != 'php') {
            this.threadId = node.data.threadId;
        }
        this.starttime = node.data.startTime;
        this.walltime = node.data.wallTime;
        this.returnvalue = node.data.returnValue;
        this.queryparameter = this._ddrData.decodeHTMLString(node.data.queryParameter);
        this.cputime = node.data.cpuTime;
        this.timeStamp = node.data.timeStamp;
        if ((typeof (node.data.percentage)) == 'number') {
            this.percentage = Number(node.data.percentage).toFixed(2);
        }
        else {
            this.percentage = node.data.percentage;
        }
        if (node.data.fqm == '-')
            this.methodDetailsHeaderName = "Callout Details";
        else
            this.methodDetailsHeaderName = "Method Details";
        this.methodDetails = true;
    }
    /**Used to open service method timing from Method summary table of FLowpath details report */
    openServiceMethodTiming(rowData) {
        let reqData = {};
        reqData["methodid"] = rowData.ID;
        reqData['tierName'] = this.id.tierName;
        reqData['serverName'] = this.id.serverName;
        reqData['appName'] = this.id.appName;
        reqData['strStartTime'] = this.id.startTime;
        reqData['strEndTime'] = this.id.endTime;
        this.commonService.dataForServiceMethod = reqData;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].MCTREPORT;
        if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
            this._router.navigate(['/home/ddrCopyLink/servicemethodtiming']);
        else
            this._router.navigate(['/home/ddr/servicemethodtiming']);
    }
    getSourceCode(node) {
        this.mName = this.extractMethodNameForHighlight(node.data.methodName);
        let jsonData = this.updateJsonForFqm(node);
        let queryParam = '';
        if (this.commonService.enableQueryCaching == 1) {
            queryParam += "cacheId=" + this.id.testRun + "&fqm=" + jsonData.fqm + "&j_uid=" + "" + "&tierName=" + jsonData.data.tierName + "&serverName=" + jsonData.data.serverName + "&instanceName=" + jsonData.data.appName + "&testRun=" + this.id.testRun + "&classSourceCode=" + true;
        }
        else {
            queryParam += "fqm=" + jsonData.data.fqm + "&j_uid=" + "" + "&tierName=" + jsonData.data.tierName + "&serverName=" + jsonData.data.serverName + "&instanceName=" + jsonData.data.appName + "&testRun=" + this.id.testRun + "&classSourceCode=" + true;
        }
        //this.ajaxLoader = true;
        this.loader = true;
        return this.ddrHttpService.getreadMethodBody(queryParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["ReadMethodBodyLoadedState"]) {
                this.assignDataForSourceCode(state.data.methodBody);
            }
        }, (error) => {
            console.error('Error in fetching response ~ ', error);
            this.loading = false;
        });
    }
    assignDataForSourceCode(dataVal) {
        this.methodBody = dataVal;
        this.loader = false;
        this.showSourceCode = true;
        setTimeout(() => {
            this.highlight();
        }, 0);
    }
    updateJsonForFqm(jsonData) {
        let className = jsonData.data.className;
        let lineNumber = jsonData.data.lineNumber;
        let fqmParts = jsonData.data.fqm.split('(');
        let baseFqm = fqmParts[0];
        jsonData.data.fqm = `${baseFqm}(${className}.java:${lineNumber})`;
        return jsonData;
    }
    showHideColumn(data) {
        if (this.visibleCols.length === 1) {
            this.prevColumn = this.visibleCols[0];
        }
        if (this.visibleCols.length === 0) {
            this.visibleCols.push(this.prevColumn);
        }
        if (this.visibleCols.length !== 0) {
            for (let i = 0; i < this.cols.length; i++) {
                for (let j = 0; j < this.visibleCols.length; j++) {
                    if (this.cols[i].field === this.visibleCols[j]) {
                        this.cols[i].action = true;
                        break;
                    }
                    else {
                        this.cols[i].action = false;
                    }
                }
            }
        }
    }
    showHideColumnForMCT(data) {
        this.list1 = [];
        if (this.visibleColsForMCT.length !== 0) {
            for (let i = 0; i < this.colsForMCT.length; i++) {
                for (let j = 0; j < this.visibleColsForMCT.length; j++) {
                    if (this.colsForMCT[i].field === this.visibleColsForMCT[j] && this.colsForMCT[i].field != "methodName") {
                        if ((this.colsForMCT[i].field == "queueTime" || this.colsForMCT[i].field == "selfTime") && this.isEnabledQAS) {
                            this.colsForMCT[i].action = true;
                            this.list1.push(this.colsForMCT[i]);
                        }
                        else if ((this.colsForMCT[i].field == "queueTime" || this.colsForMCT[i].field == "selfTime") && !this.isEnabledQAS) {
                            this.colsForMCT[i].action = false;
                        }
                        else {
                            this.colsForMCT[i].action = true;
                            this.list1.push(this.colsForMCT[i]);
                        }
                        break;
                    }
                    else {
                        this.colsForMCT[i].action = false;
                    }
                }
            }
        }
        this.colsForMCT[0].action = true;
        let tempOrig = [];
        for (let i = 0; i < this.colsForMCT.length; i++) {
            for (let j = 0; j < this.origcolsForMCT.length; j++) {
                if (this.colsForMCT[i].field == this.origcolsForMCT[j].field) {
                    if (this.colsForMCT[i].action == true)
                        this.origcolsForMCT[j].action = true;
                    tempOrig.push(this.origcolsForMCT[j]);
                }
            }
        }
        this.minWidth = this.list1.length * 100 + 300;
        this.origcolsForMCT = JSON.parse(JSON.stringify(tempOrig));
    }
    //This method is used to update the properties of method while expanding children of parent method
    updateMethodprop(repeatObj, nodeData) {
        const { wallTime, cpuTime, waitTime, syncTime, ioTime, suspensionTime, timeStamp, queueTime, selfTime } = repeatObj;
        nodeData.wallTime = wallTime;
        nodeData.cpuTime = cpuTime;
        nodeData.waitTime = waitTime;
        nodeData.syncTime = syncTime;
        nodeData.ioTime = ioTime;
        nodeData.suspensionTime = suspensionTime;
        if (this.fpDuration === 0) {
            nodeData.percentage = 0;
        }
        else {
            nodeData.percentage = (wallTime / this.fpDuration) * 100;
        }
        nodeData.timeStamp = timeStamp;
        nodeData.queueTime = (queueTime === 0) ? "-" : queueTime;
        nodeData.selfTime = (selfTime === 0) ? "-" : selfTime;
    }
    /*This Method is used to expand the children nodes of the parent method one by one when method calling tree renders*/
    expandChildren(node) {
        if (node && node.data.repeatObj) {
            let repeatObj = node.data.repeatObj;
            this.updateMethodprop(repeatObj, node.data);
        }
        if (node.children == undefined) {
            if (this.count == 0) {
                if (node.data.methodArgument == "-" || node.data.methodArgument.includes("Method Arguments")) {
                    if (node.data.methodArgument == "-") {
                        node.data.methodArgument = this.queryParams.urlQueryParamStr;
                    }
                    else {
                        node.data.methodArgument = this.queryParams.urlQueryParamStr + '\n' + node.data.methodArgument;
                    }
                }
            }
        }
        if (node.children) {
            if (node.children.length > 50) {
                this.childrenObj[node.data.lineNumber] = JSON.parse(JSON.stringify(node.children));
                this.preNode[node.data.lineNumber] = node;
                this.expandSameLeveluptoFixLevel(node, 0, node.data.lineNumber, node.children.length);
            }
            else if (this.count < this.txtExpandCount) {
                node.expanded = true;
                if (this.count == 0) {
                    if (node.data.methodArgument == "-" || node.data.methodArgument.includes("Method Arguments")) {
                        if (node.data.methodArgument == "-") {
                            node.data.methodArgument = this.queryParams.urlQueryParamStr;
                        }
                        else {
                            node.data.methodArgument = this.queryParams.urlQueryParamStr + '\n' + node.data.methodArgument;
                        }
                    }
                }
                for (let cn of node.children) {
                    this.count += 1;
                    if (cn && cn.data.repeatObj) {
                        let repeatObj = cn.data.repeatObj;
                        this.updateMethodprop(repeatObj, cn.data);
                    }
                    if (cn.children != undefined && cn.children.length <= 50) {
                        this.expandChildren(cn);
                    }
                    else if (cn.children != undefined) {
                        this.childrenObj[cn.data.lineNumber] = JSON.parse(JSON.stringify(cn.children));
                        this.preNode[cn.data.lineNumber] = cn;
                        this.expandSameLeveluptoFixLevel(cn, 0, cn.data.lineNumber, cn.children.length);
                    }
                }
            }
        }
    }
    highlight() {
        const propertyWithHighlights = this.methodBody.replace((` ${this.mName}`), (match) => {
            return '<span class="highlight-method">' + match + '</span>';
        });
        this.methodBody = propertyWithHighlights;
        this._ChangeDetectorRef.detectChanges();
        setTimeout(() => {
            const container = this.preContent.nativeElement;
            const highlightMethod = container.querySelector('.highlight-method');
            if (highlightMethod) {
                // (highlightMethod as HTMLElement).style.backgroundColor = 'yellow';
                highlightMethod.scrollIntoView({ behavior: 'smooth' });
            }
        }, 0);
    }
    extractMethodNameForHighlight(methodSignature) {
        // Find the index of the first opening parenthesis
        const openParenIndex = methodSignature.indexOf('(');
        if (openParenIndex === -1) {
            // If there is no opening parenthesis, return the method signature as is
            return methodSignature.trim();
        }
        // Extract the method name
        const methodName = methodSignature.substring(0, openParenIndex).trim();
        // Extract the parameters part
        const parametersPart = methodSignature.substring(openParenIndex + 1).trim();
        // Find the index of the first comma or closing parenthesis
        const commaIndex = parametersPart.indexOf(',');
        const closeParenIndex = parametersPart.indexOf(')');
        // Determine the end index for the first parameter
        let endIndex;
        if (commaIndex !== -1) {
            endIndex = commaIndex;
        }
        else if (closeParenIndex !== -1) {
            endIndex = closeParenIndex;
        }
        else {
            endIndex = parametersPart.length;
        }
        // Extract the first parameter
        const firstParameter = parametersPart.substring(0, endIndex).trim();
        // Return the method name with the first parameter
        return `${methodName}(${firstParameter}`;
    }
    /*This method is used to get the child flowpath data of the respective callout*/
    getChildFLowpathsData(nodeRef) {
        const me = this;
        let node = nodeRef.node.data;
        let popupindex = 0;
        var endTimetoPass;
        var startTimetoPass = Number(me.trStartTime) - 900000;
        if (me.trEndTime == '' || me.trEndTime == null || me.trEndTime == undefined || isNaN(me.trEndTime)) {
            var strEndTime = Number(me.trStartTime) + Number(me.fpDuration);
            endTimetoPass = Number(strEndTime) + 900000;
        }
        else {
            endTimetoPass = Number(me.trEndTime) + 900000;
        }
        me._ddrData.dlStartTime = startTimetoPass;
        me._ddrData.dlEndTime = endTimetoPass;
        let fpInstance = me.queryParams.prevFlowpathInstance;
        if (me.queryParams.prevFlowpathInstance === '0')
            fpInstance = me.queryParams.flowpathInstance;
        let methodCount = 50000;
        if (me.queryParams.methodsCount)
            methodCount = Number(me.queryParams.methodsCount.toString().replace(/,/g, ""));
        const queryParams = `testRun=${me.id.testRun}&prevFlowpathInstance=${fpInstance}&strStartTime=${startTimetoPass}&strEndTime=${Number(endTimetoPass) + 1000}&beginSequenceNo=${node.seqNo}&filterLevel=${me.txtFlterMethodLevel}&filterWallTime=${me.txtFilterWallTime}&package=${me.selectedPackageList.toString()}&class=${me.selectedActClss.toString()}&method=${me.selectedActMethod.toString()}&showCallouts=${me.ignoreFilterCallOuts}&negativeMethods=${me.selectedNegativeMethod}&thresholdWallTime=${me.txtThresholdWallTime}&methodCount=${methodCount}&thresholdDiffElapsedTime=${me.txtThresholdelapsedTime}${me.commonService.enableQueryCaching === 1 ? `&cacheId=${me.id.testRun}` : ''}`;
        me.loading = false;
        return me.ddrHttpService.getChildFlowpathData(queryParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["childFlowpathLoadedState"]) {
                let data = state.data;
                if (data.Status) {
                    alert(data.Status);
                }
                else {
                    let subsParentMethodName = "";
                    if (nodeRef && nodeRef.parent && nodeRef.parent.data)
                        subsParentMethodName = nodeRef.parent.data.methodName;
                    else
                        subsParentMethodName = this._ddrData.decodeHTMLString(node.methodName);
                    this.repeatedMethodData[this.repeatedMethodData.length] = data.repeatMethodsData;
                    if (subsParentMethodName.length > 30)
                        subsParentMethodName = subsParentMethodName.substring(0, subsParentMethodName.length) + "...";
                    let subCallout = this._ddrData.decodeHTMLString(node.methodName);
                    if (subCallout.length > 30)
                        subCallout = subCallout.substring(0, subCallout.length - 1) + "...";
                    this.count = 0;
                    this.expandChildren(data.treedata.data[0]);
                    if (nodeRef && nodeRef.parent && nodeRef.parent.data)
                        this.values.push({ "treeData": data.treedata.data, "subsParentMethodName": subsParentMethodName, "parentMethodName": nodeRef.parent.data.methodName, "Callout": this._ddrData.decodeHTMLString(node.methodName), "subCallout": subCallout });
                    else
                        this.values.push({ "treeData": data.treedata.data, "subsParentMethodName": subsParentMethodName, "parentMethodName": subsParentMethodName, "Callout": this._ddrData.decodeHTMLString(node.methodName), "subCallout": subCallout });
                    if (popupindex == undefined)
                        popupindex = 0;
                    this.visibleArr[popupindex] = true;
                }
            }
        }, (error) => {
            console.error(`Error in fetching child details ~ `, error);
        });
    }
    /*This method is used to provide the parameter for which child should be expanded to a level*/
    expandSameLeveluptoFixLevelforValue(lineNumber, limit, childArrlength) {
        this.loading = true;
        let node = this.preNode[lineNumber];
        if (childArrlength == limit) {
            let value = childArrlength % 100;
            if (value > 50)
                value = value - 50;
            limit = childArrlength - value;
        }
        setTimeout(() => {
            this.expandSameLeveluptoFixLevel(node, limit, lineNumber, childArrlength);
        }, 1000);
    }
    /*This method is used to expand children to a fixed level when there is a large amount of data*/
    expandSameLeveluptoFixLevel(node, limit, parentLineNumber, childArrLength) {
        let toAddchildren = [];
        let obj = {};
        let offset = limit + 50;
        if (offset > childArrLength)
            offset = childArrLength;
        for (let j = limit; j < offset; j++) {
            obj = this.childrenObj[node.data.lineNumber][j];
            if (obj != undefined) {
                if (j != 0 && limit == j) {
                    obj['data']['limit'] = limit - 50;
                    obj['data']['offset'] = limit;
                    obj['data']['type'] = 1;
                }
                if (j == offset - 1) {
                    if (Number(offset + 50) > childArrLength) {
                        obj['data']['offset'] = childArrLength;
                    }
                    else {
                        obj['data']['offset'] = offset + 50;
                    }
                    obj['data']['type'] = 2;
                    obj['data']['limit'] = offset;
                }
                obj['data']['line'] = parentLineNumber;
                obj['data']['last'] = childArrLength;
                this.expandChildren(obj);
                toAddchildren.push(obj);
            }
            else
                break;
        }
        node.children = toAddchildren;
        node.expanded = true;
        this.mctData = [...this.mctData];
        this.loading = false;
        return;
    }
    /*We are making a rest call to get the data for MCT from server*/
    getMCTData() {
        const me = this;
        let endTimetoPass;
        let startTimetoPass = Number(me.trStartTime) - 900000;
        if (me.trEndTime == '' || me.trEndTime == null || me.trEndTime == undefined || isNaN(me.trEndTime)) {
            var strEndTime = Number(me.trStartTime) + Number(me.fpDuration);
            endTimetoPass = Number(strEndTime) + 900000;
        }
        else {
            endTimetoPass = Number(me.trEndTime) + 900000;
        }
        me._ddrData.dlStartTime = startTimetoPass;
        me._ddrData.dlEndTime = endTimetoPass;
        let lineNumber = 0;
        if (me.selectedNode) {
            lineNumber = me.selectedNode['data']['lineNumber'];
        }
        let methodCount = 50000;
        if (me.queryParams.methodsCount)
            methodCount = Number(me.queryParams.methodsCount.toString().replace(/,/g, ""));
        const queryParams = `filterGreaterThan=${me.txtFilterWallTime}&filterSelfTime=${me.txtFilterSelfTime}&filterTop=${me.txtFlterMethodLevel}&packageList=&classList=&methodList=&testRun=${me.id.testRun}&flowPathInstance=${me.queryParams.flowpathInstance}&strStartTime=${startTimetoPass}&strEndTime=${Number(endTimetoPass) + 1000}&entryResponseTime=${me.fpDuration}&thresholdWallTime=${me.txtThresholdWallTime}&FromAngular=1&enableMergeCase=${me.enableMergeCase}&ignoreFilterCallouts=${me.ignoreFilterCallOuts}&methodCount=${methodCount}&filterMethods=false&thresholdDiffElapsedTime=${me.txtThresholdelapsedTime}&lineNumber=${lineNumber}&tierName=${((this.commonService.getData().tierName) || me.queryParams.tierName)}${me.commonService.enableQueryCaching === 1 ? `&cacheId=${me.id.testRun}` : ''}`;
        me.loading = false;
        return me.ddrHttpService.getMCTData(queryParams);
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName;
        if (this._ddrData.isFromtrxFlow) {
            hostDcName = "//" + this._ddrData.hostTr + ":" + this._ddrData.portTr;
            this.id.testRun = this._ddrData.testRunTr;
        }
        else if (this.sessionService.preSession.multiDc === true && !isDownloadCase) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            if (hostDcName.lastIndexOf('ALL/') !== -1)
                hostDcName = hostDcName.substring(0, hostDcName.lastIndexOf('/'));
            this.id.testRun = this._ddrData.testRun;
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        return hostDcName;
    }
    /*This method is used to get the data through rest call for method summary report*/
    getMethodSummaryData() {
        this.loading = false;
        var endTimetoPass;
        var startTimetoPass;
        if (this.trStartTime != '')
            startTimetoPass = Number(this.trStartTime) - 900000;
        if (this.trEndTime == '' || this.trEndTime == null || this.trEndTime == undefined || isNaN(this.trEndTime)) {
            var strEndTime = Number(this.trStartTime) + Number(this.fpDuration);
            endTimetoPass = Number(strEndTime) + 900000;
        }
        else {
            endTimetoPass = Number(this.trEndTime) + 900000;
        }
        this._ddrData.dlStartTime = startTimetoPass;
        this._ddrData.dlEndTime = endTimetoPass;
        const queryParams = `testRun=${this.id.testRun}&flowpathInstance=${this.queryParams.flowpathInstance}&strStartTime=${startTimetoPass}&strEndTime=${endTimetoPass}&tierId=${this.queryParams.tierId}&serverId=${this.queryParams.serverId}&appId=${this.queryParams.appId}&tierName=${this.commonService.getData().tierName}&type=method&entity=0${this.commonService.enableQueryCaching === 1 ? `&cacheId=${this.id.testRun}` : ''}`;
        return this.ddrHttpService.getMethodTimingReportData(queryParams).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_9__["timeout"])(this.commonService.ajaxTimeOut)).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["MethodTimingLoadedState"]) {
                this.doAssignMSTValue(state.data);
            }
        }, (error) => {
            console.error('Error in fetching response ~ ', error);
            this.loading = false;
        });
    }
    /*This method is used to assign the values for Method Summary Report*/
    doAssignMSTValue(res) {
        this.loading = false;
        if (res.hasOwnProperty('Status')) {
            this.showError(res.Status);
        }
        this.methodTimingData = this.doHyperLinkOnMethod(res.data);
        if (this.methodTimingData.length > 0)
            this.dataCount = this.methodTimingData.length;
        if (this.methodTimingData.length == 0) {
            this.showDownLoadReportIcon = false;
            this.showErrorMessage = true;
        }
        else
            this.showErrorMessage = false;
    }
    /**Formatter cell data for percentage field */
    pctFormatter(value) {
        if (!isNaN(value) && Number(value) < 0) {
            return '-';
        }
        else if (!isNaN(value)) {
            return Number(Number(value).toFixed(2)).toLocaleString();
        }
        else {
            return value;
        }
    }
    /**Formatter cell data for converting ms to sec field */
    secFormatter(value) {
        if (!isNaN(value))
            return Number(value / 1000).toFixed(2);
        else
            return value;
    }
    /**Simple formater for tolocalstring */
    formatter(value) {
        if (value != '' && !isNaN(value)) {
            return Number(Number(value)).toLocaleString();
        }
        else if (value === '') {
            return '-';
        }
        else
            return value;
    }
    cpuTimeFormatter(value) {
        if (!isNaN(value)) {
            value = (Number(value)).toLocaleString();
            if (value == 0)
                value = "<1";
            return value;
        }
        else
            return value;
    }
    /*This method is used to open Auto Instrumentaion Dialogue*/
    openAutoInstDialog() {
        const me = this;
        let testRunStatus;
        let instanceType;
        const queryParams = `testRun=${me.id.testRun}`;
        me.ddrHttpService.getTRStatus(queryParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["TestRunStatusLoadedState"]) {
                let res = state.data;
                testRunStatus = res.data;
                if (testRunStatus.length != 0) {
                    me.showAutoInstrPopUp = true;
                    if (me.queryParams.Instance_Type != undefined) {
                        instanceType = me.queryParams.Instance_Type.toLowerCase() === 'java' ? 'Java' : me.queryParams.Instance_Type.toLowerCase() === 'dotnet' ? 'DotNet' : me.queryParams.Instance_Type.toLowerCase() === 'dotnetc' ? 'DotNetC' : instanceType;
                    }
                    else {
                        instanceType = me.queryParams.instanceType.toLowerCase() === 'java' ? 'Java' : me.queryParams.instanceType.toLowerCase() === 'dotnet' ? 'DotNet' : me.queryParams.instanceType.toLowerCase() === 'dotnetc' ? 'DotNetC' : instanceType;
                    }
                    me.argsForAIDDSetting = [me.queryParams.appName, me.queryParams.appId, instanceType, me.queryParams.tierName,
                        me.queryParams.serverName, me.queryParams.serverId, "-1", me.queryParams.urlName, "DDR", testRunStatus[0].status, me.id.testRun];
                }
                else {
                    me.showAutoInstrPopUp = false;
                    alert("Could not start instrumentation, test is not running");
                    return;
                }
            }
        }, (error) => {
            console.error(' Error is fetching test run status', error);
        });
    }
    /*This method is used to start auto instrumentation*/
    startInstrumentation(result) {
        this.showAutoInstrPopUp = false;
        alert(result);
    }
    closeAIDDDialog(isCloseAIDDDialog) {
        this.showAutoInstrPopUp = isCloseAIDDDialog;
    }
    openSeqDiagram() {
        var endTimetoPass;
        // need to optimize below code as it is used many times
        if (this.trEndTime == '' || this.trEndTime == null || this.trEndTime == undefined || isNaN(this.trEndTime)) {
            endTimetoPass = Number(this.trStartTime) + Number(this.fpDuration);
        }
        else {
            endTimetoPass = Number(this.trEndTime);
        }
        var urlforJsp = '';
        if (this.commonService.host != undefined && this.commonService.host != '' && this.commonService.host != null) {
            if (this.commonService.protocol && this.commonService.protocol.endsWith("://"))
                urlforJsp = this.commonService.protocol + this.commonService.host + ':' + this.commonService.port;
            else if (this.commonService.protocol)
                urlforJsp = this.commonService.protocol + "://" + this.commonService.host + ':' + this.commonService.port;
            else
                urlforJsp = "// " + this.commonService.host + ':' + this.commonService.port;
        }
        else {
            urlforJsp = this.getHostUrl();
        }
        urlforJsp += "/" + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", "") + "/integration.jsp?testRun=" + this.id.testRun + "&urlname=" + this.queryParams.urlName
            + "&completeURL=" + encodeURIComponent(this.queryParams.urlQueryParamStr) + "&flowpathID=" + this.queryParams.flowpathInstance + "&tierid=" + this.queryParams.tierId
            + "&serverid=" + this.queryParams.serverId + "&appid=" + this.queryParams.appId + "&tierName=" + this.queryParams.tierName
            + "&serverName=" + this.queryParams.serverName + "&appName=" + this.queryParams.appName + "&strStartTime=" + Number(this.trStartTime)
            + "&strEndTime=" + endTimetoPass + "&btCategory=" + this.queryParams.btCatagory + "&strOprName=FromAngularMCT&breadCrumbTrackID=0";
        window.open(urlforJsp, "_blank");
    }
    /**
     * Method used to create filter criteria for show in top of the section
     */
    createFilterCriteria() {
        this.filterCriteria = "";
        this.downloadFilterCriteria = '';
        let endTime = Number(this.trStartTime) + Number(this.fpDuration);
        this.trEndTime = endTime;
        if (this.commonService.mctFlag == true && this.commonService.mctData) {
            if (this.commonService.mctData.tierName != "NA" && this.commonService.mctData.tierName != "" && this.commonService.mctData.tierName != "undefined" && this.commonService.mctData.tierName != undefined) {
                this.filterCriteria += "Tier=" + this.commonService.mctData.tierName;
                this.downloadFilterCriteria += "Tier=" + this.commonService.mctData.tierName;
            }
            if (this.commonService.mctData.serverName != "NA" && this.commonService.mctData.serverName != "" && this.commonService.mctData.serverName != "undefined" && this.commonService.mctData.serverName != undefined) {
                this.filterCriteria += ", Server=" + this.commonService.mctData.serverName;
                this.downloadFilterCriteria += ", Server=" + this.commonService.mctData.serverName;
            }
            if (this.commonService.mctData.appName != "NA" && this.commonService.mctData.appName != "" && this.commonService.mctData.appName != "undefined" && this.commonService.mctData.appName != undefined) {
                this.filterCriteria += ", Instance=" + this.commonService.mctData.appName;
                this.downloadFilterCriteria += ", Instance=" + this.commonService.mctData.appName;
            }
        }
        else {
            if (this.id.tierName != "NA" && this.id.tierName != "" && this.id.tierName != "undefined" && this.id.tierName != undefined) {
                this.filterCriteria += "Tier=" + this.id.tierName;
                this.downloadFilterCriteria += "Tier=" + this.id.tierName;
            }
            if (this.id.serverName != "NA" && this.id.serverName != "" && this.id.serverName != "undefined" && this.id.serverName != undefined) {
                this.filterCriteria += ", Server=" + this.id.serverName;
                this.downloadFilterCriteria += ", Server=" + this.id.serverName;
            }
            if (this.id.appName != "NA" && this.id.appName != "" && this.id.appName != "undefined" && this.id.appName != undefined) {
                this.filterCriteria += ", Instance=" + this.id.appName;
                this.downloadFilterCriteria += ", Instance=" + this.id.appName;
            }
        }
        if (this.queryParams.startTime != undefined && this.queryParams.startTime != '' && this.queryParams.startTime != 'NA') {
            this.filterCriteria += ", Start Time=" + this.sessionService.convertTimestampIntoFormattedString(Number(this.queryParams.startTimeInMs), "MM/DD/YYYY HH:mm:ss");
            this.downloadFilterCriteria += ", Start Time=" + this.sessionService.convertTimestampIntoFormattedString(Number(this.queryParams.startTimeInMs), "MM/DD/YYYY HH:mm:ss");
        }
        if (this.queryParams.endTime != undefined && this.queryParams.endTime != '' && this.queryParams.endTime != 'NA') {
            this.filterCriteria += ", End Time=" + this.queryParams.endTime;
            this.downloadFilterCriteria += ", End Time=" + this.queryParams.endTime;
        }
        if (this.queryParams.selfResponseTime != undefined && this.queryParams.selfResponseTime != '' && this.queryParams.selfResponseTime != 'NA') {
            this.filterCriteria += ", ResponseTime=" + this.formatter(this.queryParams.selfResponseTime) + "(ms)";
            this.downloadFilterCriteria += ", ResponseTime=" + this.formatter(this.queryParams.selfResponseTime) + "(ms)";
        }
        if (this.queryParams.fpDuration != undefined && this.queryParams.fpDuration != '' && this.queryParams.fpDuration != 'NA') {
            this.filterCriteria += ", ProcessingTime=" + this.formatter(this.queryParams.fpDuration) + "(ms)";
            this.downloadFilterCriteria += ", ProcessingTime=" + this.formatter(this.queryParams.fpDuration) + "(ms)";
        }
        if (this.queryParams.urlName != undefined && this.queryParams.urlName != '' && this.queryParams.urlName != 'NA') {
            this.filterCriteria += ", BT=" + this.queryParams.urlName;
            this.downloadFilterCriteria += ", BT=" + this.queryParams.urlName;
        }
        if (this.queryParams.urlQueryParamStr != undefined && this.queryParams.urlQueryParamStr != '' && this.queryParams.urlQueryParamStr != 'NA') {
            if (this.queryParams.urlQueryParamStr.length > 45) {
                let wholeUrl = this.queryParams.urlQueryParamStr.substring(0, 45) + "...";
                this.filterCriteria += ",<span style='cursor:pointer;' title='" + this.queryParams.urlQueryParamStr + "'>" + " URL=" + wholeUrl + "</span>";
            }
            else {
                this.filterCriteria += ", URL=" + this.queryParams.urlQueryParamStr;
            }
            this.downloadFilterCriteria += ", URL=" + this.queryParams.urlQueryParamStr;
        }
        if (this.id.pageName != null && this.id.pageName != undefined && this.id.pageName != "" && this.id.pageName != "NA") {
            this.filterCriteria += ", Page=" + this.id.pageName;
            this.downloadFilterCriteria += ", Page=" + this.id.pageName;
        }
        if (this.id.script != null && this.id.script != undefined && this.id.script != "" && this.id.script != "NA") {
            this.filterCriteria += ", Script=" + this.id.script;
            this.downloadFilterCriteria += ", Script=" + this.id.script;
        }
        if (this.id.transtx != null && this.id.transx != undefined && this.id.transtx != "" && this.id.transtx != "NA") {
            this.filterCriteria += ", Transaction=" + this.id.transtx;
            this.downloadFilterCriteria += ", Transaction=" + this.id.transtx;
        }
        if (this.filterCriteria.startsWith(",")) {
            this.filterCriteria = this.filterCriteria.substring(1);
            this.downloadFilterCriteria = this.downloadFilterCriteria.substring(1);
        }
        if (this.filterCriteria.endsWith(",")) {
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
            this.downloadFilterCriteria = this.downloadFilterCriteria.substring(0, this.downloadFilterCriteria.length - 1);
        }
    }
    /**
     * This method is used to set Test Run header info which is used in download report as title
     */
    setTestRunInHeader() {
        if (decodeURIComponent(this.id.ipWithProd).indexOf("netstorm") != -1) {
            this.strTitle = "Netstorm - Repeated Callout Details Report - Test Run : " + this.id.testRun;
            this.strTitleMct = "Netstorm - Method Calling Tree - Test Run : " + this.id.testRun;
        }
        else {
            this.strTitle = "Netdiagnostics Enterprise - Repeated Callout Details Report - Session : " + this.id.testRun;
            this.strTitleMct = "Netdiagnostics Enterprise - Method Calling Tree - Session : " + this.id.testRun;
        }
    }
    downloadReportMCT(reports) {
        if (reports == "word") {
            this.downloadWordEnable = true;
        }
        if (reports == "excel") {
            this.downloadExcelEnable = true;
        }
        if (reports == "pdf") {
            this.downloadPdfEnable = true;
        }
        let renameArray1 = { "methodName": "Methods", 'lineNumber': 'Seq No.', "methodArgument": "Arguments", "threadName": "Thread", "threadId": "ThreadId", "tierName": "Tier", "serverName": "Server", "appName": "Instance", "className": "Class", "pacName": "Package", "startTime": "StartTime", "wallTime": "WallTime(ms)", "cpuTime": "CPUTime(ms)", "percentage": "Percentage", "pageName": "PageName", "api": "API", "waitTime": "WaitTime(ms)", "syncTime": "SyncTime(ms)", "ioTime": "IOTime(ms)", "suspensionTime": "SuspensionTime(ms)", "instanceType": "InstanceType", "asyncCall": "Async_Call", "queueTime": "ThreadQueueTime(ms)", "selfTime": "SelfTime(ms)", "timeStamp": "Elapsed Time(ms)", "sourceNetwork": "Network Delay in Req(ms)", "destNetwork": "Network Delay in Resp(ms)", "level": "Depth" };
        let colOrder1 = ["Seq No.", "Methods", "Arguments", "Thread", "ThreadId", "ThreadQueueTime(ms)", "Tier", "Server", "Instance", "Class", "Package", "StartTime", "SelfTime(ms)", "WallTime(ms)", "CPUTime(ms)", "Percentage", "PageName", "API", "WaitTime(ms)", "SyncTime(ms)", "IOTime(ms)", "SuspensionTime(ms)", "InstanceType", "Async_Call", "Elapsed Time(ms)", "Network Delay in Req(ms)", "Network Delay in Resp(ms)", "Depth"];
        if (this.queryParams.urlQueryParamStr == "undefined" || this.queryParams.urlQueryParamStr == undefined) // condition for transaction flowmap to method calling tree
            this.queryParams['urlQueryParamStr'] = this.queryParams.urlQueryParmStr; // because from transaction flowmap we are passing urlQueryParmStr 
        this.downloadMctData.forEach((val, index) => {
            if (index == 0) {
                if (val['methodArgument'] == "-" || val['methodArgument'].includes("Method Arguments")) {
                    if (val['methodArgument'] == "-") {
                        val['methodArgument'] = this.queryParams.urlQueryParamStr;
                    }
                    else {
                        val['methodArgument'] = this.queryParams.urlQueryParamStr + '\n' + val['methodArgument'];
                    }
                }
            }
            delete val['fqm'];
            delete val['methodId'];
            //    delete val['timeStamp'];
            delete val['subType'];
            //delete val['threadId'];     this is commented beacuse new column for threadid is shown 
            delete val['seqNo'];
            delete val['_$visited'];
            delete val['slowMethod'];
            delete val['repeatedMethodCount'];
            delete val['repeatObj'];
            delete val['keyLine'];
            delete val['uninstrumentedFlag'];
            delete val['showMethodColor'];
            delete val['eventIdLight'];
            delete val['eventIdDark'];
            delete val['calloutType'];
            delete val['eventId'];
            delete val['asyncToBeMatchedId'];
            delete val['dynLogFlag'];
            delete val['severityBgColorField'];
            delete val["severityBgColorField2"];
            delete val['entrySeqNum'];
            delete val['queryParameter'];
            delete val['returnValue'];
            val['cpuTime'] = this.cpuTimeFormatter(val['cpuTime']);
        });
        let downloadObj = {
            downloadType: reports,
            varFilterCriteria: this.downloadFilterCriteria.replace(/<[^>]*>/g, ""),
            strSrcFileName: 'MethodCallingReport',
            strRptTitle: this.strTitleMct,
            renameArray: JSON.stringify(renameArray1),
            colOrder: colOrder1.toString(),
            jsonData: JSON.stringify(this.downloadMctData)
        };
        let downloadFileUrl = '';
        if (this.commonService.protocol && this.commonService.host != undefined && this.commonService.host != '' && this.commonService.host != null) {
            if (this.commonService.protocol && this.commonService.protocol.endsWith("://"))
                downloadFileUrl = this.commonService.protocol + this.commonService.host + ':' + this.commonService.port + '/' + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", "");
            else if (this.commonService.protocol)
                downloadFileUrl = this.commonService.protocol + "://" + this.commonService.host + ':' + this.commonService.port + '/' + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", "");
            else
                downloadFileUrl = "//" + this.commonService.host + ':' + this.commonService.port + '/' + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", "");
        }
        else {
            if (this.sessionService.preSession.multiDc === true) {
                downloadFileUrl = decodeURIComponent(this._ddrData.getHostUrlMultiDC(true) + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", ""));
            }
            else {
                downloadFileUrl = decodeURIComponent(this._ddrData.getHostUrl(true) + '/' + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", ""));
            }
        }
        downloadFileUrl += '/v1/cavisson/netdiagnostics/ddr/downloadAngularReport';
        if (this.sessionService.preSession.multiDc === true && (downloadFileUrl.includes("/tomcat") || downloadFileUrl.includes("/node"))) {
            if (downloadFileUrl.includes("/tomcat"))
                downloadFileUrl = downloadFileUrl.replace("/tomcat", "/node");
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, downloadObj).subscribe(res => (this.checkDownloadType(res)));
        }
        else {
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, JSON.stringify(downloadObj)).subscribe(res => (this.openDownloadReports(res)));
        }
    }
    checkDownloadType(res) {
        try {
            if (res) {
                res = JSON.parse(res);
                let dcinfo = res.dcInfo;
                let keys = Object.keys(dcinfo);
                for (let i = 0; i < keys.length; i++) {
                    if (dcinfo[keys[i]].isMaster == true) {
                        this.openDownloadReports(res, dcinfo[keys[i]]);
                    }
                }
            }
        }
        catch (error) {
            console.error("Getting Error While Parsing Response From Node ", error);
        }
    }
    donwloadReportsRepeatedMethod(reports) {
        if (reports == "word") {
            this.downloadWordEnable = true;
        }
        if (reports == "excel") {
            this.downloadExcelEnable = true;
        }
        if (reports == "pdf") {
            this.downloadPdfEnable = true;
        }
        let renameArray = { "methodArgument": "Arguments", "returnValue": "Return Value", "timeStamp": "ElapsedTime(ms)", "wallTime": "WallTime(ms)", "percentage": "Percentage", "queueTime": "Thread QueueTime", "selfTime": "Self Time(ms)", "cpuTime": "CPU Time(ms)", "threadId": "ThreadId", "threadName": "Thread", "waitTime": "WaitTime(ms)", "syncTime": "SyncTime(ms)", "ioTime": "IOTime(ms)", "suspensionTime": "SuspensionTime(ms)", "lineNumber": "Seq No.", "level": "Depth" };
        let colOrder = ["Arguments", "Return Value", "ElapsedTime(ms)", "WallTime(ms)", "Percentage", "Thread QueueTime", "Self Time(ms)", "CPU Time(ms)", "ThreadId", "Thread", "WaitTime(ms)", "SyncTime(ms)", "IOTime(ms)", "SuspensionTime(ms)", "Seq No.", "Depth"];
        let data = JSON.parse(JSON.stringify(this.downloadRepeatMethod));
        data.forEach((val) => {
            delete val['tierName'];
            delete val['startTime'];
            delete val['sourceNetwork'];
            delete val['showMethodColor'];
            delete val['serverName'];
            delete val['seqNo'];
            delete val['repeatedMethodCount'];
            delete val['pageName'];
            delete val['pacName'];
            delete val['methodName'];
            delete val['methodId'];
            delete val['instanceType'];
            delete val['fqm'];
            delete val['destNetwork'];
            delete val['className'];
            delete val['asyncCall'];
            delete val['appName'];
            delete val['api'];
            delete val['repeatObj'];
            delete val['keyLine'];
            delete val['subType'];
            delete val['eventId'];
            delete val['calloutType'];
            delete val['asyncToBeMatchedId'];
            delete val['eventIdDark'];
            delete val['eventIdLight'];
            delete val['dynLogFlag'];
            delete val['severityBgColorField'];
            delete val['severityBgColorField2'];
            delete val['entrySeqNum'];
            delete val['queryParameter'];
        });
        let downloadObj = {
            downloadType: reports,
            varFilterCriteria: this.downloadFilterCriteria.replace(/<[^>]*>/g, ""),
            strSrcFileName: 'MethodSummaryReport',
            strRptTitle: this.strTitle,
            renameArray: JSON.stringify(renameArray),
            colOrder: colOrder.toString(),
            jsonData: JSON.stringify(data)
        };
        let downloadFileUrl = '';
        if (this.commonService.host != undefined && this.commonService.host != '' && this.commonService.host != null) {
            if (this.commonService.protocol && this.commonService.protocol.endsWith("://"))
                downloadFileUrl = this.commonService.protocol + this.commonService.host + ':' + this.commonService.port;
            else if (this.commonService.protocol)
                downloadFileUrl = this.commonService.protocol + "://" + this.commonService.host + ':' + this.commonService.port;
            else
                downloadFileUrl = "// " + this.commonService.host + ':' + this.commonService.port;
        }
        else {
            if (this.sessionService.preSession.multiDc === true) {
                downloadFileUrl = decodeURIComponent(this._ddrData.getHostUrlMultiDC(true) + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", ""));
            }
            else {
                downloadFileUrl = decodeURIComponent(this._ddrData.getHostUrl(true) + '/' + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", ""));
            }
        }
        downloadFileUrl += '/v1/cavisson/netdiagnostics/ddr/downloadAngularReport';
        if (this.sessionService.preSession.multiDc === true && (downloadFileUrl.includes("/tomcat") || downloadFileUrl.includes("/node"))) {
            if (downloadFileUrl.includes("/tomcat"))
                downloadFileUrl = downloadFileUrl.replace("/tomcat", "/node");
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, downloadObj).subscribe(res => (this.checkDownloadType(res)));
        }
        else {
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, JSON.stringify(downloadObj)).subscribe(res => (this.openDownloadReports(res)));
        }
    }
    downloadReports(reports) {
        let renameArray = { "pN": "Package", "cN": "Class", "mN": "Method", "fG": "FunctionalGroup", "percent": "Percentage", "sT": "CumSelfTime(sec)", "avgST": "AvgSelfTime(ms)", "totWT": "CumWallTime(sec)", "avgWT": "AvgWallTime(ms)", "cumCPUST": "CumCpuSelfTime(sec)", "avgCPUST": "AvgCpuSelfTime(ms)", "min": "MinSelfTime(ms)", "max": "MaxSelfTime(ms)", "eC": "Count", "variance": "Variance", "waitTime": "WaitTime(ms)", "syncTime": "SyncTime(ms)", "iotime": "IOTime(ms)", "suspensiontime": "SuspensionTime(ms)", "level": "Depth" };
        let colOrder = ['Package', 'Class', 'Method', 'FunctionalGroup', 'Percentage', 'CumSelfTime(sec)', 'AvgSelfTime(ms)', 'CumWallTime(sec)', 'AvgWallTime(ms)', 'CumCpuSelfTime(sec)', 'AvgCpuSelfTime(ms)', 'MinSelfTime(ms)', 'MaxSelfTime(ms)', 'Count', 'Variance', 'WaitTime(ms)', 'SyncTime(ms)', 'IOTime(ms)', 'SuspensionTime(ms)', 'Depth'];
        let pNFlag = false;
        this.methodTimingData.forEach((val, index) => {
            if (val.hasOwnProperty('pN') === false) {
                delete val['pN'];
                pNFlag = true;
            }
            delete val['ID'];
            delete val['eT'];
            delete val['eN'];
            delete val['cT'];
            delete val['_$visited'];
            delete val['avgCPU'];
            delete val['sTOrg'];
            delete val["severityBgColorField2"];
            val['sT'] = (Number(val['sT']) / 1000).toFixed(2);
            if (Number(val['percent']) != 0 && Number(val['percent']) != 100)
                val['percent'] = Number(val['percent']).toFixed(3);
            val['totWT'] = (Number(val['totWT']) / 1000).toFixed(2);
            val['avgST'] = Number(val['avgST']).toFixed(3);
            val['avgWT'] = Number(val['avgWT']).toFixed(3);
        });
        if (pNFlag) {
            delete renameArray['pN'];
            colOrder.shift();
        }
        let downloadObj = {
            downloadType: reports,
            varFilterCriteria: this.downloadFilterCriteria.replace(/<[^>]*>/g, ""),
            strSrcFileName: 'MethodSummaryReport',
            strRptTitle: this.strTitle,
            renameArray: JSON.stringify(renameArray),
            colOrder: colOrder.toString(),
            jsonData: JSON.stringify(this.methodTimingData)
        };
        let downloadFileUrl = '';
        if (this.commonService.host != undefined && this.commonService.host != '' && this.commonService.host != null) {
            if (this.commonService.protocol && this.commonService.protocol.endsWith("://"))
                downloadFileUrl = this.commonService.protocol + this.commonService.host + ':' + this.commonService.port;
            else if (this.commonService.protocol)
                downloadFileUrl = this.commonService.protocol + "://" + this.commonService.host + ':' + this.commonService.port;
            else
                downloadFileUrl = "// " + this.commonService.host + ':' + this.commonService.port;
        }
        else {
            if (this.sessionService.preSession.multiDc === true) {
                downloadFileUrl = decodeURIComponent(this._ddrData.getHostUrlMultiDC(true) + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", ""));
            }
            else {
                downloadFileUrl = decodeURIComponent(this._ddrData.getHostUrl(true) + '/' + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", ""));
            }
        }
        downloadFileUrl += '/v1/cavisson/netdiagnostics/ddr/downloadAngularReport';
        if (this.sessionService.preSession.multiDc === true && (downloadFileUrl.includes("/tomcat") || downloadFileUrl.includes("/node"))) {
            if (downloadFileUrl.includes("/tomcat"))
                downloadFileUrl = downloadFileUrl.replace("/tomcat", "/node");
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, downloadObj).subscribe(res => (this.checkDownloadType(res)));
        }
        else {
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, JSON.stringify(downloadObj)).subscribe(res => (this.openDownloadReports(res)));
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    //To open the download file from the particular path 
    openDownloadReports(res, dcInfo) {
        let downloadFileUrl = '';
        if (this.sessionService.preSession.multiDc === true) {
            downloadFileUrl = location.protocol + "//" + location.host;
            res = res.tierData;
        }
        else {
            if (dcInfo) {
                downloadFileUrl = decodeURIComponent(dcInfo.protocol + "://" + dcInfo.ip + ':' + dcInfo.port);
                res = res.tierData;
            }
            else {
                if (this.host != undefined && this.host != '' && this.host != null) {
                    if (this.commonService.protocol && this.commonService.protocol.endsWith("://"))
                        downloadFileUrl = this.commonService.protocol + this.commonService.host + ':' + this.commonService.port;
                    else
                        downloadFileUrl = this.commonService.protocol + "://" + this.commonService.host + ':' + this.commonService.port;
                }
                else {
                    downloadFileUrl = decodeURIComponent(this.getHostUrl(true) + '/' + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", "")).replace('/netstorm', '').replace('/netdiagnostics', '');
                }
            }
        }
        downloadFileUrl += '/common/' + res;
        window.open(downloadFileUrl);
        this.downloadExcelEnable = false;
        this.downloadPdfEnable = false;
        this.downloadWordEnable = false;
    }
    ngOnDestroy() {
        if (this.commonService.isFromSplitView) {
            this._ddrData.splitViewFlag = true;
            this.commonService.isToLoadSideBar = false;
        }
    }
    openDialogforfilter() {
        this.filterDialog = true;
        this.MCTDialogFilters = true;
    }
    showColorMeaning() {
        this.showColor = true;
    }
    applyThresholdFilter() {
        this.isReorder = false;
        if (this.txtFlterMethodLevel == undefined || this.txtFlterMethodLevel == null || this.txtFilterWallTime == undefined || this.txtFilterSelfTime == undefined || this.txtFilterWallTime == null || this.txtThresholdWallTime == undefined || this.txtThresholdWallTime == null) {
            alert('Please Fill all the values of Filter');
            return;
        }
        if (this.selectedNegativeMethod && this.selectedNegativeMethod.length > 0) {
            this.filterMethods = "1";
            if (this.selectedPackageList.length > 0) {
                for (let k = 0; k < this.selectedNegativeMethod.length; k++) {
                    let pkgClsindex = this.selectedNegativeMethod[k].lastIndexOf(".");
                    let packageClassName = this.selectedNegativeMethod[k].substring(0, pkgClsindex);
                    let packageName = packageClassName.substring(0, packageClassName.lastIndexOf("."));
                    let className = packageClassName.substring(packageClassName.lastIndexOf(".") + 1, packageClassName.length);
                    let methodName = this.selectedNegativeMethod[k].substring(pkgClsindex + 1, this.selectedNegativeMethod[k].length);
                    if (this.selectedPackageList.indexOf(packageName) != -1) {
                        if (this.selectedActClss.indexOf(className) != -1) {
                            if (this.selectedActMethod.indexOf(methodName) != -1) {
                                alert('Positive and negative filter could not be same ');
                                return;
                            }
                        }
                    }
                }
            }
        }
        else
            this.filterMethods = "0";
        let endTimetoPass;
        var startTimetoPass = Number(this.trStartTime) - 900000;
        if (this.trEndTime == '' || this.trEndTime == null || this.trEndTime == undefined) {
            var strEndTime = Number(this.trStartTime) + Number(this.fpDuration);
            endTimetoPass = Number(strEndTime) + 900000;
        }
        else {
            endTimetoPass = Number(this.trEndTime) + 900000;
        }
        this._ddrData.dlStartTime = startTimetoPass;
        this._ddrData.dlEndTime = endTimetoPass;
        this.assignColsForMCT();
        if (this.selectedPackageList == undefined)
            this.selectedPackageList = [];
        if (this.selectedActClss == undefined)
            this.selectedActClss = [];
        if (this.selectedActMethod == undefined)
            this.selectedActMethod = [];
        this.loading = true;
        this.filterDialog = false;
        let lineNumber = 0;
        if (this.selectedNode) {
            lineNumber = this.selectedNode['data']['lineNumber'];
        }
        let methodCount = 50000;
        if (this.queryParams.methodsCount)
            methodCount = Number(this.queryParams.methodsCount.toString().replace(/,/g, ""));
        const queryParams = `filterGreaterThan=${this.txtFilterWallTime}&filterSelfTime=${this.txtFilterSelfTime}&filterTop=${this.txtFlterMethodLevel}&packageList=${this.selectedPackageList.toString()}&classList=${this.selectedActClss.toString()}&methodList=${this.selectedActMethod.toString()}&testRun=${this.id.testRun}&flowPathInstance=${this.queryParams.flowpathInstance}&strStartTime=${startTimetoPass}&strEndTime=${Number(endTimetoPass) + 1000}&entryResponseTime=${this.fpDuration}&thresholdWallTime=${this.txtThresholdWallTime}&FromAngular=1&enableMergeCase=${this.enableMergeCase}&ignoreFilterCallouts=${this.ignoreFilterCallOuts}&negativeMethodsFilter=${this.selectedNegativeMethod}&methodCount=${methodCount}&filterMethods=${this.filterMethods}&thresholdDiffElapsedTime=${this.txtThresholdelapsedTime}&lineNumber=${lineNumber}${this.commonService.enableQueryCaching === 1 ? `&cacheId=${this.id.testRun}` : ''}`;
        this.ddrHttpService.getMCTData(queryParams).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_9__["timeout"])(this.commonService.ajaxTimeOut)).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["MethodCallDetailsLoadedState"]) {
                let mctData = state.data;
                this.limit = 10;
                this.offset = 0;
                this.mctData = mctData.treedata.data;
                this.uniqueMethodSignature = mctData.uniqueMethods;
                this.addPackageClassmethodList();
                this.downloadMctData = mctData.data;
                this.showDownLoadReportIconMct = this.downloadMctData.length === 0 ? false : true;
                let fpMap = new Map();
                fpMap = mctData.fpsInfo;
                this.fpInstanceInfoKeys = Object.keys(fpMap);
                this.fpInstanceInfo = fpMap;
                this.repeatedMethodData[0] = mctData.repeatMethodsData;
                this.asyncExitMap = mctData.asynCallMap;
                this.mctData.forEach((val, index) => {
                    if (index == 0) {
                        let node = this.mctData[index];
                        this.expandChildren(node);
                        this.count = 0;
                    }
                    fpMap = mctData.fpsInfo;
                });
                this.queueTime = mctData.totalQueueTime;
                this.selfTime = mctData.totalSelfTime;
                this.mctAppliedFilter = "(Max Depth=" + this.formatter(this.txtFlterMethodLevel) + ", Min Wall Time =" + this.formatter(this.txtFilterWallTime) + "ms, Threshold =" + this.formatter(this.txtThresholdWallTime) + "ms" + ", Elapsed Threshold=" + this.formatter(this.txtThresholdelapsedTime);
                if (this.isEnabledQAS) {
                    this.mctAppliedFilter += ", Total Thread Queue Time =" + this.formatter(this.queueTime) + "ms";
                    this.mctAppliedFilter += ", Total Self Time =" + this.formatter(this.selfTime) + "ms";
                }
                this.mctAppliedFilter += ")";
                this.loading = false;
            }
        }, (error) => {
            this.loading = false;
            this.loader = false;
            if (error.hasOwnProperty('message')) {
                this.showError('Method Call Tree taking time due to large data. Please increase timeout duration.');
            }
            else {
                if (error.hasOwnProperty('statusText')) {
                    this.showError(error);
                    console.error('Error loading:', error);
                }
            }
        });
        this.createFilterCriteria();
        this.toggleCallout = false;
        this.expandCollapseHint = "Show Callouts Expanded form";
    }
    /**
  *
  * @param error notification
  */
    showError(msg) {
        this.messageService.add({ severity: 'error', summary: 'Error Message', detail: msg });
    }
    /** Validating Number input */
    validateQty(event) {
        if (event.charCode > 31 && (event.charCode < 48 || event.charCode > 57))
            return false;
        else
            return true;
    }
    toggleNode(expandedForm) {
        this.mctData.forEach((val, index) => {
            val.expanded = expandedForm;
        });
        this.mctData = [...this.mctData];
    }
    addPackageClassmethodList() {
        let packageList = [];
        let classList = [];
        let methodList = [];
        for (let k = 0; k < this.uniqueMethodSignature.length; k++) {
            let tempArr = this.uniqueMethodSignature[k].split(".");
            let methodN = this.concatArrayToString(tempArr.splice(tempArr.length - 1, 1));
            let classN = this.concatArrayToString(tempArr.splice(tempArr.length - 1, 1));
            let packageN = this.concatArrayToString(tempArr);
            if (packageN != "" && packageN != "-" && packageList.findIndex(x => x.label == packageN) == -1)
                packageList.push({ "label": packageN, "value": packageN });
            if (classN != "" && classN != "-" && classList.findIndex(x => x.label == classN) == -1)
                classList.push({ "label": classN, "value": packageN + "_" + classN });
            if (methodN != "" && methodN != "-" && classList.findIndex(x => x.label == methodN) == -1)
                methodList.push({ "label": methodN, "value": packageN + "_" + classN + "_" + methodN });
        }
        this.packageList = packageList;
        this.actualPackageList = packageList;
        this.actualClassList = classList;
        this.actualMethodList = methodList;
        this.classList = classList;
        this.methodList = methodList;
    }
    getClassList() {
        let classList = [];
        for (let i = 0; i < this.selectedPackageList.length; i++) {
            let pkg = this.selectedPackageList[i];
            for (let j = 0; j < this.actualClassList.length; j++) {
                let value = this.actualClassList[j]['value'];
                if (value.indexOf(pkg) != -1) {
                    classList.push(this.actualClassList[j]);
                }
            }
        }
        let selectedActClss = [];
        for (let i = 0; i < classList.length; i++) {
            let classValue = classList[i]['value'];
            for (let j = 0; j < this.selectedClassList.length; j++) {
                if (classValue.indexOf(this.selectedClassList[j]) != -1)
                    selectedActClss.push(classValue);
            }
        }
        if (this.selectedPackageList.length == 0) {
            this.addPackageClassmethodList();
            this.selectedActClss = [];
            this.selectedClassList = [];
            this.selectedActMethod = [];
            this.selectedMethodList = [];
        }
        else {
            this.classList = [];
            this.classList = classList;
            this.selectedClassList = selectedActClss;
            this.getMethodList();
        }
    }
    getMethodList() {
        let methodList = [];
        let actualClass = [];
        for (let i = 0; i < this.selectedClassList.length; i++) {
            let cls = this.selectedClassList[i];
            let val = this.classList.find((obj) => { return obj.value == cls; });
            actualClass.push(val['label']);
            for (let j = 0; j < this.actualMethodList.length; j++) {
                let value = this.actualMethodList[j]['value'];
                if (value.indexOf(cls) != -1) {
                    methodList.push(this.actualMethodList[j]);
                }
            }
        }
        let selectedMethodList = [];
        for (let i = 0; i < methodList.length; i++) {
            let methodValue = methodList[i]['value'];
            for (let j = 0; j < this.selectedMethodList.length; j++) {
                if (methodValue.indexOf(this.selectedMethodList[j]) != -1)
                    selectedMethodList.push(methodValue);
            }
        }
        if (this.selectedClassList.length == 0) {
            this.methodList = Object.assign(this.actualMethodList);
            this.selectedActClss = [];
            this.selectedActMethod = [];
            this.selectedMethodList = [];
        }
        else {
            this.methodList = [];
            this.methodList = methodList;
            this.selectedMethodList = selectedMethodList;
            this.selectedActClss = actualClass;
        }
    }
    concatArrayToString(arr) {
        var str = "";
        for (var i = 0; i < arr.length; i++) {
            str = str + arr[i];
            if (arr.length - 1 != i)
                str = str + ".";
        }
        return str;
    }
    applyDefaultValue() {
        this.txtFilterWallTime = 0;
        this.txtFilterSelfTime = 0;
        this.txtFlterMethodLevel = 100;
        this.txtThresholdWallTime = 1500;
        this.txtThresholdelapsedTime = 1000;
        this.selectedPackageList = [];
        this.selectedActClss = [];
        this.selectedActMethod = [];
        this.selectedClassList = [];
        this.selectedMethodList = [];
        this.addPackageClassmethodList();
        this.txtExpandCount = 25;
        this.isExpandCount = false;
        this.selectedNegativeMethod = undefined;
        this.ignoreFilterCallOuts = ['T,E', 'D', 'J,j', 'e', 't', 'a,A'];
        this.enableMergeCase = false;
        this.isEnabledQAS = true;
    }
    getActualMethodList() {
        let actMethod = [];
        for (let i = 0; i < this.selectedMethodList.length; i++) {
            let val = this.selectedMethodList[i];
            actMethod.push(this.actualMethodList.find((Object) => { return Object['value'] == val; })['label']);
        }
        if (this.selectedMethodList.length == 0) {
            this.selectedActMethod = [];
        }
        else {
            this.selectedActMethod = [];
            this.selectedActMethod = actMethod;
        }
    }
    loadNodeUpto(event) {
        try {
            this.count1 = 0;
            if (event.node.expanded || (event.node.expanded == undefined && event.node.children && event.node.children.length > 0)) {
                setTimeout(() => { this.loading = true; }, 0);
                setTimeout(() => {
                    this.expandChildren1(event.node);
                    this.mctData = [...this.mctData];
                }, 100);
            }
        }
        catch (error) {
            console.error("Error in loadNodeUpto method: ", error);
        }
    }
    onNodeRightClick(event, contextMenu) {
        if (this.selectedNode.data.fqm == "-" || this.selectedNode.data.fqm == "") {
            this.menuIte = this.menuIteCallOut;
        }
        else {
            this.menuIte = this.menuIteMethod;
        }
    }
    showRepeatedData(node, index) {
        this.textAreaRepeatedMethod = ""; //for argument text clearing in text view or repeated method table.
        this.rowRepeatedMethodInfo = [];
        this.repeatedFQM = node.fqm;
        this.methodName = this._ddrData.decodeHTMLString(node.methodName);
        if (this.repeatedFQM != "-")
            this.substringFQM = node.fqm;
        else
            this.substringFQM = this.methodName;
        if (this.repeatedFQM != "-" && node.fqm.length > 100)
            this.substringFQM = node.fqm.substring(0, 100) + "...";
        else if (node.methodName.length > 100)
            this.substringFQM = node.methodName.substring(0, 100) + "...";
        let key = node.methodId + "_" + node.level + "_" + node.methodName + "_" + node.keyLine;
        let arr = this.repeatedMethodData[index][key];
        this.downloadRepeatMethod = JSON.parse(JSON.stringify(arr));
        this.createColsForRepeatedData();
        this.repeatedMethodsData = arr;
        this.popCount = this.repeatedMethodsData.length;
        this.repeatedMethodsDatapop = [];
        this.repeatedMethodsDatapop = this.repeatedMethodsData;
        this.rowRepeatedMethodInfo = this.repeatedMethodsDatapop[0]; // setting default case for selection in mct
        this.textAreaRepeatedMethod = this.rowRepeatedMethodInfo['methodArgument']; //default case first row selection with argumenst being shown of first row.
        this.showRepeatedDialogue = true;
    }
    createColsForRepeatedData() {
        var _a, _b, _c, _d;
        if (((_a = this.queryParams) === null || _a === void 0 ? void 0 : _a.instanceType) == 'php' && ((_b = this.queryParams) === null || _b === void 0 ? void 0 : _b.Instance_Type) == 'php' && this.commonService.currentRowData["Instance_Type"] == 'php') {
            this.relativePath = "ddr/method-calling-tree/repeated_methods/repeatedmethodphp.json";
        }
        else if (((_c = this.queryParams) === null || _c === void 0 ? void 0 : _c.instanceType) == 'Java' || ((_d = this.queryParams) === null || _d === void 0 ? void 0 : _d.Instance_Type) == 'Java' || this.commonService.currentRowData["Instance_Type"] == 'Java') {
            this.relativePath = "ddr/method-calling-tree/repeated_methods/repeatedmethodjava.json";
        }
        else {
            this.relativePath = "ddr/method-calling-tree/repeated_methods/repeatedmethod.json";
        }
    }
    expandChildren1(node) {
        if (node && node.data.repeatObj) {
            let repeatObj = node.data.repeatObj;
            this.updateMethodprop(repeatObj, node.data);
        }
        if (node && node.children) {
            if (node.children.length > 50) {
                this.childrenObj[node.data.lineNumber] = node.children;
                this.preNode[node.data.lineNumber] = node;
                this.expandSameLeveluptoFixLevel(node, 0, node.data.lineNumber, node.children.length);
            }
            else if (this.count1 < 20) {
                node.expanded = true;
                for (let cn of node.children) {
                    this.count1 += 1;
                    if (cn && cn.data.repeatObj) {
                        let repeatObj = cn.data.repeatObj;
                        this.updateMethodprop(repeatObj, cn.data);
                    }
                    if (cn.children != undefined && cn.children.length <= 50) {
                        this.expandChildren1(cn);
                    }
                    else if (cn.children != undefined) {
                        this.childrenObj[cn.data.lineNumber] = cn.children;
                        this.preNode[cn.data.lineNumber] = cn;
                        this.expandSameLeveluptoFixLevel(cn, 0, cn.data.lineNumber, cn.children.length);
                    }
                }
            }
        }
        setTimeout(() => { this.loading = false; }, 100);
    }
    sortRepeatMethod(event, tempData) {
        let fieldValue = event["field"];
        if (fieldValue == "timeStamp" || fieldValue == "cpuTime" || fieldValue == "threadId" || fieldValue == "percentage" || fieldValue == "selfTime" || fieldValue == "lineNumber") {
            if (event.order == -1) {
                event.order = 1;
                tempData = tempData.sort(function (a, b) {
                    var value = parseFloat(a[fieldValue]);
                    var value2 = parseFloat(b[fieldValue]);
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                event.order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    var value = parseFloat(a[fieldValue]);
                    var value2 = parseFloat(b[fieldValue]);
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        else {
            if (event.order == -1) {
                var temp = event["field"];
                event.order = 1;
                tempData = tempData.sort(function (a, b) {
                    if (a[temp].startsWith('<') && b[temp].startsWith('<')) {
                        return 0;
                    }
                    else if (a[temp].startsWith('<')) {
                        return 1;
                    }
                    else if (b[temp].startsWith('<')) {
                        return -1;
                    }
                    var value = Number(a[temp].replace(/,/g, ''));
                    var value2 = Number(b[temp].replace(/,/g, ''));
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = event["field"];
                event.order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    if (a[temp].startsWith('<') && b[temp].startsWith('<')) {
                        return 0;
                    }
                    else if (a[temp].startsWith('<')) {
                        return -1;
                    }
                    else if (b[temp].startsWith('<')) {
                        return 1;
                    }
                    var value = Number(a[temp].replace(/,/g, ''));
                    var value2 = Number(b[temp].replace(/,/g, ''));
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        this.repeatedMethodsDatapop = [];
        if (tempData) {
            tempData.map((rowdata) => { this.repeatedMethodsDatapop = this.Immutablepush(this.repeatedMethodsDatapop, rowdata); });
        }
    }
    showHideColumnForRepeatedData() {
        if (this.vCForRepeatedmethod.length !== 0) {
            for (let i = 0; i < this.colsForRepeatedData.length; i++) {
                for (let j = 0; j < this.vCForRepeatedmethod.length; j++) {
                    if (this.colsForRepeatedData[i].field === this.vCForRepeatedmethod[j]) {
                        this.colsForRepeatedData[i].action = true;
                        break;
                    }
                    else {
                        this.colsForRepeatedData[i].action = false;
                    }
                }
            }
        }
        else {
            for (let i = 0; i < this.colsForRepeatedData.length; i++) {
                this.colsForRepeatedData[i].action = false;
            }
        }
    }
    expandSetter() {
        if (!this.isExpandCount) {
            this.txtExpandCount = 25;
        }
    }
    callHideFunction(index) {
        this.childMCTPositionTop = this.childMCTPositionTop - 150;
        let values = [];
        for (let i = 0; i < this.values.length; i++) {
            if (index != i)
                values.push(this.values[i]);
        }
        this.visibleArr[index] = false;
        this.values = values;
    }
    decodeHTMLString(str) {
        return this._ddrData.decodeHTMLString(str);
    }
    isFullyQualifiedClassName(className) {
        const fqcnPattern = /^[a-zA-Z_][a-zA-Z0-9_]*(\.[a-zA-Z_][a-zA-Z0-9_]*)*\.[A-Z][a-zA-Z0-9_$]*$/;
        return fqcnPattern.test(className);
    }
    /*This method is used to open method calling tree with callouts in expanded form*/
    openExpandedCallouts() {
        let endTimetoPass;
        const startTimetoPass = Number(this.trStartTime) - 900000;
        if (this.trEndTime == '' || this.trEndTime == null || this.trEndTime == undefined || isNaN(this.trEndTime)) {
            var strEndTime = Number(this.trStartTime) + Number(this.fpDuration);
            endTimetoPass = Number(strEndTime) + 900000;
        }
        else {
            endTimetoPass = Number(this.trEndTime) + 900000;
        }
        this._ddrData.dlStartTime = startTimetoPass;
        this._ddrData.dlEndTime = endTimetoPass;
        let lineNumber = 0;
        if (this.selectedNode) {
            lineNumber = this.selectedNode['data']['lineNumber'];
        }
        let methodCount = 50000;
        if (this.queryParams.methodsCount)
            methodCount = Number(this.queryParams.methodsCount.toString().replace(/,/g, ""));
        const queryParams = `filterGreaterThan=${this.txtFilterWallTime}&filterSelfTime=${this.txtFilterSelfTime}&filterTop=${this.txtFlterMethodLevel}&packageList=&classList=&methodList=&testRun=${this.id.testRun}&flowPathInstance=${this.queryParams.flowpathInstance}&strStartTime=${startTimetoPass}&strEndTime=${Number(endTimetoPass) + 1000}&entryResponseTime=${this.fpDuration}&thresholdWallTime=${this.txtThresholdWallTime}&FromAngular=1&enableMergeCase=${this.enableMergeCase}&ignoreFilterCallouts=${this.ignoreFilterCallOuts}&methodCount=${methodCount}&filterMethods=${this.filterMethods}&thresholdDiffElapsedTime=${this.txtThresholdelapsedTime}&lineNumber=${lineNumber}`;
        this.loading = false;
        this.ddrHttpService.getMCTData(queryParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_13__["MethodCallDetailsLoadedState"]) {
                let data = state.data;
                this.loading = false;
                this.mctData = data.treedata.data;
                this.downloadMctData = data.data;
                this.repeatedMethodData[0] = data.repeatMethodsData;
                this.addPackageClassmethodList();
                let fpMap = new Map();
                fpMap = data.fpsInfo;
                this.queueTime = data.totalQueueTime;
                this.selfTime = data.totalSelfTime;
                this.mctAppliedFilter = "(Max Depth=" + this.formatter(this.txtFlterMethodLevel) + ", Min Wall Time =" + this.formatter(this.txtFilterWallTime) + "ms, Threshold =" + this.formatter(this.txtThresholdWallTime) + "ms" + ", Elapsed Threshold=" + this.formatter(this.txtThresholdelapsedTime);
                if (this.isEnabledQAS) {
                    this.mctAppliedFilter += " ,Total Thread Queue Time=" + this.formatter(this.queueTime) + "ms";
                    this.mctAppliedFilter += " ,Total Self Time=" + this.formatter(this.selfTime) + "ms";
                }
                this.mctAppliedFilter += ")";
                this.fpInstanceInfoKeys = Object.keys(fpMap);
                this.fpInstanceInfo = fpMap;
                this.asyncExitMap = data.asynCallMap;
                if (this.downloadMctData.length == 0)
                    this.showDownLoadReportIconMct = false;
                else
                    this.showDownLoadReportIconMct = true;
                this.mctData.forEach((val, index) => {
                    if (index == 0) {
                        let node = this.mctData[index];
                        this.expandChildren(node);
                        this.count = 0;
                    }
                });
                this.mctData = [...this.mctData];
                this.loader2 = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.loading = false;
            this.loader2 = false;
        });
    }
    toggleExpandedCallout() {
        this.loader2 = true;
        if (!this.toggleCallout) //false
         {
            this.toggleCallout = true;
            this.expandCollapseHint = "Show Callouts Collapsed form";
            this.txtExpandCount = this._ddrData.enableCalloutExpandCount;
            this.openExpandedCallouts();
        }
        else { //true 
            this.toggleCallout = false;
            this.expandCollapseHint = "Show Callouts Expanded form";
            this.txtExpandCount = 25;
            this.getMCTDataFunc();
        }
    }
    // This function recursively searches for a node in a tree structure based on specific criteria.
    findNodeWithIndexByAsyncToBeMatchedId(node, targetId, method) {
        // Check if the current node matches the criteria
        if (node.data && node.data.asyncToBeMatchedId === targetId && node.data.methodName.trim() !== method.trim()) {
            return node;
        }
        // If the current node doesn't match, check its children (if any)
        if (node.children && Array.isArray(node.children)) {
            node.expanded = true;
            for (const child of node.children) {
                this.countIndex++; // Increment index for each child node processed
                const result = this.findNodeWithIndexByAsyncToBeMatchedId(child, targetId, method);
                if (result) {
                    return result; // If a matching node is found in the child nodes, return it
                }
            }
        }
        return null; // Return null if no matching node is found in the current node and its children
    }
    // This function scrolls to the next matching node.
    scrollnextTO(node) {
        try {
            this.countIndex = 0;
            for (let i = 0; i < this.mctData.length; i++) {
                const result = this.findNodeWithIndexByAsyncToBeMatchedId(this.mctData[i], node.asyncToBeMatchedId, node.methodName);
                if (result) {
                    this.treeRef.scrollToVirtualIndex(this.countIndex); // Scroll to the found node
                    this.selectedNode = null;
                    setTimeout(() => {
                        this.selectedNode = result;
                    }, 100);
                    return true; // Return true if a matching node is found and scrolled to
                }
            }
        }
        catch (e) {
            console.error("Exception in scrollnextTO method", e);
            return false;
        }
        return false;
    }
    getAsyncExit(node) {
        let alreadyExpanded = this.scrollnextTO(node);
        if (!alreadyExpanded) {
            let toMatchSqNo = node.asyncToBeMatchedId;
            let lineNoAsync = this.asyncExitMap[toMatchSqNo];
            this.getParentSeqNo(node, node, lineNoAsync);
        }
    }
    getParentSeqNo(firstNode, node, lineNumber) {
        let parentInfo = node.parent;
        if (!parentInfo) {
            this.mctData.forEach((val, index) => {
                let nodeIndex = this.mctData[index];
                if (nodeIndex.data.lineNumber > node.data.lineNumber && nodeIndex.children) {
                    node = nodeIndex;
                    node.expanded = true;
                }
            });
        }
        else
            node = node.parent;
        if (node.data.lineNumber < lineNumber) {
            let index1 = 0;
            let childrenArr = node.children;
            for (let i = 0; i < childrenArr.length; i++) {
                let val = childrenArr[i];
                if (Number(val.data.lineNumber) >= Number(lineNumber)) {
                    index1 = i;
                    break;
                }
            }
            if (index1 == 0)
                this.getParentSeqNo(firstNode, node, lineNumber);
            else if (childrenArr[index1].data.lineNumber == lineNumber) {
                this.scrollnextTO(firstNode);
            }
            else if (childrenArr[index1].data.lineNumber < lineNumber && childrenArr[index1 + 1].data.lineNumber) {
                this.expandChildren(childrenArr[index1]);
            }
        }
    }
    resizingColumns($event) {
        let headerName = $event.element.innerText.trim();
        this.colsForMCT.forEach((val, index) => {
            if (headerName == val.header) {
                val.width = Number(val.width.replace("px", '')) + $event.delta;
                val.width = val.width + "px";
            }
            else {
                let width = 0;
                if ($event.delta < 0)
                    width = Number(val.width.replace("px", '')) + 20;
                else
                    width = Number(val.width.replace("px", '')) - 20;
                if (width > 10)
                    val.width = width + "px";
            }
        });
        this.colsForMCT = [...this.colsForMCT];
    }
    rowSelection(data) {
        this.textAreaRepeatedMethod = data.methodArgument;
    }
};
MethodcallingtreeComponent.ctorParameters = () => [
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__["SessionService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_12__["NdDdrHttpService"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_2__["MessageService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], MethodcallingtreeComponent.prototype, "columnData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('value')
], MethodcallingtreeComponent.prototype, "compareFPInfo", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('treeRef')
], MethodcallingtreeComponent.prototype, "treeRef", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('preContent')
], MethodcallingtreeComponent.prototype, "preContent", void 0);
MethodcallingtreeComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'methodcallingtree',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./methodcallingtree.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./methodcallingtree.component.scss */ "./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.scss")).default]
    }),
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"])({
        providedIn: 'root',
    })
], MethodcallingtreeComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/methodtiming/methodtiming.component.scss":
/*!*******************************************************************************!*\
  !*** ./src/app/pages/ddr/components/methodtiming/methodtiming.component.scss ***!
  \*******************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("chart {\n  display: block;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/methodtiming/methodtiming.component.ts":
/*!*****************************************************************************!*\
  !*** ./src/app/pages/ddr/components/methodtiming/methodtiming.component.ts ***!
  \*****************************************************************************/
/*! exports provided: MethodtimingComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MethodtimingComponent", function() { return MethodtimingComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_9__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");
















let MethodtimingComponent = class MethodtimingComponent {
    constructor(commonService, _router, _cavConfigService, breadcrumbService, _ddrData, messageService, ddrRequest, sessionService, breadcrumb, ndDdrHttpService, elasticSearchService) {
        this.commonService = commonService;
        this._router = _router;
        this._cavConfigService = _cavConfigService;
        this.breadcrumbService = breadcrumbService;
        this._ddrData = _ddrData;
        this.messageService = messageService;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.elasticSearchService = elasticSearchService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_9__; // Variable is used for refrence of highcharts library
        this.methodTimingData = []; // MethodTiming table data 
        this.filterCriteria = ""; // Initialize filter criteria
        this.filterCriteriaArray = []; // Array to hold individual filter criteria
        this.showChart = true; // flag to show/hide chart
        this.pointName = "";
        this.dataCount = 0; //total json length to show in acording tab as total
        this.entityName = ""; //entity name [method/class/package name]
        this.nTopMethod = ""; //apply top n methods popup
        this.filterType = "Method(s)"; //to set in dialog as top methods/classes/packages
        this.headerStats = "Method(s) Stat"; // value represents the header for statistics related to methods/classes/packages
        this.showCountPieChart = false; // flag for piechart
        this.loader = false; // Variable is used for ajax loader
        this.isAgent = true; // flag to show DDAI icon or not
        this.value = 1;
        this.customFlag = false; // Flag indicating a custom condition
        this.isFilterFromSideBar = false; // Set filter flag from sidebar
        this.filterTierName = ''; // Variable is used for filtering tier name
        this.filterServerName = ''; // Variable is used for filtering server name 
        this.filterInstanceName = ''; // Variable is used for filtering instance name 
        this.completeTier = ''; // Variable is used for Complete tier information
        this.completeServer = ''; // Variable is used for Complete server information
        this.completeInstance = ''; // Variable is used for Complete instance information
        this.showAutoInstrPopUp = false; // flag to show auto instrumentation pop up
        this.displayAutoInst = false; // flag to check auto instantiation is displayed or not
        this.ignoreFlag = false; // flag to check certain conditions should be ignored
        this.valuechbx = false; // flag to represent the value of a checkbox
        this.isApplied = false; // Flag to indicate whether an action has been applied
        this.showPagination = false; // Flag to show/hide pagination
        this.breadcrumb = breadcrumb;
        this.otelMode = this._ddrData.otelMode;
    }
    ngOnChanges() {
        var _a;
        if (this._ddrData.splitViewBreadCrumbFlag && this._ddrData.splitViewFlag) {
            this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            this.breadcrumb.add({ label: 'Method Timing' });
        }
        else {
            if (this.commonService.openfptoAggMT == true) {
                this.breadcrumb.add({ label: 'Aggregate Method Timing', routerLink: '/ddr/methodtiming' });
                this._ddrData.splitViewBreadCrumbFlag = false;
            }
            else {
                this.breadcrumb.add({ label: this.columnData.flowpathInstance });
                this.breadcrumb.add({ label: 'Method Timing' });
                this._ddrData.splitViewBreadCrumbFlag = true;
            }
        }
        this._ddrData.setInLogger("DDR:Flowpath", "Method Timing", "Open Method Timing Report");
        if (this.columnData != undefined) {
            this.id = this.commonService.getData();
            this.queryParams = JSON.parse(JSON.stringify(this.columnData));
            this.flowpathInstance = this.columnData.flowpathInstance;
            this.screenHeight = Number(this.commonService.screenHeight) - 235;
            this.commonService.mtData = JSON.parse(JSON.stringify(this.columnData));
            this.id.mtFlag = 'true';
            this.commonService.mtData.strStartTime = this.commonService.mtData.startTimeInMs;
            if (!this.otelMode) {
                if ((_a = this.commonService.mtData.fpDuration) === null || _a === void 0 ? void 0 : _a.toString().includes(','))
                    this.commonService.mtData.strEndTime = Number(this.commonService.mtData.startTimeInMs) + Number(this.commonService.mtData.fpDuration.toString().replace(/,/g, ""));
                else if (this.commonService.mtData.fpDuration == '< 1') {
                    this.commonService.mtData.strEndTime = Number(this.commonService.mtData.startTimeInMs) + Number(0);
                }
                else
                    this.commonService.mtData.strEndTime = Number(this.commonService.mtData.startTimeInMs) + Number(this.commonService.mtData.fpDuration);
            }
            else {
                this.commonService.mtData.strEndTime = this.commonService.mtData.startTimeInMs + Math.ceil(this.commonService.mtData.selfResponseTime);
            }
            if (this.commonService.mtData.btCatagory === 'Very Slow') {
                this.commonService.mtData.btCatagory = '12';
            }
            if (this.commonService.mtData.btCatagory === 'Slow') {
                this.commonService.mtData.btCatagory = '11';
            }
            if (this.commonService.mtData.btCatagory === 'Normal') {
                this.commonService.mtData.btCatagory = '10';
            }
            if (this.commonService.mtData.btCatagory === 'Errors') {
                this.commonService.mtData.btCatagory = '13';
            }
            this.getMethodTimigData('method', '0');
        }
        if (this.queryParams.instanceType == 'Java' || this.queryParams.instanceType == 'DotNet' || this.queryParams.instanceType == 'DotNetC' || this.queryParams.Instance_Type == 'Java' || this.queryParams.Instance_Type == 'DotNet' || this.queryParams.Instance_Type == 'DotNetC') {
            this.isAgent = true;
        }
        else {
            this.isAgent = false;
        }
    }
    ngOnInit() {
        this.commonService.currentReport = "Method Timing";
        if (this._ddrData.tagData) {
            this.tagInfo = this._ddrData.createGtagsIntoStr(this._ddrData.tagData);
        }
        if (this._ddrData.splitViewFlag == false) {
            this.commonService.isToLoadSideBar = true;
            this.screenHeight = Number(this.commonService.screenHeight) - 135;
            this.breadcrumb.add({ label: 'Method Timing', routerLink: '/ddr/methodtiming' });
        }
        this.sideBarMethodTiming = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Method Timing") {
                this.commonService.isFilterFromSideBar = true;
                let keys = Object.keys(temp);
                this.getMethodTimigData('method', '0'); //By defult method tab will open
            }
        });
        try {
            if (this._ddrData.splitViewFlag == false) {
                this.id = this.commonService.getData();
            }
            if (this.id.enableQueryCaching) {
                this.commonService.enableQueryCaching = this.id.enableQueryCaching;
            }
            if (this.commonService.testRun != undefined && this.commonService.testRun != null && this.commonService.testRun != '') {
                this.id.testrun = this.commonService.testRun;
            }
            this.fillData();
            this.trStartTime = this.id.startTime;
            this.trEndTime = this.id.endTime;
        }
        catch (error) {
            console.error("Getting some error ~ ", error);
        }
        if (this.queryParams) {
            if (this.queryParams.instanceType == 'Java' || this.queryParams.instanceType == 'DotNet' || this.queryParams.instanceType == 'DotNetC' || this.queryParams.Instance_Type == 'Java' || this.queryParams.Instance_Type == 'DotNet' || this.queryParams.Instance_Type == 'DotNetC') {
                this.isAgent = true;
            }
            else {
                this.isAgent = false;
            }
        }
        highcharts__WEBPACK_IMPORTED_MODULE_9__["setOptions"]({
            lang: {
                thousandsSep: ','
            }
        });
    }
    fillData() {
        if (this._ddrData.splitViewFlag == false) {
            this.getMethodTimigData('method', '0'); //By defult method tab will open
        }
    }
    /*When user click on method/class/package icon table and pie chart data will change*/
    changeData(type, entity) {
        this.urlPramObj['entity'] = entity;
        this.urlPramObj['type'] = type;
        this.getMethodTimigData(type, entity);
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName;
        if (this._ddrData.isFromtrxFlow) {
            hostDcName = "//" + this._ddrData.hostTr + ":" + this._ddrData.portTr;
            this.id.testRun = this._ddrData.testRunTr;
        }
        else if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            if (hostDcName.lastIndexOf('ALL/') !== -1)
                hostDcName = hostDcName.substring(0, hostDcName.lastIndexOf('/'));
            this.id.testRun = this._ddrData.testRun;
            this.testRun = this._ddrData.testRun;
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        return hostDcName;
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "showalldata") {
            me.showAllData();
        }
        if (((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.actionConfig) === null || _d === void 0 ? void 0 : _d.action) === "clickable") {
            me.openServiceMethodTiming((_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.row);
        }
    }
    getProgressBar() {
        let interval = setInterval(() => {
            this.value = this.value + Math.floor(Math.random() * 10) + 1;
            if (this.value >= 100) {
                this.value = 100;
                clearInterval(interval);
            }
        }, 300);
    }
    /**Rest call to get data for method timing */
    getMethodTimigData(type, entity) {
        let url = '';
        if (this.commonService.enableQueryCaching == 1)
            url += 'cacheId=' + this.id.testRun + '&testRun=' + this.id.testRun;
        else
            url += 'testRun=' + this.id.testRun;
        let urlParam = "";
        let flag = '&customFlag=' + this.customFlag;
        try {
            let fromFlowpath = false;
            let flowpathInstance = "NA";
            let tierName = "NA";
            let traceId = "NA";
            let serverName = "NA";
            let appName = "NA";
            let tierId = "NA";
            let serverId = "NA";
            let appId = "NA";
            let urlName = "NA";
            let urlIndex = "NA";
            let strStartTime = "NA";
            let strEndTime = "NA";
            let btCatagory = "NA";
            let signature = 'NA';
            let urlQueryParamStr = 'NA';
            if (this.commonService.isFilterFromSideBar && Object.keys(this.commonService.methodTimingFilters).length != 0) {
                let mtParam = this.commonService.methodTimingFilters;
                if (this.commonService.isValidParamInObj(mtParam, 'pubicIP') && this.commonService.isValidParamInObj(mtParam, 'publicPort') && this.commonService.isValidParamInObj(mtParam, 'ndeTestRun')) {
                    if (this.commonService.enableQueryCaching == 1)
                        url = 'cacheId=' + mtParam['ndeTestRun'] + '&testRun=' + mtParam['ndeTestRun'];
                    else
                        url = 'testRun=' + mtParam['ndeTestRun'];
                }
                this.nTopMethod = mtParam.topNEntities;
                let ajaxurl = this.commonService.makeParamStringFromObj(mtParam, true);
                urlParam = ajaxurl;
                this.urlPramObj = this.commonService.makeObjectFromUrlParam(urlParam);
            }
            else {
                if (this.id.mtFlag == 'true' || this.commonService.mtFlag == true || this.commonService.openfptoAggMT == true) {
                    this.fptomtFilter = true;
                    if (this.commonService.mtData.flowpathInstance !== undefined) {
                        flowpathInstance = this.commonService.mtData.flowpathInstance;
                    }
                    if (this.commonService.mtData.TraceId !== undefined) {
                        traceId = this.commonService.mtData.TraceId;
                    }
                    if (this.commonService.mtData.tierName !== undefined) {
                        tierName = this.commonService.mtData.tierName;
                    }
                    if (this.commonService.mtData.serverName !== undefined) {
                        serverName = this.commonService.mtData.serverName;
                    }
                    if (this.commonService.mtData.appName !== undefined) {
                        appName = this.commonService.mtData.appName;
                    }
                    if (this.commonService.mtData.tierId !== undefined) {
                        tierId = this.commonService.mtData.tierId;
                    }
                    if (this.commonService.mtData.serverId !== undefined) {
                        serverId = this.commonService.mtData.serverId;
                    }
                    if (this.commonService.mtData.appId !== undefined) {
                        appId = this.commonService.mtData.appId;
                    }
                    if (this.commonService.mtData.btCatagory !== undefined) {
                        btCatagory = this.getBTCategoryID(this.commonService.mtData.btCatagory);
                    }
                    if (this.commonService.mtData.urlIndex !== undefined) {
                        urlIndex = this.commonService.mtData.urlIndex;
                    }
                    if (this.commonService.mtData.urlName !== undefined) {
                        urlName = this.commonService.mtData.urlName;
                    }
                    if (this.commonService.mtData.urlQueryParamStr !== undefined) {
                        urlQueryParamStr = this.commonService.mtData.urlQueryParamStr;
                    }
                    if (this.commonService.mtData.strStartTime !== undefined) {
                        this.trStartTime = this.commonService.mtData.strStartTime;
                    }
                    if (this.commonService.mtData.strEndTime !== undefined) {
                        this.trEndTime = this.commonService.mtData.strEndTime;
                    }
                    if (this.commonService.mtData.StartTimeDF) {
                        this.startTimeinDF = this.commonService.mtData.StartTimeDF;
                    }
                    if (this.commonService.mtData.Duration) {
                        this.Duration = this.commonService.mtData.Duration;
                    }
                    if (this.commonService.mtData.serviceName) {
                        this.serviceName = this.commonService.mtData.serviceName;
                    }
                }
                else if (this.commonService.signatureTomt === true) {
                    if (this.commonService.mtData.flowpathSignature !== undefined) {
                        signature = this.commonService.mtData.flowpathSignature;
                    }
                    if (this.commonService.mtData.strStartTime !== undefined) {
                        this.trStartTime = this.commonService.mtData.strStartTime;
                    }
                    if (this.commonService.mtData.strEndTime !== undefined) {
                        this.trEndTime = this.commonService.mtData.strEndTime;
                    }
                }
                else {
                    this.fptomtFilter = false;
                    tierName = this.id.tierName;
                    serverName = this.id.serverName;
                    appName = this.id.appName;
                    urlName = this.id.urlName;
                    urlIndex = this.id.urlIndex;
                    btCatagory = this.id.btCatagory;
                    this.trStartTime = this.id.startTime;
                    this.trEndTime = this.id.endTime;
                }
                if (this.commonService.flowpathInstance != undefined && this.commonService.flowpathInstance != 'NA' && this.commonService.flowpathInstance != 'undefined') {
                    this.commonService.flowpathInstance = flowpathInstance;
                }
                else
                    this.commonService.flowpathInstance = "";
                let nsUrlIdx = "NA";
                let script = "NA";
                let page = "NA";
                let transtx = "NA";
                if (this.id.flowpathInstance != null && this.id.flowpathInstance != undefined && this.id.flowpathInstance != 'NA' && this.id.flowpathInstance != '')
                    flowpathInstance = this.id.flowpathInstance;
                if (this.id.nsUrlIndex != null && this.id.nsUrlIndex != undefined && this.id.nsUrlIndex != 'NA' && this.id.nsUrlIndex != '')
                    nsUrlIdx = this.id.nsUrlIndex;
                if (this.id.script != null && this.id.script != undefined && this.id.script != 'NA' && this.id.script != '')
                    script = this.id.script;
                if (this.id.transtx != null && this.id.transtx != undefined && this.id.transtx != "NA" && this.id.transtx != '')
                    transtx = this.id.transtx;
                if (this.id.pageName != null && this.id.pageName != undefined && this.id.pageName != "NA" && this.id.pageName != '')
                    page = this.id.pageName;
                if (this.id.completeURL != null && this.id.completeURL != undefined && this.id.completeURL != "NA" && this.id.completeURL != '')
                    urlQueryParamStr = this.id.completeURL;
                urlParam =
                    '&tierName=' + tierName +
                        '&serverName=' + serverName +
                        '&appName=' + appName +
                        '&tierId=' + tierId +
                        '&serverId=' + serverId +
                        '&appId=' + appId +
                        '&urlName=' + urlName +
                        '&urlIndex=' + urlIndex +
                        '&flowpathInstance=' + flowpathInstance +
                        '&btCatagory=' + btCatagory +
                        '&strStartTime=' + this.trStartTime +
                        '&strEndTime=' + (Number(this.trEndTime) + 1000) +
                        '&nsUrlIdx=' + nsUrlIdx +
                        '&page=' + page +
                        '&transaction=' + transtx +
                        '&Duration=' + this.Duration +
                        '&startTimeinDF=' + this.startTimeinDF +
                        '&script=' + script;
                if (this.commonService.signatureTomt === true) {
                    urlParam += '&fpSignature=' + signature;
                }
                //making ajaxurlparam to set all parameters into commonservice
                this.urlPramObj = this.commonService.makeObjectFromUrlParam(urlParam);
                if (this.tagInfo && this.tagInfo.length != 0) {
                    urlParam += "&tags=" + this.tagInfo;
                }
                if (this.commonService.isFromSplitView && this.otelMode) {
                    urlParam += `&traceId=${traceId}&serviceName=${this.serviceName}`;
                }
            }
            urlParam += '&type=' + type + '&entity=' + entity;
            url += urlParam + flag;
            if (this.valuechbx && this.isApplied) {
                url += '&min_methods=2';
            }
            this.urlPramObj = this.commonService.makeObjectFromUrlParam(urlParam);
            this.urlPramObj['tags'] = this.tagInfo;
            this.commonService.methodTimingFilters = this.urlPramObj;
            //toggle for otelMode
            if (!this.otelMode) {
                this.fetchDataFromPsql(url, type);
            }
            if (this.otelMode) {
                this.fetchDataFromElasticSearch(url);
            }
        }
        catch (error) {
            console.error('Error in getting data for method timing', error);
        }
    }
    fetchDataFromPsql(url, type) {
        this.ndDdrHttpService.getMethodTimingReportData(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["MethodTimingLoadedState"]) {
                this.assignMethodTimingData(state.data, type);
                this.loader = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.commonService.showError(error);
            this.loader = false;
        });
    }
    /**
     * Fetches data from Elasticsearch using the specified query parameters.
     *
     * @param url The query parameters to use when constructing the query.
     */
    fetchDataFromElasticSearch(url) {
        let reqPayload = {};
        if (this.elasticSearchService.isFromOtelTrxnServiceMap) {
            this.elasticSearchService.isFromOtelTrxnServiceMap = false;
            reqPayload = this.elasticSearchService.getTrxServiceMapPayload();
        }
        else {
            reqPayload = this.ndDdrHttpService.createPayloadForPOSTCall(url);
        }
        if (window['logLevel'] > 1) {
            console.log("********reqPayload******", reqPayload);
        }
        const resFields = [
            "trace_id",
            "span_id",
            "@timestamp",
            "duration",
            "attributes.cav.*",
            "attributes.code.*",
        ];
        const elasticQuery = this.elasticSearchService.buildElasticSearchQuery(reqPayload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].METHOD_TIMING);
        if (window['logLevel'] > 1) {
            console.log("********elasticQuery******", elasticQuery);
        }
        this.relativePath = 'ddr/method-timing/method-timing-method-elastic.json';
        this.elasticSearchService.search(elasticQuery).subscribe(res => {
            this.elasticSearchData = res;
            if (window['logLevel'] > 1) {
                console.log('Search results from Elasticsearch:', res);
            }
            this.filterType = "Method(s)";
            this.headerStats = "Method(s) Stat";
            this.processElasticData(this.elasticSearchData);
        }, error => {
            console.error('Error in getting data from Elasticsearch:', error);
            this.methodTimingData = [];
            this.dataCount = 0;
            this.loader = false;
        });
    }
    /**
    * Processes the data returned from Elasticsearch
    * and assigns it to the local variables.
    *
    * @param elasticData The response from Elasticsearch
    */
    processElasticData(elasticData) {
        if (elasticData && elasticData.hits && elasticData.hits.total && elasticData.aggregations.statements.buckets) {
            // Assign the aggregations data
            this.elasticMethodTimingAggData = elasticData.aggregations.statements.buckets;
            this.totalElasticRecords = Number(elasticData.hits.total.value);
            //compute the total sum of all method durations
            const totalSumInMs = this.elasticMethodTimingAggData.reduce((acc, record) => {
                const sum = Number(record.duration_stats["sum"]) / 1000000;
                return acc + (isNaN(sum) ? 0 : sum);
            }, 0);
            this.methodTimingDataArray = this.elasticMethodTimingAggData.map((record) => {
                // Creating new MethodTimingData object and assign properties for every record from elastic search
                let durationStats = record.duration_stats;
                // Calculate the duration in milliseconds
                const avgInMs = Number(durationStats["avg"]) / 1000000;
                const minInMs = Number(durationStats["min"]) / 1000000;
                const maxInMs = Number(durationStats["max"]) / 1000000;
                const sumInMs = Number(durationStats["sum"]) / 1000000;
                // Calculate percentage contribution
                const percentage = totalSumInMs > 0 ? (sumInMs / totalSumInMs) * 100 : 0;
                const mN = record.key[0]; // method name
                const cN = record.key[1].substring(record.key[1].lastIndexOf('.') + 1); // class name
                const pN = record.key[1].substring(0, record.key[1].lastIndexOf('.')); // package name
                const eC = record.doc_count; // total method count
                const avgST = isNaN(avgInMs) ? "" : avgInMs;
                const percentageFormatted = isNaN(percentage) ? "" : percentage.toFixed(2);
                return {
                    mN: mN,
                    cN: cN,
                    pN: pN,
                    eC: eC,
                    avgST: avgST,
                    percent: percentageFormatted
                };
            });
            this.filterCriteria = this.elasticSearchService.filtercriteria;
            // Split by comma, trim spaces, and filter out empty values
            this.filterCriteriaArray = this.filterCriteria
                .split(',')
                .map(item => item.trim())
                .filter(item => item.length > 0);
            if (window['logLevel'] > 1) {
                console.log("**MethodTimingDataArray**", this.methodTimingDataArray);
            }
            this.methodTimingData = this.methodTimingDataArray;
            this.dataCount = this.methodTimingData.length;
            this.createPieChart(this.methodTimingData, 'method');
            this.createCountPieChart(this.methodTimingData, 'method');
        }
    }
    getBTCategoryID(category) {
        if (category === 'Very Slow') {
            category = '12';
        }
        if (category === 'Slow') {
            category = '11';
        }
        if (category === 'Normal') {
            category = '10';
        }
        if (category === 'Errors') {
            category = '13';
        }
        if (category === 'Other') {
            category = '0';
        }
        return category;
    }
    /**Used to open service method timing from Method timing */
    openServiceMethodTiming(rowData) {
        let mtParam = this.commonService.methodTimingFilters;
        let reqData = {};
        if (this.commonService.mtFlag == true) {
            if (rowData != undefined)
                reqData["methodid"] = rowData.ID;
            reqData["fpInstance"] = this.commonService.mtData.flowpathInstance;
            reqData["urlIndex"] = this.commonService.mtData.urlIndex;
            reqData["tierId"] = mtParam['tierId'];
            reqData["serverId"] = mtParam['serverId'];
            reqData["appId"] = mtParam['appId'];
            reqData['tierName'] = mtParam['tierName'];
            reqData['serverName'] = mtParam['serverName'];
            reqData['appName'] = mtParam['appName'];
            reqData["strStartTime"] = this.commonService.mtData.strStartTime;
            reqData["strEndTime"] = this.commonService.mtData.strEndTime;
            reqData["startTimeinDF"] = mtParam['startTimeinDF'];
            reqData["Duration"] = mtParam['Duration'];
        }
        else {
            if (rowData != undefined)
                reqData["methodid"] = rowData.ID;
            reqData["tierId"] = mtParam['tierId'];
            reqData["serverId"] = mtParam['serverId'];
            reqData["appId"] = mtParam['appId'];
            reqData['tierName'] = mtParam['tierName'];
            reqData['serverName'] = mtParam['serverName'];
            reqData['appName'] = mtParam['appName'];
        }
        reqData['urlName'] = mtParam['urlName'];
        reqData['strStartTime'] = mtParam['strStartTime'];
        reqData['strEndTime'] = mtParam['strEndTime'];
        reqData['flowpathInstance'] = this.flowpathInstance;
        this.commonService.dataForServiceMethod = reqData;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].METHOD_TIMING;
        if (this._router.url.indexOf("/home/ddrCopyLink") != -1)
            this._router.navigate(['/home/ddrCopyLink/servicemethodtiming']);
        else
            this._router.navigate(['/ddr/servicemethodtiming']);
    }
    /**Assign the rest call response data to global variable */
    assignMethodTimingData(res, type) {
        this.commonService.isFilterFromSideBar = false;
        try {
            if (res === null || res === undefined) {
                return;
            }
            if (res.hasOwnProperty('Status')) {
                if (res.Status !== "" && res.Status !== "NA" && res.Status !== 'undefined' && res.Status !== undefined) {
                    this.commonService.showError(res.Status);
                }
            }
            setTimeout(() => {
                this.loader = false;
            }, 2000);
            let startTimeFormat = this.sessionService.convertTimestampIntoFormattedString(Number(res.strStartTime), "MM/DD/YYYY HH:mm:ss");
            let endTimeFormat = this.sessionService.convertTimestampIntoFormattedString(Number(res.strEndTime), "MM/DD/YYYY HH:mm:ss");
            this.commonService.methodTimingFilters['startTimeInDateFormat'] = startTimeFormat;
            this.commonService.methodTimingFilters['endTimeInDateFormat'] = endTimeFormat;
            this.showFilterCriteria(startTimeFormat, endTimeFormat);
            this.methodTimingData = res.data;
            if (this.methodTimingData.length != 0) {
                this.methodTimingData.forEach((val, index) => {
                    if (val['pN'] === undefined || val['pN'] === '' || val['pN'] === '0' || val['pN'] === 'undefined') {
                        val['pN'] = '-';
                    }
                    if (val['fG'] === undefined || val['fG'] === '' || val['fG'] === '0' || val['fG'] === 'undefined') {
                        val['fG'] = '-';
                    }
                });
            }
            else {
                this.methodTimingData = [];
            }
            this.tempMTData = this.doHyperLinkOnMethod(res.data);
            this.dataCount = this.methodTimingData.length;
            if (this.methodTimingData.length > 50) { //If data is less then 10 then no pagination .
                this.showPagination = true;
            }
            else {
                this.showPagination = false;
            }
            if (type == 'package') {
                this.filterType = "Package(s)";
                this.headerStats = "Package(s) Stat";
                this.relativePath = "ddr/method-timing/method-timing-package.json";
            }
            if (type == 'class') {
                this.filterType = "Class(es)";
                this.headerStats = "Class(es) Stat";
                this.relativePath = 'ddr/method-timing/method-timing-class.json';
            }
            if (type == 'method') {
                this.filterType = "Method(s)";
                this.headerStats = "Method(s) Stat";
                this.relativePath = 'ddr/method-timing/method-timing-method.json';
            }
            this.createPieChart(res.data, type);
            this.createCountPieChart(res.data, type);
            if (this.queryParams && this.queryParams.Instance_Type) {
                this.displayAutoInst = true;
            }
            else {
                this.getVectorIds();
            }
        }
        catch (error) {
            console.log("getting error in assigning method timing data ~ ", error);
        }
    }
    /**Used to hyper link method for opening service method timing report
    This is used to check codition of package and class based on which method name is appended with %40 to show hyperlink on table */
    doHyperLinkOnMethod(val) {
        let doHyperLink = false;
        for (let i = 0; i < val.length; i++) {
            if (val[i]["pN"] == "weblogic.servlet.internal" && val[i]["cN"] == "FilterChainImpl")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "javax.servlet.http" && val[i]["cN"] == "HttpServlet")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "com.sun.jersey.spi.container.servlet" && val[i]["cN"] == "WebComponent")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "org.glassfish.jersey.servlet" && val[i]["cN"] == "ServletContainer")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "weblogic.servlet.jsp" && val[i]["cN"] == "JspBase")
                val[i]["mN"] = val[i]["mN"] + "%40";
            else if (val[i]["pN"] == "org.apache.jasper.runtime" && val[i]["cN"] == "HttpJspBase")
                val[i]["mN"] = val[i]["mN"] + "%40";
        }
        return val;
    }
    /** Auto Instrumentation DDAI */
    getIdFortier(data) {
        return data.trim().split(":");
    }
    getVectorIds() {
        let mtFilter = this.commonService.methodTimingFilters;
        if (this.commonService.isValidParameter(mtFilter['serverName']) && this.commonService.isValidParameter(mtFilter['appName'])) {
            let urlForid;
            this.displayAutoInst = true;
            urlForid = this.getHostUrl();
            urlForid += "/" + this.sessionService.session.cctx.prodType.toLowerCase().replace("/", "") + "/analyze/drill_down_queries/" + "NDAjaxController.jsp?strOperName=getTSAname&testRun=" + this.id.testRun + "&tierName=" + mtFilter['tierName'] + "&serverName=" + mtFilter['serverName'] + "&appName=" + mtFilter['appName'];
            return this.ddrRequest.getDataInStringUsingGet(urlForid).subscribe(data => {
                this.getAgentInfo(data);
            });
        }
        else {
            this.displayAutoInst = false;
        }
    }
    getAgentInfo(res) {
        this.vecId = this.getIdFortier(res);
        this.commonService.methodTimingFilters['tierId'] = this.vecId[0].trim();
        this.commonService.methodTimingFilters['serverId'] = this.vecId[1].trim();
        this.commonService.methodTimingFilters['appId'] = this.vecId[2].trim();
        let url;
        url += "testRun=" + this.id.testRun +
            "&tierId=" + this.vecId[0].trim() + "&serverId=" + this.vecId[1].trim() + "&appId=" + this.vecId[2].trim();
        this.ndDdrHttpService.getAgentType(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["AgentTypeLoadedState"]) {
                this.agentType = state.data;
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.commonService.showError(error);
            this.loader = false;
        });
    }
    openAutoInstDialog() {
        let testRunStatus;
        let AgentType;
        let mtFilter = this.commonService.methodTimingFilters;
        let url = 'testRun=' + this.id.testRun;
        this.ndDdrHttpService.getTRStatus(url).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_12__["TestRunStatusLoadedState"]) {
                testRunStatus = state.data.data;
                if (testRunStatus.length != 0) {
                    if (this.queryParams && this.queryParams.Instance_Type) {
                        this.agentType = this.queryParams.Instance_Type;
                    }
                    else {
                        this.agentType = this.agentType;
                    }
                    if (this.agentType.toLowerCase() == 'java')
                        AgentType = 'Java';
                    else if (this.agentType.toLowerCase() == 'dotnet')
                        AgentType = 'DotNet';
                    else if (this.agentType.toLowerCase() == 'dotnetc')
                        AgentType = 'DotNetC';
                    this.showAutoInstrPopUp = true;
                    this.argsForAIDDSetting = [mtFilter['appName'], mtFilter['appId'], AgentType, mtFilter['tierName'],
                        mtFilter['serverName'], mtFilter['serverId'], "-1", mtFilter['urlName'], "DDR", testRunStatus[0].status, this.id.testRun];
                }
                else {
                    this.showAutoInstrPopUp = false;
                    this.messageService.showError("Could not start instrumentation, test is not running");
                    return;
                }
            }
        });
    }
    startInstrumentation(result) {
        this.showAutoInstrPopUp = false;
    }
    closeAIDDDialog(isCloseAIDDDialog) {
        this.showAutoInstrPopUp = isCloseAIDDDialog;
    }
    /**To show filter criteria */
    showFilterCriteria(startTime, endTime) {
        this.filterCriteria = "";
        this.URLstr = "";
        this.CompleteURL = "";
        this.filterTierName = '';
        this.filterServerName = '';
        this.filterInstanceName = '';
        this.completeTier = '';
        this.completeServer = '';
        this.completeInstance = '';
        let mtFilters = this.commonService.methodTimingFilters;
        if (this.commonService.mtFlag == true) {
            if (this.commonService.mtData.tierName != 'NA' && this.commonService.mtData.tierName != undefined && this.commonService.mtData.tierName != null && this.commonService.mtData.tierName != '') {
                this.filterCriteria += 'Tier=' + this.commonService.mtData.tierName;
            }
            if (this.commonService.mtData.serverName != 'NA' && this.commonService.mtData.serverName != undefined && this.commonService.mtData.serverName != '' && this.commonService.mtData.serverName != null) {
                this.filterCriteria += ', Server=' + this.commonService.mtData.serverName;
            }
            if (this.commonService.mtData.appName != 'NA' && this.commonService.mtData.appName != undefined && this.commonService.mtData.appName != '' && this.commonService.mtData.appName != null) {
                this.filterCriteria += ', Instance=' + this.commonService.mtData.appName;
            }
        }
        else {
            if (this.commonService.isValidParamInObj(mtFilters, "tierName")) {
                if (mtFilters['tierName'].length > 32) {
                    this.filterTierName += 'Tier=' + mtFilters['tierName'].substring(0, 32) + '...';
                    this.completeTier = mtFilters['tierName'];
                }
                else
                    this.filterTierName += 'Tier=' + mtFilters['tierName'];
            }
            if (this.commonService.isValidParamInObj(mtFilters, "serverName")) {
                if (mtFilters['serverName'].length > 32) {
                    this.filterServerName = ', Server=' + mtFilters['serverName'].substring(0, 32) + '...';
                    this.completeServer = mtFilters['serverName'];
                }
                else
                    this.filterServerName = ', Server=' + mtFilters['serverName'];
            }
            if (this.commonService.isValidParamInObj(mtFilters, "appName")) {
                if (mtFilters['appName'].length > 32) {
                    this.filterInstanceName = ', Instance=' + mtFilters['appName'].substring(0, 32) + '...';
                    this.completeInstance = mtFilters['appName'];
                }
                else
                    this.filterInstanceName = ', Instance=' + mtFilters['appName'];
            }
        }
        if (this.commonService.isValidParamInObj(mtFilters, "startTimeInDateFormat")) {
            this.filterCriteria += ', StartTime=' + mtFilters['startTimeInDateFormat'];
        }
        if (this.commonService.isValidParamInObj(mtFilters, "endTimeInDateFormat")) {
            this.filterCriteria += ', EndTime=' + mtFilters['endTimeInDateFormat'];
        }
        if (this.commonService.isValidParamInObj(mtFilters, "page")) {
            this.filterCriteria += ', Page=' + mtFilters['page'];
        }
        if (this.commonService.isValidParamInObj(mtFilters, "script")) {
            this.filterCriteria += ', Script=' + mtFilters['script'];
        }
        if (this.commonService.isValidParamInObj(mtFilters, "transaction")) {
            this.filterCriteria += ', Transaction=' + mtFilters['transaction'];
        }
        if (this.commonService.isValidParamInObj(mtFilters, "browser")) {
            this.filterCriteria += ', Browser=' + mtFilters['browser'];
        }
        if (this.commonService.isValidParamInObj(mtFilters, "access")) {
            this.filterCriteria += ', Access=' + mtFilters['access'];
        }
        if (this.commonService.isValidParamInObj(mtFilters, "location")) {
            this.filterCriteria += ', Location=' + mtFilters['location'];
        }
        if (this.commonService.isValidParamInObj(mtFilters, "btCatagory")) {
            this.filterCriteria += ', BT Type=' + this.commonService.getBTCategoryName(mtFilters['btCatagory']);
        }
        if (this.commonService.isValidParamInObj(mtFilters, "urlName")) {
            this.filterCriteria += ', BT=' + decodeURIComponent(mtFilters['urlName']);
        }
        if (this.commonService.isValidParamInObj(mtFilters, "url")) {
            let val = decodeURIComponent(mtFilters['url']);
            if (val.length > 40) {
                this.URLstr = ', URL=' + val.substring(0, 40) + "..";
                this.CompleteURL = val;
            }
            else {
                this.URLstr = ', URL=' + val;
                this.CompleteURL = val;
            }
        }
        if (this.commonService.isValidParamInObj(mtFilters, "tags")) {
            this.filterCriteria += ', Tag:' + mtFilters['tags'];
            this.filterCriteria = this.filterCriteria.replace(/["']/g, "");
        }
        if (!this.commonService.isValidParamInObj(mtFilters, "tierName") && !this.commonService.isValidParamInObj(mtFilters, "serverName") && !this.commonService.isValidParamInObj(mtFilters, "appName") && this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
    }
    /**Formatter cell data for percentage field */
    pctFormatter(value) {
        if (!isNaN(value) && (value != 100 && value != 0)) {
            return Number(value).toFixed(3);
        }
        else
            return value;
    }
    /**Formatter cell data for converting ms to sec field */
    secFormatter(value) {
        if (!isNaN(value))
            return Number(value / 1000).toFixed(2);
        else
            return value;
    }
    formatterForClass(value) {
        if (value == "")
            return "-";
        if (!isNaN(value)) {
            return (Number(value)).toLocaleString();
        }
        else
            return value;
    }
    /**Used to create custom tooltip in pie chart(package/class/method) */
    formatPointName(pack, clas, method) {
        var temp = "";
        if (pack != "" && clas != "" && method != "") {
            if (method.indexOf("%40") != -1)
                temp += "<b>Method: </b> " + method.substring(0, method.indexOf("%40")) + "<br/>" + "<b>Class: </b> " + clas + "<br/>" + "<b>Package: </b> " + pack + "<br/>";
            else
                temp += "<b>Method: </b> " + method + "<br/>" + "<b>Class: </b> " + clas + "<br/>" + "<b>Package: </b> " + pack + "<br/>";
        }
        else if (pack != "" && clas != "") {
            temp += "<b>Class: </b> " + clas + "<br/>" + "<b>Package: </b> " + pack + "<br/>";
        }
        else if (pack != "") {
            temp += "<b>Package: </b> " + pack + "<br/>";
        }
        return temp;
    }
    /**used to calculate sum of all Others(Rest)json to show in pie chart */
    sumOfRestPercentage(restJsonData) {
        let totalPct = 0;
        for (var i = 0; i < restJsonData.length; i++) {
            totalPct += Number(restJsonData[i].percent);
        }
        return totalPct.toFixed(3);
    }
    /**used to calculate sum of all Others(Rest)json to show in pie chart for Count */
    sumOfRestCount(restJsonData) {
        let totalcount = 0;
        for (var i = 0; i < restJsonData.length; i++) {
            totalcount += Number(restJsonData[i].eC);
        }
        return totalcount;
    }
    /**Used to reset to original data to table */
    showAllData() {
        this.methodTimingData = this.wholeData;
        this.dataCount = this.methodTimingData.length;
        this.pointName = "";
    }
    /**used when click on pie chart table data will change accordingly */
    clickHandler(event) {
        try {
            if (event.point.name != undefined && event.point.name != 'undefined') {
                if (event.point.name != "")
                    this.pointName = "[ " + event.point.name + " ]";
                if (event.point.name == "Other") {
                    this.methodTimingData = this.restDataArrOfPie;
                    this.dataCount = this.methodTimingData.length;
                }
                else {
                    let filteredData = [];
                    this.chartData.forEach((val, index) => {
                        if (event.point.ClickText.indexOf("%") != -1) {
                            if (val['eN'].indexOf(event.point.ClickText.substring(0, event.point.ClickText.indexOf("%"))) != -1)
                                filteredData.push(val);
                        }
                        else {
                            if (val['eN'].indexOf(event.point.ClickText) != -1) {
                                filteredData.push(val);
                            }
                        }
                    });
                    this.methodTimingData = filteredData;
                    this.dataCount = this.methodTimingData.length;
                }
            }
        }
        catch (error) {
            console.error("Error in event click:" + error);
        }
    }
    /**Used to create pie chart based on Percentage */
    createPieChart(pieData, type) {
        if (this.nTopMethod == "" || this.nTopMethod == undefined)
            this.nTopMethod = "5";
        let pct;
        let dataArr = [];
        let restDataArr = [];
        this.chartData = pieData;
        let totalRestPct;
        this.wholeData = this.chartData;
        this.showChart = this.chartData.length === 0 ? false : true;
        for (var i = 0; i < this.chartData.length; i++) {
            if (i < Number(this.nTopMethod)) {
                if (type == 'method') {
                    if (this.chartData[i]["mN"].indexOf("%40") != -1)
                        this.entityName = this.chartData[i]["mN"].substring(0, this.chartData[i]["mN"].indexOf("%40"));
                    else
                        this.entityName = this.chartData[i]["mN"];
                    pct = this.chartData[i]["percent"];
                    dataArr.push({ "name": this.entityName, "y": Number(pct), "text": this.formatPointName(this.chartData[i]['pN'], this.chartData[i]['cN'], this.chartData[i]['mN']), "ClickText": this.chartData[i]['pN'] + '.' + this.chartData[i]['cN'] + '.' + this.chartData[i]['mN'] });
                }
                else if (type == 'class') {
                    this.entityName = this.chartData[i]["cN"];
                    pct = this.chartData[i]["percent"];
                    dataArr.push({ "name": this.entityName, "y": Number(pct), "text": this.formatPointName(this.chartData[i]['pN'], this.chartData[i]['cN'], ""), "ClickText": this.chartData[i]['pN'] + '.' + this.chartData[i]['cN'] });
                }
                else if (type == 'package') {
                    this.entityName = this.chartData[i]["pN"];
                    pct = this.chartData[i]["percent"];
                    dataArr.push({ "name": this.entityName, "y": Number(pct), "text": this.formatPointName(this.chartData[i]['pN'], "", ""), "ClickText": this.chartData[i]['pN'] });
                }
            }
            else
                restDataArr.push(this.chartData[i]);
        }
        totalRestPct = this.sumOfRestPercentage(restDataArr);
        if (this.chartData.length > Number(this.nTopMethod)) {
            this.entityName = "Other";
            pct = totalRestPct;
            dataArr.push({ "name": this.entityName, "y": Number(pct.toFixed(3)) });
        }
        this.restDataArrOfPie = restDataArr;
        this.options = {
            chart: {
                type: "pie"
            },
            credits: {
                enabled: false
            },
            title: {
                text: this.filterType + ' By Percentage',
                style: { 'fontSize': '13px' }
            },
            legend: {
                itemWidth: 400
            },
            tooltip: {
                headerFormat: '',
                pointFormat: '<br>{point.text}<b>Percentage:</b>{point.y}%'
            },
            plotOptions: {
                pie: {
                    showInLegend: true,
                    allowPointSelect: true,
                    size: '50%',
                    turboThreshold: 5000,
                    cursor: 'pointer',
                    dataLabels: {
                        enabled: false,
                    },
                    events: {
                        click: function (e) {
                            this.clickHandler(e);
                        }.bind(this)
                    }
                }
            },
            exporting: {
                enabled: false
            },
            series: [
                {
                    data: dataArr,
                    enableMouseTracking: true
                }
            ]
        };
    }
    /**Method used to create Pie chart based on Count>>>>>>>>>>>>>> */
    createCountPieChart(pieData, type) {
        if (this.nTopMethod == "" || this.nTopMethod == undefined)
            this.nTopMethod = "5";
        var pieText;
        let count;
        let dataArr = [];
        let restDataArr = [];
        this.chartData = pieData;
        let totalRestCount;
        this.wholeData = this.chartData;
        this.showCountPieChart = this.chartData.length === 0 ? false : true;
        for (var i = 0; i < this.chartData.length; i++) {
            if (i < Number(this.nTopMethod)) {
                if (type == 'method') {
                    if (this.chartData[i]["mN"].indexOf("%40") != -1)
                        this.entityName = this.chartData[i]["mN"].substring(0, this.chartData[i]["mN"].indexOf("%40"));
                    else
                        this.entityName = this.chartData[i]["mN"];
                    count = this.chartData[i]["eC"];
                    dataArr.push({ "name": this.entityName, "y": Number(count), "text": this.formatPointName(this.chartData[i]['pN'], this.chartData[i]['cN'], this.chartData[i]['mN']), "ClickText": this.chartData[i]['pN'] + '.' + this.chartData[i]['cN'] + '.' + this.chartData[i]['mN'] });
                }
                else if (type == 'class') {
                    this.entityName = this.chartData[i]["cN"];
                    count = this.chartData[i]["eC"];
                    dataArr.push({ "name": this.entityName, "y": Number(count), "text": this.formatPointName(this.chartData[i]['pN'], this.chartData[i]['cN'], ""), "ClickText": this.chartData[i]['pN'] + '.' + this.chartData[i]['cN'] });
                }
                else if (type == 'package') {
                    this.entityName = this.chartData[i]["pN"];
                    count = this.chartData[i]["eC"];
                    dataArr.push({ "name": this.entityName, "y": Number(count), "text": this.formatPointName(this.chartData[i]['pN'], "", ""), "ClickText": this.chartData[i]['pN'] });
                }
            }
            else
                restDataArr.push(this.chartData[i]);
        }
        totalRestCount = this.sumOfRestCount(restDataArr);
        if (this.chartData.length > Number(this.nTopMethod)) {
            this.entityName = "Other";
            count = totalRestCount;
            dataArr.push({ "name": this.entityName, "y": Number(count) });
        }
        this.restDataArrOfPie = restDataArr;
        this.CountPieChartOptions = {
            chart: {
                type: "pie"
            },
            credits: {
                enabled: false
            },
            title: {
                text: this.filterType + ' By Count',
                style: { 'fontSize': '13px' }
            },
            legend: {
                itemWidth: 400
            },
            tooltip: {
                headerFormat: '',
                pointFormat: '<br>{point.text}<b>Count:</b>{point.y}'
            },
            plotOptions: {
                pie: {
                    showInLegend: true,
                    allowPointSelect: true,
                    size: '50%',
                    turboThreshold: 5000,
                    cursor: 'pointer',
                    dataLabels: {
                        enabled: false,
                    },
                    events: {
                        click: function (e) {
                            this.clickHandler(e);
                        }.bind(this)
                    }
                }
            },
            exporting: {
                enabled: false
            },
            series: [
                {
                    data: dataArr,
                    enableMouseTracking: true
                }
            ]
        };
    }
    ApplyignoreFP() {
        this.ignoreFlag = false;
        this.isApplied = true;
        this.getMethodTimigData(this.urlPramObj['type'], this.urlPramObj['entity']);
    }
    ngOnDestroy() {
        if (this.commonService.isFromSplitView) {
            this._ddrData.splitViewFlag = true;
            this.commonService.isToLoadSideBar = false;
        }
        this.breadcrumb['items'].pop();
        this.sideBarMethodTiming.unsubscribe();
    }
};
MethodtimingComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_4__["CavConfigService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_14__["CavMessageService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["NdDdrHttpService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_15__["ElasticsearchQueryService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], MethodtimingComponent.prototype, "columnData", void 0);
MethodtimingComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'methodtiming',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./methodtiming.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/methodtiming/methodtiming.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./methodtiming.component.scss */ "./src/app/pages/ddr/components/methodtiming/methodtiming.component.scss")).default]
    })
], MethodtimingComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.scss":
/*!**********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.scss ***!
  \**********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.ts":
/*!********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.ts ***!
  \********************************************************************************************/
/*! exports provided: NsPageReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NsPageReportComponent", function() { return NsPageReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");



let NsPageReportComponent = class NsPageReportComponent {
    constructor(breadcrumbService) {
        this.breadcrumbService = breadcrumbService;
        this.summary = false;
        this.instance = false;
        this.summaryByStatus = false;
        this.failure = false;
        this.compDetail = false;
        this.sessionSummary = false;
    }
    ngOnChanges() {
        this.loadComponent();
    }
    ngOnInit() {
        console.log(" id from input decorator = ", this.id);
        this.loadComponent();
    }
    loadComponent() {
        if (this.id === 'PageSummary') {
            this.breadcrumbService.addNewBreadcrumb({ label: 'Page Summary', routerLink: '/ddr/nsreports/PageSummary' }); // Due to A-9 migration....
            this.summary = true;
            this.summaryByStatus = false;
            this.instance = false;
            this.compDetail = false;
            this.failure = false;
            this.sessionSummary = false;
        }
        else if (this.id === 'PageSessionSummary') {
            this.breadcrumbService.addNewBreadcrumb({ label: 'Page Session Summary', routerLink: '/ddr/nsreports/PageSessionSummary' }); // Due to A-9 migration....
            this.sessionSummary = true;
            this.summary = false;
            this.summaryByStatus = false;
            this.instance = false;
            this.compDetail = false;
            this.failure = false;
        }
        else if (this.id === 'PageSummaryByStatus') {
            this.breadcrumbService.addNewBreadcrumb({ label: 'Page Summary By Status', routerLink: '/ddr/nsreports/PageSummaryByStatus' }); // Due to A-9 migration....
            this.summary = true;
            this.summaryByStatus = true;
            this.instance = false;
            this.sessionSummary = false;
            this.compDetail = false;
            this.failure = false;
        }
        else if (this.id === 'PageInstance') {
            this.breadcrumbService.addNewBreadcrumb({ label: 'Page Instance', routerLink: '/ddr/nsreports/PageInstance' }); // Due to A-9 migration....
            this.instance = true;
            this.summary = false;
            this.summaryByStatus = false;
            this.sessionSummary = false;
            this.compDetail = false;
            this.failure = false;
        }
        else if (this.id === 'PageFailure') {
            this.breadcrumbService.addNewBreadcrumb({ label: 'Page Failure', routerLink: '/ddr/nsreports/PageFailure' }); // Due to A-9 migration....
            this.failure = true;
            this.instance = false;
            this.summary = false;
            this.summaryByStatus = false;
            this.sessionSummary = false;
            this.compDetail = false;
        }
        else if (this.id === 'PageComponentDetail') {
            this.breadcrumbService.addNewBreadcrumb({ label: 'Page Component Details', routerLink: '/ddr/nsreports/PageComponentDetail' }); // Due to A-9 migration....
            this.compDetail = true;
            this.failure = false;
            this.instance = false;
            this.summary = false;
            this.summaryByStatus = false;
            this.sessionSummary = false;
        }
    }
};
NsPageReportComponent.ctorParameters = () => [
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__["BreadcrumbService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], NsPageReportComponent.prototype, "id", void 0);
NsPageReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'ns-page-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ns-page-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ns-page-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.scss")).default]
    })
], NsPageReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.scss":
/*!*****************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.scss ***!
  \*****************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-page-component-details .ddr-accordion .ui-accordion-content-wrapper .ui-accordion-content {\n  padding: 5px 0px;\n}\napp-page-component-details .ddr-graphpanel .highcharts-container .highcharts-contextbutton {\n  display: none !important;\n}\napp-page-component-details .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-page-component-details .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-page-component-details .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-page-component-details .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.ts":
/*!***************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.ts ***!
  \***************************************************************************************************************************/
/*! exports provided: PageComponentDetailsComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PageComponentDetailsComponent", function() { return PageComponentDetailsComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var rxjs_Rx__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs/Rx */ "./node_modules/rxjs-compat/_esm2015/Rx.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_11__);
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");




// import { CavConfigService } from '../../../../../../main/services/cav-config.service';
// import { CavTopPanelNavigationService } from '../../../../../../main/services/cav-top-panel-navigation.service';
//import { NsReportService } from '../../../../../../main/services/ns-report-service';





// import { DdrDataModelService } from '../../../../../../main/services/ddr-data-model.service';








let PageComponentDetailsComponent = class PageComponentDetailsComponent {
    constructor(commonService, sessionService, nsCommonData, _router, breadcrumbService, route, _ddrData, ddrRequest, txService, breadcrumb, ddrHttpService) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this.nsCommonData = nsCommonData;
        this._router = _router;
        this.breadcrumbService = breadcrumbService;
        this.route = route;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.txService = txService;
        this.breadcrumb = breadcrumb;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_11__;
        this.showPieChart = false;
        this.showStackedBarChart = false;
        this.filterCriteria = "";
        this.pageName = "";
        this.statusField = "";
        this.pageSummaryByStatusFlag = "";
        this.loading = false;
        this.location = '';
        this.access = '';
        this.browser = '';
        this.urlName = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.relativePath = "ddr/page-component-details/page-component-details.json";
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.isBackButton = true;
        this.commonService.currentReport = 'Page Component Details';
        console.log(" currRowData **** ", this.nsCommonData.currRowData);
        this.randomNumber();
        // this.pageName = this.nsCommonData.pgSummaryToCompDetailData['pageName'];
        this.urlParam = this.commonService.getData();
        console.log(" **** url Param **** ", this.urlParam);
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.pageSummaryByStatusFlag = this.route.snapshot.queryParams['pageSummaryByStatus'];
        console.log("pageSummaryByStatusFlag in component detail = ", this.pageSummaryByStatusFlag);
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_COMPONENT_DETAIL);
        this.getDataFromRow();
        this.setTestRunHeader();
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.getPageCompDetailData();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) == "clickable") {
            me.openURLCompDetail(event.cavEventExt.row);
        }
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Due to A-9 migration...
        if (this.sessionService.preSession.multiDc === true) {
            this.urlParam.testRun = this.sessionService.session.testRun.id;
            console.log("all case url==>", hostDcName, "all case test run==>", this.urlParam.testRun, "----", this.sessionService.session.testRun.id);
            var hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            var hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    getPageCompDetailData() {
        let ajaxParam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.pageSummaryByStatusFlag == 'true')
            this.statusField = this.nsCommonData.currRowData["statusCode"];
        else
            this.statusField = '-2';
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        ajaxParam += '&startTime=' + this.urlParam.startTime +
            '&endTime=' + this.urlParam.endTime +
            '&object=' + this.nsCommonData.objectType +
            '&scriptName=' + this.scriptName +
            '&trans=' + this.trnxName +
            '&status=' + this.statusField +
            '&pageIndex=' + this.pageIndex +
            '&url=' + this.urlName +
            '&location=' + this.location +
            '&browser=' + this.browser +
            '&access=' + this.access;
        if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            ajaxParam += '&groupName=' + this._ddrData.vectorName;
        if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxParam += '&generatorName=' + this._ddrData.generatorName;
        //  '&startTime=' + this.urlParam.startTime + '&endTime=' + this.urlParam.endTime +
        // '&object=1&pageIndex=' +this.nsCommonData.pgSummaryToCompDetailData['pageIndex'] +
        // '&status='+this.statusField+
        //  '&scriptName=' + this.nsCommonData.pgSummaryToCompDetailData['scriptName'];
        ajaxParam += '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        // return this.ddrRequest.getDataUsingGet(this.url).subscribe(data => this.assignPageCompDetailData(data));
        this.ddrHttpService.getPageComponentDetailData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["PageComponentDetailLoadedState"]) {
                this.assignPageCompDetailData(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignPageCompDetailData(res) {
        console.log("response for page Component = ", res);
        this.isCancelQuerydata = true;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.loading = false;
        this.pageCompDetailInfo = res.data;
        this.showFilterCriteria(res.startTimeInDateFormat, res.endTimeInDateFormat);
        this.createPieChart(res);
        this.createStackedBarChart(res);
    }
    showFilterCriteria(startTimeInDateFormat, endTimeInDateFormat) {
        this.filterCriteria += "TR=" + this.sessionService.session.testRun.id;
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') //Due to A-9 migration..
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC" + (this._ddrData.dcName || 'Master');
        if (this._ddrData.startTimeInDateFormat) {
            this.filterCriteria += ", From=" + this._ddrData.startTimeInDateFormat;
        }
        else {
            if (startTimeInDateFormat != "NA" && startTimeInDateFormat != "" && startTimeInDateFormat != undefined && startTimeInDateFormat != "undefined")
                this.filterCriteria += ", From=" + startTimeInDateFormat;
        }
        if (this._ddrData.endTimeInDateFormat) {
            this.filterCriteria += ", To=" + this._ddrData.endTimeInDateFormat;
        }
        else {
            if (endTimeInDateFormat != "NA" && endTimeInDateFormat != "" && endTimeInDateFormat != undefined && endTimeInDateFormat != "undefined")
                this.filterCriteria += ", To=" + endTimeInDateFormat;
        }
        if (this.pageName != "NA" && this.pageName != "" && this.pageName != undefined && this.pageName != "undefined")
            this.filterCriteria += ", Page=" + this.pageName;
        if (this.scriptName != "NA" && this.scriptName != "" && this.scriptName != undefined && this.scriptName != "undefined")
            this.filterCriteria += ", Script=" + this.scriptName;
        if (this.trnxName != "NA" && this.trnxName != "" && this.trnxName != undefined && this.trnxName != "undefined")
            this.filterCriteria += ", Transaction=" + this.trnxName;
        if (this.avgRespTime != "NA" && this.avgRespTime != "" && this.avgRespTime != undefined && this.avgRespTime != "undefined")
            this.filterCriteria += ",  Average Page Response Time=" + this.msToTimeFormat(this.avgRespTime) + ' (hh:mm:ss.ms)';
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.filterCriteria.startsWith(','))
            this.filterCriteria = this.filterCriteria.substring(1);
        if (this.filterCriteria.endsWith(','))
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
    }
    createPieChart(pieData) {
        let pieChartData = pieData.data;
        console.log("pieChartData == ", pieChartData);
        let pieDataArr = [];
        if (pieChartData.length == 0)
            this.showPieChart = false;
        else {
            this.showPieChart = true;
            for (let i = 0; i < pieChartData.length; i++) {
                pieDataArr.push({ 'name': pieChartData[i]['component'], 'y': Number(pieChartData[i]['pageRespTimePercent']) });
            }
            console.log("pieDataArr = ", pieDataArr);
            this.pieOptions = {
                chart: {
                    type: 'pie',
                    width: 250,
                    height: 250
                },
                credits: {
                    enabled: false
                },
                title: {
                    text: 'Page Component Details',
                    style: { 'fontSize': '13px' }
                },
                tooltip: {
                    pointFormat: '{series.name}: <b>{point.y}%</b>'
                },
                plotOptions: {
                    pie: {
                        allowPointSelect: true,
                        cursor: 'pointer',
                        dataLabels: {
                            enabled: false
                        },
                        showInLegend: true
                    }
                },
                series: [{
                        name: 'Page Components',
                        data: pieDataArr
                    }]
            };
        }
    }
    createStackedBarChart(barChartData) {
        let stackedChartData;
        let stackedDataArr = [];
        if (this.nsCommonData.isFromSessionCompDetail == true) {
            stackedChartData = this.nsCommonData.barDataForSessionComp;
            stackedDataArr = this.nsCommonData.barDataForSessionComp;
        }
        else {
            stackedChartData = barChartData.data;
            for (let k = 0; k < stackedChartData.length; k++) {
                let avgDownloadTimeInSec = Number(stackedChartData[k]['avgDownloadTime']) / 1000;
                stackedDataArr.push({ 'name': stackedChartData[k]['component'], 'data': [avgDownloadTimeInSec] });
            }
        }
        console.log("stackedDataArr = ", stackedDataArr);
        if (stackedChartData.length == 0)
            this.showStackedBarChart = false;
        else
            this.showStackedBarChart = true;
        this.stackedBarOptions = {
            chart: {
                type: 'bar',
                width: 600,
                height: 250
            },
            title: {
                text: 'Time Split chart',
                style: { 'fontSize': '13px' }
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Seconds'
                }
            },
            credits: {
                enabled: false
            },
            plotOptions: {
                series: {
                    stacking: 'normal'
                }
            },
            series: stackedDataArr
        };
    }
    openURLCompDetail(node) {
        let urlType;
        let params;
        console.log("node = ", node);
        if (node.component == 'Main URL')
            urlType = 1;
        else if (node.component == 'Embedded URL(s)')
            urlType = 2;
        else if (node.component == 'Main Redirect URL(s)')
            urlType = 3;
        if (this.nsCommonData.isFromSessionCompDetail == true)
            params = this.nsCommonData.barDataForSessionComp;
        else
            params = { "urlType": urlType, "pageIndex": this.pageIndex, "Object": "1", "status": "-2", "startTime": this.urlParam.startTime, "endTime": this.urlParam.endTime, "pageName": this.pageName, "transName": this.trnxName };
        this.nsCommonData.pgDetailToURLDetailFlag = true;
        this.nsCommonData.pgDetailToURLDetailData = params;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_COMPONENT_DETAIL;
        this.breadcrumb.add({ label: 'URL Component Details', routerLink: '/ddr/nsreports/urldetails' });
        this._router.navigate(['/ddr/nsreports/urldetails']);
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormat(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    // Formatter for showing value upto 2 decimal places
    formatter(value) {
        if (!isNaN(value))
            return Number(value).toFixed(2);
        else
            return value;
    }
    getDataFromRow() {
        if (this.nsCommonData.objectType === '2') //transaction
         {
            this.reportType = 'Transacion';
            this.avgRespTime = this.nsCommonData.currRowData["avgPageresponseTime"];
            this.pageIndex = this.nsCommonData.currRowData["pageindex"];
            this.pageName = this.nsCommonData.currRowData["pagename"];
            this.trnxName = this.nsCommonData.transactionName;
        }
        else if (this.nsCommonData.objectType === '1') //page
         {
            this.reportType = 'Page';
            this.avgRespTime = this.nsCommonData.currRowData["respTime"];
            this.pageName = this.nsCommonData.currRowData["pageName"];
            this.pageIndex = this.nsCommonData.currRowData["pageIndex"];
            this.scriptName = this.nsCommonData.scriptName;
        }
        else if (this.nsCommonData.objectType === '3') //Session
         {
            this.reportType = 'Session';
            this.scriptName = this.nsCommonData.scriptName;
            this.avgRespTime = this.nsCommonData.currRowData["avgPageResp"];
            this.pageName = this.nsCommonData.currRowData["pageName"];
            this.pageIndex = this.nsCommonData.currRowData["pageIndex"];
        }
        if (this.commonService.isFromTranscationDetails || this.commonService.isFromPageSummary || this.commonService.isFromPageSessionSummary) {
            if (this.commonService.isFromTranscationDetails) {
                this.urlParam.startTime = this.commonService.nsPageDetails['strStartTime'];
                this.urlParam.endTime = this.commonService.nsPageDetails['strEndTime'];
            }
            if (this.commonService.isFromPageSummary || this.commonService.isFromPageSessionSummary) {
                this.urlParam.startTime = this.commonService.nsPageDetails['startTime'];
                this.urlParam.endTime = this.commonService.nsPageDetails['endTime'];
            }
            if (this.commonService.nsPageDetails['page']) {
                this.pageName = this.commonService.nsPageDetails['page'];
                this.pageIndex = this.commonService.nsPageDetails['pageidx'];
            }
            if (this.commonService.nsPageDetails['transactionName'])
                this.trnxName = this.commonService.nsPageDetails['transactionName'];
            if (this.commonService.nsPageDetails['scriptName'])
                this.scriptName = this.commonService.nsPageDetails['scriptName'];
            if (this.commonService.nsPageDetails['url'])
                this.urlName = this.commonService.nsPageDetails['url'];
            if (this.commonService.nsPageDetails['location'])
                this.location = this.commonService.nsPageDetails['location'];
            if (this.commonService.nsPageDetails['browser'])
                this.browser = this.commonService.nsPageDetails['browser'];
            if (this.commonService.nsPageDetails['access'])
                this.access = this.commonService.nsPageDetails['access'];
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    setTestRunHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm')
            this.strTitle = 'Page Component Detail Report - Test Run : ' + this.sessionService.session.testRun.id; //Removed (Netstorm -) due to A-9 migration...
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Page Component Detail Report - Test Run : ' + this.sessionService.session.testRun.id;
        else
            this.strTitle = 'Netdiagnostics Enterprise - Page Component Detail Report - Session : ' + this.sessionService.session.testRun.id;
    }
    ngOnDestroy() {
        this.commonService.isFromTranscationDetails = false;
        this.commonService.isFromPageSessionSummary = false;
        this.commonService.isFromPageSummary = false;
        this.commonService.isBackButton = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        console.log("Hello u got that", url);
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
PageComponentDetailsComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__["SessionService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["ActivatedRoute"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__["DDRRequestService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_12__["TransactionDetailService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_13__["BreadcrumbService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_15__["DDRHttpService"] }
];
PageComponentDetailsComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-page-component-details',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./page-component-details.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./page-component-details.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.scss")).default]
    })
], PageComponentDetailsComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.scss":
/*!***********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.scss ***!
  \***********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-page-failure-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-page-failure-report .ddr-graphpanel .highcharts-contextbutton {\n  display: none;\n}\napp-page-failure-report .group-left {\n  float: left;\n  padding-top: 4px;\n}\napp-page-failure-report .group-right {\n  float: right;\n  padding-top: 4px;\n}\napp-page-failure-report .highcharts-legend {\n  pointer-events: none;\n}\napp-page-failure-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-page-failure-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.ts":
/*!*********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.ts ***!
  \*********************************************************************************************************************/
/*! exports provided: PageFailureReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PageFailureReportComponent", function() { return PageFailureReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var rxjs_Rx__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs/Rx */ "./node_modules/rxjs-compat/_esm2015/Rx.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_11__);
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");














let PageFailureReportComponent = class PageFailureReportComponent {
    constructor(commonService, nsCommonData, sessionService, _router, breadcrumbService, _ddrData, ddrRequest, ddrHttpService) {
        this.commonService = commonService;
        this.nsCommonData = nsCommonData;
        this.sessionService = sessionService;
        this._router = _router;
        this.breadcrumbService = breadcrumbService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_11__;
        this.showChart = false;
        this.filterCriteria = "";
        this.pageName = "";
        this.scriptName = "";
        this.loading = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        // visibleCols: any[];
        this.errorData = "";
        this.relativePath = "ddr/page-failure-report/page-failure-report.json";
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.commonService.isBackButton = true;
        console.log("page Failure Data = ", this.nsCommonData.pgSummaryToFailureData);
        this.loading = true;
        this.randomNumber();
        this.pageName = this.nsCommonData.pgSummaryToFailureData['pageName'];
        this.scriptName = this.nsCommonData.pgSummaryToFailureData['scriptName'];
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_FAILURE);
        this.urlParam = this.commonService.getData();
        this.commonService.currentReport = "Page Failure";
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        console.log("this.commonservice.nsPageFailure==>", this.commonService.nsPageFailure);
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.getPageFailureData();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) == "clickable") {
            me.openPageInstanceReport(event.cavEventExt.row);
        }
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { //Due to A-9 migration
        if (this.sessionService.preSession.multiDc === true) {
            this.urlParam.testRun = this.sessionService.session.testRun.id;
            console.log("all case url==>", hostDcName, "all case test run==>", this.urlParam.testRun, '----  ', this.sessionService.session.testRun.id);
            var hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            var hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    getPageFailureData() {
        let ajaxParam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        ajaxParam += '&startTime=' + this.urlParam.startTime + '&endTime=' + this.urlParam.endTime + '&object=1&status=-1&pageName=' + this.pageName +
            '&objectId=' + this.nsCommonData.pgSummaryToFailureData['pageIndex'] + '&scriptName=' + this.scriptName;
        if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            ajaxParam += '&groupName=' + this._ddrData.vectorName;
        if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxParam += '&generatorName=' + this._ddrData.generatorName;
        if (this._ddrData.nsErrorName) {
            ajaxParam += '&nsErrorName=' + this._ddrData.nsErrorName;
        }
        if (this.commonService.isFromPageSummary || this.commonService.isFromPageSessionSummary) {
            ajaxParam += this.commonService.makeParamStringFromObjForNS(this.commonService.nsPageFailure, true);
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsPageFailure;
        }
        else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
            this.commonService.isFromPageSummary = true;
            this.commonService.isFromPageSessionSummary = true;
            ajaxParam += this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true);
        }
        ajaxParam += '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        // return this.ddrRequest.getDataUsingGet(this.url).subscribe(data => this.assignPageFailureData(data));
        this.ddrHttpService.getPageFailureData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["PageFailureLoadedState"]) {
                this.assignPageFailureData(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignPageFailureData(res) {
        console.log(" response for failure data = ", res);
        this.isCancelQuerydata = true;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.loading = false;
        this.pageFailureData = res.data;
        this.totalFailure = res.totalFailure;
        this.showFilterCriteria(res.startTimeInDateFormat, res.endTimeInDateFormat);
        this.createColumnChart(res);
    }
    showFilterCriteria(startTimeInDateFormat, endTimeInDateFormat) {
        this.filterCriteria += "TR=" + this.sessionService.session.testRun.id;
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') //Due to A-9 migration
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC=" + (this._ddrData.dcName || 'Master');
        if (this._ddrData.startTimeInDateFormat) {
            this.filterCriteria += ", From=" + this._ddrData.startTimeInDateFormat;
        }
        else {
            if (startTimeInDateFormat != "NA" && startTimeInDateFormat != "" && startTimeInDateFormat != undefined && startTimeInDateFormat != "undefined")
                this.filterCriteria += ", From=" + startTimeInDateFormat;
        }
        if (this._ddrData.endTimeInDateFormat) {
            this.filterCriteria += ", To=" + this._ddrData.endTimeInDateFormat;
        }
        else {
            if (endTimeInDateFormat != "NA" && endTimeInDateFormat != "" && endTimeInDateFormat != undefined && endTimeInDateFormat != "undefined")
                this.filterCriteria += ", To=" + endTimeInDateFormat;
        }
        if (this.pageName != "NA" && this.pageName != "" && this.pageName != undefined && this.pageName != "undefined")
            this.filterCriteria += ", Page=" + this.pageName;
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.filterCriteria.startsWith(','))
            this.filterCriteria = this.filterCriteria.substring(1);
        if (this.filterCriteria.endsWith(','))
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
    }
    createColumnChart(chartInfo) {
        let chartData = chartInfo.data;
        console.log("chart data = ", chartData);
        let dataArr = [];
        if (chartData.length == 0)
            this.showChart = false;
        else {
            this.showChart = true;
            for (let i = 0; i < chartData.length; i++) {
                dataArr.push({ name: chartData[i]['failureType'], data: [Number(chartData[i]['noOfFailures'])] });
            }
            console.log("data arr for column chart = ", dataArr);
            this.options = {
                chart: {
                    type: 'column'
                },
                credits: {
                    enabled: false
                },
                title: {
                    text: ''
                },
                xAxis: {
                    categories: ['Number Of Failures']
                },
                yAxis: {
                    min: 0,
                    title: {
                        text: 'No Of Failures'
                    },
                    stackLabels: {
                        enabled: true,
                        style: {
                            fontWeight: 'bold',
                            color: 'gray'
                        },
                        formatter: function () {
                            if (this.total && this.total > 0) {
                                return Number(this.total).toLocaleString();
                            }
                            else {
                                return this.total;
                            }
                        }
                    }
                },
                legend: {
                    align: 'center',
                    floating: false,
                    backgroundColor: 'white',
                    borderColor: '#CCC',
                    borderWidth: 1
                },
                tooltip: {
                    pointFormat: '{series.name}: <b>{point.y}</b>'
                },
                plotOptions: {
                    column: {
                        stacking: 'normal',
                        dataLabels: {
                            enabled: false
                        },
                        pointWidth: 50
                    }
                },
                series: dataArr
            };
        }
    }
    openPageInstanceReport(nodeInfo) {
        console.log("nodeInfo in page failure report = ", nodeInfo);
        this._ddrData.nsCQMFilter["Page Instance"] = undefined;
        //this.nsCommonData.pgFailureToInstanceFlag = true;
        this._ddrData.pageFailure = true;
        this._ddrData.pgSummaryToInstanceFlag = false;
        this.nsCommonData.pgFailureToInstanceData = nodeInfo;
        this.commonService.isFilterFromNSSideBar = false;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_FAILURE;
        if (this.commonService.isFromPageSummary || this.commonService.isFromPageSessionSummary) { //doest include location ,browser and location filter
            this.commonService.nsPageInstance = JSON.parse(JSON.stringify(this.commonService.nsPageFailure));
            delete this.commonService.nsPageInstance['group'];
            if (this.commonService.nsPageInstance['trans']) {
                this.commonService.nsPageInstance['transactionName'] = this.commonService.nsPageInstance['trans'];
                delete this.commonService.nsPageInstance['trans'];
            }
            this.commonService.nsPageInstance['status'] = nodeInfo.failureCode;
            if (this._ddrData.pageFailure) {
                if (this.commonService.nsPageInstance['pageName'] && (this.commonService.nsPageInstance['pageName'] == 'undefined' || this.commonService.nsPageInstance['pageName'] == undefined))
                    this.commonService.nsPageInstance['pageName'] = this.nsCommonData.pgSummaryToFailureData['pageName'];
                if (this.commonService.nsPageInstance['scriptName'] && (this.commonService.nsPageInstance['scriptName'] == 'undefined' || this.commonService.nsPageInstance['scriptName'] == undefined))
                    this.commonService.nsPageInstance['scriptName'] = this.scriptName;
                if (this.commonService.nsPageInstance['pageIndex'] && (this.commonService.nsPageInstance['pageIndex'] == 'undefined' || this.commonService.nsPageInstance['pageIndex'] == undefined))
                    this.commonService.nsPageInstance['pageIndex'] = this.nsCommonData.pgSummaryToFailureData['pageIndex'];
                this.commonService.nsPageInstance['pageSummaryToInstFlag'] = this._ddrData.pgSummaryToInstanceFlag;
                delete this.commonService.nsPageInstance['summaryByStatusFlag'];
                delete this.commonService.nsPageInstance['summaryToSessionSummaryFlag'];
                delete this.commonService.nsPageInstance['reportType'];
                // ajaxParam += '&pageName=' + this.pageName + '&script=' + this.scriptName + "&pageIndex=" + this.nsCommonData.pgSummaryToInstanceData['pageIndex'];
                console.log("this.nsCommonData.pgFailureToInstanceFlag==>", this.nsCommonData.pgFailureToInstanceFlag);
            }
            console.log("this.nsCommonData.pgFailureToInstanceFlag==>", this.nsCommonData.pgFailureToInstanceFlag);
            this.commonService.isFromPageFailure = true;
            console.log("going out of page failure to instance====>", this.commonService.nsPageInstance);
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Page Instance');
        this.commonService.isFilterFromNSSideBar = false;
        this.nsCommonData.scriptName = this.scriptName;
        //, {queryParams : { pageFailureDataFromSummary : JSON.stringify(this.nsCommonData.pgSummaryToFailureData), scriptName : this.scriptName}}
        this._router.navigate(['/ddr/nsreports/PageInstance']);
    }
    // getHeaders(fieldName) {
    //   switch (fieldName) {
    //     case 'failureType':
    //       return 'Failure Type';
    //     case 'noOfFailures':
    //       return 'No. Of Failures';
    //   }
    // }
    ngOnDestroy() {
        this.commonService.isFromPageSummary = false;
        this.commonService.isFromPageSessionSummary = false;
        this.commonService.isCQM = false;
        this.commonService.isBackButton = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        console.log("Hello u got that", url);
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
PageFailureReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__["DDRRequestService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["DDRHttpService"] }
];
PageFailureReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-page-failure-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./page-failure-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./page-failure-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.scss")).default]
    })
], PageFailureReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.scss":
/*!*************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.scss ***!
  \*************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-page-instance-report .ddr-accordion .ui-accordion-content-wrapper .ui-accordion-content {\n  padding: 5px;\n}\napp-page-instance-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-page-instance-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-page-instance-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-page-instance-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.ts":
/*!***********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.ts ***!
  \***********************************************************************************************************************/
/*! exports provided: PageInstanceReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PageInstanceReportComponent", function() { return PageInstanceReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var rxjs_Rx__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs/Rx */ "./node_modules/rxjs-compat/_esm2015/Rx.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");


//import { NsReportService } from '../../../../../../main/services/ns-report-service';

// import { CavConfigService } from '../../../../../../main/services/cav-config.service';
// import { CavTopPanelNavigationService } from '../../../../../../main/services/cav-top-panel-navigation.service';
















let PageInstanceReportComponent = class PageInstanceReportComponent {
    constructor(sessionService, commonService, route, breadcrumbService, _router, nsCommonData, _ddrData, ddrRequest, txService, breadcrumb, scriptUtilService, dialogService, ddrHttpService) {
        this.sessionService = sessionService;
        this.commonService = commonService;
        this.route = route;
        this.breadcrumbService = breadcrumbService;
        this._router = _router;
        this.nsCommonData = nsCommonData;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.txService = txService;
        this.breadcrumb = breadcrumb;
        this.scriptUtilService = scriptUtilService;
        this.dialogService = dialogService;
        this.ddrHttpService = ddrHttpService;
        this.pageInstanceInfo = [{ "pageName": "", "scriptName": "", "location": "", "access": "", "userId": "", "sessionId": "", "startTime": "", "respTime": "",
                "status": "", "childIndex": "", "pageInstance": "" }];
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.limit = 50;
        this.offset = 0;
        this.status = "";
        this.filterCriteria = "";
        this.pageName = "";
        this.scriptName = "";
        this.statusField = "";
        this.loading = false;
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        // onFilter = false;
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.isDdrEnabled = true;
        this.errorData = "";
        this.relativePath = "ddr/page-instance-report/page-instance-report3.json";
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = true;
        this.first.first = 0;
        this.rows.rows = 50;
        this.loading = true;
        //console.log("pgSummaryToInstanceFlag = " , this.nsCommonData.pgSummaryToInstanceFlag);
        this.randomNumber();
        this.urlParam = this.commonService.getData();
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_INSTANCE);
        if (this._ddrData.pageFailure == true) {
            // this.sub = this.route.queryParams.subscribe(params => {
            //   this.failureData = JSON.parse(params['pageFailureDataFromSummary']);
            //   this.scriptName = params['scriptName'];
            //   console.log(" this.failureData ============== " ,  this.failureData); // for bug 67186 due to this ddr side bar ed cond. was getting true.cz of ? present in url of page in browser
            // });
            this.failureData = this.nsCommonData.pgSummaryToFailureData;
            this.scriptName = this.nsCommonData.scriptName;
        }
        if (this._ddrData.pgSummaryToInstanceFlag == true) {
            //this.statusField = this.route.snapshot.queryParams['statusField'];
            this.statusField = this.nsCommonData.statuscode;
            if (this.statusField == undefined)
                this.statusField = this.route.snapshot.queryParams['statusField'];
        }
        this.commonService.currentReport = "Page Instance";
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        this.subscribePage = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Page Instance") {
                this.loading = true;
                this.limit = 50;
                this.offset = 0;
                this.getPageInstanceData();
                this.getPageInstanceDataCount();
                this.makeColumns();
            }
        });
        this.setTestRunHeader();
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.makeColumns();
                this.getPageInstanceData();
                this.getPageInstanceDataCount();
            }
        });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Due to A-9 migration..
        if (this.sessionService.preSession.multiDc === true) {
            this.urlParam.testRun = this.sessionService.session.testRun.id;
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            var hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    makeColumns() {
        if (this._ddrData.WAN_ENV > 0 && !this.sessionService.session.testRun.cmt)
            this.relativePath = 'ddr/page-instance-report/page-instance-report1.json';
        else if (this._ddrData.WAN_ENV > 0 && this.sessionService.session.testRun.cmt)
            this.relativePath = 'ddr/page-instance-report/page-instance-report.json';
        else if (!(this._ddrData.WAN_ENV > 0) && !this.sessionService.session.testRun.cmt)
            this.relativePath = 'ddr/page-instance-report/page-instance-report2.json';
        else
            this.relativePath = 'ddr/page-instance-report/page-instance-report3.json';
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Script Name')
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'User Id')
            me.openUserSessionReport((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row);
        if (((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label) == 'Response Time')
            me.openSessionTimeDetail((_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.row);
    }
    getPageInstanceData() {
        let ajaxParam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        if (this.commonService.isFilterFromNSSideBar && Object.keys(this.commonService.nsPageInstance).length != 0) {
            if (this._ddrData.pgSummaryToInstanceFlag == true) {
                this.commonService.nsPageInstance['pageName'] = this.nsCommonData.pgSummaryToInstanceData['pageName'];
                this.commonService.nsPageInstance['scriptName'] = this.nsCommonData.pgSummaryToInstanceData['scriptName'];
                this.commonService.nsPageInstance['pageIndex'] = this.nsCommonData.pgSummaryToInstanceData['pageIndex'];
            }
            if (this._ddrData.pageFailure) {
                if (this.commonService.nsPageInstance['pageName'] && (this.commonService.nsPageInstance['pageName'] == 'undefined' || this.commonService.nsPageInstance['pageName'] == undefined))
                    this.commonService.nsPageInstance['pageName'] = this.nsCommonData.pgSummaryToFailureData['pageName'];
                if (this.commonService.nsPageInstance['scriptName'] && (this.commonService.nsPageInstance['scriptName'] == 'undefined' || this.commonService.nsPageInstance['scriptName'] == undefined))
                    this.commonService.nsPageInstance['scriptName'] = this.scriptName;
                if (this.commonService.nsPageInstance['pageIndex'] && (this.commonService.nsPageInstance['pageIndex'] == 'undefined' || this.commonService.nsPageInstance['pageIndex'] == undefined))
                    this.commonService.nsPageInstance['pageIndex'] = this.nsCommonData.pgSummaryToFailureData['pageIndex'];
                this.commonService.nsPageInstance['pageSummaryToInstFlag'] = this._ddrData.pgSummaryToInstanceFlag;
            }
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsPageInstance, true);
            this.commonService.isCQM = true;
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsPageInstance;
        }
        else {
            ajaxParam += '&startTime=' + this.urlParam.startTime + '&endTime=' + this.urlParam.endTime + '&object=1&wanenv=' + this._ddrData.WAN_ENV + '&pageSummaryToInstFlag='
                + this._ddrData.pgSummaryToInstanceFlag;
            if (this._ddrData.pgSummaryToInstanceFlag == true) {
                this.pageName = this.nsCommonData.pgSummaryToInstanceData['pageName'];
                this.scriptName = this.nsCommonData.pgSummaryToInstanceData['scriptName'];
                this.status = this.statusField;
                ajaxParam += '&pageName=' + this.pageName + '&scriptName=' + this.scriptName + "&pageIndex=" + this.nsCommonData.pgSummaryToInstanceData['pageIndex'];
            }
            else if (this._ddrData.pageFailure == true) {
                if (this.nsCommonData.pgFailureToInstanceData == undefined)
                    this.status = '-1';
                else
                    this.status = this.nsCommonData.pgFailureToInstanceData['failureCode'];
                let pageIndex = undefined;
                if (this.failureData && this.failureData['pageName']) {
                    this.pageName = this.failureData['pageName'];
                    pageIndex = this.failureData.pageIndex;
                }
                ajaxParam += '&pageName=' + this.pageName + '&pageIndex=' + pageIndex + '&script=' + this.scriptName;
            }
            else
                this.status = "-2";
            ajaxParam += '&status=' + this.status;
            // if(this._ddrData.groupName=="Page Download"  && this._ddrData.vectorName!='undefined'&& this._ddrData.vectorName!=undefined )
            // ajaxParam += '&pageName=' + this._ddrData.vectorName;
            if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this._ddrData.vectorName;
            if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this._ddrData.generatorName;
            if (this._ddrData.nsErrorName) {
                ajaxParam += '&nsErrorName=' + this._ddrData.nsErrorName;
            }
            // this.commonService.nsPageInstance=this.commonService.makeObjectFromUrlParam(ajaxParam);
            //do not make ajax param here cz it will change the object stored in for breadcrumb via CQM.
        }
        if (this.commonService.isFromPageSummary || this.commonService.isFromPageFailure || this.commonService.isFromPageSessionSummary || this.commonService.isCQM) {
            //this.commonService.nsTransactionSummary=this._ddrData.nsCQMFilter[this.commonService.currentReport];
            ajaxParam = this.commonService.checkAndReturnUniqueParams(ajaxParam, this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLSummary, true));
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsPageInstance;
        }
        else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
            this.commonService.isFromPageInstance = true;
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true);
        }
        this.commonService.nsPageInstance = this.commonService.makeObjectFromUrlParam(ajaxParam);
        this.url = ajaxParam;
        ajaxParam += '&limit=' + this.limit + '&offset=' + this.offset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        // return this.ddrRequest.getDataUsingGet(finalUrl).subscribe(data => this.assignPageInstanceData(data));
        this.ddrHttpService.getPageInstanceData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__["PageInstanceLoadedState"]) {
                this.assignPageInstanceData(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignPageInstanceData(res) {
        this.isCancelQuerydata = true;
        this.commonService.isFilterFromNSSideBar = false;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.loading = false;
        this.loader = false;
        this.pageInstanceInfo = res.data;
        this.pageInstanceData = this.getPageInstanceInfo();
        this.showFilterCriteria(res.startTimeInDateFormat, res.endTimeInDateFormat);
        this.commonService.customTimePlaceHolder = [];
        this.commonService.customTimePlaceHolder.push(res.startTimeInDateFormat, res.endTimeInDateFormat);
        this.pageInstanceDataOrgi = this.pageInstanceData;
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
    }
    showFilterCriteria(startTimeInDateFormat, endTimeInDateFormat) {
        this.filterCriteria = '';
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        let pageInstance = this.commonService.nsPageInstance;
        this.filterCriteria += "TR=" + this.sessionService.session.testRun.id;
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL')
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC=" + (this._ddrData.dcName || 'Master');
        if (!this.commonService.isValidParamInObj(pageInstance, 'phaseName')) {
            if (startTimeInDateFormat != "NA" && startTimeInDateFormat != "" && startTimeInDateFormat != undefined && startTimeInDateFormat != "undefined")
                this.filterCriteria += ", From=" + startTimeInDateFormat;
            if (endTimeInDateFormat != "NA" && endTimeInDateFormat != "" && endTimeInDateFormat != undefined && endTimeInDateFormat != "undefined")
                this.filterCriteria += ", To=" + endTimeInDateFormat;
        }
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.pageName != "NA" && this.pageName != "" && this.pageName != undefined && this.pageName != "undefined")
            this.filterCriteria += ", Page=" + this.pageName;
        if (this.scriptName != "NA" && this.scriptName != "" && this.scriptName != undefined && this.scriptName != "undefined")
            this.filterCriteria += ", Script=" + this.scriptName;
        if (this.commonService.isValidParamInObj(pageInstance, 'scriptName'))
            this.filterCriteria += ", script=" + pageInstance.scriptName;
        if (this.commonService.isValidParamInObj(pageInstance, 'url')) {
            let url = pageInstance['url'];
            if (url && url.length >= 20) {
                this.toolTipUrl += pageInstance['url'];
                url = url.substring(0, 19);
                this.filterUrl += ", Url=" + url + " ....";
            }
            else
                this.filterUrl += ", Url=" + url; //substringed value
        }
        //this.filterCriteria += ", url=" + pageInstance.url;
        if (this.commonService.isValidParamInObj(pageInstance, 'transactionName'))
            this.filterCriteria += ", transactionName=" + pageInstance.transactionName;
        if (this.commonService.isValidParamInObj(pageInstance, 'page'))
            this.filterCriteria += ", page" + pageInstance.page;
        if (this.commonService.isValidParamInObj(pageInstance, 'location') && this._ddrData.WAN_ENV > 0)
            this.filterCriteria += ", location=" + pageInstance.location;
        if (this.commonService.isValidParamInObj(pageInstance, 'access') && this._ddrData.WAN_ENV > 0)
            this.filterCriteria += ", access=" + pageInstance.access;
        if (this.commonService.isValidParamInObj(pageInstance, 'browser'))
            this.filterCriteria += ", browser=" + pageInstance.browser;
        if (this.commonService.isValidParamInObj(pageInstance, 'group'))
            this.filterCriteria += ", group=" + pageInstance.group;
        if (this.commonService.isValidParamInObj(pageInstance, 'order'))
            this.filterCriteria += ", order=" + pageInstance.order;
        if (this.commonService.isValidParamInObj(pageInstance, 'statusName')) {
            let status = pageInstance['status'];
            if (status && status.length >= 20) {
                this.toolTipStatus += pageInstance['status'];
                status = status.substring(0, 19);
                this.filterStatus += ", Status=" + status + " ....";
            }
            else
                this.filterStatus += ", Status=" + status;
        }
        if (this.commonService.isValidParamInObj(pageInstance, 'phaseName'))
            this.filterCriteria += ", Phase Name=" + pageInstance.phaseName;
        //    this.filterCriteria += ", Status=" + pageInstance.statusName;
        if (this.filterCriteria.startsWith(','))
            this.filterCriteria = this.filterCriteria.substring(1);
        if (this.filterCriteria.endsWith(','))
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
    }
    getPageInstanceInfo() {
        let arr = [];
        for (let i = 0; i < this.pageInstanceInfo.length; i++) {
            arr[i] = { "pageName": this.pageInstanceInfo[i]['pageName'], "scriptName": this.pageInstanceInfo[i]['scriptName'], "location": this.pageInstanceInfo[i]['location'],
                "access": this.pageInstanceInfo[i]['access'], "userId": this.pageInstanceInfo[i]['childIndex'] + ':' + this.pageInstanceInfo[i]['userId'],
                "sessionId": this.pageInstanceInfo[i]['childIndex'] + ':' + this.pageInstanceInfo[i]['sessionId'], "startTime": this.pageInstanceInfo[i]['startTime'],
                "respTime": this.pageInstanceInfo[i]['respTime'], "status": this.pageInstanceInfo[i]['status'], "childIndex": this.pageInstanceInfo[i]['childIndex'],
                "pageInstance": this.pageInstanceInfo[i]['pageInstance'], "absoluteStartTime": this.pageInstanceInfo[i]['absoluteStartTime'] };
        }
        return arr;
    }
    getPageInstanceDataCount() {
        let isCount = true;
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        let ajaxParam = this.url + "&showCount=true" + '&productKey=' + this.sessionService.session.cctx.pk;
        this.ddrHttpService.getPageInstanceData(prefix, ajaxParam, isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__["PageInstanceLoadedState"]) {
                this.assignPageInstanceCount(state.data);
                isCount = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignPageInstanceCount(res) {
        this.totalCount = res.count;
        if (this.limit > this.totalCount)
            this.limit = Number(this.totalCount);
    }
    paginate(event) {
        this.offset = Number(event.first);
        this.limit = Number(event.rows);
        if (this.limit > this.totalCount) {
            this.limit = Number(this.totalCount);
        }
        this.loader = true;
        this.commonService.isFilterFromNSSideBar = true;
        this.getPageInstanceData();
    }
    openSessionName(nodeData) {
        // let projectSubProjName = nodeData['scriptName'].split("/")[0] + "/" + nodeData['scriptName'].split("/")[1];
        // this.scriptUtilService.sendEditScriptObj(projectSubProjName,nodeData['scriptName'].split("/")[2],'Edit',false);
        // this._router.navigate(['/script'], { relativeTo: this.route });
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_14__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    openSessionTimeDetail(nodeData) {
        this.nsCommonData.currRowData = nodeData;
        this.nsCommonData._sendAbsoluteTime = this.newMsToTimeFormat(nodeData.absoluteStartTime);
        let sessionId = nodeData.sessionId;
        this.nsCommonData.sesssionDuration = sessionId.substring(sessionId.indexOf(':') + 1, sessionId.length);
        this.nsCommonData.childIdx = nodeData.childIndex;
        this.nsCommonData.scriptName = nodeData.scriptName;
        this.nsCommonData.objectType = '1';
        this.nsCommonData.pageInstance = nodeData.pageInstance;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_INSTANCE;
        if (this.commonService.isFromPageFailure || this.commonService.isFromPageSummary || this.commonService.isFromPageSessionSummary) {
            this.commonService.nsSessionTiming = JSON.parse(JSON.stringify(this.commonService.nsPageInstance));
            this.commonService.isFromPageInstance = true;
        }
        this._router.navigate(['/ddr/nsreports/sessionTiming']);
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormat(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    newMsToTimeFormat(duration) {
        //console.log("duration inside the newMsToTimeFormat()=====  ", duration);
        if (!isNaN(duration)) {
            let duration1 = Number(duration);
            let timeInDateFormat;
            timeInDateFormat = this.sessionService.convertTimestampIntoFormattedString(duration1);
            //console.log("after conversion in TimeFormat inside the newMsToTimeFormat()=====  ", timeInDateFormat);
            return timeInDateFormat;
        }
        else {
            return duration;
        }
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    openUserSessionReport(nodeInfo) {
        if (this.commonService.isFromPageFailure || this.commonService.isFromPageSummary || this.commonService.isFromPageSessionSummary) {
            this.commonService.nsUserSession = JSON.parse(JSON.stringify(this.commonService.nsPageInstance));
            this.commonService.isFromPageInstance = true;
        }
        this.nsCommonData.currRowData = nodeInfo;
        this.nsCommonData.objectType = '1';
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].USER_SESSION;
        this.breadcrumb.add({ label: 'User Session', routerLink: '/ddr/nsreports/userSession' });
        this._router.navigate(['/ddr/nsreports/userSession']);
    }
    setTestRunHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm')
            this.strTitle = 'Page Instance Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 migration...
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Page Instance Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (NetCloud -) Due to A-9 migration..
        else
            this.strTitle = 'Netdiagnostics Enterprise - Page Instance Report - Session : ' + this.sessionService.session.testRun.id;
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.subscribePage.unsubscribe();
        this.commonService.isFromPageFailure = false;
        this.commonService.isFromPageSummary = false;
        this.commonService.isFromPageSessionSummary = false;
        this.commonService.isCQM = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.pageInstanceData = this.pageInstanceData.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.pageInstanceData = this.pageInstanceData.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.pageInstanceData = this.pageInstanceData.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.pageInstanceData = this.pageInstanceData.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.pageInstanceData = this.pageInstanceData.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.pageInstanceData = this.pageInstanceDataOrgi;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.pageInstanceData = this.pageInstanceDataOrgi;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
};
PageInstanceReportComponent.ctorParameters = () => [
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__["SessionService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["ActivatedRoute"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__["DDRRequestService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_12__["BreadcrumbService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_13__["ScriptUtilService"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_15__["DialogService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_17__["DDRHttpService"] }
];
PageInstanceReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-page-instance-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./page-instance-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./page-instance-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.scss")).default]
    })
], PageInstanceReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.scss":
/*!*************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.scss ***!
  \*************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-page-session-summary .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-page-session-summary .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-page-session-summary .group-left {\n  float: left;\n  padding-top: 4px;\n}\napp-page-session-summary .group-right {\n  float: right;\n  padding-top: 4px;\n}\napp-page-session-summary .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-page-session-summary .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.ts":
/*!***********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.ts ***!
  \***********************************************************************************************************************/
/*! exports provided: PageSessionSummaryComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PageSessionSummaryComponent", function() { return PageSessionSummaryComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var rxjs_Rx__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs/Rx */ "./node_modules/rxjs-compat/_esm2015/Rx.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");


















let PageSessionSummaryComponent = class PageSessionSummaryComponent {
    constructor(commonService, sessionService, _router, nsCommonData, breadcrumbService, route, _ddrData, ddrRequest, txService, ddrHttpService, scriptUtilService, dialogService) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this._router = _router;
        this.nsCommonData = nsCommonData;
        this.breadcrumbService = breadcrumbService;
        this.route = route;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.txService = txService;
        this.ddrHttpService = ddrHttpService;
        this.scriptUtilService = scriptUtilService;
        this.dialogService = dialogService;
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.limit = 50;
        this.offset = 0;
        this.filterCriteria = "";
        this.status = '';
        this.loading = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        this.errorData = "";
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.first.first = 0;
        this.rows.rows = 50;
        this.commonService.isBackButton = true;
        this.loading = true;
        this.randomNumber();
        this.pageSummaryByStatus = this.nsCommonData.isFromSummaryByStatus;
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.urlParam = this.commonService.getData();
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SESSION_SUMMARY);
        this.commonService.currentReport = "Page Session Summary";
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        this.makeColumns();
        this.setTestRunHeader();
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.getPageSessionSummaryData();
                this.getPageSessionSummaryDataCount();
            }
        });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { Due to A-9 migration..
        if (this.sessionService.preSession.multiDc === true) {
            this.urlParam.testRun = this.sessionService.session.testRun.id;
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    makeColumns() {
        if (this.pageSummaryByStatus == true) {
            this.relativePath = "ddr/page-session-summary/page-session-summary1.json";
        }
        else {
            this.relativePath = "ddr/page-session-summary/page-session-summary.json";
        }
        // if(this.pageSummaryByStatus == true)
        //   this.cols = this.cols.concat({ field: 'status', header: 'Status', sortable: true, action: true, align: 'right', width: '70', title : 'Status'});
        // else
        //   this.cols = this.cols.concat( { field: 'failPercent', header: 'Fail%', sortable: 'custom', action: true, align: 'right', width: '50', title : 'Fail%'});
        if (this.pageSummaryByStatus == true) {
            this.relativePath = "ddr/page-session-summary/page-session-summary1.json";
        }
        else {
            this.relativePath = "ddr/page-session-summary/page-session-summary.json";
        }
        // if(this.pageSummaryByStatus == true)
        //   this.cols = this.cols.concat({ field: 'status', header: 'Status', sortable: true, action: true, align: 'right', width: '70', title : 'Status'});
        // else
        //   this.cols = this.cols.concat( { field: 'failPercent', header: 'Fail%', sortable: 'custom', action: true, align: 'right', width: '50', title : 'Fail%'});
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Script Name') {
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        }
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'Tried') {
            if (this.pageSummaryByStatus == false) {
                me.openPageInstanceReport((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row, -2);
            }
            else {
                me.openPageInstanceReport((_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.row);
            }
        }
        if (((_j = (_h = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _h === void 0 ? void 0 : _h.columnClicked) === null || _j === void 0 ? void 0 : _j.label) == 'Success') {
            if (this.pageSummaryByStatus == false) {
                me.openPageInstanceReport((_k = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _k === void 0 ? void 0 : _k.row, 0);
            }
            else {
                me.openPageInstanceReport((_l = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _l === void 0 ? void 0 : _l.row);
            }
        }
        if (((_o = (_m = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _m === void 0 ? void 0 : _m.columnClicked) === null || _o === void 0 ? void 0 : _o.label) == 'Fail') {
            if (this.pageSummaryByStatus == false) {
                me.openPageFailureReport((_p = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _p === void 0 ? void 0 : _p.row);
            }
            else {
                me.openPageFailureReport((_q = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _q === void 0 ? void 0 : _q.row);
            }
        }
        if (((_s = (_r = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _r === void 0 ? void 0 : _r.columnClicked) === null || _s === void 0 ? void 0 : _s.label) == 'Average') {
            me.openPageComponentDetailReport((_t = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _t === void 0 ? void 0 : _t.row);
        }
    }
    getPageSessionSummaryData() {
        let ajaxParam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.pageSummaryByStatus == true)
            this.status = this.nsCommonData.pgSummaryToSessionSummaryData['statusCode'];
        else
            this.status = '-2';
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        ajaxParam += '&startTime=' + this.urlParam.startTime + '&endTime=' + this.urlParam.endTime + '&object=1&field=4095&summaryToSessionSummaryFlag='
            + this.nsCommonData.pgSummaryToSessionSummaryFlag + '&pageName=' + this.nsCommonData.pgSummaryToSessionSummaryData['pageName'] + '&status='
            + this.status + '&pageIndex=' + this.nsCommonData.pgSummaryToSessionSummaryData['pageIndex'] + '&summaryByStatusFlag='
            + this.pageSummaryByStatus;
        if (this.nsCommonData.pgSummaryToSessionSummaryFlag && this.pageSummaryByStatus == false)
            ajaxParam += "&group=session";
        else if (this.nsCommonData.pgSummaryToSessionSummaryFlag && this.pageSummaryByStatus)
            ajaxParam += "&group=status,session";
        if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            ajaxParam += '&groupName=' + this._ddrData.vectorName;
        if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxParam += '&generatorName=' + this._ddrData.generatorName;
        if (this.commonService.isFromPageSummary) {
            if (this.nsCommonData.pgSummaryToSessionSummaryFlag && this.pageSummaryByStatus == false)
                this.commonService.nsPageSessionSummary['group'] = 'session';
            else if (this.nsCommonData.pgSummaryToSessionSummaryFlag && this.pageSummaryByStatus)
                this.commonService.nsPageSessionSummary['group'] = 'status,session';
            ajaxParam += this.commonService.makeParamStringFromObjForNS(this.commonService.nsPageSessionSummary, true) +
                '&summaryToSessionSummaryFlag=' + this.nsCommonData.pgSummaryToSessionSummaryFlag + '&summaryByStatusFlag=' + this.pageSummaryByStatus;
            //setting value to key
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsPageSessionSummary;
        }
        else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
            this.commonService.isFromPageSummary = true;
            ajaxParam += this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true) +
                '&summaryToSessionSummaryFlag=' + this.nsCommonData.pgSummaryToSessionSummaryFlag + '&summaryByStatusFlag=' + this.pageSummaryByStatus;
        }
        // if ( this.pageSummaryByStatus && this.nsCommonData.pgSummaryToSessionSummaryFlag)
        //   ajaxParam += "&group=status";
        this.url = ajaxParam;
        ajaxParam += '&limit=' + this.limit + '&offset=' + this.offset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        // return this.ddrRequest.getDataUsingGet(finalUrl).subscribe(data => this.assignPageSessionSummaryData(data));
        this.ddrHttpService.getPageSummaryData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["PageSummaryLoadedState"]) {
                this.assignPageSessionSummaryData(state.data);
            }
        }, (error) => {
            console.error('Error loading NSUrlReport:', error);
        });
    }
    assignPageSessionSummaryData(res) {
        this.isCancelQuerydata = true;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.loading = false;
        this.loader = false;
        this.pageSessionSummaryData = res.data;
        if (this.pageSessionSummaryData.length == 0) {
            this.empty = false;
        }
        else
            this.showFilterCriteria(res.startTimeInDateFormat, res.endTimeInDateFormat);
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
    }
    getPageSessionSummaryDataCount() {
        let isCount = true;
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        let ajaxParam = this.url + "&showCount=true" + '&productKey=' + this.sessionService.session.cctx.pk;
        this.ddrHttpService.getPageSummaryData(prefix, ajaxParam, isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["PageSummaryLoadedState"]) {
                this.assignPageSessionSummaryDataCount(state.data);
                isCount = false;
            }
        }, (error) => {
            console.error('Error loading NSUrlReport:', error);
        });
    }
    assignPageSessionSummaryDataCount(res) {
        this.totalCount = res.count;
    }
    showFilterCriteria(startTimeInDateFormat, endTimeInDateFormat) {
        this.filterCriteria += "TR=" + this.sessionService.session.testRun.id;
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') //Due to A-9 migration..
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC=" + (this._ddrData.dcName || 'Master');
        if (startTimeInDateFormat != "NA" && startTimeInDateFormat != "" && startTimeInDateFormat != undefined && startTimeInDateFormat != "undefined")
            this.filterCriteria += ", From=" + startTimeInDateFormat;
        if (endTimeInDateFormat != "NA" && endTimeInDateFormat != "" && endTimeInDateFormat != undefined && endTimeInDateFormat != "undefined")
            this.filterCriteria += ", To=" + endTimeInDateFormat;
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.filterCriteria.startsWith(','))
            this.filterCriteria = this.filterCriteria.substring(1);
        if (this.filterCriteria.endsWith(','))
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
    }
    setTestRunHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm')
            this.strTitle = 'Page Session Summary Report - Test Run : ' + this.sessionService.session.testRun.id; //Removed (Netstorm -) due to A-9 migration...
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Page Session Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        else
            this.strTitle = 'Netdiagnostics Enterprise - Page Session Summary Report - Session : ' + this.sessionService.session.testRun.id;
    }
    openSessionName(nodeData) {
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_15__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    openPageFailureReport(nodeRow) {
        this._ddrData.nsCQMFilter["Page Failure"] = undefined;
        this.nsCommonData.pgSummaryToFailureData = nodeRow;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SESSION_SUMMARY;
        if (this.commonService.isFromPageSummary) {
            this.commonService.nsPageFailure = JSON.parse(JSON.stringify(this.commonService.nsPageSessionSummary));
            this.commonService.nsPageFailure['reportType'] = 'failure';
            if (this.commonService.nsPageFailure['status'] == -2 || this.commonService.nsPageFailure['status'] == -0) {
                this.commonService.nsPageFailure['status'] = -1;
            }
            this.commonService.nsPageFailure['pageName'] = this.nsCommonData.pgSummaryToFailureData['pageName'];
            this.commonService.nsPageFailure['objectId'] = this.nsCommonData.pgSummaryToFailureData['pageIndex'];
            if (!this.commonService.nsPageFailure['scriptName'])
                this.commonService.nsPageFailure['scriptName'] = this.nsCommonData.pgSummaryToFailureData['scriptName'];
            // this.scriptName = this.nsCommonData.pgSummaryToFailureData['scriptName'];
            delete this.commonService.nsPageFailure['transidx'];
            if (this.commonService.nsPageFailure['script']) {
                this.commonService.nsPageFailure['scriptName'] = this.commonService.nsPageFailure['script'];
                delete this.commonService.nsPageFailure['script'];
            }
            if (this.commonService.nsPageFailure['transactionName']) {
                this.commonService.nsPageFailure['trans'] = this.commonService.nsPageFailure['transactionName'];
                delete this.commonService.nsPageFailure['transactionName'];
            }
            delete this.commonService.nsPageFailure['location'];
            delete this.commonService.nsPageFailure['access'];
            delete this.commonService.nsPageFailure['browser'];
            delete this.commonService.nsPageFailure['fields'];
            delete this.commonService.nsPageFailure['transidx'];
            delete this.commonService.nsPageFailure['group'];
            delete this.commonService.nsPageFailure['order'];
            this.commonService.isFromPageSessionSummary = true;
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Page Failure');
        this._router.navigate(['/ddr/nsreports/PageFailure']);
    }
    openPageComponentDetailReport(row) {
        if (this.commonService.isFromPageSummary) {
            this.commonService.nsPageDetails = JSON.parse(JSON.stringify(this.commonService.nsPageSessionSummary));
            this.commonService.isFromPageSessionSummary = true;
        }
        this.nsCommonData.currRowData = row;
        this.nsCommonData.objectType = '1';
        this.nsCommonData.isFromSessionCompDetail = false;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SESSION_SUMMARY;
        this._router.navigate(['/ddr/nsreports/PageComponentDetail'], { queryParams: { pageSummaryByStatus: this.pageSummaryByStatus } });
    }
    openPageInstanceReport(nodeData, status) {
        this._ddrData.nsCQMFilter["Page Instance"] = undefined;
        let statusValue = '';
        if (this.pageSummaryByStatus == true)
            statusValue = nodeData.statusCode;
        else {
            // statusValue = status;
            this.nsCommonData.statuscode = status;
        }
        this.nsCommonData.pgSummaryToInstanceData = nodeData;
        //this.nsCommonData.pgSummaryToInstanceFlag = true;
        this._ddrData.pgSummaryToInstanceFlag = true;
        this._ddrData.pageFailure = false;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SESSION_SUMMARY;
        if (this.commonService.isFromPageSummary) {
            this.commonService.nsPageInstance = JSON.parse(JSON.stringify(this.commonService.nsPageSessionSummary));
            if (this.commonService.nsPageInstance['group'] && this.commonService.nsPageInstance['order'])
                this.commonService.nsPageInstance = this.commonService.filterGroupOrder(this.commonService.nsPageInstance);
            else
                delete this.commonService.nsPageInstance['group'];
            if (this._ddrData.pgSummaryToInstanceFlag == true) {
                this.commonService.nsPageInstance['pageName'] = this.nsCommonData.pgSummaryToInstanceData['pageName'];
                this.commonService.nsPageInstance['scriptName'] = this.nsCommonData.pgSummaryToInstanceData['scriptName'];
                this.commonService.nsPageInstance['pageIndex'] = this.nsCommonData.pgSummaryToInstanceData['pageIndex'];
                //(status is 0 for Success only, positive for the Failure code, -1 for all failures -2 for All (Success and all failures))
                //if(!(this.commonService.nsPageInstance['status']==-1 || this.commonService.nsPageInstance['status'].every(x=>x>0)))
                if (this.commonService.nsPageInstance['pageIndex'] == -2) { //i.e no status filter was applied.
                    if (status == '0' || status == '-2') {
                        this.commonService.nsPageInstance['status'] = status;
                    }
                }
                // ajaxParam += '&pageName=' + this.pageName + '&script=' + this.scriptName + "&pageIndex=" + this.nsCommonData.pgSummaryToInstanceData['pageIndex'];
            }
            this.commonService.isFromPageSessionSummary = true;
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Page Instance');
        //this._router.navigate(['/home/ddr/nsreports/PageInstance'],{queryParams:{ statusField : statusValue}});
        this._router.navigate(['/ddr/nsreports/PageInstance']);
    }
    paginate(event) {
        this.offset = Number(event.first);
        this.limit = Number(event.rows);
        if (this.limit > this.totalCount)
            this.limit = Number(this.totalCount);
        if ((this.limit + this.offset) > this.totalCount)
            this.limit = Number(this.totalCount) - Number(this.offset);
        this.loader = true;
        this.getPageSessionSummaryData();
    }
    // Formatter for large values coming as comma seperated
    formatter(data) {
        if (Number(data) && Number(data) > 0) {
            return Number(data).toLocaleString();
        }
        else {
            return data;
        }
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormat(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    ngOnDestroy() {
        this.commonService.isFromPageSummary = false;
        this.commonService.isBackButton = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
PageSessionSummaryComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_10__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["ActivatedRoute"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__["DDRRequestService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["DDRHttpService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_16__["ScriptUtilService"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_14__["DialogService"] }
];
PageSessionSummaryComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-page-session-summary',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./page-session-summary.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./page-session-summary.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.scss")).default]
    })
], PageSessionSummaryComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.scss":
/*!***********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.scss ***!
  \***********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-page-summary-report .ddr-accordion .ui-accordion-content-wrapper .ui-accordion-content {\n  padding: 5px;\n}\napp-page-summary-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-page-summary-report .colgroup-col col {\n  min-width: 120px !important;\n}\napp-page-summary-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-page-summary-report .group-left {\n  float: left;\n  padding-top: 4px;\n}\napp-page-summary-report .group-right {\n  float: right;\n  padding-top: 4px;\n}\napp-page-summary-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-page-summary-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.ts":
/*!*********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.ts ***!
  \*********************************************************************************************************************/
/*! exports provided: PageSummaryReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PageSummaryReportComponent", function() { return PageSummaryReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var rxjs_Rx__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs/Rx */ "./node_modules/rxjs-compat/_esm2015/Rx.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! rxjs */ "./node_modules/rxjs/_esm2015/index.js");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! src/app/pages/ddr/constants/ns-ddr-header.constants */ "./src/app/pages/ddr/constants/ns-ddr-header.constants.ts");

















let PageSummaryReportComponent = class PageSummaryReportComponent {
    constructor(commonService, sessionService, _router, nsCommonData, breadcrumbService, _ddrData, ddrRequest, txService, breadcrumb, ddrHttpService) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this._router = _router;
        this.nsCommonData = nsCommonData;
        this.breadcrumbService = breadcrumbService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.txService = txService;
        this.breadcrumb = breadcrumb;
        this.ddrHttpService = ddrHttpService;
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.limit = 50;
        this.offset = 0;
        this.filterCriteria = "";
        this.tableHeader = "";
        this.status = "";
        this.loading = false;
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        // public _message: Message;
        /*Observable for update message sources.*/
        this._messageObser = new rxjs__WEBPACK_IMPORTED_MODULE_10__["Subject"]();
        this.onFilter = false;
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.isDdrEnabled = true;
        this.errorData = "";
        this.colsForTable = [];
        let tableConfig = {
            "config": {
                "globalFilter": true,
                "download": true,
            }
        };
        this.tableConfig = tableConfig;
        this.colsForTable[0] = {
            "cols": [
                {
                    "label": "Page Name",
                    "key": "pageName",
                    "type": 0,
                    "width": "15%"
                },
                {
                    "label": "Tried",
                    "key": "tried",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Success",
                    "key": "success",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Fail",
                    "key": "fail",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Min",
                    "key": "min",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Max",
                    "key": "max",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Average",
                    "key": "avg",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "click": "true",
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Median",
                    "key": "median",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P80",
                    "key": "percent80",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P90",
                    "key": "percent90",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P95",
                    "key": "percent95",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P99",
                    "key": "percent99",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                }
            ]
        };
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = true;
        this.commonService.isBackButton = true;
        this.loading = true;
        this.first.first = 0;
        this.rows.rows = 50;
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.urlParam = this.commonService.getData();
        this.randomNumber();
        this.nsCommonData.isFromSummaryByStatus = this.pageSummaryByStatus;
        if (this.pageSummaryByStatus == true) {
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY_BY_STATUS);
            this.tableHeader = "Page Summary By Status";
        }
        else {
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY);
            this.tableHeader = "Page Summary";
        }
        this.commonService.currentReport = "Page Summary";
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        this.subscribePage = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Page Summary") {
                this.loading = true;
                this.limit = 50;
                this.offset = 0;
                this.getPageSummaryData();
                this.getPageSummaryDataCount();
                // this.makeColumns();
            }
        });
        this.setTestRunHeader();
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.getPageSummaryData();
                this.getPageSummaryDataCount();
                //this.makeColumns();
            }
        });
        this.makeColumns();
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        if (this.sessionService.preSession.multiDc === true) {
            this.urlParam.testRun = this.sessionService.session.testRun.id;
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Tried') {
            if (this.pageSummaryByStatus == false) {
                me.openPageInstanceReport((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row, -2);
            }
            else
                me.openPageInstanceReport((_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.row);
        }
        if (((_f = (_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.columnClicked) === null || _f === void 0 ? void 0 : _f.label) == 'Success') {
            if (this.pageSummaryByStatus == false && ((_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.row.success) !== '0') {
                me.openPageInstanceReport((_h = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _h === void 0 ? void 0 : _h.row, 0);
            }
            else
                me.openPageInstanceReport((_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.row);
        }
        if (((_l = (_k = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _k === void 0 ? void 0 : _k.columnClicked) === null || _l === void 0 ? void 0 : _l.label) == 'Fail') {
            if (this.pageSummaryByStatus == false && ((_m = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _m === void 0 ? void 0 : _m.row.fail) !== '0') {
                me.openPageFailureReport((_o = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _o === void 0 ? void 0 : _o.row);
            }
            else
                me.openPageInstanceReport((_p = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _p === void 0 ? void 0 : _p.row);
        }
        if (((_r = (_q = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _q === void 0 ? void 0 : _q.columnClicked) === null || _r === void 0 ? void 0 : _r.label) == 'Average') {
            me.openPageComponentDetailReport((_s = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _s === void 0 ? void 0 : _s.row);
        }
        if (((_u = (_t = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _t === void 0 ? void 0 : _t.columnClicked) === null || _u === void 0 ? void 0 : _u.label) == 'Script Count') {
            me.openPageSessionSummaryReport((_v = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _v === void 0 ? void 0 : _v.row);
        }
    }
    makeColumns() {
        if (this.commonService.nsPageSummary['group'] && this.commonService.nsPageSummary['group'].indexOf('status') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Status",
                "key": "status",
                "type": 0,
                "width": "7%",
            });
        }
        else {
            this.colsForTable[0].cols.push({
                "label": "%Fail",
                "key": "failPercent",
                "type": 1,
                "width": "7%",
            });
        }
        if (this.commonService.nsPageSummary['group'] && this.commonService.nsPageSummary['group'].indexOf('generator') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Generator Name",
                "key": "generatorName",
                "type": 0,
                "width": "7%",
                "click": "true"
            });
        }
        if (this.commonService.nsPageSummary['group'] && this.commonService.nsPageSummary['group'].indexOf('transaction') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Transaction Name",
                "key": "transactionName",
                "type": 0,
                "width": "7%",
                "click": "true"
            });
        }
        if (this.commonService.nsPageSummary['group'] && this.commonService.nsPageSummary['group'].indexOf('session') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Script Name",
                "key": "scriptName",
                "type": 0,
                "width": "7%",
                "click": "true"
            });
        }
        else {
            this.colsForTable[0].cols.push({
                "label": "Script Count",
                "key": "scriptCount",
                "type": 1,
                "width": "7%",
                "click": "true"
            });
        }
    }
    getPageSummaryData() {
        let ajaxParam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        if (this.commonService.isFilterFromNSSideBar && Object.keys(this.commonService.nsPageSummary).length != 0) {
            if (this.pageSummaryByStatus) {
                let group = [];
                group = this.commonService.nsPageSummary['group'];
                if (group[0] == '' || group[0] == undefined) {
                    group[0] = 'status';
                }
                this.commonService.nsPageSummary['group'] = group;
            }
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsPageSummary, true);
            this.commonService.isCQM = true; //for summary to store filter cqm in breadcrumb case.
            // for FIlter CQM case    so that will update value in key pair.
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsPageSummary;
        }
        else {
            ajaxParam += '&startTime=' + this.urlParam.startTime + '&endTime=' + this.urlParam.endTime + '&status=-2&object=1&field=4095&summaryByStatusFlag='
                + this.pageSummaryByStatus + '&summaryToSessionSummaryFlag=false';
            if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this._ddrData.vectorName;
            if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this._ddrData.generatorName;
            if (this._ddrData.nsErrorName) {
                ajaxParam += '&nsErrorName=' + this._ddrData.nsErrorName;
            }
            if (this.pageSummaryByStatus === true) {
                ajaxParam += '&group=status';
            }
        }
        if (this.commonService.isCQM) {
            ajaxParam = this.commonService.checkAndReturnUniqueParams(ajaxParam, this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLSummary, true));
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsPageSummary;
        }
        this.commonService.nsPageSummary = this.commonService.makeObjectFromUrlParam(ajaxParam);
        this.url = ajaxParam;
        ajaxParam += '&limit=' + this.limit + '&offset=' + this.offset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        this.ddrHttpService.getPageSummaryData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["PageSummaryLoadedState"]) {
                this.assignPageSummaryData(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignPageSummaryData(res) {
        this.isCancelQuerydata = true;
        this.commonService.isFilterFromNSSideBar = false;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.loading = false;
        this.loader = false;
        this.pageSummaryData = res.data;
        if (this.pageSummaryData.length == 0) {
            this.empty = false;
        }
        this.showFilterCriteria(res.startTimeInDateFormat, res.endTimeInDateFormat);
        this.commonService.customTimePlaceHolder = [];
        this.commonService.customTimePlaceHolder.push(res.startTimeInDateFormat, res.endTimeInDateFormat);
        this.pageSummaryDataOrgi = this.pageSummaryData;
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
    }
    getPageSummaryDataCount() {
        let isCount = true;
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        let ajaxParam = this.url + "&showCount=true" + '&productKey=' + this.sessionService.session.cctx.pk;
        this.ddrHttpService.getPageSummaryData(prefix, ajaxParam, isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["PageSummaryLoadedState"]) {
                this.assignPageSummaryDataCount(state.data);
                isCount = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignPageSummaryDataCount(res) {
        this.totalCount = res.count;
        if (this.limit > this.totalCount)
            this.limit = Number(this.totalCount);
    }
    showFilterCriteria(startTimeInDateFormat, endTimeInDateFormat) {
        this.filterCriteria = '';
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        let pageSummary = this.commonService.nsPageSummary;
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC=" + (this._ddrData.dcName || 'Master');
        if (!this.commonService.isValidParamInObj(pageSummary, 'phaseName')) {
            if (startTimeInDateFormat != "NA" && startTimeInDateFormat != "" && startTimeInDateFormat != undefined && startTimeInDateFormat != "undefined")
                this.filterCriteria += ", From=" + startTimeInDateFormat;
            if (endTimeInDateFormat != "NA" && endTimeInDateFormat != "" && endTimeInDateFormat != undefined && endTimeInDateFormat != "undefined")
                this.filterCriteria += ", To=" + endTimeInDateFormat;
        }
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.commonService.isValidParamInObj(pageSummary, 'script'))
            this.filterCriteria += ", script=" + pageSummary.script;
        if (this.commonService.isValidParamInObj(pageSummary, 'url')) {
            let url = pageSummary['url'];
            if (url && url.length >= 20) {
                this.toolTipUrl += pageSummary['url'];
                url = url.substring(0, 19);
                this.filterUrl += ", Url=" + url + " ....";
            }
            else
                this.filterUrl += ", Url=" + url;
        }
        if (this.commonService.isValidParamInObj(pageSummary, 'phaseName'))
            this.filterCriteria += ", Phase Name=" + pageSummary.phaseName;
        if (this.commonService.isValidParamInObj(pageSummary, 'transactionName'))
            this.filterCriteria += ", transactionName=" + pageSummary.transactionName;
        if (this.commonService.isValidParamInObj(pageSummary, 'page'))
            this.filterCriteria += ", page" + pageSummary.page;
        if (this.commonService.isValidParamInObj(pageSummary, 'location'))
            this.filterCriteria += ", location=" + pageSummary.location;
        if (this.commonService.isValidParamInObj(pageSummary, 'access'))
            this.filterCriteria += ", access=" + pageSummary.access;
        if (this.commonService.isValidParamInObj(pageSummary, 'browser'))
            this.filterCriteria += ", browser=" + pageSummary.browser;
        if (this.commonService.isValidParamInObj(pageSummary, 'group'))
            this.filterCriteria += ", group=" + pageSummary.group;
        if (this.commonService.isValidParamInObj(pageSummary, 'order'))
            this.filterCriteria += ", order=" + pageSummary.order;
        if (this.commonService.isValidParamInObj(pageSummary, 'statusName')) {
            let status = pageSummary['statusName'];
            if (status && status.length >= 20) {
                this.toolTipStatus += pageSummary['statusName'];
                status = status.substring(0, 19);
                this.filterStatus += ", Status=" + status + " ....";
            }
            else
                this.filterStatus += ", Status=" + status;
        }
        if (this.filterCriteria.startsWith(','))
            this.filterCriteria = this.filterCriteria.substring(1);
        if (this.filterCriteria.endsWith(','))
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
    }
    openPageInstanceReport(nodeData, status) {
        this._ddrData.nsCQMFilter["Page Instance"] = undefined;
        let statusValue = '';
        if (this.pageSummaryByStatus == true) {
            statusValue = nodeData.statusCode;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY_BY_STATUS;
        }
        else {
            statusValue = status;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY;
        }
        this.nsCommonData.statuscode = statusValue;
        this.nsCommonData.pgSummaryToInstanceData = nodeData;
        this._ddrData.pgSummaryToInstanceFlag = true;
        this._ddrData.pageFailure = false;
        if (this.commonService.isCQM) {
            this.commonService.nsPageInstance = JSON.parse(JSON.stringify(this.commonService.nsPageSummary));
            if (this.commonService.nsPageInstance['group'] && this.commonService.nsPageInstance['order'])
                this.commonService.nsPageInstance = this.commonService.filterGroupOrder(this.commonService.nsPageInstance);
            else
                delete this.commonService.nsPageInstance['group'];
            if (this._ddrData.pgSummaryToInstanceFlag == true) {
                this.commonService.nsPageInstance['pageName'] = this.nsCommonData.pgSummaryToInstanceData['pageName'];
                this.commonService.nsPageInstance['scriptName'] = this.nsCommonData.pgSummaryToInstanceData['scriptName'];
                this.commonService.nsPageInstance['pageIndex'] = this.nsCommonData.pgSummaryToInstanceData['pageIndex'];
            }
            this.commonService.isFromPageSummary = true;
            if (nodeData['status'] != undefined && nodeData['status'] != "-" && nodeData['status'] != "NA") //works incase of group by status
             {
                this.commonService.nsPageInstance['status'] = nodeData['statusCode'];
            }
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Page Instance');
        this.commonService.isFilterFromNSSideBar = false;
        this._router.navigate(['/ddr/nsreports/PageInstance']);
    }
    openPageSessionSummaryReport(nodeInfo) {
        this._ddrData.nsCQMFilter["Page Session Summary"] = undefined;
        this.nsCommonData.pgSummaryToSessionSummaryData = nodeInfo;
        this.nsCommonData.pgSummaryToSessionSummaryFlag = true;
        if (this.pageSummaryByStatus == true)
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY_BY_STATUS;
        else
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY;
        if (this.commonService.isCQM) {
            this.commonService.nsPageSessionSummary = JSON.parse(JSON.stringify(this.commonService.nsPageSummary));
            this.commonService.nsPageSessionSummary['pageName'] = this.nsCommonData.pgSummaryToSessionSummaryData['pageName'];
            this.commonService.nsPageSessionSummary['pageIndex'] = this.nsCommonData.pgSummaryToSessionSummaryData['pageIndex'];
            this.commonService.isFromPageSummary = true;
            if (nodeInfo['status'] != "-") {
                this.commonService.nsPageSessionSummary['status'] = nodeInfo['statusCode'];
            }
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Page Session Summary');
        this._router.navigate(['/ddr/nsreports/PageSessionSummary']);
    }
    openPageFailureReport(nodeRow) {
        this._ddrData.nsCQMFilter["Page Failure"] = undefined;
        this.nsCommonData.pgSummaryToFailureData = nodeRow;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY;
        if (this.commonService.isCQM) {
            this.commonService.nsPageFailure = JSON.parse(JSON.stringify(this.commonService.nsPageSummary));
            if (!this.commonService.nsPageFailure['pageName']) {
                this.commonService.nsPageFailure['objectId'] = this.nsCommonData.pgSummaryToFailureData['pageIndex'];
                this.commonService.nsPageFailure['pageName'] = this.nsCommonData.pgSummaryToFailureData['pageName'];
            }
            else {
                this.commonService.nsPageFailure['objectId'] = this.commonService.nsPageFailure['pageIndex'];
                delete this.commonService.nsPageFailure['pageIndex'];
            }
            if (!this.commonService.nsPageFailure['scriptName'])
                this.commonService.nsPageFailure['scriptName'] = this.nsCommonData.pgSummaryToFailureData['scriptName'];
            delete this.commonService.nsPageFailure['transidx'];
            if (this.commonService.nsPageFailure['script']) {
                this.commonService.nsPageFailure['scriptName'] = this.commonService.nsPageFailure['script'];
                delete this.commonService.nsPageFailure['script'];
            }
            if (this.commonService.nsPageFailure['transactionName']) {
                this.commonService.nsPageFailure['trans'] = this.commonService.nsPageFailure['transactionName'];
                delete this.commonService.nsPageFailure['transactionName'];
            }
            this.commonService.nsPageFailure['reportType'] = 'failure';
            if (this.commonService.nsPageFailure['status'] == -2 || this.commonService.nsPageFailure['status'] == -0) {
                this.commonService.nsPageFailure['status'] = -1;
            }
            delete this.commonService.nsPageFailure['location'];
            delete this.commonService.nsPageFailure['access'];
            delete this.commonService.nsPageFailure['browser'];
            delete this.commonService.nsPageFailure['fields'];
            delete this.commonService.nsPageFailure['transidx'];
            delete this.commonService.nsPageFailure['group'];
            delete this.commonService.nsPageFailure['order'];
            this.commonService.isFromPageSummary = true;
            if (nodeRow['status'] != "-") {
                this.commonService.nsPageFailure['status'] = nodeRow['statusCode'];
            }
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Page Failure');
        this._router.navigate(['/ddr/nsreports/PageFailure']);
    }
    openPageComponentDetailReport(row) {
        if (this.commonService.isCQM) {
            //handeleing the required object fields in the page comp details itself and not here.
            this.commonService.nsPageDetails = JSON.parse(JSON.stringify(this.commonService.nsPageSummary));
            this.commonService.isFromPageSummary = true;
        }
        this.nsCommonData.currRowData = row;
        this.nsCommonData.objectType = '1';
        this.nsCommonData.isFromSessionCompDetail = false;
        if (this.pageSummaryByStatus == true)
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY_BY_STATUS;
        else
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].PAGE_SUMMARY;
        this._router.navigate(['/ddr/nsreports/PageComponentDetail'], { queryParams: { pageSummaryByStatus: this.pageSummaryByStatus } });
    }
    paginate(event) {
        this.offset = Number(event.first);
        this.limit = Number(event.rows);
        this.loader = true;
        this.getProgressBar();
        if (this.limit > this.totalCount)
            this.limit = Number(this.totalCount);
        if ((this.limit + this.offset) > this.totalCount)
            this.limit = Number(this.totalCount) - Number(this.offset);
        this.commonService.isFilterFromNSSideBar = true;
        this.getPageSummaryData();
    }
    /** Method for progressbar */
    getProgressBar() {
        this.value = 1;
        let interval = setInterval(() => {
            this.value = this.value + Math.floor(Math.random() * 10) + 1;
            if (this.value >= 100) {
                this.value = 100;
                clearInterval(interval);
            }
        }, 300);
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormat(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    setTestRunHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm') {
            if (this.pageSummaryByStatus == true)
                this.strTitle = 'Page Summary By Status Report - Test Run : ' + this.sessionService.session.testRun.id; //Removed (Netstorm -) due to A-9 migration...
            else
                this.strTitle = 'Page Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud') {
            if (this.pageSummaryByStatus == true)
                this.strTitle = 'Page Summary By Status Report - Test Run : ' + this.sessionService.session.testRun.id;
            else
                this.strTitle = 'Page Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else {
            if (this.pageSummaryByStatus == true)
                this.strTitle = 'Netdiagnostics Enterprise - Page Summary By Status Report - Session : ' + this.sessionService.session.testRun.id;
            else
                this.strTitle = 'Netdiagnostics Enterprise - Page Summary Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.subscribePage.unsubscribe();
        this.commonService.isCQM = false;
        this.commonService.isToLoadSideBar = false;
        this.commonService.isBackButton = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.pageSummaryData = this.pageSummaryData.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.pageSummaryData = this.pageSummaryData.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.pageSummaryData = this.pageSummaryData.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.pageSummaryData = this.pageSummaryData.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.pageSummaryData = this.pageSummaryData.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.pageSummaryData = this.pageSummaryDataOrgi;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.pageSummaryData = this.pageSummaryDataOrgi;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
};
PageSummaryReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_11__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__["DDRRequestService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_12__["TransactionDetailService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_13__["BreadcrumbService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_15__["DDRHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])("summaryByStatus")
], PageSummaryReportComponent.prototype, "pageSummaryByStatus", void 0);
PageSummaryReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-page-summary-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./page-summary-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./page-summary-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.scss")).default]
    })
], PageSummaryReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-reports.component.scss":
/*!***************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-reports.component.scss ***!
  \***************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-reports.component.ts":
/*!*************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-reports.component.ts ***!
  \*************************************************************************/
/*! exports provided: NsReportsComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NsReportsComponent", function() { return NsReportsComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/pages/tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/shared/time-bar/service/time-bar.service */ "./src/app/shared/time-bar/service/time-bar.service.ts");





let NsReportsComponent = class NsReportsComponent {
    constructor(route, ddrDataModelService, timebarService) {
        this.route = route;
        this.ddrDataModelService = ddrDataModelService;
        this.timebarService = timebarService;
        this.sessionReport = false;
        this.urlReport = false;
        this.pageReport = false;
        this.transactionReport = false;
        this.userSessionReport = false;
    }
    loadComponent() {
        this.sub = this.route.params.subscribe(params => {
            this.id = params['id'];
            if (this.id.startsWith('session')) {
                this.userSessionReport = false;
                this.urlReport = false;
                this.pageReport = false;
                this.transactionReport = false;
                this.sessionReport = true;
            }
            else if (this.id.startsWith('url')) {
                this.pageReport = false;
                this.transactionReport = false;
                this.userSessionReport = false;
                this.sessionReport = false;
                this.urlReport = true;
            }
            else if (this.id.startsWith('Page')) {
                this.urlReport = false;
                this.transactionReport = false;
                this.userSessionReport = false;
                this.sessionReport = false;
                this.pageReport = true;
            }
            else if (this.id.startsWith('Transaction')) {
                this.urlReport = false;
                this.pageReport = false;
                this.userSessionReport = false;
                this.sessionReport = false;
                this.transactionReport = true;
            }
            else if (this.id.startsWith('user')) {
                this.urlReport = false;
                this.pageReport = false;
                this.sessionReport = false;
                this.transactionReport = false;
                this.userSessionReport = true;
            }
        });
    }
    ngOnInit() {
        this.ddrDataModelService.dcName = "";
        this.ddrDataModelService.startTime = this.timebarService.getValue().time.frameStart.value.toString();
        this.ddrDataModelService.endTime = this.timebarService.getValue().time.frameEnd.value.toString();
        this.loadComponent();
    }
    ngOnDestroy() {
        if (this.sub)
            this.sub.unsubscribe();
    }
    ngOnChanges() {
        this.loadComponent();
    }
};
NsReportsComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["ActivatedRoute"] },
    { type: src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__["DdrDataModelService"] },
    { type: src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_4__["TimebarService"] }
];
NsReportsComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'ns-reports',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ns-reports.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-reports.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ns-reports.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-reports.component.scss")).default]
    })
], NsReportsComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.scss":
/*!****************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.scss ***!
  \****************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.ts":
/*!**************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.ts ***!
  \**************************************************************************************************/
/*! exports provided: NsSessionReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NsSessionReportComponent", function() { return NsSessionReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_pages_ddr_services_common_services__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/pages/ddr/services/common.services */ "./src/app/pages/ddr/services/common.services.ts");







let NsSessionReportComponent = class NsSessionReportComponent {
    constructor(breadcrumbService, nsCommonData, breadcrumb, commonServices) {
        this.breadcrumbService = breadcrumbService;
        this.nsCommonData = nsCommonData;
        this.breadcrumb = breadcrumb;
        this.commonServices = commonServices;
        this.instanceReport = false;
        this.summaryReport = false;
        this.sessionFailure = false;
        this.sessionDetail = false;
        this.sessionTiming = false;
        this.summaryReportByStatus = false;
    }
    ngOnDestroy() {
        console.log('ng On Destroy is called');
        this.instanceReport = false;
        this.summaryReport = false;
        this.sessionFailure = false;
        this.sessionDetail = false;
        this.sessionTiming = false;
    }
    ngOnChanges() {
        this.loadComponent();
    }
    ngOnInit() {
        console.log('*** input ', this.id);
        this.loadComponent();
    }
    loadComponent() {
        console.log('*** loadComponent ', this.id);
        if (this.id === 'sessionInstance') {
            this.breadcrumb.addNewBreadcrumb({ label: 'Session Instance', routerLink: '/ddr/nsreports/sessionInstance' }); // Due to A-9 migration....
            this.summaryReport = false;
            this.sessionDetail = false;
            this.sessionTiming = false;
            this.sessionFailure = false;
            this.instanceReport = true;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].SESSION_INSTANCE);
        }
        else if (this.id === 'sessionSummary') {
            this.breadcrumb.addNewBreadcrumb({ label: 'Session Summary', routerLink: '/ddr/nsreports/sessionSummary' }); // Due to A-9 migration....
            this.summaryReportByStatus = false;
            this.sessionTiming = false;
            this.sessionFailure = false;
            this.sessionDetail = false;
            this.instanceReport = false;
            this.summaryReport = true;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].SESSION_SUMMARY);
        }
        else if (this.id === 'sessionStatus') {
            this.breadcrumb.addNewBreadcrumb({ label: 'Session Status', routerLink: '/ddr/nsreports/sessionStatus' }); // Due to A-9 migration....
            this.sessionFailure = false;
            this.instanceReport = false;
            this.sessionTiming = false;
            this.sessionDetail = false;
            this.summaryReportByStatus = true; // use for Constructing query for SessionSummary by status report
            this.summaryReport = true;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].SESSION_STATUS);
        }
        else if (this.id === 'sessionFailure') {
            this.breadcrumb.addNewBreadcrumb({ label: 'Session Failure', routerLink: '/ddr/nsreports/sessionFailure' }); // Due to A-9 migration....
            this.summaryReport = false;
            this.instanceReport = false;
            this.sessionDetail = false;
            this.sessionTiming = false;
            this.sessionFailure = true;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].SESSION_FAILURE);
        }
        else if (this.id === 'sessionDetail') {
            this.breadcrumb.addNewBreadcrumb({ label: 'Session Details', routerLink: '/ddr/nsreports/sessionDetail' }); // Due to A-9 migration....
            this.summaryReport = false;
            this.instanceReport = false;
            this.sessionFailure = false;
            this.sessionTiming = false;
            this.sessionDetail = true;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].SESSION_DETAIL);
        }
        else if (this.id === 'sessionTiming') {
            /**
             * use for Setting Breadcumb Name
             */
            if (this.nsCommonData.objectType === '0')
                this.breadcrumbService.nsReportName = 'URL';
            else if (this.nsCommonData.objectType === '1')
                this.breadcrumbService.nsReportName = 'Page';
            else if (this.nsCommonData.objectType === '2')
                this.breadcrumbService.nsReportName = 'Transaction';
            else
                this.breadcrumbService.nsReportName = 'Session';
            let currentReport = this.breadcrumbService.nsReportName + " Timing Details";
            this.breadcrumb.addNewBreadcrumb({ label: currentReport, routerLink: '/ddr/nsreports/sessionTiming' }); // Due to A-9 migration....
            this.summaryReport = false;
            this.instanceReport = false;
            this.sessionFailure = false;
            this.sessionDetail = false;
            this.sessionTiming = true;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].SESSION_TIMING);
        }
    }
};
NsSessionReportComponent.ctorParameters = () => [
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__["DdrBreadcrumbService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__["NsCommonService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["BreadcrumbService"] },
    { type: src_app_pages_ddr_services_common_services__WEBPACK_IMPORTED_MODULE_6__["CommonServices"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], NsSessionReportComponent.prototype, "id", void 0);
NsSessionReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'ns-session-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ns-session-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ns-session-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.scss")).default]
    })
], NsSessionReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.scss":
/*!******************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.scss ***!
  \******************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\n\n.group-left {\n  float: left;\n  padding-top: 4px;\n}\n\n.group-right {\n  float: right;\n  padding-top: 4px;\n}\n\n.no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\n\n.no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.ts":
/*!****************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.ts ***!
  \****************************************************************************************************************************/
/*! exports provided: SessionDetailReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SessionDetailReportComponent", function() { return SessionDetailReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_11__);
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");




// import { CavConfigService } from '../../../../../../main/services/cav-config.service';
// import { CavTopPanelNavigationService } from '../../../../../../main/services/cav-top-panel-navigation.service';










let SessionDetailReportComponent = class SessionDetailReportComponent {
    constructor(commonService, sessionService, _router, nsCommonData, breadcrumbService, _ddrData, ddrRequest, breadcrumb, ddrHttpService) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this._router = _router;
        this.nsCommonData = nsCommonData;
        this.breadcrumbService = breadcrumbService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.breadcrumb = breadcrumb;
        this.ddrHttpService = ddrHttpService;
        this.thinkData = [];
        this.filterCriteria = '';
        this.loading = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.cols = [];
        this.colsPageTable = [
            { field: 'pageName', action: true },
            { field: 'avgPageResp', action: true },
            { field: 'avgPageRespPercent', action: true },
        ];
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_11__;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.pageDetailPath = "ddr/session-detail-report/session-detail-report.json";
        this.thinkDataPath = "ddr/session-detail-report/session-detail-report1.json";
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.commonService.isBackButton = true;
        this.commonService.currentReport = 'Session Details';
        this.loading = true;
        this.randomNumber();
        this.id = this.commonService.getData();
        if (!this.nsCommonData.avgTime)
            this.nsCommonData.avgTime = sessionStorage.getItem("avgTime");
        this.average = this.nsCommonData.avgTime + "(hh:mm:ss.ms)";
        sessionStorage.removeItem("avgTime");
        sessionStorage.setItem("avgTime", this.nsCommonData.avgTime);
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.getSessionDetailData();
            }
        });
        // this.thinkData.push({'avgHeader':'Think Duration','average':this.average,'percent':this.percentThink+'%'});
    }
    clickButtonEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == "Avg Page Response Time") {
            me.openPageReport(event.cavEventExt.row);
        }
    }
    getSessionDetailData() {
        if (!this.nsCommonData.currRowData || typeof this.nsCommonData.currRowData == "object")
            this.nsCommonData.scriptName = sessionStorage.getItem("scriptName");
        else
            this.nsCommonData.scriptName = this.nsCommonData.currRowData;
        let ajaxParam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        ajaxParam += '&startTime=' + this.id.startTime + '&endTime=' + this.id.endTime +
            '&objectType=3&status=-2&scriptName=' + this.nsCommonData.scriptName;
        if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            ajaxParam += '&groupName=' + this._ddrData.vectorName;
        if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxParam += '&generatorName=' + this._ddrData.generatorName;
        ajaxParam += '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        sessionStorage.removeItem("scriptName");
        sessionStorage.setItem("scriptName", this.nsCommonData.scriptName);
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        this.ddrHttpService.getSessionDetailData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["SessionDetailLoadedState"]) {
                this.doAssignValues(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Due to A-9 migration..
        if (this.sessionService.preSession.multiDc === true) {
            this.id.testRun = this.sessionService.session.testRun.id;
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    doAssignValues(res) {
        this.isCancelQuerydata = true;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.data = res.data;
        if (this.data.length == 0) {
            this.empty = true;
        }
        this.loading = false;
        this.thinkTime = res.thinkTime;
        this.percentThink = res.percentThink;
        setTimeout(() => {
            this.loading = false;
        }, 2000);
        this.createPieChart(this.data, this.thinkTime);
        this.showfilterCriteria(res.strStartTime, res.strEndTime);
        this.cols = [
            { field: 'avgHeader', action: true },
            { field: 'average', action: true },
            { field: 'percent', action: true }
        ];
        this.thinkData = this.Immutablepush(this.thinkData, { 'avgHeader': 'Think Duration', 'average': this.msToTimeFormate(this.thinkTime) + "(hh:mm:ss.ms)", 'percent': this.percentThink + '%' });
    }
    createPieChart(data, time) {
        this.chartData = data;
        var dataArr = [];
        var barArr = [];
        dataArr.push({ "name": "Think Time", "y": Number(this.thinkTime), "color": "#f4720e" });
        for (let i = 0; i < this.chartData.length; i++) {
            dataArr.push({ "name": this.chartData[i]["pageName"], "y": Number(this.chartData[i]["avgPageResp"]) });
            barArr.push({ "name": this.chartData[i]["pageName"], "data": [Number(this.chartData[i]["avgPageResp"]) / 1000] });
        }
        barArr.push({ "name": "Think Time", "data": [Number(this.thinkTime) / 1000], "color": "#f4720e" });
        this.options = {
            exporting: {
                enabled: false
            },
            chart: {
                type: "pie"
            },
            credits: {
                enabled: false
            },
            title: {
                text: "Session Detail Report",
            },
            legend: {
                itemWidth: 100
            },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.2f}%</b>'
            },
            plotOptions: {
                pie: {
                    allowPointSelect: true,
                    cursor: 'pointer',
                    dataLabels: {
                        enabled: true,
                        format: '<b>{point.name}</b>= {point.percentage:.2f} %'
                    },
                    showInLegend: true
                }
            },
            series: [
                {
                    name: "Percentage",
                    data: dataArr,
                    enableMouseTracking: true
                }
            ]
        };
        // split time chart
        this.options1 = {
            exporting: {
                enabled: false
            },
            chart: {
                type: 'bar'
            },
            title: {
                text: 'Time Split Chart (Seconds)'
            },
            xAxis: {
                categories: ['Time']
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Total Time Consumption'
                }
            },
            credits: {
                enabled: false
            },
            legend: {
                showInLegend: true
            },
            plotOptions: {
                series: {
                    stacking: 'normal'
                }
            },
            series: barArr
        };
    }
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    openPageReport(rowData) {
        this.nsCommonData.currRowData = rowData;
        this.nsCommonData.objectType = '3';
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].SESSION_DETAIL;
        this._router.navigate(['/ddr/nsreports/PageComponentDetail']);
    }
    showfilterCriteria(startTime, endTime, status) {
        this.filterCriteria = "";
        if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL')
            this.filterCriteria += "DC=" + (this._ddrData.dcName || 'Master');
        if (this.nsCommonData.isSuccess)
            this.filterCriteria += ', Session Status= ' + this.nsCommonData.isSuccess;
        if (this._ddrData.startTimeInDateFormat) {
            this.filterCriteria += ', From=' + this._ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined)
            this.filterCriteria += ', From=' + startTime;
        if (this._ddrData.endTimeInDateFormat) {
            this.filterCriteria += ', To=' + this._ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined)
            this.filterCriteria += ', To=' + endTime;
        if (this.nsCommonData.scriptName)
            this.filterCriteria += ', Script= ' + this.nsCommonData.scriptName;
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.filterCriteria.trim().startsWith(',')) {
            this.filterCriteria = this.filterCriteria.trim().substring(1);
        }
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.id.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    ngOnDestroy() {
        this.commonService.isBackButton = false;
    }
};
SessionDetailReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__["NsCommonService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["DDRHttpService"] }
];
SessionDetailReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'session-detail-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./session-detail-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./session-detail-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.scss")).default]
    })
], SessionDetailReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.scss":
/*!********************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.scss ***!
  \********************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("session-failure-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\nsession-failure-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\nsession-failure-report .ddr-graphpanel .highcharts-container .highcharts-contextbutton {\n  display: none !important;\n}\nsession-failure-report .group-left {\n  float: left;\n  padding-top: 4px;\n}\nsession-failure-report .group-right {\n  float: right;\n  padding-top: 4px;\n}\nsession-failure-report .highcharts-legend-item {\n  pointer-events: none;\n}\nsession-failure-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\nsession-failure-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.ts":
/*!******************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.ts ***!
  \******************************************************************************************************************************/
/*! exports provided: SessionFailureReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SessionFailureReportComponent", function() { return SessionFailureReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");



//import { CavTopPanelNavigationService } from '../../../../../../main/services/cav-top-panel-navigation.service';



//import { DdrDataModelService } from '../../../../../../main/services/ddr-data-model.service';







let SessionFailureReportComponent = class SessionFailureReportComponent {
    constructor(commonService, sessionService, _router, nsCommonData, breadcrumbService, ddrData, _ddrData, ddrRequest, ddrHttpService) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this._router = _router;
        this.nsCommonData = nsCommonData;
        this.breadcrumbService = breadcrumbService;
        this.ddrData = ddrData;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_10__;
        this.filterCriteria = "";
        this.loading = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.relativePath = "/ddr/session-failure-report/session-failure-report.json";
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.isBackButton = true;
        this.id = this.commonService.getData();
        this.commonService.currentReport = 'Session Failure';
        this.randomNumber();
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        console.log("this.commonservice.nssessionFailure==>", this.commonService.nsSessionFailure);
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.fillFailureData();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) == "clickable") {
            me.openInstanceReport(event.cavEventExt.row);
        }
    }
    fillFailureData() {
        try {
            this.getSessionFailureData();
            this.setTestRunInHeader();
        }
        catch (error) {
            console.log('error in intialization compaonent --> ', error);
        }
    }
    getSessionFailureData() {
        if (!this.nsCommonData.currRowData)
            this.nsCommonData.currRowData = JSON.parse(sessionStorage.getItem("currRowData"));
        if (!this.nsCommonData.failureType)
            this.nsCommonData.failureType = sessionStorage.getItem("failureType");
        let url = '';
        let ajaxparam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.commonService.enableQueryCaching == 1) {
            ajaxparam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxparam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        ajaxparam += '&startTime=' + this.id.startTime + '&endTime=' + this.id.endTime +
            '&objectType=3&status=-1&scriptName=' + this.nsCommonData.currRowData["scriptName"] +
            '&objectId=' + this.nsCommonData.failureType;
        if (this._ddrData.nsErrorName) {
            ajaxparam += '&nsErrorName=' + this._ddrData.nsErrorName;
        }
        if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            ajaxparam += '&groupName=' + this._ddrData.vectorName;
        if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxparam += '&generatorName=' + this._ddrData.generatorName;
        if (this.commonService.isFromSessionSummary) {
            console.log("is from session summary to failure===>", this.commonService.nsSessionFailure);
            ajaxparam += this.commonService.makeParamStringFromObjForNS(this.commonService.nsSessionFailure, true);
            //setting value to key
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsSessionFailure;
            console.log("this._ddrData.nsCQMFilter in data call==>", this._ddrData.nsCQMFilter);
        }
        else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
            this.commonService.isFromSessionSummary = true;
            console.log("inside else cond===> ", this._ddrData.nsCQMFilter[this.commonService.currentReport]);
            ajaxparam += this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true);
        }
        url += ajaxparam;
        console.log("FINAL URL ==>", url);
        sessionStorage.removeItem("failureType");
        sessionStorage.removeItem("currRowData");
        sessionStorage.setItem("currRowData", JSON.stringify(this.nsCommonData.currRowData));
        sessionStorage.setItem("failureType", this.nsCommonData.failureType);
        ajaxparam += '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        this.ddrHttpService.getSessionFailureData(prefix, ajaxparam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["SessionFailureLoadedState"]) {
                this.doAssignValues(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Commented for A9 Migration
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.id.testRun = this.sessionService.session.testRun.id;
            console.log("all case url==>", hostDcName, "all case test run==>", this.id.testRun, '-----  ', this.sessionService.session.testRun.id);
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    doAssignValues(res) {
        console.log('Session summary Data ', res);
        this.isCancelQuerydata = true;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.data = res.data;
        this.createStackedChart(this.data);
        setTimeout(() => {
            this.loading = false;
        }, 2000);
        this.totalFailure = this.nsCommonData.currRowData.fail;
        this.showfilterCriteria(res.starStartTime, res.strEndTime);
    }
    showfilterCriteria(startTime, endTime, status) {
        this.filterCriteria = "";
        this.failureFilter = "";
        this.toolTipStatus = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Commented for A9 Migration
        if (this.sessionService.preSession.multiDc === true) {
            this.filterCriteria += "DC=" + (this._ddrData.dcName || 'Master') + ',';
        }
        //    this.filterCriteria += ' Session Status= All Failures';
        if (this.commonService.nsSessionFailure && this.commonService.nsSessionFailure['statusName']) {
            let status = this.commonService.nsSessionFailure['statusName'];
            if (status && status.length >= 20) {
                this.toolTipStatus = status;
                status = status.substring(0, 19);
                this.failureFilter += ", Session Status=" + status + " ....";
            }
            else
                this.failureFilter += ', Session Status=' + status;
        }
        else if (this._ddrData.nsErrorName) {
            this.failureFilter += ' Session Status= ' + this._ddrData.nsErrorName;
        }
        else {
            this.failureFilter += ' Session Status= All Failures';
        }
        if (this.ddrData.startTimeInDateFormat) {
            this.filterCriteria += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined)
            this.filterCriteria += ', From=' + startTime;
        if (this.ddrData.endTimeInDateFormat) {
            this.filterCriteria += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined)
            this.filterCriteria += ', To=' + endTime;
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
    }
    createStackedChart(res) {
        this.chartData = res;
        var errArr = [];
        // alert(this.chartData);
        for (let i = 0; i < this.chartData.length; i++) {
            console.log(this.chartData[i]["failureType"]);
            var errName = this.chartData[i]["status"];
            errArr.push({ "name": errName, "data": [Number(this.chartData[i]["numberOfFailure"])] });
        }
        console.log('this.errArr******* ', errArr);
        this.options = {
            chart: {
                type: 'column'
            },
            credits: {
                enabled: false
            },
            title: {
                text: 'Failure Detail Report For Session'
            },
            xAxis: {
                categories: ['Number of Failures']
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Number of Failures'
                },
                stackLabels: {
                    enabled: true
                }
            },
            plotOptions: {
                column: {
                    stacking: 'normal',
                    pointWidth: 50
                }
            },
            series: errArr
        };
    }
    openInstanceReport(nodeData, flag) {
        this.nsCommonData.isFromSummary = true;
        this._ddrData.nsCQMFilter["Session Instance"] = undefined;
        // console.log("nodeData>>>>>>>-------"+JSON.stringify(nodeData));
        this.nsCommonData.scriptName = this.nsCommonData.currRowData["scriptName"];
        if (flag == 'totalCount')
            this.nsCommonData.sessionIndex = '-1';
        else
            this.nsCommonData.sessionIndex = nodeData.failureType;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__["BREADCRUMB_ITEMS"].SESSION_FAILURE;
        console.log("node data in failure==>", nodeData);
        //failure type is actualy error code.
        if (this.commonService.isFromSessionSummary) {
            console.log("session failure obj==>", this.commonService.nsSessionFailure);
            this.commonService.nsSessionInstance = JSON.parse(JSON.stringify(this.commonService.nsSessionFailure));
            this.commonService.nsSessionInstance['wanEnv'] = 'NA';
            if (this.commonService.nsSessionInstance['script']) {
                this.commonService.nsSessionInstance['scriptName'] = this.commonService.nsSessionInstance['script'];
                if (!this.commonService.nsSessionInstance.scriptName) //incase no filter for script has been provided.
                 {
                    this.commonService.nsSessionInstance['scriptName'] = this.nsCommonData.scriptName;
                    this.commonService.nsSessionInstance['scriptidx'] = this.nsCommonData.currRowData['sessionIndex'];
                }
            }
            this.commonService.nsSessionInstance['strStatus'] = nodeData.failureType;
            delete this.commonService.nsSessionInstance['status'];
            delete this.commonService.nsSessionInstance['objectType'];
            delete this.commonService.nsSessionInstance['strGroupBy'];
            this.commonService.isFromSessionFailure = true;
            console.log("going out of failure to instance==>", this.commonService.nsSessionInstance);
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Session Instance');
        this._router.navigate(["/ddr/nsreports/sessionInstance"]);
    }
    setTestRunInHeader() {
        if (this.id && this.id.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'Session Failure Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
        }
        else if (this.id && this.id.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Session Failure Report - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - Session Failure Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    ngOnDestroy() {
        this.commonService.isFromSessionSummary = false;
        this.commonService.isBackButton = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.id.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        console.log("Hello u got that", url);
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
SessionFailureReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["DDRHttpService"] }
];
SessionFailureReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'session-failure-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./session-failure-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./session-failure-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.scss")).default]
    })
], SessionFailureReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.scss":
/*!**********************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.scss ***!
  \**********************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("session-instance-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\nsession-instance-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\nsession-instance-report .group-left {\n  float: left;\n  padding-top: 4px;\n}\nsession-instance-report .group-right {\n  float: right;\n  padding-top: 4px;\n}\nsession-instance-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\nsession-instance-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.ts":
/*!********************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.ts ***!
  \********************************************************************************************************************************/
/*! exports provided: SessionInstanceReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SessionInstanceReportComponent", function() { return SessionInstanceReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");

















let SessionInstanceReportComponent = class SessionInstanceReportComponent {
    constructor(commonService, sessionService, _router, ddrdata, nsCommonData, breadcrumbService, _ddrData, ddrRequest, txService, breadcrumb, scriptUtilService, route, dialogService, ddrHttpService) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this._router = _router;
        this.ddrdata = ddrdata;
        this.nsCommonData = nsCommonData;
        this.breadcrumbService = breadcrumbService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.txService = txService;
        this.breadcrumb = breadcrumb;
        this.scriptUtilService = scriptUtilService;
        this.route = route;
        this.dialogService = dialogService;
        this.ddrHttpService = ddrHttpService;
        this.filterCriteria = "";
        this.isFromSummary = false;
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.limit = 50;
        this.offset = 0;
        this.showCount = false;
        this.loading = false;
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.relativePath = 'ddr/session-instance-report/session-instance-report3.json';
        this.isCount = false;
    }
    ngOnInit() {
        this.loading = true;
        this.id = this.commonService.getData();
        this.first.first = 0;
        this.rows.rows = 50;
        if (this.ddrdata.summaryToInstanceFlag === 'true')
            this.nsCommonData.isFromSummary = true;
        else if (this.ddrdata.summaryToInstanceFlag === 'false')
            this.nsCommonData.isFromSummary = false;
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.isFromSummary = this.nsCommonData.isFromSummary;
        this.randomNumber();
        this.commonService.currentReport = "Session Instance";
        this.commonService.isToLoadSideBar = true;
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        this.subscribeSession = this.commonService.sideBarUI$.subscribe((temp) => {
            if (this.commonService.currentReport == "Session Instance") {
                this.loading = true;
                this.limit = 50;
                this.offset = 0;
                let event = [];
                event['first'] = this.offset;
                event['rows'] = this.limit;
                this.paginate(event);
                this.getSessionInstanceData();
                this.makeTableColumns();
            }
        });
        this.makeTableColumns();
        this.setTestRunInHeader();
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.getSessionInstanceData();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Script Name')
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'User Id')
            me.openUserSessionReport((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row);
        if (((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label) == 'Session Duration')
            me.openSessionDetailReport((_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.row);
    }
    makeTableColumns() {
        if (this._ddrData.WAN_ENV > 0 && !this.sessionService.session.testRun.cmt) {
            this.relativePath = 'ddr/session-instance-report/session-instance-report.json';
        }
        else if (this._ddrData.WAN_ENV > 0 && this.sessionService.session.testRun.cmt) {
            this.relativePath = 'ddr/session-instance-report/session-instance-report1.json';
        }
        else if (!(this._ddrData.WAN_ENV > 0) && !this.sessionService.session.testRun.cmt) {
            this.relativePath = 'ddr/session-instance-report/session-instance-report2.json';
        }
        else {
            this.relativePath = 'ddr/session-instance-report/session-instance-report3.json';
        }
    }
    newMsToTimeFormat(duration) {
        if (!isNaN(duration)) {
            let duration1 = Number(duration);
            let timeInDateFormat;
            timeInDateFormat = this.sessionService.convertTimestampIntoFormattedString(duration1);
            return timeInDateFormat;
        }
        else {
            return duration;
        }
    }
    getSessionInstanceData() {
        let ajaxParam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (!this.totalCount)
            this.showCount = true;
        else
            this.showCount = undefined;
        // let url = '';
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        if (this.commonService.isFilterFromNSSideBar && Object.keys(this.commonService.nsSessionInstance).length != 0) {
            if (this.nsCommonData.isFromSummary) {
                this.commonService.nsSessionInstance['scriptName'] = this.nsCommonData.currRowData['scriptName'];
                this.commonService.nsSessionInstance['scriptidx'] = this.nsCommonData.currRowData['sessionIndex'];
            }
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsSessionInstance;
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsSessionInstance, true);
            ajaxParam += '&showCount=' + true;
            // this._ddrData.startTime = this.commonService.nsSessionInstance['startTime'];
            // this._ddrData.endTime = this.commonService.nsSessionInstance['endTime']; commented for bug id:69498
        }
        else {
            ajaxParam += '&startTime=' + this.id.startTime + '&endTime=' + this.id.endTime;
            // alert('this.nsCommonData.isFromSummary '+this.nsCommonData.isFromSummary);
            this._ddrData.startTime = this.id.startTime;
            this._ddrData.endTime = this.id.endTime;
            // if(this._ddrData.groupName=="Session"  && this._ddrData.vectorName!='undefined'&& this._ddrData.vectorName!=undefined )
            // ajaxParam += '&script=' + this._ddrData.vectorName;
            if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this._ddrData.vectorName;
            if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this._ddrData.generatorName;
            if (this._ddrData.fromReport) {
                ajaxParam += '&nsErrorName=' + this._ddrData.errorNameSession;
            }
            else if (this._ddrData.nsErrorName) {
                ajaxParam += '&nsErrorName=' + this._ddrData.nsErrorName;
            }
            if (this.nsCommonData.isFromSummary) {
                ajaxParam += '&wanEnv=' + this._ddrData.WAN_ENV + '&scriptName=' + this.nsCommonData.currRowData['scriptName'] /* this.nsCommonData.scriptName */ + '&strStatus=' + this.nsCommonData.sessionIndex + '&scriptidx=' + this.nsCommonData.currRowData['sessionIndex'];
            }
            else
                ajaxParam += '&wanEnv=' + this._ddrData.WAN_ENV;
            //this.commonService.nsSessionInstance=this.commonService.makeObjectFromUrlParam(ajaxParam);
            if (this.nsCommonData.FailureStatus != undefined && this.ddrdata.summaryToInstanceFlag == 'true')
                ajaxParam += '&statusCode=' + this.nsCommonData.FailureStatus;
            else if (this.nsCommonData.sessionInstancethroughsuccess)
                ajaxParam += '&statusCode=0';
            else if (this._ddrData.strStatus == 0) {
                ajaxParam += '&statusCode=' + this._ddrData.strStatus;
            }
            else if (this._ddrData.filtermode.toLowerCase() == "success") {
                ajaxParam += '&statusCode=0';
            }
            else if (this._ddrData.filtermode.toLowerCase() == "failure") {
                ajaxParam += '&statusCode=-1';
            }
            else {
                ajaxParam += '&statusCode=-2';
            }
        }
        if (this.commonService.isFromSessionSummary || this.commonService.isFromSessionFailure) {
            ajaxParam = this.commonService.checkAndReturnUniqueParams(ajaxParam, this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLSummary, true));
            //setting value to key
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsSessionInstance;
        }
        else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
            this.commonService.isFromSessionSummary = true;
            this.commonService.isFromSessionFailure = true;
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true);
        }
        this.commonService.nsSessionInstance = this.commonService.makeObjectFromUrlParam(ajaxParam);
        ajaxParam += '&limit=' + this.limit + '&offset=' + this.offset + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        if (!ajaxParam.includes("&showCount")) {
            ajaxParam += '&showCount=' + this.showCount;
            this.isCount = true;
        }
        // this.makeTableColumns();
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        // this.ddrRequest.getDataUsingGet(ajaxParam).subscribe(data => (this.doAssignValues(data)));
        this.ddrHttpService.getSessionInstanceData(prefix, ajaxParam, this.isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__["SessionInstanceLoadedState"]) {
                this.doAssignValues(state.data);
                this.isCount = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    doAssignValues(res) {
        this.isCancelQuerydata = true;
        this.commonService.isFilterFromNSSideBar = false;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        if (res.hasOwnProperty('count')) {
            this.totalCount = res.count;
            if (this.limit > this.totalCount)
                this.limit = Number(this.totalCount);
        }
        this.data = res.data;
        if (!this.data) {
            this.loading = false;
            this.empty = true;
            this.loader = false;
            return;
        }
        else {
            setTimeout(() => {
                this.loading = false;
                this.loader = false;
            }, 1000);
        }
        if (this.nsCommonData.isFromSummary)
            this.showfilterCriteria(res.strStartTime, res.strEndTime, res.data[0].status);
        else
            this.showfilterCriteria(res.strStartTime, res.strEndTime);
        this.commonService.customTimePlaceHolder = [];
        this.commonService.customTimePlaceHolder.push(res.strStartTime, res.strEndTime);
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Commented for A9 Migration
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.id.testRun = this.sessionService.session.testRun.id;
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    paginate(event) {
        // event.first = Index of the first record  (used  as offset in query)
        // event.rows = Number of rows to display in new page  (used as limit in query)
        // event.page = Index of the new page
        // event.pageCount = Total number of pages
        this.commonService.rowspaerpage = event.rows;
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        if (this.limit > this.totalCount)
            this.limit = Number(this.totalCount);
        this.loader = true;
        // this.commonService.isFilterFromNSSideBar = true;
        this.getSessionInstanceData();
    }
    showfilterCriteria(startTime, endTime, status) {
        this.filterCriteria = "";
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        let sessionInstance = this.commonService.nsSessionInstance;
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') // Commented for A9 Migartion
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC=" + (this._ddrData.dcName || 'Master');
        if (this.nsCommonData.isSuccess)
            this.filterCriteria += ', Session Status= ' + this.nsCommonData.isSuccess;
        if (!this.commonService.isValidParamInObj(sessionInstance, 'phaseName')) {
            if (this._ddrData.startTimeInDateFormat) {
                this.filterCriteria += ', From=' + this._ddrData.startTimeInDateFormat;
            }
            else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined)
                this.filterCriteria += ', From=' + startTime;
            if (this._ddrData.endTimeInDateFormat) {
                this.filterCriteria += ', To=' + this._ddrData.endTimeInDateFormat;
            }
            else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined)
                this.filterCriteria += ', To=' + endTime;
        }
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.nsCommonData.isFromSummary)
            this.filterCriteria += ', Script= ' + this.nsCommonData.currRowData["scriptName"];
        if (this.commonService.isValidParamInObj(sessionInstance, 'script'))
            this.filterCriteria += ", script=" + sessionInstance.script;
        if (this.commonService.isValidParamInObj(sessionInstance, 'url')) {
            let url = sessionInstance['url'];
            if (url && url.length >= 20) {
                this.toolTipUrl += "Url= " + sessionInstance['url'];
                url = url.substring(0, 19);
                this.filterUrl += ", url=" + url + " ....";
            }
            else
                this.filterUrl += ", url=" + url;
        }
        //this.filterCriteria += ", url=" + sessionInstance.url;
        if (this.commonService.isValidParamInObj(sessionInstance, 'transactionName'))
            this.filterCriteria += ", transactionName=" + sessionInstance.transactionName;
        if (this.commonService.isValidParamInObj(sessionInstance, 'page'))
            this.filterCriteria += ", page" + sessionInstance.page;
        if (this.commonService.isValidParamInObj(sessionInstance, 'location'))
            this.filterCriteria += ", location=" + sessionInstance.location;
        if (this.commonService.isValidParamInObj(sessionInstance, 'access'))
            this.filterCriteria += ", access=" + sessionInstance.access;
        if (this.commonService.isValidParamInObj(sessionInstance, 'browser'))
            this.filterCriteria += ", browser=" + sessionInstance.browser;
        if (this.commonService.isValidParamInObj(sessionInstance, 'group'))
            this.filterCriteria += ", group=" + sessionInstance.group;
        if (this.commonService.isValidParamInObj(sessionInstance, 'order'))
            this.filterCriteria += ", order=" + sessionInstance.order;
        if (this.commonService.isValidParamInObj(sessionInstance, 'strStatus')) {
            let status = sessionInstance['strStatus'];
            if (status && status.length >= 20) {
                this.toolTipStatus += "Status= " + sessionInstance['strStatus'];
                status = status.substring(0, 19);
                this.filterStatus += ", Status=" + status + " ....";
            }
            else
                this.filterStatus += ", Status=" + status;
        }
        if (this.commonService.isValidParamInObj(sessionInstance, 'phaseName'))
            this.filterCriteria += ", Phase Name=" + sessionInstance.phaseName;
        //   this.filterCriteria += ", Status=" + sessionInstance.strStatus
        if (this.filterCriteria.trim().startsWith(',')) {
            this.filterCriteria = this.filterCriteria.trim().substring(1);
        }
    }
    openSessionDetailReport(nodeData) {
        this.nsCommonData.currRowData = nodeData;
        this.nsCommonData._sendAbsoluteTime = this.newMsToTimeFormat(nodeData.absstarttime);
        this.nsCommonData.objectType = '3';
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_INSTANCE;
        this._router.navigate(['/ddr/nsreports/sessionTiming']);
    }
    openUserSessionReport(nodeData) {
        this.nsCommonData.currRowData = nodeData;
        this.nsCommonData.objectType = '3';
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_INSTANCE;
        if (this.commonService.isFromSessionFailure || this.commonService.isFromSessionSummary) {
            this.commonService.nsUserSession = JSON.parse(JSON.stringify(this.commonService.nsSessionInstance));
            this.commonService.isFromSessionInstance = true;
        }
        this.breadcrumb.add({ label: 'User Session', routerLink: '/ddr/nsreports/userSession' });
        this._router.navigate(['/ddr/nsreports/userSession']);
    }
    openSessionName(nodeData) {
        // let projectSubProjName = nodeData.split("/")[0] + "/" + nodeData.split("/")[1];
        // this.scriptUtilService.sendEditScriptObj(projectSubProjName,nodeData.split("/")[2],'Edit',false);
        // this._router.navigate(['/script'], { relativeTo: this.route });
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_13__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' }
        });
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    setTestRunInHeader() {
        if (this.id && this.id.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'Session Instance Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
        }
        else if (this.id && this.id.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Session Instance Report - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - Session Instance Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.subscribeSession.unsubscribe();
        this.commonService.isToLoadSideBar = false;
        this.commonService.isFromSessionFailure = false;
        this.commonService.isFromSessionSummary = false;
        this.nsCommonData.isFromSummary = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.id.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
SessionInstanceReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__["NsCommonService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_10__["TransactionDetailService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_11__["BreadcrumbService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__["ScriptUtilService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["ActivatedRoute"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_14__["DialogService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_16__["DDRHttpService"] }
];
SessionInstanceReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'session-instance-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./session-instance-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./session-instance-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.scss")).default]
    })
], SessionInstanceReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.scss":
/*!********************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.scss ***!
  \********************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("session-summary-report .colgroup-col col {\n  min-width: 120px !important;\n}\nsession-summary-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\nsession-summary-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\nsession-summary-report .group-left {\n  float: left;\n  padding-top: 4px;\n}\nsession-summary-report .group-right {\n  float: right;\n  padding-top: 4px;\n}\nsession-summary-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\nsession-summary-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.ts":
/*!******************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.ts ***!
  \******************************************************************************************************************************/
/*! exports provided: SessionSummaryReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SessionSummaryReportComponent", function() { return SessionSummaryReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! rxjs */ "./node_modules/rxjs/_esm2015/index.js");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! src/app/pages/ddr/constants/ns-ddr-header.constants */ "./src/app/pages/ddr/constants/ns-ddr-header.constants.ts");


















let SessionSummaryReportComponent = class SessionSummaryReportComponent {
    constructor(commonService, sessionService, _router, nsCommonData, breadcrumbService, _ddrData, ddrRequest, txService, scriptUtilService, route, dialogService, ddrHttpService) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this._router = _router;
        this.nsCommonData = nsCommonData;
        this.breadcrumbService = breadcrumbService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.txService = txService;
        this.scriptUtilService = scriptUtilService;
        this.route = route;
        this.dialogService = dialogService;
        this.ddrHttpService = ddrHttpService;
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.limit = 50;
        this.offset = 0;
        this.commonUrl = '';
        this.filterCriteria = "";
        this.loading = false;
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.onFilter = false;
        /*Observable for update message sources.*/
        this._messageObser = new rxjs__WEBPACK_IMPORTED_MODULE_10__["Subject"]();
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.isDdrEnabled = true;
        this.errorData = "";
        this.colsForTable = [];
        let tableConfig = {
            "config": {
                "globalFilter": true,
                "download": true,
            }
        };
        this.tableConfig = tableConfig;
        this.colsForTable[0] = {
            "cols": [
                {
                    "label": "Script Name",
                    "key": "scriptName",
                    "type": 0,
                    "width": "15%",
                    "click": "true"
                },
                {
                    "label": "Tried",
                    "key": "tried",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Success",
                    "key": "success",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Fail",
                    "key": "fail",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Min",
                    "key": "min",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Max",
                    "key": "max",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Average",
                    "key": "average",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].DURATION_DATA_TYPE,
                    "click": "true",
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Median",
                    "key": "median",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P80",
                    "key": "percent80",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P90",
                    "key": "percent90",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P95",
                    "key": "percent95",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P99",
                    "key": "percent99",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_17__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                }
            ]
        };
    }
    ngOnInit() {
        this.loading = true;
        this.first.first = 0;
        this.rows.rows = 50;
        this.id = this.commonService.getData();
        if (this.summaryReportByStatus)
            this.strGroupBy = 'status';
        this.commonService.currentReport = "Session Summary";
        this.randomNumber();
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.commonService.isToLoadSideBar = true;
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        this.subscribeSession = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Session Summary") {
                this.loading = true;
                this.getSessionSummaryData();
                //this.makeTableColumns();
            }
        });
        this.setTestRunInHeader();
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.getSessionSummaryData();
                //this.makeTableColumns();
            }
        });
        this.makeTableColumns();
    }
    getSessionSummaryData() {
        let ajaxParam = '';
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        if (this.commonService.isFilterFromNSSideBar && Object.keys(this.commonService.nsSessionSummary).length != 0) {
            if (this.summaryReportByStatus) {
                let group = [];
                group = this.commonService.nsSessionSummary['strGroupBy'];
                if (group[0] == '' || group[0] == undefined) {
                    group[0] = 'status';
                }
                this.commonService.nsSessionSummary['strGroupBy'] = group;
            }
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsSessionSummary, true);
            this.commonService.isCQM = true; //for summary to store filter cqm in breadcrumb case.
            // for FIlter CQM case    so that will update value in key pair.
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsSessionSummary;
        }
        else {
            ajaxParam += '&startTime=' + this.id.startTime + '&endTime=' + this.id.endTime +
                '&userName=' + this._ddrData.userName +
                '&strGroupBy=' + this.strGroupBy +
                '&status=-2';
            if (this._ddrData.nsErrorName) {
                ajaxParam += '&nsErrorName=' + this._ddrData.nsErrorName;
            }
            if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this._ddrData.vectorName;
            if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this._ddrData.generatorName;
        }
        if (this.commonService.isCQM) {
            ajaxParam = this.commonService.checkAndReturnUniqueParams(ajaxParam, this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLSummary, true));
            this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsSessionSummary;
        }
        this.commonService.nsSessionSummary = this.commonService.makeObjectFromUrlParam(ajaxParam);
        this.commonUrl = ajaxParam;
        ajaxParam += '&limit=' + this.limit + '&offset=' + this.offset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
        this.ddrHttpService.getSessionSummaryData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__["SessionSummaryLoadedState"]) {
                this.doAssignValues(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    doAssignValues(res) {
        this.isCancelQuerydata = true;
        this.commonService.isFilterFromNSSideBar = false;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.data = res.data;
        if (!this.data) {
            this.loading = false;
            this.loader = false;
            this.empty = false;
            return;
        }
        else {
            setTimeout(() => {
                this.loading = false;
                this.loader = false;
            }, 1000);
        }
        this.showfilterCriteria(res.strStartTime, res.strEndTime);
        this.commonService.customTimePlaceHolder = [];
        this.commonService.customTimePlaceHolder.push(res.strStartTime, res.strEndTime);
        this.makeajaxcallCount();
        this.dataOrig = this.data;
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        if (this.sessionService.preSession.multiDc === true) {
            this.id.testRun = this.sessionService.session.testRun.id;
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Tried') {
            me.openInstanceReport((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        }
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'Success' && ((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row.success) !== '0') {
            me.openInstanceReport((_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.row, 'Success');
        }
        if (((_j = (_h = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _h === void 0 ? void 0 : _h.columnClicked) === null || _j === void 0 ? void 0 : _j.label) == 'Fail' && ((_k = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _k === void 0 ? void 0 : _k.row.fail) !== '0') {
            me.openFailureReport((_l = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _l === void 0 ? void 0 : _l.row);
        }
        if (((_o = (_m = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _m === void 0 ? void 0 : _m.columnClicked) === null || _o === void 0 ? void 0 : _o.label) == 'Average') {
            me.openSessionDetailReport((_p = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _p === void 0 ? void 0 : _p.row);
        }
        if (((_r = (_q = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _q === void 0 ? void 0 : _q.columnClicked) === null || _r === void 0 ? void 0 : _r.label) == 'Script Name') {
            me.openSessionName((_s = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _s === void 0 ? void 0 : _s.row);
        }
    }
    makeTableColumns() {
        if (this.commonService.nsSessionSummary['strGroupBy'] && this.commonService.nsSessionSummary['strGroupBy'].indexOf('status') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Status",
                "key": "statusName",
                "type": 0
            });
        }
        else {
            this.colsForTable[0].cols.push({
                "label": "%Fail",
                "key": "percentFail",
                "type": 1
            });
        }
        if (this.commonService.nsSessionSummary['strGroupBy'] && this.commonService.nsSessionSummary['strGroupBy'].indexOf('generator') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Generator Name",
                "key": "generatorName",
                "type": 0
            });
        }
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    showfilterCriteria(startTime, endTime) {
        this.filterCriteria = '';
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        let sessionParam = this.commonService.nsSessionSummary;
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC=" + (this._ddrData.dcName || 'Master');
        if (!this.commonService.isValidParamInObj(sessionParam, 'phaseName')) {
            if (this._ddrData.startTimeInDateFormat) {
                this.filterCriteria += ', From=' + this._ddrData.startTimeInDateFormat;
            }
            else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
                this.filterCriteria += ', From=' + startTime;
            }
            if (this._ddrData.endTimeInDateFormat) {
                this.filterCriteria += ', To=' + this._ddrData.endTimeInDateFormat;
            }
            else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
                this.filterCriteria += ', To=' + endTime;
            }
        }
        if (this._ddrData.generatorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.commonService.isValidParamInObj(sessionParam, 'script'))
            this.filterCriteria += ", script=" + sessionParam.script;
        if (this.commonService.isValidParamInObj(sessionParam, 'url')) {
            let url = sessionParam['url'];
            if (url && url.length >= 20) {
                this.toolTipUrl += "Url= " + sessionParam['url'];
                url = url.substring(0, 19);
                this.filterUrl += ", url=" + url + " ....";
            }
            else
                this.filterUrl += ", url=" + url;
        }
        if (this.commonService.isValidParamInObj(sessionParam, 'transactionName'))
            this.filterCriteria += ", transactionName=" + sessionParam.transactionName;
        if (this.commonService.isValidParamInObj(sessionParam, 'page'))
            this.filterCriteria += ", page" + sessionParam.page;
        if (this.commonService.isValidParamInObj(sessionParam, 'location'))
            this.filterCriteria += ", location=" + sessionParam.location;
        if (this.commonService.isValidParamInObj(sessionParam, 'access'))
            this.filterCriteria += ", access=" + sessionParam.access;
        if (this.commonService.isValidParamInObj(sessionParam, 'browser'))
            this.filterCriteria += ", browser=" + sessionParam.browser;
        if (this.commonService.isValidParamInObj(sessionParam, 'strGroupBy'))
            this.filterCriteria += ", group=" + sessionParam.strGroupBy;
        if (this.commonService.isValidParamInObj(sessionParam, 'order'))
            this.filterCriteria += ", order=" + sessionParam.order;
        if (this.commonService.isValidParamInObj(sessionParam, 'statusName')) {
            let status = sessionParam['statusName'];
            if (status && status.length >= 20) {
                this.toolTipStatus += "Status= " + sessionParam['statusName'];
                status = status.substring(0, 19);
                this.filterStatus += ", Status=" + status + " ....";
            }
            else
                this.filterStatus += ", Status=" + status;
        }
        if (this.commonService.isValidParamInObj(sessionParam, 'phaseName'))
            this.filterCriteria += ", Phase Name=" + sessionParam.phaseName;
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
    }
    makeajaxcallCount() {
        let isCount = true;
        let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
        let countUrl = this.commonUrl + '&showCount=true' + '&productKey=' + this.sessionService.session.cctx.pk;
        this.ddrHttpService.getSessionSummaryData(prefix, countUrl, isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__["SessionSummaryLoadedState"]) {
                this.assignCountData(state.data);
                isCount = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignCountData(countdata) {
        this.count = countdata.totalCount;
        if (this.limit > this.count)
            this.limit = Number(this.count);
    }
    paginate(event) {
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        if (this.limit > this.count)
            this.limit = Number(this.count);
        this.loader = true;
        this.getProgressBar();
        if ((this.limit + this.offset) > this.count)
            this.limit = Number(this.count) - Number(this.offset);
        this.getSessionSummaryData();
    }
    /** Method for progressbar */
    getProgressBar() {
        this.value = 1;
        let interval = setInterval(() => {
            this.value = this.value + Math.floor(Math.random() * 10) + 1;
            if (this.value >= 100) {
                this.value = 100;
                clearInterval(interval);
            }
        }, 300);
    }
    openInstanceReport(nodeData, success) {
        this._ddrData.nsCQMFilter["Session Instance"] = undefined;
        this.nsCommonData.currRowData = nodeData;
        this.nsCommonData.sessionIndex = undefined;
        this.nsCommonData.isFromSummary = true;
        if (success == 'Success')
            this.nsCommonData.sessionIndex = '0';
        else
            this.nsCommonData.sessionIndex = '-2';
        this.nsCommonData.isSuccess = success;
        if (this.summaryReportByStatus) {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_STATUS;
            this._ddrData.errorNameSession = nodeData.statusName;
            this._ddrData.errorUserSession = nodeData.statusName;
            this._ddrData.fromReport = true;
        }
        else {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_SUMMARY;
            this._ddrData.errorNameSession = undefined;
            this._ddrData.errorUserSession = undefined;
            this._ddrData.fromReport = false;
        }
        //CQM case
        if (this.commonService.isCQM) {
            this.commonService.nsSessionInstance = JSON.parse(JSON.stringify(this.commonService.nsSessionSummary));
            this.commonService.nsSessionInstance['wanEnv'] = 0;
            if (this.commonService.nsSessionInstance['script']) {
                this.commonService.nsSessionInstance['scriptName'] = this.commonService.nsSessionInstance['script'];
            }
            if (!this.commonService.nsSessionInstance.scriptName) //incase no filter for script has been provided.
             {
                this.commonService.nsSessionInstance['scriptName'] = this.nsCommonData.currRowData['scriptName'];
                this.commonService.nsSessionInstance['scriptidx'] = this.nsCommonData.currRowData['sessionIndex'];
            }
            this.commonService.nsSessionInstance['strStatus'] = this.commonService.nsSessionInstance['status'];
            delete this.commonService.nsSessionInstance['status'];
            if (this.commonService.nsSessionInstance['strGroupBy'] && this.commonService.nsSessionInstance['order'])
                this.commonService.nsSessionInstance = this.commonService.filterGroupOrder(this.commonService.nsSessionInstance);
            else
                delete this.commonService.nsSessionInstance['strGroupBy'];
            if (success == 'Success')
                this.commonService.nsSessionInstance['strStatus'] = '0';
            this.commonService.isFromSessionSummary = true;
            if (nodeData['status'] && nodeData['status'] != "-" && nodeData['status'] != "NA") {
                this.commonService.nsSessionInstance['strStatus'] = nodeData['status'];
            }
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Session Instance');
        this._router.navigate(['/ddr/nsreports/sessionInstance']);
    }
    openFailureReport(nodeData) {
        this._ddrData.nsCQMFilter["Session Failure"] = undefined;
        this.nsCommonData.currRowData = nodeData;
        if (this.summaryReportByStatus) {
            this.nsCommonData.sessionIndex = nodeData.status;
            this.nsCommonData.isSuccess = nodeData.statusName;
            this.nsCommonData.isFromSummary = true;
            this._ddrData.errorNameSession = nodeData.statusName;
            this._ddrData.errorUserSession = nodeData.statusName;
            this._ddrData.fromReport = true;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_STATUS;
        }
        else {
            this._ddrData.errorUserSession = undefined;
            this._ddrData.errorNameSession = undefined;
            this._ddrData.fromReport = false;
            this.nsCommonData.failureType = nodeData.sessionIndex;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_SUMMARY;
        }
        if (this.commonService.isCQM) {
            if (this.summaryReportByStatus) {
                this.commonService.nsSessionInstance = JSON.parse(JSON.stringify(this.commonService.nsSessionSummary));
                this.commonService.nsSessionInstance['wanEnv'] = 0;
                if (!this.commonService.nsSessionInstance.scriptName) //incase no filter for script has been provided.
                 {
                    this.commonService.nsSessionInstance['scriptName'] = this.nsCommonData.scriptName;
                    this.commonService.nsSessionInstance['scriptidx'] = this.nsCommonData.currRowData['sessionIndex'];
                }
                this.commonService.nsSessionInstance['strStatus'] = this.commonService.nsSessionInstance['status'];
                delete this.commonService.nsSessionInstance['status'];
                delete this.commonService.nsSessionInstance['strGroupBy'];
            }
            else {
                this.commonService.nsSessionFailure = JSON.parse(JSON.stringify(this.commonService.nsSessionSummary));
                this.commonService.nsSessionFailure['wanEnv'] = 'NA';
                if (this.commonService.nsSessionFailure.status == 0 || this.commonService.nsSessionFailure == -2)
                    this.commonService.nsSessionFailure.status = -1;
                this.commonService.nsSessionFailure['objectId'] = this.nsCommonData.failureType;
                //failure type stores session index?   if script filter provided the will open report for that particular script and the script index will be same as the row data .sessionindex
                if (this.commonService.nsSessionFailure.script) {
                    this.commonService.nsSessionFailure['scriptName'] = this.commonService.nsSessionFailure.script;
                    delete this.commonService.nsSessionFailure.script;
                }
                else //incase no filter for script has been provided.
                 {
                    this.commonService.nsSessionFailure['scriptName'] = this.nsCommonData.currRowData["scriptName"];
                }
                if (this.commonService.nsSessionInstance['strStatus'] == -2 || this.commonService.nsSessionInstance['strStatus'] == -0) {
                    this.commonService.nsSessionInstance['strStatus'] = -1;
                }
                //'&objectType=3
                if (nodeData['status'] != "-") {
                    this.commonService.nsSessionInstance['strStatus'] = nodeData['status'];
                }
                delete this.commonService.nsSessionFailure['scriptidx'];
                delete this.commonService.nsSessionFailure['strGroupBy'];
                delete this.commonService.nsSessionFailure['order'];
                this.commonService.nsSessionFailure['objectType'] = 3; //added cz in session summary the object =3 is added on rest side.
            }
            this.commonService.isFromSessionSummary = true;
        }
        if (this.summaryReportByStatus) {
            this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Session Instance');
            this._router.navigate(['/ddr/nsreports/sessionInstance']);
        }
        else {
            this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Session Failure');
            this._router.navigate(['/ddr/nsreports/sessionFailure']);
        }
    }
    openSessionDetailReport(nodeData) {
        this.nsCommonData.currRowData = nodeData.scriptName;
        this.nsCommonData.sessionIndex = undefined;
        this.nsCommonData.avgTime = this.msToTimeFormate(nodeData.average);
        if (this.summaryReportByStatus) {
            this.nsCommonData.isSuccess = nodeData.statusName;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_STATUS;
        }
        else
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_SUMMARY;
        this._router.navigate(['/ddr/nsreports/sessionDetail']);
    }
    openSessionName(nodeData) {
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_13__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    setTestRunInHeader() {
        if (this.id && this.id.product.toLowerCase() == 'netstorm') {
            if (this.summaryReportByStatus)
                this.strTitle = 'Session Summary By Status Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
            else
                this.strTitle = 'Session Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else if (this.id && this.id.product.toLowerCase() == 'netcloud') {
            if (this.summaryReportByStatus)
                this.strTitle = 'Session Summary By Status Report - Test Run : ' + this.sessionService.session.testRun.id;
            else
                this.strTitle = 'Session Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else {
            if (this.summaryReportByStatus)
                this.strTitle = 'Netdiagnostics Enterprise - Session Summary By Status Report - Session : ' + this.sessionService.session.testRun.id;
            else
                this.strTitle = 'Netdiagnostics Enterprise - Session Summary Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.subscribeSession.unsubscribe();
        this.commonService.isToLoadSideBar = false;
        this.commonService.isCQM = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.id.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.data = this.data.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.data = this.data.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.data = this.data.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.data = this.data.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.data = this.data.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.data = this.dataOrig;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.data = this.dataOrig;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
};
SessionSummaryReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_1__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__["NsCommonService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__["ScriptUtilService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["ActivatedRoute"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_14__["DialogService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_15__["DDRHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], SessionSummaryReportComponent.prototype, "summaryReportByStatus", void 0);
SessionSummaryReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Component"])({
        selector: 'session-summary-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./session-summary-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_2__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./session-summary-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.scss")).default]
    })
], SessionSummaryReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.scss":
/*!************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.scss ***!
  \************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("session-timing-detail-panel .sidebarHeightClass .ui-sidebar {\n  height: calc(100vh - 42px);\n}\nsession-timing-detail-panel .uplodSpinr {\n  position: absolute;\n  right: 113px;\n  top: 14px;\n  display: flex;\n  align-items: center;\n  justify-content: flex-end;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.ts":
/*!**********************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.ts ***!
  \**********************************************************************************************************************************/
/*! exports provided: SessionTimingDetailPanelComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SessionTimingDetailPanelComponent", function() { return SessionTimingDetailPanelComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! lodash */ "./node_modules/lodash/lodash.js");
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var src_app_pages_ddr_services_common_services__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/pages/ddr/services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var src_app_pages_ddr_services_ddr_request_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/pages/ddr/services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_pages_ddr_services_rrx_data_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/ddr/services/rrx-data.service */ "./src/app/pages/ddr/services/rrx-data.service.ts");












let SessionTimingDetailPanelComponent = class SessionTimingDetailPanelComponent {
    constructor(_router, sessionService, nsCommonData, ddrData, breadcumb, commonService, ddrRequest, rrxDataService) {
        this._router = _router;
        this.sessionService = sessionService;
        this.nsCommonData = nsCommonData;
        this.ddrData = ddrData;
        this.breadcumb = breadcumb;
        this.commonService = commonService;
        this.ddrRequest = ddrRequest;
        this.rrxDataService = rrxDataService;
        this.showTansactionTimeSidebar = false;
        this.sessTimingPanelEvent = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this.transactionTimeTableData = [];
        this.tableCols = [];
        this.childTableCols = [];
        this.cols = [];
        this.tmpGrpTableHeaders = [];
        this.togglingTreeTable = false;
        this.calloutTreeTableData = {};
        this.tableColsFirstBytes = [];
        this.tmpGrpTableHeadersForFirstBytes = [];
        this.isCallOut = false;
        this.tableCols = [
            { field: 'name', header: 'Event', width: '50' },
            { field: 'absStartTime', header: 'Absolute Start Time', width: '10' },
            { field: 'status', header: 'Status', width: '10' },
            { field: 'duration', header: 'Duration(ms)', width: '10' },
        ];
        this.tableColsFirstBytes = [
            { field: 'urlName', header: 'Event', width: '50' },
            { field: 'startTimeInMs', header: 'Absolute Start Time', width: '10' },
            { field: 'statusCode', header: 'Status', width: '10' },
            { field: 'selfResponseTime', header: 'Duration(ms)', width: '10' },
        ];
        this.tmpGrpTableHeaders = this.tableCols.slice();
        this.tmpGrpTableHeadersForFirstBytes = this.tableColsFirstBytes.slice();
        this.cols = [
            { field: 'version', header: 'Version', width: '10' },
            { field: 'version', header: 'Elapsed Time', width: '10' },
            { field: 'version', header: 'Reused Connection', width: '10' },
            { field: 'version', header: 'Reused SSL', width: '10' },
            { field: 'version', header: 'Trx Bytes', width: '10' },
            { field: 'version', header: 'Rcv Bytes', width: '10' }
        ];
    }
    closeSideBar() {
        this.sessTimingPanelEvent.emit({
            close: true
        });
    }
    onChangeMultiselect(evt) {
        this.tableCols = lodash__WEBPACK_IMPORTED_MODULE_3__["cloneDeep"](this.tmpGrpTableHeaders);
        this.tableColsFirstBytes = lodash__WEBPACK_IMPORTED_MODULE_3__["cloneDeep"](this.tmpGrpTableHeadersForFirstBytes);
        let dataArray = [];
        if (evt.value.length == 0) {
            this.tableCols = this.tmpGrpTableHeaders;
            this.tableColsFirstBytes = this.tmpGrpTableHeadersForFirstBytes;
        }
        else {
            for (let i = 0; i < evt.value.length; i++) {
                dataArray.push(evt.value[i]);
            }
            var unique = dataArray.filter(this.onlyUnique);
            this.tableCols = [...this.tableCols, ...unique];
            this.tableColsFirstBytes = [...this.tableColsFirstBytes, ...unique];
        }
    }
    onlyUnique(value, index, self) {
        return self.indexOf(value) === index;
    }
    expandCollapse(expand) {
        this.togglingTreeTable = true;
        let data = this.treeTableData;
        this.modifyTreeRecursively(data, expand);
        this.treeTableData = [...data];
        this.togglingTreeTable = false;
    }
    /**
     * Expanding or collapsing tree by modifying expanded property after traversing tree table recursively.
     * @param data tree table data
     * @param toggleCollapsable expand/collapse flag
     */
    modifyTreeRecursively(data, toggleCollapsable) {
        data.forEach((node) => {
            var _a;
            if (node && node.children && node.children[0] && node.children[0].data && node.children[0].data['flowpath'] && !this.calloutTreeTableData[node.children[0].data['flowpath']])
                this.openCalloutTreeTable((_a = node.children[0].data) !== null && _a !== void 0 ? _a : undefined, node['data']);
            node.expanded = toggleCollapsable;
            if (this.calloutTreeTableData[node['data']['flowpath']] && this.calloutTreeTableData[node['data']['flowpath']]['data']) {
                let data = this.calloutTreeTableData[node['data']['flowpath']]['data'];
                this.modifyBytesTreeRecursively(data, toggleCollapsable);
                this.calloutTreeTableData[node['data']['flowpath']]['data'] = [...data];
            }
            if (node.children && node.children.length > 0) {
                this.modifyTreeRecursively(node.children, toggleCollapsable);
            }
        });
    }
    modifyBytesTreeRecursively(flowPathdata, toggleCollapsable) {
        flowPathdata.forEach((node) => {
            node.expanded = toggleCollapsable;
            if (node.children && node.children.length > 0) {
                this.modifyBytesTreeRecursively(node.children, toggleCollapsable);
            }
        });
    }
    openCalloutTreeTable(node, parentNode) {
        if (this.calloutTreeTableData && this.calloutTreeTableData[node.flowpath] && Object.keys(this.calloutTreeTableData[node.flowpath]).length > 0) {
            this.calloutTreeTableData[node.flowpath]['isTableIconCollapsed'] = !this.calloutTreeTableData[node.flowpath]['isTableIconCollapsed'];
        }
        else {
            this.isCallOut = true;
            this.calloutTreeTableData[node.flowpath] = {
                'data': [],
                'isTableIconCollapsed': true,
                'loading': true
            };
            this.fetchCalloutData(node, parentNode);
        }
    }
    fetchCalloutData(node, parentNode) {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            let startTime = node.absStartTime;
            let endTime;
            if (startTime && parentNode)
                endTime = Number(startTime) + (Number(parentNode.duration) * 1000) + 1800000;
            this.calloutTreeTableData[node.flowpath]['data'] = yield this.rrxDataService.TrxflowmapDataNonExpand(node.flowpath, startTime, endTime);
            this.calloutTreeTableData[node.flowpath]['loading'] = false;
            this.isCallOut = false;
        });
    }
    ViewNetworkLogs(row, enableAll) {
        try {
            let endtm;
            if (this.dataObj.startTime && this.dataObj.respTime)
                endtm = Number(this.dataObj.startTime) + Number(this.dataObj.respTime * 1000);
            let urlPar = {};
            urlPar['path'] = this.dataObj.hostUrl;
            urlPar['product'] = this.dataObj.id.product;
            urlPar['testRun'] = this.sessionService.session.testRun.id;
            urlPar['userName'] = this.dataObj.id.userName || "";
            urlPar['strOperName'] = 'pageDump';
            if (this.nsCommonData.objectType == "3")
                urlPar['strScriptName'] = this.dataObj.name;
            else
                urlPar['strScriptName'] = this.dataObj.scriptName;
            urlPar['sessionIndex'] = this.dataObj.sessionIndex;
            urlPar['childIndex'] = this.dataObj.childIndex;
            urlPar['pageName'] = row.name.split(":")[1].trim();
            urlPar['flagOfDrillDown'] = 'yes';
            if (!(row.flowpath > 0)) {
                urlPar['isND'] = 0;
                urlPar['StartTime'] = this.dataObj.startTime;
                urlPar['EndTime'] = endtm;
                urlPar['flowPathInstance'] = "0";
            }
            else {
                urlPar['flowPathInstance'] = row.flowpath;
                urlPar['pageName'] = row.name.split(":")[1].trim();
                urlPar['StartTime'] = this.dataObj.startTime;
                urlPar['strStartTime'] = this.dataObj.id.startTime;
                urlPar['strEndTime'] = this.dataObj.id.endTime;
                urlPar['EndTime'] = endtm;
            }
            if (enableAll) {
                if (urlPar['pageName'] != "" && urlPar['pageName']) {
                    urlPar['pageName'] = "";
                }
                if (urlPar['flowPathInstance'] && urlPar['flowPathInstance']) {
                    delete urlPar['flowPathInstance'];
                }
            }
            this.ddrData.pagedump = urlPar;
            sessionStorage.setItem("ddrTabName", "Page Dump");
            this.breadcumb.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].SESSION_TIMING;
            this._router.navigate(['/ddr/networkLogs']);
        }
        catch (error) {
            console.log(error);
        }
    }
    openFlowpathReport(rowdata) {
        console.log('currrow fpid ', rowdata);
        this.commonService.isFilterFromSideBar = false;
        this.ddrData.resetDDRArguments();
        this.ddrData.fpIdFromNSSession = rowdata.flowpath;
        this.breadcumb.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].SESSION_TIMING;
        this._router.navigate(['/ddr/flowpath']);
    }
};
SessionTimingDetailPanelComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_4__["SessionService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_5__["NsCommonService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__["DdrBreadcrumbService"] },
    { type: src_app_pages_ddr_services_common_services__WEBPACK_IMPORTED_MODULE_9__["CommonServices"] },
    { type: src_app_pages_ddr_services_ddr_request_service__WEBPACK_IMPORTED_MODULE_10__["DDRRequestService"] },
    { type: src_app_pages_ddr_services_rrx_data_service__WEBPACK_IMPORTED_MODULE_11__["RrxDataService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])("showTansactionTimeSidebar")
], SessionTimingDetailPanelComponent.prototype, "showTansactionTimeSidebar", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])("treeTableData")
], SessionTimingDetailPanelComponent.prototype, "treeTableData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])("dataObj")
], SessionTimingDetailPanelComponent.prototype, "dataObj", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"])("sessTimingPanelEvent")
], SessionTimingDetailPanelComponent.prototype, "sessTimingPanelEvent", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChildren"])("treeTable")
], SessionTimingDetailPanelComponent.prototype, "treeTable", void 0);
SessionTimingDetailPanelComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'session-timing-detail-panel',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./session-timing-detail-panel.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./session-timing-detail-panel.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.scss")).default]
    })
], SessionTimingDetailPanelComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.scss":
/*!******************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.scss ***!
  \******************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("session-timing-detail .sedebarHeightClass .ui-sidebar {\n  height: calc(100vh - 42px);\n}\nsession-timing-detail .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\nsession-timing-detail .group-left {\n  float: left;\n  padding-top: 4px;\n}\nsession-timing-detail .group-right {\n  float: right;\n  padding-top: 4px;\n}\nsession-timing-detail .no-record {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 310px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 20px auto;\n  padding: 10px;\n}\nsession-timing-detail .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\nsession-timing-detail .no-transactions img {\n  max-width: 70%;\n}\nsession-timing-detail .img-8 {\n  width: 14px;\n  height: 14px;\n}\nsession-timing-detail .column-container {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  height: 100%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.ts":
/*!****************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.ts ***!
  \****************************************************************************************************************************/
/*! exports provided: SessionTimingDetailComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SessionTimingDetailComponent", function() { return SessionTimingDetailComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _angular_cdk_clipboard__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! @angular/cdk/clipboard */ "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/clipboard.js");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
/* harmony import */ var src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! src/app/shared/time-bar/service/time-bar.service */ "./src/app/shared/time-bar/service/time-bar.service.ts");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! moment */ "./node_modules/moment/moment.js");
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_16__);



// import { CavTopPanelNavigationService } from '../../../../../../main/services/cav-top-panel-navigation.service';

// import { CavConfigService } from '../../../../../../main/services/cav-config.service';













let SessionTimingDetailComponent = class SessionTimingDetailComponent {
    constructor(commonService, sessionService, _router, breadcumb, nsCommonData, ddrData, ddrRequest, sessiontimeservice, ddrHttpService, clipboardService, scriptUtilService, timebarService) {
        this.commonService = commonService;
        this.sessionService = sessionService;
        this._router = _router;
        this.breadcumb = breadcumb;
        this.nsCommonData = nsCommonData;
        this.ddrData = ddrData;
        this.ddrRequest = ddrRequest;
        this.sessiontimeservice = sessiontimeservice;
        this.ddrHttpService = ddrHttpService;
        this.clipboardService = clipboardService;
        this.scriptUtilService = scriptUtilService;
        this.timebarService = timebarService;
        this.tableData = [];
        this.scaleData = [];
        this.filterCriteria = "";
        this.loading = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.filterApply = false;
        this.isFilter = false;
        this.isAction = false;
        this.isDdrEnabled = true;
        this.viewCorrelationId = false;
        this.scriptname = "";
        this.userId = "";
        this.sessionId = "";
        this.pagename = "";
        this.urlName = "";
        this.correlationId = "";
        this.dynaTraceVal = "";
        this.isLoading = false;
        this.errorData = "";
        this.isTableIconCollapsed = false;
        this.showTansactionTimeSidebar = false;
        this.dataObj = {};
        this.headerRelativePath = "/ddr/session-timing-detail/session-timing-detail.json";
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.isBackButton = true;
        this.commonService.currentReport = this.breadcumb.nsReportName + ' Timing Details';
        this.randomNumber();
        this.getDataFromRow();
        this.id = this.commonService.getData();
        this.commonService.isToLoadSideBar = false;
        this.makeTableColumns();
        this.setTestRunInHeader();
        this.sessiontimeservice.getSessionPct().subscribe((sessTime) => {
            this.sessiontimingPct = `${sessTime["msg"]}`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.getSessionTimingDetailData();
            }
        });
        this.sessionStorageData = JSON.parse(sessionStorage.getItem('timePresets'));
    }
    clickButtonEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) == "showTree") {
            me.openTreeView();
        }
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { //Due to A-9 migration...
        if (this.sessionService.preSession.multiDc === true) {
            this.id.testRun = this.sessionService.session.testRun.id;
            console.log("all case url==>", hostDcName, "all case test run==>", this.id.testRun, '-----  ', this.sessionService.session.testRun.id);
            hostDcName = this.ddrData.getHostUrlMultiDC(isDownloadCase);
        }
        else {
            hostDcName = this.ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    getSessionTimingDetailData() {
        let ajaxParam = '';
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        // query doesnt support start time and end time . #only start time in case of url.
        ajaxParam += '&childidx=' + this.childIndex +
            '&objectType=' + this.nsCommonData.objectType +
            '&sessioninst=' + this.sessionIndex +
            '&txinst=' + this.trxnInstance +
            '&starttime=' + this.strTime +
            '&urlidx=' + this.urlidx +
            '&strStartTime=' + this.id.startTime +
            '&strEndTime=' + this.id.endTime +
            '&pageInstance=' + this.pageinst +
            '&queryId=' + this.queryId +
            '&productKey=' + this.sessionService.session.cctx.pk +
            '&treeTableMainObjName=' + this.pageName +
            '&treeTableMainObjDuration=' + this.respTime;
        if (this.ddrData.generatorName || (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxParam += '&generatorName=' + this.ddrData.generatorName;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
        this.ddrHttpService.getSessionTimingData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["SessionTimeLoadedState"]) {
                this.doGetTableValues(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    doGetTableValues(res) {
        var _a, _b, _c, _d, _e, _f, _g;
        this.isCancelQuerydata = true;
        if (!res.tableData || (res.tableData && res.tableData.length == 0)) {
            this.loading = false;
            this.empty = true;
            if (res.errorData)
                this.errorData = res.errorData;
            else {
                this.tableData = (_a = res.tableData) !== null && _a !== void 0 ? _a : [];
                this.chartData = (_b = res.barData) !== null && _b !== void 0 ? _b : [];
                this.scaleData = (_c = res.scaleData) !== null && _c !== void 0 ? _c : [];
                this.totalBytes = (_d = res.totalBytes) !== null && _d !== void 0 ? _d : [];
                this.ndKeyValue = (_e = res.ndKeyValue) !== null && _e !== void 0 ? _e : [];
                this.pdKeyValue = (_f = res.pdKeyValue) !== null && _f !== void 0 ? _f : [];
                this.treeTableData = (_g = res.tableTreeData) !== null && _g !== void 0 ? _g : [];
            }
            return;
        }
        // }else if (res.errorData) {
        //     this.loading = false;
        //     this.errorData = res.errorData;
        //     return;
        // }
        else {
            setTimeout(() => {
                this.loading = false;
            }, 1000);
        }
        this.tableData = res.tableData;
        this.chartData = res.barData;
        this.scaleData = res.scaleData;
        this.totalBytes = res.totalBytes;
        this.ndKeyValue = res.ndKeyValue;
        this.pdKeyValue = res.pdKeyValue;
        this.treeTableData = res.tableTreeData;
        this.showfilterCriteria(res.strStartTime, res.strEndTime);
        for (let i = 0; i < this.tableData.length; i++) {
            if (this.tableData[i]['fpSignature'] == '1' && this.convertIntoNumber(this.tableData[i]['flowpath']) > 0) {
                this.isAction = true;
                break;
            }
            else if (this.tableData[i]['instance'].startsWith('Conn') && this.pdKeyValue) {
                this.isAction = true;
                break;
            }
        }
        if (!this.isAction) {
            this.cols1.pop();
            this.cols1[0]['width'] = 15;
        }
    }
    showToolTipForPageDownload(text, obj, val) {
        let tooltip = text + '\n' + obj + '\n' + val + "sec";
        return tooltip;
    }
    showToolTip(d) {
        let tooltip = `${d.objName}\n\n`;
        if (this.strinToNum(d.dnsLookupSec) > 0)
            tooltip += `DNS Lookup Time - ${d.dnsLookupSec} sec\n`;
        if (this.strinToNum(d.connectSec) > 0)
            tooltip += `Connect Time - ${d.connectSec} sec\n`;
        if (this.strinToNum(d.sslSec) > 0)
            tooltip += `SSL Time - ${d.sslSec} sec\n`;
        if (this.strinToNum(d.writeSec) > 0)
            tooltip += `Request Sent Time - ${d.writeSec} sec\n`;
        if (this.strinToNum(d.firstSec) > 0)
            tooltip += `First Byte Time - ${d.firstSec} sec\n`;
        if (this.strinToNum(d.contentSec) > 0)
            tooltip += `Content Download - ${d.contentSec} sec\n`;
        return tooltip;
    }
    strinToNum(rowdata) {
        return Number.parseFloat(rowdata);
    }
    truncateUrl(urlName, limit) {
        // if (urlName.indexOf('?') != -1)
        //     urlName = urlName.substring(0, urlName.indexOf('?')) + "...";
        // // Check for : from index 6 to skip http: or https:
        // else if (urlName.indexOf(':', 6) != -1)
        //     urlName = urlName.substring(0, urlName.indexOf(':', 6)) + "...";
        if (urlName.length > limit)
            urlName = urlName.substring(0, limit) + "...";
        return urlName;
    }
    makeTableColumns() {
        this.cols1 = [
            { field: 'objName', header: 'Object Name', sortable: true, action: true, width: 10, align: 'left' },
            { field: 'status', header: 'Status', sortable: true, action: true, width: 4, align: 'left' },
            { field: 'httpCode', header: 'HTTP Code', sortable: true, action: true, width: 3, align: 'right' },
            { field: 'connReused', header: 'Reused Conn.', sortable: true, action: true, width: 2.5, align: 'left' },
            { field: 'sslReused', header: 'Reused SSL', sortable: true, action: true, width: 2.5, align: 'left' }
        ];
        if (!this.sessionService.session.testRun.cmt)
            this.cols1.push({ field: 'startTime', header: 'Start Time', sortable: 'custom', action: true, width: 5, align: 'right' });
        this.cols1.push({ field: 'totalTime', header: 'Total', sortable: 'custom', action: true, width: 4, align: 'right' }, { field: 'dnsLookup', header: 'DNS', sortable: 'custom', action: true, width: 5, align: 'right' }, { field: 'connectTime', header: 'Connect', sortable: 'custom', action: true, width: 5, align: 'right' }, { field: 'sslTime', header: 'SSL', sortable: 'custom', action: true, width: 5, align: 'right' }, { field: 'reqTime', header: 'Request', sortable: 'custom', action: true, width: 5, align: 'right' }, { field: 'firstByte', header: '1st Byte', sortable: 'custom', action: true, width: 5, align: 'right' }, { field: 'contentDownload', header: 'Content Download', sortable: 'custom', action: true, width: 5, align: 'right' }, { field: 'totalBytes', header: 'Total bytes', sortable: 'custom', action: true, width: 5, align: 'right' }, { field: 'action', header: 'Action', sortable: false, action: true, width: 5, align: 'center' });
        this.visibleCols1 = ['objName', 'status', 'httpCode', 'connReused', 'sslReused', 'startTime', 'totalTime', 'connectTime', 'sslTime', 'reqTime', 'firstByte', 'contentDownload', 'totalBytes', 'action'];
        this.columnOptions1 = [];
        for (let i = 0; i < this.cols1.length; i++) {
            this.columnOptions1.push({ label: this.cols1[i].header, value: this.cols1[i].field });
        }
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    getDataFromRow() {
        if (!this.nsCommonData.objectType)
            this.nsCommonData.objectType = sessionStorage.getItem("objType");
        else {
            sessionStorage.removeItem("objType");
            sessionStorage.setItem("objType", this.nsCommonData.objectType);
        }
        if (!this.nsCommonData.currRowData)
            this.nsCommonData.currRowData = JSON.parse(sessionStorage.getItem("currRowData"));
        else {
            sessionStorage.removeItem("currRowData");
            sessionStorage.setItem("currRowData", JSON.stringify(this.nsCommonData.currRowData));
        }
        if (this.nsCommonData.objectType === '2') //transaction
         {
            this.reportType = 'Transaction';
            this.startTime = this.nsCommonData.currRowData["startTime"];
            this.respTime = this.nsCommonData.currRowData["responseTime"] / 1000;
            this.childIndex = this.nsCommonData.currRowData["childIndex"];
            this.trxnInstance = this.nsCommonData.currRowData["txInstance"];
            this.sessionIndex = this.nsCommonData.currRowData["sessionInst"];
            this.status = this.nsCommonData.currRowData["statusName"];
            this.scriptName = this.nsCommonData.currRowData["scriptName"];
            /**Use For Filtercriteria */
            this.sessWithUserID = this.nsCommonData.currRowData["userId"];
            this.pageName = this.nsCommonData.currRowData["TransactionName"];
            if (this.nsCommonData.currRowData["location"] && this.nsCommonData.currRowData["access"] && this.nsCommonData.currRowData["browser"]) {
                this.location = this.nsCommonData.currRowData["location"];
                this.access = this.nsCommonData.currRowData["access"];
                this.browser = this.nsCommonData.currRowData["browser"];
            }
        }
        else if (this.nsCommonData.objectType === '1') //page
         {
            this.reportType = 'Page';
            this.status = this.nsCommonData.currRowData["status"];
            this.scriptName = this.nsCommonData.currRowData["scriptName"];
            this.startTime = this.nsCommonData.currRowData["startTime"];
            this.respTime = this.nsCommonData.currRowData["respTime"] / 1000;
            this.childIndex = this.nsCommonData.currRowData["childIndex"];
            let sessId = this.nsCommonData.currRowData["sessionId"];
            this.sessionIndex = sessId.substring(sessId.indexOf(':') + 1, sessId.length);
            this.pageinst = this.nsCommonData.currRowData["pageInstance"];
            /** For Filter Criteria */
            this.sessWithUserID = this.nsCommonData.currRowData["userId"];
            this.pageName = this.nsCommonData.currRowData["pageName"];
            if (this.nsCommonData.currRowData["location"] && this.nsCommonData.currRowData["access"] && this.nsCommonData.currRowData["browser"]) {
                this.location = this.nsCommonData.currRowData["location"];
                this.access = this.nsCommonData.currRowData["access"];
                this.browser = this.nsCommonData.currRowData["browser"];
            }
        }
        else if (this.nsCommonData.objectType === '0') //url
         {
            this.reportType = 'Url';
            this.status = this.nsCommonData.currRowData["statusName"];
            this.startTime = this.nsCommonData.currRowData["startTime"];
            this.childIndex = this.nsCommonData.currRowData["childIndex"];
            this.sessionIndex = this.nsCommonData.currRowData["sessionId"];
            this.urlidx = this.nsCommonData.currRowData["urlIndex"];
            this.pageinst = this.nsCommonData.currRowData["pageInstance"];
            this.strTime = this.nsCommonData.currRowData["startTime"];
            this.scriptName = this.nsCommonData.currRowData["scriptName"];
            this.respTime = this.nsCommonData.currRowData["responseTime"] / 1000;
            /** For Filter Criteria */
            this.sessWithUserID = this.nsCommonData.currRowData["convuserId"];
            this.pageName = this.nsCommonData.currRowData["pageName"];
            if (this.nsCommonData.currRowData["location"] && this.nsCommonData.currRowData["access"] && this.nsCommonData.currRowData["browser"]) {
                this.location = this.nsCommonData.currRowData["location"];
                this.access = this.nsCommonData.currRowData["access"];
                this.browser = this.nsCommonData.currRowData["browser"];
            }
        }
        else if (this.nsCommonData.objectType === '3') //Session
         {
            this.reportType = 'Session';
            this.pageName = this.nsCommonData.currRowData["scriptName"];
            this.startTime = this.nsCommonData.currRowData["starttime"];
            this.respTime = this.nsCommonData.currRowData["duration"] / 1000;
            this.status = this.nsCommonData.currRowData["status"];
            if (!this.respTime) // coming from ns-usersession
                this.respTime = this.nsCommonData.currRowData["totalTime"] / 1000;
            if (!isNaN(this.status)) // coming from ns-usersession
                this.status = this.nsCommonData.currRowData["statusName"];
            if (this.nsCommonData.currRowData["childindex"]) // Child index From  Session Instance
                this.childIndex = this.nsCommonData.currRowData["childindex"];
            else if (this.nsCommonData.currRowData["childIndex"]) // Child Index From ns-usersession report
                this.childIndex = this.nsCommonData.currRowData["childIndex"];
            if (this.nsCommonData.currRowData["starttime"]) // start timeFrom  Session Instance
                this.startTime = this.nsCommonData.currRowData["starttime"];
            else if (this.nsCommonData.currRowData["startTime"]) // start Time From ns-usersession report
                this.startTime = this.nsCommonData.currRowData["startTime"];
            if (this.nsCommonData.currRowData["sessionid"]) // Session id From  Session Instance
                this.sessionIndex = this.nsCommonData.currRowData["sessionid"];
            else if (this.nsCommonData.currRowData["sessionId"]) // Session Id From ns-usersession report
                this.sessionIndex = this.nsCommonData.currRowData["sessionId"];
            /** For Filter Criteria */
            if (this.nsCommonData.currRowData["userid"])
                this.sessWithUserID = this.childIndex + ":" + this.nsCommonData.currRowData["userid"];
            else
                this.sessWithUserID = this.childIndex + ":" + this.nsCommonData.userId; //comes from user-session
            if (this.nsCommonData.currRowData["location"] && this.nsCommonData.currRowData["access"] && this.nsCommonData.currRowData["browser"]) {
                this.location = this.nsCommonData.currRowData["location"];
                this.access = this.nsCommonData.currRowData["access"];
                this.browser = this.nsCommonData.currRowData["browser"];
            }
        }
    }
    customsortOnColumns(event, tempData) {
        if (event.order == -1) {
            var temp = (event["field"]);
            event.order = 1;
            tempData = tempData.sort(function (a, b) {
                var value, value2;
                if (temp == 'startTime' || temp == 'totalBytes') // for start Time -- 00:23:19.131"
                 {
                    value = Number(a[temp].replace(/[:.,]/g, ''));
                    value2 = Number(b[temp].replace(/[:.,]/g, ''));
                }
                else if (temp == 'objName' || temp == "status" || temp == "sslReused" || temp == "connReused") {
                    value = a[temp].toLocaleLowerCase();
                    value2 = b[temp].toLocaleLowerCase();
                }
                else {
                    value = Number(a[temp]);
                    value2 = Number(b[temp]);
                }
                return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
            });
        }
        else {
            var temp = (event["field"]);
            event.order = -1;
            //asecding order
            tempData = tempData.sort(function (a, b) {
                var value, value2;
                if (temp == 'startTime' || temp == 'totalBytes') {
                    value = Number(a[temp].replace(/[:.,]/g, ''));
                    value2 = Number(b[temp].replace(/[:.,]/g, ''));
                }
                else if (temp == 'objName' || temp == "status" || temp == "sslReused" || temp == "connReused") {
                    value = a[temp].toLocaleLowerCase();
                    value2 = b[temp].toLocaleLowerCase();
                }
                else {
                    value = Number(a[temp]);
                    value2 = Number(b[temp]);
                }
                return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
            });
        }
        this.tableData = [];
        //console.log(JSON.stringify(tempData));
        if (tempData) {
            tempData.map((rowdata) => { this.tableData = this.Immutablepush(this.tableData, rowdata); });
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    convertIntoNumber(data) {
        return Number(data);
    }
    openFlowpathReport(nextRowIndex) {
        if (nextRowIndex < this.tableData.length) {
            const rowdata = this.tableData[nextRowIndex];
            this.commonService.isFilterFromSideBar = false;
            this.ddrData.resetDDRArguments();
            this.ddrData.fpIdFromNSSession = rowdata.flowpath;
            let startDate = moment__WEBPACK_IMPORTED_MODULE_16__["tz"](Number(this.timebarService.getValue() ? this.timebarService.getValue().time.frameStart.value : this.sessionStorageData.times[0]), sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss');
            let endDate = moment__WEBPACK_IMPORTED_MODULE_16__["tz"](Number(this.timebarService.getValue() ? this.timebarService.getValue().time.frameEnd.value : this.sessionStorageData.times[this.sessionStorageData.times.length - 1]), sessionStorage.getItem('_nvtimezone')).format('MM/DD/YYYY HH:mm:ss');
            let startTimeInMSTemp = this.sessionService.convertFormattedStringIntoTimestamp(startDate);
            let endTimeInMSTemp = this.sessionService.convertFormattedStringIntoTimestamp(endDate);
            this.ddrData.startTime = startTimeInMSTemp.toString();
            this.ddrData.endTime = endTimeInMSTemp.toString();
            this.breadcumb.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_TIMING;
            this._router.navigate(['/ddr/flowpath']);
        }
    }
    showfilterCriteria(startTime, endTime) {
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') // Due to A-9 migration..
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC=" + (this.ddrData.dcName || 'Master');
        if (this.ddrData.startTimeInDateFormat) {
            this.filterCriteria += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime)
            this.filterCriteria += ', From=' + startTime;
        if (this.ddrData.endTimeInDateFormat) {
            this.filterCriteria += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime)
            this.filterCriteria += ', To=' + endTime;
        if (this.ddrData.WAN_ENV) {
            if (this.location)
                this.filterCriteria += ", Location= " + this.location;
            if (this.access)
                this.filterCriteria += ", Access= " + this.access;
            if (this.browser)
                this.filterCriteria += ", Browser= " + this.browser;
        }
        if (this.pageName) {
            if (this.reportType == 'Transaction')
                this.filterCriteria += ", Transaction= " + this.pageName;
            else
                this.filterCriteria += ", Page= " + this.pageName;
        }
        if (this.scriptName)
            this.filterCriteria += ", Script= " + this.scriptName;
        if (this.sessWithUserID)
            this.filterCriteria += ", User Id= " + this.sessWithUserID;
        if (this.ddrData.generatorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this.ddrData.generatorName;
        if (this.filterCriteria.startsWith(','))
            this.filterCriteria = this.filterCriteria.substring(1);
    }
    setTestRunInHeader() {
        if (this.id && this.id.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'Netstorm - ' + this.reportType + ' Timing Details - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else if (this.id && this.id.product.toLowerCase() == 'netcloud')
            this.strTitle = 'NetCloud - ' + this.reportType + ' Timing Details - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - ' + this.reportType + ' Timing Details - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    formatter(value) {
        if (value == null || value == undefined || value == "" || value == 0) {
            return "-";
        }
        else {
            return value;
        }
    }
    ViewPageDump(row, enableAll) {
        try {
            console.log("row in page dumppp", row);
            let endtm;
            if (this.startTime && this.respTime)
                endtm = Number(this.startTime) + Number(this.respTime * 1000);
            let urlPar = {};
            urlPar['path'] = this.getHostUrl();
            urlPar['product'] = this.id.product;
            urlPar['testRun'] = this.sessionService.session.testRun.id;
            urlPar['userName'] = this.id.userName || "";
            urlPar['strOperName'] = 'pageDump';
            if (this.nsCommonData.objectType == "3")
                urlPar['strScriptName'] = this.pageName;
            else
                urlPar['strScriptName'] = this.scriptName;
            urlPar['sessionIndex'] = this.sessionIndex;
            urlPar['childIndex'] = this.childIndex;
            urlPar['pageName'] = row.pageName;
            urlPar['flagOfDrillDown'] = 'yes';
            // let url = '//' + this.getHostUrl() + '/' + this.id.product + '/analyze/rptPageDumpFramesNew.jsp?testRun=' + this.id.testRun + '&strOperName=pageDump' + '&sessionIndex=' + this.sessionIndex + '&childIndex=' + this.childIndex + '&pageName=' + row.pageName + "&flagOfDrillDown=yes";
            if (!(row.flowpath > 0)) {
                urlPar['isND'] = 0;
                urlPar['StartTime'] = this.startTime;
                urlPar['EndTime'] = endtm;
                urlPar['flowPathInstance'] = "0";
                //   url += '&isND=0' + '&StartTime=' + this.startTime  + '&EndTime=' + endtm;
            }
            else {
                urlPar['flowPathInstance'] = row.flowpath;
                urlPar['pageName'] = row.pageName;
                urlPar['StartTime'] = this.startTime;
                urlPar['strStartTime'] = this.id.startTime;
                urlPar['strEndTime'] = this.id.endTime;
                urlPar['EndTime'] = endtm;
                //  url +=  '&flowPathInstance=' + row.flowpath +'&StartTime=' +this.startTime + '&strStartTime=' + this.id.startTime+ '&strEndTime='+this.id.endTime+"&EndTime=" + endtm;
            }
            if (enableAll) {
                if (urlPar['pageName'] != "" && urlPar['pageName']) {
                    urlPar['pageName'] = "";
                }
                if (urlPar['flowPathInstance'] && urlPar['flowPathInstance']) {
                    delete urlPar['flowPathInstance'];
                }
            }
            this.ddrData.pagedump = urlPar;
            // this.breadcumb.parentComponent = CONSTANTS.BREADCRUMB_ITEMS.URL_INSTANCE;
            // this._navService.addNewNaviationLink('ddr'); // Due to A-9 migration..
            sessionStorage.setItem("ddrTabName", "Page Dump");
            // this.ddrData.tabNameObserver$.next('');
            this.breadcumb.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SESSION_TIMING;
            this._router.navigate(['/ddr/networkLogs']);
            // window.open(url,'_blank');
        }
        catch (error) {
            console.log(error);
        }
    }
    /*  ViewPageDump(row){
        try {
            console.log("row in page dumppp",row);
            let endtm;
            if (this.startTime && this.respTime)
                endtm = Number(this.startTime) + Number(this.respTime*1000);
            let url = '//' + this.getHostUrl() + '/' + this.id.product + '/analyze/rptPageDumpFramesNew.jsp?testRun=' + this.id.testRun + '&strOperName=pageDump' + '&sessionIndex=' + this.sessionIndex + '&childIndex=' + this.childIndex + '&pageName=' + row.pageName + "&flagOfDrillDown=yes";
            if(!(row.flowpath >0))
            {
              url += '&isND=0' + '&StartTime=' + this.startTime  + '&EndTime=' + endtm;
            }
            else
            {
             url +=  '&flowPathInstance=' + row.flowpath +'&StartTime=' +this.startTime + '&strStartTime=' + this.id.startTime+ '&strEndTime='+this.id.endTime+"&EndTime=" + endtm;
            }
            window.open(url,'_blank');
            }
        catch (error) {
            console.log(error);
        }

      }*/
    /** Download report for Instance report  */
    downloadReports(reports) {
        let downloadTimingInfo = JSON.parse(JSON.stringify(this.tableData));
        let renameArray = { 'objName': 'Object Name', 'status': 'Status', 'httpCode': 'HTTP Code', 'connReused': 'Reused Conn.', 'sslReused': 'Reused SSL', 'startTime': 'Start Time', 'totalTime': 'Total', 'dnsLookup': 'DNS', 'connectTime': 'Connect', 'sslTime': 'SSL', 'reqTime': 'Request', 'firstByte': '1st Byte', 'contentDownload': 'Content Download', 'totalBytes': 'Total bytes' };
        let colOrder = ['Object Name', 'Status', 'HTTP Code', 'Reused Conn.', 'Reused SSL', 'Start Time', 'Total', 'DNS', 'Connect', 'SSL', 'Request', '1st Byte', 'Content Download', 'Total bytes'];
        //console.log("InstanceData=========== ", JSON.stringify(this.tableData));
        this.tableData.forEach((val, index) => {
            delete val['action'];
            delete val['flowpath'];
            delete val['fpSignature'];
            delete val['instance'];
            delete val['object'];
            delete val['pageName'];
        });
        let tableRowData = [];
        let headers = [];
        let isHeaderFlag = false;
        for (let i = 0; i < this.tableData.length; i++) {
            const rowData = this.tableData[i];
            const selectedRowData = [];
            if (headers.length > 0)
                isHeaderFlag = true;
            if (!isHeaderFlag)
                headers.push("#");
            selectedRowData.push("");
            for (let j = 0; j < this.visibleCols1.length - 1; j++) {
                if (!isHeaderFlag)
                    headers.push(this.getHeaders(this.visibleCols1[j]));
                selectedRowData.push(rowData[this.visibleCols1[j]]);
            }
            tableRowData.push(selectedRowData);
        }
        let downloadObj = {
            testRun: this.sessionService.session.testRun.id,
            cctx: this.sessionService.session.cctx,
            type: reports,
            skipColumn: "",
            rowData: tableRowData,
            header: headers,
            title: 'Session Timing Detail Report',
            arrParaList: null,
            subTitle: "",
            forReport: "nsDdrReport",
            lowerPanelTitle: "",
            noOfRowConsiderAsHeader: ""
        };
        this.ddrHttpService.downloadV2DdrReports(JSON.stringify(downloadObj)).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["DownloadAngularReportLoadingState"]) {
                return;
            }
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["DownloadAngularReportLoadedState"]) {
                this.openDownloadReports(state.data);
                return;
            }
        }, (state) => {
            console.error('Error loading:', state.data);
        });
    }
    openDownloadReports(res) {
        console.log('file name generate ===', res);
        window.open(decodeURIComponent(this.ddrData.getHostWithoutLocation(this.getHostUrl(true))) + '/common/' + res);
    }
    getHeaders(fieldName) {
        switch (fieldName) {
            case 'objName':
                return 'Object Name';
            case 'status':
                return 'Status';
            case 'httpCode':
                return 'HTTP Code';
            case 'connReused':
                return 'Reused Conn.';
            case 'sslReused':
                return 'Reused SSL';
            case 'startTime':
                return 'Start Time';
            case 'totalTime':
                return 'Total';
            case 'dnsLookup':
                return 'DNS';
            case 'connectTime':
                return 'Connect';
            case 'sslTime':
                return 'SSL';
            case 'reqTime':
                return 'Request';
            case 'firstByte':
                return '1st Byte';
            case 'contentDownload':
                return 'Content Download';
            case 'totalBytes':
                return 'Total bytes';
            case 'action':
                return 'Action';
        }
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.id.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        console.log("Hello u got that", url);
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    onSessTimingPanelEvent(event) {
        if (event.close) {
            this.isTableIconCollapsed = false;
            this.showTansactionTimeSidebar = false;
        }
    }
    viewCorrelation(rowData) {
        this.viewCorrelationId = true;
        this.getCorrelationData(rowData);
    }
    getCorrelationData(rowData) {
        this.isLoading = true;
        let arr;
        let correlationParam = "";
        this.scriptname = this.commonService.urlInstanceObj['scriptName'];
        this.pagename = rowData['pageName'];
        this.urlName = rowData['object'];
        this.userId = this.commonService.urlInstanceObj['useridx'];
        this.sessionId = this.commonService.urlInstanceObj['sessionId'];
        correlationParam += 'testRun=' + this.sessionService.session.testRun.id + '&scriptName=' + this.commonService.urlInstanceObj['scriptName'] + '&pageName=' + rowData['pageName'] + '&urlName=' + rowData['object'] + '&useridx=' + this.commonService.urlInstanceObj['useridx'] + '&childindex=' + this.commonService.urlInstanceObj['childindex'] + '&sessionId=' + this.commonService.urlInstanceObj['sessionId'] + '&pageInstance=' + this.commonService.urlInstanceObj['pageInstance'] + '&urlInstance=' + this.commonService.urlInstanceObj['urlInstance'];
        this.ddrHttpService.getCorrelationData(correlationParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["GetCorrelationLoadingState"]) {
                this.isLoading = true;
                return;
            }
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["GetCorrelationLoadedState"]) {
                this.setCorrelationValues(state.data);
                this.isLoading = false;
                return;
            }
        }, (state) => {
            console.log(state.error);
            this.isLoading = false;
        });
    }
    setCorrelationValues(data) {
        const lines = data.trim().split('\n');
        const keyValuePairs = {};
        lines.forEach((line) => {
            const [key, value] = line.split(': ');
            keyValuePairs[key] = value;
        });
        this.correlationId = keyValuePairs['X-Correlation-ID'];
        this.dynaTraceVal = keyValuePairs['x-dynaTrace'];
    }
    copyCorrelationId(correlationVal) {
        // this.messageService.add({ severity: 'success', summary: 'Copied to clipboard', detail: '' });
        this.clipboardService.copy(correlationVal);
        this.scriptUtilService.successMessage("Correlation Id copied to clipboard");
    }
    copyDynaTrace(dynatraceVal) {
        this.clipboardService.copy(dynatraceVal);
        this.scriptUtilService.successMessage("DynaTrace copied to clipboard");
    }
    copyScriptName(scriptname) {
        this.clipboardService.copy(scriptname);
        this.scriptUtilService.successMessage("Script Name copied to clipboard");
    }
    copyPageName(pagename) {
        this.clipboardService.copy(pagename);
        this.scriptUtilService.successMessage("Page Name copied to clipboard");
    }
    copyURLName(urlName) {
        this.clipboardService.copy(urlName);
        this.scriptUtilService.successMessage("URL Name copied to clipboard");
    }
    openTreeView() {
        this.dataObj = {
            hostUrl: this.getHostUrl(),
            id: this.id,
            pageName: this.pageName,
            scriptName: this.scriptName,
            sessionIndex: this.sessionIndex,
            reportType: this.reportType,
            pdKeyValue: this.pdKeyValue,
            startTime: this.startTime,
            respTime: this.respTime,
            childIndex: this.childIndex,
            strStrtTime: this.id.startTime,
            strEndTime: this.id.endTime,
            ndKeyValue: this.ndKeyValue
        };
        this.showTansactionTimeSidebar = true;
    }
    filteredDataForInputData(searchData, colName) {
        if (searchData)
            this.isFilter = true;
        else
            this.isFilter = false;
        this.dt.filter(searchData, colName, 'contains');
    }
    ngOnDestroy() {
        this.commonService.isBackButton = false;
        this.commonService.urlInstanceObj = {};
        // this.commonService.isUrlInstance = false;
    }
};
SessionTimingDetailComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__["DdrBreadcrumbService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_4__["NsCommonService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_10__["TransactionDetailService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["DDRHttpService"] },
    { type: _angular_cdk_clipboard__WEBPACK_IMPORTED_MODULE_13__["Clipboard"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_14__["ScriptUtilService"] },
    { type: src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_15__["TimebarService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('dt')
], SessionTimingDetailComponent.prototype, "dt", void 0);
SessionTimingDetailComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'session-timing-detail',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./session-timing-detail.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./session-timing-detail.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.scss")).default]
    })
], SessionTimingDetailComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.scss":
/*!************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.scss ***!
  \************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".ddr-lable-header {\n  font-size: 12px;\n  font-family: inherit;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.ts":
/*!**********************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.ts ***!
  \**********************************************************************************************************/
/*! exports provided: NsTransactionReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NsTransactionReportComponent", function() { return NsTransactionReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");





let NsTransactionReportComponent = class NsTransactionReportComponent {
    constructor(breadcrumbService, breadcrumb) {
        this.breadcrumbService = breadcrumbService;
        this.breadcrumb = breadcrumb;
        this.summaryReport = false;
        this.instanceReport = false;
        this.summarybystatusReport = false;
        this.transactionDetail = false;
        this.transactionSessionSummary = false;
        this.transactionFailure = false;
    }
    ngOnChanges() {
        this.loadComponent();
    }
    ngOnInit() {
        console.log('*** input ', this.id);
        this.loadComponent();
    }
    loadComponent() {
        console.log('*** loadComponent ', this.id);
        if (this.id === 'TransactionSummary') {
            this.summaryReport = true;
            this.summarybystatusReport = false;
            this.instanceReport = false;
            this.transactionDetail = false;
            this.transactionSessionSummary = false;
            this.transactionFailure = false;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMARY);
            this.breadcrumb.add({ label: 'Transaction Summary', routerLink: '/ddr/nsreports/TransactionSummary' });
        }
        else if (this.id === 'TransactionSummaryByStatus') {
            this.summarybystatusReport = true;
            this.summaryReport = false;
            this.instanceReport = false;
            this.transactionDetail = false;
            this.transactionSessionSummary = false;
            this.transactionFailure = false;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMAY_STATUS);
            this.breadcrumb.add({ label: 'Transaction Summary By Status', routerLink: '/ddr/nsreports/TransactionSummaryByStatus' });
        }
        else if (this.id === 'TransactionInstance') {
            this.instanceReport = true;
            this.summaryReport = false;
            this.summarybystatusReport = false;
            this.transactionDetail = false;
            this.transactionSessionSummary = false;
            this.transactionFailure = false;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].TRANSACTION_INSTANCE);
            this.breadcrumb.add({ label: 'Transaction Instance', routerLink: '/ddr/nsreports/TransactionInstance' });
        }
        else if (this.id === 'TransactionFailurereport') {
            this.transactionFailure = true;
            this.summaryReport = false;
            this.summarybystatusReport = false;
            this.instanceReport = false;
            this.transactionDetail = false;
            this.transactionSessionSummary = false;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].TRANSACTION_FAILURE);
            this.breadcrumb.add({ label: 'Transaction Failure', routerLink: '/ddr/nsreports/TransactionFailurereport' });
        }
        else if (this.id === 'TransactionDetails') {
            this.transactionDetail = true;
            this.summaryReport = false;
            this.summarybystatusReport = false;
            this.instanceReport = false;
            this.transactionSessionSummary = false;
            this.transactionFailure = false;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].TRANSACTION_DETAILS);
            this.breadcrumb.add({ label: 'Transaction Details Report', routerLink: '/ddr/nsreports/TransactionDetails' });
        }
        else if (this.id === 'TransactionSessionSummary') {
            this.transactionSessionSummary = true;
            this.summaryReport = false;
            this.summarybystatusReport = false;
            this.instanceReport = false;
            this.transactionDetail = false;
            this.transactionFailure = false;
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_3__["BREADCRUMB_ITEMS"].TRANSACTION_SESSION_SUMMARY);
            this.breadcrumb.add({ label: 'Transaction Session Summary', routerLink: '/ddr/nsreports/TransactionSessionSummary' });
        }
    }
};
NsTransactionReportComponent.ctorParameters = () => [
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__["DdrBreadcrumbService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["BreadcrumbService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], NsTransactionReportComponent.prototype, "id", void 0);
NsTransactionReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'ns-transaction-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ns-transaction-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ns-transaction-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.scss")).default]
    })
], NsTransactionReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.scss":
/*!*******************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.scss ***!
  \*******************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("transaction-details-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\ntransaction-details-report .ddr-box {\n  background-color: var(--background_color_1);\n}\ntransaction-details-report .ddr-graphpanel .highcharts-contextbutton {\n  display: none;\n}\ntransaction-details-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\ntransaction-details-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.ts":
/*!*****************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.ts ***!
  \*****************************************************************************************************************************************/
/*! exports provided: TransactionDetailsReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TransactionDetailsReportComponent", function() { return TransactionDetailsReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");


//import { DataTableModule, BlockUIModule, MultiSelectModule } from 'primeng/primeng';

//import { CavTopPanelNavigationService } from '../../../../../../main/services/cav-top-panel-navigation.service';

//import { CavConfigService } from "../../../../../../main/services/cav-config.service";
//import { DdrDataModelService } from "../../../../../../main/services/ddr-data-model.service";

//import { ChartModule } from 'angular2-highcharts';










let TransactionDetailsReportComponent = class TransactionDetailsReportComponent {
    constructor(commonService, 
    //private _navService: CavTopPanelNavigationService,
    _router, txService, 
    //private _cavConfigService: CavConfigService,
    //private _cavConfig: CavConfigService,
    _ddrData, breadcrumbService, nsCommonData, ddrData, ddrRequest, sessionService, breadcrumb, ddrHttpService) {
        this.commonService = commonService;
        this._router = _router;
        this.txService = txService;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.nsCommonData = nsCommonData;
        this.ddrData = ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.breadcrumb = breadcrumb;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_10__;
        this.loading = false;
        this.ajaxLoader = true;
        this.loader = false;
        this.filterCriteria = '';
        this.txLimit = 50;
        this.txOffset = 0;
        this.value = 1;
        this.showChart = false;
        this.thinkData = [];
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.relativePath = '';
        this.headerRelativePath = "/ddr/transaction-think-report/transaction-think-report.json";
        this.relativePath = 'ddr/transaction-details-report/transaction-details-report.json';
    }
    ngOnInit() {
        this.urlParam = this.commonService.getData();
        this.commonService.isToLoadSideBar = false;
        this.commonService.isBackButton = true;
        this.loading = true;
        this.screenHeight = Number(this.commonService.screenHeight) - 94;
        this.commonService.currentReport = "Transaction Details Report";
        this.randomNumber();
        this.average = this.msToTimeFormate(this.nsCommonData.averagetime) + "(hh:mm:ss.ms)";
        if (this._ddrData.isDetailsFlag)
            this.nsCommonData.transactionName = undefined;
        //check for key value in case of Breadcrumb
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.trStartTime = this.urlParam.startTime;
                this.trEndTime = this.urlParam.endTime;
                this.fillInstanceData();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b, _c;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Avg Page Response Time')
            me.openPageReport((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
    }
    fillInstanceData() {
        try {
            this.getTransactionDetailsData();
            this.setTestRunInHeader();
            this.cols = [
                { field: 'avgHeader', header: 'Average Time', action: true },
                { field: 'average', header: this.average, action: true },
                { field: 'percent', header: '100%', action: true },
            ];
            this.visibleCols = [
                'avgHeader', 'average', 'percent'
            ];
            this.columnOptions = [];
            for (let i = 0; i < this.cols.length; i++) {
                this.columnOptions.push({ label: this.cols[i].header, value: this.cols[i].field });
            }
        }
        catch (error) {
            console.log('error in intialization compaonent --> ', error);
        }
    }
    getTransactionDetailsData() {
        try {
            let ajaxParam = '';
            let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
            if (this.commonService.enableQueryCaching == 1) {
                ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
            }
            else {
                ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
            }
            ajaxParam += '&strStartTime=' + this.trStartTime +
                '&strEndTime=' + this.trEndTime +
                '&object=2';
            if (this.nsCommonData.transactionName)
                ajaxParam += '&transactionName=' + this.nsCommonData.transactionName;
            else if (this._ddrData.transactionName)
                ajaxParam += '&transactionName=' + this._ddrData.transactionName;
            if (this.nsCommonData.sessionSummaryFlag == true) {
                ajaxParam += '&script=' + this.nsCommonData.scriptname;
                if (this.nsCommonData.statuscode !== '-')
                    ajaxParam += '&statusCode=' + this.nsCommonData.statuscode;
            }
            else {
                ajaxParam += '&statusCode=-2';
            }
            if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this._ddrData.vectorName;
            if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this._ddrData.generatorName;
            if (this.commonService.isFromTransactionSession || this.commonService.isFromTransactionSummary) {
                //over rides the other normal cases....
                ajaxParam += this.commonService.makeParamStringFromObjForNS(this.commonService.nsTransactionDetails, true);
                this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsTransactionDetails;
            }
            else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
                ajaxParam += this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true);
            }
            // url+=ajaxParam;
            ajaxParam += '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
            setTimeout(() => {
                this.openpopup();
            }, this._ddrData.guiCancelationTimeOut);
            this.ddrHttpService.getTransactionDetailsReportData(prefix, ajaxParam).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["TransactionDetailsReportLoadedState"]) {
                    this.assignTransactionDetailsData(state.data);
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    assignTransactionDetailsData(res) {
        // console.log("res>>>>>>>>>>>>>"+JSON.stringify(res));
        try {
            this.isCancelQuerydata = true;
            if (res.errorData) {
                this.errorData = res.errorData;
                this.loading = false;
                return;
            }
            if (res === null || res === undefined) {
                this.empty = true;
                this.loading = false;
                return;
            }
            setTimeout(() => {
                this.loading = false;
                this.loader = false;
            }, 2000);
            this.value = 1;
            this.loading = false;
            this.ajaxLoader = false;
            this.thinkTime = res.thinkTime;
            this.thinktimeDuration = this.msToTimeFormate(this.thinkTime) + "(hh:mm:ss.ms)";
            this.percentThink = res.percentThink;
            this.TransactionDetailsData = res.data;
            this.showfilterCriteria(res.startTime, res.endTime);
            this.createpieChart(this.TransactionDetailsData, this.thinkTime);
            this.thinkData = this.Immutablepush(this.thinkData, { 'avgHeader': 'Think Duration', 'average': this.thinkTime, 'percent': this.percentThink + '%' });
            this.thinkData.unshift({ 'avgHeader': 'Average Time', 'average': this.nsCommonData.averagetime, 'percent': '100' + '%' });
            //  console.log("this.thinkData************",this.thinkData);
        }
        catch (error) {
            console.log(error);
        }
    }
    openPageReport(rowData) {
        if (this.commonService.isFromTransactionSession || this.commonService.isFromTransactionSummary) {
            this.commonService.nsPageDetails = JSON.parse(JSON.stringify(this.commonService.nsTransactionDetails));
            this.commonService.isFromTranscationDetails = true;
        }
        //not routed param to page rn.
        this.nsCommonData.currRowData = rowData;
        this.nsCommonData.objectType = '2';
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].TRANSACTION_DETAILS;
        this._router.navigate(['ddr/nsreports/PageComponentDetail']);
    }
    /**Used to create Stacked bar chart based on data */
    createpieChart(StackedData, time) {
        this.piechartData = StackedData;
        if (this.piechartData.length == 0)
            this.showChart = false;
        else
            this.showChart = true;
        var dataArr = [];
        var barArr = [];
        dataArr.push({ "name": "Think Time", "y": Number(this.thinkTime), "color": "#f4720e" });
        for (let i = 0; i < this.piechartData.length; i++) {
            dataArr.push({ "name": this.piechartData[i]["pagename"], "y": Number(this.piechartData[i]["avgPageresponseTime"]), "color": "rgb(124, 181, 236)" });
            barArr.push({ "name": this.piechartData[i]["pagename"], "data": [Number(this.piechartData[i]["avgPageresponseTime"]) / 1000], "color": "rgb(124, 181, 236)" });
        }
        barArr.push({ "name": "Think Time", "data": [Number(this.thinkTime) / 1000], "color": "#f4720e" });
        this.options = {
            chart: {
                type: "pie",
                width: 500,
                height: 350,
            },
            credits: {
                enabled: false
            },
            title: {
                text: "Transaction Detail Report",
            },
            legend: {
            //    itemWidth : 600
            },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
            },
            plotOptions: {
                pie: {
                    allowPointSelect: true,
                    cursor: 'pointer',
                    dataLabels: {
                        enabled: true,
                        format: '<b>{point.name}</b>= {point.percentage:.2f} %'
                    },
                    showInLegend: true
                }
            },
            series: [
                {
                    name: "Percentage",
                    data: dataArr,
                    enableMouseTracking: true
                }
            ]
        };
        // split time chart
        this.StackBarChartOptions = {
            chart: {
                type: 'bar',
                width: 600,
                height: 250,
            },
            title: {
                text: 'Time Split Chart (Seconds)'
            },
            xAxis: {
                categories: ['Time']
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Total Time Consumption'
                }
            },
            credits: {
                enabled: false
            },
            legend: {
                showInLegend: true
            },
            plotOptions: {
                series: {
                    stacking: 'normal'
                }
            },
            series: barArr
        };
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        //if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { //Commented for A9 Migration.
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.urlParam.testRun = this.sessionService.session.testRun.id;
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    setTestRunInHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'Transaction Details Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
        }
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Transaction Details Report - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - Transaction Details Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    /** Method for progressbar */
    getProgressBar() {
        this.value = 1;
        let interval = setInterval(() => {
            this.value = this.value + Math.floor(Math.random() * 10) + 1;
            if (this.value >= 100) {
                this.value = 100;
                clearInterval(interval);
            }
        }, 300);
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    /**  FilterCritera for NS Summary */
    showfilterCriteria(startTime, endTime) {
        //if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') // Commented for A9 Migartion
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += "DC=" + (this.ddrData.dcName || 'Master');
        if (this.ddrData.startTimeInDateFormat) {
            this.filterCriteria += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
            this.filterCriteria = ', From=' + startTime;
        }
        if (this.ddrData.endTimeInDateFormat) {
            this.filterCriteria += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
            this.filterCriteria += ', To=' + endTime;
        }
        if (this._ddrData.generatorName)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.nsCommonData.transactionName || this._ddrData.transactionName) {
            this.filterCriteria += ', Transaction=' + (this.nsCommonData.transactionName || this._ddrData.transactionName);
        }
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
        if (this.filterCriteria.endsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
        }
        else
            this.filterCriteria += '';
    }
    /**  CustomSorting for Transaction Details Report */
    CustomsortOnColumns(event, tempData) {
        if (event.order == -1) {
            var temp = (event["field"]);
            event.order = 1;
            tempData = tempData.sort(function (a, b) {
                var value = Number(a[temp]);
                var value2 = Number(b[temp]);
                return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
            });
        }
        else {
            var temp = (event["field"]);
            event.order = -1;
            //asecding order
            tempData = tempData.sort(function (a, b) {
                var value = Number(a[temp]);
                var value2 = Number(b[temp]);
                return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
            });
        }
        this.TransactionDetailsData = [];
        //console.log(JSON.stringify(tempData));
        if (tempData) {
            tempData.map((rowdata) => { this.TransactionDetailsData = this.Immutablepush(this.TransactionDetailsData, rowdata); });
        }
    }
    /** Download report for Transaction Details report  */
    downloadReports(reports) {
        let pageweightedTime = '';
        let thinkTimeRenameArray = { 'avgHeader': 'Average Time', 'average': this.average, 'percent': '100%' };
        let transactionDetailRenameArray = { "pagename": "Page Name", "avgPageresponseTime": "Avg Page Response Time", "pageweightedTime": "Page Weighted Time", "avgPageRespPercent": "Page Weighted Time Percentage" };
        let thinkTimeColOrder = ["Average Time", this.average, '100%'];
        let transactionDetailColOrder = ["Page Name", "Avg Page Response Time", "Page Weighted Time", "Page Weighted Time Percentage"];
        //  this.thinkData.forEach((val,index)=>
        //  { delete val['pageindex'];
        //  });
        this.visibleCols = [
            'pagename', 'avgPageresponseTime', 'pageweightedTime', 'avgPageRespPercent'
        ];
        this.TransactionDetailsData.forEach((val, index) => {
            delete val['pageindex'];
            delete val['Total'];
            val['avgPageresponseTime'] = this.msToTimeFormate(val['avgPageresponseTime']);
            val['pageweightedTime'] = this.msToTimeFormate(val['avgPageresponseTime']);
        });
        let tableRowData = [];
        let headers = [];
        let isHeaderFlag = false;
        for (let i = 0; i < this.TransactionDetailsData.length; i++) {
            const rowData = this.TransactionDetailsData[i];
            const selectedRowData = [];
            if (headers.length > 0)
                isHeaderFlag = true;
            if (!isHeaderFlag)
                headers.push("#");
            selectedRowData.push("");
            for (let j = 0; j < this.visibleCols.length; j++) {
                if (!isHeaderFlag)
                    headers.push(this.getHeaders(this.visibleCols[j]));
                selectedRowData.push(rowData[this.visibleCols[j]]);
            }
            tableRowData.push(selectedRowData);
        }
        let downloadObj = {
            testRun: this.sessionService.session.testRun.id,
            cctx: this.sessionService.session.cctx,
            type: reports,
            skipColumn: "",
            rowData: tableRowData,
            header: headers,
            title: 'Transaction Detail Report',
            arrParaList: null,
            subTitle: "",
            forReport: "nsDdrReport",
            lowerPanelTitle: "",
            noOfRowConsiderAsHeader: ""
        };
        this.ddrHttpService.downloadV2DdrReports(downloadObj).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["DownloadAngularReportLoadingState"]) {
                return;
            }
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["DownloadAngularReportLoadedState"]) {
                this.openDownloadReports(state.data);
                return;
            }
        }, (state) => {
            console.error('Error loading:', state.data);
        });
    }
    openDownloadReports(res) {
        let downloadFileUrl = '';
        window.open(decodeURIComponent(this._ddrData.getHostWithoutLocation(this.getHostUrl(true))) + '/common/' + res);
    }
    getHeaders(fieldName) {
        switch (fieldName) {
            case 'pagename':
                return 'Page Name';
            case 'avgPageresponseTime':
                return 'Avg Page Response Time';
            case 'pageweightedTime':
                return 'Page Weighted Time';
            case 'avgPageRespPercent':
                return 'Page Weighted Time Percentage';
        }
    }
    ngOnDestroy() {
        this.commonService.isFromTransactionSummary = false;
        this.commonService.isFromTransactionSession = false;
        this._ddrData.isDetailsFlag = false;
        this.commonService.isBackButton = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
TransactionDetailsReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__["NsCommonService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_12__["BreadcrumbService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["DDRHttpService"] }
];
TransactionDetailsReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'transaction-details-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./transaction-details-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./transaction-details-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.scss")).default]
    })
], TransactionDetailsReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.scss":
/*!********************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.scss ***!
  \********************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("transaction-failure-report .ddr-lable-header {\n  font-size: 12px;\n  font-family: inherit;\n}\ntransaction-failure-report .ddr-graphpanel .highcharts-contextbutton {\n  display: none;\n}\ntransaction-failure-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\ntransaction-failure-report .highcharts-legend-item {\n  pointer-events: none;\n}\ntransaction-failure-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\ntransaction-failure-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.ts":
/*!******************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.ts ***!
  \******************************************************************************************************************************************/
/*! exports provided: TransactionFailureReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TransactionFailureReportComponent", function() { return TransactionFailureReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");














let TransactionFailureReportComponent = class TransactionFailureReportComponent {
    constructor(commonService, _router, _ddrData, breadcrumbService, nsCommonData, ddrData, ddrRequest, sessionService, breadcrumb, ddrHttpService) {
        this.commonService = commonService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.nsCommonData = nsCommonData;
        this.ddrData = ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.breadcrumb = breadcrumb;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_10__;
        this.loading = false;
        this.ajaxLoader = true;
        this.loader = false;
        this.filterCriteria = '';
        this.txLimit = 50;
        this.txOffset = 0;
        this.showChart = false;
        this.value = 1;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.relativePath = "ddr/transaction-failure-report/transaction-failure-report.json";
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.commonService.isBackButton = true;
        this.loading = true;
        this.screenHeight = Number(this.commonService.screenHeight) - 200;
        this.commonService.currentReport = "Transaction Failure";
        this.randomNumber();
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        console.log("this.commonservice.nsTransactionFailure==>", this.commonService.nsTransactionFailure);
        this.urlParam = this.commonService.getData();
        this.trStartTime = this.urlParam.startTime;
        this.trEndTime = this.urlParam.endTime;
        console.log("this.urlParam >>>>>>>>>" + JSON.stringify(this.urlParam));
        if (this._ddrData.isDetailsFlag) {
            this.nsCommonData.transactionIndex = undefined;
            this.nsCommonData.transactionName = undefined;
        }
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.fillInstanceData();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) == "clickable") {
            me.openInstanceReport(event.cavEventExt.row);
        }
    }
    fillInstanceData() {
        try {
            this.getTransactionFailureData();
            this.setTestRunInHeader();
        }
        catch (error) {
            console.log('error in intialization compaonent --> ', error);
        }
    }
    getTransactionFailureData() {
        try {
            let url = '';
            let ajaxParam = '';
            let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
            if (this._ddrData.transactionName === 'All Transactions') {
                this.nsCommonData.transactionName = undefined;
                console.log("this.nsCommonData.transactionName", this._ddrData.transactionName);
                this._ddrData.transactionName = undefined;
            }
            if (this.commonService.enableQueryCaching == 1) {
                ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
            }
            else {
                ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
            }
            ajaxParam += '&strStartTime=' + this.trStartTime +
                '&strEndTime=' + this.trEndTime +
                '&object_id=' + this.nsCommonData.transactionIndex +
                '&statusCode=-1&object=2&reportType=failure';
            if (this._ddrData.transactionName || this.nsCommonData.transactionName) {
                ajaxParam += '&transactionName=' + (this._ddrData.transactionName || this.nsCommonData.transactionName);
            }
            if (this._ddrData.nsErrorName) {
                ajaxParam += '&nsErrorName=' + this._ddrData.nsErrorName;
            }
            if (this._ddrData.strStatus == -1) {
                ajaxParam += '&statusCode=' + this._ddrData.strStatus;
            }
            if (this.nsCommonData.sessionSummaryFlag == true) {
                ajaxParam += '&script=' + this.nsCommonData.scriptname;
            }
            if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this._ddrData.vectorName;
            if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this._ddrData.generatorName;
            if (this.commonService.isFromTransactionSummary || this.commonService.isFromTransactionSession) {
                if (this.nsCommonData.sessionSummaryFlag == true) {
                    this.commonService.nsTransactionFailure['script'] = this.nsCommonData.scriptname;
                }
                ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsTransactionFailure, true);
                //setting value to key
                this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsTransactionFailure;
            }
            else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
                this.commonService.isFromTransactionSummary = true;
                this.commonService.isFromTransactionSession = true;
                ajaxParam = this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true);
            }
            // url+=ajaxParam;
            ajaxParam += '&limit=' + this.txLimit + '&offset=' + this.txOffset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
            setTimeout(() => {
                this.openpopup();
            }, this._ddrData.guiCancelationTimeOut);
            this.ddrHttpService.getNSTransactionReportsData(prefix, ajaxParam).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["NSTransactionReportsLoadedState"]) {
                    this.assignTransactionFailureData(state.data);
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    assignTransactionFailureData(res) {
        // console.log("res>>>>>>>>>>>>>"+JSON.stringify(res));
        try {
            this.isCancelQuerydata = true;
            if (res.errorData) {
                this.errorData = res.errorData;
                this.loading = false;
                return;
            }
            if (res === null || res === undefined) {
                this.loading = false;
                this.empty = true;
                return;
            }
            setTimeout(() => {
                this.loading = false;
                this.loader = false;
            }, 2000);
            this.loading = false;
            this.ajaxLoader = false;
            this.TransactionFailureData = res.data;
            //if(this.nsCommonData.currRowData)
            //this.totalFailure= this.nsCommonData.currRowData.fail;
            //else{
            this.totalFailure = 0;
            this.TransactionFailureData.forEach((val, index) => {
                this.totalFailure = +this.totalFailure + Number(val['NumberOfFailures']);
            });
            // }
            this.showfilterCriteria(res.startTime, res.endTime);
            this.createStackBarChart(res);
        }
        catch (error) {
        }
    }
    openInstanceReport(rowData, flag) {
        console.log("rowData>>>>>>>-------" + JSON.stringify(rowData));
        this.ddrData.nsCQMFilter["Transaction Instance"] = undefined;
        if (this.commonService.isFromTransactionSummary || this.commonService.isFromTransactionSession) {
            console.log("transaction summary going out==>");
            this.commonService.nsTransactionInstance = JSON.parse(JSON.stringify(this.commonService.nsTransactionFailure));
            let param = this.commonService.nsTransactionInstance; //param holds ref of txnInstance obj.
            delete this.commonService.nsTransactionInstance['group'];
            this.commonService.nsTransactionInstance['reportType'] = 'instance';
            delete this.commonService.nsTransactionInstance['fields'];
            delete this.commonService.nsTransactionInstance['object_id'];
            if (!param['transactionName']) {
                param['transactionName'] = rowData.TransactionName;
                param['transidx'] = rowData.transactionindex;
            }
            this.commonService.nsTransactionInstance['statusCode'] = rowData.FailureType;
            this.commonService.isFromTransactionFailure = true;
            console.log("this.commonservice.nsTransactionInstance==>", this.commonService.nsTransactionInstance);
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Transaction Instance');
        this._ddrData.summaryToInstanceFlag = "true";
        this.nsCommonData.failureToInstanceFlag = true;
        if (this.nsCommonData.sessionSummaryFlag == true) {
            this.nsCommonData.scriptname = rowData.scriptname;
        }
        if (flag == 'totalCount')
            this.nsCommonData.statuscode = '-1';
        else
            this.nsCommonData.statuscode = rowData.FailureType;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_FAILURE;
        this.nsCommonData.transactionInstancethroughsuccess = false;
        this.breadcrumb.add({ label: 'Transaction Instance', routerLink: '/ddr/nsreports/TransactionInstance' });
        this._router.navigate(['/ddr/nsreports/TransactionInstance']);
    }
    /**Used to create stacked Column chart based on FailureCount */
    createStackBarChart(res) {
        this.chartData = res.data;
        if (this.chartData.length == 0)
            this.showChart = false;
        else
            this.showChart = true;
        var failureInfoArr = [];
        var failureCount = [];
        for (var j = 0; j < this.chartData.length; j++) {
            var failuretype = this.chartData[j]["Failurevalue"];
            failureCount[j] = [Number(this.chartData[j]["NumberOfFailures"])];
            failureInfoArr.push({ "name": failuretype, "data": failureCount[j] });
        }
        console.log("failureInfoArr>>>>>>>>>>>>", failureInfoArr);
        this.options = {
            chart: {
                type: 'column'
            },
            title: {
                text: 'Failure Details Report for Transaction'
            },
            credits: {
                enabled: false
            },
            xAxis: {
                categories: ['Number of Failure']
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Number of Failures'
                },
                stackLabels: {
                    enabled: true,
                }
            },
            plotOptions: {
                column: {
                    stacking: 'normal',
                    pointWidth: 40
                }
            },
            series: failureInfoArr
        };
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        //  if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Commentted for A9 migration
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.urlParam.testRun = this.sessionService.session.testRun.id;
            console.log("all case url==>", hostDcName, "all case test run==>", this.urlParam.testRun, '----  ', this.sessionService.session.testRun.id);
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    setTestRunInHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'Transaction Failure Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
        }
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Transaction Failure Report - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - Transaction Failure Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    /**  FilterCritera for Failure Report */
    showfilterCriteria(startTime, endTime) {
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { //Commentted for A9 Migration
        if (this.sessionService.preSession.multiDc === true) {
            this.filterCriteria += "DC=" + (this.ddrData.dcName || 'Master');
        }
        if (this.ddrData.startTimeInDateFormat) {
            this.filterCriteria += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
            this.filterCriteria = ', From=' + startTime;
        }
        if (this.ddrData.endTimeInDateFormat) {
            this.filterCriteria += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
            this.filterCriteria += ', To=' + endTime;
        }
        if (this._ddrData.generatorName && this.ddrData.generatorName != this.sessionService.session.testRun.id)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.nsCommonData.transactionName || this._ddrData.transactionName) {
            this.filterCriteria += ', Transaction=' + (this.nsCommonData.transactionName || this._ddrData.transactionName);
        }
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
        if (this.filterCriteria.endsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
        }
        else
            this.filterCriteria += '';
    }
    ngOnDestroy() {
        this.commonService.isFromTransactionSummary = false;
        this.commonService.isBackButton = false;
        this._ddrData.isDetailsFlag = false;
        console.log("ondestroy of failure called");
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        console.log("Hello u got that", url);
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
TransactionFailureReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_11__["BreadcrumbService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["DDRHttpService"] }
];
TransactionFailureReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'transaction-failure-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./transaction-failure-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./transaction-failure-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.scss")).default]
    })
], TransactionFailureReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.scss":
/*!**********************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.scss ***!
  \**********************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("transaction-instance-report .colgroup-col col {\n  min-width: 180px !important;\n}\ntransaction-instance-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\ntransaction-instance-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\ntransaction-instance-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\ntransaction-instance-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.ts":
/*!********************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.ts ***!
  \********************************************************************************************************************************************/
/*! exports provided: TransactionInstanceReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TransactionInstanceReportComponent", function() { return TransactionInstanceReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");

















let TransactionInstanceReportComponent = class TransactionInstanceReportComponent {
    constructor(commonService, txService, _router, _ddrData, breadcrumbService, nsCommonData, ddrData, ddrRequest, sessionService, breadcrumb, scriptUtilService, route, dialogService, ddrHttpService) {
        this.commonService = commonService;
        this.txService = txService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.nsCommonData = nsCommonData;
        this.ddrData = ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.breadcrumb = breadcrumb;
        this.scriptUtilService = scriptUtilService;
        this.route = route;
        this.dialogService = dialogService;
        this.ddrHttpService = ddrHttpService;
        this.InstanceDetail = [{ "TransactionName": "", "scriptName": "", "location": "", "access": "", "browser": "", "userId": "", "sessionId": "", "txInstance": "", "childIndex": "", "startTime": "", "absoluteStartTime": "", "responseTime": "", "statusName": ""
            }];
        this.loading = false;
        this.ajaxLoader = true;
        this.loader = false;
        this.filterCriteria = '';
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.txLimit = 50;
        this.txOffset = 0;
        this.value = 1;
        this.toolTipStatus = '';
        this.filterStatus = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.isDdrEnabled = true;
        this.errorData = "";
        this.relativePath = 'ddr/transaction-instance-report/transaction-instance-report.json';
    }
    ngOnInit() {
        this.screenHeight = Number(this.commonService.screenHeight) - 130;
        this.commonService.isToLoadSideBar = true;
        this.first.first = 0;
        this.rows.rows = 50;
        this.loading = true;
        this.urlParam = this.commonService.getData();
        this.commonService.currentReport = "Transaction Instance";
        this.randomNumber();
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        this.subscribeTransaction = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Transaction Instance") {
                this.loading = true;
                this.txLimit = 50;
                this.txOffset = 0;
                this.fillInstanceData();
            }
        });
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                if (this._ddrData.WAN_ENV < 1 && !this.sessionService.session.testRun.cmt)
                    this.relativePath = 'ddr/transaction-instance-report/transaction-instance-report2.json';
                else if (this._ddrData.WAN_ENV < 1 && this.sessionService.session.testRun.cmt)
                    this.relativePath = 'ddr/transaction-instance-report/transaction-instance-report1.json';
                else if (this._ddrData.WAN_ENV >= 1 && !this.sessionService.session.testRun.cmt)
                    this.relativePath = 'ddr/transaction-instance-report/transaction-instance-report3.json';
                else
                    this.relativePath = 'ddr/transaction-instance-report/transaction-instance-report.json';
                this.trStartTime = this.urlParam.startTime;
                this.trEndTime = this.urlParam.endTime;
                this.fillInstanceData();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Script Name')
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'User Id')
            me.openUserSessionReport((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row);
        if (((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label) == 'Response Time')
            me.opentimeDetailsReport((_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.row);
    }
    fillInstanceData() {
        try {
            this.getTransactionInstanceData();
            this.getTransactionInstanceCount();
            this.setTestRunInHeader();
            if (this._ddrData.WAN_ENV < 1) {
                this.nsCommonData.isFromSummary = true;
            }
        }
        catch (error) {
            console.log('error in intialization compaonent --> ', error);
        }
    }
    getTransactionInstanceData() {
        try {
            let ajaxParam = '';
            let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
            if (this._ddrData.transactionError == true)
                ajaxParam += this._ddrData.product + '&cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
            else if (this.commonService.enableQueryCaching == 1) {
                ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
            }
            else {
                ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
            }
            if (this.commonService.isFilterFromNSSideBar && Object.keys(this.commonService.nsTransactionInstance).length != 0) {
                if (this.nsCommonData.summaryToInstanceFlag == true && this._ddrData.summaryToInstanceFlag == "true" && !(this.commonService.nsTransactionInstance['transidx'])) {
                    this.commonService.nsTransactionInstance['transidx'] = this.nsCommonData.transactionIndex;
                    delete this.commonService.nsTransactionInstance['transactionName'];
                }
                if (this.nsCommonData.failureToInstanceFlag == true && this._ddrData.summaryToInstanceFlag == "true"
                    && !(this.commonService.nsTransactionInstance['transidx'] && this.commonService.nsTransactionInstance['transactionName'])) {
                    // condition for failure to instance
                    this.commonService.nsTransactionInstance['transidx'] = this.nsCommonData.transactionIndex;
                    this.commonService.nsTransactionInstance['transactionName'] = this.nsCommonData.transactionName;
                }
                if (this.nsCommonData.sessionSummaryFlag === true && this._ddrData.summaryToInstanceFlag == "true"
                    && !(this.commonService.nsTransactionInstance['transidx'] && this.commonService.nsTransactionInstance['transactionName'])) {
                    this.commonService.nsTransactionInstance['script'] = this.nsCommonData.scriptname;
                    this.commonService.nsTransactionInstance['transidx'] = this.nsCommonData.transactionIndex;
                    this.commonService.nsTransactionInstance['transactionName'] = this.nsCommonData.transactionName;
                }
                ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsTransactionInstance, true);
                // for FIlter CQM case    so that will update value in key pair.
                this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsTransactionInstance;
            }
            else {
                if (this._ddrData.transactionError == true) {
                    this.trStartTime = this._ddrData.startTime;
                    this.trEndTime = this._ddrData.endTime;
                }
                ajaxParam += '&strStartTime=' + this.trStartTime +
                    '&strEndTime=' + this.trEndTime +
                    '&object=2&reportType=instance';
                if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                    ajaxParam += '&groupName=' + this._ddrData.vectorName;
                if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                    ajaxParam += '&generatorName=' + this._ddrData.generatorName;
                if (this._ddrData.transactionName)
                    ajaxParam += '&transactionName=' + this._ddrData.transactionName;
                if (this.nsCommonData.summaryToInstanceFlag == true && this._ddrData.summaryToInstanceFlag == "true") {
                    ajaxParam += '&transidx=' + this.nsCommonData.transactionIndex;
                }
                if (this._ddrData.transactionError) {
                    //ajaxParam += '&transidx=' + this.nsCommonData.transactionIndex;
                    ajaxParam += '&transactionName=' + this._ddrData.transactionName;
                    ajaxParam += '&statusCode=' + this._ddrData.statuscode;
                }
                else if (this.nsCommonData.failureToInstanceFlag == true && this._ddrData.summaryToInstanceFlag == "true") {
                    // condition for failure to instance
                    if (this.nsCommonData.transactionIndex)
                        ajaxParam += '&transidx=' + this.nsCommonData.transactionIndex;
                    if (this.nsCommonData.transactionName)
                        ajaxParam += '&transactionName=' + this.nsCommonData.transactionName;
                    if (this.nsCommonData.statuscode)
                        ajaxParam += '&statusCode=' + this.nsCommonData.statuscode;
                }
                else if (this.nsCommonData.transactionInstancethroughsuccess) {
                    ajaxParam += '&statusCode=0';
                }
                else if (this._ddrData.strStatus == 0) {
                    ajaxParam += '&statusCode=' + this._ddrData.strStatus;
                }
                else if (this._ddrData.filtermode.toLowerCase() == "success") {
                    ajaxParam += '&statusCode=0';
                }
                else if (this._ddrData.filtermode.toLowerCase() == "failure") {
                    ajaxParam += '&statusCode=-1';
                }
                else {
                    ajaxParam += '&statusCode=-2';
                }
                if (this.nsCommonData.sessionSummaryFlag === true && this._ddrData.summaryToInstanceFlag == "true") {
                    ajaxParam += '&script=' + this.nsCommonData.scriptname;
                    ajaxParam += '&transidx=' + this.nsCommonData.transactionIndex;
                    ajaxParam += '&transactionName=' + this.nsCommonData.transactionName;
                }
                // this.commonService.nsTransactionInstance = this.commonService.makeObjectFromUrlParam(ajaxParam);
                //do not make ajax param here cz it will change the object stored in for breadcrumb via CQM.
            }
            if (this.commonService.isFromTransactionSummary || this.commonService.isFromTransactionSession || this.commonService.isFromTransactionFailure) {
                // this.commonService.nsTransactionInstance=this._ddrData.nsCQMFilter[this.commonService.currentReport];
                if (ajaxParam === undefined || ajaxParam === "")
                    ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsTransactionInstance, true);
                this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsTransactionInstance;
            }
            else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
                //condition for bread crumb. travel cz when other report are opened flags are turned off.
                this.commonService.isFromTransactionSummary = true;
                this.commonService.isFromTransactionSession = true;
                this.commonService.isFromTransactionFailure = true;
                ajaxParam = this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true);
            }
            if (this._ddrData.nsErrorName) {
                ajaxParam += '&nsErrorName=' + this._ddrData.nsErrorName;
            }
            this.commonService.nsTransactionInstance = this.commonService.makeObjectFromUrlParam(ajaxParam);
            this.url = ajaxParam;
            ajaxParam += '&limit=' + this.txLimit + '&offset=' + this.txOffset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
            setTimeout(() => {
                this.openpopup();
            }, this._ddrData.guiCancelationTimeOut);
            this.ddrHttpService.getNSTransactionReportsData(prefix, ajaxParam).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__["NSTransactionReportsLoadedState"]) {
                    this.assignTransactionInstanceData(state.data);
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    assignTransactionInstanceData(res) {
        this.isCancelQuerydata = true;
        //  console.log("res>>>>>>>>>>>>>"+JSON.stringify(res));
        this.commonService.isFilterFromNSSideBar = false;
        try {
            if (res.errorData) {
                this.errorData = res.errorData;
                this.loading = false;
                return;
            }
            if (res === null || res === undefined) {
                this.loading = false;
                this.empty = true;
                return;
            }
            if (res['data'].length == 0)
                this.empty = true;
            setTimeout(() => {
                this.loading = false;
                this.loader = false;
            }, 2000);
            this.value = 1;
            this.loading = false;
            this.ajaxLoader = false;
            this.InstanceDetail = res.data;
            this.TransactionInstanceData = this.getInstanceInfo();
            this.TransactionInstanceDataOrig = this.TransactionInstanceData;
            this.showfilterCriteria(res.startTime, res.endTime);
            this.commonService.customTimePlaceHolder = [];
            this.commonService.customTimePlaceHolder.push(res.startTime, res.endTime);
            setTimeout(() => {
                this.first = { first: this.txOffset };
                this.rows = { rows: this.txLimit };
            }, 1000);
        }
        catch (error) {
        }
    }
    getTransactionInstanceCount() {
        try {
            let counturl = '';
            let isCount = true;
            let prefix = this._ddrData.getHostWithoutLocation(this.getHostUrl());
            counturl = this.url + '&showCount=true' + '&productKey=' + this.sessionService.session.cctx.pk;
            this.ddrHttpService.getNSTransactionReportsData(prefix, counturl, isCount).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__["NSTransactionReportsLoadedState"]) {
                    this.assignTransactioninstanceCount(state.data);
                    isCount = false;
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    assignTransactioninstanceCount(res) {
        this.txTotalCount = res.totalCount;
        if (this.txLimit > this.txTotalCount)
            this.txLimit = Number(this.txTotalCount);
    }
    opentimeDetailsReport(rowData) {
        this.nsCommonData._sendAbsoluteTime = this.newMsToTimeFormat(rowData.absoluteStartTime);
        if (this.commonService.isFromTransactionSession || this.commonService.isFromTransactionSummary) {
            this.commonService.nsSessionTiming = JSON.parse(JSON.stringify(this.commonService.nsTransactionInstance));
            this.commonService.isFromTransactionInstance = true;
        }
        this.nsCommonData.currRowData = rowData;
        this.nsCommonData.objectType = '2';
        this._router.navigate(['/ddr/nsreports/sessionTiming']);
    }
    openSessionName(rowData) {
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_13__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Commentted for A9 migration
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.urlParam.testRun = this.sessionService.session.testRun.id;
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    setTestRunInHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'Transaction Instance Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
        }
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Transaction Instance Report - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - Transaction Instance Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    /**  Pagination method */
    paginate(event) {
        // event.first = Index of the first record  (used  as offset in query)
        // event.rows = Number of rows to display in new page  (used as limit in query)
        // event.page = Index of the new page
        // event.pageCount = Total number of pages
        this.txOffset = parseInt(event.first);
        this.txLimit = parseInt(event.rows);
        if (this.txLimit > this.txTotalCount)
            this.txLimit = Number(this.txTotalCount);
        this.loader = true;
        this.commonService.isFilterFromNSSideBar = true;
        this.fillInstanceData();
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    newMsToTimeFormat(duration) {
        if (!isNaN(duration)) {
            let duration1 = Number(duration);
            let timeInDateFormat;
            timeInDateFormat = this.sessionService.convertTimestampIntoFormattedString(duration1);
            return timeInDateFormat;
        }
        else {
            return duration;
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    /**  FilterCritera for NS Summary */
    showfilterCriteria(startTime, endTime) {
        this.filterCriteria = '';
        this.toolTipStatus = '';
        this.toolTipHint = '';
        this.filterStatus = '';
        let transactionInstance = this.commonService.nsTransactionInstance;
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Commentted for A9 migration.
        if (this.sessionService.preSession.multiDc === true) {
            this.filterCriteria += "DC=" + (this.ddrData.dcName || 'Master');
        }
        if (!this.commonService.isValidParamInObj(transactionInstance, 'phaseName')) {
            if (this.ddrData.startTimeInDateFormat) {
                this.filterCriteria += ', From=' + this.ddrData.startTimeInDateFormat;
            }
            else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
                this.filterCriteria = ', From=' + startTime;
            }
            if (this.ddrData.endTimeInDateFormat) {
                this.filterCriteria += ', To=' + this.ddrData.endTimeInDateFormat;
            }
            else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
                this.filterCriteria += ', To=' + endTime;
            }
        }
        if (this._ddrData.generatorName)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.nsCommonData.sessionSummaryFlag == true && this._ddrData.summaryToInstanceFlag == "true") {
            if (this.nsCommonData.scriptname !== 'NA' && this.nsCommonData.scriptname !== '' && this.nsCommonData.scriptname !== undefined) {
                this.filterCriteria += ', Script=' + this.nsCommonData.scriptname;
            }
        }
        if (this.commonService.isValidParamInObj(transactionInstance, 'script'))
            this.filterCriteria += ", script=" + transactionInstance.script;
        if (this.commonService.isValidParamInObj(transactionInstance, 'transactionName'))
            this.filterCriteria += ", Transaction Name=" + transactionInstance.transactionName;
        if (this.commonService.isValidParamInObj(transactionInstance, 'page'))
            this.filterCriteria += ", page" + transactionInstance.page;
        if (this.commonService.isValidParamInObj(transactionInstance, 'location') && this._ddrData.WAN_ENV > 0)
            this.filterCriteria += ", location=" + transactionInstance.location;
        if (this.commonService.isValidParamInObj(transactionInstance, 'access') && this._ddrData.WAN_ENV > 0)
            this.filterCriteria += ", access=" + transactionInstance.access;
        if (this.commonService.isValidParamInObj(transactionInstance, 'browser'))
            this.filterCriteria += ", browser=" + transactionInstance.browser;
        if (this.commonService.isValidParamInObj(transactionInstance, 'group'))
            this.filterCriteria += ", group=" + transactionInstance.group;
        if (this.commonService.isValidParamInObj(transactionInstance, 'order'))
            this.filterCriteria += ", order=" + transactionInstance.order;
        if (this.commonService.isValidParamInObj(transactionInstance, 'statusName')) {
            let status = transactionInstance['statusName'];
            if (status && status.length >= 20) {
                this.toolTipStatus += "Status= " + transactionInstance['statusName'];
                status = status.substring(0, 19);
                this.filterStatus += ", Status=" + status + " ....";
            }
            else
                this.filterStatus += ", Status=" + status;
        }
        if (this.commonService.isValidParamInObj(transactionInstance, 'phaseName'))
            this.filterCriteria += ", Phase Name=" + transactionInstance.phaseName;
        // this.filterCriteria += ", Status=" + transactionInstance.statusName;
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
        if (this.filterCriteria.endsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
        }
        else
            this.filterCriteria += '';
    }
    getInstanceInfo() {
        var InstanceArr = [];
        if (this.InstanceDetail.length > 0) {
            for (var i = 0; i < this.InstanceDetail.length; i++) {
                InstanceArr[i] = { TransactionName: this.InstanceDetail[i]["TransactionName"], scriptName: this.InstanceDetail[i]["scriptName"], location: this.InstanceDetail[i]["location"], access: this.InstanceDetail[i]["access"], browser: this.InstanceDetail[i]["browser"], userId: (this.InstanceDetail[i]["childIndex"] + ":" + this.InstanceDetail[i]["userId"]), userInst: this.InstanceDetail[i]["userId"], sessionInst: this.InstanceDetail[i]["sessionId"], sessionId: (this.InstanceDetail[i]["childIndex"] + ":" + this.InstanceDetail[i]["sessionId"]), txInstance: this.InstanceDetail[i]["txInstance"], childIndex: this.InstanceDetail[i]["childIndex"], startTime: this.InstanceDetail[i]["startTime"], absoluteStartTime: this.InstanceDetail[i]["absoluteStartTime"], responseTime: this.InstanceDetail[i]["responseTime"], statusName: this.InstanceDetail[i]["statusName"] };
            }
            return InstanceArr;
        }
        return InstanceArr;
    }
    openUserSessionReport(rowData) {
        if (this.commonService.isFromTransactionSession || this.commonService.isFromTransactionSummary) {
            this.commonService.nsUserSession = JSON.parse(JSON.stringify(this.commonService.nsTransactionInstance));
            this.commonService.isFromTransactionInstance = true;
        }
        this.nsCommonData.currRowData = rowData;
        this.nsCommonData.objectType = '2';
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_7__["BREADCRUMB_ITEMS"].TRANSACTION_INSTANCE;
        this.breadcrumb.add({ label: 'User Session', routerLink: '/ddr/nsreports/userSession' });
        this._router.navigate(['/ddr/nsreports/userSession']);
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.subscribeTransaction.unsubscribe();
        this.commonService.isFilterFromNSSideBar = false;
        this.commonService.isFromTransactionSession = false;
        this.commonService.isFromTransactionSummary = false;
        this.commonService.isFromTransactionFailure = false;
        this.nsCommonData.transactionInstancethroughsuccess = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.TransactionInstanceData = this.TransactionInstanceData.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.TransactionInstanceData = this.TransactionInstanceData.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.TransactionInstanceData = this.TransactionInstanceData.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.TransactionInstanceData = this.TransactionInstanceData.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.TransactionInstanceData = this.TransactionInstanceData.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.TransactionInstanceData = this.TransactionInstanceDataOrig;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.TransactionInstanceData = this.TransactionInstanceDataOrig;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
};
TransactionInstanceReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_6__["DdrBreadcrumbService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_8__["NsCommonService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_5__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__["ScriptUtilService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["ActivatedRoute"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_14__["DialogService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_16__["DDRHttpService"] }
];
TransactionInstanceReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'transaction-instance-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./transaction-instance-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./transaction-instance-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.scss")).default]
    })
], TransactionInstanceReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.scss":
/*!************************************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.scss ***!
  \************************************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("transaction-session-summary-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\ntransaction-session-summary-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\ntransaction-session-summary-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\ntransaction-session-summary-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.ts":
/*!**********************************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.ts ***!
  \**********************************************************************************************************************************************************/
/*! exports provided: TransactionSessionSummaryReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TransactionSessionSummaryReportComponent", function() { return TransactionSessionSummaryReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
















let TransactionSessionSummaryReportComponent = class TransactionSessionSummaryReportComponent {
    constructor(commonService, _router, _ddrData, breadcrumbService, nsCommonData, ddrData, ddrRequest, sessionService, breadcrumb, ddrHttpService, scriptUtilService, dialogService) {
        this.commonService = commonService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.nsCommonData = nsCommonData;
        this.ddrData = ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.breadcrumb = breadcrumb;
        this.ddrHttpService = ddrHttpService;
        this.scriptUtilService = scriptUtilService;
        this.dialogService = dialogService;
        this.loading = false;
        this.ajaxLoader = true;
        this.loader = false;
        this.filterCriteria = '';
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.txLimit = 50;
        this.txOffset = 0;
        this.value = 1;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.isDdrEnabled = true;
        this.errorData = "";
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.first.first = 0;
        this.rows.rows = 50;
        this.loading = true;
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.id = this.commonService.getData();
        this.urlParam = this.commonService.getData();
        this.commonService.currentReport = "Transaction Session Summary";
        this.randomNumber();
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        console.log("this.commonservice.nsTransactionSessionSummary==>", this.commonService.nsTransactionSummary);
        //  console.log("this._ddrData.filtermodefailure>>>>ff",this._ddrData.filtermode);
        console.log("this.urlParam >>>>>>>>>" + this.urlParam);
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.trStartTime = this.urlParam.startTime;
                this.trEndTime = this.urlParam.endTime;
                this.fillNSTransactionData();
            }
        });
    }
    fillNSTransactionData() {
        try {
            this.getTransactionSessionSummaryData();
            this.getTransactionSessionSummaryCount();
            this.setTestRunInHeader();
            if (this._ddrData.filtermode.toLowerCase() == 'success') {
                this.relativePath = "ddr/transaction-session-summary/transaction-session-summary.json";
            }
            else if (this._ddrData.filtermode.toLowerCase() == 'failure') {
                this.relativePath = "ddr/transaction-session-summary/transaction-session-summary1.json";
            }
            else if (this.nsCommonData.summaryByStatusFlag === false) {
                this.relativePath = "ddr/transaction-session-summary/transaction-session-summary2.json";
            }
            else
                this.relativePath = "ddr/transaction-session-summary/transaction-session-summary3.json";
            //console.log("this._ddrData.filtermodefailure>>>>ffillllllllllll",this._ddrData.filtermode);
            // this.cols = [
            //   { field: 'TransactionName', header: 'Transaction Name',  sortable: 'true',action: true, align: 'left', color: 'black', width: '120', title : 'Transaction Name'},
            //   { field: 'scriptname', header: 'Script Name', sortable:'true', action: true, align: 'left', color: 'black', width: '75', title : 'Script Name'},
            //   { field: 'tried', header: 'Tried', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : 'Tried'},
            //   { field: 'success', header: 'Success', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : 'Success'},
            //   { field: 'StatusType', header: 'Status',  sortable: 'true',action: true, align: 'left', color: 'black', width: '75', title : 'Status'},
            //   { field: 'fail', header: 'Fail', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : 'Fail'},
            //   { field: 'failPercent', header: '%Fail',  sortable: 'true',action: true, align: 'right', color: 'black', width: '75', title : '%Fail'},
            //   { field: 'min', header: 'Min', sortable:'custom', action: true,align: 'right', color: 'black', width: '75', title : 'Min'},
            //   { field: 'average', header: 'Average', sortable:'custom', action: true,align: 'right', color: 'black', width: '95', title : 'Average'},
            //   { field: 'max', header: 'Max', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : 'Max'},
            //   { field: 'median', header: 'Median', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : 'Median'},
            //   { field: 'eighty', header: 'P80', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : '80th (%) Percentile'},
            //   { field: 'ninety', header: 'P90', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : '90th (%) Percentile'},
            //   { field: 'ninetyFive', header: 'P95', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : '95th (%) Percentile'},
            //   { field: 'ninetyNine', header: 'P99', sortable:'custom', action: true, align: 'right', color: 'black', width: '75', title : '99th (%) Percentile'}
            // ];
            // this.visibleCols = [
            //   'TransactionName','scriptname','tried','success','StatusType','fail','failPercent','min','average','max','median','eighty','ninety','ninetyFive','ninetyNine'
            // ];
            // if (this._ddrData.filtermode.toLowerCase() == 'success'){
            //   this.cols.splice(4,3);
            //   this.visibleCols.splice(4,3);
            // }
            // else if(this._ddrData.filtermode.toLowerCase() == 'failure'){
            //   this.cols.splice(3,2);
            //   this.visibleCols.splice(3,2);
            // }
            // else if(this.nsCommonData.summaryByStatusFlag === false)
            // {
            //   this.cols.splice(4,1);
            //   this.visibleCols.splice(4,1);
            // }else{
            //   this.cols.splice(2,2);
            //   this.visibleCols.splice(2,2);
            //   //console.log("this.cols***--------",this.cols, "this.visibleCols*********--",this.visibleCols);
            //   this.cols.splice(3,2);
            //   this.visibleCols.splice(3,2);
            //   //console.log("this.cols***--------",this.cols, "this.visibleCols*********--",this.visibleCols);
            //   }
            // this.columnOptions = [];
            // for (let i = 0; i < this.cols.length; i++) {
            //   this.columnOptions.push({ label: this.cols[i].header, value: this.cols[i].field });
            // }
            //console.log('column options', this.columnOptions);
        }
        catch (error) {
            console.log('error in intialization compaonent --> ', error);
        }
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Script Name') {
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        }
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'Tried') {
            me.openInstanceReport((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row);
        }
        if (((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label) == 'Success') {
            me.openInstanceReport((_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.row, true);
        }
        if (((_l = (_k = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _k === void 0 ? void 0 : _k.columnClicked) === null || _l === void 0 ? void 0 : _l.label) == 'Fail') {
            me.openFailureReport((_m = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _m === void 0 ? void 0 : _m.row);
        }
        if (((_p = (_o = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _o === void 0 ? void 0 : _o.columnClicked) === null || _p === void 0 ? void 0 : _p.label) == 'Average') {
            me.openDetailsReport((_q = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _q === void 0 ? void 0 : _q.row);
        }
    }
    getTransactionSessionSummaryData() {
        try {
            let ajaxParam = '';
            let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
            if (this.commonService.enableQueryCaching == 1) {
                ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
            }
            else {
                ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
            }
            ajaxParam += '&strStartTime=' + this.trStartTime +
                '&strEndTime=' + this.trEndTime +
                '&transactionName=' + this.nsCommonData.transactionName +
                '&transidx=' + this.nsCommonData.transactionIndex +
                '&object=2&fields=4095&reportType=summary';
            if (this.nsCommonData.summaryByStatusFlag === true) {
                ajaxParam += '&group=session,status' +
                    '&statusCode=' + this.nsCommonData.statuscode;
            }
            else {
                ajaxParam += '&group=session' + '&statusCode=-2';
            }
            if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this._ddrData.vectorName;
            if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this._ddrData.generatorName;
            if (this.commonService.isFromTransactionSummary) {
                if (this.nsCommonData.summaryByStatusFlag === true) {
                    this.commonService.nsTRansactionSessionSummary['group'] = ['session', 'status'];
                    //this.commonService.nsTRansactionSessionSummary ['statusCode']=this.nsCommonData.statuscode;
                }
                else {
                    this.commonService.nsTRansactionSessionSummary['group'] = ['session'];
                }
                ajaxParam += this.commonService.makeParamStringFromObjForNS(this.commonService.nsTRansactionSessionSummary, true);
                //setting value to key
                this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsTRansactionSessionSummary;
            }
            else if (this._ddrData.nsCQMFilter[this.commonService.currentReport]) {
                this.commonService.isFromTransactionSummary = true;
                ajaxParam += this.commonService.makeParamStringFromObjForNS(this._ddrData.nsCQMFilter[this.commonService.currentReport], true);
            }
            this.url = ajaxParam;
            ajaxParam += '&limit=' + this.txLimit + '&offset=' + this.txOffset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
            setTimeout(() => {
                this.openpopup();
            }, this._ddrData.guiCancelationTimeOut);
            // this.ddrRequest.getDataUsingGet(dataurl).subscribe(data => (this.assignTransactionSessionSummaryData(data)));
            this.ddrHttpService.getNSTransactionReportsData(prefix, ajaxParam).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["NSTransactionReportsLoadedState"]) {
                    this.assignTransactionSessionSummaryData(state.data);
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    assignTransactionSessionSummaryData(res) {
        try {
            this.isCancelQuerydata = true;
            if (res.errorData) {
                this.errorData = res.errorData;
                this.loading = false;
                return;
            }
            if (res === null || res === undefined) {
                this.empty = true;
                return;
            }
            setTimeout(() => {
                this.loader = false;
            }, 2000);
            this.value = 1;
            this.loading = false;
            this.ajaxLoader = false;
            this.TransactionSessionSummaryData = res.data;
            this.showfilterCriteria(res.startTime, res.endTime);
            this.TransactionSessionSummaryDataOrig = this.TransactionSessionSummaryData;
            setTimeout(() => {
                this.first = { first: this.txOffset };
                this.rows = { rows: this.txLimit };
            }, 1000);
        }
        catch (error) {
        }
    }
    getTransactionSessionSummaryCount() {
        try {
            let counturl = '';
            let isCount = true;
            counturl = this.url + '&showCount=true';
            let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
            this.ddrHttpService.getNSTransactionReportsData(prefix, counturl, isCount).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["NSTransactionReportsLoadedState"]) {
                    this.assignTransactionSessionSummaryCount(state.data);
                    isCount = false;
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    assignTransactionSessionSummaryCount(res) {
        console.log("res>>>>>>>>>>>>>" + JSON.stringify(res));
        this.txTotalCount = res.totalCount;
        if (this.txLimit > this.txTotalCount)
            this.txLimit = Number(this.txTotalCount);
    }
    openSessionName(rowData) {
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_13__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    openInstanceReport(rowData, success) {
        console.log("rowData>>>>>>>-------" + JSON.stringify(rowData));
        if (this.commonService.isFromTransactionSummary) {
            console.log("transaction summary going out==>");
            this.commonService.nsTransactionInstance = JSON.parse(JSON.stringify(this.commonService.nsTRansactionSessionSummary));
            this.commonService.nsTransactionInstance['reportType'] = 'instance';
            delete this.commonService.nsTransactionInstance['fields'];
            if (this.commonService.nsTransactionInstance['group'] && this.commonService.nsTransactionInstance['order'])
                this.commonService.nsTransactionInstance = this.commonService.filterGroupOrder(this.commonService.nsTransactionInstance);
            else
                delete this.commonService.nsTransactionInstance['group'];
            if (!this.commonService.nsTransactionInstance['script']) {
                this.commonService.nsTransactionInstance['script'] = rowData.scriptname;
            }
            let param = this.commonService.nsTransactionInstance; //param holds ref of txnInstance obj.
            if (!param['transactionName']) {
                param['transactionName'] = rowData.TransactionName;
                //param['transidx'] = rowData.transactionindex;
            }
            this.commonService.isFromTransactionSession = true;
            console.log("this.commonservice.nsTransactionInstance==>", this.commonService.nsTransactionInstance);
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Transaction Instance');
        this._ddrData.summaryToInstanceFlag = "true";
        this.nsCommonData.sessionSummaryFlag = true;
        this.nsCommonData.scriptname = rowData.scriptname;
        this.nsCommonData.transactionName = rowData.TransactionName;
        this.nsCommonData.transactionIndex = rowData.transactionindex;
        this.nsCommonData.transactionInstancethroughsuccess = success;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].TRANSACTION_SESSION_SUMMARY;
        this.breadcrumb.add({ label: 'Transaction Instance', routerLink: '/ddr/nsreports/TransactionInstance' });
        this._router.navigate(['/ddr/nsreports/TransactionInstance']);
    }
    openDetailsReport(rowData) {
        console.log("rowData>>>>>>>-------" + JSON.stringify(rowData));
        if (this.commonService.isFromTransactionSummary) {
            console.log("his.commonService.nsTRansactionSessionSummary=====>", this.commonService.nsTRansactionSessionSummary);
            if (!this.commonService.nsTRansactionSessionSummary['script']) {
                this.commonService.nsTRansactionSessionSummary['script'] = rowData.scriptname;
            }
            this.commonService.nsTRansactionSessionSummary['transactionName'] = rowData.TransactionName;
            delete this.commonService.nsTRansactionSessionSummary['transidx'];
            this.commonService.nsTransactionDetails = JSON.parse(JSON.stringify(this.commonService.nsTRansactionSessionSummary));
            this.commonService.isFromTransactionSession = true;
        }
        this.nsCommonData.sessionSummaryFlag = true;
        this.nsCommonData.scriptname = rowData.scriptname;
        this.nsCommonData.averagetime = rowData.average;
        this.nsCommonData.statuscode = rowData.status;
        this.nsCommonData.transactionName = rowData.TransactionName;
        this.nsCommonData.transactionIndex = rowData.transactionindex;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].TRANSACTION_SESSION_SUMMARY;
        this.breadcrumb.add({ label: 'Transaction Details Report', routerLink: '/ddr/nsreports/TransactionDetails' });
        this._router.navigate(['/ddr/nsreports/TransactionDetails']);
    }
    openFailureReport(rowData) {
        if (this.commonService.isFromTransactionSummary) {
            console.log("transaction summary going out==>");
            this.commonService.nsTransactionFailure = JSON.parse(JSON.stringify(this.commonService.nsTRansactionSessionSummary));
            if (this.commonService.nsTransactionFailure['transidx']) {
                this.commonService.nsTransactionFailure['object_id'] = this.commonService.nsTransactionFailure['transidx'];
                delete this.commonService.nsTransactionFailure['transidx'];
            }
            delete this.commonService.nsTransactionFailure['scriptidx'];
            this.commonService.nsTransactionFailure['reportType'] = 'failure';
            if (this.commonService.nsTransactionFailure['statusCode'] == -2 || this.commonService.nsTransactionFailure['statusCode'] == -0) {
                this.commonService.nsTransactionFailure['statusCode'] = -1;
            }
            delete this.commonService.nsTransactionFailure['location'];
            delete this.commonService.nsTransactionFailure['access'];
            delete this.commonService.nsTransactionFailure['browser'];
            delete this.commonService.nsTransactionFailure['fields'];
            delete this.commonService.nsTransactionFailure['group'];
            delete this.commonService.nsTransactionFailure['order'];
            let param = this.commonService.nsTransactionFailure;
            if (!param['transactionName']) {
                param['transactionName'] = rowData.TransactionName;
            }
            this.commonService.isFromTransactionSession = true;
            console.log("this.commonservice.nsTransactionFailure==>", this.commonService.nsTransactionFailure);
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Transaction Failure');
        this.nsCommonData.sessionSummaryFlag = true;
        this.nsCommonData.scriptname = rowData.scriptname;
        this.nsCommonData.transactionName = rowData.TransactionName;
        this.nsCommonData.transactionIndex = rowData.transactionindex;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].TRANSACTION_SESSION_SUMMARY;
        this.breadcrumb.add({ label: 'Transaction Failure', routerLink: '/ddr/nsreports/TransactionFailurereport' });
        this._router.navigate(['/ddr/nsreports/TransactionFailurereport']);
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        //if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Commented for A9 Migration
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.urlParam.testRun = this.sessionService.session.testRun.id;
            console.log("all case url==>", hostDcName, "all case test run==>", this.urlParam.testRun, '-----  ', this.sessionService.session.testRun.id);
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    setTestRunInHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'Transaction Session Summary Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
        }
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud')
            this.strTitle = 'Transaction Session Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - Transaction Session Summary Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    /**  Pagination method */
    paginate(event) {
        // event.first = Index of the first record  (used  as offset in query)
        // event.rows = Number of rows to display in new page  (used as limit in query)
        // event.page = Index of the new page
        // event.pageCount = Total number of pages
        this.txOffset = parseInt(event.first);
        this.txLimit = parseInt(event.rows);
        if (this.txLimit > this.txTotalCount)
            this.txLimit = Number(this.txTotalCount);
        if ((this.txLimit + this.txOffset) > this.txTotalCount)
            this.txLimit = Number(this.txTotalCount) - Number(this.txOffset);
        this.loader = true;
        this.getTransactionSessionSummaryData();
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    /**  FilterCritera for NS Summary */
    showfilterCriteria(startTime, endTime) {
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { // Commented for A9 Migartion
        if (this.sessionService.preSession.multiDc === true) {
            this.filterCriteria += "DC=" + (this.ddrData.dcName || 'Master');
        }
        if (this.ddrData.startTimeInDateFormat) {
            this.filterCriteria += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
            this.filterCriteria = ', From=' + startTime;
        }
        if (this.ddrData.endTimeInDateFormat) {
            this.filterCriteria += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
            this.filterCriteria += ', To=' + endTime;
        }
        if (this._ddrData.generatorName)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.nsCommonData.transactionName !== 'NA' && this.nsCommonData.transactionName !== '' && this.nsCommonData.transactionName !== undefined) {
            this.filterCriteria += ', Transaction=' + this.nsCommonData.transactionName;
        }
        console.log('headerinfo', this.filterCriteria);
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
        if (this.filterCriteria.endsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
        }
        else
            this.filterCriteria += '';
    }
    formatter(value) {
        if (value != '' && !isNaN(value)) {
            return Number(Number(value)).toLocaleString();
        }
        else if (value === '') {
            return '-';
        }
        else
            return value;
    }
    ngOnDestroy() {
        this.commonService.isFromTransactionSummary = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        console.log("Hello u got that", url);
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.TransactionSessionSummaryData = this.TransactionSessionSummaryData.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.TransactionSessionSummaryData = this.TransactionSessionSummaryData.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.TransactionSessionSummaryData = this.TransactionSessionSummaryData.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.TransactionSessionSummaryData = this.TransactionSessionSummaryData.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.TransactionSessionSummaryData = this.TransactionSessionSummaryData.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.TransactionSessionSummaryData = this.TransactionSessionSummaryDataOrig;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.TransactionSessionSummaryData = this.TransactionSessionSummaryDataOrig;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
};
TransactionSessionSummaryReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__["NsCommonService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["DDRHttpService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_15__["ScriptUtilService"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_12__["DialogService"] }
];
TransactionSessionSummaryReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'transaction-session-summary-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./transaction-session-summary-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./transaction-session-summary-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.scss")).default]
    })
], TransactionSessionSummaryReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.scss":
/*!********************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.scss ***!
  \********************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("transaction-summary-report .colgroup-col col {\n  min-width: 120px !important;\n}\ntransaction-summary-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\ntransaction-summary-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\ntransaction-summary-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\ntransaction-summary-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.ts":
/*!******************************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.ts ***!
  \******************************************************************************************************************************************/
/*! exports provided: TransactionSummaryReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TransactionSummaryReportComponent", function() { return TransactionSummaryReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/shared/time-bar/service/time-bar.service */ "./src/app/shared/time-bar/service/time-bar.service.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! src/app/pages/ddr/constants/ns-ddr-header.constants */ "./src/app/pages/ddr/constants/ns-ddr-header.constants.ts");
















let TransactionSummaryReportComponent = class TransactionSummaryReportComponent {
    constructor(commonService, nsCommonData, _router, txService, _ddrData, breadcrumbService, ddrData, ddrRequest, sessionService, breadcrumb, timebarService, ddrHttpService, activeRoute) {
        this.commonService = commonService;
        this.nsCommonData = nsCommonData;
        this._router = _router;
        this.txService = txService;
        this._ddrData = _ddrData;
        this.breadcrumbService = breadcrumbService;
        this.ddrData = ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.breadcrumb = breadcrumb;
        this.timebarService = timebarService;
        this.ddrHttpService = ddrHttpService;
        this.activeRoute = activeRoute;
        this.loading = false;
        this.ajaxLoader = true;
        this.loader = false;
        this.filterCriteria = '';
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.txLimit = 50;
        this.txOffset = 0;
        this.value = 1;
        this.filterCriteriaUrl = '';
        this.completeUrl = '';
        this.filterStatus = '';
        this.statusHint = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.isCount = false;
        this.colsForTable = [];
        let tableConfig = {
            "config": {
                "globalFilter": true,
                "download": true,
            }
        };
        this.tableConfig = tableConfig;
        this.colsForTable[0] = {
            "cols": [
                {
                    "label": "Transaction Name",
                    "key": "TransactionName",
                    "type": 0,
                    "width": "15%"
                },
                {
                    "label": "Min",
                    "key": "min",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Max",
                    "key": "max",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Average",
                    "key": "average",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].DURATION_DATA_TYPE,
                    "click": "true",
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Median",
                    "key": "median",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P80",
                    "key": "eighty",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P90",
                    "key": "ninety",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P95",
                    "key": "ninetyFive",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P99",
                    "key": "ninetyNine",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_15__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                }
            ]
        };
    }
    ngOnInit() {
        this.loading = true;
        this.first.first = 0;
        this.rows.rows = 50;
        this.urlParam = this.commonService.getData();
        this.screenHeight = Number(this.commonService.screenHeight) - 100;
        this.activeRoute.queryParams.subscribe((params) => {
            if (Object.keys(params).length === 0) {
                this.commonService.resetNSDDRArguments();
            }
        });
        this.commonService.currentReport = "Transaction Summary";
        this.commonService.isToLoadSideBar = true;
        this.randomNumber();
        this.commonService.checkForNsKeyObj(this._ddrData.nsCQMFilter, this.commonService.currentReport);
        this.subscribeTransaction = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == "Transaction Summary") {
                this.loading = true;
                this.txLimit = 50;
                this.txOffset = 0;
                this.fillNSTransactionData();
            }
        });
        this.changeTabHeader();
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.trStartTime = this.urlParam.startTime;
                this.trEndTime = this.urlParam.endTime;
                this.fillNSTransactionData();
            }
        });
        this.makeColumns();
    }
    fillNSTransactionData() {
        try {
            this.getTransactionSummaryData();
            this.getTransactionSummaryCount();
            this.setTestRunInHeader();
        }
        catch (error) {
            console.log('error in intialization compaonent --> ', error);
        }
    }
    makeColumns() {
        if (this.commonService.nsTransactionSummary['group'] && (this.commonService.nsTransactionSummary['group'].indexOf('generator') != -1 || this.commonService.nsTransactionSummary['group'].indexOf('session') != -1)) {
            if (this.commonService.nsTransactionSummary['group'] && this.commonService.nsTransactionSummary['group'].indexOf('session') != -1) {
                this.colsForTable[0].cols.push({
                    "label": "Script Name",
                    "key": "scriptname",
                    "type": 0
                });
            }
            if (this.commonService.nsTransactionSummary['group'] && this.commonService.nsTransactionSummary['group'].indexOf('generator') != -1) {
                this.colsForTable[0].cols.push({
                    "label": "Generator Name",
                    "key": "generatorName",
                    "type": 0
                });
            }
        }
        else {
            this.colsForTable[0].cols.push({
                "label": "Script Count",
                "key": "sessionCount",
                "type": 1,
                "click": "true",
                "width": "7%"
            });
        }
        if (this.commonService.nsTransactionSummary['group'] && this.commonService.nsTransactionSummary['group'].indexOf('status') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Status",
                "key": "StatusType",
                "type": 0
            });
        }
        else if (this._ddrData.filtermode.toLowerCase() == "success") {
            this.colsForTable[0].cols.splice(1, 0, {
                "label": "Tried",
                "key": "tried",
                "type": 1,
                "width": '7%',
                "click": "true"
            });
            this.colsForTable[0].cols.splice(2, 0, {
                "label": "Success",
                "key": "success",
                "type": 1,
                "width": '7%',
                "click": "true"
            });
        }
        else if (this._ddrData.filtermode.toLowerCase() == "failure") {
            this.colsForTable[0].cols.splice(1, 0, {
                "label": "Tried",
                "key": "tried",
                "type": 1,
                "width": '7%',
                "click": "true"
            });
            this.colsForTable[0].cols.splice(2, 0, {
                "label": "Fail",
                "key": "fail",
                "type": 1,
                "width": '7%',
                "click": "true"
            });
            this.colsForTable[0].cols.splice(11, 0, {
                "label": "%Fail",
                "key": "failPercent",
                "type": 1,
                "width": '7%'
            });
        }
        else {
            this.colsForTable[0].cols.splice(1, 0, {
                "label": "Tried",
                "key": "tried",
                "type": 1,
                "width": '7%',
                "click": "true"
            });
            this.colsForTable[0].cols.splice(2, 0, {
                "label": "Success",
                "key": "success",
                "type": 1,
                "width": '7%',
                "click": "true"
            });
            this.colsForTable[0].cols.splice(3, 0, {
                "label": "Fail",
                "key": "fail",
                "type": 1,
                "width": '7%',
                "click": "true"
            });
            this.colsForTable[0].cols.splice(12, 0, {
                "label": "%Fail",
                "key": "failPercent",
                "type": 1,
                "width": '7%'
            });
        }
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Tried') {
            me.openInstanceReport((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        }
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'Success' && ((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row.success) !== '0') {
            me.openInstanceReport((_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.row, true);
        }
        if (((_j = (_h = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _h === void 0 ? void 0 : _h.columnClicked) === null || _j === void 0 ? void 0 : _j.label) == 'Fail' && ((_k = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _k === void 0 ? void 0 : _k.row.fail) !== '0') {
            me.openFailureReport((_l = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _l === void 0 ? void 0 : _l.row);
        }
        if (((_o = (_m = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _m === void 0 ? void 0 : _m.columnClicked) === null || _o === void 0 ? void 0 : _o.label) == 'Average') {
            me.openDetailsReport((_p = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _p === void 0 ? void 0 : _p.row);
        }
        if (((_r = (_q = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _q === void 0 ? void 0 : _q.columnClicked) === null || _r === void 0 ? void 0 : _r.label) == 'Script Count') {
            me.opensessionCountReport((_s = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _s === void 0 ? void 0 : _s.row);
        }
    }
    getTransactionSummaryData() {
        try {
            this.isCount = false;
            let ajaxParam = '';
            let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
            if (this.commonService.enableQueryCaching == 1) {
                ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
            }
            else {
                ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
            }
            if (this.commonService.isFilterFromNSSideBar && Object.keys(this.commonService.nsTransactionSummary).length != 0) {
                this.commonService.isCQM = true; // on applying filter this is set true;
                if (this.summarybystatusReport) {
                    let group = [];
                    group = this.commonService.nsTransactionSummary['group'];
                    if (group[0] == '' || group[0] == undefined) {
                        group[0] = 'status';
                    }
                    this.commonService.nsTransactionSummary['group'] = group;
                }
                ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsTransactionSummary, true);
                // for FIlter CQM case    so that will update value in key pair.
                this._ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsTransactionSummary;
            }
            else {
                ajaxParam += '&strStartTime=' + this.trStartTime +
                    '&strEndTime=' + this.trEndTime +
                    '&object=2&fields=4095&reportType=summary';
                if (this._ddrData.filtermode.toLowerCase() == "success") {
                    ajaxParam += '&statusCode=0';
                }
                else if (this._ddrData.filtermode.toLowerCase() == "failure") {
                    ajaxParam += '&statusCode=-1';
                }
                else {
                    ajaxParam += '&statusCode=-2';
                }
                if (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                    ajaxParam += '&groupName=' + this._ddrData.vectorName;
                if (this._ddrData.generatorName || (this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                    ajaxParam += '&generatorName=' + this._ddrData.generatorName;
                if (this._ddrData.transactionName)
                    ajaxParam += '&transactionName=' + this._ddrData.transactionName;
                if (this.summarybystatusReport === true) {
                    ajaxParam += '&group=status';
                }
                if (this._ddrData.nsErrorName) {
                    ajaxParam += '&nsErrorName=' + this._ddrData.nsErrorName;
                }
            }
            this.commonService.nsTransactionSummary = this.commonService.makeObjectFromUrlParam(ajaxParam);
            this.url = ajaxParam;
            ajaxParam += '&limit=' + this.txLimit + '&offset=' + this.txOffset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
            setTimeout(() => {
                this.openpopup();
            }, this._ddrData.guiCancelationTimeOut);
            this.ddrHttpService.getNSTransactionReportsData(prefix, ajaxParam, this.isCount).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["NSTransactionReportsLoadedState"]) {
                    this.assignTransactionSummaryData(state.data);
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    assignTransactionSummaryData(res) {
        this.isCancelQuerydata = true;
        this.commonService.isFilterFromNSSideBar = false;
        try {
            if (res.errorData) {
                this.errorData = res.errorData;
                this.loading = false;
                return;
            }
            if (res === null || res === undefined) {
                this.loading = false;
                this.empty = true;
                return;
            }
            if (res['data'].length == 0)
                this.empty = true;
            setTimeout(() => {
                this.loading = false;
                this.loader = false;
            }, 2000);
            this.value = 1;
            this.loading = false;
            this.ajaxLoader = false;
            this.TransactionSummaryData = res.data;
            this.showfilterCriteria(res.startTime, res.endTime);
            this.commonService.customTimePlaceHolder = [];
            this.commonService.customTimePlaceHolder.push(res.startTime, res.endTime);
            this.TransactionSummaryDataOrig = this.TransactionSummaryData;
            setTimeout(() => {
                this.first = { first: this.txOffset };
                this.rows = { rows: this.txLimit };
            }, 1000);
        }
        catch (error) {
        }
    }
    getTransactionSummaryCount() {
        try {
            let counturl = '';
            counturl = this.url + '&showCount=true' + '&productKey=' + this.sessionService.session.cctx.pk;
            this.isCount = true;
            let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
            this.ddrHttpService.getNSTransactionReportsData(prefix, counturl, this.isCount).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_14__["NSTransactionReportsLoadedState"]) {
                    this.assignTransactionSummaryCount(state.data);
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
        catch (error) {
            console.log('error in getting data from rest call', error);
        }
    }
    assignTransactionSummaryCount(res) {
        this.txTotalCount = res.totalCount;
        if (this.txLimit > this.txTotalCount)
            this.txLimit = Number(this.txTotalCount);
    }
    changeTabHeader() {
        if (this.summarybystatusReport === false)
            this.tabName = "Transaction Summary";
        else
            this.tabName = "Transaction Summary By Status";
    }
    opensessionCountReport(rowData) {
        this.ddrData.nsCQMFilter["Transaction Session Summary"] = undefined;
        if (this.commonService.isCQM) {
            this.commonService.nsTRansactionSessionSummary = JSON.parse(JSON.stringify(this.commonService.nsTransactionSummary));
            let param = this.commonService.nsTRansactionSessionSummary;
            if (!param['transactionName']) {
                param['transactionName'] = rowData.TransactionName;
                param['transidx'] = rowData.transactionindex;
            }
            if (rowData['status'] && rowData['StatusType'] && rowData['status'] != '-' && rowData['StatusType'] != '-') {
                this.commonService.nsTRansactionSessionSummary['statusCode'] = rowData['status']; // cond for when user has selected group by status.
            }
            this.commonService.isFromTransactionSummary = true;
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Transaction Session Summary'); //so that current report and the next report object will be made.
        this.nsCommonData.transactionName = rowData.TransactionName;
        this.nsCommonData.transactionIndex = rowData.transactionindex;
        this.nsCommonData.summaryByStatusFlag = false;
        if (this.summarybystatusReport === true) {
            this.nsCommonData.summaryByStatusFlag = true;
            this.nsCommonData.statuscode = rowData.status;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMAY_STATUS;
        }
        else
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMARY;
        this.breadcrumb.add({ label: 'Transaction Session Summary', routerLink: '/ddr/nsreports/TransactionSessionSummary' });
        this._router.navigate(['/ddr/nsreports/TransactionSessionSummary']);
    }
    openInstanceReport(rowData, status) {
        this.ddrData.nsCQMFilter["Transaction Instance"] = undefined;
        if (this.commonService.isCQM) {
            this.commonService.nsTransactionInstance = JSON.parse(JSON.stringify(this.commonService.nsTransactionSummary));
            let param = this.commonService.nsTransactionInstance; //param holds ref of txnInstance obj.
            if (this.commonService.nsTransactionInstance['group'] && this.commonService.nsTransactionInstance['order'])
                this.commonService.nsTransactionInstance = this.commonService.filterGroupOrder(this.commonService.nsTransactionInstance);
            else
                delete this.commonService.nsTransactionInstance['group'];
            this.commonService.nsTransactionInstance['reportType'] = 'instance';
            delete this.commonService.nsTransactionInstance['fields'];
            delete this.commonService.nsTransactionInstance['object_id'];
            if (!param['transactionName']) {
                param['transactionName'] = rowData.TransactionName;
                param['transidx'] = rowData.transactionindex;
            }
            if (status) //true in case of all success on row click
                this.commonService.nsTransactionInstance['statusCode'] = '0';
            this.commonService.isFromTransactionSummary = true;
            if (rowData['status'] && rowData['StatusType'] && rowData['status'] && rowData['StatusType'] && rowData['status'] != '-' && rowData['StatusType'] != '-') {
                this.commonService.nsTRansactionSessionSummary['statusCode'] = rowData['status']; // cond for when user has selected group by status.
            }
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Transaction Instance');
        this._ddrData.summaryToInstanceFlag = "true";
        this.nsCommonData.summaryToInstanceFlag = true;
        this.nsCommonData.transactionName = rowData.TransactionName;
        this.nsCommonData.transactionIndex = rowData.transactionindex;
        this.nsCommonData.failureToInstanceFlag = false;
        this.nsCommonData.transactionInstancethroughsuccess = status;
        if (this.summarybystatusReport === true)
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMAY_STATUS;
        else
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMARY;
        this.breadcrumb.add({ label: 'Transaction Instance', routerLink: '/ddr/nsreports/TransactionInstance' });
        this._router.navigate(['/ddr/nsreports/TransactionInstance']);
    }
    openDetailsReport(rowData) {
        if (this.commonService.isCQM) {
            this.commonService.nsTransactionDetails = JSON.parse(JSON.stringify(this.commonService.nsTransactionSummary));
            delete this.commonService.nsTransactionDetails['transidx']; //details doesnt support transaction id.
            let param = this.commonService.nsTransactionDetails;
            if (!param['transactionName']) {
                param['transactionName'] = rowData.TransactionName;
            }
            this.commonService.isFromTransactionSummary = true;
        }
        this.nsCommonData.sessionSummaryFlag = false;
        this.nsCommonData.averagetime = rowData.average;
        this.nsCommonData.transactionName = rowData.TransactionName;
        this.nsCommonData.transactionIndex = rowData.transactionindex;
        if (this.summarybystatusReport === true)
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMAY_STATUS;
        else
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMARY;
        this.breadcrumb.add({ label: 'Transaction Details Report', routerLink: '/ddr/nsreports/TransactionDetails' });
        this._router.navigate(['/ddr/nsreports/TransactionDetails']);
    }
    openFailureReport(rowData) {
        if (this.commonService.isCQM) {
            this.commonService.nsTransactionFailure = JSON.parse(JSON.stringify(this.commonService.nsTransactionSummary));
            if (this.commonService.nsTransactionFailure['transidx']) {
                this.commonService.nsTransactionFailure['object_id'] = this.commonService.nsTransactionFailure['transidx'];
                delete this.commonService.nsTransactionFailure['transidx'];
            }
            delete this.commonService.nsTransactionFailure['scriptname'];
            delete this.commonService.nsTransactionFailure['scriptidx'];
            this.commonService.nsTransactionFailure['reportType'] = 'failure';
            if (this.commonService.nsTransactionFailure['statusCode'] == -2 || this.commonService.nsTransactionFailure['statusCode'] == -0) {
                this.commonService.nsTransactionFailure['statusCode'] = -1;
            }
            delete this.commonService.nsTransactionFailure['location'];
            delete this.commonService.nsTransactionFailure['access'];
            delete this.commonService.nsTransactionFailure['browser'];
            delete this.commonService.nsTransactionFailure['fields'];
            delete this.commonService.nsTransactionFailure['group'];
            delete this.commonService.nsTransactionFailure['order'];
            let param = this.commonService.nsTransactionFailure;
            if (!param['transactionName']) {
                param['transactionName'] = rowData.TransactionName;
            }
            this.commonService.isFromTransactionSummary = true;
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'Transaction Failure'); //making object of failure so that from failure when we open instance we will be gtting object bro.
        this.nsCommonData.sessionSummaryFlag = false;
        this.nsCommonData.currRowData = rowData;
        this.nsCommonData.transactionName = rowData.TransactionName;
        this.nsCommonData.transactionIndex = rowData.transactionindex;
        if (this.summarybystatusReport === true)
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMAY_STATUS;
        else
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_6__["BREADCRUMB_ITEMS"].TRANSACTION_SUMMARY;
        this.breadcrumb.add({ label: 'Transaction Failure', routerLink: '/ddr/nsreports/TransactionFailurereport' });
        this._router.navigate(['/ddr/nsreports/TransactionFailurereport']);
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.urlParam.testRun = this.sessionService.session.testRun.id;
        }
        else {
            hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    setTestRunInHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm') {
            if (this.summarybystatusReport === true)
                this.strTitle = 'Transaction Summary By Status Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
            else
                this.strTitle = 'Transaction Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud') {
            if (this.summarybystatusReport === true)
                this.strTitle = 'Transaction Summary By Status Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (NetCloud -) due to A-9 ....
            else
                this.strTitle = 'Transaction Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else {
            if (this.summarybystatusReport === true)
                this.strTitle = 'Netdiagnostics Enterprise - Transaction Summary By Status Report - Session : ' + this.sessionService.session.testRun.id;
            else
                this.strTitle = 'Netdiagnostics Enterprise - Transaction Summary Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    /**  Pagination method */
    paginate(event) {
        // event.first = Index of the first record  (used  as offset in query)
        // event.rows = Number of rows to display in new page  (used as limit in query)
        // event.page = Index of the new page
        // event.pageCount = Total number of pages
        this.txOffset = parseInt(event.first);
        this.txLimit = parseInt(event.rows);
        if (this.txLimit > this.txTotalCount)
            this.txLimit = Number(this.txTotalCount);
        if ((this.txLimit + this.txOffset) > this.txTotalCount)
            this.txLimit = Number(this.txTotalCount) - Number(this.txOffset);
        this.loader = true;
        this.getProgressBar();
        this.commonService.isFilterFromNSSideBar = true;
        this.getTransactionSummaryData();
    }
    /** Method for progressbar */
    getProgressBar() {
        this.value = 1;
        let interval = setInterval(() => {
            this.value = this.value + Math.floor(Math.random() * 10) + 1;
            if (this.value >= 100) {
                this.value = 100;
                clearInterval(interval);
            }
        }, 300);
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    /**  FilterCritera for NS Summary */
    showfilterCriteria(startTime, endTime) {
        this.filterCriteria = '';
        this.statusHint = '';
        this.filterStatus = '';
        let transactionSummary = this.commonService.nsTransactionSummary;
        if (this.sessionService.preSession.multiDc === true) {
            this.filterCriteria += "DC=" + (this.ddrData.dcName || 'Master');
        }
        if (!this.commonService.isValidParamInObj(transactionSummary, 'phaseName')) {
            if (this.ddrData.startTimeInDateFormat) {
                this.filterCriteria += ', From=' + this.ddrData.startTimeInDateFormat;
            }
            else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
                this.filterCriteria += ', From=' + startTime;
            }
            if (this.ddrData.endTimeInDateFormat) {
                this.filterCriteria += ', To=' + this.ddrData.endTimeInDateFormat;
            }
            else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
                this.filterCriteria += ', To=' + endTime;
            }
        }
        if (this._ddrData.generatorName)
            this.filterCriteria += ', Generator Name=' + this._ddrData.generatorName;
        if (this._ddrData.vectorName && this._ddrData.vectorMetaData && this._ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this._ddrData.vectorName;
        if (this.commonService.isValidParamInObj(transactionSummary, 'script'))
            this.filterCriteria += ", script=" + transactionSummary.script;
        if (this.commonService.isValidParamInObj(transactionSummary, 'url')) {
            this.completeUrl = transactionSummary.url;
            this.filterCriteriaUrl = this.completeUrl;
            this.filterCriteriaUrl = this.filterCriteriaUrl.substring(0, 30);
            this.filterCriteriaUrl += ", url=" + this.filterCriteriaUrl;
        }
        else
            this.completeUrl = '';
        if (this.commonService.isValidParamInObj(transactionSummary, 'transactionName'))
            this.filterCriteria += ", Transaction Name=" + transactionSummary.transactionName;
        if (this.commonService.isValidParamInObj(transactionSummary, 'location'))
            this.filterCriteria += ", location=" + transactionSummary.location;
        if (this.commonService.isValidParamInObj(transactionSummary, 'access'))
            this.filterCriteria += ", access=" + transactionSummary.access;
        if (this.commonService.isValidParamInObj(transactionSummary, 'browser'))
            this.filterCriteria += ", browser=" + transactionSummary.browser;
        if (this.commonService.isValidParamInObj(transactionSummary, 'group'))
            this.filterCriteria += ", group=" + transactionSummary.group;
        if (this.commonService.isValidParamInObj(transactionSummary, 'order'))
            this.filterCriteria += ", order=" + transactionSummary.order;
        if (this.commonService.isValidParamInObj(transactionSummary, 'statusName')) {
            let status = transactionSummary['statusName'];
            if (status && status.length >= 20) {
                status = status.substring(0, 19);
                this.statusHint = transactionSummary['statusName'];
                this.filterStatus += ", Status=" + status + " ....";
            }
            else
                this.filterStatus += ", Status=" + status;
        }
        if (this.commonService.isValidParamInObj(transactionSummary, 'phaseName'))
            this.filterCriteria += ", Phase Name=" + transactionSummary.phaseName;
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
        if (this.filterCriteria.endsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
        }
        else
            this.filterCriteria += '';
    }
    formatter(value) {
        if (value != '' && !isNaN(value)) {
            return Number(Number(value)).toLocaleString();
        }
        else if (value === '') {
            return '-';
        }
        else
            return value;
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.subscribeTransaction.unsubscribe();
        this.commonService.isFromBreadCrumb = false;
        this.commonService.isCQM = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id;
        +"&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.TransactionSummaryData = this.TransactionSummaryData.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.TransactionSummaryData = this.TransactionSummaryData.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.TransactionSummaryData = this.TransactionSummaryData.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.TransactionSummaryData = this.TransactionSummaryData.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.TransactionSummaryData = this.TransactionSummaryData.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.TransactionSummaryData = this.TransactionSummaryDataOrig;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.TransactionSummaryData = this.TransactionSummaryDataOrig;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
};
TransactionSummaryReportComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_5__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_12__["TimebarService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["DDRHttpService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["ActivatedRoute"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], TransactionSummaryReportComponent.prototype, "summarybystatusReport", void 0);
TransactionSummaryReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'transaction-summary-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./transaction-summary-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./transaction-summary-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.scss")).default]
    })
], TransactionSummaryReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.scss":
/*!********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.scss ***!
  \********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.ts":
/*!******************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.ts ***!
  \******************************************************************************************/
/*! exports provided: NsUrlReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NsUrlReportComponent", function() { return NsUrlReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");




let NsUrlReportComponent = class NsUrlReportComponent {
    constructor(breadcrumbService, breadcrumb) {
        this.breadcrumbService = breadcrumbService;
        this.breadcrumb = breadcrumb;
        this.urlSummaryReport = false;
        this.urlSessionsummary = false;
        this.urlSummaryStatus = false;
        this.urlInstanceReport = false;
        this.urlFailure = false;
        this.urlDetail = false;
    }
    ngOnChanges() {
        this.loadComponent();
    }
    ngOnInit() {
        console.log('*** input ', this.id);
        this.loadComponent();
    }
    loadComponent() {
        console.log('*** loadComponent ', this.id);
        if (this.id == 'urlInstance') {
            this.urlSummaryReport = false;
            this.urlSessionsummary = false;
            this.urlFailure = false;
            this.urlDetail = false;
            this.urlInstanceReport = true;
            this.urlSummaryStatus = false;
            this.breadcrumb.add({ label: 'URL Instance', routerLink: '/ddr/nsreports/urlInstance' });
        }
        else if (this.id == 'urlSummary' || this.id === 'urlSummaryStatus') {
            this.urlSummaryReport = true;
            this.urlSessionsummary = false;
            this.urlSummaryStatus = false;
            this.urlInstanceReport = false;
            this.urlFailure = false;
            this.urlDetail = false;
            if (this.id === 'urlSummaryStatus') {
                this.urlSummaryStatus = true;
                this.breadcrumb.add({ label: 'URL Summary By Status', routerLink: '/ddr/nsreports/urlSummaryStatus' });
            }
            else {
                this.breadcrumb.add({ label: 'URL Summary', routerLink: '/ddr/nsreports/urlSummary' });
            }
        }
        else if (this.id === 'urlfail') {
            this.urlSummaryReport = false;
            this.urlSummaryStatus = false;
            this.urlSessionsummary = false;
            this.urlInstanceReport = false;
            this.urlFailure = true;
            this.urlDetail = false;
            this.breadcrumb.add({ label: 'URL Failure Report', routerLink: '/ddr/nsreports/urlfail' });
        }
        else if (this.id === 'urldetails') {
            this.urlSummaryReport = false;
            this.urlSummaryStatus = false;
            this.urlSessionsummary = false;
            this.urlInstanceReport = false;
            this.urlFailure = false;
            this.urlDetail = true;
            this.breadcrumb.add({ label: 'URL Component Details', routerLink: '/ddr/nsreports/urldetails' });
        }
        else if (this.id === 'urlsessionsummary') {
            this.urlSummaryReport = false;
            this.urlSummaryStatus = false;
            this.urlSessionsummary = true;
            this.urlInstanceReport = false;
            this.urlFailure = false;
            this.urlDetail = false;
            this.breadcrumb.add({ label: 'URL Session Summary', routerLink: '/ddr/nsreports/urlsessionsummary' });
        }
    }
};
NsUrlReportComponent.ctorParameters = () => [
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_2__["DdrBreadcrumbService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__["BreadcrumbService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], NsUrlReportComponent.prototype, "id", void 0);
NsUrlReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'ns-url-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ns-url-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ns-url-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.scss")).default]
    })
], NsUrlReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.scss":
/*!**************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.scss ***!
  \**************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-url-component-details .ddr-accordion .ui-accordion-content-wrapper .ui-accordion-content {\n  padding: 5px 0px;\n}\napp-url-component-details .ddr-graphpanel .highcharts-container .highcharts-contextbutton {\n  display: none !important;\n}\napp-url-component-details .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-url-component-details .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-url-component-details .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-url-component-details .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.ts":
/*!************************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.ts ***!
  \************************************************************************************************************************/
/*! exports provided: UrlComponentDetailsComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UrlComponentDetailsComponent", function() { return UrlComponentDetailsComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");














let UrlComponentDetailsComponent = class UrlComponentDetailsComponent {
    constructor(_router, breadcrumbService, commonService, ddrData, nsCommonData, ddrRequest, sessionService, txService, ddrHttpService) {
        this._router = _router;
        this.breadcrumbService = breadcrumbService;
        this.commonService = commonService;
        this.ddrData = ddrData;
        this.nsCommonData = nsCommonData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.txService = txService;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_10__;
        //urlParam:any;                                      //parameters from url
        //hosturl:any=window.location.host;
        this.object = 0; //object 0 passed in case of url report
        this.fields = 4095;
        this.statusCode = -2;
        this.limit = 22;
        this.offset = 0;
        this.showChart = false;
        this.showChartForRespTime = true;
        this.columnData = [];
        this.loading = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.showDownloadOption = true;
        this.isDdrEnabled = true;
        this.errorData = "";
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.currentReport = "URL Component Details";
        this.commonService.isBackButton = true;
        this.screenHeight = this.commonService.screenHeight;
        this.commonParams = this.commonService.getData();
        this.randomNumber();
        this.setTestRunInHeader();
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_DETAIL);
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.makeajaxcall();
            }
        });
        this.relativePath = "ddr/url-component-detail/url-component-detail.json";
    }
    ngOnDestroy() {
        this.nsCommonData.urldetaildata = undefined;
        this.commonService.isBackButton = false;
    }
    CreateCharts(jsonData) {
        let pieData = jsonData;
        this.showChart = true;
        var dataArr = [];
        let obj = {};
        for (let i = 0; i < pieData.length; i++) {
            var barArr = [];
            let curr = pieData[i];
            if (curr.dnsLookUp != 0 && curr.dnsLookUp != "-") {
                obj['DNS Lookup'] = {
                    'dataArr': { "name": "DNS Lookup", "y": Number(curr.dnsLookUpPct), "color": "#FF5733" },
                    'barArr': { "name": "DNS Lookup", "data": [Number(curr.dnsLookUp) / 1000], "color": "#FF5733" }
                };
            }
            if (curr.connectionTime != 0 && curr.connectionTime != "-") {
                obj['Connect'] = {
                    'dataArr': { "name": "Connect", "y": Number(curr.connectionTimePct), "color": "#808000" },
                    'barArr': { "name": "Connect", "data": [Number(curr.connectionTime) / 1000], "color": "#808000" }
                };
            }
            if (curr.sslHandshake != 0 && curr.sslHandshake != "-") {
                obj['sslHandshake'] = {
                    'dataArr': { "name": "SSL", "y": Number(curr.sslHandshakePct), "color": "#FF0000" },
                    'barArr': { "name": "SSL", "data": [Number(curr.sslHandshake) / 1000], "color": "#FF0000" }
                };
            }
            if (curr.requestSendTime != 0 && curr.requestSendTime != "-") {
                obj['requestSendTime'] = {
                    'dataArr': { "name": "Request Sent", "y": Number(curr.requestSendTimePct), "color": "#0000FF" },
                    'barArr': { "name": "Request Sent", "data": [Number(curr.requestSendTime) / 1000], "color": "#0000FF" }
                };
            }
            if (curr.firstByteReceivedTime != 0 && curr.firstByteReceivedTime != "-") {
                obj['First Byte'] = {
                    'dataArr': { "name": "First Byte", "y": Number(curr.firstByteReceivedTimePct), "color": "#4B3E45" },
                    'barArr': { "name": "First Byte", "data": [Number(curr.firstByteReceivedTime) / 1000], "color": "#4B3E45" }
                };
            }
            if (curr.contentDownloadTime != 0 && curr.contentDownloadTime != "-") {
                obj['Content Download'] = {
                    'dataArr': { "name": "Content Download", "y": Number(curr.contentDownloadTimePct), "color": "#F08080" },
                    'barArr': { "name": "Content Download", "data": [Number(curr.contentDownloadTime) / 1000], "color": "#F08080" }
                };
            }
        }
        let arr = [obj['DNS Lookup'], obj['Connect'], obj['sslHandshake'], obj['requestSendTime'], obj['First Byte'], obj['Content Download']];
        for (let i = arr.length; i > 0; i--) {
            if (!arr[i])
                continue;
            dataArr.push(arr[i]['dataArr']);
            barArr.push(arr[i]['barArr']);
        }
        this.options = {
            chart: {
                type: "pie",
                width: 700,
                height: 350
            },
            credits: {
                enabled: false
            },
            title: {
                text: "URL Component Details",
            },
            legend: {
                // itemWidth : 600
                align: 'right',
                verticalAlign: 'top',
                layout: 'vertical',
                x: 0,
                y: 100
            },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
            },
            plotOptions: {
                pie: {
                    allowPointSelect: true,
                    cursor: 'pointer',
                    dataLabels: {
                        enabled: true,
                        format: '<b>{point.name}</b>= {point.percentage:.2f} %'
                    },
                    showInLegend: true
                }
            },
            series: [
                {
                    name: "Percentage Response Time",
                    data: dataArr,
                    enableMouseTracking: true
                }
            ]
        };
        this.options1 = {
            chart: {
                type: 'bar',
                width: 600,
                height: 250
            },
            title: {
                text: 'Time Split Chart (Seconds)'
            },
            xAxis: {
                categories: ['Time']
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Total Time consumption'
                }
            },
            credits: {
                enabled: false
            },
            legend: {
                showInLegend: true
            },
            plotOptions: {
                series: {
                    stacking: 'normal'
                }
            },
            series: barArr
        };
    }
    setTestRunInHeader() {
        if (this.commonParams && this.commonParams.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'URL Component Details - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else if (this.commonParams && this.commonParams.product.toLowerCase() == 'netcloud')
            this.strTitle = 'URL Component Details - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - URL Component Details - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    makeajaxcall() {
        let startTime = this.commonParams.startTime;
        let endTime = this.commonParams.endTime;
        if (this.nsCommonData.urlidx != undefined || this.nsCommonData.urlidx != null)
            this.urlindex = this.nsCommonData.urlidx;
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        // if (this.url.endsWith("/"))
        //   this.url = this.url.substring(0, this.url.length - 1);
        let ajaxParam = '';
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.commonParams.testRun;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        ajaxParam += '&statusCode=-2&showCount=false' + '&reportType=urldetails' + '&strStatusName="NA"';
        if (this.nsCommonData.urlsessionsummarydata != undefined)
            ajaxParam += '&pageName=' + this.nsCommonData.urlsessionsummarydata.pageName;
        if (this.nsCommonData.pgDetailToURLDetailFlag == true) {
            let pageParams = this.nsCommonData.pgDetailToURLDetailData;
            ajaxParam += '&urltype=' + pageParams.urlType + '&pageidx=' + pageParams.pageIndex + '&startTime=' + pageParams.startTime + '&endTime=' + pageParams.endTime + '&object=' + pageParams.Object;
        }
        else
            ajaxParam += '&object=0' + '&startTime=' + startTime + '&endTime=' + endTime + '&urlidx=' + this.urlindex;
        if (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            ajaxParam += '&groupName=' + this.ddrData.vectorName;
        if (this.ddrData.generatorName || (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxParam += '&generatorName=' + this.ddrData.generatorName;
        ajaxParam += '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
        this.ddrHttpService.getNSUrlReportData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["NSUrlReportLoadedState"]) {
                this.Data(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    Data(json) {
        this.isCancelQuerydata = true;
        this.detailsData = json.data;
        if (json.errorData) {
            this.errorData = json.errorData;
            this.loading = false;
            this.empty = true;
            return;
        }
        this.loading = false;
        if (this.detailsData.length == 0) {
            this.empty = true;
            this.showDownloadOption = false;
        }
        this.filtercriteria(json.starttime, json.endtime);
        if (this.detailsData.length != 0) {
            this.columnData = [];
            /*Data for columns to be displayed*/
            for (let j = 0; j < this.detailsData.length; j++) {
                let obj = {};
                obj["component"] = "DNS Lookup";
                obj["avgResponseTime"] = this.detailsData[j].dnsLookUpAvg;
                obj["pctResponseTime"] = this.detailsData[j].dnsLookUpPct;
                obj["avgResponseTimesort"] = this.detailsData[j].dnsLookUp;
                obj["pctResponseTimesort"] = this.detailsData[j].dnsLookUpPct;
                this.columnData.push(JSON.parse(JSON.stringify(obj)));
                obj["component"] = "Connect";
                obj["avgResponseTime"] = this.detailsData[j].connectionTimeAvg;
                obj["pctResponseTime"] = this.detailsData[j].connectionTimePct;
                obj["avgResponseTimesort"] = this.detailsData[j].connectionTime;
                obj["pctResponseTimesort"] = this.detailsData[j].connectionTimePct;
                this.columnData.push(JSON.parse(JSON.stringify(obj)));
                obj["component"] = "SSL";
                obj["avgResponseTime"] = this.detailsData[j].sslHandshakeAvg;
                obj["pctResponseTime"] = this.detailsData[j].sslHandshakePct;
                obj["avgResponseTimesort"] = this.detailsData[j].sslHandshake;
                obj["pctResponseTimesort"] = this.detailsData[j].sslHandshakePct;
                this.columnData.push(JSON.parse(JSON.stringify(obj)));
                obj["component"] = "Request Sent";
                obj["avgResponseTime"] = this.detailsData[j].requestSendTimeAvg;
                obj["pctResponseTime"] = this.detailsData[j].requestSendTimePct;
                obj["avgResponseTimesort"] = this.detailsData[j].requestSendTime;
                obj["pctResponseTimesort"] = this.detailsData[j].requestSendTimePct;
                this.columnData.push(JSON.parse(JSON.stringify(obj)));
                obj["component"] = "First Byte";
                obj["avgResponseTime"] = this.detailsData[j].firstByteReceivedTimeAvg;
                obj["pctResponseTime"] = this.detailsData[j].firstByteReceivedTimePct;
                obj["avgResponseTimesort"] = this.detailsData[j].firstByteReceivedTime;
                obj["pctResponseTimesort"] = this.detailsData[j].firstByteReceivedTimePct;
                this.columnData.push(JSON.parse(JSON.stringify(obj)));
                obj["component"] = "Content Download";
                obj["avgResponseTime"] = this.detailsData[j].contentDownloadTimeAvg;
                obj["pctResponseTime"] = this.detailsData[j].contentDownloadTimePct;
                obj["avgResponseTimesort"] = this.detailsData[j].contentDownloadTime;
                obj["pctResponseTimesort"] = this.detailsData[j].contentDownloadTimePct;
                this.columnData.push(JSON.parse(JSON.stringify(obj)));
            }
            this.CreateCharts(this.detailsData);
        }
    }
    filtercriteria(startTime, endTime) {
        this.filter = "";
        if (this.sessionService.preSession.multiDc === true)
            this.filter += "DC=" + (this.ddrData.dcName || 'Master');
        if (this.ddrData.startTimeInDateFormat) {
            this.filter += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
            this.filter += ', From=' + startTime;
        }
        if (this.ddrData.endTimeInDateFormat) {
            this.filter += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
            this.filter += ', To=' + endTime;
        }
        if (this.nsCommonData.urldetaildata != undefined) {
            this.filter += ', URL=' + this.nsCommonData.urldetaildata.urlName;
        }
        if (this.nsCommonData.urlsessionsummarydata != undefined) {
            this.filter += ', Script Name=' + this.nsCommonData.urlsessionsummarydata.scriptName + ', Page Name=' + this.nsCommonData.urlsessionsummarydata.pageName + ', URL=' + this.nsCommonData.urlsessionsummarydata.urlName + ', URL Response Time=' + this.nsCommonData.urlsessionsummarydata.avgaverage + '(hh:mm:ss:ms)';
        }
        if (this.nsCommonData.urldetaildata != undefined) {
            if (this.nsCommonData.urldetaildata.avgaverage != undefined)
                this.filter += ', URL Response Time=' + this.nsCommonData.urldetaildata.avgaverage + '(hh:mm:ss:ms)';
        }
        if (this.ddrData.generatorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1) {
            this.filter += ', Generator Name=' + this.ddrData.generatorName;
        }
        if (this.ddrData.vectorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1) {
            this.filter += ', Group Name=' + this.ddrData.vectorName;
        }
        if (this.nsCommonData.pgDetailToURLDetailData) {
            if (this.nsCommonData.pgDetailToURLDetailData['pageName'] != undefined) {
                this.filter += ', Page=' + this.nsCommonData.pgDetailToURLDetailData['pageName'];
            }
            if (this.nsCommonData.pgDetailToURLDetailData['transName'] != undefined) {
                this.filter += ', Transaction=' + this.nsCommonData.pgDetailToURLDetailData['transName'];
            }
        }
        if (this.filter.startsWith(',')) {
            this.filter = this.filter.substring(1);
        }
        if (this.filter.endsWith(',')) {
            this.filter = this.filter.substring(0, this.filter.length - 1);
        }
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = this.ddrData.getHostUrl();
        if (this.sessionService.preSession.multiDc === true) {
            this.commonParams.testRun = this.sessionService.session.testRun.id;
        }
        return hostDcName;
    }
    /*
  **FUnction used to custom sort for intger and float
  */
    sortColumnsOnCustom(event, columnData) {
        let fieldValue = event["field"];
        if (fieldValue == "avgResponseTime")
            fieldValue = ["avgResponseTimesort"];
        if (fieldValue == "pctResponseTime")
            fieldValue = ["pctResponseTimesort"];
        if (event.order == -1) {
            event.order = 1;
            columnData = columnData.sort(function (a, b) {
                var value, value2;
                if (fieldValue == 'component') {
                    value = (a[fieldValue].toLocaleLowerCase());
                    value2 = (b[fieldValue].toLocaleLowerCase());
                }
                else {
                    value = parseInt(a[fieldValue]);
                    value2 = parseInt(b[fieldValue]);
                }
                return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
            });
        }
        else {
            event.order = -1;
            //asecding order
            columnData = columnData.sort(function (a, b) {
                var value, value2;
                if (fieldValue == 'component') {
                    value = (a[fieldValue].toLocaleLowerCase());
                    value2 = (b[fieldValue].toLocaleLowerCase());
                }
                else {
                    value = parseInt(a[fieldValue]);
                    value2 = parseInt(b[fieldValue]);
                }
                return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
            });
        }
        this.columnData = [];
        //console.log(JSON.stringify(tempData));
        if (columnData) {
            columnData.map((rowdata) => { this.columnData = this.Immutablepush(this.columnData, rowdata); });
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    /* Download report for URL Component Details  */
    downloadReports(reports) {
        this.downloadData = JSON.parse(JSON.stringify(this.columnData));
        let renameArray = { "component": "Component", "avgResponseTime": "Avg Response Time", "pctResponseTime": "Percentage Response Time" };
        let colOrder = ['Component', 'Avg Response Time', 'Percentage Response Time'];
        this.downloadData.forEach((val, index) => {
            delete val['avgResponseTimesort'];
            delete val['pctResponseTimesort'];
        });
        let tableRowData = [];
        let headers = [];
        let isHeaderFlag = false;
        for (let i = 0; i < this.columnData.length; i++) {
            const rowData = this.columnData[i];
            const selectedRowData = [];
            if (headers.length > 0)
                isHeaderFlag = true;
            if (!isHeaderFlag)
                headers.push("#");
            selectedRowData.push("");
            for (let j = 0; j < this.visibleCols.length; j++) {
                if (!isHeaderFlag)
                    headers.push(this.getHeaders(this.visibleCols[j]));
                selectedRowData.push(rowData[this.visibleCols[j]]);
            }
            tableRowData.push(selectedRowData);
        }
        let downloadObj = {
            testRun: this.sessionService.session.testRun.id,
            cctx: this.sessionService.session.cctx,
            type: reports,
            skipColumn: "",
            rowData: tableRowData,
            header: headers,
            title: 'URL Details',
            arrParaList: null,
            subTitle: "",
            forReport: "nsDdrReport",
            lowerPanelTitle: "",
            noOfRowConsiderAsHeader: ""
        };
        this.ddrHttpService.downloadV2DdrReports(downloadObj).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["DownloadAngularReportLoadingState"]) {
                return;
            }
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["DownloadAngularReportLoadedState"]) {
                this.openDownloadReports(state.data);
                return;
            }
        }, (state) => {
            console.error('Error loading:', state.data);
        });
    }
    openDownloadReports(res) {
        // window.open(decodeURIComponent(this.getHostUrl(true)) + '/common/' + res);
        window.open(decodeURIComponent(this.ddrData.getHostWithoutLocation(this.getHostUrl(true)) + '/common/' + res));
    }
    getHeaders(fieldName) {
        switch (fieldName) {
            case 'component':
                return 'Component';
            case 'avgResponseTime':
                return 'Avg Response Time';
            case 'pctResponseTime':
                return 'Percentage Response Time';
        }
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.commonParams.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    msToTimeFormat(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    formatter(value) {
        if (!isNaN(value))
            return Number(value).toFixed(2);
        else
            return value;
    }
};
UrlComponentDetailsComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_5__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_7__["NsCommonService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_13__["DDRHttpService"] }
];
UrlComponentDetailsComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-url-component-details',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./url-component-details.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./url-component-details.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.scss")).default]
    })
], UrlComponentDetailsComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.scss":
/*!********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.scss ***!
  \********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-url-failure-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-url-failure-report .ddr-graphpanel .highcharts-contextbutton {\n  display: none;\n}\napp-url-failure-report .group-left {\n  float: left;\n  padding-top: 4px;\n}\napp-url-failure-report .group-right {\n  float: right;\n  padding-top: 4px;\n}\napp-url-failure-report .highcharts-legend {\n  pointer-events: none;\n}\napp-url-failure-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-url-failure-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.ts":
/*!******************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.ts ***!
  \******************************************************************************************************************/
/*! exports provided: UrlFailureReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UrlFailureReportComponent", function() { return UrlFailureReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");













let UrlFailureReportComponent = class UrlFailureReportComponent {
    constructor(_router, ddrData, commonService, breadcrumbService, nsCommonData, ddrRequest, sessionService, ddrHttpService) {
        this._router = _router;
        this.ddrData = ddrData;
        this.commonService = commonService;
        this.breadcrumbService = breadcrumbService;
        this.nsCommonData = nsCommonData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ddrHttpService = ddrHttpService;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_10__;
        this.toolTipStatus = "";
        this.urlidx = this.nsCommonData.urlidx;
        this.loading = false;
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.headerRelativePath = "/ddr/url-failure-report/url-failure-report.json";
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.commonService.isBackButton = true;
        this.loading = true;
        this.commonParams = this.commonService.getData();
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__["BREADCRUMB_ITEMS"].URL_FAIL);
        this.commonService.currentReport = "URL Failure";
        this.randomNumber();
        this.commonService.checkForNsKeyObj(this.ddrData.nsCQMFilter, this.commonService.currentReport);
        console.log("this.commonservice.nsURLSummary==>", this.commonService.nsURLFailure);
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.makeajaxcall();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b, _c;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.key) == 'failures')
            me.URLInstanceReport((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = this.ddrData.getHostUrl();
        if (this.sessionService.preSession.multiDc === true) {
            this.commonParams.testRun = this.sessionService.session.testRun.id;
            console.log("all case url==>", hostDcName, "all case test run==>", this.commonParams.testRun, '----  ', this.sessionService.session.testRun.id);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    makeajaxcall() {
        let startTime = this.commonParams.startTime;
        let endTime = this.commonParams.endTime;
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        let ajaxParam = '';
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.commonParams.testRun;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        ajaxParam += '&object=0&statusCode=-1' + '&startTime=' + startTime + '&endTime=' + endTime + '&reportType=failure' + '&strStatusName=NA' + '&objid=' + this.urlidx;
        if (this.ddrData.nsErrorName) {
            ajaxParam += '&nsErrorName=' + this.ddrData.nsErrorName;
        }
        if (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            ajaxParam += '&groupName=' + this.ddrData.vectorName;
        if (this.ddrData.generatorName || (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxParam += '&generatorName=' + this.ddrData.generatorName;
        if (this.commonService.isFromUrlSummary || this.commonService.isFromUrlSession) {
            if (this.commonService.nsURLFailure['objid']) {
                delete this.commonService.nsURLFailure['url'];
            }
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLFailure, true);
            this.ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsURLFailure;
        }
        else if (this.ddrData.nsCQMFilter[this.commonService.currentReport]) {
            this.commonService.isFromUrlSummary = true;
            this.commonService.isFromUrlSession = true;
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this.ddrData.nsCQMFilter[this.commonService.currentReport], true);
        }
        if (this.nsCommonData.urlsessionsummarydata != undefined)
            ajaxParam += '&pageName=' + this.nsCommonData.urlsessionsummarydata.pageName + '&scriptName=' + this.nsCommonData.urlsessionsummarydata.scriptName;
        ajaxParam += '&limit=22&offset=0&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
        this.ddrHttpService.getNSUrlReportData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["NSUrlReportLoadedState"]) {
                this.AssignData(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    AssignData(res) {
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.isCancelQuerydata = true;
        console.log("res in assign data", JSON.stringify(res));
        this.urlFailureData = res.data;
        this.loading = false;
        if (this.urlFailureData.length == 0) {
            this.empty = true;
        }
        this.filtercriteria(res.starttime, res.endtime);
        this.createTable();
        this.createStackBarChart(this.urlFailureData);
    }
    filtercriteria(startTime, endTime) {
        this.filter = "";
        this.failureFilter = "";
        this.toolTipStatus = "";
        if (this.sessionService.preSession.multiDc === true)
            this.filter += "DC=" + (this.ddrData.dcName || 'Master');
        if (this.ddrData.startTimeInDateFormat) {
            this.filter += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
            this.filter += ', From=' + startTime;
        }
        if (this.ddrData.endTimeInDateFormat) {
            this.filter += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
            this.filter += ', To=' + endTime;
        }
        if (this.nsCommonData.urlfaildata != undefined) {
            this.filter += ', URL=' + this.nsCommonData.urlfaildata.urlName;
        }
        if (this.nsCommonData.urlsessionsummarydata != undefined) {
            this.filter += ', Script Name=' + this.nsCommonData.urlsessionsummarydata.scriptName + ', Page Name=' + this.nsCommonData.urlsessionsummarydata.pageName + ', URL=' + this.nsCommonData.urlsessionsummarydata.urlName;
        }
        //if (this.nsCommonData.urlfaildata!=undefined)
        //{
        //  this.filter += ', URL Status= All Failures';
        //  }
        if (this.commonService.nsURLFailure && this.commonService.nsURLFailure['statusCodeFC']) {
            let status = this.commonService.nsURLFailure['statusCodeFC'];
            console.log('status of fail', status);
            if (status && status.length >= 20) {
                this.toolTipStatus = status;
                status = status.substring(0, 19);
                this.failureFilter += ", URL Status=" + status + " ....";
            }
            else
                this.failureFilter += ', URL Status=' + status;
        }
        else if (this.ddrData.nsErrorName) {
            this.failureFilter += ', URL Status=' + this.ddrData.nsErrorName;
        }
        else {
            this.failureFilter += ', URL Status= All Failures';
        }
        if (this.ddrData.generatorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1) {
            this.filter += ', Generator Name=' + this.ddrData.generatorName;
        }
        if (this.ddrData.vectorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1) {
            this.filter += ', Group Name=' + this.ddrData.vectorName;
        }
        if (this.filter.startsWith(',')) {
            this.filter = this.filter.substring(1);
        }
        if (this.filter.endsWith(',')) {
            this.filter = this.filter.substring(0, this.filter.length - 1);
        }
    }
    /**Used to create stacked Column chart based on FailureCount */
    createStackBarChart(stackData) {
        console.log("in bar", Number(stackData[0].failures));
        let failurearr = [];
        for (let i = 0; i < stackData.length; i++) {
            failurearr.push({ "name": stackData[i]["errorname"], "data": [Number(stackData[i].failures)] });
        }
        //console.log("bar dataaaaaaaaa",failurearr);
        this.options = {
            chart: {
                type: "column"
            },
            credits: {
                enabled: false
            },
            title: {
                text: "Failure Detail Report For URL",
                style: { 'fontSize': '20px' }
            },
            xAxis: {
                title: {
                    text: 'Number of Failures'
                },
            },
            yAxis: {
                min: 0,
                title: {
                    text: 'Number of Failures'
                },
                stackLabels: {
                    enabled: true,
                    style: {
                        fontWeight: 'bold',
                        color: 'gray'
                    }
                }
            },
            exporting: {
                buttons: {
                    contextButton: {
                        enabled: false
                    }
                }
            },
            legend: {
                align: 'center',
                floating: false,
                backgroundColor: 'white',
                borderColor: '#CCC',
                borderWidth: 1,
                shadow: true
            },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>, Count: <b> {point.y}</b>'
            },
            plotOptions: {
                column: {
                    stacking: 'normal',
                    pointWidth: 50,
                    dataLabels: {
                        enabled: true,
                        color: 'white'
                    },
                    showInLegend: true
                }
            },
            series: failurearr
        };
    }
    URLInstanceReport(row) {
        console.log("function data ---------", row);
        this.commonService.nsURLInstance = {}; // for in case if user apply filter in instance then go back in summary then goes to instance.
        // then the object will still be remaining there therefore will oopen up same data of instance again. for bug :68564
        console.log("inside url instance ==>", this.commonService.nsURLSummary, " instacne ", this.commonService.nsURLInstance, " nsCQM ** ", this.ddrData.nsCQMFilter["URL Instance"]);
        this.ddrData.nsCQMFilter["URL Instance"] = undefined;
        this.ddrData.summaryToInstanceFlag = 'true';
        this.nsCommonData.urlidx = this.nsCommonData.urlidx;
        this.nsCommonData.FailureStatus = row.failuretype;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__["BREADCRUMB_ITEMS"].URL_FAIL;
        this.nsCommonData.urlInstancethroughsuccess = false;
        if (this.commonService.isFromUrlSummary || this.commonService.isFromUrlSession) {
            console.log("inside of cqm cond==>", this.commonService.nsURLFailure);
            this.commonService.nsURLInstance = JSON.parse(JSON.stringify(this.commonService.nsURLFailure));
            this.commonService.nsURLInstance['reportType'] = 'instance';
            delete this.commonService.nsURLInstance['fields'];
            if (this.commonService.isFromUrlSession || this.commonService.isFromUrlSummary) {
                this.commonService.nsURLInstance['urlidx'] = this.commonService.nsURLInstance['objid'];
                delete this.commonService.nsURLInstance['objid'];
                console.log("chnaged objid to url id");
            }
            console.log("this.commonService.nsURLInstance['urlidx']=>", this.commonService.nsURLInstance['urlidx']);
            this.commonService.nsURLInstance['statusCode'] = row.failuretype;
            if (this.commonService.nsURLInstance['urlidx'] && (this.nsCommonData.urlidx == 'undefined' || this.nsCommonData.urlidx)) {
                this.commonService.nsURLInstance['urlidx'] = this.nsCommonData.urlidx;
                console.log("sessting default==>", this.commonService.nsURLInstance['urlidx']);
            }
            // if (this.nsCommonData.urlInstancethroughsuccess)
            // this.commonService.nsURLInstance['statusCode']=0;
            console.log("this.commonService.nsURLInstance==> going ourt of summary=====>", this.commonService.nsURLInstance);
            // if (this.nsCommonData.urlsessionsummarydata != undefined) {
            //   ajaxParam += '&pageName=' + this.nsCommonData.urlsessionsummarydata.pageName + '&scriptName=' + this.nsCommonData.urlsessionsummarydata.scriptName;
            // }
            this.commonService.isFromUrlFailure = true;
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'URL Instance');
        this.ddrData.nsFromGraph = false;
        this._router.navigate(['/ddr/nsreports/urlInstance']);
    }
    createTable() {
        this.cols = [
            { field: 'errorname', header: 'Failure Type', sortable: true, action: true },
            { field: 'failures', header: 'Number Of Failures', sortable: true, color: 'blue', action: true }
        ];
        this.visibleCols = ['errorname', 'failures'];
    }
    getSelected(event) {
    }
    ngOnDestroy() {
        this.commonService.isFromUrlSummary = false;
        this.commonService.isFromUrlSession = false;
        this.commonService.isBackButton = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.commonParams.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        console.log("Hello u got that", url);
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
UrlFailureReportComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_5__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__["DdrBreadcrumbService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__["NsCommonService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["DDRHttpService"] }
];
UrlFailureReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-url-failure-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./url-failure-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./url-failure-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.scss")).default]
    })
], UrlFailureReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.scss":
/*!**********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.scss ***!
  \**********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-url-instance-report .colgroup-col col {\n  min-width: 120px !important;\n}\napp-url-instance-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-url-instance-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-url-instance-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-url-instance-report .no-transactions img {\n  max-width: 70%;\n}\napp-url-instance-report .column-container {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  height: 100%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.ts":
/*!********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.ts ***!
  \********************************************************************************************************************/
/*! exports provided: UrlInstanceReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UrlInstanceReportComponent", function() { return UrlInstanceReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _angular_cdk_clipboard__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! @angular/cdk/clipboard */ "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/clipboard.js");
/* harmony import */ var src_app_pages_home_load_test_services_load_test_utils_service__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! src/app/pages/home/load-test/services/load-test-utils.service */ "./src/app/pages/home/load-test/services/load-test-utils.service.ts");



















let UrlInstanceReportComponent = class UrlInstanceReportComponent {
    constructor(_router, breadcrumbService, commonService, ddrData, nsCommonData, ddrRequest, sessionService, route, breadcrumb, txService, scriptUtilService, dialogService, ddrHttpService, clipboardService, loadTestUtilsService) {
        this._router = _router;
        this.breadcrumbService = breadcrumbService;
        this.commonService = commonService;
        this.ddrData = ddrData;
        this.nsCommonData = nsCommonData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.route = route;
        this.breadcrumb = breadcrumb;
        this.txService = txService;
        this.scriptUtilService = scriptUtilService;
        this.dialogService = dialogService;
        this.ddrHttpService = ddrHttpService;
        this.clipboardService = clipboardService;
        this.loadTestUtilsService = loadTestUtilsService;
        this.url = ""; //url for ajaxcall
        this.strStatusName = "NA"; //for vector name
        this.statusCode = -2;
        this.object = 0;
        this.cols = [];
        this.visibleCols = [];
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.limit = 50;
        this.offset = 0;
        this.loading = false;
        this.isEnabledColumnFilter = true;
        this.toggleFilterTitle = '';
        this.ajaxUrl = "";
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.onFilter = false;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.isDdrEnabled = true;
        this.viewCorrelationId = false;
        this.scriptName = "";
        this.userId = "";
        this.sessionId = "";
        this.pageName = "";
        this.urlName = "";
        this.correlationId = "";
        this.dynaTraceVal = "";
        this.isLoading = false;
        this.isActionColumn = false;
        this.errorData = "";
        this.relativePath = 'ddr/url-instance-report/url-instance-report3.json';
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = true;
        this.first.first = 0;
        this.rows.rows = 50;
        this.screenHeight = Number(this.commonService.screenHeight) - 94;
        this.commonService.currentReport = 'URL Instance';
        this.randomNumber();
        if (this.ddrData.summaryToInstanceFlag === 'true')
            this.nsCommonData.isFromSummary = true;
        else if (this.ddrData.summaryToInstanceFlag === 'false')
            this.nsCommonData.isFromSummary = false;
        this.loading = true;
        this.commonParams = this.commonService.getData();
        this.vectorMetaData = this.ddrData.vectorMetaData;
        this.vectorData = this.ddrData.vectorName;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_INSTANCE);
        this.setTestRunInHeader();
        this.subscribeURL = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == 'URL Instance') {
                this.loading = true;
                this.limit = 50;
                this.offset = 0;
                let length = this.paginateRef['pageLinkSize'];
                let arry = [];
                for (let i = 1; i <= length; i++)
                    arry.push(i);
                this.paginateRef['pageLinks'] = [];
                this.paginateRef['pageLinks'] = arry;
                this.paginateRef['_rows'] = 50;
                this.paginateRef['_first'] = 0;
                this.makeajaxcall();
                this.makeajaxcallCount();
            }
        });
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.makeajaxcall();
                this.makeajaxcallCount();
            }
        });
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Script Name')
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'User Id')
            me.userSession((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row);
        if (((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label) == 'Response Time')
            me.urltimedetails((_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.row);
        if (((_l = (_k = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _k === void 0 ? void 0 : _k.actionConfig) === null || _l === void 0 ? void 0 : _l.action) == 'click')
            me.viewCorrelation((_m = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _m === void 0 ? void 0 : _m.row);
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = this.ddrData.getHostUrl();
        if (this.sessionService.preSession.multiDc === true) {
            this.commonParams.testRun = this.sessionService.session.testRun.id;
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    setTestRunInHeader() {
        if (this.commonParams && this.commonParams.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'URL Instance Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else if (this.commonParams && this.commonParams.product.toLowerCase() == 'netcloud')
            this.strTitle = 'URL Instance Report - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - URL Instance Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    makeajaxcall() {
        let ajaxParam = "";
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.commonParams.testRun;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        /*ajax call when from WD*/
        if (this.commonService.isFilterFromNSSideBar && Object.keys(this.commonService.nsURLInstance).length != 0) {
            if (this.nsCommonData && this.nsCommonData.urlidx != undefined && !(this.commonService.nsURLInstance["url"] && this.commonService.nsURLInstance["urlidx"])) {
                this.commonService.nsURLInstance["urlidx"] = this.nsCommonData.urlidx;
            }
            this.commonService.nsURLInstance;
            if (!this.commonService.nsURLInstance['statusCodeFC']) {
                if (this.ddrData.fromReport) {
                    this.commonService.nsURLInstance['nsErrorName'] = this.ddrData.errorNameUrl;
                }
                else if (this.ddrData.nsErrorName) {
                    this.commonService.nsURLInstance['nsErrorName'] = this.ddrData.nsErrorName;
                }
            }
            else {
                delete this.commonService.nsURLInstance['nsErrorName'];
            }
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLInstance, true);
            this.commonService.isCQM = true;
            // for FIlter CQM case    so that will update value in key pair.
            this.ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsURLInstance;
        }
        else {
            // if (this.nsCommonData.urlidx != undefined /*&& this.ddrData.summaryToInstanceFlag == 'true' */) {
            if (this.nsCommonData.urlidx != undefined && this.ddrData.nsFromGraph == false) {
                this.urlidx = this.nsCommonData.urlidx;
            }
            if (!this.nsCommonData.FailureStatus || this.ddrData.summaryToInstanceFlag == 'false') {
                if (this.vectorMetaData != undefined) {
                    if (this.vectorMetaData == "Error" && this.vectorData != "NA") {
                        this.strStatusName = this.vectorData;
                        //vectorName = "NA";     //becuse of errors graphs in webdashboard
                    }
                }
            }
            if (this.nsCommonData.FailureStatus != undefined && this.ddrData.summaryToInstanceFlag == 'true')
                this.statusCode = this.nsCommonData.FailureStatus;
            else if (this.nsCommonData.urlInstancethroughsuccess)
                this.statusCode = 0;
            else {
                if (this.nsCommonData.urlsessionsummarydata && (this.nsCommonData.urlsessionsummarydata['status'] != '-' && this.nsCommonData.urlsessionsummarydata['status'] != null && this.nsCommonData.urlsessionsummarydata['status'] != undefined))
                    this.statusCode = this.nsCommonData.urlsessionsummarydata['status'];
                else if (this.ddrData.filtermode == 'failure')
                    this.statusCode = -1;
                else if (this.ddrData.filtermode == 'success')
                    this.statusCode = 0;
                else
                    this.statusCode = -2;
            }
            let startTime = this.commonParams.startTime;
            let endTime = this.commonParams.endTime;
            ajaxParam += '&object=0' + '&startTime=' + startTime + '&endTime=' + endTime + "&statusCode=" + this.statusCode + "&strStatusName=" + this.strStatusName + '&reportType=instance' + "&urlidx=" + this.urlidx;
            // if (this.nsCommonData.urlsessionsummarydata != undefined) {
            //   ajaxParam += '&pageName=' + this.nsCommonData.urlsessionsummarydata.pageName + '&scriptName=' + this.nsCommonData.urlsessionsummarydata.scriptName;
            // }
            if (this.ddrData.fromReport) {
                ajaxParam += '&nsErrorName=' + this.ddrData.errorNameUrl;
            }
            else if (this.ddrData.nsErrorName) {
                ajaxParam += '&nsErrorName=' + this.ddrData.nsErrorName;
            }
            if (this.loadTestUtilsService.isFromCorrelationUI) {
                ajaxParam += '&urlInstance=' + this.loadTestUtilsService.correlationData['urlInstance'] + '&pageInstance=' + this.loadTestUtilsService.correlationData['pageInstance'] + '&sessionid=' + this.loadTestUtilsService.correlationData['sessionId'] + '&childidx=' + this.loadTestUtilsService.correlationData['childindex'] + '&userindex=' + this.loadTestUtilsService.correlationData['useridx'];
            }
            // if(this.ddrData.groupName=="HTTP Requests"  && this.ddrData.vectorName!='undefined'&& this.ddrData.vectorName!=undefined )
            // ajaxParam += '&url=' + this.ddrData.vectorName;
            if (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this.ddrData.vectorName;
            if (this.ddrData.generatorName || (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this.ddrData.generatorName;
            if (this.commonService.isFromUrlSummary || this.commonService.isCQM || this.commonService.isFromUrlFailure || this.commonService.isFromUrlSession) {
                // this.commonService.nsTransactionInstance=this.ddrData.nsCQMFilter[this.commonService.currentReport];
                ajaxParam = this.commonService.checkAndReturnUniqueParams(ajaxParam, this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLInstance, true));
                this.ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsURLInstance;
            }
            else if (this.ddrData.nsCQMFilter[this.commonService.currentReport]) {
                ajaxParam = this.commonService.makeParamStringFromObjForNS(this.ddrData.nsCQMFilter[this.commonService.currentReport], true);
            }
            this.commonService.nsURLInstance = this.commonService.makeObjectFromUrlParam(ajaxParam);
        }
        if (this.nsCommonData.urlsessionsummarydata != undefined && this.ddrData.nsFromGraph == false) {
            ajaxParam += '&pageName=' + this.nsCommonData.urlsessionsummarydata.pageName + '&scriptName=' + this.nsCommonData.urlsessionsummarydata.scriptName;
        }
        this.ajaxUrl = ajaxParam;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
        let finalUrl = this.ajaxUrl + '&limit=' + this.limit + '&offset=' + this.offset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        // this.ddrRequest.getDataUsingGet(finalUrl).subscribe(data => { (this.assignData(data)) });
        this.ddrHttpService.getNSUrlReportData(prefix, finalUrl).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__["NSUrlReportLoadedState"]) {
                this.assignData(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignData(json) {
        if (json.errorData) {
            this.loading = false;
            this.errorData = json.errorData;
            return;
        }
        this.createTable();
        this.isCancelQuerydata = true;
        this.commonService.isFilterFromNSSideBar = false;
        this.urlInstanceData = json.data;
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
        setTimeout(() => {
            this.loader = false;
        }, 2000);
        this.loading = false;
        if (this.urlInstanceData.length == 0) {
            this.empty = true;
            this.showDownloadOption = false;
        }
        this.filtercriteria(json.starttime, json.endtime);
        this.commonService.customTimePlaceHolder = [];
        this.commonService.customTimePlaceHolder.push(json.starttime, json.endtime);
        if (this.urlInstanceData.length !== 0) {
            let count = 0;
            this.urlInstanceData.forEach((val, index) => {
                count++;
                if (val.hasOwnProperty('GeneratorName')) {
                    if (val['GeneratorName'] === '') {
                        val['GeneratorName'] = 'NA';
                    }
                }
                else {
                    val['GeneratorName'] = 'NA';
                }
                if (count == 1 && val.hasOwnProperty('urlInstance')) {
                    this.isActionColumn = true;
                }
            });
        }
        this.changeColumnFilter();
        this.urlInstanceDataOrgi = this.urlInstanceData;
    }
    filtercriteria(startTime, endTime) {
        this.filter = "";
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        let urlInstanceHeader = this.commonService.nsURLInstance;
        if (this.sessionService.preSession.multiDc === true) {
            this.filter += "DC=" + (this.ddrData.dcName || 'Master');
        }
        if (!this.commonService.isValidParamInObj(urlInstanceHeader, 'phaseName')) {
            if (this.ddrData.startTimeInDateFormat) {
                this.filter += ', From=' + this.ddrData.startTimeInDateFormat;
            }
            else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
                this.filter += ', From=' + startTime;
            }
            if (this.ddrData.endTimeInDateFormat) {
                this.filter += ', To=' + this.ddrData.endTimeInDateFormat;
            }
            else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
                this.filter += ', To=' + endTime;
            }
            if (this.ddrData.correlationId)
                this.filter += ", Correlation ID=" + this.ddrData.correlationId;
        }
        if (this.ddrData.generatorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filter += ', Generator Name=' + this.ddrData.generatorName;
        if (this.ddrData.vectorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filter += ', Group Name=' + this.ddrData.vectorName;
        if (this.commonService.isValidParamInObj(urlInstanceHeader, "url")) {
            let url = urlInstanceHeader['url'];
            if (url && url.length >= 20) {
                this.toolTipUrl += urlInstanceHeader['url'];
                url = url.substring(0, 19);
                this.filterUrl += ", Url=" + url + " ....";
            }
            else
                this.filter += ", Url=" + url;
            // this.filter += ', URL=' + urlInstanceHeader['url'];
        }
        if (this.commonService.isValidParamInObj(urlInstanceHeader, "pageName")) {
            this.filter += ', Page=' + urlInstanceHeader['pageName'];
        }
        if (this.commonService.isValidParamInObj(urlInstanceHeader, "scriptName")) {
            this.filter += ', Script=' + urlInstanceHeader['scriptName'];
        }
        if (this.commonService.isValidParamInObj(urlInstanceHeader, "transactionName")) {
            this.filter += ', Transaction=' + urlInstanceHeader['transactionName'];
        }
        if (this.commonService.isValidParamInObj(urlInstanceHeader, "location") && this.ddrData.WAN_ENV > 0) {
            this.filter += ', Location=' + urlInstanceHeader['location'];
        }
        if (this.commonService.isValidParamInObj(urlInstanceHeader, "browser")) {
            this.filter += ', Browser=' + urlInstanceHeader['browser'];
        }
        if (this.commonService.isValidParamInObj(urlInstanceHeader, "access") && this.ddrData.WAN_ENV > 0) {
            this.filter += ', Access=' + urlInstanceHeader['access'];
        }
        if (this.commonService.isValidParamInObj(urlInstanceHeader, "statusCodeFC")) {
            let status = urlInstanceHeader['statusCodeFC'];
            if (status && status.length >= 20) {
                this.toolTipStatus += urlInstanceHeader['statusCodeFC'];
                status = status.substring(0, 19);
                this.filterStatus += ", Status=" + status + " ....";
            }
            else
                this.filter += ", Status=" + status;
            // this.filter += ', Status =' + urlInstanceHeader['statusCodeFC'];
        }
        // if (this.nsCommonData.urlInstanceData != undefined) {
        //   this.filter += ', URL=' + this.nsCommonData.urlInstanceData.urlName;
        // }
        // if (this.nsCommonData.urlInstanceData != undefined) {
        //   if (this.nsCommonData.urlInstanceData.errorname != undefined)
        //     this.filter += ', URL Status=' + this.nsCommonData.urlInstanceData.errorname;
        // }
        // if (this.nsCommonData.urlsessionsummarydata != undefined) {
        //   this.filter += ', Script Name=' + this.nsCommonData.urlsessionsummarydata.scriptName + ', Page Name=' + this.nsCommonData.urlsessionsummarydata.pageName + ', URL=' + this.nsCommonData.urlsessionsummarydata.urlName + ', URL Status=' + this.nsCommonData.urlsessionsummarydata.errorname;
        // }
        if (this.commonService.isValidParamInObj(urlInstanceHeader, 'order'))
            this.filter += ", order=" + urlInstanceHeader.order;
        if (this.commonService.isValidParamInObj(urlInstanceHeader, 'phaseName'))
            this.filter += ", Phase Name=" + urlInstanceHeader.phaseName;
        if (this.filter.startsWith(',')) {
            this.filter = this.filter.substring(1);
        }
        if (this.filter.endsWith(',')) {
            this.filter = this.filter.substring(0, this.filter.length - 1);
        }
    }
    makeajaxcallCount() {
        let isCount = true;
        let countUrl = this.ajaxUrl + '&showCount=true' + '&productKey=' + this.sessionService.session.cctx.pk;
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        this.ddrHttpService.getNSUrlReportData(prefix, countUrl, isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__["NSUrlReportLoadedState"]) {
                this.assignCountData(state.data);
                isCount = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignCountData(countdata) {
        this.count = countdata.totalCount;
        if (this.limit > this.count)
            this.limit = Number(this.count);
    }
    paginate(event) {
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        if (this.limit > this.count)
            this.limit = Number(this.count);
        this.loader = true;
        this.makeajaxcall();
    }
    createTable() {
        if (this.ddrData.WAN_ENV > 0 && !this.sessionService.session.testRun.cmt)
            this.relativePath = 'ddr/url-instance-report/page-instance-report.json';
        else if (this.ddrData.WAN_ENV > 0 && this.sessionService.session.testRun.cmt)
            this.relativePath = 'ddr/url-instance-report/url-instance-report1.json';
        else if (!(this.ddrData.WAN_ENV > 0) && !this.sessionService.session.testRun.cmt)
            this.relativePath = 'ddr/url-instance-report/url-instance-report2.json';
        else
            this.relativePath = 'ddr/url-instance-report/url-instance-report3.json';
    }
    urltimedetails(rowData) {
        //--testrun 1979 --object 0 --childidx 7 --sessioninst 162 --starttime 1489669 --urlidx 7 --pageinst 0
        this.commonService.urlInstanceObj = {
            scriptName: rowData['scriptName'],
            pageName: rowData['pageName'],
            urlName: rowData['urlName'],
            useridx: rowData['userId'],
            childindex: rowData['childIndex'],
            sessionId: rowData['sessionId'],
            pageInstance: rowData['pageInstance'],
            urlInstance: rowData['urlInstance'],
            isUrlInstance: rowData['urlInstance'] ? true : false
        };
        this.nsCommonData.currRowData = rowData;
        this.nsCommonData._sendAbsoluteTime = this.newMsToTimeFormat(rowData.absoluteStartTime);
        this.nsCommonData.objectType = '0';
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_INSTANCE;
        //this.breadcrumb.add({label: 'URL Timing Details', routerLink: '/ddr/nsreports/sessionTiming'});
        this._router.navigate(['/ddr/nsreports/sessionTiming']);
    }
    userSession(data) {
        this.commonService.urlInstanceObj = {
            scriptName: data['scriptName'],
            pageName: data['pageName'],
            urlName: data['urlName'],
            useridx: data['userId'],
            childindex: data['childIndex'],
            sessionId: data['sessionId'],
            pageInstance: data['pageInstance'],
            urlInstance: data['urlInstance'],
            isUrlInstance: data['urlInstance'] ? true : false
        };
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_INSTANCE;
        this.nsCommonData.currRowData = data;
        this.nsCommonData.objectType = '0';
        this.breadcrumb.add({ label: 'User Session', routerLink: '/ddr/nsreports/userSession' });
        this._router.navigate(['/ddr/nsreports/userSession']);
    }
    openSessionName(rowData) {
        // let url = this.getHostUrl() + '/' + this.commonParams.product +
        //   '/recorder/recorder.jsp?openFrom=TR' + this.sessionService.session.testRun.id +
        //   '&scriptName=' + rowData.scriptName + "&sesLoginName=" + sessionStorage.getItem('sesLoginName');;
        // window.open(url, "_blank");
        // let projectSubProjName = rowData['scriptName'].split("/")[0] + "/" + rowData['scriptName'].split("/")[1];
        // this.scriptUtilService.sendEditScriptObj(projectSubProjName,rowData['scriptName'].split("/")[2],'Edit',false);
        // this._router.navigate(['/script'], { relativeTo: this.route });
        // throw new Error('Method not implemented.');
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_14__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    /*This method is used to Enable/Disabled Column Filter*/
    changeColumnFilter() {
        try {
            let tableColumns = this.cols;
            if (this.isEnabledColumnFilter) {
                this.toggleFilterTitle = 'Show Filters';
                for (let i = 0; i < tableColumns.length; i++) {
                    tableColumns[i].filter = false;
                }
            }
            else {
                this.toggleFilterTitle = 'Hide Filters';
                for (let i = 0; i < tableColumns.length; i++) {
                    tableColumns[i].filter = true;
                }
            }
        }
        catch (error) {
            console.log('Error while Enable/Disabled column filters', error);
        }
    }
    msToTimeFormat(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    newMsToTimeFormat(duration) {
        if (!isNaN(duration)) {
            let duration1 = Number(duration);
            let timeInDateFormat;
            timeInDateFormat = this.sessionService.convertTimestampIntoFormattedString(duration1); //convertTimestampIntoFormattedString()
            return timeInDateFormat;
        }
        else {
            return duration;
        }
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.subscribeURL.unsubscribe();
        this.commonService.isFromUrlSummary = false;
        this.commonService.isCQM = false;
        this.commonService.isFromUrlFailure = false;
        this.commonService.isFromUrlSession = false;
        this.loadTestUtilsService.isFromCorrelationUI = false;
        this.loadTestUtilsService.correlationData = {};
        this.isActionColumn = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.commonParams.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.urlInstanceData = this.urlInstanceData.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.urlInstanceData = this.urlInstanceData.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.urlInstanceData = this.urlInstanceData.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.urlInstanceData = this.urlInstanceData.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.urlInstanceData = this.urlInstanceData.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.urlInstanceData = this.urlInstanceDataOrgi;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.urlInstanceData = this.urlInstanceDataOrgi;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
    viewCorrelation(rowData) {
        this.viewCorrelationId = true;
        this.getCorrelationData(rowData);
    }
    getCorrelationData(rowData) {
        this.isLoading = true;
        let arr;
        let correlationParam = "";
        this.scriptName = rowData['scriptName'];
        this.pageName = rowData['pageName'];
        this.urlName = rowData['urlName'];
        this.userId = rowData['userId'];
        this.sessionId = rowData['sessionId'];
        correlationParam += 'testRun=' + this.sessionService.session.testRun.id + '&scriptName=' + rowData['scriptName'] + '&pageName=' + rowData['pageName'] + '&urlName=' + encodeURIComponent(rowData['urlName']) + '&useridx=' + rowData['userId'] + '&childindex=' + rowData['childIndex'] + '&sessionId=' + rowData['sessionId'] + '&pageInstance=' + rowData['pageInstance'] + '&urlInstance=' + rowData['urlInstance']
            + '&localURLIndex=' + rowData['localURLIndex'] + '&localTxIndex=' + rowData['localTxIndex'];
        this.ddrHttpService.getCorrelationData(correlationParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__["GetCorrelationLoadingState"]) {
                this.isLoading = true;
                return;
            }
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_15__["GetCorrelationLoadedState"]) {
                this.setCorrelationValues(state.data);
                this.isLoading = false;
                return;
            }
        }, (state) => {
            console.log(state.error);
            this.isLoading = false;
        });
    }
    setCorrelationValues(data) {
        const lines = data.trim().split('\n');
        const keyValuePairs = {};
        lines.forEach((line) => {
            const [key, value] = line.split(': ');
            keyValuePairs[key] = value;
        });
        this.correlationId = keyValuePairs['X-Correlation-ID'];
        this.dynaTraceVal = keyValuePairs['x-dynaTrace'];
    }
    copyCorrelationId(correlationVal) {
        // this.messageService.add({ severity: 'success', summary: 'Copied to clipboard', detail: '' });
        this.clipboardService.copy(correlationVal);
        this.scriptUtilService.successMessage("Correlation Id copied to clipboard");
    }
    copyDynaTrace(dynatraceVal) {
        this.clipboardService.copy(dynatraceVal);
        this.scriptUtilService.successMessage("DynaTrace copied to clipboard");
    }
    copyScriptName(scriptName) {
        this.clipboardService.copy(scriptName);
        this.scriptUtilService.successMessage("Script Name copied to clipboard");
    }
    copyPageName(pageName) {
        this.clipboardService.copy(pageName);
        this.scriptUtilService.successMessage("Page Name copied to clipboard");
    }
    copyURLName(urlName) {
        this.clipboardService.copy(urlName);
        this.scriptUtilService.successMessage("URL Name copied to clipboard");
    }
};
UrlInstanceReportComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_5__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__["NsCommonService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["ActivatedRoute"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__["ScriptUtilService"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_13__["DialogService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_16__["DDRHttpService"] },
    { type: _angular_cdk_clipboard__WEBPACK_IMPORTED_MODULE_17__["Clipboard"] },
    { type: src_app_pages_home_load_test_services_load_test_utils_service__WEBPACK_IMPORTED_MODULE_18__["LoadTestUtilsService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])("paginateRef")
], UrlInstanceReportComponent.prototype, "paginateRef", void 0);
UrlInstanceReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-url-instance-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./url-instance-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./url-instance-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.scss")).default]
    })
], UrlInstanceReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.scss":
/*!**********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.scss ***!
  \**********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-url-session-summary .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-url-session-summary .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-url-session-summary .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-url-session-summary .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.ts":
/*!********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.ts ***!
  \********************************************************************************************************************/
/*! exports provided: UrlSessionSummaryComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UrlSessionSummaryComponent", function() { return UrlSessionSummaryComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var src_app_pages_home_script_manager_sm_tree_sm_tree_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! src/app/pages/home/script-manager/sm-tree/sm-tree.service */ "./src/app/pages/home/script-manager/sm-tree/sm-tree.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");

















let UrlSessionSummaryComponent = class UrlSessionSummaryComponent {
    constructor(_router, breadcrumbService, commonService, ddrData, nsCommonData, ddrRequest, sessionService, txService, ddrHttpService, smtreeService, scriptUtilService, dialogService) {
        this._router = _router;
        this.breadcrumbService = breadcrumbService;
        this.commonService = commonService;
        this.ddrData = ddrData;
        this.nsCommonData = nsCommonData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.txService = txService;
        this.ddrHttpService = ddrHttpService;
        this.smtreeService = smtreeService;
        this.scriptUtilService = scriptUtilService;
        this.dialogService = dialogService;
        this.strGroupBy = ""; //passed in url in case of url summary by status
        this.object = 0; //object 0 passed in case of url report
        this.fields = 4095;
        this.statusCode = -2;
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.limit = 50;
        this.offset = 0;
        this.filter = "";
        this.loading = false;
        this.showAllOption = false;
        this.isEnabledColumnFilter = true;
        this.toggleFilterTitle = '';
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.onFilter = false;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.relativePath = "ddr/url-session-summary/url-session-summary1.json";
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.isBackButton = true;
        this.first.first = 0;
        this.rows.rows = 50;
        this.commonParams = this.commonService.getData();
        this.commonService.currentReport = 'URL Session Summary';
        this.randomNumber();
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SESSION_SUMMARY);
        this.commonService.checkForNsKeyObj(this.ddrData.nsCQMFilter, this.commonService.currentReport);
        this.commonService.isToLoadSideBar = false;
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.makeajaxcall();
                this.makeajaxcallCount();
            }
        });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = this.ddrData.getHostUrl();
        if (this.sessionService.preSession.multiDc === true) {
            this.commonParams.testRun = this.sessionService.session.testRun.id;
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    makeajaxcall() {
        if (this.nsCommonData.urlreportid) {
            this.group = "page,session,status";
            if (this.nsCommonData.urlSummaryData && this.nsCommonData.urlSummaryData['status'])
                this.statusCode = Number(this.nsCommonData.urlSummaryData['status']);
        }
        else {
            this.group = "page,session";
            this.statusCode = -2;
        }
        let startTime = this.commonParams.startTime;
        let endTime = this.commonParams.endTime;
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        let ajaxParam = '';
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.commonParams.testRun;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        ajaxParam += '&object=0&fields=4095' + '&statusCode=' + this.statusCode + '&startTime=' + startTime + '&endTime=' + endTime + '&strGroupBy=' + this.strGroupBy + '&reportType=summary' + '&strStatusName=NA' + '&group=' + this.group + '&urlidx=' + this.nsCommonData.urlidx;
        if (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            ajaxParam += '&groupName=' + this.ddrData.vectorName;
        if (this.ddrData.generatorName || (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
            ajaxParam += '&generatorName=' + this.ddrData.generatorName;
        if (this.commonService.isFromUrlSummary) {
            //this.commonService.nsTransactionSummary=this.ddrData.nsCQMFilter[this.commonService.currentReport];
            if (this.nsCommonData.urlreportid)
                this.commonService.nsURLSession['group'] = "page,session,status";
            else
                this.commonService.nsURLSession['group'] = "page,session";
            ajaxParam = this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLSession, true);
            this.ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsURLSession;
        }
        else if (this.ddrData.nsCQMFilter[this.commonService.currentReport]) {
            this.commonService.isFromUrlSummary = true;
            ajaxParam += this.commonService.makeParamStringFromObjForNS(this.ddrData.nsCQMFilter[this.commonService.currentReport], true);
        }
        this.url = ajaxParam;
        //object = 0 is for URL Report
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
        ajaxParam += '&limit=' + this.limit + '&offset=' + this.offset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        this.ddrHttpService.getNSUrlReportData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_13__["NSUrlReportLoadedState"]) {
                this.AssignData(state.data);
            }
        }, (error) => {
            console.error('Error loading :', error);
        });
    }
    AssignData(res) {
        this.isCancelQuerydata = true;
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.urlSessionSummaryData = res.data;
        this.loading = false;
        if (this.urlSessionSummaryData.length == 0) {
            this.empty = true;
        }
        this.filtercriteria(res.starttime, res.endtime);
        this.createTable();
        this.urlSessionSummaryDataOrgi = this.urlSessionSummaryData;
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
    }
    filtercriteria(startTime, endTime) {
        this.filter = "";
        if (this.sessionService.preSession.multiDc === true) {
            this.filter += "DC=" + (this.ddrData.dcName || 'Master');
        }
        if (this.ddrData.startTimeInDateFormat) {
            this.filter += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
            this.filter += ', From=' + startTime;
        }
        if (this.ddrData.endTimeInDateFormat) {
            this.filter += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
            this.filter += ', To=' + endTime;
        }
        if (this.nsCommonData.urlSummaryData != undefined) {
            this.filter += ', URL=' + this.nsCommonData.urlSummaryData.urlName;
        }
        if (this.ddrData.generatorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1) {
            this.filter += ', Generator Name=' + this.ddrData.generatorName;
        }
        if (this.ddrData.vectorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1) {
            this.filter += ', Group Name=' + this.ddrData.vectorName;
        }
        if (this.filter.startsWith(',')) {
            this.filter = this.filter.substring(1);
        }
        if (this.filter.endsWith(',')) {
            this.filter = this.filter.substring(0, this.filter.length - 1);
        }
    }
    makeajaxcallCount() {
        let isCount = true;
        let countUrl = this.url + '&limit=' + this.limit + '&offset=' + this.offset + '&showCount=true' + '&productKey=' + this.sessionService.session.cctx.pk;
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        this.ddrHttpService.getNSUrlReportData(prefix, countUrl, isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_13__["NSUrlReportLoadedState"]) {
                this.AssignCountData(state.data);
                isCount = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    AssignCountData(countdata) {
        this.count = countdata.totalCount;
        if (this.limit > this.count)
            this.limit = Number(this.count);
    }
    createTable() {
        if (this.nsCommonData.urlreportid) {
            this.relativePath = "ddr/url-session-summary/url-session-summary.json";
        }
        else {
            this.relativePath = "ddr/url-session-summary/url-session-summary1.json";
        }
        // this.cols = [
        //   { field: 'urlName', header: 'URL Name', sortable: true, align: 'left', action: true ,width: '155', title: 'URL Name'},
        //  // { field: 'sessionCount', header: 'Script Count', align: 'right', color: 'blue', sortable: 'custom  ', action: true },
        //   { field: 'pageName', header: 'Page Name', sortable: 'custom', align: 'left', action: true , width: '75', title: 'Page Name'},
        //   { field: 'scriptName', header: 'Script Name', sortable: 'custom', align: 'left', action: true , width: '140' , title: 'Script Name' },
        //   { field: 'tried', header: 'Tried', sortable: 'custom', align: 'right', action: true , width: '50' , title: 'Tried'},
        //   { field: 'success', header: 'Success', sortable: 'custom', align: 'right', action: true , width: '50' , title: 'Success' },
        //   { field: 'fail', header: 'Fail', sortable: true, align: 'right', action: true , width: '55' , title: 'Fail' },
        //   { field: 'failPercent', header: '%Fail', sortable: 'custom', align: 'right', action: true , width: '50' , title: 'Fail(%)'},
        //   { field: 'avgmin', header: 'Min', sortable: 'custom', align: 'right', action: true , width: '85' , title: 'Minimum transaction time'},
        //   { field: 'avgaverage', header: 'Average', sortable: 'custom', align: 'right', action: true , width: '85' , title: 'Average transaction time' },
        //   { field: 'avgmax', header: 'Max', sortable: 'custom', align: 'right', action: true , width: '85' , title: 'Maximum transaction time' },
        //   { field: 'avgmedian', header: 'Median', sortable: 'custom', align: 'right', action: true , width: '85' , title: 'Median' },
        //   { field: 'avgeighty', header: 'P80', sortable: 'custom', align: 'right', action: true , width: '85' , title : '80th (%) Percentile'},
        //   { field: 'avgninety', header: 'P90', sortable: 'custom', align: 'right', action: true , width: '85' , title : '90th (%) Percentile' },
        //   { field: 'avgninetyFive', header: 'P95', sortable: 'custom', align: 'right', action: true , width: '85' , title : '95th (%) Percentile' },
        //   { field: 'avgninetyNine', header: 'P99', sortable: 'custom', align: 'right', action: true , width: '85' , title : '99th (%) Percentile'}
        // ];
        // /*Component changes in case of url summary by status(fail% column is not shown and status column is added)*/
        // if (this.nsCommonData.urlreportid) {
        //   this.cols[6].field = "errorname";
        //   this.cols[6].header = "Status";
        // }
        // this.visibleCols = [
        //   'urlName','pageName','scriptName','tried','success',  'fail', 'avgmin', 'avgaverage',
        //   'avgmax', 'avgmedian', 'avgeighty', 'avgninety', 'avgninetyFive',
        //   'avgninetyNine'
        // ];
        // this.renameArray = { "urlName": "URL Name", "tried": "Tried", "success": "Success", "fail": "Fail", "avgmin": "Min", "avgaverage": "Average", "avgmax": "Max", "avgmedian": "Median", "avgeighty": "P80", "avgninety": "P90", "avgninetyFive": "P95", "avgninetyNine": "P99"}
        // this.colOrder = ['URL Name', 'Tried', 'Success', 'Fail', 'Min', 'Average', 'Max', 'Median', 'P80', 'P90', 'P95', 'P99'];
        // if(this.nsCommonData.urlreportid) {
        //   this.visibleCols.push('errorname');
        //   this.renameArray['errorname'] = 'Status';
        //   this.colOrder.push('Status');
        // }
        // else{
        //   this.visibleCols.push('failPercent');
        //   this.renameArray['failPercent'] = '%Fail';
        //   this.colOrder.push('%Fail');
        // }
        // this.columnOptions = [];
        // for (let i = 0; i < this.cols.length; i++) {
        //   this.columnOptions.push({ label: this.cols[i].header, value: this.cols[i].field });
        // }
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Script Name') {
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        }
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'Tried') {
            me.urlInstanceReport((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row);
        }
        if (((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label) == 'Success') {
            me.urlInstanceReport((_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.row);
        }
        if (((_l = (_k = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _k === void 0 ? void 0 : _k.columnClicked) === null || _l === void 0 ? void 0 : _l.label) == 'Fail') {
            me.failure((_m = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _m === void 0 ? void 0 : _m.row);
        }
        if (((_p = (_o = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _o === void 0 ? void 0 : _o.columnClicked) === null || _p === void 0 ? void 0 : _p.label) == 'Average') {
            me.componentDetails((_q = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _q === void 0 ? void 0 : _q.row);
        }
    }
    /*Function is called when Instance report is opened (from tried and success)*/
    urlInstanceReport(row, status) {
        this.ddrData.nsCQMFilter["URL Instance"] = undefined;
        this.nsCommonData.urlInstanceData = undefined;
        this.nsCommonData.urlsessionsummarydata = row;
        this.nsCommonData.urlidx = row.urlindex;
        if (status) {
            this.nsCommonData.urlInstancethroughsuccess = true;
        }
        else {
            this.nsCommonData.urlInstancethroughsuccess = false;
        }
        if (this.commonService.isFromUrlSummary) {
            this.commonService.nsURLInstance = JSON.parse(JSON.stringify(this.commonService.nsURLSession));
            this.commonService.nsURLInstance['reportType'] = 'instance';
            delete this.commonService.nsURLInstance['fields'];
            if (this.commonService.nsURLInstance['group'] && this.commonService.nsURLInstance['order'])
                this.commonService.nsURLInstance = this.commonService.filterGroupOrder(this.commonService.nsURLInstance);
            else
                delete this.commonService.nsURLInstance['group'];
            if (this.commonService.nsURLInstance['urlidx'] && (this.commonService.nsURLInstance['urlidx'] == 'undefined' || this.commonService.nsURLInstance['urlidx'])) {
                this.commonService.nsURLInstance['urlidx'] = this.nsCommonData.urlidx;
            }
            if (this.nsCommonData.urlInstancethroughsuccess)
                this.commonService.nsURLInstance['statusCode'] = 0;
            // if (this.nsCommonData.urlsessionsummarydata != undefined) {
            //   ajaxParam += '&pageName=' + this.nsCommonData.urlsessionsummarydata.pageName + '&scriptName=' + this.nsCommonData.urlsessionsummarydata.scriptName;
            // }
            this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'URL Instance');
            this.commonService.isFromUrlSession = true;
        }
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SESSION_SUMMARY;
        this.ddrData.nsFromGraph = false;
        this._router.navigate(['/ddr/nsreports/urlInstance']);
    }
    /*Function is called when url component detail report is opened (from average)*/
    componentDetails(row) {
        this.nsCommonData.urldetaildata = undefined;
        this.nsCommonData.urlsessionsummarydata = row;
        this.nsCommonData.urlidx = row.urlindex;
        this.nsCommonData.pgDetailToURLDetailFlag = false;
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SESSION_SUMMARY;
        this._router.navigate(['/ddr/nsreports/urldetails']);
    }
    failure(row) {
        this.nsCommonData.urlfaildata = undefined;
        this.nsCommonData.urlsessionsummarydata = row;
        this.nsCommonData.urlidx = row.urlindex;
        if (this.nsCommonData.urlreportid) {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SESSION_SUMMARY;
            this.nsCommonData.FailureStatus = row.status;
            //  this._router.navigate(['/home/ddr/nsreports/urlInstance'])
        }
        else {
            this.nsCommonData.urlsessionsummarydata = row;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SESSION_SUMMARY;
            //this._router.navigate(['/home/ddr/nsreports/urlfail']);
        }
        if (this.nsCommonData.urlreportid) {
            if (this.commonService.isFromUrlSummary) {
                this.commonService.nsURLInstance = JSON.parse(JSON.stringify(this.commonService.nsURLSession));
                this.commonService.nsURLInstance['reportType'] = 'instance';
                delete this.commonService.nsURLInstance['fields'];
                delete this.commonService.nsURLInstance['group'];
                //  delete this.commonService.nsURLInstance['order'];
                if (this.commonService.nsURLInstance['urlidx'] && (this.commonService.nsURLInstance['urlidx'])) {
                    this.commonService.nsURLInstance['urlidx'] = this.nsCommonData.urlidx;
                }
                if (!this.commonService.nsURLInstance['pageName'])
                    this.commonService.nsURLInstance['pageName'] = row.pageName;
                if (this.nsCommonData.urlInstancethroughsuccess)
                    this.commonService.nsURLInstance['statusCode'] = 0;
                this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'URL Failure');
                this.commonService.isFromUrlSession = true;
            }
        }
        else {
            if (this.commonService.isFromUrlSummary) {
                this.commonService.nsURLFailure = JSON.parse(JSON.stringify(this.commonService.nsURLSession));
                if (this.commonService.nsURLFailure['objid'] == 'undefined' || this.commonService.nsURLFailure['objid'] == undefined)
                    this.commonService.nsURLFailure['objid'] = this.nsCommonData.urlidx;
                else
                    this.commonService.nsURLFailure['objid'] = this.commonService.nsURLFailure['urlidx'];
                delete this.commonService.nsURLFailure['urlidx'];
                delete this.commonService.nsURLFailure['transidx'];
                delete this.commonService.nsURLFailure['pageidx'];
                delete this.commonService.nsURLFailure['scriptidx'];
                delete this.commonService.nsURLFailure['fields'];
                delete this.commonService.nsURLFailure['strGroupBy'];
                delete this.commonService.nsURLFailure['group'];
                this.commonService.nsURLFailure['reportType'] = 'failure';
                if (this.commonService.nsURLFailure['statusCode'] == -2 || this.commonService.nsURLFailure['statusCode'] == -0) {
                    this.commonService.nsURLFailure['statusCode'] = -1;
                }
                this.commonService.nsURLFailure['strStatusName'] = 'NA';
                delete this.commonService.nsURLFailure['fields'];
                delete this.commonService.nsURLFailure['strGroupBy'];
                delete this.commonService.nsURLFailure['order'];
                delete this.commonService.nsURLFailure['location'];
                delete this.commonService.nsURLFailure['browser'];
                delete this.commonService.nsURLFailure['access'];
                if (!this.commonService.nsURLFailure['pageName'])
                    this.commonService.nsURLFailure['pageName'] = row.pageName;
                // this.url += '&object=0&limit=22&offset=0&statusCode=-1&showCount=false' + '&startTime=' + startTime + '&endTime='
                // endTime + '&reportType=failure' + '&strStatusName=NA' + '&objid=' + this.urlidx;
                this.commonService.isFromUrlSession = true;
            }
        }
        if (this.nsCommonData.urlreportid) {
            this.ddrData.nsFromGraph = false;
            this._router.navigate(['/ddr/nsreports/urlInstance']);
        }
        else
            this._router.navigate(['/ddr/nsreports/urlfail']);
    }
    paginate(event) {
        // event.first = Index of the first record  (used  as offset in query)
        // event.rows = Number of rows to display in new page  (used as limit in query)
        // event.page = Index of the new page
        // event.pageCount = Total number of pages
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        if (this.limit > this.count)
            this.limit = Number(this.count);
        if ((this.limit + this.offset) > this.count)
            this.limit = Number(this.count) - Number(this.offset);
        this.makeajaxcall();
    }
    openSessionName(nodeData) {
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_12__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    formatter(value) {
        if (value != '' && !isNaN(value)) {
            return Number(Number(value)).toLocaleString();
        }
        else if (value === '') {
            return '-';
        }
        else
            return value;
    }
    ngOnDestroy() {
        this.commonService.isFromUrlSummary = false;
        this.commonService.isBackButton = false;
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.commonParams.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.urlSessionSummaryData = this.urlSessionSummaryData.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.urlSessionSummaryData = this.urlSessionSummaryData.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.urlSessionSummaryData = this.urlSessionSummaryData.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.urlSessionSummaryData = this.urlSessionSummaryData.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.urlSessionSummaryData = this.urlSessionSummaryData.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.urlSessionSummaryData = this.urlSessionSummaryDataOrgi;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.urlSessionSummaryData = this.urlSessionSummaryDataOrgi;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
};
UrlSessionSummaryComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_5__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_8__["DdrDataModelService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__["NsCommonService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_10__["TransactionDetailService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["DDRHttpService"] },
    { type: src_app_pages_home_script_manager_sm_tree_sm_tree_service__WEBPACK_IMPORTED_MODULE_15__["SmTreeService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_16__["ScriptUtilService"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_14__["DialogService"] }
];
UrlSessionSummaryComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-url-session-summary',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./url-session-summary.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./url-session-summary.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.scss")).default]
    })
], UrlSessionSummaryComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.scss":
/*!********************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.scss ***!
  \********************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-url-summary-report .colgroup-col col {\n  min-width: 120px !important;\n}\napp-url-summary-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-url-summary-report .ddr-graphpanel .highcharts-contextbutton {\n  display: none;\n}\napp-url-summary-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-url-summary-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-url-summary-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.ts":
/*!******************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.ts ***!
  \******************************************************************************************************************/
/*! exports provided: UrlSummaryReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UrlSummaryReportComponent", function() { return UrlSummaryReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! src/app/pages/ddr/constants/ns-ddr-header.constants */ "./src/app/pages/ddr/constants/ns-ddr-header.constants.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");


















let UrlSummaryReportComponent = class UrlSummaryReportComponent {
    constructor(_router, breadcrumbService, commonService, ddrData, nsCommonData, ddrRequest, messageService, sessionService, txService, ddrHttpService, scriptUtilService, dialogService) {
        this._router = _router;
        this.breadcrumbService = breadcrumbService;
        this.commonService = commonService;
        this.ddrData = ddrData;
        this.nsCommonData = nsCommonData;
        this.ddrRequest = ddrRequest;
        this.messageService = messageService;
        this.sessionService = sessionService;
        this.txService = txService;
        this.ddrHttpService = ddrHttpService;
        this.scriptUtilService = scriptUtilService;
        this.dialogService = dialogService;
        this.strGroupBy = ""; //passed in url in case of URLSUMMARYSTATUS
        this.first = { first: 0 };
        this.rows = { rows: 50 };
        this.limit = 50;
        this.offset = 0;
        this.filter = "";
        this.loading = false;
        this.commonUrl = '';
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        this.msgs = [];
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.filterValueObj = {}; //This object is used to maintain all the filter values that are given by user.
        this.filterValueArr = []; //This is to maintain order of filter given by user.
        this.filterMinTimeout = -1;
        this.filterMaxTimeout = -1;
        this.isDdrEnabled = true;
        this.errorData = "";
        this.colsForTable = [];
        let tableConfig = {
            "config": {
                "globalFilter": true,
                "download": true,
            }
        };
        this.tableConfig = tableConfig;
        this.colsForTable[0] = {
            "cols": [
                {
                    "label": "URL Name",
                    "key": "urlName",
                    "type": 0,
                    "width": "15%"
                },
                {
                    "label": "Tried",
                    "key": "tried",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Success",
                    "key": "success",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Fail",
                    "key": "fail",
                    "type": 1,
                    "width": "7%",
                    "click": "true"
                },
                {
                    "label": "Min",
                    "key": "min",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Max",
                    "key": "max",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Average",
                    "key": "average",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "click": "true",
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "Median",
                    "key": "median",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P80",
                    "key": "eighty",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P90",
                    "key": "ninety",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P95",
                    "key": "ninetyFive",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                },
                {
                    "label": "P99",
                    "key": "ninetyNine",
                    "type": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].DURATION_DATA_TYPE,
                    "width": "7%",
                    "format": src_app_pages_ddr_constants_ns_ddr_header_constants__WEBPACK_IMPORTED_MODULE_16__["DDR"].TIME_DURATION_FORMAT,
                    "classes": "text-right"
                }
            ]
        };
    }
    ngOnInit() {
        this.loading = true;
        this.screenHeight = Number(this.commonService.screenHeight) - 94;
        this.first.first = 0;
        this.rows.rows = 50;
        this.commonService.isToLoadSideBar = true;
        this.commonService.currentReport = 'URL Summary';
        this.randomNumber();
        if (this.urlSummaryStatus)
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY_STATUS);
        else
            this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY);
        this.commonService.checkForNsKeyObj(this.ddrData.nsCQMFilter, this.commonService.currentReport);
        console.log("this.commonservice.nsURLSummary==>", this.commonService.nsURLSummary);
        this.subscribeURL = this.commonService.sideBarUIObservable$.subscribe((temp) => {
            if (this.commonService.currentReport == 'URL Summary') {
                this.loading = true;
                this.limit = 50;
                this.offset = 0;
                console.log("this.paginateRef===>", this.paginateRef);
                if (this.paginateRef) {
                    let length = this.paginateRef['pageLinkSize'];
                    let arry = [];
                    for (let i = 1; i <= length; i++)
                        arry.push(i);
                    this.paginateRef['pageLinks'] = [];
                    this.paginateRef['pageLinks'] = arry;
                    this.paginateRef['_rows'] = 50;
                    this.paginateRef['_first'] = 0;
                }
                this.makeajaxcall();
                this.makeajaxcallCount();
            }
        });
        this.ddrData.passMesssage$.subscribe((mssg) => { this.showMessage(mssg); });
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.commonParams = this.commonService.getData();
                this.setTestRunInHeader();
                this.makeajaxcall();
                this.makeajaxcallCount();
            }
        });
        this.createTable();
    }
    setTestRunInHeader() {
        if (this.commonParams && this.commonParams.product.toLowerCase() == 'netstorm') {
            if (this.urlSummaryStatus)
                this.strTitle = 'Url Summary By Status Report - Test Run : ' + this.sessionService.session.testRun.id;
            else
                this.strTitle = 'Url Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else if (this.commonParams && this.commonParams.product.toLowerCase() == 'netcloud') {
            if (this.urlSummaryStatus)
                this.strTitle = 'Url Summary By Status Report - Test Run : ' + this.sessionService.session.testRun.id;
            else
                this.strTitle = 'Url Summary Report - Test Run : ' + this.sessionService.session.testRun.id;
        }
        else {
            if (this.urlSummaryStatus)
                this.strTitle = 'Netdiagnostics Enterprise - Url Summary By Status Report - Session : ' + this.sessionService.session.testRun.id;
            else
                this.strTitle = 'Netdiagnostics Enterprise - Url Summary Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = this.ddrData.getHostUrl();
        if (this.sessionService.preSession.multiDc === true) {
            this.commonParams.testRun = this.sessionService.session.testRun.id;
            console.log("all case url==>", hostDcName, "all case test run==>", this.sessionService.session.testRun.id);
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    makeajaxcall() {
        var _a, _b;
        let ajaxParam = '';
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        if (this.urlSummaryStatus)
            this.strGroupBy = "status";
        let startTime = (_a = this.commonParams) === null || _a === void 0 ? void 0 : _a.startTime;
        let endTime = (_b = this.commonParams) === null || _b === void 0 ? void 0 : _b.endTime;
        if (this.commonService.enableQueryCaching == 1) {
            ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun.id;
        }
        else {
            ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
        }
        if (this.commonService.isFilterFromNSSideBar && Object.keys(this.commonService.nsURLSummary).length != 0) {
            if (this.urlSummaryStatus) {
                let group = [];
                group = this.commonService.nsURLSummary['strGroupBy'];
                if (group[0] == '' || group[0] == undefined) {
                    group[0] = 'status';
                }
                this.commonService.nsURLSummary['strGroupBy'] = group;
            }
            this.commonService.isCQM = true;
            let param = this.commonService.nsURLSummary;
            ajaxParam = this.commonService.makeParamStringFromObjForNS(param);
            // for FIlter CQM case    so that will update value in key pair.
            this.ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsURLSummary;
        }
        else {
            ajaxParam += '&object=0&fields=4095&statusCode=-2' + '&startTime=' + startTime + '&endTime=' + endTime + '&strGroupBy=' + this.strGroupBy + '&reportType=summary' + '&strStatusName=NA';
            if (this.ddrData.nsErrorName) {
                ajaxParam += '&nsErrorName=' + this.ddrData.nsErrorName;
            }
            if (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this.ddrData.vectorName;
            if (this.ddrData.generatorName || (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this.ddrData.generatorName;
        }
        if (this.commonService.isCQM) {
            ajaxParam = this.commonService.checkAndReturnUniqueParams(ajaxParam, this.commonService.makeParamStringFromObjForNS(this.commonService.nsURLSummary, true));
            this.ddrData.nsCQMFilter[this.commonService.currentReport] = this.commonService.nsURLSummary;
        }
        this.commonService.nsURLSummary = this.commonService.makeObjectFromUrlParam(ajaxParam);
        this.commonUrl = ajaxParam;
        ajaxParam += '&limit=' + this.limit + '&offset=' + this.offset + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
        this.ddrHttpService.getNSUrlReportData(prefix, ajaxParam).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["NSUrlReportLoadedState"]) {
                this.assignData(state.data);
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignData(res) {
        this.isCancelQuerydata = true;
        this.commonService.isFilterFromNSSideBar = false;
        if (res.errorData) {
            this.loading = false;
            this.errorData = res.errorData;
            return;
        }
        this.urlSummaryData = res.data;
        setTimeout(() => {
            this.loader = false;
        }, 2000);
        this.loading = false;
        if (this.urlSummaryData.length == 0) {
            this.empty = true;
        }
        this.filtercriteria(res.starttime, res.endtime);
        this.commonService.customTimePlaceHolder = [];
        this.commonService.customTimePlaceHolder.push(res.starttime, res.endtime);
        //  this.createTable();
        this.urlSummaryDataOrig = this.urlSummaryData;
        setTimeout(() => {
            this.first = { first: this.offset };
            this.rows = { rows: this.limit };
        }, 1000);
    }
    filtercriteria(startTime, endTime) {
        this.filter = "";
        this.toolTipStatus = '';
        this.toolTipUrl = '';
        this.filterStatus = '';
        this.filterUrl = '';
        let urlSummaryHeader = JSON.parse(JSON.stringify(this.commonService.nsURLSummary));
        if (this.sessionService.preSession.multiDc === true) {
            this.filter += "DC=" + (this.ddrData.dcName || 'Master');
        }
        if (!this.commonService.isValidParamInObj(urlSummaryHeader, 'phaseName')) {
            if (this.ddrData.startTimeInDateFormat) {
                this.filter += ', From=' + this.ddrData.startTimeInDateFormat;
            }
            else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
                this.filter += ', From=' + startTime;
            }
            if (this.ddrData.endTimeInDateFormat) {
                this.filter += ', To=' + this.ddrData.endTimeInDateFormat;
            }
            else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
                this.filter += ', To=' + endTime;
            }
        }
        if (this.ddrData.generatorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filter += ', Generator Name=' + this.ddrData.generatorName;
        if (this.ddrData.vectorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filter += ', Group Name=' + this.ddrData.vectorName;
        if (this.commonService.isValidParamInObj(urlSummaryHeader, "url")) {
            let url = decodeURIComponent(JSON.parse(JSON.stringify(urlSummaryHeader['url'])));
            if (url && (url.length >= 20)) {
                this.toolTipUrl += url;
                this.filterUrl += ", Url=" + url.substring(0, 19) + " ...";
            }
            else
                this.filterUrl += ", Url=" + url;
        }
        if (this.commonService.isValidParamInObj(urlSummaryHeader, "pageName")) {
            this.filter += ', Page=' + urlSummaryHeader['pageName'];
        }
        if (this.commonService.isValidParamInObj(urlSummaryHeader, "scriptName")) {
            this.filter += ', Script=' + urlSummaryHeader['scriptName'];
        }
        if (this.commonService.isValidParamInObj(urlSummaryHeader, "transactionName")) {
            this.filter += ', Transaction=' + urlSummaryHeader['transactionName'];
        }
        if (this.commonService.isValidParamInObj(urlSummaryHeader, "location")) {
            this.filter += ', Location=' + urlSummaryHeader['location'];
        }
        if (this.commonService.isValidParamInObj(urlSummaryHeader, "browser")) {
            this.filter += ', Browser=' + urlSummaryHeader['browser'];
        }
        if (this.commonService.isValidParamInObj(urlSummaryHeader, "access")) {
            this.filter += ', Access=' + urlSummaryHeader['access'];
        }
        if (this.commonService.isValidParamInObj(urlSummaryHeader, 'statusCodeFC')) {
            let status = urlSummaryHeader['statusCodeFC'];
            if (status && status.length >= 20) {
                this.toolTipStatus += urlSummaryHeader['statusCodeFC'];
                status = status.substring(0, 19);
                this.filterStatus += ", Status=" + status + " ....";
            }
            else
                this.filterStatus += ", Status=" + status;
        }
        if (this.commonService.isValidParamInObj(urlSummaryHeader, 'strGroupBy'))
            this.filter += ", group=" + urlSummaryHeader.strGroupBy;
        if (this.commonService.isValidParamInObj(urlSummaryHeader, 'order'))
            this.filter += ", order=" + urlSummaryHeader.order;
        if (this.commonService.isValidParamInObj(urlSummaryHeader, 'phaseName'))
            this.filter += ", Phase Name=" + urlSummaryHeader.phaseName;
        if (this.filter.startsWith(',')) {
            this.filter = this.filter.substring(1);
        }
        if (this.filter.endsWith(',')) {
            this.filter = this.filter.substring(0, this.filter.length - 1);
        }
        console.log("url=========>>>", this.commonService.nsURLSummary);
    }
    makeajaxcallCount() {
        let isCount = true;
        let countUrl = this.commonUrl + '&showCount=true' + '&productKey=' + this.sessionService.session.cctx.pk;
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        this.ddrHttpService.getNSUrlReportData(prefix, countUrl, isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_12__["NSUrlReportLoadedState"]) {
                this.assignCountData(state.data);
                isCount = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignCountData(countdata) {
        this.count = countdata.totalCount;
        if (this.limit > this.count)
            this.limit = Number(this.count);
        console.log("countdata", countdata);
    }
    paginate(event) {
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        if (this.limit > this.count)
            this.limit = Number(this.count);
        this.loader = true;
        this.getProgressBar();
        if ((this.limit + this.offset) > this.count)
            this.limit = Number(this.count) - Number(this.offset);
        this.makeajaxcall();
    }
    /** Method for progressbar */
    getProgressBar() {
        this.value = 1;
        let interval = setInterval(() => {
            this.value = this.value + Math.floor(Math.random() * 10) + 1;
            if (this.value >= 100) {
                this.value = 100;
                clearInterval(interval);
            }
        }, 300);
    }
    /*Function is called when Instance report is opened (from tried and success)*/
    urlInstanceReport(row, status) {
        this.commonService.nsURLInstance = {}; // for in case if user apply filter in instance then go back in summary then goes to instance.
        // then the object will still be remaining there therefore will oopen up same data of instance again. for bug :68564
        this.commonService.currentReport = 'URL Instance';
        console.log("inside url instance ==>", this.commonService.nsURLSummary, " instacne ", this.commonService.nsURLInstance, " nsCQM ** ", this.ddrData.nsCQMFilter["URL Instance"]);
        this.ddrData.nsCQMFilter["URL Instance"] = undefined;
        this.nsCommonData.urlInstanceData = row;
        this.nsCommonData.urlidx = row.urlindex;
        this.nsCommonData.FailureStatus = undefined;
        this.nsCommonData.urlsessionsummarydata = undefined;
        this.ddrData.summaryToInstanceFlag = 'true';
        if (status) {
            this.nsCommonData.urlInstancethroughsuccess = true;
        }
        else {
            this.nsCommonData.urlInstancethroughsuccess = false;
        }
        if (this.commonService.isCQM) {
            console.log("inside of cqm cond==>", this.commonService.nsURLSummary);
            this.commonService.nsURLInstance = JSON.parse(JSON.stringify(this.commonService.nsURLSummary));
            this.commonService.nsURLInstance['reportType'] = 'instance';
            delete this.commonService.nsURLInstance['fields'];
            this.commonService.nsURLInstance['urlidx'] = this.nsCommonData.urlidx;
            if (this.nsCommonData.urlInstancethroughsuccess)
                this.commonService.nsURLInstance['statusCode'] = 0;
            if (this.commonService.nsURLInstance['strGroupBy'] && this.commonService.nsURLInstance['order'])
                this.commonService.nsURLInstance = this.commonService.filterGroupOrder(this.commonService.nsURLInstance);
            else
                delete this.commonService.nsURLInstance['strGroupBy'];
            if (this.urlSummaryStatus) {
                this.commonService.nsURLInstance['nsErrorName'] = row.errorname;
            }
            if (row['status'] != undefined && row['status'] != "-" && row['status'] != "NA") //works in case of group by status
             {
                this.commonService.nsURLInstance['statusCode'] = row['status'];
            }
            console.log("this.commonService.nsURLInstance==> going ourt of summary=====>", this.commonService.nsURLInstance);
            this.commonService.isFromUrlSummary = true;
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'URL Instance');
        this.ddrData.nsFromGraph = false;
        if (this.urlSummaryStatus) {
            this.ddrData.errorNameUrl = row.errorname;
            this.ddrData.fromReport = true;
            this.ddrData.errorUserSession = row.errorname;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY_STATUS;
            this._router.navigate(['/ddr/nsreports/urlInstance']);
        }
        else {
            this.ddrData.errorUserSession = undefined;
            this.ddrData.errorNameUrl = undefined;
            this.ddrData.fromReport = false;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY;
            this._router.navigate(['/ddr/nsreports/urlInstance']);
        }
    }
    /*Function is called when url component detail report is opened (from average)*/
    componentDetails(row) {
        this.nsCommonData.urlsessionsummarydata = undefined;
        this.nsCommonData.urldetaildata = row;
        this.nsCommonData.urlidx = row.urlindex;
        this.nsCommonData.pgDetailToURLDetailFlag = false;
        if (this.urlSummaryStatus) {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY_STATUS;
            this._router.navigate(['/ddr/nsreports/urldetails']);
        }
        else {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY;
            this._router.navigate(['/ddr/nsreports/urldetails']);
        }
    }
    failure(row) {
        this.nsCommonData.urlsessionsummarydata = undefined;
        this.nsCommonData.urlfaildata = row;
        this.nsCommonData.urlidx = row.urlindex;
        this.nsCommonData.urlInstancethroughsuccess = false;
        if (this.urlSummaryStatus) {
            this.ddrData.errorUserSession = row.errorname;
            this.ddrData.errorNameUrl = row.errorname;
            this.ddrData.fromReport = true;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY_STATUS;
            this.nsCommonData.FailureStatus = row.status;
        }
        else {
            this.ddrData.errorUserSession = undefined;
            this.ddrData.errorNameUrl = undefined;
            this.ddrData.fromReport = false;
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY;
        }
        if (this.commonService.isCQM) {
            if (this.urlSummaryStatus) {
                console.log("inside of cqm cond==>", this.commonService.nsURLSummary);
                this.commonService.nsURLInstance = JSON.parse(JSON.stringify(this.commonService.nsURLSummary));
                this.commonService.nsURLInstance['reportType'] = 'instance';
                delete this.commonService.nsURLInstance['fields'];
                this.commonService.nsURLInstance['urlidx'] = this.nsCommonData.urlidx;
                if (this.nsCommonData.urlInstancethroughsuccess)
                    this.commonService.nsURLInstance['statusCode'] = 0;
                delete this.commonService.nsURLInstance['strGroupBy'];
                if (this.urlSummaryStatus) {
                    this.commonService.nsURLInstance['nsErrorName'] = row.errorname;
                }
                if (row['status'] != "-") {
                    this.commonService.nsURLInstance['statusCode'] = row['status'];
                }
                console.log("this.commonService.nsURLInstance==> going ourt of summary=====>", this.commonService.nsURLInstance);
                this.commonService.isFromUrlSummary = true;
            }
            else {
                this.commonService.nsURLFailure = JSON.parse(JSON.stringify(this.commonService.nsURLSummary));
                console.log("this.commonService.nsURLFailure==>", this.commonService.nsURLFailure);
                this.commonService.nsURLFailure['objid'] = this.nsCommonData.urlidx; //for case when u click on diff row when coming back from breadcrumb.
                console.log("2nd cond==>", this.nsCommonData.urlidx);
                delete this.commonService.nsURLFailure['urlidx'];
                delete this.commonService.nsURLFailure['transidx'];
                delete this.commonService.nsURLFailure['pageidx'];
                delete this.commonService.nsURLFailure['scriptidx'];
                delete this.commonService.nsURLFailure['fields'];
                delete this.commonService.nsURLFailure['location'];
                delete this.commonService.nsURLFailure['access'];
                delete this.commonService.nsURLFailure['browser'];
                delete this.commonService.nsURLFailure['strGroupBy'];
                delete this.commonService.nsURLFailure['order'];
                this.commonService.nsURLFailure['reportType'] = 'failure';
                if (this.commonService.nsURLFailure['statusCode'] == -2 || this.commonService.nsURLFailure['statusCode'] == 0) {
                    this.commonService.nsURLFailure['statusCode'] = -1;
                }
                if (row['status'] != "-") {
                    this.commonService.nsURLFailure['statusCode'] = row['status'];
                }
                this.commonService.nsURLFailure['strStatusName'] = 'NA';
                delete this.commonService.nsURLInstance['fields'];
                console.log("this.commonservice.nsURLFailure===> going out==>", this.commonService.nsURLFailure);
                this.commonService.isFromUrlSummary = true;
            }
        }
        if (this.urlSummaryStatus) {
            this.ddrData.nsFromGraph = false;
            this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'URL Instance');
            this._router.navigate(['/ddr/nsreports/urlInstance']);
        }
        else {
            this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'URL Failure');
            this._router.navigate(['/ddr/nsreports/urlfail']);
        }
    }
    createTable() {
        let urlSummaryParam = this.commonService.nsURLSummary;
        if (this.commonService.nsURLSummary['strGroupBy'] && this.commonService.nsURLSummary['strGroupBy'].indexOf('status') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Status",
                "key": "errorname",
                "type": 0,
                "width": "7%"
            });
        }
        else {
            this.colsForTable[0].cols.push({
                "label": "%Fail",
                "key": "failPercent",
                "type": "1",
                "classes": "text-right",
                "width": "7%"
            });
        }
        if (this.commonService.nsURLSummary['strGroupBy'] && this.commonService.nsURLSummary['strGroupBy'].indexOf('transaction') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Transaction Name",
                "key": "transactionName",
                "type": "0",
                "width": "7%"
            });
        }
        if (this.commonService.nsURLSummary['strGroupBy'] && this.commonService.nsURLSummary['strGroupBy'].indexOf('page') != -1) {
            this.colsForTable[0].cols.push({
                "label": "Page Name",
                "key": "pageName",
                "type": "0",
                "width": "7%"
            });
        }
        if (this.commonService.nsURLSummary['strGroupBy'] && (this.commonService.nsURLSummary['strGroupBy'].indexOf('session') != -1 || this.commonService.nsURLSummary['strGroupBy'].indexOf('generator') != -1)) {
            if (this.commonService.nsURLSummary['strGroupBy'] && this.commonService.nsURLSummary['strGroupBy'].indexOf('session') != -1) {
                this.colsForTable[0].cols.push({
                    "label": "Script Name",
                    "key": "scriptName",
                    "type": "0",
                    "width": "7%"
                });
            }
            if (this.commonService.nsURLSummary['strGroupBy'] && this.commonService.nsURLSummary['strGroupBy'].indexOf('generator') != -1) {
                this.colsForTable[0].cols.push({
                    "label": "Generator Name",
                    "key": "generatorName",
                    "type": "0",
                    "width": "7%"
                });
            }
        }
        else {
            this.colsForTable[0].cols.push({
                "label": "Script Count",
                "key": "sessionCount",
                "type": "1",
                "click": "true",
                "classes": "text-right",
                "width": "7%",
                "selected": "false"
            });
        }
        console.log("final json------------", this.colsForTable[0].cols);
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.label) == 'Script Name') {
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        }
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'Tried') {
            me.urlInstanceReport((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row);
        }
        if (((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.label) == 'Success' && ((_j = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _j === void 0 ? void 0 : _j.row.success) !== '0') {
            me.urlInstanceReport((_k = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _k === void 0 ? void 0 : _k.row, true);
        }
        if (((_m = (_l = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _l === void 0 ? void 0 : _l.columnClicked) === null || _m === void 0 ? void 0 : _m.label) == 'Fail' && ((_o = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _o === void 0 ? void 0 : _o.row.fail) !== '0') {
            me.failure((_p = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _p === void 0 ? void 0 : _p.row);
        }
        if (((_r = (_q = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _q === void 0 ? void 0 : _q.columnClicked) === null || _r === void 0 ? void 0 : _r.label) == 'Average') {
            me.componentDetails((_s = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _s === void 0 ? void 0 : _s.row);
        }
        if (((_u = (_t = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _t === void 0 ? void 0 : _t.columnClicked) === null || _u === void 0 ? void 0 : _u.label) == 'Script Count') {
            me.scriptCount((_v = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _v === void 0 ? void 0 : _v.row);
        }
    }
    openSessionName(nodeData) {
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_15__["ScriptCompareComponent"], {
            header: 'View Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    scriptCount(row) {
        this.ddrData.nsCQMFilter["URL Session Summary"] = undefined; //resetting if user clicks on the row of urs summary.
        this.nsCommonData.urlsessionsummarydata = undefined;
        this.nsCommonData.urlreportid = this.urlSummaryStatus;
        this.nsCommonData.urlidx = row.urlindex;
        this.nsCommonData.urlSummaryData = row;
        if (this.commonService.isCQM) {
            console.log("in cqm cond of session summary==>", this.commonService.nsURLSummary);
            this.commonService.nsURLSession = JSON.parse(JSON.stringify(this.commonService.nsURLSummary));
            this.commonService.nsURLSession['summary'] = 'summary';
            if (this.nsCommonData.urlreportid)
                this.commonService.nsURLSession['group'] = "page,session,status";
            else
                this.commonService.nsURLSession['group'] = "page,session";
            this.commonService.nsURLSession['urlidx'] = this.nsCommonData.urlidx;
            this.commonService.nsURLSession['strStatusName'] = 'NA';
            this.commonService.nsURLSession['strGroupBy'] = '';
            this.commonService.isFromUrlSummary = true;
            if (row['status'] != "-") {
                this.commonService.nsURLSession['statusCode'] = row['status'];
            }
        }
        this.commonService.nsAutoFillSideBar(this.commonService.currentReport, 'URL Session Summary');
        if (this.urlSummaryStatus) {
            this.commonService.nsURLSession['statusCode'] = row['status'];
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY_STATUS;
        }
        else {
            this.commonService.nsURLSession['statusCode'] = '-2';
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_2__["BREADCRUMB_ITEMS"].URL_SUMMARY;
        }
        this._router.navigate(['/ddr/nsreports/urlsessionsummary']);
    }
    formatter(value) {
        if (value != '' && !isNaN(value)) {
            return Number(Number(value)).toLocaleString();
        }
        else if (value === '') {
            return '-';
        }
        else
            return value;
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.subscribeURL.unsubscribe();
        this.commonService.isCQM = false;
    }
    showMessage(mssg) {
        this.msgs = [];
        if (mssg == "Query Saved")
            this.msgs.push({ severity: 'success', summary: 'Success Message', detail: mssg });
        else if (mssg == "Query Already Defined")
            this.msgs.push({ severity: 'error', summary: 'Error Message', detail: mssg });
        else
            this.msgs.push({ severity: 'error', summary: 'Error Message', detail: mssg });
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
        console.log("queryId:::::::::::::" + this.queryId);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.commonParams.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        console.log("Hello u got that", url);
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    filterNameColumn(column, filterInpRef) {
        let value = filterInpRef.value;
        if (!value) {
            this.clearFilter(column, '');
            return;
        }
        else {
            this.filterValueObj[column] = value;
            if (this.filterValueArr.indexOf(column) == -1)
                this.filterValueArr.push(column);
        }
        this.urlSummaryData = this.urlSummaryData.filter(ele => ele[column].toLowerCase().startsWith(value.toLowerCase()));
    }
    filterMinValue(column, filterInpRef) {
        if (this.filterMinTimeout > 0) {
            clearTimeout(this.filterMinTimeout);
        }
        this.filterMinTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'min');
                return;
            }
            else {
                this.filterValueObj[column + '_min'] = value;
                if (this.filterValueArr.indexOf(column + '_min') == -1)
                    this.filterValueArr.push(column + '_min');
            }
            if (value.includes(":")) {
                this.urlSummaryData = this.urlSummaryData.filter(ele => this.msToTimeFormate(ele[column]) >= value);
            }
            else {
                this.urlSummaryData = this.urlSummaryData.filter(ele => Number.parseFloat(ele[column]) >= Number.parseFloat(value));
            }
            clearTimeout(this.filterMinTimeout);
        }, 1500);
    }
    filterMaxValue(column, filterInpRef) {
        if (this.filterMaxTimeout > 0) {
            clearTimeout(this.filterMaxTimeout);
        }
        this.filterMaxTimeout = setTimeout(() => {
            let value = filterInpRef.value;
            if (!value) {
                this.clearFilter(column, 'max');
                return;
            }
            else {
                this.filterValueObj[column + '_max'] = value;
                if (this.filterValueArr.indexOf(column + '_max') == -1)
                    this.filterValueArr.push(column + '_max');
            }
            if (value.includes(":")) {
                this.urlSummaryData = this.urlSummaryData.filter(ele => this.msToTimeFormate(ele[column]) <= value);
            }
            else {
                this.urlSummaryData = this.urlSummaryData.filter(ele => Number.parseFloat(ele[column]) <= Number.parseFloat(value));
            }
            clearTimeout(this.filterMaxTimeout);
        }, 1500);
    }
    clearFilter(column, filterType) {
        delete this.filterValueObj[column + filterType];
        this.filterValueArr = this.filterValueArr.filter(ele => ele != column);
        if (Object.keys(this.filterValueObj).length == 0) {
            this.urlSummaryData = this.urlSummaryDataOrig;
        }
        else {
            this.reApplyFilter();
        }
    }
    reApplyFilter() {
        let tmpArr = [];
        let tmpObj = [];
        tmpArr = JSON.parse(JSON.stringify(this.filterValueArr));
        tmpObj = JSON.parse(JSON.stringify(this.filterValueObj));
        this.filterValueArr = [];
        this.filterValueObj = [];
        this.urlSummaryData = this.urlSummaryDataOrig;
        for (let i = 0; i < tmpArr.length; i++) {
            if (tmpArr[i].indexOf('min') > -1) {
                this.filterMinValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else if (tmpArr[i].indexOf('max') > -1) {
                this.filterMaxValue(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
            else {
                this.filterNameColumn(tmpArr[i], { value: tmpObj[tmpArr[i]] });
            }
        }
    }
};
UrlSummaryReportComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_5__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_8__["NsCommonService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_9__["DDRRequestService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_17__["CavMessageService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_7__["SessionService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_10__["TransactionDetailService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_11__["DDRHttpService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_13__["ScriptUtilService"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_14__["DialogService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], UrlSummaryReportComponent.prototype, "urlSummaryStatus", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])("paginateRef")
], UrlSummaryReportComponent.prototype, "paginateRef", void 0);
UrlSummaryReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-url-summary-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./url-summary-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./url-summary-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.scss")).default]
    })
], UrlSummaryReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.scss":
/*!**************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.scss ***!
  \**************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("app-ns-usersessions-report .loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}\napp-ns-usersessions-report .ui-multiselect-trigger-icon {\n  font-size: 20px !important;\n}\napp-ns-usersessions-report .group-left {\n  float: left;\n  padding-top: 4px;\n}\napp-ns-usersessions-report .group-right {\n  float: right;\n  padding-top: 4px;\n}\napp-ns-usersessions-report .no-transactions {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  width: 430px;\n  box-shadow: 0px 0px 15px 0px #ddd;\n  border-radius: 4px;\n  margin: 100px auto;\n  padding: 20px 0px;\n}\napp-ns-usersessions-report .no-transactions img {\n  max-width: 70%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.ts":
/*!************************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.ts ***!
  \************************************************************************************************************/
/*! exports provided: NsUsersessionsReportComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NsUsersessionsReportComponent", function() { return NsUsersessionsReportComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/pages/home/transaction-detail/services/transaction-detail.service */ "./src/app/pages/home/transaction-detail/services/transaction-detail.service.ts");
/* harmony import */ var src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/pages/home/script-manager/services/script-utils.service */ "./src/app/pages/home/script-manager/services/script-utils.service.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! src/app/pages/home/script-manager/script-compare/script-compare.component */ "./src/app/pages/home/script-manager/script-compare/script-compare.component.ts");
/* harmony import */ var _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ../services/ddr.state */ "./src/app/pages/ddr/components/ns-reports/services/ddr.state.ts");

















let NsUsersessionsReportComponent = class NsUsersessionsReportComponent {
    constructor(_router, commonService, nsCommonData, breadcrumbService, sessionService, ddrData, ddrRequest, breadcrumb, txService, scriptUtilService, route, dialogService, ddrHttpService) {
        this._router = _router;
        this.commonService = commonService;
        this.nsCommonData = nsCommonData;
        this.breadcrumbService = breadcrumbService;
        this.sessionService = sessionService;
        this.ddrData = ddrData;
        this.ddrRequest = ddrRequest;
        this.breadcrumb = breadcrumb;
        this.txService = txService;
        this.scriptUtilService = scriptUtilService;
        this.route = route;
        this.dialogService = dialogService;
        this.ddrHttpService = ddrHttpService;
        this.UserSessionsData = [];
        this.limit = 50;
        this.offset = 0;
        this.loading = false;
        this.columnOptions = [];
        this.showAllOption = false;
        this.filterCriteria = "";
        this.isCancelQuery = false;
        this.isCancelQuerydata = false;
        this.isDdrEnabled = true;
        this.errorData = "";
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.isBackButton = true;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__["BREADCRUMB_ITEMS"].USER_SESSION);
        this.urlParam = this.commonService.getData();
        this.commonService.currentReport = "User Session";
        this.randomNumber();
        this.commonService.isToLoadSideBar = false;
        this.getDataFromRow();
        this.setTestRunInHeader();
        this.breadcrumb.add({ label: 'User Session', routerLink: '/ddr/nsreports/userSession' });
        this.txService.getSessionPct().subscribe((result) => {
            this.sessionPct = `(${result["msg"]})`;
        });
        this.commonService.getKeywordData().then((data) => {
            this.isDdrEnabled = (data != null && data['G_REPORTING']['data']['ALL'][0][0] && data['G_REPORTING']['data']['ALL'][0][0] == 2) ? true : false;
            if (!this.isDdrEnabled) {
                this.loading = false;
            }
            else if (this.isDdrEnabled) {
                this.makeajaxcall();
                this.makeajaxcallCount();
            }
        });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = this.ddrData.getHostUrl();
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') { //Due to A-9 migratuon..
        if (this.sessionService.preSession.multiDc === true) {
            this.urlParam.testRun = this.sessionService.session.testRun.id;
        }
        console.log('hostDcName getHostURL =', hostDcName);
        if (hostDcName.endsWith("/"))
            hostDcName = hostDcName.substring(0, hostDcName.length - 1);
        return hostDcName;
    }
    makeajaxcall() {
        /*ajax call when traverse from WD*/
        {
            let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
            let ajaxParam = '';
            if (this.commonService.enableQueryCaching == 1) {
                ajaxParam += 'cacheId=' + this.sessionService.session.testRun.id + '&testRun=' + this.sessionService.session.testRun;
            }
            else {
                ajaxParam += 'testRun=' + this.sessionService.session.testRun.id;
            }
            ajaxParam += '&object=' + this.nsCommonData.objectType + '&limit=' + this.limit + '&offset=' + this.offset;
            if (this.commonService.isFromTransactionInstance || this.commonService.isFromPageInstance) {
                if (this.commonService.isFromTransactionInstance) {
                    this.urlParam.startTime = this.commonService.nsUserSession['strStartTime'];
                    this.urlParam.endTime = this.commonService.nsUserSession['strEndTime'];
                }
                if (this.commonService.isFromPageInstance || this.commonService.isFromSessionInstance) {
                    this.urlParam.startTime = this.commonService.nsUserSession['startTime'];
                    this.urlParam.endTime = this.commonService.nsUserSession['endTime'];
                }
                if (this.commonService.nsUserSession['access'])
                    this.access = this.commonService.nsUserSession['access'];
                if (this.commonService.nsUserSession['location'])
                    this.location = this.commonService.nsUserSession['location'];
                if (this.commonService.nsUserSession['page'])
                    this.access = this.commonService.nsUserSession['page'];
            }
            ajaxParam += '&startTime=' + this.urlParam.startTime +
                '&endTime=' + this.urlParam.endTime +
                '&user=' + this.userId +
                '&script=' + this.scriptName +
                '&page=' + this.pageinst +
                '&location=' + this.location +
                '&access=' + this.access +
                '&urlidx=' + this.urlIndex +
                '&child=' + this.childIndex +
                '&trans=' + this.trxnInstance;
            if (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
                ajaxParam += '&groupName=' + this.ddrData.vectorName;
            if (this.ddrData.generatorName || (this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1))
                ajaxParam += '&generatorName=' + this.ddrData.generatorName;
            if (this.nsCommonData.objectType === '3')
                ajaxParam += '&wanenv=NA';
            else
                ajaxParam += '&wanenv=0';
            if (this.ddrData.errorUserSession)
                ajaxParam += '&errorName=' + this.ddrData.errorUserSession;
            this.url = ajaxParam;
            let finalUrl = ajaxParam + '&showCount=false' + '&queryId=' + this.queryId + '&productKey=' + this.sessionService.session.cctx.pk;
            setTimeout(() => {
                this.openpopup();
            }, this.ddrData.guiCancelationTimeOut);
            // this.ddrRequest.getDataUsingGet(finalUrl).subscribe(data => { (this.assignData(data)) });
            // this.http.get(this.url).subscribe(data => { (this.assignData(data)) });
            this.ddrHttpService.getNSUserSessionReportData(prefix, finalUrl).subscribe((state) => {
                if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__["NSUserSessionReportLoadedState"]) {
                    this.assignData(state.data);
                }
            }, (error) => {
                console.error('Error loading:', error);
            });
        }
    }
    assignData(res) {
        if (res.errorData) {
            this.errorData = res.errorData;
            this.loading = false;
            return;
        }
        this.isCancelQuerydata = true;
        this.UserSessionsData = res.data;
        if (this.UserSessionsData.length == 0) {
            this.empty = false;
        }
        this.loading = false;
        this.loader = false;
        this.createTable();
        this.showfilterCriteria(res.strStartTime, res.strEndTime);
    }
    createTable() {
        if (this.ddrData.WAN_ENV < 1 && !this.sessionService.session.testRun.cmt) {
            this.relativePath = 'ddr/user-session-report/user-session-report.json';
        }
        else if (this.ddrData.WAN_ENV < 1 && this.sessionService.session.testRun.cmt) {
            this.relativePath = 'ddr/user-session-report/user-session-report1.json';
        }
        else if (!(this.ddrData.WAN_ENV < 1) && !this.sessionService.session.testRun.cmt) {
            this.relativePath = 'ddr/user-session-report/user-session-report2.json';
        }
        else {
            this.relativePath = 'ddr/user-session-report/user-session-report3.json';
        }
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f;
        console.log("event~", event);
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.columnClicked) === null || _b === void 0 ? void 0 : _b.key) == 'scriptName')
            me.openSessionName((_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.row);
        if (((_e = (_d = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _d === void 0 ? void 0 : _d.columnClicked) === null || _e === void 0 ? void 0 : _e.label) == 'Total Time')
            me.openSessionDetailReport((_f = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _f === void 0 ? void 0 : _f.row);
    }
    /**Formatter cell data for converting ms to sec field */
    msToTimeFormate(duration) {
        if (!isNaN(duration)) {
            var milliseconds, seconds, minutes, hours, temp, time;
            time = +duration;
            time = Math.round(time);
            milliseconds = time % 1000;
            time = (time - milliseconds) / 1000;
            hours = parseInt(Number(time / 3600) + '');
            time = time % 3600;
            minutes = parseInt(Number(time / 60) + '');
            time = time % 60;
            seconds = parseInt(Number(time) + '');
            return (this.appendStringToTime(hours, minutes, seconds, milliseconds));
        }
        else
            return duration;
    }
    appendStringToTime(hh, mm, ss, msec) {
        if (msec < 10)
            msec = "0" + msec;
        if (msec < 100)
            msec = "0" + msec;
        if (mm < 10)
            mm = "0" + mm;
        if (ss < 10)
            ss = "0" + ss;
        if (hh < 10)
            hh = "0" + hh; // Make hrs 2 digit string
        return (hh + ":" + mm + ":" + ss + "." + msec);
    }
    newMsToTimeFormat(duration) {
        if (!isNaN(duration)) {
            let duration1 = Number(duration);
            let timeInDateFormat;
            timeInDateFormat = this.sessionService.convertTimestampIntoFormattedString(duration1);
            return timeInDateFormat;
        }
        else {
            return duration;
        }
    }
    makeSessionIndex(nodeData) {
        return this.childIndex + ":" + nodeData;
    }
    /*
    **FUnction used to custom sort
    */
    sortColumnsOnCustom(event, tempData) {
        //for interger type data type
        if (event["field"] == 'sessionId') {
            if (event.order == -1) {
                var temp = (event["field"]);
                let arr1;
                let arr2;
                event.order = 1;
                tempData = tempData.sort(function (a, b) {
                    arr1 = a[temp].split(":");
                    arr2 = b[temp].split(":");
                    if (arr1[0] == arr2[0]) {
                        var value = Number(arr1[1]);
                        var value2 = Number(arr2[1]);
                    }
                    else {
                        var value = Number(arr1[0]);
                        var value2 = Number(arr2[0]);
                    }
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = (event["field"]);
                let arr1;
                let arr2;
                event.order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    arr1 = a[temp].split(":");
                    arr2 = b[temp].split(":");
                    if (arr1[0] == arr2[0]) {
                        var value = Number(arr1[1]);
                        var value2 = Number(arr2[1]);
                    }
                    else {
                        var value = Number(arr1[0]);
                        var value2 = Number(arr2[0]);
                    }
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        else {
            if (event.order == -1) {
                var temp = (event["field"]);
                event.order = 1;
                tempData = tempData.sort(function (a, b) {
                    var value, value2;
                    if (temp == 'scriptName' || temp == "statusName") {
                        value = (a[temp].toLocaleLowerCase());
                        value2 = (b[temp].toLocaleLowerCase());
                    }
                    else {
                        value = Number(a[temp]);
                        value2 = Number(b[temp]);
                    }
                    return (value2 > value) ? 1 : ((value2 < value) ? -1 : 0);
                });
            }
            else {
                var temp = (event["field"]);
                event.order = -1;
                //asecding order
                tempData = tempData.sort(function (a, b) {
                    var value, value2;
                    if (temp == 'scriptName' || temp == "statusName") {
                        value = (a[temp].toLocaleLowerCase());
                        value2 = (b[temp].toLocaleLowerCase());
                    }
                    else {
                        value = Number(a[temp]);
                        value2 = Number(b[temp]);
                    }
                    return (value > value2) ? 1 : ((value < value2) ? -1 : 0);
                });
            }
        }
        this.UserSessionsData = [];
        if (tempData) {
            tempData.map((rowdata) => { this.UserSessionsData = this.Immutablepush(this.UserSessionsData, rowdata); });
        }
    }
    Immutablepush(arr, newEntry) {
        return [...arr, newEntry];
    }
    ngOnDestroy() {
        this.id = false;
        this.commonService.isFromTransactionInstance = false;
        this.commonService.isFromPageInstance = false;
        this.commonService.isBackButton = false;
    }
    showHideColumn(data) {
        if (this.visibleCols.length === 1) {
            this.prevColumn = this.visibleCols[0];
        }
        if (this.visibleCols.length === 0) {
            this.visibleCols.push(this.prevColumn);
        }
        if (this.visibleCols.length !== 0) {
            for (let i = 0; i < this.cols.length; i++) {
                for (let j = 0; j < this.visibleCols.length; j++) {
                    if (this.cols[i].field === this.visibleCols[j]) {
                        this.cols[i].action = true;
                        break;
                    }
                    else {
                        this.cols[i].action = false;
                    }
                }
            }
        }
        // data.value.sort(function (a, b) {
        //   return parseFloat(a.index) - parseFloat(b.index);
        // });
        let n = this.visibleCols.length;
        this.dynamicWidthColumn = Number(1300 / n);
        this.dynamicWidthColumn = Number(this.dynamicWidthColumn.toFixed(0)) - 2;
    }
    showfilterCriteria(startTime, endTime) {
        // if (sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL') // Due to A-9 migration..
        if (this.sessionService.preSession.multiDc === true)
            this.filterCriteria += ", DC=" + (this.ddrData.dcName || 'Master');
        if (this.ddrData.startTimeInDateFormat) {
            this.filterCriteria += ', From=' + this.ddrData.startTimeInDateFormat;
        }
        else if (startTime !== 'NA' && startTime !== '' && startTime !== undefined) {
            this.filterCriteria += ', From=' + startTime;
        }
        if (this.ddrData.endTimeInDateFormat) {
            this.filterCriteria += ', To=' + this.ddrData.endTimeInDateFormat;
        }
        else if (endTime !== 'NA' && endTime !== '' && endTime !== undefined) {
            this.filterCriteria += ', To=' + endTime;
        }
        if (this.ddrData.generatorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("generator") != -1)
            this.filterCriteria += ', Generator Name=' + this.ddrData.generatorName;
        if (this.ddrData.vectorName && this.ddrData.vectorMetaData && this.ddrData.vectorMetaData.toLowerCase().indexOf("group") != -1)
            this.filterCriteria += ', Group Name=' + this.ddrData.vectorName;
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
    }
    openSessionName(rowData) {
        // let projectSubProjName = rowData['scriptName'].split("/")[0] + "/" + rowData['scriptName'].split("/")[1];
        // this.scriptUtilService.sendEditScriptObj(projectSubProjName,rowData['scriptName'].split("/")[2],'Edit',false);
        // this._router.navigate(['/script'], { relativeTo: this.route });
        this.sessionService.compareTrScript = [{ 'tr': this.sessionService.session.testRun.id }];
        this.scriptUtilService.openScriptCompareFrom = 'tr';
        this.ref = this.dialogService.open(src_app_pages_home_script_manager_script_compare_script_compare_component__WEBPACK_IMPORTED_MODULE_14__["ScriptCompareComponent"], {
            header: 'Compare Scripts',
            width: '99vw',
            styleClass: 'foterDialog',
            baseZIndex: 10000,
            showHeader: true,
            style: { 'padding': 'unset' },
            contentStyle: { 'overflow': 'hidden' },
        });
    }
    getDataFromRow() {
        if (!this.nsCommonData.currRowData["userid"] && !this.nsCommonData.currRowData["userId"]) {
            // console.log("nsCommonDataaaaaaaa1111111111", this.nsCommonData.currRowData);
            this.commData = JSON.parse(sessionStorage.getItem("currRow"));
            //  console.log("commmData111111111111111",this.commData);
        }
        else {
            // console.log("nsCommonDataaaaaaaa", this.nsCommonData.currRowData);
            this.commData = JSON.parse(JSON.stringify(this.nsCommonData.currRowData));
            // console.log("commData222222222222222",this.commData);
        }
        if (this.nsCommonData.objectType === '2') //transaction
         {
            this.reportType = 'Transacion';
            this.userId = this.commData["userInst"];
            this.childIndex = this.commData["childIndex"];
            this.trxnInstance = this.commData["TransactionName"];
            this.scriptName = this.commData["scriptName"];
            this.location = this.commData["location"];
            this.access = this.commData["access"];
            this.filterCriteria += ', Transaction= ' + this.trxnInstance;
            this.filterCriteria += ', Script= ' + this.scriptName;
            this.filterCriteria += ', User Id= ' + this.userId;
        }
        else if (this.nsCommonData.objectType === '1') //page
         {
            this.reportType = 'Page';
            let uId = this.commData["userId"];
            this.userId = uId.substring(uId.indexOf(':') + 1, uId.length);
            this.childIndex = this.commData["childIndex"];
            this.pageinst = this.commData["pageName"];
            this.scriptName = this.commData["scriptName"];
            this.location = this.commData["location"];
            this.access = this.commData["access"];
            this.filterCriteria += ', Script= ' + this.scriptName;
            this.filterCriteria += ', Page= ' + this.pageinst;
            this.filterCriteria += ', UserId= ' + this.userId;
        }
        else if (this.nsCommonData.objectType === '0') //url
         {
            this.reportType = 'Url';
            this.userId = this.commData["userId"];
            this.childIndex = this.commData["childIndex"];
            this.pageinst = this.commData["pageName"];
            this.scriptName = this.commData["scriptName"];
            this.urlIndex = this.commData["urlIndex"];
            this.filterCriteria += ', Script= ' + this.scriptName;
            this.filterCriteria += ', Page= ' + this.pageinst;
            this.filterCriteria += ', URL= ' + this.urlIndex;
            this.filterCriteria += ', UserId= ' + this.userId;
        }
        else if (this.nsCommonData.objectType === '3') //Session
         {
            this.reportType = 'Session';
            // console.log("userrrrrrrr iiiiid",this.commData);
            if (this.commData["userid"])
                this.userId = this.commData["userid"];
            if (this.commData["userId"])
                this.userId = this.commData["userId"]; // for url case
            if (this.commData["userInst"])
                this.userId = this.commData["userInst"]; //for transaction case
            let uId = this.commData["userId"];
            if (this.commData["userId"])
                this.userId = uId.substring(uId.indexOf(':') + 1, uId.length); // for page case
            this.scriptName = this.commData["scriptName"];
            if (this.commData["childindex"])
                this.childIndex = this.commData["childindex"];
            if (this.commData["childIndex"])
                this.childIndex = this.commData["childIndex"];
            this.trxnInstance = this.commData["TransactionName"]; // for user-session via session timing in case of transaction instance
            this.pageinst = this.commData["pageName"]; //  for user-session via session timing in case of page
            this.location = this.commData["location"];
            this.access = this.commData["access"];
            this.urlIndex = this.commData["urlIndex"];
            if (this.trxnInstance)
                this.filterCriteria += ', Transaction= ' + this.trxnInstance;
            if (this.pageinst)
                this.filterCriteria += ', Page= ' + this.pageinst;
            if (this.urlIndex)
                this.filterCriteria += ', URL= ' + this.urlIndex;
            if (this.userId)
                this.filterCriteria += ', UserId= ' + this.userId;
            this.filterCriteria += ', Script= ' + this.scriptName;
        }
    }
    openSessionDetailReport(nodeData) {
        // console.log("userid....... ",this.nsCommonData.currRowData);
        if (this.nsCommonData.currRowData["userid"] || this.nsCommonData.currRowData["userId"]) {
            sessionStorage.removeItem("currRow");
            sessionStorage.setItem("currRow", JSON.stringify(this.nsCommonData.currRowData));
            // console.log('this.nsCommonData---------',sessionStorage.getItem("currRow"));
        }
        this.nsCommonData.currRowData = nodeData;
        this.nsCommonData._sendAbsoluteTime = this.newMsToTimeFormat(nodeData.abStarTime);
        this.nsCommonData.userId = this.userId;
        this.nsCommonData.objectType = '3';
        this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__["BREADCRUMB_ITEMS"].SESSION_TIMING;
        this.breadcrumb.add({ label: 'Session Timing Details', routerLink: '/ddr/nsreports/sessionTiming' });
        this._router.navigate(['/ddr/nsreports/sessionTiming']);
    }
    makeajaxcallCount() {
        let isCount = true;
        let countUrl = this.url + '&showCount=true' + '&productKey=' + this.sessionService.session.cctx.pk;
        let prefix = this.ddrData.getHostWithoutLocation(this.getHostUrl());
        this.ddrHttpService.getNSUserSessionReportData(prefix, countUrl, isCount).subscribe((state) => {
            if (state instanceof _services_ddr_state__WEBPACK_IMPORTED_MODULE_16__["NSUserSessionReportLoadedState"]) {
                this.assignCountData(state.data);
                isCount = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    assignCountData(res) {
        this.count = res.totalCount;
        if (this.limit > this.count)
            this.limit = Number(this.count);
    }
    /**  Pagination method */
    paginate(event) {
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        if (this.limit > this.count)
            this.limit = Number(this.count);
        this.loader = true;
        this.getProgressBar();
        if ((this.limit + this.offset) > this.count)
            this.limit = Number(this.count) - Number(this.offset);
        this.makeajaxcall();
    }
    /** Method for progressbar */
    getProgressBar() {
        this.value = 1;
        let interval = setInterval(() => {
            this.value = this.value + Math.floor(Math.random() * 10) + 1;
            if (this.value >= 100) {
                this.value = 100;
                clearInterval(interval);
            }
        }, 300);
    }
    setTestRunInHeader() {
        if (this.urlParam && this.urlParam.product.toLowerCase() == 'netstorm') {
            this.strTitle = 'User Session Report - Test Run : ' + this.sessionService.session.testRun.id; // Removed (Netstorm -) due to A-9 ....
        }
        else if (this.urlParam && this.urlParam.product.toLowerCase() == 'netcloud')
            this.strTitle = '-User Session Report - Test Run : ' + this.sessionService.session.testRun.id;
        else {
            this.strTitle = 'Netdiagnostics Enterprise - User Session Report - Session : ' + this.sessionService.session.testRun.id;
        }
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this.ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        let url = "";
        url = decodeURIComponent(this.getHostUrl() + '/' + this.urlParam.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/webddr/cancleQuery?testRun=" + this.sessionService.session.testRun.id + "&queryId=" + this.queryId;
        this.isCancelQuery = false;
        this.ddrRequest.getDataInStringUsingGet(url).subscribe(data => { return data; });
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
};
NsUsersessionsReportComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_5__["Router"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_ns_common_service__WEBPACK_IMPORTED_MODULE_6__["NsCommonService"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__["DdrBreadcrumbService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_10__["BreadcrumbService"] },
    { type: src_app_pages_home_transaction_detail_services_transaction_detail_service__WEBPACK_IMPORTED_MODULE_11__["TransactionDetailService"] },
    { type: src_app_pages_home_script_manager_services_script_utils_service__WEBPACK_IMPORTED_MODULE_12__["ScriptUtilService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_5__["ActivatedRoute"] },
    { type: primeng__WEBPACK_IMPORTED_MODULE_13__["DialogService"] },
    { type: _services_ddr_http_service__WEBPACK_IMPORTED_MODULE_15__["DDRHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], NsUsersessionsReportComponent.prototype, "id", void 0);
NsUsersessionsReportComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-ns-usersessions-report',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ns-usersessions-report.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ns-usersessions-report.component.scss */ "./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.scss")).default]
    })
], NsUsersessionsReportComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.scss":
/*!*******************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.scss ***!
  \*******************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".child-indices {\n  display: flex !important;\n  align-items: center;\n  justify-content: space-between;\n  border: solid 1px #007acc;\n  background-color: var(--background_color_1);\n  padding: 4px;\n  width: -moz-max-content;\n  width: max-content;\n  border-radius: 30px;\n  transition: all 0.3s ease-in;\n}\n.child-indices:hover {\n  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);\n}\n.child-indices:hover .hover-popup {\n  display: block;\n}\n.child-indices .indices-icon {\n  width: 40px;\n  height: 40px;\n  border-radius: 50%;\n  border: solid 0.3em #19afdc;\n}\n.child-indices .connection-point {\n  position: absolute;\n  width: 8px;\n  height: 8px;\n  background: #007acc;\n  border-radius: 50%;\n  top: 50%;\n  transform: translateY(-50%);\n}\n.child-indices .connection-point.left {\n  left: -4px;\n}\n.child-indices .connection-point.right {\n  right: -4px;\n}\n.child-indices .hover-popup {\n  left: 0px;\n  top: 55px;\n  position: absolute;\n  border-radius: 8px;\n  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\n  z-index: 10000;\n  width: 350px;\n  display: none;\n  background-color: var(--background_color_1);\n  pointer-events: none;\n}\n.child-indices .hover-popup .popup-header {\n  padding: 8px 12px;\n  font-size: 12px;\n  font-weight: bold;\n  border-radius: 6px 6px 0 0;\n}\n.parent-cluster {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  width: 50px;\n  height: 50px;\n  background-color: #bdef84;\n  border-radius: 50%;\n  font-size: 11px;\n  font-weight: 500;\n}\n.node-container.jtk-node-selected {\n  border-color: #ff6b35;\n  box-shadow: 0 0 10px rgba(255, 107, 53, 0.3);\n}\n.node-container.jtk-node-selected .node-header {\n  background: #ff6b35;\n}\n.node-container.jtk-node-selected .connection-point {\n  background: #ff6b35;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.ts":
/*!*****************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.ts ***!
  \*****************************************************************************************************/
/*! exports provided: OtelOutputNodeIndicesComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "OtelOutputNodeIndicesComponent", function() { return OtelOutputNodeIndicesComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _jsplumbtoolkit_browser_ui_angular__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @jsplumbtoolkit/browser-ui-angular */ "./node_modules/@jsplumbtoolkit/browser-ui-angular/__ivy_ngcc__/fesm2015/jsplumbtoolkit-browser-ui-angular.js");
/* harmony import */ var src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/pages/tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");






let OtelOutputNodeIndicesComponent = class OtelOutputNodeIndicesComponent extends _jsplumbtoolkit_browser_ui_angular__WEBPACK_IMPORTED_MODULE_2__["BaseNodeComponent"] {
    constructor(ddrData, _router, elasticSearch) {
        super();
        this.ddrData = ddrData;
        this._router = _router;
        this.elasticSearch = elasticSearch;
        this.menuItems = [];
        this.subscription = null;
    }
    ngOnInit() {
        var _a;
        // The node data is available via this.obj.
        this.nodeInfo = this.obj;
        // Keep hover popup data local to this node so every node shows its own details.
        this.hoveredNodeData = ((_a = this.nodeInfo) === null || _a === void 0 ? void 0 : _a.data) || null;
        if (window["logLevel"] > 0)
            console.log('Node data:', this.obj);
        if (this.hoveredNodeData)
            console.log('Hovered Node Data :', this.hoveredNodeData);
        this.menuItems = [
            {
                label: 'DB Request Report'
            },
            {
                label: 'Method Timing Report'
            },
            {
                label: 'Method Call Details'
            },
            {
                label: 'HotSpot Thread Details'
            },
            {
                label: 'HTTP Report'
            },
            {
                label: 'Exception Report'
            }
        ];
    }
    onMenuClick(event) {
        if (event.label == 'DB Request Report') {
            this.openDBReports();
        }
        else if (event.label == 'Method Timing Report') {
            this.openMethodTimingReport();
        }
        else if (event.label == 'Method Call Details') {
            this.openMethodCallingTree(this.nodeInfo.data);
        }
        else if (event.label == 'HotSpot Thread Details') {
            this.openHotspotReport(this.nodeInfo.data);
        }
        else if (event.label == 'HTTP Report') {
            this.openHttpReport();
        }
        else if (event.label == 'Exception Report') {
            this.openExceptionReport();
        }
    }
    openDBReports() {
        this.elasticSearch.isFromOtelTrxnServiceMap = true;
        this.elasticSearch.setTrxServiceMapPayload(this.payload);
        this._router.navigate(['/ddr/dbReport']);
    }
    openMethodTimingReport() {
        this.elasticSearch.isFromOtelTrxnServiceMap = true;
        this.elasticSearch.setTrxServiceMapPayload(this.payload);
        this._router.navigate(['/ddr/methodtiming']);
    }
    openMethodCallingTree(nodeData) {
        this.ddrData.selectedFPRowData = {
            "testRun": nodeData.attributes["cav.TR"],
            "tierName": nodeData.attributes["cav.tier"],
            "serverName": nodeData.attributes["cav.server"],
            "appName": nodeData.attributes["cav.instance"],
            "TraceId": nodeData["trace_id"],
            "startTimeInMs": nodeData["@timestamp"],
            "selfResponseTime": nodeData["duration"]
        };
        this._router.navigate(['/ddr/method-call-info']);
    }
    openHotspotReport(nodeData) {
        this.ddrData.isFromOtelTrxnServiceMap = true;
        const strStartTime = Number(nodeData["@timestamp"]);
        const strEndTime = Math.ceil(Number(nodeData["@timestamp"]) + (nodeData["duration"] / 1000000));
        const url = `testRun=${nodeData.attributes["cav.TR"]},&tierName=${nodeData.attributes["cav.tier"]},&serverName=${nodeData.attributes["cav.server"]},&appName=${nodeData.attributes["cav.instance"]},&urlName=${nodeData.attributes["cav.BT"]},&strStartTime=${strStartTime},&strEndTime=${strEndTime}`;
        this.ddrData.otelTrxnServMapHSParam = url;
        this._router.navigate(['/ddr/hotspot']);
    }
    openHttpReport() {
        this.elasticSearch.isFromOtelTrxnServiceMap = true;
        this.elasticSearch.setTrxServiceMapPayload(this.payload);
        this._router.navigate(['/ddr/httpReqResp']);
    }
    openExceptionReport() {
        this.elasticSearch.isFromOtelTrxnServiceMap = true;
        this.elasticSearch.setTrxServiceMapPayload(this.payload);
        this._router.navigate(['/ddr/exception']);
    }
    ngOnDestroy() {
        var _a;
        (_a = this.subscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
    }
    onMouseLeave() {
        // This will notify any component (like the parent) that the data should be cleared.
        this.ddrData.setHoveredNode(null);
    }
    // Get node label from the data
    get nodeLabel() {
        var _a, _b;
        return ((_a = this.obj) === null || _a === void 0 ? void 0 : _a.label) || ((_b = this.obj) === null || _b === void 0 ? void 0 : _b.id) || 'Unknown Node';
    }
    // Get node ID
    get nodeId() {
        var _a;
        return ((_a = this.obj) === null || _a === void 0 ? void 0 : _a.id) || '';
    }
    // Handle node click event
    onNodeClick() {
        this.payload = this.reportPayload(this.nodeInfo.data);
        console.log('Node clicked:', this.nodeId, this.nodeLabel);
    }
    reportPayload(nodeData) {
        const pay = {
            "testRun": nodeData.attributes["cav.TR"],
            "tierName": nodeData.attributes["cav.tier"],
            "serverName": nodeData.attributes["cav.server"],
            "appName": nodeData.attributes["cav.instance"],
            "traceId": nodeData["trace_id"],
            "strStartTime": Number(nodeData["@timestamp"]),
            "strEndTime": Math.ceil(Number(nodeData["@timestamp"]) + (nodeData["duration"] / 1000000)) + 10000
        };
        console.log("Payload :", pay);
        return pay;
    }
};
OtelOutputNodeIndicesComponent.ctorParameters = () => [
    { type: src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__["DdrDataModelService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_4__["Router"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_5__["ElasticsearchQueryService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], OtelOutputNodeIndicesComponent.prototype, "hoveredNodeData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["HostListener"])('mouseleave')
], OtelOutputNodeIndicesComponent.prototype, "onMouseLeave", null);
OtelOutputNodeIndicesComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-otel-output-node-indices',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./otel-output-node-indices.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./otel-output-node-indices.component.scss */ "./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.scss")).default]
    })
], OtelOutputNodeIndicesComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.scss":
/*!*****************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.scss ***!
  \*****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.ts":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.ts ***!
  \***************************************************************************************/
/*! exports provided: OtelServiceViewComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "OtelServiceViewComponent", function() { return OtelServiceViewComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/shared/time-bar/service/time-bar.service */ "./src/app/shared/time-bar/service/time-bar.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");







let OtelServiceViewComponent = class OtelServiceViewComponent {
    constructor(timebarService, elasticSearchService, _ddrData, _router) {
        this.timebarService = timebarService;
        this.elasticSearchService = elasticSearchService;
        this._ddrData = _ddrData;
        this._router = _router;
        this.serviceData = [];
        this.showPagination = false;
    }
    ngOnInit() {
        var _a, _b, _c, _d;
        const timeValue = this.timebarService.getValue();
        this.startTime = (_b = (_a = timeValue.time.frameStart) === null || _a === void 0 ? void 0 : _a.value) !== null && _b !== void 0 ? _b : timeValue.time.frameStart;
        this.endTime = (_d = (_c = timeValue.time.frameEnd) === null || _c === void 0 ? void 0 : _c.value) !== null && _d !== void 0 ? _d : timeValue.time.frameEnd;
        this.timeDurationInSec = (this.endTime - this.startTime) / 1000;
        this.fetchDataFromElasticSearch();
    }
    fetchDataFromElasticSearch() {
        this.loader = true;
        this.relativePath = 'ddr/otel-service-view/otel-service-view.json';
        // Build payload 
        const reqPayload = {
            strStartTime: this.startTime,
            strEndTime: this.endTime
        };
        if (window['logLevel'] > 1) {
            console.log("********reqPayload******", reqPayload);
        }
        const resFields = [
            'resource.attributes.service.name',
            'duration',
            'kind'
        ];
        const elasticQuery = this.elasticSearchService.buildElasticSearchQuery(reqPayload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].OTEL_SERVICE_VIEW);
        if (window['logLevel'] > 1) {
            console.log("********elasticQuery******", elasticQuery);
        }
        this.elasticSearchService.search(elasticQuery).subscribe(res => {
            this.elasticSearchData = res;
            if (window['logLevel'] > 1) {
                console.log('Search results from Elasticsearch:', res);
            }
            this.processElasticData(this.elasticSearchData);
            this.loader = false;
        }, error => {
            console.error('Error fetching Otel Service View data:', error);
            this.serviceData = [];
            this.loader = false;
        });
    }
    processElasticData(elasticData) {
        var _a, _b;
        try {
            const buckets = ((_b = (_a = elasticData === null || elasticData === void 0 ? void 0 : elasticData.aggregations) === null || _a === void 0 ? void 0 : _a.spans_by_service) === null || _b === void 0 ? void 0 : _b.buckets) || [];
            this.serviceData = buckets.map((bucket) => ({
                serviceName: bucket.key,
                totalTransaction: bucket.doc_count,
                tps: ((bucket.doc_count / this.timeDurationInSec)).toFixed(3),
                avgResTime: ((bucket.total_duration.value / 1000000) / bucket.doc_count).toFixed(3),
                p90Duration: (bucket.duration_percentiles.values["90.0"] / 1000000).toFixed(3)
            }));
            this.showPagination = this.serviceData.length > 10;
            if (window['logLevel'] > 1) {
                console.log('Processed Service Data:', this.serviceData);
            }
        }
        catch (e) {
            console.error('Error processing service data:', e);
            this.serviceData = [];
        }
    }
    clickButtonEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "onRowSelect") {
            this._ddrData.startTime = this.startTime;
            this._ddrData.endTime = this.endTime;
            this._ddrData.getOtelMode().then(() => {
                this._ddrData.otelServiceName = event.cavEventExt.row.serviceName;
                this._router.navigate(['/ddr/flowpath']);
            });
        }
    }
};
OtelServiceViewComponent.ctorParameters = () => [
    { type: src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_3__["TimebarService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_6__["ElasticsearchQueryService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] }
];
OtelServiceViewComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-otel-service-view',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./otel-service-view.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./otel-service-view.component.scss */ "./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.scss")).default]
    })
], OtelServiceViewComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.css":
/*!**************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.css ***!
  \**************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\r\n    height: 50px;\r\n    margin-left: 50%;\r\n}\r\n\r\ntable, tr, td {\r\n    border: none;\r\n}\r\n\r\n.container{\r\n    border-radius:3px;\r\n    padding:5px;\r\n    width: 60%;\r\n    margin: 0 auto;\r\n   }\r\n\r\n.context-menu{\r\n    display: none;\r\n    position: fixed;\r\n    border: 1px solid black;\r\n    border-radius: 3px;\r\n    width: 150px;\r\n    background: white;\r\n    z-index:1000;\r\n   }\r\n\r\n.context-menu ul{\r\n    list-style: none;\r\n    padding: 2px;\r\n    }\r\n\r\n.context-menu ul li{\r\n    padding: 5px 2px;\r\n    margin-bottom: 3px;\r\n    color: white;\r\n    font-weight: bold;\r\n    background-color: darkturquoise;\r\n   \r\n    }\r\n\r\n.context-menu ul li:hover{\r\n    cursor: pointer;\r\n    background-color: #7fffd4;\r\n   }\r\n\r\n/* .seq-dig-div{\r\n    width: 1244px; \r\n    height: 430px;\r\n    overflow: auto;\r\n    position : relative;\r\n} */\r\n\r\n.ui-panel-contents {\r\n    overflow: auto;\r\n    height: 367px;\r\n  }");

/***/ }),

/***/ "./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.ts":
/*!*************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.ts ***!
  \*************************************************************************************/
/*! exports provided: SequenceDiagramComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SequenceDiagramComponent", function() { return SequenceDiagramComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _custom_directive_area_hover_directive__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../custom-directive/area-hover-directive */ "./src/app/pages/ddr/custom-directive/area-hover-directive.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");













let SequenceDiagramComponent = class SequenceDiagramComponent {
    constructor(commonService, _ddrData, _router, breadcrumbService, route, breadcrumb, messageService, sessionService, ddrHttpService) {
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this._router = _router;
        this.breadcrumbService = breadcrumbService;
        this.route = route;
        this.messageService = messageService;
        this.sessionService = sessionService;
        this.ddrHttpService = ddrHttpService;
        this.filterCriteria = ""; // To show filter criteria
        this.loading = false; // Loading ajax loader icon
        this.showImage = false; // flag to show image or not
        this.isAgent = true; // flag to show DDAI icon or not
        this.arrCoordinates = []; // to store the coordinates of the image
        this.filterDialog = false; // flag to show filter dialog
        this.txtClassWidth = 300; // Initial width (in pixels) of the input field 'txtClassWidth'
        this.txtThresholdWallTime = 1500; // Default threshold wall time (in milliseconds) for a numeric input field 'txtThresholdWallTime'.
        this.txtFilterWallTime = 1; // Default filter wall time (in milliseconds) for a numeric input field 'txtFilterWallTime'.
        this.txtFlterMethodLevel = 5; // Default filter method level for a numeric input field 'txtFlterMethodLevel'
        this.selectedPackageList = []; // array to store selected packages from package list in filter dialog
        this.selectedClassList = []; // array to store selected classes from class list in filter dialog
        this.selectedMethodList = []; // array to store selected methods from method list in filter dialog
        this.uniqueMethodSignature = []; // array to store unique method signature
        this.selectedActClss = [];
        this.selectedActMethod = [];
        this.ignoreFilterCallOutsforSD = ['T', 'E', 'D', 'd', 'J', 'e', 't', 'a', 'A']; // array to store ignore filter callouts
        this.corrInfo = []; // array to store co-ordinates and package,class,method info of the selected callout
        this.callOutFPFlag = false; // flag to show callout flowpath data
        this.imagePathObj = {}; // Object containing image paths
        this.keysArr = [];
        this.showFilter = true; // flag to show filter-criteria
        this.showAutoInstrPopUp = false; // flag to show auto instrumentation pop up
        this.callOutObj = {}; // object to store callout details
        this.seqDFilter = ''; // To show applied filters in sequence diagram accordion
        this.breadcrumb = breadcrumb;
    }
    ngOnChanges(changes) {
        if (this._ddrData.splitViewBreadCrumbFlag && this._ddrData.splitViewFlag) {
            this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            // this.breadcrumb.add({label: 'Sequence Diagram', routerLink: '/ddr/sequencediagram/:param'});
            this.commonService.column = "flowpathInstance";
            this.breadcrumb.add({ label: 'Sequence Diagram', routerLink: '/ddr/DdrSplitview' });
        }
        else {
            this.breadcrumb.add({ label: this.columnData.flowpathInstance });
            // this.breadcrumb.add({label: 'Sequence Diagram', routerLink: '/ddr/sequencediagram/:param'});
            this.commonService.column = "flowpathInstance";
            this.breadcrumb.add({ label: 'Sequence Diagram', routerLink: '/ddr/DdrSplitview' });
            this._ddrData.splitViewBreadCrumbFlag = true;
        }
        if (this._ddrData.splitViewFlag === true) {
            this._ddrData.setInLogger("DDR:Flowpath", "Sequence Diagram", "Open Sequence Diagram");
        }
        this.loading = true;
        this.showFilter = true;
        this.corrInfo = [];
        this.keysArr = [];
        this.arrCoordinates = [];
        this.imagePathObj = {};
        this.callOutFPFlag = false;
        this.id = this.commonService.getData();
        if (this.columnData != undefined) { // Handle queryParams
            this.queryParams = JSON.parse(JSON.stringify(this.columnData));
            if (this.queryParams['fpDuration'] != undefined) {
                if (this.queryParams['fpDuration'] == '< 1') {
                    this.queryParams.fpDuration = 0;
                    this.fpDuration = 0;
                }
                else if (this.queryParams['fpDuration'].toString().includes(',')) {
                    this.queryParams.fpDuration = this.queryParams.fpDuration.toString().replace(/,/g, "");
                    this.fpDuration = this.queryParams.fpDuration.toString().replace(/,/g, "");
                }
                else {
                    this.fpDuration = this.queryParams.fpDuration;
                }
            }
            this.trStartTime = this.queryParams.startTimeInMs;
            this.trEndTime = Number(this.queryParams.startTimeInMs) + Number(this.queryParams.fpDuration);
        }
        this.getSessionId();
        // Construct seqDFilter
        this.seqDFilter = `(Class Name Width(px)= ${this.formatter(this.txtClassWidth)}, Top Methods= ${this.formatter(this.txtFlterMethodLevel)}, Wall Time= ${this.formatter(this.txtFilterWallTime)}ms, Threshold Wall Time= ${this.formatter(this.txtThresholdWallTime)}ms)`;
        const acceptedTypes = ['Java', 'DotNet', 'DotNetC'];
        this.isAgent = acceptedTypes.includes(this.queryParams.instanceType) || acceptedTypes.includes(this.queryParams.Instance_Type);
    }
    ngOnInit() {
        this.loading = true;
        this.sub = this.route.params.subscribe(params => {
            this.param = params['param'];
        });
        if (this.param == 'fromPage') {
            this.showFilter = false;
            // this.breadcrumbService.setBreadcrumbs(CONSTANTS.BREADCRUMB_ITEMS.SEQ_DIAG);
            // this.breadcrumb.add({label: 'Sequence Diagram', routerLink: '/ddr/sequencediagram/:param'});
            this.id = this._ddrData.pagedump;
            this.getSessionId();
        }
        const acceptedTypes = ['Java', 'DotNet', 'DotNetC'];
        this.isAgent = acceptedTypes.includes(this.queryParams.instanceType) || acceptedTypes.includes(this.queryParams.Instance_Type);
    }
    /*Method is used get host url*/
    getHostUrl() {
        if (this._ddrData.isFromtrxFlow) {
            this.id.testRun = this._ddrData.testRunTr;
            return `//${this._ddrData.hostTr}:${this._ddrData.portTr}`;
        }
        let hostDcName = this._ddrData.getHostUrl();
        if (hostDcName.lastIndexOf('ALL/') !== -1)
            hostDcName = hostDcName.substring(0, hostDcName.lastIndexOf('/'));
        if (this.sessionService.preSession.multiDc) {
            const dcMatch = this.sessionService.preSession.dcData.find(dc => dc.name === this._ddrData.dcName);
            if (dcMatch) {
                this.id.testRun = dcMatch.testRun.id;
                this.testRun = this.id.testRun;
                console.log("all case url==>", hostDcName, "all case test run==>", this.id.testRun);
            }
        }
        return hostDcName;
    }
    createFilterCriteria(startTime, endTime) {
        this.filterCriteria = '';
        if (this.queryParams != undefined && this.param !== 'fromPage') {
            if (this.queryParams.tierName != "NA" && this.queryParams.tierName != "" && this.queryParams.tierName != "undefined" && this.queryParams.tierName != undefined)
                this.filterCriteria += "Tier=" + this.queryParams.tierName;
            if (this.queryParams.serverName != "NA" && this.queryParams.serverName != "" && this.queryParams.serverName != "undefined" && this.queryParams.serverName != undefined)
                this.filterCriteria += ", Server=" + this.queryParams.serverName;
            if (this.queryParams.appName != "NA" && this.queryParams.appName != "" && this.queryParams.appName != "undefined" && this.queryParams.appName != undefined)
                this.filterCriteria += ", Instance=" + this.queryParams.appName;
        }
        else {
            if (this.id.tierName != "NA" && this.id.tierName != "" && this.id.tierName != "undefined" && this.id.tierName != undefined)
                this.filterCriteria = "Tier=" + this.id.tierName;
            if (this.id.serverName != "NA" && this.id.serverName != "" && this.id.serverName != "undefined" && this.id.serverName != undefined)
                this.filterCriteria += ", Server=" + this.id.serverName;
            if (this.id.appName != "NA" && this.id.appName != "" && this.id.appName != "undefined" && this.id.appName != undefined)
                this.filterCriteria += ", Instance=" + this.id.appName;
        }
        if (startTime != undefined && startTime != '' && startTime != 'NA')
            this.filterCriteria += ", Start Time=" + startTime;
        if (endTime != undefined && endTime != '' && endTime != 'NA')
            this.filterCriteria += ", End Time=" + endTime;
        if (this.queryParams.selfResponseTime != undefined && this.queryParams.selfResponseTime != '' && this.queryParams.selfResponseTime != 'NA')
            this.filterCriteria += ", ResponseTime=" + this.formatter(this.queryParams.selfResponseTime) + "(ms)";
        if (this.queryParams.urlName != undefined && this.queryParams.urlName != '' && this.queryParams.urlName != 'NA')
            this.filterCriteria += ", BT=" + this.queryParams.urlName;
        if (this.queryParams.urlQueryParamStr != undefined && this.queryParams.urlQueryParamStr != '' && this.queryParams.urlQueryParamStr != 'NA') {
            if (this.queryParams.urlQueryParamStr.length > 45) {
                let wholeUrl = this.queryParams.urlQueryParamStr.substring(0, 45) + "...";
                this.filterCriteria += ",<span style='cursor:pointer;' title='" + this.queryParams.urlQueryParamStr + "'>" + " URL=" + wholeUrl + "</span>";
            }
            else {
                this.filterCriteria += ", URL=" + this.queryParams.urlQueryParamStr;
            }
        }
        if (this.filterCriteria.startsWith(","))
            this.filterCriteria = this.filterCriteria.substring(1);
        if (this.filterCriteria.endsWith(","))
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
    }
    formatter(value) {
        if (value != '' && !isNaN(value)) {
            return (Number(value)).toLocaleString();
        }
        else if (value === '') {
            return '-';
        }
        else
            return value;
    }
    showSeqDiag() {
        const startTimetoPass = Number(this.trStartTime) - 900000;
        const endTimetoPass = (this.trEndTime && !isNaN(this.trEndTime)) ? Number(this.trEndTime) + 900000 : (Number(this.trStartTime) + Number(this.fpDuration) + 900000);
        if (this.param) {
            this.pageName = this.id.pageName;
            this.fpInstance = this.id.flowPathInstance;
            this.strCmdArgs = ` --testrun ${this.id.testRun} --fpinstance ${this.fpInstance} --page ${this.pageName}`;
            this.imageName = `${this.fpInstance}_SequenceDiagram${this.id.testRun}_FPDetails${this.sessionID}.png`;
        }
        else if (this.callOutFPFlag) {
            const callOutFPData = this.callOutFPData[0];
            this.strCmdArgs = ` --testrun ${this.id.testRun} --fpinstance ${callOutFPData.flowpathInstance} --tierid ${callOutFPData.tierId} --serverid ${callOutFPData.serverId} --appid ${callOutFPData.appId} --urlidx ${callOutFPData.urlIndex} --methods_count ${callOutFPData.methodCount} --abs_starttime ${startTimetoPass} --abs_endtime ${Number(endTimetoPass) + 1000}`;
            this.imageName = `${callOutFPData.flowpathInstance}_SequenceDiagram${this.id.testRun}_FPDetails${this.sessionID}.png`;
        }
        else {
            const queryParams = this.queryParams;
            this.strCmdArgs = ` --testrun ${this.id.testRun} --fpinstance ${queryParams.flowpathInstance} --tierid ${queryParams.tierId} --serverid ${queryParams.serverId} --appid ${queryParams.appId} --abs_starttime ${startTimetoPass} --abs_endtime ${Number(endTimetoPass) + 1000}`;
            this.imageName = `${queryParams.flowpathInstance}_SequenceDiagram${this.id.testRun}_FPDetails${this.sessionID}.png`;
        }
        this.cacheId = this.commonService.enableQueryCaching === 1 ? this.id.testRun : undefined;
        let payload = {
            cctx: this.sessionService.session.cctx,
            cmdArgs: this.strCmdArgs,
            imageName: this.imageName,
            filterGreaterThan: this.txtFilterWallTime,
            classWidth: this.txtClassWidth,
            highLightWallTime: this.txtThresholdWallTime,
            filterTop: this.txtFlterMethodLevel,
            filters: this.selectedPackageList.toString(),
            testRun: this.id.testRun,
            ignoreFilterCallOuts: this.ignoreFilterCallOutsforSD.toString(),
            selectedNegativeMethod: this.selectedNegativeMethod + "",
            startTimeINMS: Number(this.trStartTime),
            endTimeINMS: ((Number(this.trStartTime) + Number(this.fpDuration)) + 1000),
            cacheId: this.cacheId,
            subject: {
                "tags": [
                    {
                        "key": "Tier",
                        "value": this.id.tierName,
                        "mode": 1 //specific node of that tier
                    }
                ]
            }
        };
        if (this.sessionService.preSession.multiDc === false) {
            payload = JSON.stringify(payload);
        }
        this.ddrHttpService.getSequenceDiagramData(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["SequenceDiagramLoadedState"]) {
                this.getImage(state.data);
                this.loading = false;
            }
        }, (error) => {
            console.error('Error loading:', error);
            this.loading = false;
        });
    }
    getSessionId() {
        let payload = "&tierName=" + this.id.tierName;
        this.ddrHttpService.getSessionInfo(payload).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["SessionInfoLoadedState"]) {
                this.doAssignSessionValue(state.data);
            }
        }, (error) => {
            console.error('Error in getting Session ID:', error);
            this.loading = false;
        });
    }
    doAssignSessionValue(res) {
        this.sessionID = res.id;
        this.showSeqDiag();
    }
    openAutoInstDialog() {
        const queryParam = 'testRun=' + this.id.testRun;
        this.ddrHttpService.getTRStatus(queryParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["TestRunStatusLoadedState"]) {
                let res = state.data;
                const testRunStatus = res.data;
                if (testRunStatus.length === 0) {
                    this.showAutoInstrPopUp = false;
                    this.messageService.showError("Could not start instrumentation, test is not running");
                    return;
                }
                this.showAutoInstrPopUp = true;
                let instanceType;
                if (this.queryParams.Instance_Type.toLowerCase() == 'java')
                    instanceType = 'Java';
                else if (this.queryParams.Instance_Type.toLowerCase() == 'dotnet')
                    instanceType = 'DotNet';
                else if (this.queryParams.Instance_Type.toLowerCase() == 'dotnetc')
                    instanceType = 'DotNetC';
                this.argsForAIDDSetting = [this.queryParams.appName, this.queryParams.appId, instanceType, this.queryParams.tierName,
                    this.queryParams.serverName, this.queryParams.serverId, "-1", this.queryParams.urlName, "DDR", testRunStatus[0].status, this.id.testRun];
            }
        }, (error) => {
            console.error('Error loading:', error);
        });
    }
    startInstrumentation(result) { this.showAutoInstrPopUp = false; }
    closeAIDDDialog(isCloseAIDDDialog) { this.showAutoInstrPopUp = isCloseAIDDDialog; }
    getImage(res) {
        this.loading = false;
        this.createFilterCriteria(res.startTimeInDateFormat, res.endTimeInDateFormat);
        this.startTimeInDateFormat = res.startTimeInDateFormat;
        if (res.hasOwnProperty('img')) {
            const image = res.img;
            this.uniqueMethodSignature = res.uniqueMethods;
            this.addPackageClassmethodList();
            this.showImage = true;
            if (this.sessionService.preSession.multiDc === true) {
                this.imagePath = this._ddrData.getHostUrlMultiDC() + image;
            }
            else {
                this.imagePath = this.getHostUrl() + image;
            }
            let imageKey = image.substring(image.lastIndexOf('/') + 1, image.indexOf('_'));
            this.imagePathObj[imageKey] = this.imagePath;
            this.keysArr = Object.keys(this.imagePathObj);
            this.arrCoordinates = this.arrCoordinates.concat(res.coordinates);
            this.createToolTipOnImageAtSpecificPoint();
        }
        else if (res.hasOwnProperty('errorMsg')) {
            this.showImage = false;
            this.errorMsg = res.errorMsg;
        }
    }
    createToolTipOnImageAtSpecificPoint() {
        let arr = [];
        for (let j = 0; j < this.arrCoordinates.length; j++) {
            let tempArray = this.arrCoordinates[j].split(":");
            arr[j] = { "corrdinates": tempArray[0], "pcm": tempArray[1] };
        }
        this.corrInfo = arr;
    }
    openSeqDiagInNewTab() {
        if (this.showImage == true)
            window.open(this.imagePath, "_blank");
    }
    openDBReport(data, index) {
        var _a;
        this._ddrData.splitViewFlag = false;
        this.commonService.seqDiagToDBFlag = true;
        let sqlIndex;
        let arVal = data.split('%%%');
        if (arVal[0].startsWith("DB Error"))
            sqlIndex = arVal[3].split("_")[1]; // arVal[3] is backendId
        else
            sqlIndex = arVal[4];
        const arr = JSON.parse("[" + sqlIndex + "]");
        const uniqueSqlIndex = arr.filter(function (item, i, ar) { return ar.indexOf(item) === i; });
        const callOutData = (_a = this.callOutObj[index]) === null || _a === void 0 ? void 0 : _a[0];
        if (this.param) {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SEQ_DIAG;
            this.commonService.seqDiagToDBData = this.id;
        }
        else {
            const params = callOutData ? {
                'testRun': this.queryParams.testRun, 'flowpathInstance': callOutData.flowpathInstance,
                'tierId': callOutData.tierId, 'serverId': callOutData.serverId,
                'appId': callOutData.appId, 'tierName': callOutData.tierName,
                'serverName': callOutData.serverName, 'appName': callOutData.appName,
                'fpDuration': this.queryParams.fpDuration, 'startTimeInMs': this.trStartTime,
                'sqlIndex': uniqueSqlIndex.toString(), 'product': this.id.product
            } : {
                'testRun': this.queryParams.testRun, 'flowpathInstance': this.queryParams.flowpathInstance,
                'tierId': this.queryParams.tierId, 'serverId': this.queryParams.serverId, 'appId': this.queryParams.appId,
                'tierName': this.queryParams.tierName, 'serverName': this.queryParams.serverName, 'appName': this.queryParams.appName,
                'fpDuration': this.queryParams.fpDuration, 'startTimeInMs': this.trStartTime, 'sqlIndex': uniqueSqlIndex.toString(),
                'product': this.id.product
            };
            this.commonService.seqDiagToDBData = params;
        }
        if (this._router.url.indexOf('/ddr') != -1)
            this._router.navigate(['/ddr/flowpathToDB']);
        else if (this._router.url.indexOf('/home/ED-ddr') != -1)
            this._router.navigate(['/home/ED-ddr/flowpathToDB']);
        else if (this._router.url.indexOf('/home/ddrCopyLink') != -1)
            this._router.navigate(['/home/ddrCopyLink/flowpathToDB']);
    }
    openExceptionReport(data, index, caseValue) {
        var _a;
        this.commonService.seqDiagToExceptionFlag = true;
        this._ddrData.flowpathToExFlag = false;
        this._ddrData.splitViewFlag = false;
        const arVal = data.split('%%%');
        let backendId, backendSubType;
        if (arVal.length > 3) {
            [backendId, backendSubType] = arVal[3].split('_');
        }
        const failedQuery = caseValue === "exception" ? undefined : 1;
        const endTimeInMs = Number(this.trStartTime) + Number(this.fpDuration);
        const sequenceNumber = arVal[2];
        const seqNoToPass = sequenceNumber.substring(sequenceNumber.lastIndexOf(".") + 1);
        const callOutData = (_a = this.callOutObj[index]) === null || _a === void 0 ? void 0 : _a[0];
        if (this.param) {
            this.breadcrumbService.parentComponent = _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_5__["BREADCRUMB_ITEMS"].SEQ_DIAG;
            this.commonService.seqDiagToDBData = this.id;
        }
        else {
            const params = callOutData ? {
                'testRun': this.queryParams.testRun, 'flowpathInstance': callOutData.flowpathInstance,
                'tierId': callOutData.tierId, 'serverId': callOutData.serverId,
                'appId': callOutData.appId, 'tierName': callOutData.tierName,
                'serverName': callOutData.serverName, 'appName': callOutData.appName,
                'fpDuration': this.queryParams.fpDuration, 'startTimeInMs': this.trStartTime,
                'backendSubType': backendSubType, 'backendid': backendId, 'backendName': arVal[4], 'product': this.id.product, 'failedQuery': failedQuery
            } : {
                'testRun': this.id.testRun, 'flowpathInstance': this.queryParams.flowpathInstance, 'startTimeInMs': this.trStartTime,
                'endTimeInMs': endTimeInMs, 'tierId': this.queryParams.tierId, 'tierName': this.queryParams.tierName, 'serverId': this.queryParams.serverId,
                'serverName': this.queryParams.serverName, 'appId': this.queryParams.appId, 'appName': this.queryParams.appName, 'backendSubType': backendSubType,
                'backendid': backendId, 'backendName': arVal[4], 'product': this.id.product, 'seqNo': seqNoToPass, 'failedQuery': failedQuery
            };
            this.commonService.seqDiagToExceptionData = params;
        }
        if (this._router.url.indexOf('/ddr') != -1)
            this._router.navigate(['/ddr/exception']);
        else if (this._router.url.indexOf('/home/ED-ddr') != -1)
            this._router.navigate(['/home/ED-ddr/exception']);
        else if (this._router.url.indexOf('/home/ddrCopyLink') != -1)
            this._router.navigate(['/home/ddrCopyLink/exception']);
    }
    onRightClick(event) {
        event.preventDefault();
        jQuery('.context-menu').toggle(100).css({
            top: (event.pageY - 40) + 'px',
            left: event.pageX + 'px'
        });
        jQuery(document).click(function (event) {
            event.stopPropagation();
            jQuery('.context-menu').hide();
        });
        //this.myAreaDirective.showContextMenu();
    }
    openCallOutFlowpathInstance(data, index) {
        const startTimeInMs = Number(this.trStartTime) - 60000;
        const endTimeInMs = Number(this.trStartTime) + Number(this.fpDuration) + 6000;
        let childflowpaths = this.queryParams.flowpathInstance;
        if (this.queryParams.prevFlowpathInstance != '0')
            childflowpaths = this.queryParams.prevFlowpathInstance;
        const cmdArgs = ` --testrun ${this.queryParams.testRun} --prev_fpinstance ${childflowpaths} --begin_seq_num ${data.split('%%%')[2]} --abs_starttime ${startTimeInMs} --abs_endtime ${endTimeInMs}`;
        const queryParam = "cmdArgs=" + cmdArgs;
        this.ddrHttpService.getCalloutFlowpathDetail(queryParam).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["CalloutFlowpathLoadedState"]) {
                this.assignCallOutFPValue(state.data, index);
            }
        }, (error) => {
            console.error('Error in getting Callout Flowpath Detail', error);
        });
    }
    assignCallOutFPValue(res, index) {
        if (res.data.length != 0) {
            this.callOutFPFlag = true;
            this.callOutFPData = res.data;
            this.callOutObj[index] = this.callOutFPData;
            this.getSessionId();
        }
        else {
            this.messageService.showInfo("No data found for this Callout");
        }
    }
    addPackageClassmethodList() {
        let packageList = [];
        let classList = [];
        let methodList = [];
        for (let k = 0; k < this.uniqueMethodSignature.length; k++) {
            let tempArr = this.uniqueMethodSignature[k].split(".");
            let methodN = this.concatArrayToString(tempArr.splice(tempArr.length - 1, 1));
            let classN = this.concatArrayToString(tempArr.splice(tempArr.length - 1, 1));
            let packageN = this.concatArrayToString(tempArr);
            if (packageN != "" && packageN != "-" && packageList.findIndex(x => x.label == packageN) == -1)
                packageList.push({ "label": packageN, "value": packageN });
            if (classN != "" && classN != "-" && classList.findIndex(x => x.label == classN) == -1)
                classList.push({ "label": classN, "value": packageN + "_" + classN });
            if (methodN != "" && methodN != "-" && classList.findIndex(x => x.label == methodN) == -1)
                methodList.push({ "label": methodN, "value": packageN + "_" + classN + "_" + methodN });
        }
        this.packageList = packageList;
        this.actualPackageList = packageList;
        this.actualClassList = classList;
        this.actualMethodList = methodList;
        this.classList = classList;
        this.methodList = methodList;
    }
    getClassList() {
        let classList = [];
        for (let i = 0; i < this.selectedPackageList.length; i++) {
            let pkg = this.selectedPackageList[i];
            for (let j = 0; j < this.actualClassList.length; j++) {
                let value = this.actualClassList[j]['value'];
                if (value.indexOf(pkg) != -1) {
                    classList.push(this.actualClassList[j]);
                }
            }
        }
        let selectedActClss = [];
        for (let i = 0; i < classList.length; i++) {
            let classValue = classList[i]['value'];
            for (let j = 0; j < this.selectedClassList.length; j++) {
                if (classValue.indexOf(this.selectedClassList[j]) != -1)
                    selectedActClss.push(classValue);
            }
        }
        if (this.selectedPackageList.length == 0) {
            this.addPackageClassmethodList();
            this.selectedActClss = [];
            this.selectedClassList = [];
            this.selectedActMethod = [];
            this.selectedMethodList = [];
        }
        else {
            this.classList = [];
            this.classList = classList;
            this.selectedClassList = selectedActClss;
            this.getMethodList();
        }
    }
    getMethodList() {
        let methodList = [];
        let actualClass = [];
        for (let i = 0; i < this.selectedClassList.length; i++) {
            let cls = this.selectedClassList[i];
            let val = this.classList.find((obj) => { return obj.value == cls; });
            actualClass.push(val['label']);
            for (let j = 0; j < this.actualMethodList.length; j++) {
                let value = this.actualMethodList[j]['value'];
                if (value.indexOf(cls) != -1) {
                    methodList.push(this.actualMethodList[j]);
                }
            }
        }
        let selectedMethodList = [];
        for (let i = 0; i < methodList.length; i++) {
            let methodValue = methodList[i]['value'];
            for (let j = 0; j < this.selectedMethodList.length; j++) {
                if (methodValue.indexOf(this.selectedMethodList[j]) != -1)
                    selectedMethodList.push(methodValue);
            }
        }
        if (this.selectedClassList.length == 0) {
            this.methodList = Object.assign(this.actualMethodList);
            this.selectedActClss = [];
            this.selectedActMethod = [];
            this.selectedMethodList = [];
        }
        else {
            this.methodList = [];
            this.methodList = methodList;
            this.selectedMethodList = selectedMethodList;
            this.selectedActClss = actualClass;
        }
    }
    concatArrayToString(arr) {
        var str = "";
        for (var i = 0; i < arr.length; i++) {
            str = str + arr[i];
            if (arr.length - 1 != i)
                str = str + ".";
        }
        return str;
    }
    applyDefaultValue() {
        this.txtFilterWallTime = 5;
        this.txtFlterMethodLevel = 5;
        this.txtThresholdWallTime = 1500;
        this.txtClassWidth = 300;
        this.selectedPackageList = [];
        this.selectedActClss = [];
        this.selectedActMethod = [];
        this.selectedClassList = [];
        this.selectedMethodList = [];
        this.addPackageClassmethodList();
        this.selectedNegativeMethod = undefined;
        this.ignoreFilterCallOutsforSD = ['T', 'E', 'D', 'd', 'J', 'e', 't', 'a', 'A'];
    }
    getActualMethodList() {
        let actMethod = [];
        for (let i = 0; i < this.selectedMethodList.length; i++) {
            let val = this.selectedMethodList[i];
            actMethod.push(this.actualMethodList.find((Object) => { return Object['value'] == val; })['label']);
        }
        if (this.selectedMethodList.length == 0) {
            this.selectedActMethod = [];
        }
        else {
            this.selectedActMethod = [];
            this.selectedActMethod = actMethod;
        }
    }
    showAllData() {
        this.txtFilterWallTime = 0;
        this.txtFlterMethodLevel = 100;
        this.txtClassWidth = 300;
        this.txtThresholdWallTime = 1500;
        this.applyThresholdFilter();
    }
    openDialogforfilter() {
        this.filterDialog = true;
    }
    applyThresholdFilter() {
        // Check if any required filter values are missing
        if (this.txtClassWidth == undefined || this.txtClassWidth == null || this.txtFlterMethodLevel == undefined || this.txtFlterMethodLevel == null || this.txtFilterWallTime == undefined || this.txtFilterWallTime == null || this.txtThresholdWallTime == undefined || this.txtThresholdWallTime == null) {
            this.messageService.showError("Please fill all the filter values.");
            return;
        }
        if (this.txtClassWidth < 150) {
            this.messageService.showError("Please enter class name width greater than 150 pixels.");
            return;
        }
        // Constructing filter string
        this.seqDFilter = '(Class Name Width(px)= ' + this.formatter(this.txtClassWidth) + ', Top Methods= ' + this.formatter(this.txtFlterMethodLevel) +
            ', Wall Time= ' + this.formatter(this.txtFilterWallTime) + 'ms, Threshold Wall Time= ' + this.formatter(this.txtThresholdWallTime) + 'ms)';
        // Check for conflicting positive and negative filters
        if (this.selectedNegativeMethod && this.selectedNegativeMethod.length > 0) {
            if (this.selectedPackageList.length > 0) {
                for (let k = 0; k < this.selectedNegativeMethod.length; k++) {
                    let pkgClsindex = this.selectedNegativeMethod[k].lastIndexOf(".");
                    let packageClassName = this.selectedNegativeMethod[k].substring(0, pkgClsindex);
                    let packageName = packageClassName.substring(0, packageClassName.lastIndexOf("."));
                    let className = packageClassName.substring(packageClassName.lastIndexOf(".") + 1, packageClassName.length);
                    let methodName = this.selectedNegativeMethod[k].substring(pkgClsindex + 1, this.selectedNegativeMethod[k].length);
                    if (this.selectedPackageList.includes(packageName) && this.selectedActClss.includes(className) && this.selectedActMethod.includes(methodName)) {
                        this.messageService.showError('Positive and negative filters cannot be the same.');
                        return;
                    }
                }
            }
        }
        this.arrCoordinates = [];
        // Initialize selected lists if they are undefined
        this.selectedPackageList = this.selectedPackageList || [];
        this.selectedActClss = this.selectedActClss || [];
        this.selectedActMethod = this.selectedActMethod || [];
        this.loading = true;
        this.filterDialog = false; // close filter dialog
        this.getSessionId();
    }
    /**
    * Validates the input event to allow only numeric characters (0-9).
    * @param event The input event to validate.
    * @returns True if the character is numeric (0-9), otherwise false.
    */
    validateQty(event) {
        if (event.charCode <= 31 || (event.charCode >= 48 && event.charCode <= 57)) {
            return true;
        }
        else {
            return false;
        }
    }
    searchMethodName(event) {
        this.negativeMethodArr = JSON.parse(JSON.stringify(this.uniqueMethodSignature));
    }
};
SequenceDiagramComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["DdrBreadcrumbService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["ActivatedRoute"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_8__["BreadcrumbService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_12__["CavMessageService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], SequenceDiagramComponent.prototype, "columnData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])(_custom_directive_area_hover_directive__WEBPACK_IMPORTED_MODULE_7__["MyAreaDirective"])
], SequenceDiagramComponent.prototype, "myAreaDirective", void 0);
SequenceDiagramComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'sequence-diagram',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./sequence-diagram.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./sequence-diagram.component.css */ "./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.css")).default]
    })
], SequenceDiagramComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.scss":
/*!*************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.scss ***!
  \*************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.ts":
/*!***********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.ts ***!
  \***********************************************************************************************/
/*! exports provided: ServiceMethodTimingComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ServiceMethodTimingComponent", function() { return ServiceMethodTimingComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");








let ServiceMethodTimingComponent = class ServiceMethodTimingComponent {
    constructor(commonService, _ddrData, sessionService, ddrHttpService, breadcrumb) {
        this.commonService = commonService;
        this._ddrData = _ddrData;
        this.sessionService = sessionService;
        this.ddrHttpService = ddrHttpService;
        this.loading = false; // AJAX-loader
        this.filterCriteria = ""; // filter-criteria string
        this.limit = 50; // specifies the maximum number of records to be retrieved from the server
        this.offset = 0; // represents the offset value used in pagination for fetching service-method timing data
        this.totalCount = 0; // stores the total number of service methods retrieved from the server
        this.customFlag = false;
        this.filterTierName = '';
        this.completeTier = '';
        this.showPagination = false; // flag to show/hide pagination
        this.isCancelQuery = false; // variable to toggle Cancel Query Dialog
        this.isCancelQuerydata = false; // variable to disable cancel query Button
        this.relativePath = "ddr/service-method-timing/service-method-timing.json"; // Relative path of JSON file
        this.breadcrumb = breadcrumb;
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.isToLoadSideBar = false;
        if (this.commonService.isFromSplitView) {
            this.breadcrumb.removeAll(false);
            this.breadcrumb.add({ label: 'Flowpath', routerLink: '/ddr/flowpath' });
            this.breadcrumb.add({ label: this.commonService.dataForServiceMethod['flowpathInstance'] || this.commonService.mtData.flowpathInstance });
            if (this._ddrData.isFromTrxnFlowmap) {
                this.breadcrumb.add({ label: 'Transaction FlowMap', routerLink: '/ddr/DdrSplitview' });
            }
            this.breadcrumb.add({ label: 'Method Timing', routerLink: '/ddr/methodtiming' });
            this.breadcrumb.add({ label: 'Service Method Timing', routerLink: '/ddr/servicemethodtiming' });
        }
        else {
            this.breadcrumb.removeAll(false);
            this.breadcrumb.add({ label: 'Method Timing', routerLink: '/ddr/methodtiming' });
            this.breadcrumb.add({ label: 'Service Method Timing', routerLink: '/ddr/servicemethodtiming' });
        }
        try {
            this.id = this.commonService.getData();
            if (this.commonService.testRun) {
                this.id.testRun = this.id.testRun;
            }
            this.queryParams = this.commonService.dataForServiceMethod; // filters for service method timing from Method Timing 
            this.randomNumber();
            this.trStartTime = this.queryParams.strStartTime;
            this.trEndTime = this.queryParams.strEndTime;
            this.getServiceMethodTimingData();
        }
        catch (error) {
            console.error('error in intialization of component ~ ', error);
        }
    }
    /**Formatter cell data for converting ms to sec field */
    secFormatter(value) {
        if (!isNaN(value)) {
            let a = Number(value / 1000).toFixed(3);
            return (Number(a).toLocaleString('en-IN'));
        }
        else
            return value;
    }
    /*Formatter to convert nanoseconds to seconds*/
    nanoFormatter(value) {
        if (!isNaN(value)) {
            let a = Number(value / 1000000000).toFixed(3);
            return (Number(a).toLocaleString('en-IN'));
        }
        else
            return value;
    }
    /*Formatter to convert nanoseconds to milliseconds*/
    milliFormatter(value) {
        if (!isNaN(value)) {
            let a = Number(value / 1000000).toFixed(3);
            return (Number(a).toLocaleString('en-IN'));
        }
        else
            return value;
    }
    getServiceMethodTimingData() {
        const me = this;
        try {
            const testRun = this.commonService.testRun || this.id.testRun;
            const queryParam = `testRun=${testRun}&tierName=${this.queryParams.tierName}&serverName=${this.queryParams.serverName}&appName=${this.queryParams.appName}&tierId=${this.queryParams.tierId}&serverId=${this.queryParams.serverId}&appId=${this.queryParams.appId}&methodId=${this.queryParams.methodid}&fpInstance=${this.queryParams.fpInstance}&urlIndex=${this.queryParams.urlIndex}&absStartTime=${this.trStartTime}&absEndtime=${this.trEndTime}&customFlag=${this.customFlag}&Duration=${this.queryParams.Duration}&startTimeinDF=${this.queryParams.startTimeinDF}&limit=${this.limit}&offset=${this.offset}&queryId=${this.queryId}${me.commonService.enableQueryCaching === 1 ? `&cacheId=${testRun}` : ''}`;
            setTimeout(() => { this.openpopup(); }, this._ddrData.guiCancelationTimeOut);
            me.ddrHttpService.getServiceMethodTimingData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_7__["ServiceMethodTimingLoadedState"]) {
                    this.doAssignValues(state.data);
                }
            }, (error) => {
                console.error('Error loading:', error);
                this.loading = false;
                if (error.hasOwnProperty('message')) {
                    this.commonService.showError(error);
                }
            });
            this.customFlag = false;
        }
        catch (err) {
            console.error("Error in fetching data ~ ", err);
        }
    }
    doAssignValues(res) {
        try {
            this.isCancelQuerydata = true;
            if (res.hasOwnProperty('Status')) {
                this.commonService.showError(res.Status);
            }
            if (!res) {
                return;
            }
            this.loading = false;
            this.data = res.data;
            this.totalCount = res.totalCount;
            this.showPagination = this.totalCount > 50;
            if (this.limit > this.totalCount) {
                this.limit = Number(this.totalCount);
            }
            if ((this.limit + this.offset) > this.totalCount) {
                this.limit = Number(this.totalCount) - Number(this.offset);
            }
            this.limit = Math.min(this.limit, this.totalCount);
            this.limit = Math.min(this.limit, this.totalCount - this.offset);
            this.showFilterCriteria(res.strStartTime, res.strEndTime);
        }
        catch (err) {
            console.error('Error in assigning values ~ ', err);
        }
    }
    paginate(event) {
        // event.first = Index of the first record  (used  as offset in query) 
        // event.rows = Number of rows to display in new page  (used as limit in query)
        // event.page = Index of the new page
        // event.pageCount = Total number of pages
        this.offset = parseInt(event.first);
        this.limit = parseInt(event.rows);
        this.limit = Math.min(this.limit, this.totalCount);
        this.getServiceMethodTimingData();
    }
    showFilterCriteria(startTime, endTime) {
        this.filterCriteria = "";
        this.completeTier = "";
        this.filterTierName = "";
        if (this.commonService.dataForServiceMethod) {
            if (this.commonService.dataForServiceMethod.tierName != 'NA' && this.commonService.dataForServiceMethod.tierName != undefined && this.commonService.dataForServiceMethod.tierName != null && this.commonService.dataForServiceMethod.tierName != '' && this.commonService.dataForServiceMethod.tierName != "undefined") {
                if (this.commonService.dataForServiceMethod.tierName.length > 32) {
                    this.filterTierName = 'Tier=' + this.commonService.dataForServiceMethod.tierName.substring(0, 32) + '...,';
                    this.completeTier = this.commonService.dataForServiceMethod.tierName;
                }
                else
                    this.filterTierName = 'Tier=' + this.commonService.dataForServiceMethod.tierName + ',';
            }
            if (this.commonService.dataForServiceMethod.serverName != 'NA' && this.commonService.dataForServiceMethod.serverName != undefined && this.commonService.dataForServiceMethod.serverName != 'undefined' && this.commonService.dataForServiceMethod.serverName != '' && this.commonService.dataForServiceMethod.serverName != null) {
                this.filterCriteria += ', Server=' + this.commonService.dataForServiceMethod.serverName;
            }
            if (this.commonService.dataForServiceMethod.appName != 'NA' && this.commonService.dataForServiceMethod.appName != undefined && this.commonService.dataForServiceMethod.appName != 'undefined' && this.commonService.dataForServiceMethod.appName != null && this.commonService.dataForServiceMethod.appName != '') {
                this.filterCriteria += ', Instance=' + this.commonService.dataForServiceMethod.appName;
            }
            if (this.commonService.dataForServiceMethod.urlName != 'NA' && this.commonService.dataForServiceMethod.urlName != undefined && this.commonService.dataForServiceMethod.urlName != 'undefined' && this.commonService.dataForServiceMethod.urlName != null && this.commonService.dataForServiceMethod.urlName != '') {
                this.filterCriteria += ', BT=' + this.commonService.dataForServiceMethod.urlName;
            }
        }
        else {
            if (this.id.tierName !== 'undefined' && this.id.tierName !== 'NA' && this.id.tierName !== '' && this.id.tierName !== undefined && this.id.tierName !== null) {
                if (this.id.tierName.length > 32) {
                    this.filterTierName += 'Tier=' + this.id.tierName.substring(0, 32) + '...,';
                    this.completeTier = this.id.tierName;
                }
                else
                    this.filterTierName += 'Tier=' + this.id.tierName + ',';
            }
            if (this.id.serverName !== 'undefined' && this.id.serverName !== 'NA' && this.id.serverName !== '' && this.id.serverName !== undefined && this.id.serverName !== null) {
                this.filterCriteria += ', Server=' + this.id.serverName;
            }
            if (this.id.appName !== 'undefined' && this.id.appName !== 'NA' && this.id.appName !== '' && this.id.appName !== undefined && this.id.appName !== null) {
                this.filterCriteria += ', Instance=' + this.id.appName;
            }
        }
        if (startTime !== 'NA' && startTime !== '' && startTime !== undefined && startTime !== "undefined") {
            this.filterCriteria += ', StartTime=' + startTime;
        }
        if (endTime !== 'NA' && endTime !== '' && endTime !== undefined && endTime !== "undefined") {
            this.filterCriteria += ', EndTime=' + endTime;
        }
        if (this.filterCriteria.startsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(1);
        }
        if (this.filterCriteria.endsWith(',')) {
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
        }
    }
    randomNumber() {
        this.queryId = (Math.random() * 1000000).toFixed(0);
    }
    waitQuery() {
        this.isCancelQuery = false;
        setTimeout(() => {
            this.openpopup();
        }, this._ddrData.guiCancelationTimeOut);
    }
    onCancelQuery() {
        const queryParams = `testRun=${this.id.testRun}&queryId=${this.queryId}&tierName=${this.queryParams.tierName}`;
        this.ddrHttpService.getCancelQueryResult(queryParams).subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_7__["CancelQueryLoadedState"]) {
                return (state.data.status);
            }
        }, (error) => {
            console.error('Error fetching status ~ ', error);
        });
        this.isCancelQuery = false;
    }
    openpopup() {
        if (!this.isCancelQuerydata)
            this.isCancelQuery = true;
    }
    ngOnDestroy() {
        if (this._ddrData.isFromTrxnFlowmap) {
            this._ddrData.splitViewFlag = false;
        }
    }
};
ServiceMethodTimingComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__["DdrDataModelService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_5__["SessionService"] },
    { type: _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_6__["NdDdrHttpService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["BreadcrumbService"] }
];
ServiceMethodTimingComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'service-method-timing',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./service-method-timing.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./service-method-timing.component.scss */ "./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.scss")).default]
    })
], ServiceMethodTimingComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.css":
/*!*********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.css ***!
  \*********************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\n    height: 50px;\n    margin-left: 50%;\n}\n.ForToolTip{\n    text-align: left;\n    cursor: pointer;\n    display:block;\n    width:100%;\n}\n\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.ts":
/*!********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.ts ***!
  \********************************************************************************************/
/*! exports provided: GroupByAllComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "GroupByAllComponent", function() { return GroupByAllComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../tools/configuration/nd-config/services/cav-top-panel-navigation.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-top-panel-navigation.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/pages/ddr/services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");











let GroupByAllComponent = class GroupByAllComponent {
    //constructor  to initialize value
    constructor(commonService, route, router, _cavConfigService, _navService, _ddrData, ddrRequest, sessionService, ndDdrHttpService) {
        this.commonService = commonService;
        this.route = route;
        this.router = router;
        this._cavConfigService = _cavConfigService;
        this._navService = _navService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.stSignature = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this.downloadJSON = [];
        this.relativePathForSignature = "ddr/thread-hotspot-report/group-by-all.json";
        //Structured for hotspot 1st table 
        this.hotspotData = [{ "CompareST": "", "STSignature": "", "CompareDepth": "", "DisplayName": "", "TopMethods": "", "Count": "", "Min": "", "Max": "", "Average": "", "Variance": "", "Tierid": "", "Serverid": "", "Appid": "", "MinDepth": "", "MaxDepth": "", "MinToolTip": "", "MaxToolTip": "", "AvgToolTip": "", "VmrToolTip": "" }];
        //Structured for hotspot 2nd table
        this.hotspotSecData = [{ "0": "", "1": "", "2": "", "3": "", "4": "", "5": "", "6": "", "7": "" }];
        //Used to show the stacktrace information for first time
        this.selectItem = { "CompareST": "", "STSignature": "", "CompareDepth": "", "DisplayName": "", "TopMethods": "", "Count": "", "Min": "", "Max": "", "Average": "", "Variance": "", "Tierid": "", "Serverid": "", "Appid": "", "MinDepth": "", "MaxDepth": "", "MinToolTip": "", "MaxToolTip": "", "AvgToolTip": "", " VmrToolTip": "" };
    }
    /**
    * Loader will visible when load the component first time
    */
    ngOnInit() {
        this.id = this.commonService.getData();
        this.createDropDownMenu();
        this.createCols();
        this.startTimeInDate = this.id.startTimeInDateFormat;
        this.endTimeInDate = this.id.endTimeInDateFormat;
        this.getHotspotData();
        this.createTimeRangeHeader();
    }
    createCols() {
        this.colsForStackTrace = [
            { field: 'methodName', header: 'Method', sortable: false, action: true, align: 'left', width: '30%' },
            { field: 'className', header: 'Class', sortable: false, action: true, align: 'left', width: '50%' },
            { field: 'lineNo', header: 'Line', sortable: false, action: true, align: 'right', width: '15%' },
            { field: 'packageName', header: 'Source File', sortable: false, action: true, align: 'left', width: '25%' },
            { field: 'frameNo', header: 'Frame', sortable: false, action: true, align: 'right', width: '15%' }
        ];
        this.visibleColsForStackTrace = [
            '4', '3', '2', '1', '0'
        ];
        this.columnOptionsForStackTrace = [];
        for (let i = 0; i < this.colsForStackTrace.length; i++) {
            this.columnOptionsForStackTrace.push({ label: this.colsForStackTrace[i].header, value: this.colsForStackTrace[i].field });
        }
    }
    ngOnDestroy() {
        this.commonService.indexArr.push(1);
    }
    createDropDownMenu() {
        this.timeRange = [];
        this.timeRange.push({ label: 'Last 10 Min', value: '10' });
        this.timeRange.push({ label: 'Last 20 Min', value: '20' });
        this.timeRange.push({ label: 'Last 30 Min', value: '30' });
        this.timeRange.push({ label: 'Last 40 Min', value: '40' });
        this.timeRange.push({ label: 'Last 50 Min', value: '50' });
        this.timeRange.push({ label: 'Last 60 Min', value: '60' });
    }
    createTimeRangeHeader() {
        if (this.id.isZoomPanel == "true") {
            this.hideTimeFilters = true;
            this.hideTimeRange = false;
        }
        else {
            this.hideTimeFilters = false;
            this.hideTimeRange = true;
        }
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.id.testRun = this._ddrData.testRun;
            console.log("all case url==>", hostDcName, "all case test run==>", this.id.testRun);
        }
        else {
            hostDcName = this._ddrData.getHostUrl();
        }
        console.log('hostDcName =', hostDcName);
        return hostDcName;
    }
    //To set thread stacktrace header information
    getSelected(event) {
        this.selectItem = event.data;
    }
    //Method to apply filtes based on input
    clickApply(searchVal, timeVal) {
        if ((searchVal == undefined) && (timeVal == undefined)) {
            alert("Please enter some valid value");
            return;
        }
        else {
            var strStartTime;
            var strEndTime;
            var timeFilterUrl;
            if (this.id.product.replace("/", "") == "netstorm" && timeVal != undefined) {
                timeFilterUrl = 'testRun=' + this.id.testRun;
                timeFilterUrl = timeFilterUrl + "&graphTimeKey=" + timeVal;
                this.ndDdrHttpService.getTimeStamp(timeFilterUrl).subscribe((state) => {
                    if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_9__["TimeStampLoadedState"]) {
                        this.setTimeFilter(state.data, searchVal);
                    }
                });
            }
            else {
                if (timeVal != undefined) {
                    timeVal = Number(timeVal) * 60 * 1000; //dropdown(nTime) value to ms
                    var testDuration = Number(this.id.endTime) - Number(this.id.startTime);
                    if (testDuration > timeVal) {
                        var applyST = Number(this.id.endTime) - timeVal;
                        strStartTime = applyST;
                        strEndTime = this.id.endTime;
                    }
                    else //calculate end time when test is less than input time
                     {
                        alert("Filters time is greater than test run total time");
                        strStartTime = Number(this.id.endTime) - Number(testDuration);
                        strEndTime = this.id.endTime;
                    }
                }
                else {
                    strStartTime = this.id.startTime;
                    strEndTime = this.id.endTime;
                }
                var queryParam;
                if (this.commonService.enableQueryCaching == 1) {
                    queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime + "&searchKeyVal=" + searchVal;
                }
                else {
                    queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime + "&searchKeyVal=" + searchVal;
                }
                try {
                    return this.ndDdrHttpService.getGroupFrameData(queryParam).subscribe((state) => {
                        if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_9__["GroupFrameDataLoadedState"]) {
                            this.doAssignValueHotspot(state.data);
                        }
                    }, (error) => {
                        console.error(error);
                    });
                }
                catch (error) {
                    console.error(error);
                }
            }
        }
    }
    setTimeFilter(res, searchVal) {
        var strStartTime;
        var strEndTime;
        var queryParam;
        strStartTime = res.ddrStartTime;
        strEndTime = res.ddrEndTime;
        if (this.commonService.enableQueryCaching == 1) {
            queryParam += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime + "&searchKeyVal=" + searchVal;
        }
        else {
            queryParam += "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime + "&searchKeyVal=" + searchVal;
        }
        try {
            this.ndDdrHttpService.getGroupFrameData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_9__["GroupFrameDataLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                console.error(error);
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Method called when click on Thread count row
    clickOnThreadCount(displayName, signatureName, compareDepth) {
        let dataArr = [];
        dataArr.push(displayName);
        dataArr.push(signatureName);
        dataArr.push(0);
        dataArr.push(compareDepth);
        this.stSignature.emit(dataArr);
    }
    //Method to reset the data
    clickReset(searchFilter) {
        searchFilter = undefined;
        this.stackTrace = undefined;
        this.selectedTimeRange = undefined;
        this.getHotspotData();
    }
    //Method to get data when clcik on thread id -for thread stack trace
    passDataForStackTrace(data) {
        //dynamic creation for stack trace header info
        this.stackTraceFilter = `(Signature:${data.STSignature}, Thread Count(s):${data.Count}, Average Duration:${data.Average}seconds)`;
        let queryParam = "";
        if (this.commonService.enableQueryCaching == 1) {
            queryParam += "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierId=" + data.Tierid + "&serverId=" + data.Serverid + "&appId=" + data.Appid + "&stsignature=" + data.STSignature + "&depth=0" + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&minDepth=" + data.MinDepth + "&maxDepth=" + data.MaxDepth + '&tierName=' + this.id.tierName;
        }
        else {
            queryParam += "testRun=" + this.id.testRun + "&tierId=" + data.Tierid + "&serverId=" + data.Serverid + "&appId=" + data.Appid + "&stsignature=" + data.STSignature + "&depth=0" + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&minDepth=" + data.MinDepth + "&maxDepth=" + data.MaxDepth + '&tierName=' + this.id.tierName;
        }
        this.getHotspotSecData(queryParam);
    }
    //Rest call to get data as a response for thread info table
    getHotspotData() {
        let queryParam = "";
        if (this.commonService.enableQueryCaching == 1) {
            queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&depth=0";
        }
        else {
            queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&depth=0";
        }
        queryParam += "&showCount=false";
        try {
            return this.ndDdrHttpService.getGroupFrameData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_9__["GroupFrameDataLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                console.error(error);
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Rest call to get data for stacktrace table
    getHotspotSecData(queryParam) {
        try {
            return this.ndDdrHttpService.getStackTraceData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_9__["StackTraceDataLoadedState"]) {
                    this.doAssignValueSecHotspot(state.data);
                }
            }, (error) => {
                console.error(error);
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Assign hotspot response value to the firstarray
    doAssignValueHotspot(res) {
        if (res.hasOwnProperty('Status')) {
            this.showError(res.Status);
        }
        this.hotspotData = res.data;
        let count = this.hotspotData.length;
        if (!count)
            count = 0;
        if (res.startTime && res.startTime != "undefined")
            this.hotspotFilter = "(Total:" + count + ", Start Time:" + res.startTime + ", End Time:" + res.endTime + ", Tier:" + this.id.tierName + ", Server:" + this.id.serverName + ", Instance:" + this.id.appName + ")";
        else
            this.hotspotFilter = "(Total:" + count + ", Tier:" + this.id.tierName + ", Server:" + this.id.serverName + ", Instance:" + this.id.appName + ")";
        if (this.hotspotData.length == 0) //If no data found. blank stack trace table
         {
            this.hotSpotSecInfo = [];
            this.stackTraceFilter = "";
        }
        else
            this.hotSpotInfo = this.getHotspotInfo();
    }
    //Assign hotspot response value to the secondtarray
    doAssignValueSecHotspot(res) {
        this.hotspotSecData = res.treedata;
        this.hotSpotSecInfo = res.treedata;
        this.downloadJSON = res.downloadJSON;
    }
    //Store value for thread data
    getHotspotInfo() {
        var arrHotSpotData = [];
        for (var i = 0; i < this.hotspotData.length; i++) {
            if (i == 0) //for first time thread header information in table
             {
                this.passDataForStackTrace(this.hotspotData[i]); //
                this.selectItem = this.hotspotData[i];
            }
            var maxDur = (this.hotspotData[i]["Max"]);
            var minDur = (this.hotspotData[i]["Min"]);
            var avgDur = (this.hotspotData[i]["Average"]);
            arrHotSpotData[i] = { CompareST: this.hotspotData[i]["CompareST"], STSignature: this.hotspotData[i]["STSignature"], CompareDepth: this.hotspotData[i]["CompareDepth"], DisplayName: this.hotspotData[i]["DisplayName"], TopMethods: this.hotspotData[i]["TopMethods"], Count: this.hotspotData[i]["Count"], Min: minDur, Max: maxDur, Average: avgDur, Variance: this.hotspotData[i]["Variance"], Tierid: this.hotspotData[i]["Tierid"], Serverid: this.hotspotData[i]["Serverid"], Appid: this.hotspotData[i]["Appid"], MinDepth: this.hotspotData[i]["MinDepth"], MaxDepth: this.hotspotData[i]["MaxDepth"], MinToolTip: this.hotspotData[i]["MinToolTip"], MaxToolTip: this.hotspotData[i]["MaxToolTip"], AvgToolTip: this.hotspotData[i]["AvgToolTip"], VmrToolTip: this.hotspotData[i]["VmrToolTip"] };
        }
        return arrHotSpotData;
    }
    //Store value for thread stackTrace data 
    getHotspotSecInfo() {
        var arrHotSpotSecData = [];
        for (var i = 0; i < this.hotspotSecData.length; i++) {
            arrHotSpotSecData[i] = { 0: this.hotspotSecData[i]["0"], 1: this.hotspotSecData[i]["1"], 2: this.hotspotSecData[i]["2"], 3: this.hotspotSecData[i]["3"], 4: this.hotspotSecData[i]["4"], 5: this.hotspotSecData[i]["5"], 6: this.hotspotSecData[i]["6"], 7: this.hotspotSecData[i]["7"] };
        }
        return arrHotSpotSecData;
    }
    showError(msg) {
        this.errMsg = [];
        this.errMsg.push({ severity: 'error', summary: 'Error Message', detail: msg });
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable" && ((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.columnClicked) === null || _d === void 0 ? void 0 : _d.key) === "DisplayName") {
            me.passDataForStackTrace(event.cavEventExt.row);
        }
        else if (((_f = (_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.actionConfig) === null || _f === void 0 ? void 0 : _f.action) === "clickable" && ((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.key) === "Count") {
            me.clickOnThreadCount(event.cavEventExt.row.DisplayName, event.cavEventExt.row.STSignature, event.cavEventExt.row.CompareDepth);
        }
    }
};
GroupByAllComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["ActivatedRoute"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_4__["CavConfigService"] },
    { type: _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_5__["CavTopPanelNavigationService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_6__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_7__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_8__["SessionService"] },
    { type: src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"])()
], GroupByAllComponent.prototype, "stSignature", void 0);
GroupByAllComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-group-by-all',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./group-by-all.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./group-by-all.component.css */ "./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.css")).default]
    })
], GroupByAllComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.css":
/*!***************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.css ***!
  \***************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\n    height: 50px;\n    margin-left: 50%;\n}\n.ForToolTip{\n    text-align: left;\n    cursor: pointer;\n    display:block;\n    width:270px;\n}\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.ts":
/*!**************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.ts ***!
  \**************************************************************************************************/
/*! exports provided: GroupByCustomComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "GroupByCustomComponent", function() { return GroupByCustomComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/common */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
/* harmony import */ var _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../tools/configuration/nd-config/services/cav-config.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-config.service.ts");
/* harmony import */ var _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../tools/configuration/nd-config/services/cav-top-panel-navigation.service */ "./src/app/pages/tools/configuration/nd-config/services/cav-top-panel-navigation.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/pages/ddr/services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");












let GroupByCustomComponent = class GroupByCustomComponent {
    constructor(commonService, route, router, location, _cavConfigService, _navService, _ddrData, ddrRequest, sessionService, nddrHttpService) {
        this.commonService = commonService;
        this.route = route;
        this.router = router;
        this.location = location;
        this._cavConfigService = _cavConfigService;
        this._navService = _navService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.nddrHttpService = nddrHttpService;
        this.stSignature = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this.downloadJSON = [];
        //Structured for hotspot 1st table 
        this.hotspotData = [{ "CompareST": "", "STSignature": "", "CompareDepth": "", "DisplayName": "", "TopMethods": "", "Count": "", "Min": "", "Max": "", "Average": "", "Variance": "", "Tierid": "", "Serverid": "", "Appid": "", "MinDepth": "", "MaxDepth": "", "MinToolTip": "", "MaxToolTip": "", "AvgToolTip": "", "VmrToolTip": "" }];
        //Structured for hotspot 2nd table 
        this.hotspotSecData = [{ "0": "", "1": "", "2": "", "3": "", "4": "", "5": "", "6": "", "7": "" }];
        //Used to show the stacktrace information for first time
        this.selectItem = { "CompareST": "", "STSignature": "", "CompareDepth": "", "DisplayName": "", "TopMethods": "", "Count": "", "Min": "", "Max": "", "Average": "", "Variance": "", "Tierid": "", "Serverid": "", "Appid": "", "MinDepth": "", "MaxDepth": "", "MinToolTip": "", "MaxToolTip": "", "AvgToolTip": "", "VmrToolTip": "" };
        this.relativePathForSignature = "ddr/thread-hotspot-report/group-by-custom.json";
        // Varibles used for column level filter
        this.toggleFilterTitleForSignature = '';
        this.isEnabledColumnFilterForSignature = false;
        this.toggleFilterTitleForStack = '';
        this.isEnabledColumnFilterForStack = true;
        this.showDownLoadReportIcon = true;
    }
    ngOnInit() {
        this.id = this.commonService.getData();
        this.createDropDownMenu();
        this.createCols();
        this.startTimeInDate = this.id.startTimeInDateFormat;
        this.endTimeInDate = this.id.endTimeInDateFormat;
        this.createTimeRangeHeader();
        this.clickGroupBy(this.topFrame);
        this.setTestRunInHeader();
    }
    createCols() {
        this.colsForStackTrace = [
            { field: 'methodName', header: 'Method', sortable: false, action: true, align: 'left', width: '30%' },
            { field: 'className', header: 'Class', sortable: false, action: true, align: 'left', width: '50%' },
            { field: 'lineNo', header: 'Line', sortable: false, action: true, align: 'right', width: '15%' },
            { field: 'packageName', header: 'Source File', sortable: false, action: true, align: 'left', width: '25%' },
            { field: 'frameNo', header: 'Frame', sortable: false, action: true, align: 'right', width: '15%' }
        ];
        this.visibleColsForStackTrace = [
            '4', '3', '2', '1', '0'
        ];
        this.columnOptionsForStackTrace = [];
        for (let i = 0; i < this.colsForStackTrace.length; i++) {
            this.columnOptionsForStackTrace.push({ label: this.colsForStackTrace[i].header, value: this.colsForStackTrace[i].field });
        }
    }
    ngOnDestroy() {
        this.commonService.indexArr.push(2);
    }
    createDropDownMenu() {
        this.timeRange = [];
        this.timeRange.push({ label: 'Last 10 Min', value: '10' });
        this.timeRange.push({ label: 'Last 20 Min', value: '20' });
        this.timeRange.push({ label: 'Last 30 Min', value: '30' });
        this.timeRange.push({ label: 'Last 40 Min', value: '40' });
        this.timeRange.push({ label: 'Last 50 Min', value: '50' });
        this.timeRange.push({ label: 'Last 60 Min', value: '60' });
    }
    setTestRunInHeader() {
        if (decodeURIComponent(this.getHostUrl() + '/' + this.id.product).indexOf("netstorm") != -1)
            this.strTitle = "Netstorm - Thread HotSpots - Test Run : " + this.id.testRun;
        else
            this.strTitle = "Netdiagnostics Enterprise - Thread HotSpots - Session : " + this.id.testRun;
    }
    createTimeRangeHeader() {
        if (this.id.isZoomPanel == "true") {
            this.hideTimeFilters = true;
            this.hideTimeRange = false;
        }
        else {
            this.hideTimeFilters = false;
            this.hideTimeRange = true;
        }
    }
    //Method to open groupby screen based on depth
    clickGroupBy(groupByVal) {
        var queryParam;
        if (this.commonService.enableQueryCaching == 1) {
            queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&depth=" + groupByVal + "&showCount=false";
        }
        else {
            queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&depth=" + groupByVal + "&showCount=false";
        }
        try {
            return this.nddrHttpService.getGroupFrameData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["GroupFrameDataLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                console.error(error);
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //To set thread stacktrace header information
    getSelected(event) {
        this.selectItem = event.data;
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.id.testRun = this._ddrData.testRun;
        }
        else {
            hostDcName = this._ddrData.getHostUrl();
        }
        return hostDcName;
    }
    //Method to apply filtes based on input
    clickApply(searchVal, timeVal) {
        if ((searchVal == undefined) && (timeVal == undefined)) {
            alert("Please enter some valid value");
            return;
        }
        else {
            var strStartTime;
            var strEndTime;
            var timeFilterUrl;
            if (this.id.product.replace("/", "") == "netstorm" && timeVal != undefined) {
                timeFilterUrl = 'testRun=' + this.id.testRun;
                timeFilterUrl = timeFilterUrl + "&graphTimeKey=" + timeVal;
                this.nddrHttpService.getTimeStamp(timeFilterUrl).subscribe((state) => {
                    if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["TimeStampLoadedState"]) {
                        this.setTimeFilter(state.data, searchVal);
                    }
                });
            }
            else {
                if (timeVal != undefined) {
                    timeVal = Number(timeVal) * 60 * 1000; //dropdown(nTime) value to ms
                    var testDuration = Number(this.id.endTime) - Number(this.id.startTime);
                    if (testDuration > timeVal) {
                        var applyST = Number(this.id.endTime) - timeVal;
                        strStartTime = applyST;
                        strEndTime = this.id.endTime;
                    }
                    else //calculate end time when test is less than input time
                     {
                        alert("Filters time is greater than test run total time");
                        strStartTime = Number(this.id.endTime) - Number(testDuration);
                        strEndTime = this.id.endTime;
                    }
                }
                else {
                    strStartTime = this.id.startTime;
                    strEndTime = this.id.endTime;
                }
                var queryParam;
                if (this.commonService.enableQueryCaching == 1) {
                    queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime + "&searchKeyVal=" + searchVal + "&depth=" + this.topFrame;
                }
                else {
                    queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime + "&searchKeyVal=" + searchVal + "&depth=" + this.topFrame;
                }
                try {
                    return this.nddrHttpService.getGroupFrameData(queryParam).subscribe((state) => {
                        if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["GroupFrameDataLoadedState"]) {
                            this.doAssignValueHotspot(state.data);
                        }
                    }, (error) => {
                        console.error(error);
                    });
                }
                catch (error) {
                    console.error(error);
                }
            }
        }
    }
    setTimeFilter(res, searchVal) {
        var strStartTime;
        var strEndTime;
        var queryParam;
        strStartTime = res.ddrStartTime;
        strEndTime = res.ddrEndTime;
        if (this.commonService.enableQueryCaching == 1) {
            queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime + "&searchKeyVal=" + searchVal + "&depth=" + this.topFrame;
        }
        else {
            queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime + "&searchKeyVal=" + searchVal + "&depth=" + this.topFrame;
        }
        try {
            this.nddrHttpService.getGroupFrameData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["GroupFrameDataLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                console.error(error);
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Whenn clicked on thread count
    clickOnThreadCount(displayName, signatureName, compareDepth) {
        let dataArr = [];
        dataArr.push(displayName);
        dataArr.push(signatureName);
        dataArr.push(0);
        dataArr.push(compareDepth);
        this.stSignature.emit(dataArr);
    }
    //Method to reset the data
    clickReset(searchFilter) {
        searchFilter = undefined;
        this.stackTrace = undefined;
        this.selectedTimeRange = undefined;
        this.getHotspotData();
    }
    //Method to get data when clcik on thread id -for thread stack trace
    passDataForStackTrace(data) {
        this.stackTraceFilter = `(Signature:${data.STSignature}, Thread Count(s):${data.Count}, Average Duration:${data.Average} seconds)`;
        let queryParam;
        if (this.commonService.enableQueryCaching == 1) {
            queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierId=" + data.Tierid + "&serverId=" + data.Serverid + "&appId=" + data.Appid + "&stsignature=" + data.STSignature + "&depth=" + data.CompareDepth + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&minDepth=" + data.MinDepth + "&maxDepth=" + data.MaxDepth + '&tierName=' + this.id.tierName;
        }
        else {
            queryParam = "testRun=" + this.id.testRun + "&tierId=" + data.Tierid + "&serverId=" + data.Serverid + "&appId=" + data.Appid + "&stsignature=" + data.STSignature + "&depth=" + data.CompareDepth + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&minDepth=" + data.MinDepth + "&maxDepth=" + data.MaxDepth + '&tierName=' + this.id.tierName;
        }
        this.getHotspotSecData(queryParam);
    }
    //Rest call to get data as a response for thread info table
    getHotspotData() {
        var queryParam;
        if (this.commonService.enableQueryCaching == 1) {
            queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&depth=" + this.topFrame;
        }
        else {
            queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&depth=" + this.topFrame;
        }
        queryParam += "&showCount=false";
        try {
            return this.nddrHttpService.getGroupFrameData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["GroupFrameDataLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                console.error(error);
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Rest call to get data as a response for thread stackTrace table 
    getHotspotSecData(queryParam) {
        try {
            return this.nddrHttpService.getStackTraceData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_11__["StackTraceDataLoadedState"]) {
                    this.doAssignValueSecHotspot(state.data);
                }
            }, (error) => {
                console.error(error);
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Assign hotspot response value to the firstarray
    doAssignValueHotspot(res) {
        if (res.hasOwnProperty('Status')) {
            this.showError(res.Status);
        }
        this.hotspotData = res.data;
        let count = this.hotspotData.length;
        if (!count)
            count = 0;
        if (res.startTime && res.startTime != "undefined")
            this.hotspotFilter = "(Total:" + count + ", Start Time:" + res.startTime + ", End Time:" + res.endTime + ", Tier:" + this.id.tierName + ", Server:" + this.id.serverName + ", Instance:" + this.id.appName + ")";
        else
            this.hotspotFilter = "(Total:" + count + ", Tier:" + this.id.tierName + ", Server:" + this.id.serverName + ", Instance:" + this.id.appName + ")";
        if (this.hotspotData.length == 0) {
            this.hotSpotSecInfo = [];
            this.stackTraceFilter = "";
            this.showDownLoadReportIcon = false;
        }
        else
            this.showDownLoadReportIcon = true;
        this.hotSpotInfo = this.getHotspotInfo();
    }
    //Assign hotspot response value to the secondarray
    doAssignValueSecHotspot(res) {
        this.hotspotSecData = res.treedata;
        this.hotSpotSecInfo = res.treedata;
        this.downloadJSON = res.downloadJSON;
    }
    //Store value for thread data
    getHotspotInfo() {
        var arrHotSpotData = [];
        for (var i = 0; i < this.hotspotData.length; i++) {
            if (i == 0) {
                this.passDataForStackTrace(this.hotspotData[i]); //
                this.selectItem = this.hotspotData[i];
            }
            var minDur = (this.hotspotData[i]["Min"]);
            var maxDur = (this.hotspotData[i]["Max"]);
            var avgDur = (this.hotspotData[i]["Average"]);
            arrHotSpotData[i] = { CompareST: this.hotspotData[i]["CompareST"], STSignature: this.hotspotData[i]["STSignature"], CompareDepth: this.hotspotData[i]["CompareDepth"], DisplayName: this.hotspotData[i]["DisplayName"], TopMethods: this.hotspotData[i]["TopMethods"], Count: this.hotspotData[i]["Count"], Min: minDur, Max: maxDur, Average: avgDur, Variance: this.hotspotData[i]["Variance"], Tierid: this.hotspotData[i]["Tierid"], Serverid: this.hotspotData[i]["Serverid"], Appid: this.hotspotData[i]["Appid"], MinDepth: this.hotspotData[i]["MinDepth"], MaxDepth: this.hotspotData[i]["MaxDepth"], MinToolTip: this.hotspotData[i]["MinToolTip"], MaxToolTip: this.hotspotData[i]["MaxToolTip"], AvgToolTip: this.hotspotData[i]["AvgToolTip"], VmrToolTip: this.hotspotData[i]["VmrToolTip"] };
        }
        return arrHotSpotData;
    }
    //Store value for thread stacktrace data
    getHotspotSecInfo() {
        var arrHotSpotSecData = [];
        for (var i = 0; i < this.hotspotSecData.length; i++) {
            arrHotSpotSecData[i] = { 0: this.hotspotSecData[i]["0"], 1: this.hotspotSecData[i]["1"], 2: this.hotspotSecData[i]["2"], 3: this.hotspotSecData[i]["3"], 4: this.hotspotSecData[i]["4"], 5: this.hotspotSecData[i]["5"], 6: this.hotspotSecData[i]["6"], 7: this.hotspotSecData[i]["7"] };
        }
        return arrHotSpotSecData;
    }
    showError(msg) {
        this.errMsg = [];
        this.errMsg.push({ severity: 'error', summary: 'Error Message', detail: msg });
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable" && ((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.columnClicked) === null || _d === void 0 ? void 0 : _d.key) === "DisplayName") {
            me.passDataForStackTrace(event.cavEventExt.row);
        }
        else if (((_f = (_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.actionConfig) === null || _f === void 0 ? void 0 : _f.action) === "clickable" && ((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.key) === "Count") {
            me.clickOnThreadCount(event.cavEventExt.row.DisplayName, event.cavEventExt.row.STSignature, event.cavEventExt.row.CompareDepth);
        }
    }
};
GroupByCustomComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["ActivatedRoute"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] },
    { type: _angular_common__WEBPACK_IMPORTED_MODULE_4__["Location"] },
    { type: _tools_configuration_nd_config_services_cav_config_service__WEBPACK_IMPORTED_MODULE_5__["CavConfigService"] },
    { type: _tools_configuration_nd_config_services_cav_top_panel_navigation_service__WEBPACK_IMPORTED_MODULE_6__["CavTopPanelNavigationService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_7__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_8__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_10__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], GroupByCustomComponent.prototype, "index", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], GroupByCustomComponent.prototype, "topFrame", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"])()
], GroupByCustomComponent.prototype, "stSignature", void 0);
GroupByCustomComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-group-by-custom',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./group-by-custom.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./group-by-custom.component.css */ "./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.css")).default]
    })
], GroupByCustomComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.css":
/*!*****************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.css ***!
  \*****************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".loadingIcon1 {\r\n    height: 50px;\r\n    margin-left: 50%;\r\n}\r\na.activeLink,\r\na.activeLink:hover {\r\n    color: #1D5290 !important;\r\n    cursor: pointer !important;\r\n}\r\n\r\n");

/***/ }),

/***/ "./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.ts":
/*!****************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.ts ***!
  \****************************************************************************************/
/*! exports provided: NogroupingComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NogroupingComponent", function() { return NogroupingComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/pages/ddr/services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");










let NogroupingComponent = class NogroupingComponent {
    // constructor to intilizes values 
    constructor(commonService, messageService, _router, _ddrData, ddrRequest, sessionService, ndDdrHttpService) {
        this.commonService = commonService;
        this.messageService = messageService;
        this._router = _router;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.stSignature = new _angular_core__WEBPACK_IMPORTED_MODULE_2__["EventEmitter"]();
        this.displayPopUp = false;
        this.downloadJSON = [];
        this.relativePathForHotspot = "ddr/thread-hotspot-report/no-grouping-hotspot.json";
        this.relativePathForIp = "ddr/thread-hotspot-report/no-grouping-ip.json";
        //Structured for all parameters 
        this.id = { "testRun": "", "tierName": "", "serverName": "", "appName": "", "startTime": "", "endTime": "", "startTimeInDateFormat": "", "endTimeInDateFormat": "", "trStartTime": "", "trDuration": "", "ipWithProd": "", "isZoomPanel": "", "strGraphKey": "" };
        //variable used for disable/enable loader image
        this.BackFlag = false;
        //Structured for hotspot 1st table
        this.hotspotData = [{ "tierid": "", "serverid": "", "appid": "", "threadid": "", "threadname": "", "hotspotstarttimestamp": "", "hotspotduration": "", "threadstate": "", "threadpriority": "", "threadstackdepth": "", "FlowPathInstance": "", "toolTipTextForHsDur": "", "hsTimeInMs": "", "hsDurationInMs": "", "hotspotElapsedTime": "", "startTime": "", "endTime": "", "instanceType": "" }];
        //Structured for Integration Point table
        this.backendData = [{ "backendType": "", "backendId": "", "backendDuration": "", "backendSubType": "", "backendStartTime": "", "modifiedBackendStartTime": "", "starttimeInMs": "", "errorCount": "" }];
        //Structured for stacktrace 2nd table
        this.hotspotSecData = [{ "0": "", "1": "", "2": "", "3": "", "4": "", "5": "", "6": "", "7": "" }];
        this.hsLimit = 10;
        this.hsOffset = 0;
        // Varibles used for column level filter
        this.showDownLoadReportIcon = true;
        //Used to show the stacktrace information for first time
        this.selectItem = { "tierid": "", "serverid": "", "appid": "", "threadid": "", "threadname": "", "hotspotstarttimestamp": "", "hotspotduration": "", "threadstate": "", "threadpriority": "", "threadstackdepth": "", "FlowPathInstance": "", "toolTipTextForHsDur": "", "hsTimeInMs": "", "hsDurationInMs": "", "hotspotElapsedTime": "", "instanceType": "" };
        this.aggCase = true;
        this.aggIpInfo = [];
        this.filterCriteriaagg = '';
        this.showPagination = false;
        this.showPaginationIP = false;
    }
    /**
     * Loader will visible when load the component first time
     */
    ngOnInit() {
        this.id = this.commonService.getData();
        this.createCols();
        this.getGraphKey();
        this.createDropDownMenu();
        this.getMode(this.id);
        this.getHotspotData();
    }
    ngOnChanges() {
        this.minDepth = this.compareDepth;
    }
    createCols() {
        this.colsForStackTrace = [
            { field: 'methodName', header: 'Method', sortable: false, action: true, align: 'left', width: '30%' },
            { field: 'className', header: 'Class', sortable: false, action: true, align: 'left', width: '50%' },
            { field: 'lineNo', header: 'Line', sortable: false, action: true, align: 'right', width: '15%' },
            { field: 'packageName', header: 'Source File', sortable: false, action: true, align: 'left', width: '25%' },
            { field: 'elapsedTime', header: 'Elapsed Time(ms)', sortable: false, action: true, align: 'right', width: '20%' },
            { field: 'frameNo', header: 'Frame', sortable: false, action: true, align: 'right', width: '15%' }
        ];
        this.visibleColsForStackTrace = [
            '4', '3', '2', '1', '0'
        ];
        this.columnOptionsForStackTrace = [];
        for (let i = 0; i < this.colsForStackTrace.length; i++) {
            this.columnOptionsForStackTrace.push({ label: this.colsForStackTrace[i].header, value: this.colsForStackTrace[i].field });
        }
    }
    ngOnDestroy() {
        this.commonService.indexArr.push(0);
    }
    getGraphKey() {
        return this.ddrRequest.getDataUsingGet(this.id.restDrillDownUrl).subscribe(data => (this.doAssigngraphKey(data)));
    }
    doAssigngraphKey(res) {
        this.graphKey = res.graphTimeKey;
    }
    createDropDownMenu() {
        this.timeRange = [];
        this.timeRange.push({ label: 'Last 10 Min', value: '10' });
        this.timeRange.push({ label: 'Last 20 Min', value: '20' });
        this.timeRange.push({ label: 'Last 30 Min', value: '30' });
        this.timeRange.push({ label: 'Last 40 Min', value: '40' });
        this.timeRange.push({ label: 'Last 50 Min', value: '50' });
        this.timeRange.push({ label: 'Last 60 Min', value: '60' });
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = "";
        if (this.sessionService.preSession.multiDc === true) {
            hostDcName = this._ddrData.getHostUrlMultiDC(isDownloadCase);
            this.id.testRun = this._ddrData.testRun;
        }
        else {
            hostDcName = this._ddrData.getHostUrl();
        }
        return hostDcName;
    }
    getMode(queryParam) {
        var mode = queryParam.product;
        this.startTimeInDate = queryParam.startTimeInDateFormat;
        this.endTimeInDate = queryParam.endTimeInDateFormat;
        this.createTimeRangeHeader(queryParam.isZoomPanel);
        this.signatureInHeader = queryParam.displayName;
        if (this.displayName != undefined)
            this.signaturePassHeader = this.displayName;
        else
            this.signaturePassHeader = "";
        if (mode == "netstorm")
            this.elapsedTimeCol = true;
        else
            this.elapsedTimeCol = false;
    }
    createTimeRangeHeader(isZoom) {
        if (isZoom == "true") {
            this.hideTimeFilters = true;
            this.hideTimeRange = false;
        }
        else {
            this.hideTimeFilters = false;
            this.hideTimeRange = true;
        }
    }
    //Method to apply filtes based on input
    clickApply(searchVal, depthVal, timeVal, durVal) {
        this.signaturePassHeader = "";
        if ((searchVal == undefined) && (depthVal == undefined) && (timeVal == undefined) && (durVal == undefined)) {
            alert("Please enter some valid value");
            return;
        }
        else {
            var strStartTime;
            var strEndTime;
            var timeFilterUrl;
            if (this.id.product.replace("/", "") == "netstorm" && timeVal != undefined) {
                timeFilterUrl = 'testRun=' + this.id.testRun;
                timeFilterUrl = timeFilterUrl + "&graphTimeKey=" + timeVal;
                this.ndDdrHttpService.getTimeStamp(timeFilterUrl).subscribe((state) => {
                    if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["TimeStampLoadedState"]) {
                        this.setTimeFilter(state.data, searchVal, depthVal, durVal);
                    }
                });
            }
            else {
                if (timeVal != undefined) {
                    timeVal = Number(timeVal) * 60 * 1000; //dropdown(nTime) value to ms
                    var testDuration = Number(this.id.endTime) - Number(this.id.startTime);
                    if (testDuration > timeVal) {
                        var applyST = Number(this.id.endTime) - timeVal;
                        strStartTime = applyST;
                        strEndTime = this.id.endTime;
                    }
                    else //calculate end time when test is less than input time
                     {
                        alert("Filters time is greater than test run total time");
                        strStartTime = Number(this.id.endTime) - Number(testDuration);
                        strEndTime = this.id.endTime;
                    }
                }
                else {
                    strStartTime = this.id.startTime;
                    strEndTime = this.id.endTime;
                }
                durVal = Number(durVal) * 1000; //Sec to Ms 
                //Rest call based on Filters input
                var queyrParam;
                if (this.commonService.enableQueryCaching == 1) {
                    queyrParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime
                        + "&searchKeyVal=" + searchVal + "&depth=" + depthVal + "&hsDuration=" + durVal + "&stSignature=" + this.signatureName + "&graphId=" + this.id.graphId;
                }
                else {
                    queyrParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime
                        + "&searchKeyVal=" + searchVal + "&depth=" + depthVal + "&hsDuration=" + durVal + "&stSignature=" + this.signatureName + "&graphId=" + this.id.graphId;
                }
                try {
                    return this.ndDdrHttpService.getNoGroupingData(queyrParam).subscribe((state) => {
                        if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["NoGroupingLoadedState"]) {
                            this.doAssignValueHotspot(state.data);
                        }
                    }, (error) => {
                        if (error.hasOwnProperty('message')) {
                            this.messageService.showError(error);
                        }
                        else {
                            if (error.hasOwnProperty('statusText')) {
                                this.messageService.showError(error);
                                console.error(error);
                            }
                        }
                    });
                }
                catch (error) {
                    console.error(error);
                }
            }
        }
    }
    setTimeFilter(res, searchVal, depthVal, durVal) {
        var strStartTime;
        var strEndTime;
        var queryParam;
        strStartTime = res.ddrStartTime;
        strEndTime = res.ddrEndTime;
        if (this.commonService.enableQueryCaching == 1) {
            queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime
                + "&searchKeyVal=" + searchVal + "&depth=" + depthVal + "&hsDuration=" + durVal + "&stSignature=" + this.signatureName + "&graphId=" + this.id.graphId;
        }
        else {
            queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + strStartTime + "&strEndTime=" + strEndTime
                + "&searchKeyVal=" + searchVal + "&depth=" + depthVal + "&hsDuration=" + durVal + "&stSignature=" + this.signatureName + "&graphId=" + this.id.graphId;
        }
        try {
            this.ndDdrHttpService.getNoGroupingData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["NoGroupingLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                if (error.hasOwnProperty('message')) {
                    this.messageService.showError(error);
                }
                else {
                    if (error.hasOwnProperty('statusText')) {
                        this.messageService.showError(error);
                        console.error(error);
                    }
                }
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    clickBack() {
        let dataArr = [];
        console.log('index arr is ', this.commonService.indexArr);
        this.index = this.commonService.indexArr.pop();
        console.log('index value in clickback', this.index);
        dataArr.push(this.index);
        this.signatureName = undefined;
        this.stSignature.emit(dataArr);
    }
    //Method to reset data table
    clickReset() {
        this.signaturePassHeader = undefined;
        this.compareDepth = 0;
        this.signaturePassHeader = "";
        this.selectedTimeRange = undefined;
        this.stackTrace = undefined;
        this.minDepth = undefined;
        this.minDuration = undefined;
        this.BackFlag = false;
        this.signatureName = undefined;
        let url = "";
        url = this.getHostUrl();
        let queryParam;
        if (this.commonService.enableQueryCaching == 1) {
            queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName="
                + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&graphId=" + this.id.graphId + "&depth=0";
        }
        else {
            queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName="
                + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&graphId=" + this.id.graphId + "&depth=0";
        }
        try {
            return this.ndDdrHttpService.getNoGroupingData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["NoGroupingLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                if (error.hasOwnProperty('message')) {
                    this.messageService.showError(error);
                }
                else {
                    if (error.hasOwnProperty('statusText')) {
                        this.messageService.showError(error);
                        console.error(error);
                    }
                }
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Method to open Flowpath report when click on thread duration(mm:ss) based on row selected data
    openFPReport(data) {
        let threadId = "NA";
        if (data.instanceType.toLowerCase() != 'dotnet' || data.instanceType.toLowerCase() != 'dotnetc')
            threadId = data.threadid;
        let reqData = {};
        if (data != undefined) {
            var flowpathEndTime = (Number(data.hsTimeInMs) + Number(data.hsDurationInMs)).toString();
            reqData["hsEndTime"] = (Number(data.hsTimeInMs) + Number(data.hsDurationInMs) + 900000).toString();
            reqData["tierId"] = data.tierid;
            reqData["serverId"] = data.serverid;
            reqData["appId"] = data.appid;
            reqData["tierName"] = this.id.tierName;
            reqData["serverName"] = this.id.serverName;
            reqData["appName"] = this.id.appName;
            reqData["threadId"] = threadId;
            reqData["hsTimeInMs"] = data.hsTimeInMs;
            reqData["flowpathEndTime"] = flowpathEndTime;
        }
        this.commonService.isFilterFromSideBar = false;
        this.commonService.hstofpData = reqData;
        this._ddrData.FromhsFlag = 'true';
        this._router.navigate(['/ddr/flowpath']);
    }
    //Method to get data when clcik on thread id -for thread stack trace
    passDataForStackTrace(data) {
        //dynamic creation for stack trace header info
        this.stackTraceFilter = `(Thread Id:${data.threadid}, Thread Name:${data.threadname}, HotSpot EntryTime(Absolute):${data.hotspotstarttimestamp}, Hotspot Duration:${data.hotspotduration} seconds )`;
        this.filterCriteriaagg = this.stackTraceFilter;
        if (this.commonService.enableQueryCaching == 1) {
            let second_queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierId=" + data.tierid + "&serverId=" + data.serverid + "&appId=" + data.appid + "&threadId=" + data.threadid + "&hsTimeInMs=" + data.hsTimeInMs + "&hotSpotDuration=" + data.hsDurationInMs + '&instanceType=' + data.instanceType + '&tierName=' + this.id.tierName;
            this.getHotspotSecData(second_queryParam); // Pass the URL to get Response from Rest service
            let IP_queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierId=" + data.tierid + "&serverId=" + data.serverid + "&appId=" + data.appid + "&startTime=" + data.hotspotstarttimestamp + "&hsDuration=" + data.hsDurationInMs + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&threadId=" + data.threadid + '&tierName=' + this.id.tierName;
            this.getbackendData(IP_queryParam);
        }
        else {
            let second_queryParam = "testRun=" + this.id.testRun + "&tierId=" + data.tierid + "&serverId=" + data.serverid + "&appId=" + data.appid + "&threadId=" + data.threadid + "&hsTimeInMs=" + data.hsTimeInMs + "&hotSpotDuration=" + data.hsDurationInMs + '&instanceType=' + data.instanceType + '&tierName=' + this.id.tierName;
            this.getHotspotSecData(second_queryParam); // Pass the URL to get Response from Rest service
            let IP_queryParam = "testRun=" + this.id.testRun + "&tierId=" + data.tierid + "&serverId=" + data.serverid + "&appId=" + data.appid + "&startTime=" + data.hotspotstarttimestamp + "&hsDuration=" + data.hsDurationInMs + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&threadId=" + data.threadid + '&tierName=' + this.id.tierName;
            this.getbackendData(IP_queryParam);
        }
    }
    //Rest call to get data as a response for thread info table   
    getHotspotData() {
        let pagination = "";
        pagination = "&hsLimit=" + this.hsLimit + "&hsOffset=" + this.hsOffset;
        if (this.signatureName != undefined) {
            this.BackFlag = true;
        }
        if (!this.compareDepth)
            this.compareDepth = 0;
        let queryParam;
        if (this.commonService.enableQueryCaching == 1) {
            queryParam = "cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&depth=" + this.compareDepth + "&compst=-" + "&stSignature=" + this.signatureName + "&graphId=" + this.id.graphId;
        }
        else {
            queryParam = "testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime + "&depth=" + this.compareDepth + "&compst=-" + "&stSignature=" + this.signatureName + "&graphId=" + this.id.graphId;
        }
        //   console.log("Threadcount to nogrouping URL = " + endpoint_url);
        queryParam += "&showCount=false" + pagination;
        try {
            return this.ndDdrHttpService.getNoGroupingData(queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["NoGroupingLoadedState"]) {
                    this.doAssignValueHotspot(state.data);
                }
            }, (error) => {
                if (error.hasOwnProperty('message')) {
                    this.messageService.showError(error);
                }
                else {
                    if (error.hasOwnProperty('statusText')) {
                        this.messageService.showError(error);
                        console.error(error);
                    }
                }
            });
        }
        catch (error) {
            console.log(error);
        }
    }
    getbackendData(IP_url) {
        try {
            return this.ndDdrHttpService.getBackendNameHotspot(IP_url).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["BackendNameHotspotLoadedState"]) {
                    this.doAssignValueBackendData(state.data);
                }
            }, (error) => {
                if (error.hasOwnProperty('message')) {
                    this.messageService.showError(error);
                }
                else {
                    if (error.hasOwnProperty('statusText')) {
                        this.messageService.showError(error);
                        console.error(error);
                    }
                }
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Rest call to get data for stacktrace table
    getHotspotSecData(second_queryParam) {
        //console.log("second url===="+second_url);
        try {
            return this.ndDdrHttpService.getStackTraceData(second_queryParam).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_8__["StackTraceDataLoadedState"]) {
                    this.doAssignValueSecHotspot(state.data);
                }
            }, (error) => {
                if (error.hasOwnProperty('message')) {
                    this.messageService.showError(error);
                }
                else {
                    if (error.hasOwnProperty('statusText')) {
                        this.messageService.showError(error);
                        console.error(error);
                    }
                }
            });
        }
        catch (error) {
            console.error(error);
        }
    }
    //Assign hotspot response value to the firstarray
    doAssignValueHotspot(res) {
        if (res.hasOwnProperty('Status')) {
            this.showError(res.Status);
        }
        this.hotspotData = res.data;
        this.id.stSignature = undefined;
        this.hstotalCount = res.TotalCount;
        if (!this.hstotalCount) {
            this.hstotalCount = 0;
        }
        if (res.startTime && res.startTime != "undefined")
            this.hotspotFilter = "(Total:" + this.hstotalCount + ", Start Time:" + res.startTime + ", End Time:" + res.endTime + ", Tier:" + this.id.tierName + ", Server:" + this.id.serverName + ", Instance:" + this.id.appName + ")";
        else
            this.hotspotFilter = "(Total:" + this.hstotalCount + ", Tier:" + this.id.tierName + ", Server:" + this.id.serverName + ", Instance:" + this.id.appName + ")";
        if (this.hstotalCount > 10) { //If data is less then 10 then no pagination .
            this.showPagination = true;
        }
        else {
            this.showPagination = false;
        }
        if (this.hotspotData.length == 0) //If no data found. blank stack trace table
         {
            this.hotSpotSecInfo = [];
            this.IPInfo = [];
            this.aggIpInfo = [];
            this.stackTraceFilter = "";
            this.showDownLoadReportIcon = false;
        }
        else
            this.showDownLoadReportIcon = true;
        this.hotSpotInfo = this.getHotspotInfo();
    }
    //Assign stacktrace response value to secondarray 
    doAssignValueSecHotspot(res) {
        this.hotspotSecData = res.treedata;
        this.hotSpotSecInfo = res.treedata;
        this.downloadJSON = res.downloadJSON;
    }
    doAssignValueBackendData(data) {
        this.renamebackendNameMap = data.renamebackendNameMap;
        this.actualBackendNameMap = data.actualBackendNameMap;
        this.backendSubTypeNameMap = data.backendSubTypeNameMap;
        let backendInfoList = data.backendInfoList;
        this.backendData = backendInfoList;
        if (data && data.aggDataForBackends && Object.keys(data.aggDataForBackends).length != 0) {
            console.log("aggregate case-------------");
            this.aggCase = true;
            this.aggIpInfo = data.aggDataForBackends;
        }
        else {
            console.log("previous  case-------------");
            this.aggCase = false;
            this.IPInfo = this.getIPinfo();
            if (this.IPInfo.length > 10) { //If data is less then 10 then no pagination .
                this.showPaginationIP = true;
            }
            else {
                this.showPaginationIP = false;
            }
        }
    }
    openIPHealthScreen(nodeData) {
        this.commonService.hotspotToIP = true;
        this._ddrData.splitViewFlag = false;
        this.commonService.hotspotToIPData = nodeData;
        if (this._router.url.indexOf('/home/ddrCopyLink') != -1) {
            this._router.navigate(['/home/ddrCopyLink/IpStatComponent']);
        }
        else if (this._router.url.indexOf('/home/ED-ddr') != -1) {
            this._router.navigate(['/home/ED-ddr/IpStatComponent']);
        }
        else {
            this._router.navigate(['/home/ddr/IpStatComponent']);
        }
    }
    //Store value for thread data
    getHotspotInfo() {
        var arrHotSpotData = [];
        for (var i = 0; i < this.hotspotData.length; i++) {
            if (i == 0) //for first time thread header information in table
             {
                this.passDataForStackTrace(this.hotspotData[i]);
                this.selectItem = this.hotspotData[i];
            }
            var hsDur = (this.hotspotData[i]["hotspotduration"]);
            arrHotSpotData[i] = { tierid: this.hotspotData[i]["tierid"], serverid: this.hotspotData[i]["serverid"], appid: this.hotspotData[i]["appid"], threadid: this.hotspotData[i]["threadid"], hotspotstarttimestamp: this.hotspotData[i]["hotspotstarttimestamp"], hotspotduration: hsDur, threadstate: this.hotspotData[i]["threadstate"], threadpriority: this.hotspotData[i]["threadpriority"], threadstackdepth: this.hotspotData[i]["threadstackdepth"], FlowPathInstance: this.hotspotData[i]["FlowPathInstance"], threadname: this.hotspotData[i]["threadname"], hsTimeInMs: this.hotspotData[i]["hsTimeInMs"], toolTipTextForHsDur: this.hotspotData[i]["toolTipTextForHsDur"], hsDurationInMs: this.hotspotData[i]["hsDurationInMs"], hotspotElapsedTime: this.hotspotData[i]["hotspotElapsedTime"], strStartTime: this.hotspotData[i]["strStartTime"], strEndTime: this.hotspotData[i]["strEndTime"], instanceType: this.hotspotData[i]["instanceType"] };
        }
        return arrHotSpotData;
    }
    getIPinfo() {
        var arrbackendData = [];
        for (var i = 0; i < this.backendData.length; i++) {
            arrbackendData[i] = {
                renamebackendIPname: this.renamebackendNameMap[this.backendData[i]["backendId"]],
                actualbackendIPname: this.actualBackendNameMap[this.backendData[i]["backendId"]].replace(/&#46;/g, '.'),
                backendType: this.BackendTypeName(this.backendData[i]["backendType"]),
                backendDuration: this.backendData[i]["backendDuration"],
                backendStartTime: this.backendData[i]["backendStartTime"],
                errorCount: this.HotspotStatus(this.backendData[i]["errorCount"]),
                Query: this.backendData[i]["backendSubType"] == 0 ? '-' : this.backendSubTypeNameMap[this.backendData[i]["backendSubType"]].replace(/&#044;/g, ',').replace(/&#010;/g, '\n'),
                starttimeInMs: this.backendData[i]["starttimeInMs"]
            };
        }
        return arrbackendData;
    }
    //Store value fot thread stack trace data
    getHotspotSecInfo() {
        var arrHotSpotSecData = [];
        for (var i = 0; i < this.hotspotSecData.length; i++) {
            arrHotSpotSecData[i] = { 0: this.hotspotSecData[i]["0"], 1: this.hotspotSecData[i]["1"], 2: this.hotspotSecData[i]["2"], 3: this.hotspotSecData[i]["3"], 4: this.hotspotSecData[i]["4"], 5: this.hotspotSecData[i]["5"], 6: this.hotspotSecData[i]["6"], 7: this.hotspotSecData[i]["7"] };
        }
        return arrHotSpotSecData;
    }
    updateSignature(displaySignature) {
        if (displaySignature == "") {
            alert("Display Name Could not be empty.Resetting to last updated display name.");
            return "";
        }
        else if (displaySignature == this.signatureName) {
            alert("Not updated, already updated Same name.");
            displaySignature = this.signatureName;
            return "";
        }
        let url;
        url = this.getHostUrl();
        let updateStSigantureUrl = decodeURIComponent(url + '/' + this.id.product.replace("/", "")) + "/v1/cavisson/netdiagnostics/ddr/InsertOrUpdateSignatue?testRun=" + this.id.testRun + "&compDepth=0" + "&stSignature=" + this.signatureName + "&displayName=" + displaySignature + "&extraDisplayName=" + this.signatureName;
        this.ddrRequest.getDataInStringUsingGet(updateStSigantureUrl).subscribe(data => {
            if (data.trim() != "")
                alert(data);
        });
        return "";
    }
    //This function is used to set backendtype according to the type
    BackendTypeName(backendType) {
        var backendTypeName = "OTHER";
        if (backendType == 1)
            return "HTTP";
        else if (backendType == 2)
            return "JDBC";
        else if (backendType == 3)
            return "COHERENCE";
        else if (backendType == 4)
            return "RMI";
        else if (backendType == 5)
            return "MemCache";
        else if (backendType == 6)
            return "CLOUDANT";
        else if (backendType == 7)
            return "HADOOP";
        else if (backendType == 9)
            return "CASSANDRA";
        else if (backendType == 10)
            return "DB";
        else if (backendType == 14)
            return "JMSP";
        else if (backendType == 15)
            return "DATABASE";
        else if (backendType == 16)
            return "DATABASE";
        return backendTypeName;
    }
    // This Function is used to set value in Status
    HotspotStatus(errorCount) {
        if (errorCount == false)
            return 'Pass';
        else
            return 'Fail';
    }
    Querypop(nodeInfo) {
        var arr = [];
        this.displayPopUp = true;
        arr.push({ "IPname": nodeInfo.renamebackendIPname, "DiscoveredIPName": nodeInfo.actualbackendIPname, "Type": nodeInfo.backendType, "StartTime": nodeInfo.backendStartTime, "Duration": nodeInfo.backendDuration, "Status": nodeInfo.errorCount, "Query": nodeInfo.Query });
        this.rowData = arr;
    }
    showError(msg) {
        this.errMsg = [];
        this.errMsg.push({ severity: 'error', summary: 'Error Message', detail: msg });
    }
    clickButtonEvent(event) {
        var _a, _b, _c, _d, _e, _f, _g, _h;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable" && ((_d = (_c = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _c === void 0 ? void 0 : _c.columnClicked) === null || _d === void 0 ? void 0 : _d.key) === "threadid") {
            me.passDataForStackTrace(event.cavEventExt.row);
        }
        else if (((_f = (_e = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _e === void 0 ? void 0 : _e.actionConfig) === null || _f === void 0 ? void 0 : _f.action) === "clickable" && ((_h = (_g = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _g === void 0 ? void 0 : _g.columnClicked) === null || _h === void 0 ? void 0 : _h.key) === "hotspotduration") {
            me.openFPReport(event.cavEventExt.row);
        }
    }
};
NogroupingComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_4__["CommonServices"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_9__["CavMessageService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_3__["Router"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_1__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_5__["DDRRequestService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_6__["SessionService"] },
    { type: src_app_pages_ddr_services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_7__["NdDdrHttpService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], NogroupingComponent.prototype, "signatureName", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], NogroupingComponent.prototype, "displayName", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Output"])()
], NogroupingComponent.prototype, "stSignature", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Input"])()
], NogroupingComponent.prototype, "compareDepth", void 0);
NogroupingComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_2__["Component"])({
        selector: 'app-nogrouping',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./nogrouping.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./nogrouping.component.css */ "./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.css")).default]
    })
], NogroupingComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.css":
/*!**********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.css ***!
  \**********************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("");

/***/ }),

/***/ "./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.ts":
/*!*********************************************************************************!*\
  !*** ./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.ts ***!
  \*********************************************************************************/
/*! exports provided: ThreadHotspotComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ThreadHotspotComponent", function() { return ThreadHotspotComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");




let ThreadHotspotComponent = class ThreadHotspotComponent {
    constructor(commonService, breadcrumb) {
        this.commonService = commonService;
        this.display = false;
        this.index = 0;
        this.breadcrumb = breadcrumb;
    }
    ngOnInit() {
        this.commonService.isToLoadSideBar = false;
        this.screenHeight = Number(this.commonService.screenHeight) - 80;
        this.id = this.commonService.getData();
        this.reportHeader = 'Thread Hotspot Report- ' + this.id.testRun;
        this.breadcrumb.add({ label: 'Thread Hotspots', routerLink: '/ddr/threadhotspot' });
    }
    saveSignatureData(data) {
        if (data.length >= 3) {
            this.displayName = data[0];
            this.signatureName = data[1];
            this.index = data[2];
            if (data.length > 3)
                this.depth = data[3];
            console.log("Data in parent module=--->", data);
        }
        else if (data.length == 1) {
            this.index = data[0];
            console.log('index value in back case', this.index);
        }
    }
    getValue() {
        if (isNaN(this.topFrame) || this.topFrame.trim() == "" || Number(this.topFrame) < 0)
            alert("Please enter valid input.");
        else
            this.display = false;
    }
    handleChange(event) {
        this.index = event.index;
        // this.indexArr.push(this.index);
        console.log('index is', this.index);
        if (Number(this.index) == 2)
            this.display = true;
        this.signatureName = undefined;
    }
    back() {
        this.index = this.commonService.indexArr.pop();
        this.display = false;
    }
};
ThreadHotspotComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__["BreadcrumbService"] }
];
ThreadHotspotComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-thread-hotspot',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./thread-hotspot.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./thread-hotspot.component.css */ "./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.css")).default]
    })
], ThreadHotspotComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.scss":
/*!***************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.scss ***!
  \***************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("::ng-deep .d3-flame-graph-tip {\n  max-width: 300px !important;\n  word-wrap: break-word !important;\n  z-index: 9999;\n}\n\n.page {\n  width: 100%;\n}\n\n.chart-wrap {\n  width: 100%;\n  min-height: calc(100vh - 140px);\n  padding: 32px 24px;\n  box-sizing: border-box;\n  display: flex;\n  align-items: center;\n  justify-content: flex-start;\n}\n\n#chart {\n  width: 100%;\n  height: 100%;\n}\n\n.chart-wrap.inverted {\n  align-items: flex-start !important;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.ts":
/*!*************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.ts ***!
  \*************************************************************************************/
/*! exports provided: TraceFlamegraphComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TraceFlamegraphComponent", function() { return TraceFlamegraphComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var d3_flame_graph__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! d3-flame-graph */ "./node_modules/d3-flame-graph/dist/d3-flamegraph.es.js");
/* harmony import */ var d3_selection__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! d3-selection */ "./node_modules/d3-selection/src/index.js");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/pages/tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");







let TraceFlamegraphComponent = class TraceFlamegraphComponent {
    constructor(ddrData, sessionService, messageService) {
        this.ddrData = ddrData;
        this.sessionService = sessionService;
        this.messageService = messageService;
        this.cellHeight = 24;
        this.viewInitialized = false;
        this.completeSpanMap = {}; // map to stores complete span details
        this.searchTerm = '';
        this.isInverted = false;
    }
    ngOnInit() {
        // Start the async trace fetch immediately; actual render waits for the chart container.
        this.loadTraceData();
    }
    ngOnChanges(changes) {
        if (changes.columnData && !changes.columnData.firstChange) {
            this.loadTraceData();
        }
    }
    ngAfterViewInit() {
        setTimeout(() => {
            const tip = document.querySelector('.d3-flame-graph-tip');
            if (tip) {
                tip.style.transform = 'none';
                tip.style.left = '0px'; // optional reset
            }
        }, 0);
        this.resizeObserver = new window.ResizeObserver(() => {
            clearTimeout(this.resizeTimeout);
            this.resizeTimeout = setTimeout(() => {
                this.tryRenderChart();
            }, 150);
        });
        this.viewInitialized = true;
        this.resizeObserver.observe(this.chartRef.nativeElement);
        // Create the D3 flamegraph only after the host element is available.
        this.viewInitialized = true;
        this.resizeObserver.observe(this.chartRef.nativeElement);
        const tip = d3_flame_graph__WEBPACK_IMPORTED_MODULE_2__["tooltip"]
            .defaultFlamegraphTooltip()
            .html((d) => {
            var _a, _b, _c, _d;
            return `
        <div style="padding:5px; max-width: 300px; white-space: normal; word-wrap:break-word;">
          <b>${((_a = d.data) === null || _a === void 0 ? void 0 : _a.name) || d.name}</b><br/>
          Kind: ${((_b = d.data) === null || _b === void 0 ? void 0 : _b.kind) || 'Internal'}<br/>
          Duration: ${((((_c = d.data) === null || _c === void 0 ? void 0 : _c.rawDuration) || ((_d = d.data) === null || _d === void 0 ? void 0 : _d.value) || d.value) / 1e6).toFixed(2)} ms
        </div>
      `;
        });
        this.chart = Object(d3_flame_graph__WEBPACK_IMPORTED_MODULE_2__["default"])()
            .width(this.chartRef.nativeElement.clientWidth)
            .cellHeight(this.cellHeight)
            .minFrameSize(0.1)
            .transitionDuration(750)
            .selfValue(false)
            .setLabelHandler((d) => {
            var _a, _b, _c;
            const name = ((_a = d.data) === null || _a === void 0 ? void 0 : _a.name) || d.name || 'unknown';
            const raw = ((_b = d.data) === null || _b === void 0 ? void 0 : _b.rawDuration) || ((_c = d.data) === null || _c === void 0 ? void 0 : _c.value) || d.value || 0;
            return `${name} (${(raw / 1e6).toFixed(2)} ms)`;
        })
            .tooltip(tip);
        this.initSearchHandlers();
        this.tryRenderChart();
    }
    ngOnDestroy() {
        document.querySelectorAll('.d3-flame-graph-tip').forEach(el => el.remove());
    }
    applyCurrentSearch() {
        if (!this.chart)
            return;
        const term = (this.searchTerm || '').trim();
        this.chart.search(term);
    }
    toggleInvert() {
        if (!this.chart)
            return;
        this.isInverted = !this.isInverted;
        this.chart.inverted(this.isInverted);
        Object(d3_selection__WEBPACK_IMPORTED_MODULE_3__["select"])(this.chartRef.nativeElement).selectAll('*').remove();
        this.renderChart();
    }
    onReset() {
        if (!this.chart)
            return;
        this.searchTerm = '';
        this.chart.search('');
        this.renderChart();
        this.chart.resetZoom();
    }
    onSearch() {
        if (!this.chart)
            return;
        const term = (this.searchTerm || '').trim();
        if (!term) {
            this.messageService.showWarning("Search field is empty");
            return;
        }
        this.chart.search(term);
    }
    initSearchHandlers() {
        if (!this.chart)
            return;
        this.chart.setSearchMatch((d, term) => {
            var _a;
            if (!term)
                return false;
            const label = (((_a = d === null || d === void 0 ? void 0 : d.data) === null || _a === void 0 ? void 0 : _a.name) || (d === null || d === void 0 ? void 0 : d.name) || '').toString();
            return label.toLowerCase().includes(term.toLowerCase());
        });
    }
    buildTree() {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            this.traceDetails = yield this.ddrData.getTraceDataById(this.columnData);
            console.log('Trace Details ', this.traceDetails);
            let spans = this.traceDetails || [];
            const spanMap = {};
            const roots = [];
            this.completeSpanMap = {};
            // First pass → create all nodes
            spans.forEach(span => {
                var _a, _b;
                spanMap[span.span_id] = {
                    data: {
                        name: span.name,
                        startTime: this.sessionService.convertTimeToSelectedTimeZone(Number(span["@timestamp"])),
                        threadId: span.attributes["thread.id"],
                        threadName: span.attributes["thread.name"],
                        kind: span.kind,
                        duration: span.duration,
                        traceId: span.trace_id,
                        spanId: span.span_id,
                        parentSpanId: span.parent_span_id || null,
                        service: ((_b = (_a = span.resource) === null || _a === void 0 ? void 0 : _a.attributes) === null || _b === void 0 ? void 0 : _b['service.name']) || ''
                    },
                    children: []
                };
                this.completeSpanMap[span.span_id] = span;
            });
            console.log("Span Map :", spanMap);
            // Second pass → assign children to parents
            spans.forEach(span => {
                var _a;
                const node = spanMap[span.span_id];
                if (span.parent_span_id && spanMap[span.parent_span_id]) {
                    (_a = spanMap[span.parent_span_id].children) === null || _a === void 0 ? void 0 : _a.push(node);
                }
                else {
                    roots.push(node);
                }
            });
            return roots;
        });
    }
    onMouseMove(event) {
        const tips = document.querySelectorAll('.d3-flame-graph-tip');
        tips.forEach((tip) => {
            if (tip.style.opacity === '0')
                return;
            const tooltipWidth = tip.offsetWidth;
            if (event.clientX > window.innerWidth - tooltipWidth - 20) {
                tip.style.left = event.clientX - tooltipWidth - 10 + 'px';
            }
            else {
                tip.style.left = event.clientX + 10 + 'px';
            }
        });
    }
    loadTraceData() {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            try {
                const treeData = yield this.buildTree();
                this.nodes = treeData;
                console.log('Tree Nodes', this.nodes);
                const data = yield this.buildFlameData(this.nodes);
                // Flamegraph expects one root node, so wrap multiple roots under a synthetic parent.
                this.finalData = data.length === 1
                    ? data[0]
                    : { name: 'Trace', value: data.reduce((sum, node) => sum + (node.value || 0), 0), children: data };
                this.tryRenderChart();
            }
            catch (error) {
                console.error('Error building trace flamegraph:', error);
                this.finalData = null;
            }
        });
    }
    tryRenderChart() {
        // Data fetch and view init are independent, so render only when both are ready.
        if (!this.viewInitialized || !this.chart || !this.finalData) {
            return;
        }
        this.renderChart();
    }
    renderChart() {
        if (!this.finalData) {
            return;
        }
        document.querySelectorAll('.d3-flame-graph-tip').forEach(el => el.remove());
        Object(d3_selection__WEBPACK_IMPORTED_MODULE_3__["select"])(this.chartRef.nativeElement).selectAll('*').remove();
        const depth = this.getTreeDepth(this.finalData);
        const contentHeight = Math.max(220, depth * this.cellHeight + 10);
        this.chart
            .width(this.chartRef.nativeElement.clientWidth)
            .height(contentHeight);
        Object(d3_selection__WEBPACK_IMPORTED_MODULE_3__["select"])(this.chartRef.nativeElement)
            .datum(this.finalData)
            .call(this.chart);
        this.applyCurrentSearch();
    }
    getTreeDepth(node) {
        var _a;
        if (!((_a = node === null || node === void 0 ? void 0 : node.children) === null || _a === void 0 ? void 0 : _a.length)) {
            return 1;
        }
        return 1 + Math.max(...node.children.map((child) => this.getTreeDepth(child)));
    }
    // ✅ Convert tree → flame graph format
    buildFlameData(nodes) {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            const convert = (node) => {
                var _a;
                const children = ((_a = node.children) === null || _a === void 0 ? void 0 : _a.map(convert)) || [];
                const childrenTotal = children.reduce((sum, child) => sum + (child.value || 0), 0);
                // Keep parent frames visible even when child duration sum is larger than self duration.
                const value = Math.max(node.data.duration || 0, childrenTotal);
                const obj = {
                    name: node.data.name || 'unknown',
                    value,
                    rawDuration: node.data.duration || 0,
                    kind: node.data.kind || 'Internal'
                };
                if (children.length) {
                    obj.children = children;
                }
                return obj;
            };
            return nodes.map(convert);
        });
    }
};
TraceFlamegraphComponent.ctorParameters = () => [
    { type: src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__["DdrDataModelService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_4__["SessionService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_6__["CavMessageService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], TraceFlamegraphComponent.prototype, "columnData", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('chartRef', { static: true })
], TraceFlamegraphComponent.prototype, "chartRef", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["HostListener"])('document:mousemove', ['$event'])
], TraceFlamegraphComponent.prototype, "onMouseMove", null);
TraceFlamegraphComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-trace-flamegraph',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./trace-flamegraph.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./trace-flamegraph.component.scss */ "./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.scss")).default]
    })
], TraceFlamegraphComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.scss":
/*!*************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.scss ***!
  \*************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (".hover .showHover {\n  display: inline-block;\n  margin-left: 4px;\n  opacity: 0;\n  visibility: hidden;\n}\n.hover:hover .showHover {\n  opacity: 1;\n  visibility: visible;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.ts":
/*!***********************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.ts ***!
  \***********************************************************************************************/
/*! exports provided: TraceTimelineViewerComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TraceTimelineViewerComponent", function() { return TraceTimelineViewerComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var src_app_shared_cav_nav_bar_cav_nav_bar_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! src/app/shared/cav-nav-bar/cav-nav-bar.service */ "./src/app/shared/cav-nav-bar/cav-nav-bar.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var highcharts_modules_gantt__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! highcharts/modules/gantt */ "./node_modules/highcharts/modules/gantt.js");
/* harmony import */ var highcharts_modules_gantt__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(highcharts_modules_gantt__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/http.js");
/* harmony import */ var highcharts_angular__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! highcharts-angular */ "./node_modules/highcharts-angular/__ivy_ngcc__/fesm2015/highcharts-angular.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");













highcharts_modules_gantt__WEBPACK_IMPORTED_MODULE_5___default()(highcharts__WEBPACK_IMPORTED_MODULE_4__);
let TraceTimelineViewerComponent = class TraceTimelineViewerComponent {
    constructor(breadcrumbService, cavNavBarService, zone, http, commonService, sessionService, elasticSearchService, messageService, ddrData) {
        this.breadcrumbService = breadcrumbService;
        this.cavNavBarService = cavNavBarService;
        this.zone = zone;
        this.http = http;
        this.commonService = commonService;
        this.sessionService = sessionService;
        this.elasticSearchService = elasticSearchService;
        this.messageService = messageService;
        this.ddrData = ddrData;
        this.Highcharts = highcharts__WEBPACK_IMPORTED_MODULE_4__;
        this.graphData = [];
        this.dataUrl = 'assets/dummyData/graphData3.json';
        this.shouldResizeChart = false;
        this.subscriptions = [];
        this.elasticTraceDetails = [];
        this.finalSortedTraceDetails = [];
        this.chartCallback = (chart) => {
            this.chartRef = chart;
        };
    }
    ngOnInit() {
        this.loader = true;
        if (this.elasticSearchService.isFromOtelTrxnServiceMap) {
            this.elasticSearchService.isFromOtelTrxnServiceMap = false;
            if (window['logLevel'] > 1) {
                console.log("Payload from trxn service map : ", this.elasticSearchService.getTrxServiceMapPayload());
            }
            this.ddrData.getTraceDataById(this.elasticSearchService.getTrxServiceMapPayload()).then(traceData => {
                this.finalSortedTraceDetails = traceData;
                this.loadData();
            }).catch(error => {
                console.error('Error fetching trace data from transaction serive map:', error);
                this.loader = false;
            });
        }
        else {
            this.ddrData.getTraceDataById(this.columnData).then(traceData => {
                this.finalSortedTraceDetails = traceData;
                this.loadData();
            }).catch(error => {
                console.error('Error fetching trace data:', error);
                this.loader = false;
            });
        }
    }
    ngOnChanges(changes) {
        this.loader = true;
        this.closeSelectedTask();
        if (changes.columnData && changes.columnData.currentValue) {
            this.ddrData.getTraceDataById(changes.columnData.currentValue).then(traceData => {
                this.finalSortedTraceDetails = traceData;
                this.loadData();
            }).catch(error => {
                console.error('Error fetching trace data:', error);
                this.loader = false;
            });
        }
    }
    loadData() {
        this.graphData = this.finalSortedTraceDetails;
        const ganttData = this.graphData
            .map(item => ({
            name: item.name,
            start: Number(item['@timestamp']),
            end: Number(item['@timestamp']) + Number(item.duration / 1000000)
        }));
        this.selectedTopRowData = this.graphData[0];
        const rowHeight = 30;
        const newHeight = this.graphData.length * rowHeight;
        this.chartOptions = {
            exporting: { enabled: false },
            title: { text: '' },
            chart: {
                height: Math.max(newHeight + 70),
            },
            time: {
                timezone: sessionStorage.getItem('_nvtimezone'),
            },
            xAxis: {
                min: Math.min(...ganttData.map(d => d.start)),
                max: Math.max(...ganttData.map(d => d.end)),
                visible: false
            },
            yAxis: { staticScale: 26 },
            credits: { enabled: false },
            plotOptions: {
                series: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    states: {
                        hover: {
                            enabled: true,
                            halo: {
                                size: 0
                            },
                            borderColor: '#ff4757',
                            borderWidth: 2
                        },
                        select: {
                            borderColor: '#ff4757',
                            borderWidth: 4
                        }
                    },
                    point: {
                        events: {
                            click: (event) => {
                                var _a;
                                // Use the point's index to directly access the span data
                                const index = event.point.index;
                                const selected = this.graphData[index];
                                if (selected) {
                                    this.selectedRowData = selected;
                                    this.selectedTask = true;
                                    this.spanAttributes = selected.attributes;
                                    this.resourceAttributes = (_a = selected.resource) === null || _a === void 0 ? void 0 : _a.attributes;
                                    this.scope = selected.scope;
                                }
                                this.updateChartSize();
                            }
                        }
                    }
                },
                gantt: {
                    pointPadding: 3,
                    pointWidth: 10,
                    borderRadius: 0
                }
            },
            series: [{
                    type: 'gantt',
                    name: 'Trace Graph',
                    data: ganttData,
                    pointHeight: 10,
                    allowPointSelect: true,
                    minPointLength: 10 // Ensure minimum clickable width
                }]
        };
        this.loader = false;
    }
    trackByKey(index, item) {
        return item.key;
    }
    updateChartSize() {
        this.zone.onStable.pipe().subscribe(() => {
            if (this.chartRef) {
                this.chartRef.reflow();
            }
        });
    }
    ngAfterViewChecked() {
        if (this.shouldResizeChart && this.chartRef) {
            setTimeout(() => {
                this.chartRef.reflow();
                this.shouldResizeChart = false;
            }, 0); // Allow DOM to update before calling reflow
        }
    }
    closeSelectedTask() {
        if (this.chartRef) {
            const selectedPoints = this.chartRef.getSelectedPoints();
            if (selectedPoints.length > 0) {
                selectedPoints.forEach((point) => {
                    point.select(false);
                });
            }
        }
        this.selectedTask = false;
        this.updateChartSize();
    }
    downloadTraceDetails() {
        const traceId = this.selectedTopRowData.trace_id;
        const fileName = `trace_details_${traceId}.json`;
        const dataStr = JSON.stringify(this.finalSortedTraceDetails, null, 2);
        const blob = new Blob([dataStr], { type: 'application/json' });
        const url = window.URL.createObjectURL(blob);
        const a = document.createElement('a');
        a.href = url;
        a.download = fileName;
        document.body.appendChild(a);
        a.click();
        document.body.removeChild(a);
        window.URL.revokeObjectURL(url);
    }
    isObjectOrArray(value) {
        return value && (typeof value === 'object');
    }
    formatDuration(duration) {
        duration = duration / 1000000;
        if (duration < 1000) {
            return `${(duration).toFixed(3)}ms`;
        }
        else {
            return `${(duration / 1000).toFixed(3)}s`;
        }
    }
    flattenObject(obj, parentKey = '') {
        const result = [];
        const recurse = (subObj, parent) => {
            for (const key in subObj) {
                if (!subObj.hasOwnProperty(key))
                    continue;
                const fullKey = parent ? `${parent}.${key}` : key;
                const value = subObj[key];
                if (typeof value === 'object' && value !== null && !Array.isArray(value)) {
                    recurse(value, fullKey);
                }
                else {
                    result.push({ key: fullKey, value });
                }
            }
        };
        recurse(obj, parentKey);
        return result;
    }
    copyToClipboard(value) {
        const textArea = document.createElement('textarea');
        textArea.value = value;
        textArea.style.position = 'fixed'; // Prevent scrolling to bottom of page in MS Edge
        document.body.appendChild(textArea);
        textArea.focus();
        textArea.select();
        try {
            document.execCommand('copy');
            this.messageService.showSuccess("Attribute's value copied to clipboard");
        }
        catch (err) {
            this.messageService.showError('Copy Failed:', err);
        }
        document.body.removeChild(textArea);
    }
    ngOnDestroy() {
        this.subscriptions.forEach(subscription => subscription.unsubscribe());
    }
};
TraceTimelineViewerComponent.ctorParameters = () => [
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__["BreadcrumbService"] },
    { type: src_app_shared_cav_nav_bar_cav_nav_bar_service__WEBPACK_IMPORTED_MODULE_2__["CavNavBarService"] },
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"] },
    { type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__["HttpClient"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_8__["CommonServices"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_9__["SessionService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_10__["ElasticsearchQueryService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_11__["CavMessageService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_12__["DdrDataModelService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])(highcharts_angular__WEBPACK_IMPORTED_MODULE_7__["HighchartsChartComponent"])
], TraceTimelineViewerComponent.prototype, "chartComponent", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], TraceTimelineViewerComponent.prototype, "columnData", void 0);
TraceTimelineViewerComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-trace-timeline-viewer',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./trace-timeline-viewer.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./trace-timeline-viewer.component.scss */ "./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.scss")).default]
    })
], TraceTimelineViewerComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.scss":
/*!*****************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.scss ***!
  \*****************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = (":host {\n  display: flex;\n  flex-direction: column;\n  width: 100%;\n  height: 100vh;\n  overflow: hidden;\n}\n\n.surfWrap {\n  flex: 1;\n  width: 100%;\n  height: 100%;\n  overflow: visible;\n  position: relative;\n}\n\njsplumb-surface {\n  display: block;\n  width: 100%;\n  height: 100%;\n  border: 1px solid #ccc;\n  background-color: #f5f5f5;\n}\n\njsplumb-surface ::ng-deep .jtk-surface {\n  width: 100%;\n  height: 100%;\n  min-width: 100%;\n  min-height: 100%;\n}\n\njsplumb-surface ::ng-deep .jtk-surface-canvas {\n  width: 100%;\n  height: 100%;\n  min-width: 100%;\n  min-height: 100%;\n}\n\njsplumb-surface ::ng-deep .jtk-draggable {\n  width: 100%;\n  height: 100%;\n}\n\njsplumb-surface ::ng-deep .jtk-node {\n  position: absolute;\n  display: inline-block;\n}\n\njsplumb-surface ::ng-deep .node-container.jtk-node-selected {\n  stroke: #ff6b35;\n  stroke-width: 3px;\n}\n\njsplumb-surface ::ng-deep .edge-label {\n  font-size: 12px;\n  background: var(--background_color_1);\n  border: 1px solid #ccc;\n  border-radius: 4px;\n  padding: 4px 6px;\n}\n\njsplumb-surface .edge-label {\n  display: flex;\n  align-items: center;\n  justify-content: space-between;\n  border: 2px solid var(--border_bottom_color_2);\n  padding: 5px 11px 1px 10px;\n  width: -moz-max-content;\n  width: max-content;\n  min-height: 17px;\n  border-radius: 20px;\n  font-size: 11px;\n}\n\njsplumb-surface .edge-label .edge-index {\n  border: none;\n  border-radius: 50%;\n  display: flex;\n  height: 19px;\n  width: 19px;\n  align-items: center;\n  position: absolute;\n  left: 0;\n  top: 0;\n  justify-content: center;\n  background-color: var(--background_color_7);\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.ts":
/*!***************************************************************************************************!*\
  !*** ./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.ts ***!
  \***************************************************************************************************/
/*! exports provided: TransactionServiceMapComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TransactionServiceMapComponent", function() { return TransactionServiceMapComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _jsplumbtoolkit_browser_ui_angular__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @jsplumbtoolkit/browser-ui-angular */ "./node_modules/@jsplumbtoolkit/browser-ui-angular/__ivy_ngcc__/fesm2015/jsplumbtoolkit-browser-ui-angular.js");
/* harmony import */ var _jsplumbtoolkit_layout_hierarchy__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @jsplumbtoolkit/layout-hierarchy */ "./node_modules/@jsplumbtoolkit/layout-hierarchy/js/jsplumbtoolkit.layout-hierarchy.es.js");
/* harmony import */ var src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/pages/tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/shared/cav-toast/service/cav-message.service */ "./src/app/shared/cav-toast/service/cav-message.service.ts");
/* harmony import */ var _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/elasticsearch-query.service */ "./src/app/pages/ddr/services/elasticsearch-query.service.ts");
/* harmony import */ var _otel_output_node_indices_otel_output_node_indices_component__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../otel-output-node-indices/otel-output-node-indices.component */ "./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");









let TransactionServiceMapComponent = class TransactionServiceMapComponent {
    constructor($jsplumb, ddrData, elasticsearchQueryService, messageService) {
        this.$jsplumb = $jsplumb;
        this.ddrData = ddrData;
        this.elasticsearchQueryService = elasticsearchQueryService;
        this.messageService = messageService;
        this.transactionServiceData = [];
        this.surfaceId = 'flowchartSurface';
        this.toolkitId = 'flowchart';
        //stores the nodes while processing
        this.nodeList = [];
        //stores the final nodes and edges respectively
        this.nodes = [];
        this.edges = [];
        this.serverList = [];
        //stores the index of each span
        this.spanMap = new Map();
        this.parentMap = new Map();
        this.discardSpanSet = new Set();
        this.nodeSet = new Set();
        // Maps every raw span to its merged node id so edge lookup still works after grouping.
        this.renderedNodeIdBySpanId = new Map();
        // Caches computed node depth because same span may be revisited while grouping servers.
        this.nodeDepthBySpanId = new Map();
        //Backend Maps: stores nodes based on their callouts
        // Server nodes are merged only when the same server repeats at the same rendered depth.
        this.serverGroupMap = new Map();
        this.dbBackendMap = new Map();
        this.httpBackendMap = new Map();
        this.messageBackendMap = new Map();
        this.otherBackendMap = new Map();
        // Data loading state
        this.dataLoaded = false;
        this.surfaceReady = false;
        this.loader = true;
        this.filterCriteriaArray = [];
        //stores the callout data from elastic search
        this.serverNodeData = [];
        this.clientNodeData = [];
        this.nodeDetails = false;
        //hovered node data
        this.selectedNode = null;
        this.hoveredNodeData = null;
        this.showPopup = false;
        this.view = {
            nodes: {
                default: {
                    component: _otel_output_node_indices_otel_output_node_indices_component__WEBPACK_IMPORTED_MODULE_7__["OtelOutputNodeIndicesComponent"],
                    events: {
                        tap: (params) => {
                            if (window['logLevel'] > 1) {
                                console.log("Inside node tapped", params.obj.data.id);
                            }
                            this.showNodeDetailsPanel(params.obj.data.id);
                        },
                        dblclick: (params) => {
                            console.log("Node double-clicked:", params.obj.data.id, params.obj.data);
                            this.dblClick(params);
                        },
                        mouseover: (params) => {
                            this.openOutputNodeOverlay(params);
                        },
                        mouseout: (params) => {
                            this.clearHoverData();
                        },
                    }
                }
            },
            edges: {
                default: {
                    connector: 'Bezier',
                    anchors: ['Right', 'Left'],
                    overlays: [
                        {
                            type: 'Arrow',
                            options: {
                                location: 1,
                                width: 8,
                                length: 8
                            }
                        },
                        {
                            type: 'Label',
                            options: {
                                label: '{{label}}',
                                cssClass: "edge-label",
                                location: 0.5 // middle of edge
                            }
                        }
                    ],
                    endpoint: 'Blank',
                }
            }
        };
        this.renderParams = {
            layout: {
                type: _jsplumbtoolkit_layout_hierarchy__WEBPACK_IMPORTED_MODULE_3__["HierarchyLayout"].type,
                options: {
                    axis: "vertical",
                    padding: { x: 50, y: 110 },
                },
            },
        };
        this.agentTypeMap = {
            java: "java-logo.svg",
            nodejs: "icons8-node-js-100.png",
            dotnet: "icons8-dotnet-100.png",
            php: "icons8-php-logo-100.png",
            go: "icons8-go-100.png",
            python: "icons8-python-100.png"
        };
        this.backendTypeMap = {
            mssql: "db.svg",
            mysql: "db.svg",
            oracle: "db.svg",
            db2: "db.svg",
            postgresql: "db.svg",
            mongodb: "icons8-mongodb-100.png",
            cassandra: "icons8-cassandra-100.png",
            redis: "icons8-redis-100.png",
            cloudant: "db.svg",
            ftp: "icons8-ftp-100.png",
            kafka: "icons8-kafka-100.png",
            ldap: "icons8-ldap-100.png",
            dynamo: "icons8-dynamo-100.png",
            socket: "icons8-socket-100.png"
        };
    }
    ngOnInit() {
        // Step 1: Initialize toolkit first (synchronous)
        this.initializeToolkit();
        // Step 2: Load data asynchronously
        this.loadData();
    }
    ngOnChanges(changes) {
        if (changes.columnData && changes.columnData.currentValue && this.surfaceReady) {
            this.loader = true;
            if (window['logLevel'] > 1) {
                console.log("Column data changed:", changes.columnData.currentValue);
            }
            this.clearStructures();
            this.dataLoaded = false;
            this.toolkit.clear();
            this.loadData();
        }
    }
    ngAfterViewInit() {
        // Step 3: Initialize surface after view is ready
        this.initializeSurface();
    }
    ngOnDestroy() {
        var _a, _b;
        try {
            if (this.surface) {
                if (this.surface.getContainer && this.surface.getContainer()) {
                    (_a = this.surface) === null || _a === void 0 ? void 0 : _a.destroy();
                }
            }
            if (this.toolkit) {
                this.toolkit.clear();
            }
            (_b = this.subscription) === null || _b === void 0 ? void 0 : _b.unsubscribe();
            this.clearStructures();
        }
        catch (err) {
            console.warn('Surface cleanup skipped:', err);
        }
    }
    /**
   * Initialize the jsPlumb toolkit instance
   */
    initializeToolkit() {
        try {
            this.toolkit = this.$jsplumb.getToolkit(this.toolkitId, {
            // Add any toolkit options here
            });
            if (window['logLevel'] > 1) {
                console.log('Toolkit initialized:', this.toolkit);
            }
        }
        catch (error) {
            console.error('Error initializing toolkit:', error);
        }
    }
    loadData() {
        return Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__awaiter"])(this, void 0, void 0, function* () {
            try {
                const data = yield this.ddrData.getTraceDataById(this.columnData);
                this.transactionServiceData = data;
                if (window['logLevel'] > 1) {
                    console.log("Trace Details Data", this.transactionServiceData);
                }
                // Process the data
                this.indexSpans();
                this.populateTypeMaps();
                this.dataLoaded = true;
                // Try to render if surface is also ready
                this.attemptToRender();
            }
            catch (err) {
                console.error('Failed to load Trace Details Data', err);
                this.transactionServiceData = [];
            }
        });
    }
    /**
   * Initialize the jsPlumb surface for rendering
   */
    initializeSurface() {
        // Use timeout to ensure DOM is fully rendered
        setTimeout(() => {
            this.$jsplumb.getSurface(this.surfaceId, (surface) => {
                this.surface = surface;
                this.surfaceReady = true;
                if (window['logLevel'] > 1) {
                    console.log('Surface initialized:', surface);
                }
                // Try to render if data is also ready
                this.attemptToRender();
            });
        }, 0);
    }
    attemptToRender() {
        if (this.dataLoaded && this.surfaceReady && this.toolkit && this.surface) {
            this.renderData();
        }
    }
    renderData() {
        if (this.nodeList.length > 0) {
            let nodes = this.nodeList.map((span) => ({
                id: span.span_id,
                label: span.name || span.span_id,
                data: span,
            }));
            //add root node
            nodes.unshift({ id: "root", label: "Start", data: {} });
            this.nodes = nodes;
            console.log("Final Nodes:", this.nodes);
            console.log("Final Edges:", this.edges);
            try {
                // Load data into toolkit
                this.toolkit.load({
                    data: {
                        nodes: this.nodes,
                        edges: this.edges,
                    },
                });
                this.surface.zoomToFit({
                    fill: 0.7,
                });
                if (this.subscription) {
                    this.subscription.unsubscribe();
                }
                this.subscription = this.elasticsearchQueryService.filterCriteriaDetails.subscribe(criteria => {
                    this.filterCriteria = criteria;
                    console.log("Filter Criteria in TSM component:", this.filterCriteria);
                    this.filterCriteriaArray = this.filterCriteria
                        .split(',')
                        .map(item => item.trim())
                        .filter(item => item.length > 0);
                });
                this.loader = false;
                if (window['logLevel'] > 1) {
                    console.log('Data loaded successfully into toolkit');
                }
            }
            catch (error) {
                console.error('Error loading data into toolkit:', error);
            }
        }
        else {
            console.warn('No nodes to render');
        }
    }
    populateTypeMaps() {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
        for (const span of this.transactionServiceData) {
            // Merge repeated server spans before rendering so same-depth duplicates share one node.
            if (((_a = span.kind) === null || _a === void 0 ? void 0 : _a.toLowerCase()) == 'server') {
                this.addServerSpanToGroup(span);
                continue;
            }
            if (((_b = span.kind) === null || _b === void 0 ? void 0 : _b.toLowerCase()) !== 'client')
                continue;
            // Check if client span has any server children
            if (this.hasServerChild(span)) {
                console.warn(`Client span ${span["span_id"]} has server child, skipping processing for type map.`);
                this.discardSpanSet.add(span["span_id"]);
                continue;
            }
            // Detect callout type
            const calloutType = this.elasticsearchQueryService.detectCalloutType(span);
            console.log("callout-type:", calloutType);
            if (calloutType == 'other') {
                console.warn(`Callout type 'other' detected for span ID ${span.span_id} and span Name ${span.name}, skipping processing for type map.`);
                continue; // Skip processing 'other' callouts
            }
            if (window['logLevel'] > 1) {
                console.log("Callout type is:======>", calloutType);
            }
            // Generate backend key
            const idKey = this.getBackendKey(span, calloutType);
            if (window['logLevel'] > 1) {
                console.log("backend key generated :=======>", idKey);
            }
            // Get correct map for this type
            const map = this.getMapByType(calloutType);
            if (window['logLevel'] > 1) {
                console.log("Corresponding mapbyType:======>", map);
            }
            // duration from span
            const duration = span.duration || 0;
            // identify calling service instance
            const tierName = ((_c = span.attributes) === null || _c === void 0 ? void 0 : _c['cav.tier']) || ((_e = (_d = span.resource) === null || _d === void 0 ? void 0 : _d.attributes) === null || _e === void 0 ? void 0 : _e['service.name']) || 'unknown_tier';
            const serverName = ((_f = span.attributes) === null || _f === void 0 ? void 0 : _f['cav.server']) || ((_h = (_g = span.resource) === null || _g === void 0 ? void 0 : _g.attributes) === null || _h === void 0 ? void 0 : _h['host.name']) || 'unknown_server';
            const instanceName = ((_j = span.attributes) === null || _j === void 0 ? void 0 : _j['cav.instance']) || ((_l = (_k = span.resource) === null || _k === void 0 ? void 0 : _k.attributes) === null || _l === void 0 ? void 0 : _l['service.instance.id']) || ((_o = (_m = span.resource) === null || _m === void 0 ? void 0 : _m.attributes) === null || _o === void 0 ? void 0 : _o['process.pid']) || 'unknown_instance';
            const instanceKey = `${tierName}##${serverName}##${instanceName}`;
            const backendTypeLabel = idKey.split('##')[1].toUpperCase();
            const backendDisplayName = this.getBackendDisplayName(span, calloutType);
            const backendLookupName = ((_p = span.attributes) === null || _p === void 0 ? void 0 : _p['cav.IP']) || backendDisplayName;
            if (!map.has(idKey)) {
                map.set(idKey, {
                    nodeId: span.span_id,
                    firstSpanId: span.span_id,
                    backendKey: idKey,
                    displayName: backendDisplayName,
                    lookupName: backendLookupName,
                    type: backendTypeLabel,
                    spanIds: [span.span_id],
                    count: 1,
                    totalDuration: span.duration || 0,
                    perInstance: {
                        [instanceKey]: {
                            firstSpanId: span.span_id,
                            spanIds: [span.span_id],
                            count: 1,
                            duration: duration,
                            type: backendTypeLabel
                        }
                    },
                });
            }
            else {
                const entry = map.get(idKey);
                entry.spanIds.push(span.span_id);
                entry.count += 1;
                entry.totalDuration += span.duration || 0;
                if (!entry.perInstance[instanceKey]) {
                    entry.perInstance[instanceKey] = { firstSpanId: span.span_id, spanIds: [span.span_id], count: 1, duration: duration, type: backendTypeLabel };
                }
                else {
                    entry.perInstance[instanceKey].spanIds.push(span.span_id);
                    entry.perInstance[instanceKey].count += 1;
                    entry.perInstance[instanceKey].duration += duration;
                }
            }
        }
        if (window['logLevel'] > 1) {
            console.log("Backend Maps Populated:", {
                db: this.dbBackendMap,
                http: this.httpBackendMap,
                msg: this.messageBackendMap,
                other: this.otherBackendMap
            });
        }
        this.addServerNodesToNodeList();
        // Build nodes from unique backends
        this.addIPNodesToNodeList();
        //Get all edges for nodes
        this.getAllEdges();
    }
    addIPNodesToNodeList() {
        this.addFirstSpansToNodeList(this.dbBackendMap, "db");
        this.addFirstSpansToNodeList(this.httpBackendMap, "http");
        this.addFirstSpansToNodeList(this.messageBackendMap, "messaging");
        this.addFirstSpansToNodeList(this.otherBackendMap, "other");
    }
    getAllEdges() {
        this.getEdge(this.dbBackendMap);
        this.getEdge(this.httpBackendMap);
        this.getEdge(this.messageBackendMap);
        this.getEdge(this.otherBackendMap);
        this.getServerEdge(this.serverGroupMap);
    }
    //indexing spans
    indexSpans() {
        this.spanMap.clear();
        this.parentMap.clear();
        for (const span of this.transactionServiceData) {
            this.spanMap.set(span.span_id, span);
            // Only index child spans (those with a parent_span_id)
            if (span["parent_span_id"]) {
                if (!this.parentMap.has(span["parent_span_id"])) {
                    this.parentMap.set(span["parent_span_id"], []);
                }
                // Safely retrieve the child array and push the span_id
                const children = this.parentMap.get(span["parent_span_id"]);
                if (children) {
                    children.push(span["span_id"]);
                }
            }
        }
        console.log("Span Map Indexed:", [...this.spanMap.keys()]);
        console.log("Parent Map Indexed:", this.parentMap);
    }
    addServerSpanToGroup(span) {
        const depth = this.getNodeDepth(span);
        const serverKey = this.getServerGroupKey(span, depth);
        if (!this.serverGroupMap.has(serverKey)) {
            this.serverGroupMap.set(serverKey, {
                nodeId: span.span_id,
                firstSpanId: span.span_id,
                serverKey,
                depth,
                spanIds: [span.span_id],
                count: 1,
                totalDuration: span.duration || 0,
            });
            return;
        }
        const entry = this.serverGroupMap.get(serverKey);
        entry.spanIds.push(span.span_id);
        entry.count += 1;
        entry.totalDuration += span.duration || 0;
    }
    addServerNodesToNodeList() {
        var _a, _b;
        for (const serverGroup of this.serverGroupMap.values()) {
            const firstSpan = this.spanMap.get(serverGroup.firstSpanId);
            if (!firstSpan) {
                continue;
            }
            const agentType = (_b = (_a = firstSpan.resource) === null || _a === void 0 ? void 0 : _a.attributes) === null || _b === void 0 ? void 0 : _b["telemetry.sdk.language"];
            const serverNode = Object.assign(Object.assign({}, firstSpan), { attributes: Object.assign({}, (firstSpan.attributes || {})), resource: Object.assign({}, (firstSpan.resource || {})), nodeIcon: this.getAgentIcon(agentType), totalCount: serverGroup.count, totalDuration: (serverGroup.totalDuration / 1000000).toFixed(3), type: "server", spanIds: [...serverGroup.spanIds], serverDepth: serverGroup.depth });
            // Point every grouped server span back to the merged node for later edge resolution.
            this.nodeList.push(serverNode);
            this.nodeSet.add(serverGroup.nodeId);
            for (const spanId of serverGroup.spanIds) {
                this.renderedNodeIdBySpanId.set(spanId, serverGroup.nodeId);
            }
        }
    }
    //creates nodes
    addFirstSpansToNodeList(map, backendType) {
        for (const backend of map.values()) {
            const firstSpan = this.spanMap.get(backend.firstSpanId);
            if (!firstSpan) {
                continue;
            }
            const backendNode = Object.assign(Object.assign({}, firstSpan), { attributes: Object.assign({}, (firstSpan.attributes || {})), resource: Object.assign({}, (firstSpan.resource || {})), nodeIcon: this.getBackendIcon(backend.type), totalCount: backend.count, totalDuration: (backend.totalDuration / 1000000).toFixed(3), type: backend.type, backendType, backendKey: backend.backendKey, backendDisplayName: backend.displayName, backendLookupName: backend.lookupName, name: backend.displayName, spanIds: [...backend.spanIds] });
            // Point every grouped backend span back to the merged node for later edge resolution.
            this.nodeList.push(backendNode);
            this.nodeSet.add(backend.nodeId);
            for (const spanId of backend.spanIds) {
                this.renderedNodeIdBySpanId.set(spanId, backend.nodeId);
            }
        }
    }
    //create edges
    getEdge(spanObj) {
        for (const backendStats of spanObj.values()) {
            // Collapse multiple raw calls from the same source into one labeled edge.
            const edgeSummary = new Map();
            for (const spanId of backendStats.spanIds) {
                const span = this.spanMap.get(spanId);
                if (!span) {
                    continue;
                }
                const sourceInfo = this.findSourceNode(span, backendStats.nodeId);
                const sourceId = (sourceInfo === null || sourceInfo === void 0 ? void 0 : sourceInfo.nodeId) || "root";
                const existingSummary = edgeSummary.get(sourceId);
                if (existingSummary) {
                    existingSummary.count += 1;
                    existingSummary.duration += span.duration || 0;
                }
                else {
                    edgeSummary.set(sourceId, {
                        sourceId,
                        count: 1,
                        duration: span.duration || 0,
                    });
                }
            }
            for (const summary of edgeSummary.values()) {
                this.edges.push({
                    source: summary.sourceId,
                    target: backendStats.nodeId,
                    data: {
                        label: `${summary.count} ${backendStats.type}, ${(summary.duration / 1000000).toFixed(3)} ms`
                    }
                });
            }
        }
    }
    getServerEdge(serverMap) {
        for (const serverGroup of serverMap.values()) {
            // Collapse multiple raw server spans from the same source into one labeled edge.
            const edgeSummary = new Map();
            for (const spanId of serverGroup.spanIds) {
                const span = this.spanMap.get(spanId);
                if (!span) {
                    continue;
                }
                const sourceInfo = this.findSourceNode(span, serverGroup.nodeId);
                const sourceId = (sourceInfo === null || sourceInfo === void 0 ? void 0 : sourceInfo.nodeId) || "root";
                const existingSummary = edgeSummary.get(sourceId);
                if (existingSummary) {
                    existingSummary.count += 1;
                    existingSummary.duration += span.duration || 0;
                }
                else {
                    edgeSummary.set(sourceId, {
                        sourceId,
                        count: 1,
                        duration: span.duration || 0,
                    });
                }
            }
            for (const summary of edgeSummary.values()) {
                this.edges.push({
                    source: summary.sourceId,
                    target: serverGroup.nodeId,
                    data: { label: `${summary.count} HTTP, ${(summary.duration / 1000000).toFixed(3)} ms` }
                });
            }
        }
    }
    //finding source
    findSourceNode(span, excludedNodeId) {
        var _a;
        let current = span;
        if (!current["parent_span_id"]) {
            return null;
        }
        while (current["parent_span_id"]) {
            const parent = this.spanMap.get(current["parent_span_id"]);
            if (!parent)
                break;
            if (((_a = parent.kind) === null || _a === void 0 ? void 0 : _a.toLowerCase()) !== 'internal') {
                const nodeId = this.renderedNodeIdBySpanId.get(parent.span_id);
                if (nodeId && this.nodeSet.has(nodeId) && nodeId !== excludedNodeId) {
                    return { span: parent, nodeId };
                }
            }
            current = parent;
        }
        return null;
    }
    findRenderableAncestorSpan(span) {
        let current = span;
        while (current["parent_span_id"]) {
            const parent = this.spanMap.get(current["parent_span_id"]);
            if (!parent) {
                break;
            }
            // Depth is based on visible nodes only, so skipped/internal spans do not increase it.
            if (this.isRenderableNode(parent)) {
                return parent;
            }
            current = parent;
        }
        return null;
    }
    getNodeDepth(span) {
        if (this.nodeDepthBySpanId.has(span.span_id)) {
            return this.nodeDepthBySpanId.get(span.span_id);
        }
        // Depth is memoized because server grouping repeatedly asks for the same ancestry chain.
        const parentNode = this.findRenderableAncestorSpan(span);
        const depth = parentNode ? this.getNodeDepth(parentNode) + 1 : 1;
        this.nodeDepthBySpanId.set(span.span_id, depth);
        return depth;
    }
    isRenderableNode(span) {
        var _a;
        const kind = (_a = span.kind) === null || _a === void 0 ? void 0 : _a.toLowerCase();
        if (kind === 'server') {
            return true;
        }
        if (kind !== 'client') {
            return false;
        }
        if (this.hasServerChild(span)) {
            return false;
        }
        return this.elasticsearchQueryService.detectCalloutType(span) !== 'other';
    }
    hasServerChild(span) {
        var _a;
        const clientChild = (_a = this.parentMap.get(span["span_id"])) !== null && _a !== void 0 ? _a : [];
        return clientChild.some(childSpanId => { var _a, _b; return ((_b = (_a = this.spanMap.get(childSpanId)) === null || _a === void 0 ? void 0 : _a["kind"]) === null || _b === void 0 ? void 0 : _b.toLowerCase()) === 'server'; });
    }
    getServerGroupKey(span, depth) {
        var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
        const tierName = (_e = (_b = (_a = span.attributes) === null || _a === void 0 ? void 0 : _a["cav.tier"]) !== null && _b !== void 0 ? _b : (_d = (_c = span.resource) === null || _c === void 0 ? void 0 : _c.attributes) === null || _d === void 0 ? void 0 : _d["service.name"]) !== null && _e !== void 0 ? _e : 'unknown_tier';
        const serverName = (_k = (_g = (_f = span.attributes) === null || _f === void 0 ? void 0 : _f["cav.server"]) !== null && _g !== void 0 ? _g : (_j = (_h = span.resource) === null || _h === void 0 ? void 0 : _h.attributes) === null || _j === void 0 ? void 0 : _j["host.name"]) !== null && _k !== void 0 ? _k : 'unknown_server';
        const appName = (_t = (_q = (_m = (_l = span.attributes) === null || _l === void 0 ? void 0 : _l["cav.instance"]) !== null && _m !== void 0 ? _m : (_p = (_o = span.resource) === null || _o === void 0 ? void 0 : _o.attributes) === null || _p === void 0 ? void 0 : _p["service.instance.id"]) !== null && _q !== void 0 ? _q : (_s = (_r = span.resource) === null || _r === void 0 ? void 0 : _r.attributes) === null || _s === void 0 ? void 0 : _s["process.pid"]) !== null && _t !== void 0 ? _t : 'unknown_instance';
        return `${depth}##${tierName}##${serverName}##${appName}`;
    }
    //get unique backendkey 
    getBackendKey(span, calloutType) {
        const attrs = span.attributes || {};
        switch (calloutType) {
            case 'db': {
                const connStr = attrs['cav.IP'] || attrs['db.connection_string'] || attrs['db.connection.url'];
                const connNet = this.getDbNetworkIdentity(attrs);
                const dbType = attrs['db.system'] || attrs['db.system.name'] || 'unknown_db_type';
                if (connStr) {
                    return `${connStr}##${dbType}`;
                }
                if (connNet) {
                    return `${connNet}##${dbType}`;
                }
                const fallbackIdentity = span.name || 'unknown_db_url';
                return `${fallbackIdentity}##${dbType}`;
            }
            case 'http': {
                const host = attrs['http.host'] || attrs['net.peer.name'] || attrs['net.peer.ip'] || attrs['server.address'] || attrs['cav.IP'] || span.name || 'unknown_http_host';
                const method = "http";
                return `${host}##${method}`;
            }
            case 'message': {
                const system = attrs['messaging.system'] || attrs['cav.IP'] || span.name || 'unknown_messaging';
                const destination = attrs['messaging.destination'] || 'unknown_destination';
                return `${system}##${destination}`;
            }
            case 'other': {
                const name = attrs['cav.IP'] || span.name || 'unknown';
                return `${name}##other`;
            }
            default:
                return 'unknown##unknown';
        }
    }
    getBackendDisplayName(span, calloutType) {
        const attrs = span.attributes || {};
        switch (calloutType) {
            case 'db':
                return this.getDbDisplayName(span);
            case 'http':
            case 'message':
            case 'other':
                return attrs['cav.IP'] || span.name || 'unknown_backend';
            default:
                return attrs['cav.IP'] || span.name || 'unknown_backend';
        }
    }
    getDbNetworkIdentity(attrs) {
        const address = attrs['network.peer.address'] || attrs['server.address'] || attrs['net.peer.name'] || attrs['net.peer.ip'];
        if (!address) {
            return null;
        }
        const port = attrs['network.peer.port'] || attrs['server.port'] || attrs['net.peer.port'] || '';
        return port ? `${address}_${port}` : `${address}`;
    }
    getDbDisplayName(span) {
        const attrs = span.attributes || {};
        const connStr = attrs['cav.IP'] || attrs['db.connection_string'] || attrs['db.connection.url'];
        const connNet = this.getDbNetworkIdentity(attrs);
        const dbName = attrs['db.name'];
        return connStr || connNet || dbName || span.name || 'unknown_backend';
    }
    getMapByType(calloutType) {
        switch (calloutType) {
            case 'db':
                return this.dbBackendMap;
            case 'http':
                return this.httpBackendMap;
            case 'message':
                return this.messageBackendMap;
            case 'other':
            default:
                return this.otherBackendMap;
        }
    }
    showNodeDetailsPanel(nodeData) {
        this.selectedNode = this.spanMap.get(nodeData);
        if (window['logLevel'] > 1) {
            console.log(this.selectedNode);
        }
    }
    openOutputNodeOverlay(nodeData) {
        this.ddrData.setHoveredNode("");
        this.hoveredNodeData = nodeData.obj.data.data;
        this.ddrData.setHoveredNode(this.hoveredNodeData);
        if (window['logLevel'] > 1) {
            console.log("Hovered Node Data:", this.hoveredNodeData);
        }
    }
    dblClick(nodeData) {
        const data = nodeData.obj.data.data;
        const kind = data.kind.toLowerCase();
        this.nodeKind = kind;
        if (kind == 'server') {
            this.relativePathForINDPopup = 'ddr/trxn-service-map/server-node.json';
            this.serverNodeData = this.buildServerNodeDetails(data);
            this.nodeDetails = true;
            console.log("Server Node Data :", this.serverNodeData);
        }
        if (kind == 'client') {
            const backendType = data.backendType;
            // Query the full merged node span set so popup rows cover every collapsed backend call.
            const payload = this.buildClientNodeDetailsPayload(data);
            const resFields = [
                "trace_id",
                "span_id",
                "name",
                "@timestamp",
                "duration",
                "attributes.cav.*",
                "attributes.http.*",
                "attributes.db.*",
                "attributes.url.full"
            ];
            const ipIndInfoESQuery = this.elasticsearchQueryService.buildElasticSearchQuery(payload, resFields, _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_8__["BREADCRUMB_ITEMS"].IP_CALLOUT_DETAILS);
            this.elasticsearchQueryService.search(ipIndInfoESQuery).subscribe(res => {
                var _a, _b;
                this.elasticSearchData = res;
                const indCalloutDataArray = this.processIndElasticInfo(this.elasticSearchData, backendType);
                this.clientNodeData = indCalloutDataArray;
                this.fullQueryName = ((_a = indCalloutDataArray[0]) === null || _a === void 0 ? void 0 : _a.queries) || ((_b = indCalloutDataArray[0]) === null || _b === void 0 ? void 0 : _b.url) || "-";
                this.nodeDetails = true;
                if (window['logLevel'] > 1) {
                    console.log("Data from process elastic", indCalloutDataArray);
                    console.log('Search results from Elasticsearch:', res);
                }
            }, error => {
                console.error('Error in getting data from Elasticsearch:', error);
                this.clientNodeData = [];
            });
        }
    }
    buildClientNodeDetailsPayload(data) {
        var _a, _b;
        const spanIds = Array.isArray(data.spanIds) && data.spanIds.length ? data.spanIds : [data.span_id];
        const relatedSpans = spanIds
            .map((spanId) => this.spanMap.get(spanId))
            .filter((span) => !!span);
        const startTime = relatedSpans.length
            ? Math.min(...relatedSpans.map((span) => Math.floor(Number(span["@timestamp"]) || 0)))
            : Math.floor(Number(data["@timestamp"]) || 0);
        const endTime = relatedSpans.length
            ? Math.max(...relatedSpans.map((span) => Math.floor(Number(span["@timestamp"]) || 0) + Math.ceil((span.duration || 0) / 1000000)))
            : Math.floor(Number(data["@timestamp"]) || 0) + Math.ceil((data.duration || 0) / 1000000);
        // Expand the time range to the merged span set so backend popup data is complete.
        return {
            testRun: data.attributes["cav.TR"],
            strStartTime: startTime,
            strEndTime: endTime + 1000,
            traceId: data.trace_id,
            backendIPname: (_b = (_a = data.backendLookupName) !== null && _a !== void 0 ? _a : data.attributes["cav.IP"]) !== null && _b !== void 0 ? _b : data.name,
            spanIds,
        };
    }
    buildServerNodeDetails(data) {
        const spanIds = Array.isArray(data.spanIds) && data.spanIds.length ? data.spanIds : [data.span_id];
        // Server popup rows are limited to the exact spans merged into the clicked node.
        return spanIds
            .map((spanId) => this.spanMap.get(spanId))
            .filter((span) => !!span)
            .map((span) => {
            var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u;
            return ({
                tierName: (_b = (_a = span.attributes) === null || _a === void 0 ? void 0 : _a["cav.tier"]) !== null && _b !== void 0 ? _b : (_d = (_c = span.resource) === null || _c === void 0 ? void 0 : _c.attributes) === null || _d === void 0 ? void 0 : _d["service.name"],
                serverName: (_f = (_e = span.attributes) === null || _e === void 0 ? void 0 : _e["cav.server"]) !== null && _f !== void 0 ? _f : (_h = (_g = span.resource) === null || _g === void 0 ? void 0 : _g.attributes) === null || _h === void 0 ? void 0 : _h["host.name"],
                appName: (_o = (_k = (_j = span.attributes) === null || _j === void 0 ? void 0 : _j["cav.instance"]) !== null && _k !== void 0 ? _k : (_m = (_l = span.resource) === null || _l === void 0 ? void 0 : _l.attributes) === null || _m === void 0 ? void 0 : _m["service.instance.id"]) !== null && _o !== void 0 ? _o : (_q = (_p = span.resource) === null || _p === void 0 ? void 0 : _p.attributes) === null || _q === void 0 ? void 0 : _q["process.pid"],
                bt: (_r = span.attributes) === null || _r === void 0 ? void 0 : _r["cav.BT"],
                url: (_t = (_s = span.attributes) === null || _s === void 0 ? void 0 : _s["url.path"]) !== null && _t !== void 0 ? _t : (_u = span.attributes) === null || _u === void 0 ? void 0 : _u["http.url"],
                startTime: Math.floor(Number(span["@timestamp"]) || 0),
                duration: ((span.duration || 0) / 1000000).toFixed(3),
            });
        });
    }
    //process's and fills the data received from elasticSearch
    processIndElasticInfo(elasticData, backendType) {
        var _a, _b, _c;
        const elasticInd = elasticData.hits.hits;
        let calloutType;
        let queries;
        let startTime;
        let endTime;
        let url;
        let spanName;
        const result = [];
        if (backendType.toLowerCase() == "db") {
            this.relativePathForINDPopup = "ddr/agg-ip-info/ind-popup-elasticSearch.json";
            for (const indData of elasticInd) {
                spanName = indData._source.name;
                calloutType = (_a = indData._source.attributes["cav.IP"]) !== null && _a !== void 0 ? _a : indData._source.name;
                queries = indData._source.attributes["db.statement"] || spanName;
                startTime = Math.floor(indData._source["@timestamp"]);
                endTime = (indData._source.duration) / 1000000;
                result.push({
                    callOutType: calloutType,
                    queries: queries,
                    startTime: startTime,
                    endTime: endTime
                });
            }
            return result;
        }
        else if (backendType.toLowerCase() == "http") {
            this.relativePathForINDPopup = "ddr/agg-ip-info/ind-popup-http-elasticSearch.json";
            for (const indData of elasticInd) {
                calloutType = (_b = indData._source.attributes["cav.IP"]) !== null && _b !== void 0 ? _b : indData._source.name;
                startTime = Math.floor(indData._source["@timestamp"]);
                endTime = (indData._source.duration) / 1000000;
                url = indData._source.attributes["url.full"] || indData._source.attributes["http.url"] || indData._source.attributes["http.request.url"];
                result.push({
                    callOutType: calloutType,
                    url: url,
                    startTime: startTime,
                    endTime: endTime
                });
            }
            return result;
        }
        else {
            this.relativePathForINDPopup = "ddr/agg-ip-info/ind-popup-http-elasticSearch.json";
            for (const indData of elasticInd) {
                calloutType = (_c = indData._source.attributes["cav.IP"]) !== null && _c !== void 0 ? _c : indData._source.name;
                startTime = Math.floor(indData._source["@timestamp"]);
                endTime = (indData._source.duration) / 1000000;
                url = indData._source.attributes["url.full"] || indData._source.attributes["http.url"] || indData._source.attributes["http.request.url"] || indData._source.name;
                result.push({
                    callOutType: calloutType,
                    url: url,
                    startTime: startTime,
                    endTime: endTime
                });
            }
            return result;
        }
    }
    showInfoMessage() {
        const message = 'Query copied!';
        this.messageService.showInfo(message);
        setTimeout(() => {
            this.messageService.clear();
        }, 5000); // 5000 milliseconds = 5 seconds
    }
    copytext(val) {
        const text = val;
        const tempInput = document.createElement('textarea');
        tempInput.value = text;
        document.body.appendChild(tempInput);
        tempInput.select();
        document.execCommand('copy');
        tempInput.remove();
        this.showInfoMessage();
    }
    clickButtonEvent(event) {
        var _a, _b;
        const me = this;
        if (((_b = (_a = event === null || event === void 0 ? void 0 : event.cavEventExt) === null || _a === void 0 ? void 0 : _a.actionConfig) === null || _b === void 0 ? void 0 : _b.action) === "clickable") {
            me.showRowInfo(event.cavEventExt.row);
        }
    }
    clearHoverData() {
        this.hoveredNodeData = null;
    }
    getAgentIcon(agent) {
        if (!agent) {
            return "icons8-globe-100.png";
        }
        return this.agentTypeMap[agent.toLowerCase()] || "icons8-globe-100.png";
    }
    getBackendIcon(backend) {
        return this.backendTypeMap[backend.toLowerCase()] || "icons8-backend-100.png";
    }
    showRowInfo(rowData) {
        if (rowData.queries || rowData.url) {
            this.fullQueryName = rowData.queries || rowData.url;
        }
    }
    clearStructures() {
        this.spanMap.clear();
        this.serverGroupMap.clear();
        this.dbBackendMap.clear();
        this.httpBackendMap.clear();
        this.messageBackendMap.clear();
        this.otherBackendMap.clear();
        this.parentMap.clear();
        this.discardSpanSet.clear();
        this.nodeSet.clear();
        this.renderedNodeIdBySpanId.clear();
        this.nodeDepthBySpanId.clear();
        this.nodeList.length = 0; // Clear the node list
        this.serverList.length = 0; // Clear the server list
        this.nodes.length = 0; // Clear the nodes
        this.edges.length = 0; // Clear the edges
    }
};
TransactionServiceMapComponent.ctorParameters = () => [
    { type: _jsplumbtoolkit_browser_ui_angular__WEBPACK_IMPORTED_MODULE_2__["jsPlumbService"] },
    { type: src_app_pages_tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_4__["DdrDataModelService"] },
    { type: _services_elasticsearch_query_service__WEBPACK_IMPORTED_MODULE_6__["ElasticsearchQueryService"] },
    { type: src_app_shared_cav_toast_service_cav_message_service__WEBPACK_IMPORTED_MODULE_5__["CavMessageService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], TransactionServiceMapComponent.prototype, "columnData", void 0);
TransactionServiceMapComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'app-transaction-service-map',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./transaction-service-map.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./transaction-service-map.component.scss */ "./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.scss")).default]
    })
], TransactionServiceMapComponent);



/***/ }),

/***/ "./src/app/pages/ddr/components/weblogic/weblogic.component.scss":
/*!***********************************************************************!*\
  !*** ./src/app/pages/ddr/components/weblogic/weblogic.component.scss ***!
  \***********************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("/*Responsive table*/\ntable {\n  width: 100%;\n  background: #fff;\n  /*box-shadow: 0px 3px 6px #B5B5B5;*/\n}\ntd {\n  padding: 2px;\n  text-align: left;\n  font-size: 11px;\n}\nth {\n  padding: 4px;\n  font-size: 11px;\n}\n/* Zebra striping */\ntr:nth-of-type(odd) {\n  background: #e3ebf9;\n  color: #000;\n  font-weight: \"normal\";\n}\nth {\n  background: #154771;\n  font-weight: bold;\n  font-size: 11px;\n  color: #fff;\n  font-weight: \"bold\";\n}\nh1 a {\n  text-decoration: none;\n  color: #fff;\n}\nmd-card-actions {\n  margin-left: 0;\n  margin-right: 0;\n  padding: 0;\n}\n.cardTitleClass {\n  height: 20px;\n  float: right;\n  font-size: 14px;\n  color: #e6e6e6;\n  line-height: 20px;\n  width: 82%;\n}\nmd-card-title-text {\n  font-size: 14px;\n}\n.ui-dialog.ui-widget .ui-dialog-titlebar .ui-dialog-title {\n  font-size: 13px !important;\n}\n.loadingIcon1 {\n  height: 50px;\n  margin-left: 50%;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/components/weblogic/weblogic.component.ts":
/*!*********************************************************************!*\
  !*** ./src/app/pages/ddr/components/weblogic/weblogic.component.ts ***!
  \*********************************************************************/
/*! exports provided: WeblogicComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "WeblogicComponent", function() { return WeblogicComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./../../constants/breadcrumb.constants */ "./src/app/pages/ddr/constants/breadcrumb.constants.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! highcharts */ "./node_modules/highcharts/highcharts.js");
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_7__);


//import {DataTableModule,BlockUIModule,PaginatorModule} from 'primeng/primeng';

//import 'rxjs/Rx';
//import { ChartModule } from 'angular2-highcharts';
//import { CavConfigService } from "../../../../main/services/cav-config.service";
//import { CavTopPanelNavigationService } from "../../../../main/services/cav-top-panel-navigation.service";


//import { DdrDataModelService } from '../../services/ddr-data-model.service';



let WeblogicComponent = class WeblogicComponent {
    constructor(commonService, 
    //private _cavConfigService: CavConfigService, 
    //private _navService: CavTopPanelNavigationService, 
    //private _cavConfig: CavConfigService,
    breadcrumbService, _ddrData, ddrRequest) {
        this.commonService = commonService;
        this.breadcrumbService = breadcrumbService;
        this._ddrData = _ddrData;
        this.ddrRequest = ddrRequest;
        this.highcharts = highcharts__WEBPACK_IMPORTED_MODULE_7__;
        this.weblogicDetail = [{ threadName: "", workManager: "", currReq: "", totalReq: "", threadState: "" }];
        this.startTime = "";
        this.endTime = "";
        this.filterCriteria = ""; //To show filter criteria
        this.showPieChart = false;
        this.loading = false; //Loading ajax loader icon
        this.showDownLoadReportIcon = true;
        this.totalThreads = ""; //Total no. of threads
        this.activeThreads = ""; //Total no. of active threads
        this.selectedThreadState = "Thread State:All";
        this.showResetBtn = false;
        this.reportHeader = "";
        this.filterDCName = '';
        this.id = commonService.getData();
        this.getWeblogicData();
        this.setTestRunInHeader();
    }
    ngOnInit() {
        this.loading = true;
        this.commonService.isToLoadSideBar = false;
        this.breadcrumbService.setBreadcrumbs(_constants_breadcrumb_constants__WEBPACK_IMPORTED_MODULE_4__["BREADCRUMB_ITEMS"].WEBLOGIC);
        this.reportHeader = 'Weblogic Thread Pool Report- ' + this.id.testRun;
    }
    /*Method is used get host url*/
    getHostUrl(isDownloadCase) {
        var hostDcName = this._ddrData.getHostUrl(isDownloadCase);
        if (!isDownloadCase && sessionStorage.getItem("isMultiDCMode") == "true") {
            //hostDcName =   this._ddrData.host + ':' + this._ddrData.port;
            this.id.testRun = this._ddrData.testRun;
            //this.testRun= this._ddrData.testRun;
            console.log("all case url==>", hostDcName, "all case test run==>", this.id.testRun);
        }
        // else
        // if (this._navService.getDCNameForScreen("weblogic") === undefined)
        //   hostDcName = this._cavConfigService.getINSPrefix();
        // else
        //   hostDcName = this._cavConfigService.getINSPrefix() + this._navService.getDCNameForScreen("weblogic");
        // if (hostDcName.length > 0) {
        //   sessionStorage.removeItem("hostDcName");
        //   sessionStorage.setItem("hostDcName", hostDcName);
        // }
        // else
        //   hostDcName = sessionStorage.getItem("hostDcName");
        console.log('hostDcName =', hostDcName);
        return hostDcName;
    }
    /**
     * Rest call for getting weblogic data
     */
    getWeblogicData() {
        let url = '';
        this.loading = false;
        //if(sessionStorage.getItem("isMultiDCMode") == "true" && this._cavConfigService.getActiveDC() == 'ALL'){
        if (this.commonService.enableQueryCaching == 1) {
            url = this.getHostUrl() + '/' + this.id.product + "/v1/cavisson/netdiagnostics/ddr/weblogicReport?cacheId=" + this.id.testRun + "&testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime;
        }
        else {
            url = this.getHostUrl() + '/' + this.id.product + "/v1/cavisson/netdiagnostics/ddr/weblogicReport?testRun=" + this.id.testRun + "&tierName=" + this.id.tierName + "&serverName=" + this.id.serverName + "&appName=" + this.id.appName + "&strStartTime=" + this.id.startTime + "&strEndTime=" + this.id.endTime;
        }
        // }
        //  else{
        //   if(this.commonService.enableQueryCaching == 1){
        //      url = this.getHostUrl() + '/' + this.id.product+"/v1/cavisson/netdiagnostics/ddr/weblogicReport/" + this.id.testRun + "?testRun="+this.id.testRun+"&tierName="+this.id.tierName+"&serverName="+this.id.serverName+"&appName="+this.id.appName+"&strStartTime="+ this.id.startTime + "&strEndTime="+ this.id.endTime;
        //   }
        //   else{
        //      url = this.getHostUrl() + '/' + this.id.product+"/v1/cavisson/netdiagnostics/ddr/weblogicReport?testRun="+this.id.testRun+"&tierName="+this.id.tierName+"&serverName="+this.id.serverName+"&appName="+this.id.appName+"&strStartTime="+ this.id.startTime + "&strEndTime="+ this.id.endTime;
        //   }
        //  }
        return this.ddrRequest.getDataUsingGet(url).subscribe(data => (this.doAssignWeblogicValue(data)));
    }
    /**
     *Assign values from JSON to local object array
     * @param res
     */
    doAssignWeblogicValue(res) {
        this.loading = false;
        this.createFilterCriteria();
        this.weblogicDetail = res.data; //JSON Weblogic data
        this.threadInfoDetail = res.threadInfo;
        this.weblogicDataInfo = this.getWeblogicDataInfo();
        this.originalAllData = this.weblogicDataInfo;
        if (this.weblogicDataInfo.length == 0)
            this.showDownLoadReportIcon = false;
        this.createThreadCountInfo(res.threadInfo);
        this.createPieChart(res.threadInfo);
    }
    /**
     * Assigning data to array
     */
    getWeblogicDataInfo() {
        var arrWeblogicData = [];
        if (this.weblogicDetail != undefined) {
            for (var i = 0; i < this.weblogicDetail.length; i++) {
                arrWeblogicData[i] = { threadName: this.weblogicDetail[i]["threadName"], workManager: this.weblogicDetail[i]["workManager"], currReq: this.weblogicDetail[i]["currReq"], totalReq: this.weblogicDetail[i]["totalReq"], threadState: this.weblogicDetail[i]["threadState"] };
            }
        }
        return arrWeblogicData;
    }
    /**
     * Method used to create filter criteria for show in top of the section
     */
    createFilterCriteria() {
        this.filterCriteria = '';
        if (this.selectedDC != undefined && this.selectedDC != null && this.selectedDC != '' && this.selectedDC != 'NA') {
            this.filterCriteria = 'DC=' + this.selectedDC + ', ';
        }
        else if (sessionStorage.getItem("isMultiDCMode") == "true") {
            let dcName = "ALL";
            if (dcName == "ALL")
                dcName = this._ddrData.dcName;
            this.filterCriteria = 'DC=' + dcName + ', ';
        }
        if (this.id.tierName != "NA" && this.id.tierName != "" && this.id.tierName != "undefined" && this.id.tierName != undefined)
            this.filterCriteria += "Tier=" + this.id.tierName;
        if (this.id.serverName != "NA" && this.id.serverName != "" && this.id.serverName != "undefined" && this.id.serverName != undefined)
            this.filterCriteria += ", Server=" + this.id.serverName;
        if (this.id.appName != "NA" && this.id.appName != "" && this.id.appName != "undefined" && this.id.appName != undefined)
            this.filterCriteria += ", Instance=" + this.id.appName;
        if (this.id.startTimeInDateFormat != "NA" && this.id.startTimeInDateFormat != "" && this.id.startTimeInDateFormat != undefined && this.id.startTimeInDateFormat != "undefined")
            this.filterCriteria += ", StartTime=" + this.id.startTimeInDateFormat;
        if (this.id.endTimeInDateFormat != "NA" && this.id.endTimeInDateFormat != "" && this.id.endTimeInDateFormat != undefined && this.id.endTimeInDateFormat != "undefined")
            this.filterCriteria += ", EndTime=" + this.id.endTimeInDateFormat;
        if (this.filterCriteria.startsWith(","))
            this.filterCriteria = this.filterCriteria.substring(1);
        if (this.filterCriteria.endsWith(","))
            this.filterCriteria = this.filterCriteria.substring(0, this.filterCriteria.length - 1);
    }
    /**
     * This method is used to set Test Run header info which is used in download report as title
     */
    setTestRunInHeader() {
        if (decodeURIComponent(this.id.ipWithProd).indexOf("netstorm") != -1)
            this.strTitle = "Netstorm - Weblogic Thread Pool Stats - Test Run : " + this.id.testRun;
        else
            this.strTitle = "Netdiagnostics Enterprise - Weblogic Thread Pool Stats - Session : " + this.id.testRun;
    }
    /**
     *This method is used to calculate total threads and active threads which is
     *used to show in pie chart subtitle sections
     */
    getTotalAndActiveThreads() {
        return `[ Total Threads: ${this.totalThreads}, Active Threads: ${this.activeThreads} ]`;
    }
    /**
     *This method is used to create pie charts based on thread status count
     * @param threadInfo
     */
    createPieChart(threadInfo) {
        if (threadInfo.length == 0 || threadInfo == undefined) {
            this.showPieChart = false;
        }
        else {
            this.showPieChart = true;
        }
        var threadInfoArr = [];
        var threadStateName = threadInfo[0];
        for (var i in threadStateName) {
            if (i == "Idle" || i == "Hogger" || i == "Running" || i == "Standby" || i == "Stuck")
                threadInfoArr.push({ "name": i, "y": Number(threadStateName[i]), "statusCount": Number(threadStateName[i]) });
        }
        this.options = {
            chart: {
                type: 'pie',
            },
            credits: {
                enabled: false
            },
            title: { text: 'Threads State', style: { 'fontSize': '13px' } },
            subtitle: {
                text: this.getTotalAndActiveThreads(),
                style: {
                    fontSize: '12px',
                    color: 'blue',
                    fontFamily: 'Verdana',
                    marginBottom: '10px'
                }
            },
            tooltip: {
                pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b><br>Count: {point.statusCount}'
            },
            plotOptions: {
                pie: {
                    cursor: 'pointer',
                    allowPointSelect: true,
                    dataLabels: {
                        enabled: true,
                        format: '<b> {point.name} </b>: {point.percentage:.2f} %',
                    },
                    showInLegend: true
                }
            },
            series: [
                {
                    name: 'Percentage',
                    data: threadInfoArr,
                    enableMouseTracking: true
                }
            ]
        };
    }
    /**
     * This method is used to count the total threads and active threads
     * @param threadStateCount
     */
    createThreadCountInfo(threadStateCount) {
        var threadStateCount = threadStateCount[0];
        this.totalThreads = threadStateCount.Total;
        this.activeThreads = threadStateCount.Active;
    }
    /**
     * This method is used to Chnage table data based on pie chart threas state clicked
     * @param event
     */
    changeTableData(event) {
        this.showResetBtn = true;
        this.selectedThreadState = "Thread State: " + event.point.name;
        var selectThread = event.point.name;
        var sectionJson = this.weblogicDetail.filter((data) => {
            if (data.threadState == selectThread) {
                return data;
            }
        });
        this.weblogicDataInfo = sectionJson;
    }
    /**
     * This method is used to reset the data table with all data
     */
    resetTableData() {
        this.showResetBtn = false;
        this.selectedThreadState = "Thread State: All";
        this.weblogicDataInfo = this.originalAllData;
    }
    //This method is used to download the Weblogic data table
    downloadReport(downloadType) {
        var jsonData = "[";
        let weblogicTableRenameArray = { "threadName": "Thread Name", "workManager": "Work Manager", "currReq": "Current Request", "totalReq": "Total Request", "threadState": "Thread State" };
        let weblogicColOrder = ["Thread Name", "Work Manager", "Current Request", "Total Request", "Thread State"];
        let downloadObj = {
            downloadType: downloadType,
            strSrcFileName: "WeblogicReport",
            strRptTitle: this.strTitle,
            weblogicData: JSON.stringify(this.weblogicDetail),
            weblogicTableRenameArray: JSON.stringify(weblogicTableRenameArray),
            varFilterCriteria: this.filterCriteria,
            weblogicColOrder: weblogicColOrder.toString()
        };
        let downloadFileUrl;
        if (sessionStorage.getItem("isMultiDCMode") == "true" && (downloadFileUrl.includes("/tomcat") || downloadFileUrl.includes("/node"))) {
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, (downloadObj)).subscribe(res => (this.openDownloadReports(res)));
        }
        else
            this.ddrRequest.getDataInStringUsingPost(downloadFileUrl, JSON.stringify(downloadObj)).subscribe(res => (this.openDownloadReports(res)));
    }
    //To open the download file from the particular path 
    openDownloadReports(res) {
        let downloadFileUrl = decodeURIComponent(this.getHostUrl(true)) + "/common/" + res;
        window.open(downloadFileUrl);
    }
};
WeblogicComponent.ctorParameters = () => [
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_2__["CommonServices"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__["DdrBreadcrumbService"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__["DdrDataModelService"] },
    { type: _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_6__["DDRRequestService"] }
];
WeblogicComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'weblogic',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./weblogic.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/components/weblogic/weblogic.component.html")).default,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./weblogic.component.scss */ "./src/app/pages/ddr/components/weblogic/weblogic.component.scss")).default]
    })
], WeblogicComponent);



/***/ }),

/***/ "./src/app/pages/ddr/constants/ns-ddr-header.constants.ts":
/*!****************************************************************!*\
  !*** ./src/app/pages/ddr/constants/ns-ddr-header.constants.ts ***!
  \****************************************************************/
/*! exports provided: NS_DDR_HELP, DDR */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NS_DDR_HELP", function() { return NS_DDR_HELP; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DDR", function() { return DDR; });
const NS_DDR_HELP = {
    'URL Summary': 'urlSummary',
    'Transaction Summary': 'nsDdrTransaction',
    'Session Summary': 'pageSessionReport',
    'Page Summary': 'pageSummaryReport'
};
const DDR = {
    TIME_DURATION_FORMAT: 'time_duration',
    DURATION_DATA_TYPE: 1
};


/***/ }),

/***/ "./src/app/pages/ddr/custom-directive/area-hover-directive.ts":
/*!********************************************************************!*\
  !*** ./src/app/pages/ddr/custom-directive/area-hover-directive.ts ***!
  \********************************************************************/
/*! exports provided: MyAreaDirective */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MyAreaDirective", function() { return MyAreaDirective; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");


let MyAreaDirective = class MyAreaDirective {
    constructor(el) {
        this.el = el;
    }
    onmouseenter() {
        this.getToolTip(this.tooltipText);
    }
    getToolTip(value) {
        console.log('getToolTip() ~ agent type is ', this.agent);
        // Define file extension based on agent type
        let ext = this.agent && this.agent == "php" ? ".php" : this.agent === "Java" ? ".java" : "";
        let callOutType;
        let callOutCount;
        let backendName;
        let sourceMethod;
        let toolTipMessage;
        // Check if value indicates a callout
        if (value.indexOf('%%%') != -1) {
            let arr = value.split('%%%');
            callOutType = arr[0];
            sourceMethod = arr[1];
            // Determine backend name and callout count based on callout type
            switch (true) {
                case callOutType.startsWith('DB Error'):
                    backendName = arr[4];
                    callOutCount = 1;
                    break;
                case callOutType.startsWith('DB'):
                    backendName = arr[3];
                    callOutCount = arr[4].split(',').length;
                    break;
                case callOutType.startsWith('Error'):
                case callOutType.startsWith('Tier'):
                case callOutType.startsWith('Thread'):
                    backendName = arr[4];
                    callOutCount = 1;
                    break;
                case callOutType.startsWith('JMS'):
                    backendName = arr[3];
                    callOutCount = '';
                    break;
                case callOutType.startsWith('Exception'):
                    // Handle exceptions (if needed)
                    break;
                default:
                    backendName = arr[4];
                    callOutCount = 1;
            }
            // Construct tool tip message for callout
            if (!callOutType.startsWith('Exception'))
                toolTipMessage = callOutType + " CallOut, Source: " + sourceMethod;
            else
                toolTipMessage = callOutType + ", Source: " + sourceMethod;
            // Append backend name and callout count if available
            if (backendName != undefined && backendName != "" && Number(callOutCount) == 1)
                toolTipMessage += ", Integration Point: " + backendName;
            if (Number(callOutCount) > 1)
                toolTipMessage += ", Count: " + callOutCount + " times";
        }
        else {
            // Handle non-callout case
            toolTipMessage = value;
            let arrTemp = [];
            let arrTemp1 = [];
            arrTemp = value.split(',');
            arrTemp1 = arrTemp[0].split('.');
            // Extract wall time
            let wallTime = (arrTemp[1] != undefined && !isNaN(arrTemp[1])) ? Number(arrTemp[1]).toLocaleString() : '0';
            if (this.agent == "php") {
                let method = arrTemp[0].substring(arrTemp[0].lastIndexOf('.') + 1, arrTemp[0].length);
                let cls = arrTemp[0];
                if (arrTemp[2] != undefined) {
                    toolTipMessage = 'Class: ' + cls + ext + ', Method: ' + method + ', WallTime: ' + wallTime + ', StartTime: ' + this.startTime;
                }
                else {
                    toolTipMessage = 'Class: ' + cls + ext + ', Method: ' + method + ', WallTime: ' + wallTime;
                }
                this.el.nativeElement.setAttribute('title', toolTipMessage);
                return;
            }
            if (arrTemp1.length > 3) {
                if (arrTemp[0].indexOf('(') != -1) {
                    let method = arrTemp[0].substring(arrTemp[0].lastIndexOf('.') + 1, arrTemp[0].length);
                    let PkgClsStr = arrTemp[0].substring(0, arrTemp[0].lastIndexOf('.'));
                    let cls = PkgClsStr.substring(PkgClsStr.lastIndexOf('.') + 1, PkgClsStr.length);
                    let pkg = PkgClsStr.substring(0, PkgClsStr.lastIndexOf('.'));
                    if (arrTemp[2] != undefined) {
                        toolTipMessage = 'Package: ' + pkg + ', Class: ' + cls + ', Method: ' + method + ', WallTime: ' + wallTime + ', StartTime: ' + this.startTime;
                    }
                    else {
                        toolTipMessage = 'Package: ' + pkg + ', Class: ' + cls + ', Method: ' + method + ', WallTime: ' + wallTime;
                    }
                }
                else {
                    if (arrTemp[2] != undefined) {
                        toolTipMessage = 'Package: ' + value + ', StartTime: ' + this.startTime;
                    }
                    else {
                        toolTipMessage = 'Package: ' + value;
                    }
                }
            }
            else if (arrTemp1.length == 3) {
                if (arrTemp[2] != undefined) {
                    toolTipMessage = 'Package: ' + value + ', StartTime: ' + this.startTime;
                }
                else {
                    toolTipMessage = 'Package: ' + value;
                }
            }
            else {
                if (arrTemp[2] != undefined) {
                    toolTipMessage = 'Class: ' + value + `${ext}, StartTime: ` + this.startTime;
                }
                else {
                    toolTipMessage = 'Class: ' + value + ext;
                }
            }
        }
        this.el.nativeElement.setAttribute('title', toolTipMessage);
    }
};
MyAreaDirective.ctorParameters = () => [
    { type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('areaDirective')
], MyAreaDirective.prototype, "tooltipText", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], MyAreaDirective.prototype, "startTime", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])('id')
], MyAreaDirective.prototype, "id", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"])()
], MyAreaDirective.prototype, "agent", void 0);
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["HostListener"])('mouseenter')
], MyAreaDirective.prototype, "onmouseenter", null);
MyAreaDirective = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"])({
        selector: '[areaDirective]'
    })
], MyAreaDirective);



/***/ }),

/***/ "./src/app/pages/ddr/ddr.component.scss":
/*!**********************************************!*\
  !*** ./src/app/pages/ddr/ddr.component.scss ***!
  \**********************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("ddr-loading .blockedUI {\n  background: rgba(9, 9, 9, 0.52);\n  cursor: none;\n  z-index: 99999;\n  height: 100vh;\n  position: absolute;\n  width: 100%;\n  top: 0%;\n  left: 0px;\n}\nddr-loading .overlay {\n  position: fixed;\n  width: 100%;\n  height: 100%;\n  top: 69px;\n  left: 0;\n  background-color: rgba(255, 255, 255, 0.9);\n  z-index: 9999;\n}\nddr-loading .container {\n  align-items: center;\n  display: flex;\n  height: 100%;\n  justify-content: center;\n  width: 100%;\n}\nddr-loading .loadingIcon {\n  display: block;\n  margin-left: auto;\n  margin-right: auto;\n  height: 32px;\n  margin-top: 20%;\n}\nddr-loading .sidebarUI-container {\n  width: auto;\n}\nddr-loading .sidebarUI-sidenav {\n  margin-left: -1px;\n  margin-top: -1px;\n  margin-right: 4px;\n  min-height: 85vh;\n  padding: 2px;\n  border-radius: 4px;\n  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);\n  height: 100%;\n  background-color: transparent;\n  box-shadow: none !important;\n}\nddr-loading .sidenav {\n  margin-top: -23px;\n  margin-left: 7px;\n  color: var(--color_1);\n  cursor: pointer;\n  position: absolute;\n  z-index: 5;\n  display: inline-block;\n}\nddr-loading mat-sidenav-content.mat-drawer-content.mat-sidenav-content {\n  overflow: unset;\n}");

/***/ }),

/***/ "./src/app/pages/ddr/ddr.component.ts":
/*!********************************************!*\
  !*** ./src/app/pages/ddr/ddr.component.ts ***!
  \********************************************/
/*! exports provided: DdrComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrComponent", function() { return DdrComponent; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _services_common_services__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./services/common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/shared/time-bar/service/time-bar.service */ "./src/app/shared/time-bar/service/time-bar.service.ts");
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! rxjs/operators */ "./node_modules/rxjs/_esm2015/operators/index.js");
/* harmony import */ var src_app_shared_cav_nav_bar_cav_nav_bar_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! src/app/shared/cav-nav-bar/cav-nav-bar.service */ "./src/app/shared/cav-nav-bar/cav-nav-bar.service.ts");





//import { DdrDataModelService } from './services/ddr-data-model.service';






let DdrComponent = class DdrComponent {
    constructor(route, service, breadcrumb, commonServices, ddr_data, sessionService, timebarService, cavNavBarService) {
        this.route = route;
        this.service = service;
        this.breadcrumb = breadcrumb;
        this.commonServices = commonServices;
        this.ddr_data = ddr_data;
        this.sessionService = sessionService;
        this.timebarService = timebarService;
        this.cavNavBarService = cavNavBarService;
        this.title = 'app works!';
        this.showBreadcrumb = true;
        this.cavNavBarService.showNavBar = false;
        console.log('title===>', this.title, this.menuSideNav);
        this.changeNvToNd();
    }
    /**change the label from NV to ND */
    changeNvToNd() {
        try {
            let path = location.href;
            //let checkProduct = sessionStorage.getItem('productType');
            let checkProduct = this.sessionService.session.cctx.prodType;
            if (checkProduct == 'netstorm' || 'Netstorm') {
                document.title = 'Cavisson NetStorm';
            }
            else if (checkProduct == 'netdiagnostics' || "NetDiagnostics") {
                document.title = 'Cavisson NetDiagnostics Enterprise';
            }
            else if (checkProduct == 'netocean') {
                document.title = 'Cavisson NetOcean';
            }
            else if (checkProduct == 'netfunction') {
                document.title = 'Cavisson NetFunction';
            }
            else if (checkProduct == 'Netcloud' || checkProduct == 'netcloud') {
                document.title = 'Cavisson NetCloud';
            }
            else if (!checkProduct && (path.indexOf("/home/ddrCopyLink/") != -1)) {
                document.title = 'Cavisson NetDiagnostics Enterprise';
            }
            else {
                document.title = 'Cavisson NetVision';
            }
            console.log('document.title===>', document.title);
        }
        catch (error) {
            console.log('Error in changing the name', error);
        }
    }
    ngOnInit() {
        var _a, _b;
        this.route.events.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_9__["take"])(1)).subscribe((event) => {
            var _a;
            // if (event instanceof NavigationEnd) {
            if ((_a = event['url']) === null || _a === void 0 ? void 0 : _a.startsWith('/ddr/networkLogs')) {
                this.showBreadcrumb = false;
            }
            else
                this.showBreadcrumb = true;
            // }
        });
        if ((_b = (_a = this.route) === null || _a === void 0 ? void 0 : _a.url) === null || _b === void 0 ? void 0 : _b.startsWith('/ddr/networkLogs')) {
            this.showBreadcrumb = false;
        }
        else
            this.showBreadcrumb = true;
        if (this.ddr_data.isFromNV != "1") {
            this.breadcrumb.removeAll();
            this.breadcrumb.addNewBreadcrumb({ label: 'Home', routerLink: '/home' });
        }
        this.commonServices.closeUISideBarObservable$.subscribe((temp) => {
            if (this.menuSideNav)
                this.menuSideNav.close();
        });
    }
    openSideNav() {
        console.log('value in menusideNav===>', this.menuSideNav);
        console.log("flag of isToLoadSideBarAmannnnnn", this.commonServices.isToLoadSideBar);
        if (!this.menuSideNav.opened) {
            this.menuSideNav.open();
        }
        else {
            this.menuSideNav.close();
        }
    }
    onCloseSidebar() {
        try {
            this.menuSideNav.close();
        }
        catch (e) {
            console.log(e);
        }
    }
    ngOnDestroy() {
        //Called once, before the instance is destroyed.
        //Add 'implements OnDestroy' to the class.
        this.ddr_data.nsCQMFilter = {};
        //this.ddr_data.searchString="";
        this.commonServices.errMsg = undefined;
        this.ddr_data.resetDDRArguments();
        this.cavNavBarService.showNavBar = true;
    }
};
DdrComponent.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] },
    { type: _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_3__["DdrBreadcrumbService"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_7__["BreadcrumbService"] },
    { type: _services_common_services__WEBPACK_IMPORTED_MODULE_4__["CommonServices"] },
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_5__["DdrDataModelService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_6__["SessionService"] },
    { type: src_app_shared_time_bar_service_time_bar_service__WEBPACK_IMPORTED_MODULE_8__["TimebarService"] },
    { type: src_app_shared_cav_nav_bar_cav_nav_bar_service__WEBPACK_IMPORTED_MODULE_10__["CavNavBarService"] }
];
Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"])('navSideBar')
], DdrComponent.prototype, "menuSideNav", void 0);
DdrComponent = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"])({
        selector: 'ddr-loading',
        template: Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! raw-loader!./ddr.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/ddr/ddr.component.html")).default,
        encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
        styles: [Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__importDefault"])(__webpack_require__(/*! ./ddr.component.scss */ "./src/app/pages/ddr/ddr.component.scss")).default]
    })
], DdrComponent);



/***/ }),

/***/ "./src/app/pages/ddr/ddr.module.ts":
/*!*****************************************!*\
  !*** ./src/app/pages/ddr/ddr.module.ts ***!
  \*****************************************/
/*! exports provided: DdrModule */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrModule", function() { return DdrModule; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/common */ "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ "./node_modules/@angular/forms/__ivy_ngcc__/fesm2015/forms.js");
/* harmony import */ var _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./services/ddr-request.service */ "./src/app/pages/ddr/services/ddr-request.service.ts");
/* harmony import */ var _services_sql_query_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./services/sql-query.service */ "./src/app/pages/ddr/services/sql-query.service.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var src_app_shared_pipes_pipes_module__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/shared/pipes/pipes.module */ "./src/app/shared/pipes/pipes.module.ts");
/* harmony import */ var primeng__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! primeng */ "./node_modules/primeng/__ivy_ngcc__/fesm2015/primeng.js");
/* harmony import */ var _ddr_component__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./ddr.component */ "./src/app/pages/ddr/ddr.component.ts");
/* harmony import */ var _angular_material_slide_toggle__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/material/slide-toggle */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/slide-toggle.js");
/* harmony import */ var _angular_material_button_toggle__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/material/button-toggle */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/button-toggle.js");
/* harmony import */ var _angular_material_checkbox__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/material/checkbox */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/checkbox.js");
/* harmony import */ var _angular_material_button__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! @angular/material/button */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/button.js");
/* harmony import */ var _angular_material_card__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! @angular/material/card */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/card.js");
/* harmony import */ var _angular_material_menu__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! @angular/material/menu */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/menu.js");
/* harmony import */ var _angular_material_toolbar__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! @angular/material/toolbar */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/toolbar.js");
/* harmony import */ var _angular_material_icon__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! @angular/material/icon */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/icon.js");
/* harmony import */ var _angular_material_input__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! @angular/material/input */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/input.js");
/* harmony import */ var _angular_material_datepicker__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! @angular/material/datepicker */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/datepicker.js");
/* harmony import */ var _angular_material_core__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! @angular/material/core */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_material_progress_spinner__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! @angular/material/progress-spinner */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/progress-spinner.js");
/* harmony import */ var _angular_material_table__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! @angular/material/table */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/table.js");
/* harmony import */ var _angular_material_expansion__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! @angular/material/expansion */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/expansion.js");
/* harmony import */ var _angular_material_select__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! @angular/material/select */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/select.js");
/* harmony import */ var _angular_material_snack_bar__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! @angular/material/snack-bar */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/snack-bar.js");
/* harmony import */ var _angular_material_tooltip__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! @angular/material/tooltip */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/tooltip.js");
/* harmony import */ var _angular_material_chips__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! @angular/material/chips */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/chips.js");
/* harmony import */ var _angular_material_list__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! @angular/material/list */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/list.js");
/* harmony import */ var _angular_material_sidenav__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! @angular/material/sidenav */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/sidenav.js");
/* harmony import */ var _angular_material_tabs__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! @angular/material/tabs */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/tabs.js");
/* harmony import */ var _angular_material_progress_bar__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! @angular/material/progress-bar */ "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/progress-bar.js");
/* harmony import */ var _angular_cdk_clipboard__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! @angular/cdk/clipboard */ "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/clipboard.js");
/* harmony import */ var _components_weblogic_weblogic_component__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! ./components/weblogic/weblogic.component */ "./src/app/pages/ddr/components/weblogic/weblogic.component.ts");
/* harmony import */ var highcharts_angular__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(/*! highcharts-angular */ "./node_modules/highcharts-angular/__ivy_ngcc__/fesm2015/highcharts-angular.js");
/* harmony import */ var _routes_ddr_routes__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(/*! ./routes/ddr.routes */ "./src/app/pages/ddr/routes/ddr.routes.ts");
/* harmony import */ var src_app_shared_common_Tag_common_tag_module__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(/*! src/app/shared/common-Tag/common-tag.module */ "./src/app/shared/common-Tag/common-tag.module.ts");
/* harmony import */ var _components_flowpath_flowpath_component__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(/*! ./components/flowpath/flowpath.component */ "./src/app/pages/ddr/components/flowpath/flowpath.component.ts");
/* harmony import */ var _app_shared_common_config_module_common_module__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(/*! ../../../app/shared/common-config-module/common.module */ "./src/app/shared/common-config-module/common.module.ts");
/* harmony import */ var _components_ddr_bread_crumb_ddr_bread_crumb_component__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(/*! ./components/ddr-bread-crumb/ddr-bread-crumb.component */ "./src/app/pages/ddr/components/ddr-bread-crumb/ddr-bread-crumb.component.ts");
/* harmony import */ var _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(/*! ./services/ddr-breadcrumb.service */ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts");
/* harmony import */ var _components_ddr_side_view_ddr_side_view_component__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(/*! ./components/ddr-side-view/ddr-side-view.component */ "./src/app/pages/ddr/components/ddr-side-view/ddr-side-view.component.ts");
/* harmony import */ var _components_ddr_details_view_ddr_details_view_component__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(/*! ./components/ddr-details-view/ddr-details-view.component */ "./src/app/pages/ddr/components/ddr-details-view/ddr-details-view.component.ts");
/* harmony import */ var _components_ddr_paginator_ddr_paginator_component__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(/*! ./components/ddr-paginator/ddr-paginator.component */ "./src/app/pages/ddr/components/ddr-paginator/ddr-paginator.component.ts");
/* harmony import */ var _components_ddr_chart_ddr_chart_component__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(/*! ./components/ddr-chart/ddr-chart.component */ "./src/app/pages/ddr/components/ddr-chart/ddr-chart.component.ts");
/* harmony import */ var _custom_directive_area_hover_directive__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(/*! ./custom-directive/area-hover-directive */ "./src/app/pages/ddr/custom-directive/area-hover-directive.ts");
/* harmony import */ var _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(/*! ./services/ddr-message.service */ "./src/app/pages/ddr/services/ddr-message.service.ts");
/* harmony import */ var _components_ddr_side_bar_ddr_side_bar_component__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(/*! ./components/ddr-side-bar/ddr-side-bar.component */ "./src/app/pages/ddr/components/ddr-side-bar/ddr-side-bar.component.ts");
/* harmony import */ var _components_flowpath_group_by_flowpath_group_by_component__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(/*! ./components/flowpath-group-by/flowpath-group-by.component */ "./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.ts");
/* harmony import */ var _components_methodtiming_methodtiming_component__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(/*! ./components/methodtiming/methodtiming.component */ "./src/app/pages/ddr/components/methodtiming/methodtiming.component.ts");
/* harmony import */ var _components_db_group_by_db_group_by_component__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(/*! ./components/db-group-by/db-group-by.component */ "./src/app/pages/ddr/components/db-group-by/db-group-by.component.ts");
/* harmony import */ var _components_flowpath_analyzer_flowpath_analyzer_component__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(/*! ./components/flowpath-analyzer/flowpath-analyzer.component */ "./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.ts");
/* harmony import */ var _components_db_report_db_report_component__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(/*! ./components/db-report/db-report.component */ "./src/app/pages/ddr/components/db-report/db-report.component.ts");
/* harmony import */ var _components_fp_to_db_component_fp_to_db_component_component__WEBPACK_IMPORTED_MODULE_53__ = __webpack_require__(/*! ./components/fp-to-db-component/fp-to-db-component.component */ "./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.ts");
/* harmony import */ var _components_agg_ip_info_agg_ip_info_component__WEBPACK_IMPORTED_MODULE_54__ = __webpack_require__(/*! ./components/agg-ip-info/agg-ip-info.component */ "./src/app/pages/ddr/components/agg-ip-info/agg-ip-info.component.ts");
/* harmony import */ var _components_ip_summary_ip_summary_component__WEBPACK_IMPORTED_MODULE_55__ = __webpack_require__(/*! ./components/ip-summary/ip-summary.component */ "./src/app/pages/ddr/components/ip-summary/ip-summary.component.ts");
/* harmony import */ var _components_service_method_timing_service_method_timing_component__WEBPACK_IMPORTED_MODULE_56__ = __webpack_require__(/*! ./components/service-method-timing/service-method-timing.component */ "./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.ts");
/* harmony import */ var _components_exception_report_exception_report_component__WEBPACK_IMPORTED_MODULE_57__ = __webpack_require__(/*! ./components/exception-report/exception-report.component */ "./src/app/pages/ddr/components/exception-report/exception-report.component.ts");
/* harmony import */ var _components_http_req_resp_http_req_resp_component__WEBPACK_IMPORTED_MODULE_58__ = __webpack_require__(/*! ./components/http-req-resp/http-req-resp.component */ "./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.ts");
/* harmony import */ var _components_hotspot_hotspot_component__WEBPACK_IMPORTED_MODULE_59__ = __webpack_require__(/*! ./components/hotspot/hotspot.component */ "./src/app/pages/ddr/components/hotspot/hotspot.component.ts");
/* harmony import */ var _components_methodcallingtree_methodcallingtree_component__WEBPACK_IMPORTED_MODULE_60__ = __webpack_require__(/*! ./components/methodcallingtree/methodcallingtree.component */ "./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.ts");
/* harmony import */ var _components_sequence_diagram_sequence_diagram_component__WEBPACK_IMPORTED_MODULE_61__ = __webpack_require__(/*! ./components/sequence-diagram/sequence-diagram.component */ "./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.ts");
/* harmony import */ var _components_ddr_bt_trend_ddr_bt_trend_component__WEBPACK_IMPORTED_MODULE_62__ = __webpack_require__(/*! ./components/ddr-bt-trend/ddr-bt-trend.component */ "./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.ts");
/* harmony import */ var _components_ddr_compare_flowpath_ddr_compare_flowpath_component__WEBPACK_IMPORTED_MODULE_63__ = __webpack_require__(/*! ./components/ddr-compare-flowpath/ddr-compare-flowpath.component */ "./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.ts");
/* harmony import */ var _components_ddr_compare_queries_ddr_compare_queries_component__WEBPACK_IMPORTED_MODULE_64__ = __webpack_require__(/*! ./components/ddr-compare-queries/ddr-compare-queries.component */ "./src/app/pages/ddr/components/ddr-compare-queries/ddr-compare-queries.component.ts");
/* harmony import */ var _components_ddr_compare_methodtiming_ddr_compare_methodtiming_component__WEBPACK_IMPORTED_MODULE_65__ = __webpack_require__(/*! ./components/ddr-compare-methodtiming/ddr-compare-methodtiming.component */ "./src/app/pages/ddr/components/ddr-compare-methodtiming/ddr-compare-methodtiming.component.ts");
/* harmony import */ var _components_metadata_metadata_component__WEBPACK_IMPORTED_MODULE_66__ = __webpack_require__(/*! ./components/metadata/metadata.component */ "./src/app/pages/ddr/components/metadata/metadata.component.ts");
/* harmony import */ var _components_group_by_custom_data_group_by_custom_data_component__WEBPACK_IMPORTED_MODULE_67__ = __webpack_require__(/*! ./components/group-by-custom-data/group-by-custom-data.component */ "./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.ts");
/* harmony import */ var _components_ddr_agg_flowmap_ddr_agg_flowmap_component__WEBPACK_IMPORTED_MODULE_68__ = __webpack_require__(/*! ./components/ddr-agg-flowmap/ddr-agg-flowmap.component */ "./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.ts");
/* harmony import */ var _components_ddr_transaction_flowmap_ddr_transaction_flowmap_component__WEBPACK_IMPORTED_MODULE_69__ = __webpack_require__(/*! ./components/ddr-transaction-flowmap/ddr-transaction-flowmap.component */ "./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.ts");
/* harmony import */ var _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_70__ = __webpack_require__(/*! ./services/ddr-txn-flowmap-data.service */ "./src/app/pages/ddr/services/ddr-txn-flowmap-data.service.ts");
/* harmony import */ var _components_ddr_tier_merge_view_ddr_tier_merge_view_component__WEBPACK_IMPORTED_MODULE_71__ = __webpack_require__(/*! ./components/ddr-tier-merge-view/ddr-tier-merge-view.component */ "./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.ts");
/* harmony import */ var _services_ddr_transactio_individual_info_service__WEBPACK_IMPORTED_MODULE_72__ = __webpack_require__(/*! ./services/ddr-transactio-individual-info.service */ "./src/app/pages/ddr/services/ddr-transactio-individual-info.service.ts");
/* harmony import */ var _services_ddr_agg_flowmap_service__WEBPACK_IMPORTED_MODULE_73__ = __webpack_require__(/*! ./services/ddr-agg-flowmap.service */ "./src/app/pages/ddr/services/ddr-agg-flowmap.service.ts");
/* harmony import */ var _components_ddr_show_related_graph_ddr_show_related_graph_component__WEBPACK_IMPORTED_MODULE_74__ = __webpack_require__(/*! ./components/ddr-show-related-graph/ddr-show-related-graph.component */ "./src/app/pages/ddr/components/ddr-show-related-graph/ddr-show-related-graph.component.ts");
/* harmony import */ var _components_thread_hotspot_thread_hotspot_component__WEBPACK_IMPORTED_MODULE_75__ = __webpack_require__(/*! ./components/thread-hotspot/thread-hotspot.component */ "./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.ts");
/* harmony import */ var _components_thread_hotspot_nogrouping_nogrouping_component__WEBPACK_IMPORTED_MODULE_76__ = __webpack_require__(/*! ./components/thread-hotspot/nogrouping/nogrouping.component */ "./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.ts");
/* harmony import */ var _components_thread_hotspot_group_by_all_group_by_all_component__WEBPACK_IMPORTED_MODULE_77__ = __webpack_require__(/*! ./components/thread-hotspot/group-by-all/group-by-all.component */ "./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.ts");
/* harmony import */ var _components_thread_hotspot_group_by_custom_group_by_custom_component__WEBPACK_IMPORTED_MODULE_78__ = __webpack_require__(/*! ./components/thread-hotspot/group-by-custom/group-by-custom.component */ "./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.ts");
/* harmony import */ var _components_ip_stat_ip_stat_component__WEBPACK_IMPORTED_MODULE_79__ = __webpack_require__(/*! ./components/ip-stat/ip-stat.component */ "./src/app/pages/ddr/components/ip-stat/ip-stat.component.ts");
/* harmony import */ var _components_ddr_header_top_nav_bar_ddr_header_top_nav_bar__WEBPACK_IMPORTED_MODULE_80__ = __webpack_require__(/*! ./components/ddr-header-top-nav-bar/ddr-header-top-nav-bar */ "./src/app/pages/ddr/components/ddr-header-top-nav-bar/ddr-header-top-nav-bar.ts");
/* harmony import */ var _components_ns_reports_ns_reports_component__WEBPACK_IMPORTED_MODULE_81__ = __webpack_require__(/*! ./components/ns-reports/ns-reports.component */ "./src/app/pages/ddr/components/ns-reports/ns-reports.component.ts");
/* harmony import */ var _components_ns_reports_services_ns_common_service__WEBPACK_IMPORTED_MODULE_82__ = __webpack_require__(/*! ./components/ns-reports/services/ns-common-service */ "./src/app/pages/ddr/components/ns-reports/services/ns-common-service.ts");
/* harmony import */ var _components_ns_reports_ns_session_report_session_instance_report_session_instance_report_component__WEBPACK_IMPORTED_MODULE_83__ = __webpack_require__(/*! ./components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-instance-report/session-instance-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_session_report_ns_session_report_component__WEBPACK_IMPORTED_MODULE_84__ = __webpack_require__(/*! ./components/ns-reports/ns-session-report/ns-session-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/ns-session-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_session_report_session_failure_report_session_failure_report_component__WEBPACK_IMPORTED_MODULE_85__ = __webpack_require__(/*! ./components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-failure-report/session-failure-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_session_report_session_summary_report_session_summary_report_component__WEBPACK_IMPORTED_MODULE_86__ = __webpack_require__(/*! ./components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-summary-report/session-summary-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_session_report_session_detail_report_session_detail_report_component__WEBPACK_IMPORTED_MODULE_87__ = __webpack_require__(/*! ./components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-detail-report/session-detail-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_session_report_session_timing_detail_session_timing_detail_component__WEBPACK_IMPORTED_MODULE_88__ = __webpack_require__(/*! ./components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail.component.ts");
/* harmony import */ var _components_ns_reports_ns_session_report_session_timing_detail_session_timing_detail_panel_component__WEBPACK_IMPORTED_MODULE_89__ = __webpack_require__(/*! ./components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component */ "./src/app/pages/ddr/components/ns-reports/ns-session-report/session-timing-detail/session-timing-detail-panel.component.ts");
/* harmony import */ var _components_ns_reports_ns_page_report_ns_page_report_component__WEBPACK_IMPORTED_MODULE_90__ = __webpack_require__(/*! ./components/ns-reports/ns-page-report/ns-page-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/ns-page-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_page_report_page_summary_report_page_summary_report_component__WEBPACK_IMPORTED_MODULE_91__ = __webpack_require__(/*! ./components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-summary-report/page-summary-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_page_report_page_instance_report_page_instance_report_component__WEBPACK_IMPORTED_MODULE_92__ = __webpack_require__(/*! ./components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-instance-report/page-instance-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_page_report_page_failure_report_page_failure_report_component__WEBPACK_IMPORTED_MODULE_93__ = __webpack_require__(/*! ./components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-failure-report/page-failure-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_page_report_page_component_details_page_component_details_component__WEBPACK_IMPORTED_MODULE_94__ = __webpack_require__(/*! ./components/ns-reports/ns-page-report/page-component-details/page-component-details.component */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-component-details/page-component-details.component.ts");
/* harmony import */ var _components_ns_reports_ns_page_report_page_session_summary_page_session_summary_component__WEBPACK_IMPORTED_MODULE_95__ = __webpack_require__(/*! ./components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component */ "./src/app/pages/ddr/components/ns-reports/ns-page-report/page-session-summary/page-session-summary.component.ts");
/* harmony import */ var _components_ns_reports_ns_url_report_ns_url_report_component__WEBPACK_IMPORTED_MODULE_96__ = __webpack_require__(/*! ./components/ns-reports/ns-url-report/ns-url-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/ns-url-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_url_report_url_instance_report_url_instance_report_component__WEBPACK_IMPORTED_MODULE_97__ = __webpack_require__(/*! ./components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-instance-report/url-instance-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_url_report_url_summary_report_url_summary_report_component__WEBPACK_IMPORTED_MODULE_98__ = __webpack_require__(/*! ./components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-summary-report/url-summary-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_url_report_url_component_details_url_component_details_component__WEBPACK_IMPORTED_MODULE_99__ = __webpack_require__(/*! ./components/ns-reports/ns-url-report/url-component-details/url-component-details.component */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-component-details/url-component-details.component.ts");
/* harmony import */ var _components_ns_reports_ns_url_report_url_failure_report_url_failure_report_component__WEBPACK_IMPORTED_MODULE_100__ = __webpack_require__(/*! ./components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-failure-report/url-failure-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_url_report_url_session_summary_url_session_summary_component__WEBPACK_IMPORTED_MODULE_101__ = __webpack_require__(/*! ./components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component */ "./src/app/pages/ddr/components/ns-reports/ns-url-report/url-session-summary/url-session-summary.component.ts");
/* harmony import */ var _components_ns_reports_ns_transaction_report_ns_transaction_report_component__WEBPACK_IMPORTED_MODULE_102__ = __webpack_require__(/*! ./components/ns-reports/ns-transaction-report/ns-transaction-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/ns-transaction-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_transaction_report_transaction_instance_report_transaction_instance_report_component__WEBPACK_IMPORTED_MODULE_103__ = __webpack_require__(/*! ./components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-instance-report/transaction-instance-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_transaction_report_transaction_summary_report_transaction_summary_report_component__WEBPACK_IMPORTED_MODULE_104__ = __webpack_require__(/*! ./components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-summary-report/transaction-summary-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_transaction_report_transaction_failure_report_transaction_failure_report_component__WEBPACK_IMPORTED_MODULE_105__ = __webpack_require__(/*! ./components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-failure-report/transaction-failure-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_transaction_report_transaction_detail_report_transaction_details_report_component__WEBPACK_IMPORTED_MODULE_106__ = __webpack_require__(/*! ./components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-detail-report/transaction-details-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_transaction_report_transaction_session_summary_report_transaction_session_summary_report_component__WEBPACK_IMPORTED_MODULE_107__ = __webpack_require__(/*! ./components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-transaction-report/transaction-session-summary-report/transaction-session-summary-report.component.ts");
/* harmony import */ var _components_ns_reports_ns_usersessions_report_ns_usersessions_report_component__WEBPACK_IMPORTED_MODULE_108__ = __webpack_require__(/*! ./components/ns-reports/ns-usersessions-report/ns-usersessions-report.component */ "./src/app/pages/ddr/components/ns-reports/ns-usersessions-report/ns-usersessions-report.component.ts");
/* harmony import */ var src_app_shared_cav_table_cav_table_module__WEBPACK_IMPORTED_MODULE_109__ = __webpack_require__(/*! src/app/shared/cav-table/cav-table.module */ "./src/app/shared/cav-table/cav-table.module.ts");
/* harmony import */ var angular_split__WEBPACK_IMPORTED_MODULE_110__ = __webpack_require__(/*! angular-split */ "./node_modules/angular-split/__ivy_ngcc__/fesm2015/angular-split.js");
/* harmony import */ var src_app_shared_time_bar_time_bar_module__WEBPACK_IMPORTED_MODULE_111__ = __webpack_require__(/*! src/app/shared/time-bar/time-bar.module */ "./src/app/shared/time-bar/time-bar.module.ts");
/* harmony import */ var _dashboard_service_req_transaction_flowmap_transaction_flowmap_module__WEBPACK_IMPORTED_MODULE_112__ = __webpack_require__(/*! ../dashboard-service-req/transaction-flowmap/transaction-flowmap.module */ "./src/app/pages/dashboard-service-req/transaction-flowmap/transaction-flowmap.module.ts");
/* harmony import */ var src_app_shared_help_help_module__WEBPACK_IMPORTED_MODULE_113__ = __webpack_require__(/*! src/app/shared/help/help.module */ "./src/app/shared/help/help.module.ts");
/* harmony import */ var _components_ns_reports_services_ddr_http_service__WEBPACK_IMPORTED_MODULE_114__ = __webpack_require__(/*! ./components/ns-reports/services/ddr-http.service */ "./src/app/pages/ddr/components/ns-reports/services/ddr-http.service.ts");
/* harmony import */ var _components_ddr_split_view_ddr_split_view_component__WEBPACK_IMPORTED_MODULE_115__ = __webpack_require__(/*! ./components/ddr-split-view/ddr-split-view.component */ "./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.ts");
/* harmony import */ var _services_rrx_data_service__WEBPACK_IMPORTED_MODULE_116__ = __webpack_require__(/*! ./services/rrx-data.service */ "./src/app/pages/ddr/services/rrx-data.service.ts");
/* harmony import */ var _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_117__ = __webpack_require__(/*! ./services/nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _tools_admin_access_control_services_access_control_model__WEBPACK_IMPORTED_MODULE_118__ = __webpack_require__(/*! ../tools/admin/access-control/services/access-control.model */ "./src/app/pages/tools/admin/access-control/services/access-control.model.ts");
/* harmony import */ var _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_119__ = __webpack_require__(/*! ../tools/admin/access-control-management/constants/cav-acl-features.constants */ "./src/app/pages/tools/admin/access-control-management/constants/cav-acl-features.constants.ts");
/* harmony import */ var _components_trace_timeline_viewer_trace_timeline_viewer_component__WEBPACK_IMPORTED_MODULE_120__ = __webpack_require__(/*! ./components/trace-timeline-viewer/trace-timeline-viewer.component */ "./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.ts");
/* harmony import */ var src_app_shared_cav_loader_cav_loader_module__WEBPACK_IMPORTED_MODULE_121__ = __webpack_require__(/*! src/app/shared/cav-loader/cav-loader.module */ "./src/app/shared/cav-loader/cav-loader.module.ts");
/* harmony import */ var _components_transaction_service_map_transaction_service_map_component__WEBPACK_IMPORTED_MODULE_122__ = __webpack_require__(/*! ./components/transaction-service-map/transaction-service-map.component */ "./src/app/pages/ddr/components/transaction-service-map/transaction-service-map.component.ts");
/* harmony import */ var _components_otel_output_node_indices_otel_output_node_indices_component__WEBPACK_IMPORTED_MODULE_123__ = __webpack_require__(/*! ./components/otel-output-node-indices/otel-output-node-indices.component */ "./src/app/pages/ddr/components/otel-output-node-indices/otel-output-node-indices.component.ts");
/* harmony import */ var _jsplumbtoolkit_browser_ui_angular__WEBPACK_IMPORTED_MODULE_124__ = __webpack_require__(/*! @jsplumbtoolkit/browser-ui-angular */ "./node_modules/@jsplumbtoolkit/browser-ui-angular/__ivy_ngcc__/fesm2015/jsplumbtoolkit-browser-ui-angular.js");
/* harmony import */ var jsplumbtoolkit_angular_drop__WEBPACK_IMPORTED_MODULE_125__ = __webpack_require__(/*! jsplumbtoolkit-angular-drop */ "./node_modules/jsplumbtoolkit-angular-drop/__ivy_ngcc__/jsplumbtoolkit-angular-drop.js");
/* harmony import */ var src_app_shared_dashboard_widget_widget_menu_widget_submenu_widget_submenu_module__WEBPACK_IMPORTED_MODULE_126__ = __webpack_require__(/*! src/app/shared/dashboard/widget/widget-menu/widget-submenu/widget-submenu.module */ "./src/app/shared/dashboard/widget/widget-menu/widget-submenu/widget-submenu.module.ts");
/* harmony import */ var _components_method_call_info_method_call_info_component__WEBPACK_IMPORTED_MODULE_127__ = __webpack_require__(/*! ./components/method-call-info/method-call-info.component */ "./src/app/pages/ddr/components/method-call-info/method-call-info.component.ts");
/* harmony import */ var _components_trace_flamegraph_trace_flamegraph_component__WEBPACK_IMPORTED_MODULE_128__ = __webpack_require__(/*! ./components/trace-flamegraph/trace-flamegraph.component */ "./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.ts");
/* harmony import */ var ngx_monaco_editor__WEBPACK_IMPORTED_MODULE_129__ = __webpack_require__(/*! ngx-monaco-editor */ "./node_modules/ngx-monaco-editor/__ivy_ngcc__/fesm2015/ngx-monaco-editor.js");
/* harmony import */ var _components_otel_service_view_otel_service_view_component__WEBPACK_IMPORTED_MODULE_130__ = __webpack_require__(/*! ./components/otel-service-view/otel-service-view.component */ "./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.ts");

// Angular Imports







//import { StoreModule } from '@ngrx/store';
// BrowserXhr


// import { CommonServices } from './services/common.services';
//Material






















// import 'hammerjs';




// import { ChartModule } from 'angular2-highcharts';
// import {NoopAnimationsModule} from '@angular/platform-browser/animations';

/* Common Tag Module */



























/**
 * Compare Components
 */





/**
 * Transaction Flowmap Components & Services
 */







/**
 * Thread Hotspot Report Components
 */




// import { QueriesComponent } from './components/queries/queries.component';
// import { ExceptionComponent } from './components/exception/exception.component';
// import { DdrIntegratedFlowpathComponent } from './components/ddr-integrated-flowpath/ddr-integrated-flowpath.component';
// import { FlowpathBySignatureComponent } from './components/flowpath-by-signature/flowpath-by-signature.component';
// import { SqlByExecutionTimeComponent } from './components/sql-by-execution-time/sql-by-execution-time.component';
// import { SqlTimingComponent } from './components/sql-timing/sql-timing.component';


/**
 * NS Session Report Component
 */









/**
 * NS Page Report Component
 */






/**
 * NS URL Report Component
 */






/**
 * NS Transaction Report
 */






/**
 * user session
 */

/* cavTable */

/* Dynamic Diagnostics AI fron Config UI*/
// import { CommonComponentsModule } from '../../common-module/common.module';
// import { IbmHeapDumpAnalyserComponent } from './components/ibm-heap-analyser/ibm-heap-dump-analyser.component';
// import { HeapDumpAnalyserComponent } from './components/heap-analyser/heap-dump-analyser.component';
// import { ThreadDumpAnalyseComponent } from './components/thread-dump-analyse/thread-dump-analyse.component';
// import { CompareThreadDumpComponent } from './components/compare-thread-dump/compare-thread-dump.component';
// import { TakeThreadDumpComponent } from './components/take-thread-dump/take-thread-dump.component';
// import { ThreadDumpSummaryComponent } from './components/thread-dump-summary/thread-dump-summary.component';
// import { SystemDefinedComponent } from './components/system-defined/system-defined.component';
// import { GcManagerComponent } from './components/gcManager/gcManager.component';
// import { GcViewerComponent } from './components/gcViewer/gcViewer.component';
/**
 * Also commented in A9 migrated code
 */
// import { AppModuleForConfig } from '../../modules/nd-config/config.module';










// import { DynamicDiagnosticsComponent } from '../../common-module/components/dynamic-diagnostics/dynamic-diagnostics.component';
// import { DDRTreeTableModule } from '../../../vendors/prime-ng/treetable/treetable';











const routes = [
    {
        path: '', component: _ddr_component__WEBPACK_IMPORTED_MODULE_9__["DdrComponent"],
        children: [
            { path: '', redirectTo: 'ddr', pathMatch: 'full' },
            { path: 'main', component: _components_weblogic_weblogic_component__WEBPACK_IMPORTED_MODULE_33__["WeblogicComponent"] },
            { path: 'flowpath', component: _components_flowpath_flowpath_component__WEBPACK_IMPORTED_MODULE_37__["FlowpathComponent"] },
            { path: 'methodtiming', component: _components_methodtiming_methodtiming_component__WEBPACK_IMPORTED_MODULE_49__["MethodtimingComponent"] },
            { path: 'servicemethodtiming', component: _components_service_method_timing_service_method_timing_component__WEBPACK_IMPORTED_MODULE_56__["ServiceMethodTimingComponent"] },
            { path: 'Flowpathgroupby', component: _components_flowpath_group_by_flowpath_group_by_component__WEBPACK_IMPORTED_MODULE_48__["FlowpathGroupByComponent"] },
            { path: 'dbGroupBy', component: _components_db_group_by_db_group_by_component__WEBPACK_IMPORTED_MODULE_50__["DbGroupByComponent"] },
            { path: 'flowpathAnalyzer', component: _components_flowpath_analyzer_flowpath_analyzer_component__WEBPACK_IMPORTED_MODULE_51__["FlowpathAnalyzerComponent"] },
            { path: 'dbReport', component: _components_db_report_db_report_component__WEBPACK_IMPORTED_MODULE_52__["DbReportComponent"] },
            { path: 'flowpathToDB', component: _components_fp_to_db_component_fp_to_db_component_component__WEBPACK_IMPORTED_MODULE_53__["FpToDbComponentComponent"] },
            { path: 'ipsummary', component: _components_ip_summary_ip_summary_component__WEBPACK_IMPORTED_MODULE_55__["IpSummaryComponent"] },
            { path: 'exception', component: _components_exception_report_exception_report_component__WEBPACK_IMPORTED_MODULE_57__["ExceptionReportComponent"] },
            { path: 'httpReqResp', component: _components_http_req_resp_http_req_resp_component__WEBPACK_IMPORTED_MODULE_58__["HttpReqRespComponent"] },
            { path: 'hotspot', component: _components_hotspot_hotspot_component__WEBPACK_IMPORTED_MODULE_59__["HotspotComponent"] },
            { path: 'methodCallingTree', component: _components_methodcallingtree_methodcallingtree_component__WEBPACK_IMPORTED_MODULE_60__["MethodcallingtreeComponent"] },
            { path: 'sequencediagram/:param', component: _components_sequence_diagram_sequence_diagram_component__WEBPACK_IMPORTED_MODULE_61__["SequenceDiagramComponent"] },
            { path: 'Ddrtransactionflowpmap', component: _components_ddr_transaction_flowmap_ddr_transaction_flowmap_component__WEBPACK_IMPORTED_MODULE_69__["DdrTransactionFlowmapComponent"] },
            { path: 'DdrAggFlowmapComponent', component: _components_ddr_agg_flowmap_ddr_agg_flowmap_component__WEBPACK_IMPORTED_MODULE_68__["DdrAggFlowmapComponent"] },
            { path: 'DdrTierMergeViewComponent', component: _components_ddr_tier_merge_view_ddr_tier_merge_view_component__WEBPACK_IMPORTED_MODULE_71__["DdrTierMergeViewComponent"] },
            { path: 'flowpathToMD', component: _components_metadata_metadata_component__WEBPACK_IMPORTED_MODULE_66__["MetadataComponent"] },
            { path: 'DdrBtTrendComponent', component: _components_ddr_bt_trend_ddr_bt_trend_component__WEBPACK_IMPORTED_MODULE_62__["DdrBtTrendComponent"] },
            { path: 'CustomDataByBTSplitting', component: _components_group_by_custom_data_group_by_custom_data_component__WEBPACK_IMPORTED_MODULE_67__["GroupByCustomDataComponent"] },
            { path: 'threadhotspot', component: _components_thread_hotspot_thread_hotspot_component__WEBPACK_IMPORTED_MODULE_75__["ThreadHotspotComponent"] },
            { path: 'nogrouping', component: _components_thread_hotspot_nogrouping_nogrouping_component__WEBPACK_IMPORTED_MODULE_76__["NogroupingComponent"] },
            { path: 'allframe', component: _components_thread_hotspot_group_by_all_group_by_all_component__WEBPACK_IMPORTED_MODULE_77__["GroupByAllComponent"] },
            { path: 'customdepth', component: _components_thread_hotspot_group_by_custom_group_by_custom_component__WEBPACK_IMPORTED_MODULE_78__["GroupByCustomComponent"] },
            // { path: 'Flowpathbysignature', component: FlowpathBySignatureComponent },
            // { path: 'integratedFlowpath', component: DdrIntegratedFlowpathComponent },
            { path: 'IpStatComponent', component: _components_ip_stat_ip_stat_component__WEBPACK_IMPORTED_MODULE_79__["IpStatComponent"] },
            // { path: 'sqlByExecutionTime', component: SqlByExecutionTimeComponent },
            // { path: 'sqlTiming', component: SqlTimingComponent },
            { path: 'nsreports/:id', component: _components_ns_reports_ns_reports_component__WEBPACK_IMPORTED_MODULE_81__["NsReportsComponent"] },
        ]
    }
];
let DdrModule = class DdrModule {
    constructor() {
        console.log('DDR Module');
    }
};
DdrModule = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"])({
        imports: [
            //RouterModule.forChild(routes),
            //DDRRoutingModule,
            //DataTableModule,
            // BrowserModule,
            // BrowserAnimationsModule,
            // HttpClientModule,
            _dashboard_service_req_transaction_flowmap_transaction_flowmap_module__WEBPACK_IMPORTED_MODULE_112__["TransactionFlowmapModule"],
            _angular_common__WEBPACK_IMPORTED_MODULE_2__["CommonModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["TableModule"],
            _angular_forms__WEBPACK_IMPORTED_MODULE_3__["FormsModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["ButtonModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["ChipsModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["SplitButtonModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["DialogModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["DropdownModule"],
            _angular_router__WEBPACK_IMPORTED_MODULE_6__["RouterModule"].forChild(_routes_ddr_routes__WEBPACK_IMPORTED_MODULE_35__["DDR_ROUTES"]),
            primeng__WEBPACK_IMPORTED_MODULE_8__["TooltipModule"],
            highcharts_angular__WEBPACK_IMPORTED_MODULE_34__["HighchartsChartModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["AccordionModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["BlockUIModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["MultiSelectModule"],
            _angular_cdk_clipboard__WEBPACK_IMPORTED_MODULE_32__["ClipboardModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["PaginatorModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["ToolbarModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["TabViewModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["InputTextModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["ProgressBarModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["CalendarModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["RadioButtonModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["CheckboxModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["InputTextareaModule"],
            // GrowlModule,
            // NoopAnimationsModule,
            _angular_material_slide_toggle__WEBPACK_IMPORTED_MODULE_10__["MatSlideToggleModule"], _angular_material_button_toggle__WEBPACK_IMPORTED_MODULE_11__["MatButtonToggleModule"], _angular_material_checkbox__WEBPACK_IMPORTED_MODULE_12__["MatCheckboxModule"], _angular_material_button__WEBPACK_IMPORTED_MODULE_13__["MatButtonModule"],
            _angular_material_card__WEBPACK_IMPORTED_MODULE_14__["MatCardModule"], _angular_material_menu__WEBPACK_IMPORTED_MODULE_15__["MatMenuModule"], _angular_material_toolbar__WEBPACK_IMPORTED_MODULE_16__["MatToolbarModule"], _angular_material_icon__WEBPACK_IMPORTED_MODULE_17__["MatIconModule"], _angular_material_input__WEBPACK_IMPORTED_MODULE_18__["MatInputModule"],
            _angular_material_datepicker__WEBPACK_IMPORTED_MODULE_19__["MatDatepickerModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_20__["MatNativeDateModule"], _angular_material_progress_spinner__WEBPACK_IMPORTED_MODULE_21__["MatProgressSpinnerModule"], _angular_material_table__WEBPACK_IMPORTED_MODULE_22__["MatTableModule"],
            _angular_material_expansion__WEBPACK_IMPORTED_MODULE_23__["MatExpansionModule"], _angular_material_select__WEBPACK_IMPORTED_MODULE_24__["MatSelectModule"], _angular_material_snack_bar__WEBPACK_IMPORTED_MODULE_25__["MatSnackBarModule"], _angular_material_tooltip__WEBPACK_IMPORTED_MODULE_26__["MatTooltipModule"], _angular_material_chips__WEBPACK_IMPORTED_MODULE_27__["MatChipsModule"],
            _angular_material_list__WEBPACK_IMPORTED_MODULE_28__["MatListModule"], _angular_material_sidenav__WEBPACK_IMPORTED_MODULE_29__["MatSidenavModule"], _angular_material_tabs__WEBPACK_IMPORTED_MODULE_30__["MatTabsModule"], _angular_material_progress_bar__WEBPACK_IMPORTED_MODULE_31__["MatProgressBarModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["ContextMenuModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["TreeModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["BreadcrumbModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["TreeTableModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["SharedModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["ConfirmDialogModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["FieldsetModule"],
            _app_shared_common_config_module_common_module__WEBPACK_IMPORTED_MODULE_38__["CommonComponentsModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["AutoCompleteModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["PickListModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["InputSwitchModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["PanelModule"],
            // AppModuleForConfig,
            angular_split__WEBPACK_IMPORTED_MODULE_110__["AngularSplitModule"],
            // DDRTreeTableModule,
            primeng__WEBPACK_IMPORTED_MODULE_8__["FileUploadModule"],
            src_app_shared_time_bar_time_bar_module__WEBPACK_IMPORTED_MODULE_111__["TimeBarModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["CardModule"],
            src_app_shared_pipes_pipes_module__WEBPACK_IMPORTED_MODULE_7__["PipeModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["SidebarModule"],
            // StoreModule.forRoot({}),
            src_app_shared_common_Tag_common_tag_module__WEBPACK_IMPORTED_MODULE_36__["CommonTagModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["SidebarModule"],
            src_app_shared_help_help_module__WEBPACK_IMPORTED_MODULE_113__["HelpModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["MenuModule"],
            src_app_shared_cav_table_cav_table_module__WEBPACK_IMPORTED_MODULE_109__["CavTableModule"],
            primeng__WEBPACK_IMPORTED_MODULE_8__["ToastModule"],
            src_app_shared_cav_loader_cav_loader_module__WEBPACK_IMPORTED_MODULE_121__["CavLoaderModule"],
            _jsplumbtoolkit_browser_ui_angular__WEBPACK_IMPORTED_MODULE_124__["jsPlumbToolkitModule"],
            jsplumbtoolkit_angular_drop__WEBPACK_IMPORTED_MODULE_125__["jsPlumbToolkitDragDropModule"],
            src_app_shared_dashboard_widget_widget_menu_widget_submenu_widget_submenu_module__WEBPACK_IMPORTED_MODULE_126__["WidgetSubMenuModule"],
            ngx_monaco_editor__WEBPACK_IMPORTED_MODULE_129__["MonacoEditorModule"].forRoot()
        ],
        providers: [
            _components_ns_reports_services_ns_common_service__WEBPACK_IMPORTED_MODULE_82__["NsCommonService"],
            _services_ddr_transactio_individual_info_service__WEBPACK_IMPORTED_MODULE_72__["DdrTransactioIndividualInfoService"],
            _services_ddr_agg_flowmap_service__WEBPACK_IMPORTED_MODULE_73__["DdrAggFlowmapService"],
            _services_ddr_message_service__WEBPACK_IMPORTED_MODULE_46__["MessageService"],
            _services_ddr_txn_flowmap_data_service__WEBPACK_IMPORTED_MODULE_70__["DdrTxnFlowmapDataService"],
            // CommonServices,
            _services_rrx_data_service__WEBPACK_IMPORTED_MODULE_116__["RrxDataService"],
            _services_nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_117__["NdDdrHttpService"],
            _services_ddr_breadcrumb_service__WEBPACK_IMPORTED_MODULE_40__["DdrBreadcrumbService"],
            {
                provide: _angular_common__WEBPACK_IMPORTED_MODULE_2__["LocationStrategy"],
                useClass: _angular_common__WEBPACK_IMPORTED_MODULE_2__["HashLocationStrategy"]
            },
            primeng__WEBPACK_IMPORTED_MODULE_8__["ConfirmationService"],
            _services_sql_query_service__WEBPACK_IMPORTED_MODULE_5__["SqlQueryService"],
            _services_ddr_request_service__WEBPACK_IMPORTED_MODULE_4__["DDRRequestService"],
            _components_ns_reports_services_ddr_http_service__WEBPACK_IMPORTED_MODULE_114__["DDRHttpService"],
            { provide: _tools_admin_access_control_services_access_control_model__WEBPACK_IMPORTED_MODULE_118__["ACL_PROPS"], useValue: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_119__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_119__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS } }
        ],
        declarations: [
            _ddr_component__WEBPACK_IMPORTED_MODULE_9__["DdrComponent"],
            _components_weblogic_weblogic_component__WEBPACK_IMPORTED_MODULE_33__["WeblogicComponent"],
            _custom_directive_area_hover_directive__WEBPACK_IMPORTED_MODULE_45__["MyAreaDirective"],
            _components_ddr_bread_crumb_ddr_bread_crumb_component__WEBPACK_IMPORTED_MODULE_39__["DdrBreadCrumbComponent"],
            _components_ddr_split_view_ddr_split_view_component__WEBPACK_IMPORTED_MODULE_115__["DdrSplitViewComponent"],
            _components_ddr_side_view_ddr_side_view_component__WEBPACK_IMPORTED_MODULE_41__["DdrSideViewComponent"],
            _components_ddr_details_view_ddr_details_view_component__WEBPACK_IMPORTED_MODULE_42__["DdrDetailsViewComponent"],
            _components_ddr_side_bar_ddr_side_bar_component__WEBPACK_IMPORTED_MODULE_47__["DdrSideBarComponent"],
            _components_ddr_chart_ddr_chart_component__WEBPACK_IMPORTED_MODULE_44__["DdrChartComponent"],
            _components_ddr_paginator_ddr_paginator_component__WEBPACK_IMPORTED_MODULE_43__["DdrPaginator"],
            _components_flowpath_flowpath_component__WEBPACK_IMPORTED_MODULE_37__["FlowpathComponent"],
            _components_methodtiming_methodtiming_component__WEBPACK_IMPORTED_MODULE_49__["MethodtimingComponent"],
            _components_flowpath_group_by_flowpath_group_by_component__WEBPACK_IMPORTED_MODULE_48__["FlowpathGroupByComponent"],
            _components_db_group_by_db_group_by_component__WEBPACK_IMPORTED_MODULE_50__["DbGroupByComponent"],
            _components_flowpath_analyzer_flowpath_analyzer_component__WEBPACK_IMPORTED_MODULE_51__["FlowpathAnalyzerComponent"],
            _components_db_report_db_report_component__WEBPACK_IMPORTED_MODULE_52__["DbReportComponent"],
            _components_fp_to_db_component_fp_to_db_component_component__WEBPACK_IMPORTED_MODULE_53__["FpToDbComponentComponent"],
            _components_ip_summary_ip_summary_component__WEBPACK_IMPORTED_MODULE_55__["IpSummaryComponent"],
            _components_agg_ip_info_agg_ip_info_component__WEBPACK_IMPORTED_MODULE_54__["AggIpInfoComponent"],
            _components_service_method_timing_service_method_timing_component__WEBPACK_IMPORTED_MODULE_56__["ServiceMethodTimingComponent"],
            _components_exception_report_exception_report_component__WEBPACK_IMPORTED_MODULE_57__["ExceptionReportComponent"],
            _components_http_req_resp_http_req_resp_component__WEBPACK_IMPORTED_MODULE_58__["HttpReqRespComponent"],
            _components_hotspot_hotspot_component__WEBPACK_IMPORTED_MODULE_59__["HotspotComponent"],
            _components_methodcallingtree_methodcallingtree_component__WEBPACK_IMPORTED_MODULE_60__["MethodcallingtreeComponent"],
            _components_sequence_diagram_sequence_diagram_component__WEBPACK_IMPORTED_MODULE_61__["SequenceDiagramComponent"],
            _components_ddr_agg_flowmap_ddr_agg_flowmap_component__WEBPACK_IMPORTED_MODULE_68__["DdrAggFlowmapComponent"],
            _components_ddr_transaction_flowmap_ddr_transaction_flowmap_component__WEBPACK_IMPORTED_MODULE_69__["DdrTransactionFlowmapComponent"],
            _components_ddr_tier_merge_view_ddr_tier_merge_view_component__WEBPACK_IMPORTED_MODULE_71__["DdrTierMergeViewComponent"],
            _components_ddr_compare_flowpath_ddr_compare_flowpath_component__WEBPACK_IMPORTED_MODULE_63__["DdrCompareFlowpathComponent"],
            _components_ddr_compare_queries_ddr_compare_queries_component__WEBPACK_IMPORTED_MODULE_64__["DdrCompareQueriesComponent"],
            _components_ddr_compare_methodtiming_ddr_compare_methodtiming_component__WEBPACK_IMPORTED_MODULE_65__["DdrCompareMethodtimingComponent"],
            _components_metadata_metadata_component__WEBPACK_IMPORTED_MODULE_66__["MetadataComponent"],
            _components_ddr_bt_trend_ddr_bt_trend_component__WEBPACK_IMPORTED_MODULE_62__["DdrBtTrendComponent"],
            _components_group_by_custom_data_group_by_custom_data_component__WEBPACK_IMPORTED_MODULE_67__["GroupByCustomDataComponent"],
            _components_ddr_show_related_graph_ddr_show_related_graph_component__WEBPACK_IMPORTED_MODULE_74__["DdrShowRelatedGraphComponent"],
            _components_ip_stat_ip_stat_component__WEBPACK_IMPORTED_MODULE_79__["IpStatComponent"],
            _components_ddr_header_top_nav_bar_ddr_header_top_nav_bar__WEBPACK_IMPORTED_MODULE_80__["DdrHeaderTopNavBarComponent"],
            _components_thread_hotspot_thread_hotspot_component__WEBPACK_IMPORTED_MODULE_75__["ThreadHotspotComponent"],
            _components_thread_hotspot_nogrouping_nogrouping_component__WEBPACK_IMPORTED_MODULE_76__["NogroupingComponent"],
            _components_thread_hotspot_group_by_all_group_by_all_component__WEBPACK_IMPORTED_MODULE_77__["GroupByAllComponent"],
            _components_thread_hotspot_group_by_custom_group_by_custom_component__WEBPACK_IMPORTED_MODULE_78__["GroupByCustomComponent"],
            // SystemDefinedComponent,
            // FlowpathBySignatureComponent,
            // QueriesComponent,
            // DdrIntegratedFlowpathComponent,
            // SqlByExecutionTimeComponent,
            // SqlTimingComponent,
            // GcViewerComponent,
            /**
             * NS Session
             */
            _components_ns_reports_ns_session_report_session_failure_report_session_failure_report_component__WEBPACK_IMPORTED_MODULE_85__["SessionFailureReportComponent"],
            _components_ns_reports_ns_session_report_session_detail_report_session_detail_report_component__WEBPACK_IMPORTED_MODULE_87__["SessionDetailReportComponent"],
            _components_ns_reports_ns_session_report_session_timing_detail_session_timing_detail_component__WEBPACK_IMPORTED_MODULE_88__["SessionTimingDetailComponent"],
            _components_ns_reports_ns_session_report_session_timing_detail_session_timing_detail_panel_component__WEBPACK_IMPORTED_MODULE_89__["SessionTimingDetailPanelComponent"],
            _components_ns_reports_ns_reports_component__WEBPACK_IMPORTED_MODULE_81__["NsReportsComponent"],
            _components_ns_reports_ns_session_report_ns_session_report_component__WEBPACK_IMPORTED_MODULE_84__["NsSessionReportComponent"],
            _components_ns_reports_ns_session_report_session_instance_report_session_instance_report_component__WEBPACK_IMPORTED_MODULE_83__["SessionInstanceReportComponent"],
            _components_ns_reports_ns_session_report_session_summary_report_session_summary_report_component__WEBPACK_IMPORTED_MODULE_86__["SessionSummaryReportComponent"],
            /**
             * NS Page
             */
            _components_ns_reports_ns_page_report_page_summary_report_page_summary_report_component__WEBPACK_IMPORTED_MODULE_91__["PageSummaryReportComponent"],
            _components_ns_reports_ns_page_report_page_instance_report_page_instance_report_component__WEBPACK_IMPORTED_MODULE_92__["PageInstanceReportComponent"],
            _components_ns_reports_ns_page_report_page_failure_report_page_failure_report_component__WEBPACK_IMPORTED_MODULE_93__["PageFailureReportComponent"],
            _components_ns_reports_ns_page_report_page_component_details_page_component_details_component__WEBPACK_IMPORTED_MODULE_94__["PageComponentDetailsComponent"],
            _components_ns_reports_ns_page_report_page_session_summary_page_session_summary_component__WEBPACK_IMPORTED_MODULE_95__["PageSessionSummaryComponent"],
            _components_ns_reports_ns_page_report_ns_page_report_component__WEBPACK_IMPORTED_MODULE_90__["NsPageReportComponent"],
            /**
             * NS URL
             */
            _components_ns_reports_ns_url_report_url_summary_report_url_summary_report_component__WEBPACK_IMPORTED_MODULE_98__["UrlSummaryReportComponent"],
            _components_ns_reports_ns_url_report_url_instance_report_url_instance_report_component__WEBPACK_IMPORTED_MODULE_97__["UrlInstanceReportComponent"],
            _components_ns_reports_ns_url_report_url_component_details_url_component_details_component__WEBPACK_IMPORTED_MODULE_99__["UrlComponentDetailsComponent"],
            _components_ns_reports_ns_url_report_url_failure_report_url_failure_report_component__WEBPACK_IMPORTED_MODULE_100__["UrlFailureReportComponent"],
            _components_ns_reports_ns_url_report_url_session_summary_url_session_summary_component__WEBPACK_IMPORTED_MODULE_101__["UrlSessionSummaryComponent"],
            _components_ns_reports_ns_url_report_ns_url_report_component__WEBPACK_IMPORTED_MODULE_96__["NsUrlReportComponent"],
            /**
             * NS Transaction
             */
            _components_ns_reports_ns_transaction_report_transaction_instance_report_transaction_instance_report_component__WEBPACK_IMPORTED_MODULE_103__["TransactionInstanceReportComponent"],
            _components_ns_reports_ns_transaction_report_transaction_summary_report_transaction_summary_report_component__WEBPACK_IMPORTED_MODULE_104__["TransactionSummaryReportComponent"],
            _components_ns_reports_ns_transaction_report_transaction_session_summary_report_transaction_session_summary_report_component__WEBPACK_IMPORTED_MODULE_107__["TransactionSessionSummaryReportComponent"],
            _components_ns_reports_ns_transaction_report_transaction_failure_report_transaction_failure_report_component__WEBPACK_IMPORTED_MODULE_105__["TransactionFailureReportComponent"],
            _components_ns_reports_ns_transaction_report_transaction_detail_report_transaction_details_report_component__WEBPACK_IMPORTED_MODULE_106__["TransactionDetailsReportComponent"],
            _components_ns_reports_ns_transaction_report_ns_transaction_report_component__WEBPACK_IMPORTED_MODULE_102__["NsTransactionReportComponent"],
            _components_ns_reports_ns_usersessions_report_ns_usersessions_report_component__WEBPACK_IMPORTED_MODULE_108__["NsUsersessionsReportComponent"],
            _components_trace_timeline_viewer_trace_timeline_viewer_component__WEBPACK_IMPORTED_MODULE_120__["TraceTimelineViewerComponent"],
            _components_transaction_service_map_transaction_service_map_component__WEBPACK_IMPORTED_MODULE_122__["TransactionServiceMapComponent"],
            _components_otel_output_node_indices_otel_output_node_indices_component__WEBPACK_IMPORTED_MODULE_123__["OtelOutputNodeIndicesComponent"],
            _components_method_call_info_method_call_info_component__WEBPACK_IMPORTED_MODULE_127__["MethodCallInfoComponent"],
            _components_trace_flamegraph_trace_flamegraph_component__WEBPACK_IMPORTED_MODULE_128__["TraceFlamegraphComponent"],
            _components_otel_service_view_otel_service_view_component__WEBPACK_IMPORTED_MODULE_130__["OtelServiceViewComponent"],
        ],
        entryComponents: [
            _ddr_component__WEBPACK_IMPORTED_MODULE_9__["DdrComponent"]
        ],
        exports: [
            _ddr_component__WEBPACK_IMPORTED_MODULE_9__["DdrComponent"],
            _components_transaction_service_map_transaction_service_map_component__WEBPACK_IMPORTED_MODULE_122__["TransactionServiceMapComponent"],
            _components_otel_output_node_indices_otel_output_node_indices_component__WEBPACK_IMPORTED_MODULE_123__["OtelOutputNodeIndicesComponent"]
        ]
    })
], DdrModule);



/***/ }),

/***/ "./src/app/pages/ddr/routes/ddr.routes.ts":
/*!************************************************!*\
  !*** ./src/app/pages/ddr/routes/ddr.routes.ts ***!
  \************************************************/
/*! exports provided: DDR_ROUTES, DDRRoutingModule */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DDR_ROUTES", function() { return DDR_ROUTES; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DDRRoutingModule", function() { return DDRRoutingModule; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _components_weblogic_weblogic_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../components/weblogic/weblogic.component */ "./src/app/pages/ddr/components/weblogic/weblogic.component.ts");
/* harmony import */ var _ddr_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../ddr.component */ "./src/app/pages/ddr/ddr.component.ts");
/* harmony import */ var _components_flowpath_flowpath_component__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../components/flowpath/flowpath.component */ "./src/app/pages/ddr/components/flowpath/flowpath.component.ts");
/* harmony import */ var _components_methodtiming_methodtiming_component__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../components/methodtiming/methodtiming.component */ "./src/app/pages/ddr/components/methodtiming/methodtiming.component.ts");
/* harmony import */ var _components_service_method_timing_service_method_timing_component__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../components/service-method-timing/service-method-timing.component */ "./src/app/pages/ddr/components/service-method-timing/service-method-timing.component.ts");
/* harmony import */ var _components_flowpath_group_by_flowpath_group_by_component__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../components/flowpath-group-by/flowpath-group-by.component */ "./src/app/pages/ddr/components/flowpath-group-by/flowpath-group-by.component.ts");
/* harmony import */ var _components_db_group_by_db_group_by_component__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../components/db-group-by/db-group-by.component */ "./src/app/pages/ddr/components/db-group-by/db-group-by.component.ts");
/* harmony import */ var _components_flowpath_analyzer_flowpath_analyzer_component__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../components/flowpath-analyzer/flowpath-analyzer.component */ "./src/app/pages/ddr/components/flowpath-analyzer/flowpath-analyzer.component.ts");
/* harmony import */ var _components_db_report_db_report_component__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../components/db-report/db-report.component */ "./src/app/pages/ddr/components/db-report/db-report.component.ts");
/* harmony import */ var _components_ip_summary_ip_summary_component__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ../components/ip-summary/ip-summary.component */ "./src/app/pages/ddr/components/ip-summary/ip-summary.component.ts");
/* harmony import */ var _components_fp_to_db_component_fp_to_db_component_component__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ../components/fp-to-db-component/fp-to-db-component.component */ "./src/app/pages/ddr/components/fp-to-db-component/fp-to-db-component.component.ts");
/* harmony import */ var _components_exception_report_exception_report_component__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ../components/exception-report/exception-report.component */ "./src/app/pages/ddr/components/exception-report/exception-report.component.ts");
/* harmony import */ var _components_http_req_resp_http_req_resp_component__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ../components/http-req-resp/http-req-resp.component */ "./src/app/pages/ddr/components/http-req-resp/http-req-resp.component.ts");
/* harmony import */ var _components_hotspot_hotspot_component__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ../components/hotspot/hotspot.component */ "./src/app/pages/ddr/components/hotspot/hotspot.component.ts");
/* harmony import */ var _components_methodcallingtree_methodcallingtree_component__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ../components/methodcallingtree/methodcallingtree.component */ "./src/app/pages/ddr/components/methodcallingtree/methodcallingtree.component.ts");
/* harmony import */ var _components_sequence_diagram_sequence_diagram_component__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ../components/sequence-diagram/sequence-diagram.component */ "./src/app/pages/ddr/components/sequence-diagram/sequence-diagram.component.ts");
/* harmony import */ var _components_ddr_agg_flowmap_ddr_agg_flowmap_component__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ../components/ddr-agg-flowmap/ddr-agg-flowmap.component */ "./src/app/pages/ddr/components/ddr-agg-flowmap/ddr-agg-flowmap.component.ts");
/* harmony import */ var _components_ddr_tier_merge_view_ddr_tier_merge_view_component__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ../components/ddr-tier-merge-view/ddr-tier-merge-view.component */ "./src/app/pages/ddr/components/ddr-tier-merge-view/ddr-tier-merge-view.component.ts");
/* harmony import */ var _components_ddr_transaction_flowmap_ddr_transaction_flowmap_component__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ../components/ddr-transaction-flowmap/ddr-transaction-flowmap.component */ "./src/app/pages/ddr/components/ddr-transaction-flowmap/ddr-transaction-flowmap.component.ts");
/* harmony import */ var _components_metadata_metadata_component__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ../components/metadata/metadata.component */ "./src/app/pages/ddr/components/metadata/metadata.component.ts");
/* harmony import */ var _components_ddr_bt_trend_ddr_bt_trend_component__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ../components/ddr-bt-trend/ddr-bt-trend.component */ "./src/app/pages/ddr/components/ddr-bt-trend/ddr-bt-trend.component.ts");
/* harmony import */ var _components_group_by_custom_data_group_by_custom_data_component__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ../components/group-by-custom-data/group-by-custom-data.component */ "./src/app/pages/ddr/components/group-by-custom-data/group-by-custom-data.component.ts");
/* harmony import */ var _components_ddr_compare_flowpath_ddr_compare_flowpath_component__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ../components/ddr-compare-flowpath/ddr-compare-flowpath.component */ "./src/app/pages/ddr/components/ddr-compare-flowpath/ddr-compare-flowpath.component.ts");
/* harmony import */ var _components_thread_hotspot_thread_hotspot_component__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ../components/thread-hotspot/thread-hotspot.component */ "./src/app/pages/ddr/components/thread-hotspot/thread-hotspot.component.ts");
/* harmony import */ var _components_thread_hotspot_nogrouping_nogrouping_component__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ../components/thread-hotspot/nogrouping/nogrouping.component */ "./src/app/pages/ddr/components/thread-hotspot/nogrouping/nogrouping.component.ts");
/* harmony import */ var _components_thread_hotspot_group_by_all_group_by_all_component__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ../components/thread-hotspot/group-by-all/group-by-all.component */ "./src/app/pages/ddr/components/thread-hotspot/group-by-all/group-by-all.component.ts");
/* harmony import */ var _components_thread_hotspot_group_by_custom_group_by_custom_component__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ../components/thread-hotspot/group-by-custom/group-by-custom.component */ "./src/app/pages/ddr/components/thread-hotspot/group-by-custom/group-by-custom.component.ts");
/* harmony import */ var _components_ip_stat_ip_stat_component__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ../components/ip-stat/ip-stat.component */ "./src/app/pages/ddr/components/ip-stat/ip-stat.component.ts");
/* harmony import */ var _components_ns_reports_ns_reports_component__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! ../components/ns-reports/ns-reports.component */ "./src/app/pages/ddr/components/ns-reports/ns-reports.component.ts");
/* harmony import */ var _components_ddr_split_view_ddr_split_view_component__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ../components/ddr-split-view/ddr-split-view.component */ "./src/app/pages/ddr/components/ddr-split-view/ddr-split-view.component.ts");
/* harmony import */ var src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! src/app/core/guards/cav-acl-feature.guard */ "./src/app/core/guards/cav-acl-feature.guard.ts");
/* harmony import */ var _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(/*! ../../tools/admin/access-control-management/constants/cav-acl-features.constants */ "./src/app/pages/tools/admin/access-control-management/constants/cav-acl-features.constants.ts");
/* harmony import */ var _components_trace_timeline_viewer_trace_timeline_viewer_component__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(/*! ../components/trace-timeline-viewer/trace-timeline-viewer.component */ "./src/app/pages/ddr/components/trace-timeline-viewer/trace-timeline-viewer.component.ts");
/* harmony import */ var _components_method_call_info_method_call_info_component__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(/*! ../components/method-call-info/method-call-info.component */ "./src/app/pages/ddr/components/method-call-info/method-call-info.component.ts");
/* harmony import */ var _components_trace_flamegraph_trace_flamegraph_component__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(/*! ../components/trace-flamegraph/trace-flamegraph.component */ "./src/app/pages/ddr/components/trace-flamegraph/trace-flamegraph.component.ts");
/* harmony import */ var _components_otel_service_view_otel_service_view_component__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(/*! ../components/otel-service-view/otel-service-view.component */ "./src/app/pages/ddr/components/otel-service-view/otel-service-view.component.ts");

// import {Routes} from '@angular/router';





























// import { FlowpathBySignatureComponent} from "../components/flowpath-by-signature/flowpath-by-signature.component";
// import { DdrIntegratedFlowpathComponent } from '../components/ddr-integrated-flowpath/ddr-integrated-flowpath.component';


// import { SqlByExecutionTimeComponent } from '../components/sql-by-execution-time/sql-by-execution-time.component';
// import { SqlTimingComponent } from '../components/sql-timing/sql-timing.component';







// import { TakeThreadDumpComponent } from '../components/take-thread-dump/take-thread-dump.component';
// import { QueriesComponent } from '../components/queries/queries.component';
// import { HeapDumpAnalyserComponent } from '../components/heap-analyser/heap-dump-analyser.component';
// import { SystemDefinedComponent } from '../components/system-defined/system-defined.component';
// import { GcViewerComponent } from '../components/gcViewer/gcViewer.component';
// import { IbmHeapDumpAnalyserComponent } from '../components/ibm-heap-analyser/ibm-heap-dump-analyser.component';
// import { GcManagerComponent } from '../components/gcManager/gcManager.component';
const DDR_ROUTES = [
    {
        path: '', component: _ddr_component__WEBPACK_IMPORTED_MODULE_4__["DdrComponent"],
        children: [
            { path: '', redirectTo: 'ddr', pathMatch: 'full' },
            { path: 'main', component: _components_weblogic_weblogic_component__WEBPACK_IMPORTED_MODULE_3__["WeblogicComponent"] },
            {
                path: 'flowpath', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_flowpath_flowpath_component__WEBPACK_IMPORTED_MODULE_5__["FlowpathComponent"]
            },
            {
                path: 'methodtiming', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_methodtiming_methodtiming_component__WEBPACK_IMPORTED_MODULE_6__["MethodtimingComponent"]
            },
            {
                path: 'Flowpathgroupby', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_flowpath_group_by_flowpath_group_by_component__WEBPACK_IMPORTED_MODULE_8__["FlowpathGroupByComponent"]
            },
            {
                path: 'dbGroupBy', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_db_group_by_db_group_by_component__WEBPACK_IMPORTED_MODULE_9__["DbGroupByComponent"]
            },
            {
                path: 'flowpathAnalyzer', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_flowpath_analyzer_flowpath_analyzer_component__WEBPACK_IMPORTED_MODULE_10__["FlowpathAnalyzerComponent"]
            },
            {
                path: 'dbReport', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_db_report_db_report_component__WEBPACK_IMPORTED_MODULE_11__["DbReportComponent"]
            },
            {
                path: 'ipsummary', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_ip_summary_ip_summary_component__WEBPACK_IMPORTED_MODULE_12__["IpSummaryComponent"]
            },
            {
                path: 'flowpathToDB', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_fp_to_db_component_fp_to_db_component_component__WEBPACK_IMPORTED_MODULE_13__["FpToDbComponentComponent"]
            },
            {
                path: 'servicemethodtiming', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_service_method_timing_service_method_timing_component__WEBPACK_IMPORTED_MODULE_7__["ServiceMethodTimingComponent"]
            },
            {
                path: 'httpReqResp', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_http_req_resp_http_req_resp_component__WEBPACK_IMPORTED_MODULE_15__["HttpReqRespComponent"]
            },
            {
                path: 'hotspot', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_hotspot_hotspot_component__WEBPACK_IMPORTED_MODULE_16__["HotspotComponent"]
            },
            {
                path: 'exception', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_exception_report_exception_report_component__WEBPACK_IMPORTED_MODULE_14__["ExceptionReportComponent"]
            },
            {
                path: 'methodCallingTree', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_methodcallingtree_methodcallingtree_component__WEBPACK_IMPORTED_MODULE_17__["MethodcallingtreeComponent"]
            },
            {
                path: 'trace-viewer', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_trace_timeline_viewer_trace_timeline_viewer_component__WEBPACK_IMPORTED_MODULE_35__["TraceTimelineViewerComponent"]
            },
            {
                path: 'trace-flamegraph', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_trace_flamegraph_trace_flamegraph_component__WEBPACK_IMPORTED_MODULE_37__["TraceFlamegraphComponent"]
            },
            {
                path: 'otel-service-view', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_otel_service_view_otel_service_view_component__WEBPACK_IMPORTED_MODULE_38__["OtelServiceViewComponent"]
            },
            {
                path: 'method-call-info', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_method_call_info_method_call_info_component__WEBPACK_IMPORTED_MODULE_36__["MethodCallInfoComponent"]
            },
            {
                path: 'sequencediagram/:param', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_sequence_diagram_sequence_diagram_component__WEBPACK_IMPORTED_MODULE_18__["SequenceDiagramComponent"]
            },
            {
                path: 'Ddrtransactionflowpmap', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_ddr_transaction_flowmap_ddr_transaction_flowmap_component__WEBPACK_IMPORTED_MODULE_21__["DdrTransactionFlowmapComponent"]
            },
            {
                path: 'DdrAggFlowmapComponent', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_ddr_agg_flowmap_ddr_agg_flowmap_component__WEBPACK_IMPORTED_MODULE_19__["DdrAggFlowmapComponent"]
            },
            {
                path: 'DdrTierMergeViewComponent', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_ddr_tier_merge_view_ddr_tier_merge_view_component__WEBPACK_IMPORTED_MODULE_20__["DdrTierMergeViewComponent"]
            },
            {
                path: 'flowpathToMD', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_metadata_metadata_component__WEBPACK_IMPORTED_MODULE_22__["MetadataComponent"]
            },
            {
                path: 'DdrBtTrendComponent', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_ddr_bt_trend_ddr_bt_trend_component__WEBPACK_IMPORTED_MODULE_23__["DdrBtTrendComponent"]
            },
            {
                path: 'CustomDataByBTSplitting', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_group_by_custom_data_group_by_custom_data_component__WEBPACK_IMPORTED_MODULE_24__["GroupByCustomDataComponent"]
            },
            {
                path: 'DdrCompareFlowpath', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_ddr_compare_flowpath_ddr_compare_flowpath_component__WEBPACK_IMPORTED_MODULE_25__["DdrCompareFlowpathComponent"]
            },
            // { path: 'view', component: TakeThreadDumpComponent },
            // { path: 'query', component: QueriesComponent },
            {
                path: 'threadhotspot', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_thread_hotspot_thread_hotspot_component__WEBPACK_IMPORTED_MODULE_26__["ThreadHotspotComponent"]
            },
            {
                path: 'nogrouping', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_thread_hotspot_nogrouping_nogrouping_component__WEBPACK_IMPORTED_MODULE_27__["NogroupingComponent"]
            },
            {
                path: 'allframe', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_thread_hotspot_group_by_all_group_by_all_component__WEBPACK_IMPORTED_MODULE_28__["GroupByAllComponent"]
            },
            {
                path: 'customdepth', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_thread_hotspot_group_by_custom_group_by_custom_component__WEBPACK_IMPORTED_MODULE_29__["GroupByCustomComponent"]
            },
            // { path: 'Flowpathbysignature', component: FlowpathBySignatureComponent },
            // { path: 'integratedFlowpath', component: DdrIntegratedFlowpathComponent },
            {
                path: 'IpStatComponent', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_ip_stat_ip_stat_component__WEBPACK_IMPORTED_MODULE_30__["IpStatComponent"]
            },
            {
                path: 'nsreports/:id',
                canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].DASHBOARDS.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].DASHBOARDS.SUB_FEATURES.REPORTS },
                component: _components_ns_reports_ns_reports_component__WEBPACK_IMPORTED_MODULE_31__["NsReportsComponent"]
            },
            // { path: 'sqlByExecutionTime', component: SqlByExecutionTimeComponent },
            // { path: 'sqlTiming', component: SqlTimingComponent },
            {
                path: 'DdrSplitview', canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].APM.SUB_FEATURES.DRILL_DOWN_REPORTS }, component: _components_ddr_split_view_ddr_split_view_component__WEBPACK_IMPORTED_MODULE_32__["DdrSplitViewComponent"]
            },
            // { path: 'heapAnalyser', component: HeapDumpAnalyserComponent },
            // { path: 'ibmheapAnalyser', component: IbmHeapDumpAnalyserComponent },
            // { path: 'sysdef', component: SystemDefinedComponent },
            // { path: 'gcViewer', component: GcViewerComponent },
            // { path: 'gcManager', component: GcManagerComponent }
            {
                path: 'networkLogs',
                canActivate: [src_app_core_guards_cav_acl_feature_guard__WEBPACK_IMPORTED_MODULE_33__["CavACLFeatureGuard"]],
                data: { feature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].LOAD_TEST.NAME, subFeature: _tools_admin_access_control_management_constants_cav_acl_features_constants__WEBPACK_IMPORTED_MODULE_34__["CAV_FEATURES"].LOAD_TEST.SUB_FEATURES.TEST_EXECUTION },
                loadChildren: () => __webpack_require__.e(/*! import() | components-page-dump-revamped-page-dump-module */ "components-page-dump-revamped-page-dump-module").then(__webpack_require__.bind(null, /*! ../components/page-dump-revamped/page-dump.module */ "./src/app/pages/ddr/components/page-dump-revamped/page-dump.module.ts")).then((m) => m.PageDumpModule)
            }
        ]
    }
];
let DDRRoutingModule = class DDRRoutingModule {
};
DDRRoutingModule = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"])({
        imports: [_angular_router__WEBPACK_IMPORTED_MODULE_2__["RouterModule"].forChild(DDR_ROUTES)],
        // imports: [RouterModule.forRoot(routes)],
        exports: [_angular_router__WEBPACK_IMPORTED_MODULE_2__["RouterModule"]]
    })
], DDRRoutingModule);



/***/ }),

/***/ "./src/app/pages/ddr/services/ddr-agg-flowmap.service.ts":
/*!***************************************************************!*\
  !*** ./src/app/pages/ddr/services/ddr-agg-flowmap.service.ts ***!
  \***************************************************************/
/*! exports provided: DdrAggFlowmapService */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrAggFlowmapService", function() { return DdrAggFlowmapService; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");
/* harmony import */ var _common_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/core/breadcrumb/breadcrumb.service */ "./src/app/core/breadcrumb/breadcrumb.service.ts");
/* harmony import */ var _nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");







let DdrAggFlowmapService = class DdrAggFlowmapService {
    constructor(_router, CommonServices, breadcrumbService, ndDdrHttpService) {
        this._router = _router;
        this.CommonServices = CommonServices;
        this.breadcrumbService = breadcrumbService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.mergeJson = {}; //to hold the flowpath's data in json format
        this.jsonData = []; //final json to draw UI 
        this.jsonDataForTierMergetoView = [];
        this.jonDataForTierMergeToDraw = [];
        this.mergeRFData = [];
        this.mergeChildData = {};
        this.mapOfIt = {};
        this.btName = "";
        this.isRefreshCase = false;
        this.tierName = "";
        this.mergeBts = {};
        this.mergeTiers = {};
        this.mergeServers = {};
        this.mergeapps = {};
        this.mergeIps = {};
        /**
         * this method creates the map of ids for all the elemnts in json for agg
         */
        this.mapofIDs = {};
        this.mapOfRIds = {};
        this.mapOfUsedTiers = {};
        this.idForBackends = 1000;
        this.tempJson = [];
        this.processItLater = [];
    }
    /*
    *This method get keyword for view agg flopmap
    */
    getKeyForView() {
        this.ndDdrHttpService.getenableAggFlowmap().subscribe((state) => {
            if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_6__["enableAggviewLoadedState"]) {
                let data = state.data;
                this.enableAggView = data.enableAggView;
            }
        });
    }
    /*
     *This method creates final json from json which is recieved from server
     */
    createFirstLevelJson(url) {
        return new Promise((resolve, reject) => {
            this.mergeJson = {};
            this.initJson;
            this.jsonData = [];
            this.jsonDataForTierMergetoView = [];
            this.jonDataForTierMergeToDraw = [];
            this.mergeRFData = [];
            this.mergeChildData = {};
            this.mapOfIt = {};
            this.mergeBts = {};
            this.mergeTiers = {};
            this.mergeServers = {};
            this.mergeapps = {};
            this.mergeIps = {};
            this.mapofIDs = {};
            this.mapOfRIds = {};
            this.idForBackends = 1000;
            this.parentTierID = "";
            this.mapOfUsedTiers = {};
            this.tempJson = [];
            this.processItLater = [];
            url = url || sessionStorage.getItem("aggUrl");
            if (url) {
                sessionStorage.setItem("aggUrl", url);
            }
            this.ndDdrHttpService.getAggTrxFlowMapData(url).subscribe((state) => {
                if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_6__["AggTrxFlowMapLoadedState"]) {
                    let data = state.data;
                    this.jsonData = [];
                    for (let i = 0; i < data.length; i++) {
                        if (data[i].hasOwnProperty('ERROR')) {
                            data.splice(i, 1);
                        }
                    }
                    this.initJson = data;
                    this.mergeDCData();
                    //iterating the childs to create parent and child relationsship json
                    if (Object.keys(this.mergeChildData).length > 0 && Object.keys(this.mergeChildData).length == this.mergeRFData.length) {
                        Object.keys(this.mergeChildData).forEach((k, i) => {
                            this.createCPrelation(k, this.mergeRFData, this.mergeChildData);
                        });
                    }
                    else if ((Object.keys(this.mergeChildData).length > 0 && Object.keys(this.mergeChildData).length < this.mergeRFData.length)) {
                        for (let i = 0; i < this.mergeRFData.length; i++) {
                            let isChildPresent = false;
                            isChildPresent = this.checkChildPresentForRP(this.mergeRFData[i]["F"]);
                            if (isChildPresent) {
                                this.createCPrelation(this.mergeRFData[i]["F"], this.mergeRFData, this.mergeChildData);
                            }
                            else {
                                this.createCPrelation(this.mergeRFData[i]["F"], this.mergeRFData, this.mergeChildData);
                            }
                        }
                    }
                    else {
                        this.mergeRFData.map((obj, i) => {
                            this.createCPrelation(obj.F, this.mergeRFData, this.mergeChildData);
                        });
                    }
                    this.createIdforJson();
                    this.creteSourceIdforJson();
                    this.createJsonForTierMerge();
                    this.filterOutUnusedTiers();
                    this.createChildForTiers();
                    this.mergeChildWithTiers();
                    this.createCordinatesTierMerge();
                    this.mergeAllTierData();
                    this.CommonServices.spinner = false;
                    this.breadcrumbService.add({ label: 'Aggregate Transaction Flowmap', routerLink: '/ddr/DdrTierMergeViewComponent' });
                    if (this.CommonServices.isFromEd) {
                        if (this.isRefreshCase) {
                            this._router.navigate(['/ddr/DdrAggFlowmapComponent']);
                        }
                        else {
                            this._router.navigate(['/ddr/DdrTierMergeViewComponent']);
                        }
                    }
                    else {
                        if (this.isRefreshCase) {
                            this._router.navigate(['/ddr/DdrAggFlowmapComponent']);
                        }
                        else {
                            this._router.navigate(['/ddr/DdrTierMergeViewComponent']);
                        }
                    }
                    resolve(this.jsonDataForTierMergetoView);
                }
            });
        });
    }
    /**
    * Merges data from the 'initJson' array into different properties:
    * - Merges child data into 'mergeChildData'.
    * - Merges root FpMiss status.
    * - Merges RF data into 'mergeRFData'.
    * - Merges BTS data into 'mergeBts'.
    * - Merges application data into 'mergeapps'.
    * - Merges tier data into 'mergeTiers'.
    * - Merges server data into 'mergeServers'.
    * - Merges IPS data into 'mergeIps'.
    *
    * If the 'data' array of an element in 'initJson' is empty for all elements and
    * the 'rootFpMiss' flag is set for the last element, sets 'rootFpMiss' to true.
    */
    mergeDCData() {
        this.mergeRFData = [];
        this.mergeChildData = {};
        this.mergeBts = {};
        let len = this.initJson.length;
        for (let i = 0; i < len; i++) {
            let data = this.initJson[i]["data"]["0"];
            if (data.length > 0 && data.length >= Object.keys(this.initJson[i]["data"]).length - 1) {
                this.rootFpMiss = false;
                break;
            }
            else if (data.length == 0 && i == len - 1) {
                this.rootFpMiss = true;
                return;
            }
            else
                this.rootFpMiss = true;
        }
        for (let i = 0; i < len; i++) {
            if (!this.initJson[i]["data"])
                continue;
            let data = this.initJson[i]["data"]["0"];
            let childData = this.initJson[i]["data"];
            delete childData['0'];
            let btData = this.initJson[i]["bts"];
            let serverData = this.initJson[i]["srvrs"];
            let tierData = this.initJson[i]["tiers"];
            let appData = this.initJson[i]["insts"];
            let ipsData = this.initJson[i]["ips"];
            if (Object.entries(childData).length > 0 && childData.constructor === Object) {
                if (Object.keys(this.mergeChildData).length > 0) {
                    Object.keys(this.mergeChildData).forEach(element => {
                        for (let k in childData) {
                            if (element == k) {
                                this.mergeChildData[element] = [...this.mergeChildData[element], ...childData[k]];
                            }
                        }
                    });
                }
                else {
                    this.mergeChildData = Object.assign(childData, this.mergeChildData);
                }
            }
            if (data.length > 0)
                this.mergeRFData = [...this.mergeRFData, ...data];
            if (Object.entries(btData).length > 0)
                this.mergeBts = Object.assign(Object.assign({}, this.mergeBts), btData);
            if (Object.entries(appData).length > 0)
                this.mergeapps = Object.assign(Object.assign({}, this.mergeapps), appData);
            if (Object.entries(tierData).length > 0)
                this.mergeTiers = Object.assign(Object.assign({}, this.mergeTiers), tierData);
            if (Object.entries(serverData).length > 0)
                this.mergeServers = Object.assign(Object.assign({}, this.mergeServers), serverData);
            if (ipsData) {
                if (Object.entries(ipsData).length > 0)
                    this.mergeIps = Object.assign(Object.assign({}, this.mergeIps), ipsData);
            }
        }
    }
    /**
    * Creates a child-parent relationship JSON.
    *
    * @param parent The parent object identifier.
    * @param child The list of child objects.
    * @param childDetail Details of child objects.
    *
    * This method creates a single JSON object representing the relationship between a parent and its children.
    *
    * Parent: Objects from the list other than data[0].
    * Child: Object from data[0] which will be connected from the entry node.
    *
    * Properties:
    * - isFromEntry: Indicates if the child is from the entry node.
    * - cType: Type of the child (e.g., 'P' for parent).
    * - pBCount: Parent's backend count.
    * - pCCount: Parent's child count.
    * - F: Identifier of the parent object.
    * - pCount: Parent's count.
    */
    createCPrelation(parent, child, childDetail) {
        let keys = Object.keys(child); // Get the keys of the child object
        for (let i = 0; i < keys.length; i++) {
            if (parent == child[i]["F"]) { // Check if the parent matches the current child's 'F' property
                // Update the child properties
                child[i]["isFromEntry"] = true; // Indicates child is from the entry node
                child[i]["cType"] = "P"; // Type of the child (e.g., 'P' for parent)
                child[i]["pBCount"] = child[i]["ipc"]; // Parent's backend count
                // Update pCCount if parent details are available
                if (childDetail[parent])
                    child[i]["pCCount"] = childDetail[parent].length;
                this.mapOfIt[child[i]["tI"]] = child[i]["iT"];
                this.jsonData.push(child[i]);
                if (child[i]["ipc"] && child[i]["ipc"] > 0 && child[i]["ips"]) {
                    this.createBackend(child[i], child[i]["ipc"], i, child[i]["tI"]);
                }
                if (childDetail[parent] && childDetail[parent].length > 0)
                    this.creteChildForParent(childDetail[parent], parent);
                break;
            }
            else {
                if (i == keys.length - 1) {
                    let obj = { "F": parent, "cType": "OP", "isFromEntry": true, "pCount": childDetail[parent].length };
                    this.jsonData.push(obj);
                    if (childDetail[parent].length > 0)
                        this.creteChildForParent(childDetail[parent], parent);
                }
                else {
                    continue;
                }
            }
        }
    }
    /**
    * Appends backends in JSON for a parent.
    *
    * @param obj The parent object (data[0]).
    * @param ipCount Number of backends.
    * @param index Index of the parent object.
    * @param tI Identifier of the parent object.
    *
    * obj: Parent object (data[0]).
    * ipCount: Number of backends.
    */
    createBackend(obj, ipCount, index, tI) {
        let objNew = obj["ips"]; // Extract the list of backends from the parent object
        objNew.sort(this.compare); // Sort the backends
        let lastType = "";
        let lastId = "";
        for (let i = 0; i < objNew.length; i++) {
            let str = (objNew[i].D).toString();
            // If the backend contains a '-' in its string representation, skip it
            if (str.indexOf("-") != -1) {
                continue;
            }
            // If it's the first backend
            if (i == 0) {
                // Set properties for the backend
                objNew[i]["cType"] = "PB"; // Type of the backend
                lastType = objNew[i]["t"]; // Store the type for comparison
                lastId = objNew[i]["i"]; // Store the ID for comparison
                objNew[i]["count"] = 1; // Initialize count to 1
                objNew[i]["tI"] = tI; // Set the identifier of the parent object
                this.jsonData.push(objNew[i]); // Push the backend object into the JSON data array
            }
            else {
                // If it's not the first backend
                if (lastType == objNew[i]["t"] && objNew[i]["i"] == lastId) {
                    this.jsonData[this.jsonData.length - 1]["count"] = Number(this.jsonData[this.jsonData.length - 1]["count"]) + 1;
                    this.jsonData[this.jsonData.length - 1]["D"] = Number(this.jsonData[this.jsonData.length - 1]["D"]) + Number(objNew[i]["D"]);
                }
                else {
                    // If the backend type or ID is different from the previous one
                    objNew[i]["cType"] = "PB"; // Set the backend type
                    lastType = objNew[i]["t"]; // Update the type for comparison
                    lastId = objNew[i]["i"]; // Update the ID for comparison
                    objNew[i]["count"] = 1; // Initialize count to 1
                    objNew[i]["tI"] = tI; // Set the identifier of the parent object
                    this.jsonData.push(objNew[i]); // Push the backend object into the JSON data array
                }
            }
        }
    }
    /**
    * Creates children for a parent object.
    *
    * @param obj Data representing children (data[flowpathkeys]).
    * @param parent Identifier of the parent object.
    *
    * obj: Data representing children (data[flowpathkeys]).
    */
    creteChildForParent(obj, parent) {
        for (let i = 0; i < obj.length; i++) {
            if (parent == obj[i]["F"]) {
                console.log("do nothing"); // Skip if the object is the parent itself
            }
            else {
                obj[i]["cType"] = "C"; // Type of the child
                obj[i]["cBCount"] = obj[i]["ipc"]; // Child's backend count
                obj[i]["count"] = 1; // Initialize count to 1
                this.jsonData.push(obj[i]); // Push the child object into the JSON data array
                // If child has backends, create backends for the child
                if (obj[i]["ipc"] > 0 && obj[i]["ips"] != undefined) {
                    this.createBackendForChild(obj[i]["ips"], obj[i]["tI"]);
                }
            }
        }
    }
    /**
    * Creates backends for child objects.
    *
    * @param obj CalloutObj of the child object.
    * @param tI tierId.
    */
    createBackendForChild(obj, tI) {
        obj.sort(this.compare); // Sort Intergration points
        let lastType = "";
        for (let i = 0; i < obj.length; i++) {
            let str = (obj[i].D).toString();
            if (str.indexOf("-") != -1) {
                continue; // Skip if the backend contains '-'
            }
            if (i == 0) {
                obj[i]["cType"] = "CB"; // Type of the backend for child
                lastType = obj[i]["t"]; // Store the type for comparison
                obj[i]["count"] = 1; // Initialize count to 1
                obj[i]["tI"] = tI; // Set the tierId of the child object
                this.jsonData.push(obj[i]); // Push the backend object into the JSON data array
            }
            else {
                // If the backend type matches the previous one, increment the count
                if (lastType == obj[i]["t"]) {
                    this.jsonData[this.jsonData.length - 1]["count"] = Number(this.jsonData[this.jsonData.length - 1]["count"]) + 1;
                    this.jsonData[this.jsonData.length - 1]["D"] = Number(this.jsonData[this.jsonData.length - 1]["D"]) + Number(obj[i]["D"]);
                }
                else {
                    obj[i]["cType"] = "CB"; // Type of the backend for child
                    lastType = obj[i]["t"]; // Update the type for comparison
                    obj[i]["count"] = 1; // Initialize count to 1
                    obj[i]["tI"] = tI; // Set the tierId of the child object
                    this.jsonData.push(obj[i]); // Push the backend object into the JSON data array
                }
            }
        }
    }
    /**
    * Comparator function for sorting.
    */
    compare(a, b) {
        if (a.t < b.t)
            return -1;
        if (a.t > b.t)
            return 1;
        return 0;
    }
    /**
     * this method creates the soucrce id and target id for every node
     * these ids used by js plumb to make a connecton
     * Target id is same as as its id od node
     * To Do -  this method will also add some info to every node like instance type, servername , app name , instance name
     */
    creteSourceIdforJson() {
        let lastPId = 0;
        let lastChildId = 0;
        let childCount = 0;
        let levelCount = 2;
        let flag = false;
        let lim = 0;
        let left = 300;
        let top = 0;
        let tempT = 0;
        // Logic to position nodes based on their type
        this.jsonData.forEach((obj, index) => {
            childCount = 0;
            if (obj["cType"] == "PB" || obj["cType"] == "CB" || obj["cType"] == "C") {
                lim++;
                if (lim == 1) {
                    left = 300 * levelCount;
                    top = top - 100;
                }
                else if (lim <= 3) {
                    top = top + 100;
                    if (lim == 3) {
                        flag = true;
                        tempT = top;
                    }
                }
                else {
                    lim = 1;
                    tempT = top;
                    levelCount++;
                    left = 300 * levelCount;
                    top = top - 150;
                    flag = true;
                }
            }
            if (obj['isFromEntry'] == true && (obj["cType"] == "P" || obj["cType"] == "OP")) {
                lim = 0;
                left = 300;
                levelCount = 2;
                if (flag)
                    top = tempT;
                flag = false;
                top = top + 200;
                obj['sourceId'] = "root";
                lastPId = obj["id"];
                obj["sN"] = this.getServerName(obj["sI"]);
                obj["aN"] = this.getAppName(obj["aI"]);
                obj["tN"] = this.getTierName(obj["tI"]);
                childCount = obj["pBCount"] + obj["pCCount"];
                obj['left'] = left + 'px';
                obj['top'] = top + 'px';
                obj["icon"] = (obj.iT).toString().toUpperCase() + "new.png";
                obj["displayName"] = obj["sN"] + ":" + obj["aN"];
            }
            else if (obj["cType"] == "PB") {
                // Set source ID for parent backend nodes
                obj['left'] = left + 'px';
                obj['top'] = top + 'px';
                obj['sourceId'] = lastPId;
                obj["icon"] = this.setIconForIpcalls(obj);
                obj["displayName"] = this.setIpNames(obj.i);
            }
            else if (obj["cType"] == "C") {
                // Set source ID for child nodes
                obj['left'] = left + 'px';
                obj['top'] = top + 'px';
                obj['sourceId'] = this.setId(obj);
                lastChildId = obj['id'];
                obj["sN"] = this.getServerName(obj["sI"]);
                obj["aN"] = this.getAppName(obj["aI"]);
                obj["tN"] = this.getTierName(obj["tI"]);
                obj["icon"] = (obj.iT).toString().toUpperCase() + "new.png";
                obj["displayName"] = obj["sN"] + ":" + obj["aN"];
            }
            else if (obj["cType"] == "CB") {
                // Set source ID for child backend nodes
                obj['left'] = left + 'px';
                obj['top'] = top + 'px';
                obj['sourceId'] = lastChildId;
                obj["icon"] = this.setIconForIpcalls(obj);
                obj["displayName"] = this.setIpNames(obj.i);
            }
        });
    }
    getServerName(id) { return this.mergeServers[id]; }
    getAppName(id) { return this.mergeapps[id]; }
    getTierName(id) { return this.mergeTiers[id]; }
    createIdforJson() {
        let count = 0;
        this.jsonData.forEach(obj => {
            obj["id"] = count;
            obj["targetId"] = count;
            if (obj.cType == "P" || obj.cType == "OP" || obj.cType == "C") {
                this.mapofIDs[obj.F] = count;
            }
            if (obj.cType == "P" || obj.cType == "OP") {
                this.mapOfRIds[obj.F] = count;
            }
            count++;
        });
    }
    /**
     *
     * @param obj this method sets the source id for every object
     */
    setId(obj) {
        if (this.mapofIDs[obj.jpF] && this.mapofIDs[obj.jpF] != undefined) {
            return this.mapofIDs[obj.jpF];
        }
        else {
            return this.mapOfRIds[obj.pF];
        }
    }
    setIconForIpcalls(obj) {
        let type = obj.t;
        if (type == 2 || type == 10) //checking For DB callOut && supporting ADO.Net BackendType (10 for ADO.Net)
         {
            return "DATABASEnew.png";
        }
        else if (type == 9) //checking Cassandra DB callOut
         {
            return "CASSANDRAnew.png";
        }
        else if (type == 15) {
            return "MONGODBnew.png";
        }
        else if (type == 16) {
            return "REDISnew.png";
        }
        else if (type == 19) {
            return "DATABASEnew.png";
        }
        else if (type == 22) //checking ftp callOut
         {
            return "FTPnew.png";
        }
        else if (type == 23) //checking ftp callOut
         {
            return "KAFKAnew.png";
        }
        else if (type == -3) //checking ftp callOut
         {
            return "BACKENDnew.png";
        }
        else {
            return "backend.png";
        }
    }
    //This function is used to set backedtype according to the type
    getBackendTypeName(backendType) {
        var backendTypeName = "OTHER";
        if (backendType == 1)
            return "HTTP";
        else if (backendType == 2)
            return "JDBC";
        else if (backendType == 3)
            return "COHERENCE";
        else if (backendType == 4)
            return "RMI";
        else if (backendType == 5)
            return "MemCache";
        else if (backendType == 6)
            return "CLOUDANT";
        else if (backendType == 7)
            return "HADOOP";
        else if (backendType == 9)
            return "CASSANDRA";
        else if (backendType == 10)
            return "ADO.NET";
        else if (backendType == 11)
            return "IBM_MQ";
        else if (backendType == 12)
            return "ACTIVE_MQ";
        else if (backendType == 13)
            return "RABBIT_MQ";
        else if (backendType == 15)
            return "MongoDB";
        else if (backendType == 16)
            return "Redis";
        else if (backendType == 14)
            return "JMS_ATG";
        else if (backendType == 19)
            return "CLOUDANT_DB";
        else if (backendType == 22)
            return "FTP";
        else if (backendType == 23)
            return "KAFKA";
        else if (backendType == -3)
            return "Thread";
        else if (backendType == -1)
            return "Thread";
        else if (backendType == -5)
            return "Async";
        else
            return backendTypeName;
    }
    setIpNames(obj) {
        return this.encodeHTMLStr(this.mergeIps[obj]);
    }
    //This method is used to encode HTML characters
    encodeHTMLStr(str) {
        var returnString = "";
        if (str != undefined && str != "")
            returnString = str.toString().replace(/&#044;/g, ",").replace(/&#58;/g, ":").replace(/&#46;/g, ".").replace(/&#010;/g, "\n").replace(/&#039;/g, "\'")
                .replace(/&#034;/g, "\"").replace(/&#092;/g, "\\").replace(/&#124;/g, "|").replace(/&#123;/g, "{").replace(/&#125;/g, "}").replace(/&#126;/g, "~").replace(/&#11/g, "").replace(/&#12/g, "");
        return returnString;
    }
    /**
     * this method creates the json  to merge the tiers
     */
    createJsonForTierMerge() {
        this.tempJson = [];
        this.createIDForTiers();
        let parent;
        let lastTi;
        this.jsonData.forEach((obj) => {
            if ((obj.F) && (obj.pF) && (obj.pF == 0 || obj.F == obj.pF)) {
                lastTi = obj["tI"];
                parent = obj;
                return;
            }
            else if (obj.cType == "C") {
                lastTi = obj["tI"];
            }
            else if (obj.cType == "PB" || obj.cType == "CB") {
                let newObj = JSON.parse(JSON.stringify(obj));
                newObj["tI"] = lastTi;
                this.mergeChildsForTiers(newObj);
                // this.tempJson.push(newObj);
            }
        });
        this.checkAndCreateJson();
        // console.log("jsonfortiermerge", this.jonDataForTierMergeToDraw)
    }
    /**
     * this method creates json fot tier merge view data
     * @param obj t
     * @param parent
     */
    checkAndCreateJson() {
        let newObj;
        let lastParent;
        this.jsonData.map((val) => {
            newObj = null;
            if ((val.cType == "P" || val.cType == "OP") && (val.pF == 0 || val.pF == val.F)) {
                lastParent = val;
                this.parentTierID = val["tI"];
                this.valiateBt(val, val);
            }
            else if (val.cType == "C") {
                newObj = this.getParent(val);
                if (!newObj) {
                    newObj = lastParent;
                }
                this.parentTierID = newObj["tI"];
                this.valiateBt(val, newObj);
            }
        });
    }
    /**
     * this method creates id for all the tiers.
     */
    createIDForTiers() {
        let count = 0;
        for (let i = 0; i < this.jsonData.length; i++) {
            for (let prop in this.mergeTiers) {
                if (this.jsonData[i].tI == prop && this.jsonData[i].tN) {
                    let obj = { "tI": prop, "id": count, "cType": this.jsonData[i].cType };
                    this.jsonDataForTierMergetoView.push(obj);
                    count++;
                }
            }
            // if(this.jsonDataForTierMergetoView.length == Object.keys(this.mergeTiers).length){
            //   break;
            // }
        }
    }
    valiateBt(obj, newObj) {
        if (this.jonDataForTierMergeToDraw.length > 0) {
            let index = this.checkForParent(this.parentTierID, obj["tI"], obj["btI"]);
            if (index == undefined) {
                let objFr = {};
                objFr["tI"] = obj["tI"];
                objFr["tN"] = this.getTierName(objFr["tI"]);
                if (obj["sourceId"] == 'root') {
                    objFr["sourceId"] = "root";
                }
                else
                    objFr["sourceId"] = this.returnSourceID(newObj["tI"]);
                objFr["targetID"] = this.returnTargetID(obj["tI"]);
                objFr["BtID"] = obj["btI"];
                objFr["count"] = 1;
                objFr["Tduration"] = obj["D"];
                objFr["AvgDuration"] = obj["D"];
                objFr["pTi"] = this.parentTierID;
                objFr["icon"] = obj["icon"];
                objFr["erc"] = obj["erc"];
                this.jonDataForTierMergeToDraw.push(objFr);
                this.mapOfUsedTiers[objFr["sourceId"]] = true;
                this.mapOfUsedTiers[objFr["targetID"]] = true;
            }
            else {
                let objFr = {};
                let val = this.jonDataForTierMergeToDraw[index];
                if (val["tI"] == obj["tI"] && val["BtID"] == obj["btI"] && val["pTi"] == this.parentTierID) {
                    val["count"] = val["count"] + 1;
                    val["Tduration"] = val["Tduration"] + obj["D"];
                    if (obj.erc != undefined && !isNaN(obj.erc))
                        val["erc"] = Number(val["erc"]) + Number(obj["erc"]);
                    val["AvgDuration"] = val["Tduration"] / val["count"];
                }
                else if (val["tI"] == obj["tI"] && val["BtID"] == obj["btI"] && val["pTi"] != this.parentTierID) {
                    objFr["tI"] = obj["tI"];
                    if (obj["sourceId"] == 'root') {
                        objFr["sourceId"] = "root";
                    }
                    else
                        objFr["sourceId"] = this.returnSourceID(newObj["tI"]);
                    objFr["targetID"] = this.returnTargetID(obj["tI"]);
                    objFr["BtID"] = obj["btI"];
                    objFr["count"] = 1;
                    objFr["Tduration"] = obj["D"];
                    objFr["AvgDuration"] = obj["D"];
                    objFr["pTi"] = this.parentTierID;
                    objFr["tN"] = this.getTierName(objFr["tI"]);
                    objFr["tN"] = this.getTierName(objFr["tI"]);
                    objFr["icon"] = obj["icon"];
                    objFr["erc"] = obj["erc"];
                    this.jonDataForTierMergeToDraw.push(objFr);
                    this.mapOfUsedTiers[objFr["sourceId"]] = true;
                    this.mapOfUsedTiers[objFr["targetID"]] = true;
                }
                else if (val["tI"] == obj["tI"] && val["BtID"] != obj["btI"]) {
                    objFr["tI"] = obj["tI"];
                    if (obj["sourceId"] == 'root') {
                        objFr["sourceId"] = "root";
                    }
                    else
                        objFr["sourceId"] = this.returnSourceID(newObj["tI"]);
                    objFr["targetID"] = this.returnTargetID(obj["tI"]);
                    objFr["BtID"] = obj["btI"];
                    objFr["count"] = 1;
                    objFr["Tduration"] = obj["D"];
                    objFr["AvgDuration"] = obj["D"];
                    objFr["tN"] = this.getTierName(objFr["tI"]);
                    objFr["icon"] = obj["icon"];
                    objFr["erc"] = obj["erc"];
                    this.jonDataForTierMergeToDraw.push(objFr);
                    this.mapOfUsedTiers[objFr["sourceId"]] = true;
                    this.mapOfUsedTiers[objFr["targetID"]] = true;
                }
                else {
                    objFr["tI"] = obj["tI"];
                    if (obj["sourceId"] == 'root') {
                        objFr["sourceId"] = "root";
                    }
                    else
                        objFr["sourceId"] = this.returnSourceID(newObj["tI"]);
                    objFr["targetID"] = this.returnTargetID(obj["tI"]);
                    objFr["BtID"] = obj["btI"];
                    objFr["count"] = 1;
                    objFr["Tduration"] = obj["D"];
                    objFr["AvgDuration"] = obj["D"];
                    objFr["tN"] = this.getTierName(objFr["tI"]);
                    objFr["icon"] = obj["icon"];
                    objFr["erc"] = obj["erc"];
                    this.jonDataForTierMergeToDraw.push(objFr);
                    this.mapOfUsedTiers[objFr["sourceId"]] = true;
                    this.mapOfUsedTiers[objFr["targetID"]] = true;
                }
            }
        }
        else {
            let objFr = {};
            objFr["tI"] = obj["tI"];
            objFr["tN"] = this.getTierName(objFr["tI"]);
            if (obj["sourceId"] == 'root') {
                objFr["sourceId"] = "root";
            }
            else
                objFr["sourceId"] = this.returnSourceID(newObj["tI"]);
            objFr["targetID"] = this.returnTargetID(obj["tI"]);
            objFr["BtID"] = obj["btI"];
            objFr["count"] = 1;
            objFr["Tduration"] = obj["D"];
            objFr["AvgDuration"] = obj["D"];
            objFr["pTi"] = this.parentTierID;
            objFr["icon"] = obj["icon"];
            objFr["erc"] = obj["erc"];
            this.jonDataForTierMergeToDraw.push(objFr);
            this.mapOfUsedTiers[objFr["sourceId"]] = true;
            this.mapOfUsedTiers[objFr["targetID"]] = true;
        }
    }
    returnSourceID(id) {
        let tierID;
        let len = this.jsonDataForTierMergetoView.length;
        for (let i = 0; i <= len - 1; i++) {
            if (this.jsonDataForTierMergetoView[i]["tI"] == id) {
                tierID = this.jsonDataForTierMergetoView[i]["id"];
                break;
            }
        }
        return tierID;
    }
    returnTargetID(id) {
        let tierID;
        let len = this.jsonDataForTierMergetoView.length;
        for (let i = 0; i <= len - 1; i++) {
            if (this.jsonDataForTierMergetoView[i]["tI"] == id) {
                tierID = this.jsonDataForTierMergetoView[i]["id"];
                break;
            }
        }
        return tierID;
    }
    checkForParent(pTid, tId, btId) {
        let id;
        let len = this.jonDataForTierMergeToDraw.length;
        for (let i = 0; i <= len - 1; i++) {
            if (this.jonDataForTierMergeToDraw[i]["tI"] == tId && this.jonDataForTierMergeToDraw[i]["pTi"] == pTid && this.jonDataForTierMergeToDraw[i]["BtID"] == btId) {
                id = i;
                break;
            }
        }
        return id;
    }
    /**
     * this method creates coordinates of for the  tier boxes.
     */
    createCordinatesTierMerge() {
        let lim = 0;
        let leftTr = 580;
        let leftback = 0;
        let topTr = -80;
        let topback = 0;
        let positionTr = 1;
        let positionback = 1;
        this.arrangeInParentChildForm(this.jsonDataForTierMergetoView).then(() => {
            this.jsonDataForTierMergetoView.forEach((obj, index) => {
                if ((obj["cType"] == "P" || obj["cType"] == "OP" || obj["cType"] == "C")) {
                    obj["icon"] = this.returnIconForTier(obj["tI"]);
                    obj["tierClass"] = true;
                    obj["ovalClass"] = false;
                    lim = 0;
                    if (positionTr == 1) {
                        if (topback > 0 && topback > topTr)
                            topTr = topback + 160;
                        else
                            topTr = topTr + 200;
                        leftTr = leftTr - 210;
                        positionTr = 0;
                        topback = topTr;
                        leftback = leftTr;
                    }
                    else {
                        if (topback > 0 && topback > topTr)
                            topTr = topback + 160;
                        else
                            topTr = topTr + 200;
                        leftTr = leftTr + 220;
                        positionTr = 1;
                        topback = topTr;
                        leftback = leftTr;
                    }
                    obj['left'] = leftTr + 'px';
                    obj['top'] = topTr + 'px';
                    positionback = 1;
                    topback = topback - 140;
                    leftback = leftback + 600;
                }
                else {
                    if (positionback == 1) {
                        topback = topback + 40;
                        leftback = leftback - 160;
                        positionback = 0;
                    }
                    else {
                        topback = topback + 40;
                        leftback = leftback + 160;
                        positionback = 1;
                    }
                    obj["tierClass"] = false;
                    obj["ovalClass"] = true;
                    obj['left'] = leftback + 'px';
                    obj['top'] = topback + 'px';
                }
            });
        });
    }
    arrangeInParentChildForm(obj) {
        return new Promise((resolve, reject) => {
            try {
                let newObj = [];
                let count = 0;
                obj.forEach((valu, index) => {
                    if (valu["cType"] == "P" || valu["cType"] == "OP" || valu["cType"] == "C") {
                        newObj[count] = valu;
                        count++;
                        obj.forEach((val) => {
                            if (valu["tI"] == val["tI"] && !(val["cType"] == "P" || val["cType"] == "OP" || val["cType"] == "C")) {
                                newObj[count] = val;
                                count++;
                            }
                        });
                        if (count == obj.length) {
                            resolve();
                        }
                    }
                });
                if (this.jsonDataForTierMergetoView.length == newObj.length) {
                    this.jsonDataForTierMergetoView = newObj;
                    resolve();
                }
                else {
                    resolve();
                }
            }
            catch (e) {
                console.error("Error in arrangeInParentChildForm() ", e);
                resolve();
            }
        });
    }
    /**
     * this method  remove those tiers from json , where there in no transactions,
     * on the basis of used tiers map (mapOfUsedTiers)
     */
    filterOutUnusedTiers() {
        let temp = [];
        this.jsonDataForTierMergetoView.forEach((obj) => {
            let val = this.mapOfUsedTiers[obj.id];
            if (val) {
                obj["tN"] = this.getTierName(obj.tI);
                temp.push(obj);
            }
        });
        this.jsonDataForTierMergetoView = temp;
    }
    createChildForTiers() {
        this.tempJson.forEach((objNew) => {
            objNew["targetID"] = this.idForBackends;
            objNew["id"] = this.idForBackends;
            this.idForBackends++;
            if (this.jonDataForTierMergeToDraw.length > 0) {
                for (let i = 0; i < this.jonDataForTierMergeToDraw.length; i++) {
                    if (objNew["tI"] == this.jonDataForTierMergeToDraw[i]["tI"]) {
                        objNew["sourceId"] = this.jonDataForTierMergeToDraw[i]["targetID"];
                        break;
                    }
                }
            }
        });
    }
    mergeChildWithTiers() {
        this.jonDataForTierMergeToDraw = [...this.jonDataForTierMergeToDraw, ...this.tempJson];
        this.jsonDataForTierMergetoView = [...this.jsonDataForTierMergetoView, ...this.tempJson];
    }
    mergeChildsForTiers(obj) {
        if (this.tempJson.length < 1) {
            obj["AvgD"] = obj["D"] / obj["count"];
            obj["count"] = (obj["count"] || 1);
            if (obj.erc != undefined && !isNaN(obj.erc))
                obj.erc = Number(obj.erc);
            this.tempJson.push(obj);
        }
        else {
            for (let i = 0; i < this.tempJson.length; i++) {
                if (obj.t == this.tempJson[i]["t"] && obj.tI == this.tempJson[i]["tI"] && obj.displayName == this.tempJson[i]["displayName"]) {
                    var oldcount = this.tempJson[i]["count"];
                    this.tempJson[i]["count"] = (this.tempJson[i]["count"] + (obj.count || 1));
                    this.tempJson[i]["AvgD"] = (obj.D + this.tempJson[i]["AvgD"] * oldcount) / this.tempJson[i]["count"];
                    this.tempJson[i]["D"] = this.tempJson[i]["D"] + obj.D;
                    if (obj.erc != undefined && !isNaN(obj.erc))
                        this.tempJson[i]["erc"] = this.tempJson[i]["erc"] + Number(obj.erc);
                    break;
                }
                else if (i == this.tempJson.length - 1) {
                    obj["AvgD"] = obj["D"] / obj["count"];
                    obj["count"] = (obj["count"] || 1);
                    if (obj.erc != undefined && !isNaN(obj.erc))
                        obj.erc = Number(obj.erc);
                    this.tempJson.push(obj);
                    break;
                }
            }
        }
    }
    returnIconForTier(tI) {
        for (let i = 0; i < this.jonDataForTierMergeToDraw.length; i++) {
            if (this.jonDataForTierMergeToDraw[i]["tI"] == tI) {
                return this.jonDataForTierMergeToDraw[i]["icon"];
            }
        }
    }
    checkCoordinates(tI) {
        for (let i = 0; i < this.jsonDataForTierMergetoView.length; i++) {
            if (this.jsonDataForTierMergetoView[i]["tI"] == tI) {
                return this.jsonDataForTierMergetoView[i]["cordinate"];
            }
        }
    }
    getParent(val) {
        for (let i = 0; i < this.jsonData.length; i++) {
            if ((this.jsonData[i]["cType"] == "C" || this.jsonData[i]["cType"] == "P") && val.jpF == this.jsonData[i]["F"]) {
                return this.jsonData[i];
            }
        }
    }
    mergeAllTierData() {
        let tempJson = [];
        this.jonDataForTierMergeToDraw.map((val) => {
            if (!val["cType"]) {
                if (tempJson.length > 0) {
                    let index = this.checkForSame(val, tempJson);
                    if (index == undefined) {
                        tempJson.push(val);
                    }
                    else {
                        let newObj = JSON.parse(JSON.stringify(val));
                        tempJson[index];
                        tempJson[index]["BtID"] = tempJson[index]["BtID"] + "";
                        if (!tempJson[index]["BtID"].includes(newObj["BtID"])) {
                            tempJson[index]["BtID"] = tempJson[index]["BtID"] + "," + newObj["BtID"];
                            tempJson[index]["Tduration"] = tempJson[index]["Tduration"] + "," + newObj["Tduration"];
                            tempJson[index]["count"] = tempJson[index]["count"] + "," + newObj["count"];
                            tempJson[index]["AvgDuration"] = tempJson[index]["AvgDuration"] + newObj["Tduration"] / newObj["count"]; // tempJson[index]["Tduration"] / tempJson[index]["count"];
                        }
                        else {
                            /*get the old values , calculate new values and update
                            var bti = getindex(tempJson[index]["BtID"],newObj["BtID"]);
                            var TDurS = getvalatindex(tempJson[index]["Tduration"] , bti);
                            var TCountS = getvalatindex(tempJson[index]["count"] ,bti);
                            var TDur = Number(TDurS.trim());
                            var TCount = Number(TCountS.trim());
                            TDur = TDur + newObj["Tduration"];
                            TCount = TCount + newObj["count"];*/
                        }
                    }
                }
                else {
                    tempJson.push(val);
                }
            }
            else {
                tempJson.push(val);
            }
        });
        this.jonDataForTierMergeToDraw = tempJson;
    }
    checkForSame(val, tempJson) {
        let id;
        for (let i = 0; i < tempJson.length; i++) {
            if (val["sourceId"] == tempJson[i]["sourceId"] && val["targetID"] == tempJson[i]["targetID"]) {
                id = i;
                break;
            }
        }
        return id;
    }
    getData() {
        return new Promise((resolve, reject) => {
            if (this.jsonDataForTierMergetoView.length > 0 || this.rootFpMiss) {
                resolve(this.jsonDataForTierMergetoView);
            }
            else {
                let url;
                this.isRefreshCase = false;
                this.getHeaderDetails();
                this.createFirstLevelJson(url).then((data) => resolve(data));
            }
        });
    }
    getDataForAgg() {
        return new Promise((resolve, reject) => {
            if (this.jsonData.length > 0) {
                resolve(this.jsonData);
            }
            else {
                let url;
                this.getHeaderDetails();
                this.isRefreshCase = true;
                this.CommonServices.loaderForDdr = true;
                this.createFirstLevelJson(url).then((data) => resolve(data));
            }
        });
    }
    checkChildPresentForRP(F) {
        let res = this.mergeChildData[F];
        if (!res) {
            return false;
        }
        else {
            return true;
        }
    }
    getHeaderDetails() {
        let url = sessionStorage.getItem("aggUrl");
        let data = url.split("&");
        this.startTime = Number(data[2].split("=")[1]);
        console.log("startTime", this.startTime);
        this.endTime = Number(data[3].split("=")[1]);
        this.btName = data[5].split("=")[1];
    }
    getTruncatedURL(name) {
        let str = "";
        if (name == '-')
            return '';
        if (name.length <= 32)
            return name;
        str = name.substring(0, 16) + "..." + name.substring(name.length - 16, name.length);
        return str;
    }
};
DdrAggFlowmapService.ctorParameters = () => [
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_2__["Router"] },
    { type: _common_services__WEBPACK_IMPORTED_MODULE_3__["CommonServices"] },
    { type: src_app_core_breadcrumb_breadcrumb_service__WEBPACK_IMPORTED_MODULE_4__["BreadcrumbService"] },
    { type: _nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_5__["NdDdrHttpService"] }
];
DdrAggFlowmapService = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"])()
], DdrAggFlowmapService);



/***/ }),

/***/ "./src/app/pages/ddr/services/ddr-breadcrumb.service.ts":
/*!**************************************************************!*\
  !*** ./src/app/pages/ddr/services/ddr-breadcrumb.service.ts ***!
  \**************************************************************/
/*! exports provided: DdrBreadcrumbService */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DdrBreadcrumbService", function() { return DdrBreadcrumbService; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs */ "./node_modules/rxjs/_esm2015/index.js");
/* harmony import */ var _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../tools/actions/ddr-data-model.service */ "./src/app/pages/tools/actions/ddr-data-model.service.ts");
/* harmony import */ var _common_services__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./common.services */ "./src/app/pages/ddr/services/common.services.ts");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js");



//import { CavTopPanelNavigationService } from '../../../main/services/cav-top-panel-navigation.service';
//import { DdrDataModelService } from "./ddr-data-model.service";


//import 'rxjs/add/operator/pairwise';

let DdrBreadcrumbService = class DdrBreadcrumbService {
    constructor(ddrData, _router, commonService, _activateRoute) {
        this.ddrData = ddrData;
        this._router = _router;
        this.commonService = commonService;
        this._activateRoute = _activateRoute;
        this.breadcrumbItem$ = new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"]([]);
        this.breadCrumbAsObservable$ = this.breadcrumbItem$.asObservable();
        this.itemBreadcrums = [];
        this.isNotDuplicate = true;
        this.isFromHome = false;
        this.isFromBreadCrumb = false;
        this.parentChildInfo = {};
        this.parentComponent = '';
        this.ddrData.tabNameObservable$.subscribe((data) => {
            this.itemBreadcrums = [];
            this.commonService.removeAllComponentFromFlowpath();
        });
    }
    setBreadcrumbs(page) {
        let refList = this.getBreadcrumsLink(page);
        this.breadcrumbItem$.next(refList);
    }
    getBreadcrumsLink(page) {
        this.isNotDuplicate = true;
        this.itemBreadcrums.map((data) => {
            if (data.routerLink[0] == page) {
                this.isNotDuplicate = false;
            }
        });
        this.isFromBreadCrumb = false;
        let label = '';
        if (page == 'main') {
            label = 'Web Logic';
        }
        else if (page == 'flowpath') {
            label = 'Flowpath';
        }
        else if (page == 'view') {
            label = 'ThreadDump';
        }
        else if (page == 'gcViewer') {
            label = 'GC LOG Details';
        }
        else if (page == 'query') {
            label = 'DB Queries';
        }
        else if (page == 'exception') {
            label = 'Exceptions';
        }
        else if (page == 'methodtiming') {
            if (this.commonService.openfptoAggMT == true)
                label = 'Aggregate Method Timing';
            else
                label = 'Method Timing';
        }
        else if (page == 'servicemethodtiming') {
            label = 'Service Method Timing';
        }
        else if (page == 'threadhotspot') {
            label = 'Thread Hotspots';
        }
        else if (page == 'Ddrtransactionflowpmap') {
            label = 'Transaction Flowmap';
        }
        else if (page == 'hotspot') {
            label = 'HotSpot Thread Details';
        }
        else if (page === 'httpReqResp') {
            label = 'HTTP Request Response';
        }
        else if (page === 'methodCallingTree') {
            label = 'Method Calls Details';
        }
        else if (page === 'Flowpathbysignature') {
            label = 'Flowpaths By Signature';
        }
        else if (page === 'Flowpathgroupby') {
            label = 'Flowpaths Group By BT';
        }
        else if (page === 'CustomDataByBTSplitting') {
            label = 'Custom Data By BT Splitting';
        }
        else if (page === 'dbGroupBy') {
            label = 'DB Group By BT';
        }
        // else if (page == 'aggMethodTiming') {
        //   label = 'Aggregate Method Timing'
        // }
        else if (page == 'DdrBtTrendComponent') {
            label = 'BT Trend';
        }
        else if (page == 'IpStatComponent') {
            label = 'IP Stat';
        }
        else if (page === 'flowpathAnalyzer') {
            label = 'Flowpaths Analyzer';
        }
        else if (page === 'sqlByExecutionTime') {
            label = 'SQL Report By Query Execution Time';
        }
        else if (page === 'sqlTiming') {
            label = 'SQL Timings';
        }
        else if (page === 'ipsummary')
            label = "BT IP Summary";
        else if (page === 'dbReport') {
            label = 'DB Queries';
        }
        else if (page === 'flowpathToDB')
            label = "DB Queries";
        else if (page === 'flowpathToMD')
            label = "Metadata";
        /**
           * NS Session
           */
        else if (page === 'nsreports/sessionSummary')
            label = 'Session Summary';
        else if (page === 'nsreports/sessionStatus')
            label = 'Session Summary By Status';
        else if (page === 'nsreports/sessionInstance')
            label = 'Session Instance';
        else if (page === 'nsreports/sessionFailure')
            label = 'Session Failure Report';
        else if (page === 'nsreports/sessionDetail')
            label = 'Session Detail Report';
        else if (page === 'nsreports/sessionTiming')
            label = this.nsReportName + ' Timing Details';
        /**
         * NS Page
         */
        else if (page === 'nsreports/PageSummary')
            label = 'Page Summary';
        else if (page === 'nsreports/PageSessionSummary')
            label = 'Page Session Summary';
        else if (page === 'nsreports/PageSummaryByStatus')
            label = 'Page Summary By Status';
        else if (page === 'nsreports/PageInstance')
            label = 'Page Instance';
        else if (page === 'nsreports/PageComponentDetail')
            label = 'Page Component Details';
        else if (page === 'nsreports/PageFailure')
            label = 'Page Failure';
        /**
          * NS URL
          */
        else if (page === 'nsreports/urlSummary')
            label = 'URL Summary';
        else if (page === 'nsreports/urlSummaryStatus')
            label = 'URL Summary By Status';
        else if (page === 'nsreports/urlInstance')
            label = 'URL Instance';
        else if (page === 'nsreports/urlfail')
            label = 'URL Failure Report';
        else if (page === 'nsreports/urldetails')
            label = 'URL Component Details';
        else if (page === 'nsreports/urlsessionsummary')
            label = 'URL Session Summary';
        /**
          * NS transaction
          */
        else if (page === 'nsreports/TransactionSummary')
            label = 'Transaction Summary';
        else if (page === 'nsreports/TransactionSummaryByStatus')
            label = 'Transaction Summary By Status';
        else if (page === 'nsreports/TransactionInstance')
            label = 'Transaction Instance';
        else if (page === 'nsreports/TransactionFailurereport')
            label = 'Transaction Failure';
        else if (page === 'nsreports/TransactionDetails')
            label = 'Transaction Details Report';
        else if (page === 'nsreports/TransactionSessionSummary')
            label = 'Transaction Session Summary';
        else if (page === 'nsreports/userSession')
            label = 'User Session';
        else if (page == 'pagedump')
            label = 'Page Dump';
        else if (page == 'sequencediagram/fromPage')
            label = 'Sequence Diagram';
        else if (page == 'heapAnalyser')
            label = 'Java heap dump analyzer';
        else if (page == "DdrTierMergeViewComponent")
            label = "Aggregate Transaction Flowmap";
        else if (page == "DdrAggFlowmapComponent")
            label = "Agg Transaction Flowmap";
        else if (page == 'sysdef')
            label = 'System Queries';
        else if (page == 'ibmheapAnalyser')
            label = 'IBM Java heap dump analyzer';
        else if (page == 'gcManager')
            label = 'GC Manager';
        if (this.parentComponent == 'flowpath' && this.commonService.splitView) {
            return this.itemBreadcrums;
        }
        else {
            let objCheck = this.itemBreadcrums.find((itemObj) => { return itemObj.routerLink[0] === 'flowpath'; });
            let checkIndex = this.itemBreadcrums.indexOf(objCheck);
            // this._router.events.filter(e => e instanceof NavigationEnd).pairwise().first().subscribe((e) => {
            //   console.log('NAVIGATION PREVIOUS => ',e);
            //     if((e[0]['url'] == '/home/ddr/flowpath' || e[0]['url'] == '/home/ED-ddr/flowpath' || e[0]['url'] == '/home/ddrCopyLink/flowpath') && checkIndex != -1 && objCheck && !this.isFromBreadCrumb ){
            //     this.itemBreadcrums.splice(checkIndex + 1,this.itemBreadcrums.length-1);
            //   } 
            // });
        }
        var objToAdd = {
            label: label, routerLink: [page], command: (event) => {
                this.commonService.isFilterFromSideBar = true;
                //this.commonService.isFromBreadCrumb=true;
                console.log("event breadcrumb --", event);
                // this.ddrData.throughBreadcrumb = true ;
                let label = event.item.label;
                if (label == 'Flowpaths Group By BT')
                    this.commonService.previousReport = "FlowpathGroupBy";
                else if (label == 'Aggregate Method Timing')
                    this.commonService.previousReport = "Method Timing";
                else if (label == 'Flowpath')
                    this.commonService.previousReport = "Flowpath";
                else if (label == 'Exceptions')
                    this.commonService.previousReport = "Exception";
                else if (label == 'DB Group By BT')
                    this.commonService.previousReport = "DBGroupBy";
                else if (label == 'DB Queries')
                    this.commonService.previousReport = "DB Report";
                else if (label == 'HotSpot Thread Details')
                    this.commonService.previousReport = "HotSpot";
                else if (label == 'BT IP Summary')
                    this.commonService.previousReport = "IP Summary";
                this.parentComponent = event.item.routerLink[0];
                this.isFromHome = false;
                //this.isFromBreadCrumb = true;
                let labelTemp = '';
                if (label.indexOf(" By") != -1 && page.includes("nsreports")) // will do only in case of ns report.
                 {
                    let index = label.indexOf(" By");
                    labelTemp = label.slice(0, index);
                    console.log("sliced label turned to summary report ********* ", labelTemp);
                }
                if (this.ddrData.nsCqmAutoFill[label] || this.ddrData.nsCqmAutoFill[labelTemp]) {
                    console.log("firing event from bread crumb service *********** ", label, "*****", labelTemp);
                    if (labelTemp != '')
                        this.commonService.nsAutoFillSideBar(labelTemp);
                    else
                        this.commonService.nsAutoFillSideBar(label);
                }
            }
        };
        let objParent = this.itemBreadcrums.find((itemObj) => { return itemObj.routerLink[0] === this.parentComponent; });
        let indexOfParent = this.itemBreadcrums.indexOf(objParent);
        if (indexOfParent != -1 && indexOfParent != (this.itemBreadcrums.length - 1) && (this.parentComponent != page) && !this.isFromHome) {
            let tempBreadCrump = [];
            for (let i = 0; i <= indexOfParent; i++) {
                tempBreadCrump.push(this.itemBreadcrums[i]);
            }
            tempBreadCrump.push(objToAdd);
            this.itemBreadcrums = [];
            this.itemBreadcrums = tempBreadCrump;
        }
        else if (this.isNotDuplicate) {
            this.itemBreadcrums.push(objToAdd);
        }
        return this.itemBreadcrums;
    }
    get nsReportName() {
        return this._nsReportName;
    }
    set nsReportName(value) {
        this._nsReportName = value;
    }
};
DdrBreadcrumbService.ctorParameters = () => [
    { type: _tools_actions_ddr_data_model_service__WEBPACK_IMPORTED_MODULE_3__["DdrDataModelService"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_5__["Router"] },
    { type: _common_services__WEBPACK_IMPORTED_MODULE_4__["CommonServices"] },
    { type: _angular_router__WEBPACK_IMPORTED_MODULE_5__["ActivatedRoute"] }
];
DdrBreadcrumbService = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"])()
], DdrBreadcrumbService);



/***/ }),

/***/ "./src/app/pages/ddr/services/ddr-message.service.ts":
/*!***********************************************************!*\
  !*** ./src/app/pages/ddr/services/ddr-message.service.ts ***!
  \***********************************************************/
/*! exports provided: MessageService */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MessageService", function() { return MessageService; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs */ "./node_modules/rxjs/_esm2015/index.js");



let MessageService = class MessageService {
    constructor() {
        this.subject = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
    }
    sendMessage(message) {
        console.log("Message sevice sendMessgae called!!!!");
        this.subject.next(message);
    }
    clearMessage() {
        this.subject.next();
    }
    getMessage() {
        console.log("Message sevice getMessgae called!!!!");
        return this.subject.asObservable();
    }
};
MessageService = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"])()
], MessageService);



/***/ }),

/***/ "./src/app/pages/ddr/services/rrx-data.service.ts":
/*!********************************************************!*\
  !*** ./src/app/pages/ddr/services/rrx-data.service.ts ***!
  \********************************************************/
/*! exports provided: LZString, RrxDataService */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LZString", function() { return LZString; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "RrxDataService", function() { return RrxDataService; });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
/* harmony import */ var src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! src/app/core/session/session.service */ "./src/app/core/session/session.service.ts");
/* harmony import */ var _dashboard_service_req_transaction_flowmap_service_trx_flowmap_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../dashboard-service-req/transaction-flowmap/service/trx-flowmap.service */ "./src/app/pages/dashboard-service-req/transaction-flowmap/service/trx-flowmap.service.ts");
/* harmony import */ var _nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./nd-ddr-http.service */ "./src/app/pages/ddr/services/nd-ddr-http.service.ts");
/* harmony import */ var _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../state/nd-ddr.state */ "./src/app/pages/ddr/state/nd-ddr.state.ts");






let LZString = __webpack_require__(/*! ./../../../../../node_modules/lz-string/libs/lz-string.js */ "./node_modules/lz-string/libs/lz-string.js");
let RrxDataService = class RrxDataService {
    constructor(TrxData, sessionService, ndDdrHttpService) {
        this.TrxData = TrxData;
        this.sessionService = sessionService;
        this.ndDdrHttpService = ndDdrHttpService;
        this.base = "";
        this.cmdArgs = "";
        this.timeFilters = "";
    }
    TrxflowmapDataNonExpand(flowpathInstance, startTimeInMs, endTime, rxxflag) {
        return new Promise((resolve, reject) => {
            let rxxTreeData = [];
            this.cmdArgs = "";
            this.timeFilters = "";
            this.cmdArgs = " --object  4  --status  -2 ";
            this.timeFilters += " --abs_starttime " + (Number(startTimeInMs) - 1800000);
            this.timeFilters += " --abs_endtime " + endTime;
            this.cmdArgs = this.cmdArgs + "--getchildflowpath " + flowpathInstance + this.timeFilters + "--enableNewSQB 10 --enableDDRDebug 0";
            // this.cmdArgs = "--testrun 1011 --object  4  --status  -2 --getchildflowpath 4611756387232463875 --abs_starttime 1697174276000 --abs_endtime 1697179679230--enableNewSQB 10 --enableDDRDebug 0";
            const testRun = this.sessionService.session.testRun.id;
            // if (this.sessionService.preSession.multiDc == true)
            //   this.base = location.protocol + "//" + location.host + "/node/" + "ALL";
            // else
            //   this.base = location.protocol + "//" + location.host;
            const path = "cmdArgs=" + "--testrun " + testRun + this.cmdArgs + "&ndeId=" + "-1";
            const url = this.base + path;
            if (this.sessionService.preSession.multiDc === false) { //(tomcat)
                this.ndDdrHttpService.getTransactionFlowMapData(url).subscribe((state) => {
                    if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_5__["TransactionFlowMapDataLoadedState"]) {
                        const decompresseddata = JSON.parse(LZString.decompressFromEncodedURIComponent(state.data.data[0]));
                        console.log("resData is ~ ", decompresseddata);
                        this.TrxData.ProcessDtoLists(decompresseddata);
                        console.log("Nodelist is ~ ", this.TrxData.getNodeList());
                        this.selfLoppedDataToDrawToView = this.TrxData.getNodeList();
                        rxxTreeData = [...this.createHierarchy(this.selfLoppedDataToDrawToView)];
                        console.log("Tree ~ ", rxxTreeData);
                        resolve(rxxTreeData);
                    }
                });
            }
            else { //(Cluster Case)
                this.ndDdrHttpService.getTransactionFlowMapData(url).subscribe((state) => {
                    if (state instanceof _state_nd_ddr_state__WEBPACK_IMPORTED_MODULE_5__["TransactionFlowMapDataLoadedState"]) {
                        const dataforTRX = [];
                        for (let i = 0; i < state.data.data.length; i++) {
                            const compressedResult = state.data.data[i];
                            const decompressedResult = JSON.parse(LZString.decompressFromEncodedURIComponent(compressedResult));
                            dataforTRX[i] = { result: decompressedResult };
                        }
                        console.log("Response from server :: ", dataforTRX);
                        this.TrxData.ProcessDtoLists(dataforTRX);
                        console.log("NodeList is :: ", this.TrxData.getNodeList());
                        this.selfLoppedDataToDrawToView = this.TrxData.getNodeList();
                        rxxTreeData = [...this.createHierarchy(this.selfLoppedDataToDrawToView)];
                        console.log("Tree ~ ", rxxTreeData);
                        resolve(rxxTreeData);
                    }
                });
            }
        });
    }
    createTree(data, parentLevel = 1) {
        const tree = [];
        for (const item of data) {
            if (item.depth === parentLevel) {
                const node = {
                    data: item,
                    children: this.createTree(data, item.depth + 1) // Pass the current item's level as the parentLevel
                };
                tree.push(node);
            }
        }
        return tree;
    }
    createHierarchy(data) {
        // Sort the data based on depth and ID to ensure the desired order
        data.sort((a, b) => {
            if (a.depth === b.depth) {
                return a.id.localeCompare(b.id);
            }
            return a.depth - b.depth;
        });
        console.log('data is ', data);
        return this.createTree(data);
    }
};
RrxDataService.ctorParameters = () => [
    { type: _dashboard_service_req_transaction_flowmap_service_trx_flowmap_service__WEBPACK_IMPORTED_MODULE_3__["TrxFlowmapService"] },
    { type: src_app_core_session_session_service__WEBPACK_IMPORTED_MODULE_2__["SessionService"] },
    { type: _nd_ddr_http_service__WEBPACK_IMPORTED_MODULE_4__["NdDdrHttpService"] }
];
RrxDataService = Object(tslib__WEBPACK_IMPORTED_MODULE_0__["__decorate"])([
    Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"])({
        providedIn: 'root'
    })
], RrxDataService);



/***/ })

}]);