<template id="app-3">
 <div  id="setting">
    <div class="serch-section-opt2">
      <div class="search" id="search"><input type="text" v-model="inputSearchData" placeholder="Search..." @input="inputChangeHandleSearchData" @keyup.enter="inputHandleSearchData" ></div>
      <div class="search-icon" id="search-box"  @click="inputHandleSearchData"></div>
    </div>

    <div class="right-fixed-section">
      <div class="map-img" v-show="isEnableIcon">
        <div class="title">Overlapping Markers &nbsp;</div>
        <div class="map-img-innner">
          <div class="map-img-scroll">
          <img  v-for="image in images" v-bind:key="image.id" :src="image.url" :alt="image.alt" @click="iconsList(image.instance)"/> 
          </div>
        </div>
      </div>
    </div>

    <div class="right-fixed-section-show-hide">
      <div class="show-hide-log clearfix" v-show="isEnableIcon">
        <button @click="toggleLog()">Show/Hide Event Logs</button>
        <div class="clearfix"></div>
      </div>
    </div>

    <div class="right-fixed-section-logs">
      <div class="show-hide-log clearfix" v-show="isEnableIcon">
        <div class="logs-section" v-show="isEnableLog" >
          <div class="logs-header">
            <select v-model="selectedEventType" @change="eventTypeChangeHandler()">
              <option value="eventType">Event Type</option>
              <option value="liveStart" class="logs-green">Live Start</option>
              <option value="liveStop" class="logs-blue">Live Stop</option>
            </select>
            <select v-model="selectedDateRange" @change="dateRangeChangeHandler()">
              <option value="latestWeek">The Latest Week</option>
              <option value="lastMonth">The last month</option>
              <option value="last3Months">The last 3 months</option>
              <option value="accordingMonth">According to the month</option>
            </select>
            <datepicker v-bind:class="checkBackgroundColor" :minimumView="viewType" v-model="startDate" @selected="datepickerSelected" type="datetime" :format="format" :disabled="isDisabled"></datepicker>
            <span class="to" v-show="isDisplayDateRange">To</span>
            <datepicker :minimumView="viewType" v-model="endDate" type="datetime" :format="format" :disabled="isDisabled" v-show="isDisplayDateRange"></datepicker>
            <button @click="filterClickHandler()">Filter</button>
          </div>
          <div class="logs" id="showLogs" v-html="showLogs">
            <p class="logs-green">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-blue">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-green">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-blue">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-green">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-blue">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-green">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-blue">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-green">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
            <p class="logs-blue">08.12.2019 13:23:56 UTC-4:WCSH_R!(fe4ec403c004efcf) starts live with DBL_R54[24ca4d41460dc134]</p>
          </div>
          <div class="pagination" id="pagination" v-show="isEnablePagination">
            <CustomPagination @changePage="onChangePage" :paginationDetails="paginationDetails"> </CustomPagination>
          </div>
        </div>
      </div>
    </div>

    <div class="summary-container" id="setting" style="visibility:hidden">
      <div class="summary-details">
        <a href="#" class="link-btn map"></a>
        <a href="#" class="link-btn menu"></a>
        <div class="summary">
          Summary: Live Connection
          <span>500</span> Average Bitrate
          <span>3.6 Mbps</span> Live Time
          <span>50:26:39</span>
        </div>
        <div class="summary-panel" v-show="isShow" id="hide">
          <div class="summary-label">Summary Item</div>
          <div class="summary-item">
            <ul>
              <li
                v-for="item in summaryCheckboxes"
                :key="item.id"
                :class="item.class"
                @click="summaryItem(item.id)"
              >{{ item.text }}</li>
            </ul>
          </div>
        </div>
        <a href="#" class="link-btn settings" @click="add"></a>
      </div>
      <div class="country-details">
        <div class="country-scroll">
          <ul>
            <li>
              {{summaryData.country}}: Total Live
              <span>{{summaryData.totalLive}}</span> Incoming
              <span>{{summaryData.incoming}}</span> Outcoming
              <span>{{summaryData.outcoming}}</span> Average Bitrate
              <span>{{summaryData.averageBitrate}} Mbps</span>
            </li>
          </ul>
        </div>
        <a href="#" class="link-btn up-arrow" @click="changeSummaryData"></a>
        <a href="#" class="link-btn down-arrow" @click="changeSummaryData"></a>
      </div>
    </div>
  </div>  
</template>

<script>

  import axios from 'axios'

  import { apiDataActions } from "../actions/apidata.action";
  import init from "../map/script.js";
  import markerImageCyan from "../images/map-marker_cyan.png";//source
  import markerImageGreen from "../images/map-marker_green.png";//destination
  import markerImageOrange from "../images/map-marker_orange.png";//sourceClick
  import markerImageRed from "../images/map-marker_red.png";//destinationClick
  import markerImagePurple from "../images/map-marker_purple.png";//sourceDestination
  import Datepicker from 'vuejs-datepicker';
  import CryptoJS  from 'crypto-js';
  import config from "../../static/config.json";
  import CustomPagination from "../components/CustomPagination";
  
  let loadingText = "<p class='logs-black'>Loading...</p>";
  let selectLoadingText = "<p class='logs-black'>Please click Filter button for logs data</p>";
  let noDataFound = "No Data Found";
  let noDataFoundWithClass = "<p class=''>"+noDataFound+"</p>";
  let latestWeek = "";
  let refreshTime = config.refreshTime;// 20 seconds 
  let intervalId = "";
  let serverCurrentTime = "";

  /* value of the event in dropdown */
  let eventRange = {
    "eventType":"eventType",
    "liveStart":"liveStart",
    "liveStop":"liveStop"
  }
  /* value of the daterange in dropdown */  
  let dateRange = {
    "latestWeek":"latestWeek",
    "lastMonth":"lastMonth",
    "last3Months":"last3Months",
    "accordingMonth":"accordingMonth"
  }
  /* color icon of the marker */
  let iconImage = {
    "source": markerImageCyan,
    "destination": markerImageGreen,
    "sourceClick": markerImageOrange,
    "destinationClick": markerImageRed
  }
  let eventTypeMessage = {
    "starts": " starts ",
    "stops": " stops "
  }
  let filterList = [];
  let responseData = [];

  let searchData = "";
  let receiver = {"source":0, "destination":1};
  let icon = {"default":false, "clicked":true};

  let monthNames = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"]; 
  let dayOfWeekNames = [ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];
  let logs = {"green":"logs-green", "blue":"logs-blue", "red":"logs-red"};
  const emptyRecords = "null";

  export default {
    components: {
      Datepicker,
      CustomPagination
    },
    mounted() {
      var that = this;
      that.mapsOp = init();
      that.IsZoomProjection = 1;

      /*
      //Listener while idle
      */
      google.maps.event.addListener(that.mapsOp.map, "idle", function() {
          if (that.IsZoomProjection == 1) {
            that.callAPIAndDisplayData();
          }
        }
      );

      /*
      //Listener while projection changed
      */
      google.maps.event.addListener(that.mapsOp.map, "projection_changed", function() {
          that.callAPIAndDisplayData();
        }
      );

      /*
      //Listener while zoom changed
      */
      google.maps.event.addListener(that.mapsOp.map, "zoom_changed", function() {
          //for zoom in/out, we need to empty responseData 
          that.setAutoRefeshMode(false);
          that.clearLogs();
          that.clearResponseData();
          that.clearInterval();
          that.mapsOp.clearClickedMarkerDetails();
          that.resetZoomLevelDataBeforeCallAPI();
        }
      );
    },
    name: "Summary",
    created() {
      //this.startInterval();  
      //set the value for start date and end date
      this.setDateValue();
    },
    methods: {
      /*
      // get the accesskey 
      */
      getAcessKey : function(timestamp){
        // generate requestid
        var guid = (function() {
          function s4() {
            return Math.floor((1 + Math.random()) * 0x10000).toString(16).substring(1);
          }
          return function() {
            return s4() + s4() + s4() + s4()  + s4()  + s4() + s4() + s4();
          };
        })();

        // generate signature
        var signature = (CryptoJS.MD5(process.env.APPSECRET+timestamp)+"").toUpperCase();
        
        var object = {};
        object.appkey = "6413256a020fba4580a76034cc9b88df";
        object.timestamp = timestamp;
        object.signature = signature
        object.requestId = guid();
        //console.log("object --> ", object);
        return object;
      },

      /*
      //post data from API
      */
      postData(_input, _headers) {
        //console.log("postData");
        return apiDataActions.postData(_input, _headers);
      }, 

      /*
      // reset data before call API and display data
      */
      resetZoomLevelDataBeforeCallAPI: function(){
        var that = this;
        that.mapsOp.zoomLevel = that.mapsOp.map.getZoom();
        that.IsZoomProjection = 1;
      },

      /*
      // call API and display marker
      */
      callAPIAndDisplayData: async function(){
          let that = this;
          const toSendData = that.getCornerData(that.mapsOp.map);
          await  that.getData(toSendData).then(
            function(data) {
              that.successHandle(data);
              that.IsZoomProjection = 0;

              if(that.autoRefeshMode == false){
                that.disableIcon();
              }
              
              /*
              if(that.autoRefeshMode == true && that.isEnableIcon == true) {
                that.filterHandler();
              }
              */
            }
          ).catch(function(data){
              that.successHandle(data);
              that.IsZoomProjection = 0;
              //console.log("--------autoRefeshMode----catch-----", that.autoRefeshMode);
              that.disableIcon();
          });
      }, 

      /*
      //Clear icon collection
      */
      clearIcon:function(){
        this.$data.images = [];
      },

      /*
      //enable icon
      */
      enableIcon:function(){
        this.$data.isEnableIcon = true;
      },

      /*
      //Disable icon
      */
      disableIcon:function(){
        this.$data.isEnableIcon = false;
      },

      /*
      //enable event log
      */
      enableLog: function(){
        console.log("enableLogenableLogenableLogenableLogenableLog");
        this.$data.isEnableLog = true;
      },

      /*
      // Disable event log
      */
      disableLog: function(){
        console.log("disableLogdisableLogdisableLogdisableLogdisableLog");
        this.$data.isEnableLog = false;
      },

      /*
      // Toggle the event log value
      */      
      toggleLog: function(){
        this.$data.isEnableLog = !this.$data.isEnableLog;
      },

      /*
      // Load the data after change handler 
      */  
      eventTypeChangeHandler: function(){
        this.setLoadingText();
        this.clearInterval();
      },

      /*
      // Set the loading text
      */
      setLoadingText : function(){
        this.showLogs = selectLoadingText; 
      },

      /*
      // Set the date value on change the dropdown 
      */
      dateRangeChangeHandler: function(){
        this.setLoadingText();
        this.setDateValue();
        this.clearInterval();
      },

      /*
      // Set the date value depending upon the dropdown 
      */
      setDateValue: function(){
        this.clearStartDataEndDate();
        switch(this.$data.selectedDateRange){
          case dateRange.latestWeek: 
              this.isDisplayDateRange = true;
              this.isDisabled = true;
              this.viewType = 'day';
              this.format = 'yyyy-MM-dd';
              this.setlatestWeekData();
              break;
          case dateRange.lastMonth:
              this.isDisplayDateRange = false;
              this.isDisabled = true;
              this.viewType = 'month';
              this.format = 'yyyy-MM';
              this.setLastMonthData();
              break;
          case dateRange.last3Months:
              this.isDisplayDateRange = true;
              this.isDisabled = true;
              this.format = 'yyyy-MM';
              this.viewType = 'month';
              this.setLast3MonthsData();
              break;        
          case dateRange.accordingMonth:
              this.isDisplayDateRange = false;
              this.isDisabled = false;
              this.format = 'yyyy-MM';
              this.viewType = 'month';
              this.setAccordingMonthData();
              break;
          default :
              this.setlatestWeekData();
        }
      },

      /*
      //set default value for showlogs as loading message.
      */
      clearLogs: function(){
        this.showLogs = loadingText; 
      },

      /*
      //Set empty responseData
      */
      clearResponseData: function(){
        responseData = [];
      },

      /*
      //Set empty start and end date
      */
      clearStartDataEndDate: function(){
        this.startDate =  null;
        this.endDate =  null;
      },

      /*
      //Set current Date 
      */    
      setCurrentDate: function(){
        let currentDate = new Date();
        return currentDate;
      },

      /*
      //set the start day of any date
      */
      setStartDay: function(_date){
        _date.setHours(0,0,0,0);
        return _date;
      },

      /*
      //set the end day of any date
      */
      setEndDay: function(_date){
        _date.setHours(23,59,59,999);
        return _date;
      },

      /*
      //Set previous week time of the current date
      */    
      setPreviousWeek: function(_week){
        let startDate =  this.setCurrentDate();
        startDate.setDate( startDate.getDate() - _week);
        return startDate;
      },

      /*
      //Set previous month of the current date
      */      
      setPreviousMonth: function(_month){
        let startDate =  this.setCurrentDate();
        startDate.setMonth( startDate.getMonth() - _month);
        return startDate;
      },

      /*
      //Set first day of the month provided as parameter
      */      
      setFirstDay: function(_date){
        var firstDay = new Date(_date.getFullYear(), _date.getMonth(), 1);
        return firstDay;
      },

      /*
      //Set last day of the month provided as parameter
      */      
      setLastDay: function(_date){
        var lastDay = new Date(_date.getFullYear(), _date.getMonth() + 1, 0);      
        return lastDay;
      },

      /*
      //Set lastest week date of start date and current date as end date 
      */      
      setlatestWeekData: function(){
        let previousWeekDate = this.setPreviousWeek(6);
        this.startDate = this.setStartDay(previousWeekDate);
        this.endDate = this.setEndDay(this.setCurrentDate());
      },

      /*
      //Set first day and last day of the last month in start date and end date 
      */      
      setLastMonthData: function(){
        let previousMonth = this.setPreviousMonth(1);
        this.startDate = this.setFirstDay(previousMonth);
        this.endDate = this.setLastDay(previousMonth);
      },

      /*
      //Set first day and last day of the last 3 months in start date and end date 
      */     
      setLast3MonthsData: function(){
        let previous2Month = this.setPreviousMonth(2);
        this.startDate = this.setFirstDay(previous2Month);
        this.endDate = this.setLastDay(this.setCurrentDate());
      },

      /*
      //Set first day and last day of the last 3 months in start date and end date 
      */
      setAccordingMonthData: function(){
        let currentmonth = this.setCurrentDate();
        this.startDate =  this.setFirstDay(currentmonth);
        //this.endDate =  this.setLastDay(this.startDate); 
        this.setAccordingMonthEndDate();
      },

      /*
      //reset the enddate 
      */
      setAccordingMonthEndDate: function(){
        switch(this.$data.selectedDateRange){
          case dateRange.accordingMonth:
              this.endDate =  this.setLastDay(this.startDate);
              break;
        }
      },    

      /*
      //update enddate when we selected startdate from popup
      */
      datepickerSelected: function(){
        this.setLoadingText();
        this.clearInterval();
        //this.endDate =  this.setLastDay(this.startDate); 
      },

      /*
      //Set logs details
      */
      setLogsHistory: function(_data){
        console.log("setLogsHistory ---> ");
        this.showLogs = this.getLogsHistoryRows(_data);
      },

      /*
      //Set logs row 
      */
      getLogsHistoryRows : function(_data){
        let row = ""; 
        let rows = "";
        let data = "";
        let filterData = "";
        let cssClassLiveDuration = logs.blue;
        let cssClass = logs.red;
        let eventTypeStartStop = eventTypeMessage.stops;
        let length = _data.length;
        let dateMilliseconds = "";

        filterData = _data && _data.filter( data => {
          row = "";
          row = this.getLogsHistoryRow(data, cssClass, cssClassLiveDuration);
          rows = rows ? rows + row : row ;
          return rows;
        });

        //data = filterData && filterData.length ? rows : this.paragraphElement("", noDataFound);
        data = rows;
        return data;
      },

      /*
      //get the single row for event log and then decorate with paragraph element
      */
      getLogsHistoryRow : function(_data, _cssClass, _cssClassLiveDuration){
          const startDatemilliseconds = new Date(_data.startTime).toLocaleString('en-US', {timeZone: 'UTC'});
          const endDatemilliseconds = new Date(_data.endTime).toLocaleString('en-US', {timeZone: 'UTC'});
          const startDate =  this.formatDate(new Date(startDatemilliseconds), "MM.dd.yyyy HH:mm:ss") ;
          const endDate = this.formatDate(new Date(endDatemilliseconds), "M.dd.yyyy HH:mm:ss") 
          //const row = endDate + "(i.e. startDate : " + startDate +  ", endDate : " + endDate +  ") " +  _data.name + "(" + _data.peerId + ") " + eventTypeMessage.stops + " live with " + _data.liveGridPeerName + "[" + _data.liveGridPeerId + "]";
          const row = endDate + " " +   _data.name + "(" + _data.peerId + ") " + eventTypeMessage.stops + " live with " + _data.liveGridPeerName + "[" + _data.liveGridPeerId + "]";
          const secondRow = " Live duration: " +  this.mapsOp.msToHMS(_data.durationTime) +  " (HH:MM:SS) -- startDate : " + startDate +  ", endDate : " + endDate +  ") " ;
          return this.paragraphElement(_cssClass, row) + this.paragraphElement(_cssClassLiveDuration, secondRow) ;
      },

      /*
      //get the single row for event log and then decorate with paragraph element
      */
      getLogsLiveRow : function(_data, _cssClass){
          let liveData = "" ;
          
          //const getStartTime = serverCurrentTime - _data.liveTime * 1000 ;
          const getStartTime = _data.liveStartTime;


          if(getStartTime >= this.startDate  && getStartTime <= this.endDate){
            //const liveTimeMilliseconds = new Date(getStartTime).toLocaleString('en-US', {timeZone: 'UTC'});
            const liveTimeMilliseconds = getStartTime;
            const liveTime =  this.formatDate(new Date(liveTimeMilliseconds), "MM.dd.yyyy HH:mm:ss") ;
            const row = liveTime + " " + _data.marker1Coordinates.receiverName + "(" + _data.marker1Coordinates.peerID + ") " + eventTypeMessage.starts +" live with " +  (_data.marker2Coordinates ? _data.marker2Coordinates.receiverName : emptyRecords ) + "[" + ( _data.marker2Coordinates ?  _data.marker2Coordinates.livePeerID : emptyRecords) + "]";
            liveData = this.paragraphElement(_cssClass, row);
          }

          return liveData;
      },

      /*
      // add data at paragraph
      */
      paragraphElement : function (_class, _data){
        return "<p class='" + _class + "'>" + _data +  "</p>";
      },

      formatDate : function (date, patternStr){
        if (!patternStr) {
          patternStr = 'M/d/yyyy';
        }
        var day = date.getDate(),
          month = date.getMonth(),
          year = date.getFullYear(),
          hour = date.getHours(),
          minute = date.getMinutes(),
          second = date.getSeconds(),
          miliseconds = date.getMilliseconds(),
          h = hour % 12,
          hh = this.twoDigitPad(h),
          HH = this.twoDigitPad(hour),
          mm = this.twoDigitPad(minute),
          ss = this.twoDigitPad(second),
          aaa = hour < 12 ? 'AM' : 'PM',
          EEEE = dayOfWeekNames[date.getDay()],
          EEE = EEEE.substr(0, 3),
          dd = this.twoDigitPad(day),
          M = month + 1,
          MM = this.twoDigitPad(M),
          MMMM = monthNames[month],
          MMM = MMMM.substr(0, 3),
          yyyy = year + "",
          yy = yyyy.substr(2, 2)
        ;
        // checks to see if month name will be used
        patternStr = patternStr
          .replace('hh', hh).replace('h', h)
          .replace('HH', HH).replace('H', hour)
          .replace('mm', mm).replace('m', minute)
          .replace('ss', ss).replace('s', second)
          .replace('S', miliseconds)
          .replace('dd', dd).replace('d', day)
          
          .replace('EEEE', EEEE).replace('EEE', EEE)
          .replace('yyyy', yyyy)
          .replace('yy', yy)
          .replace('aaa', aaa);
        if (patternStr.indexOf('MMM') > -1) {
          patternStr = patternStr
            .replace('MMMM', MMMM)
            .replace('MMM', MMM);
        }
        else {
          patternStr = patternStr
            .replace('MM', MM)
            .replace('M', M);
        }
        return patternStr;
      },

      /*
      //two Digit Pad
      */
      twoDigitPad : function (num) {
        return num < 10 ? "0" + num : num;
      },

      /*
      // Handle click on filter
      */
      filterClickHandler: function(){
        //console.log("filterClickHandler ---> resetPaginationDetails");
        this.resetPaginationDetails();
        //console.log("filterClickHandler ---> filterHandler");
        this.filterHandler();
      },

      /*
      //When user click on filter button for seeing log data
      */
      filterHandler: function(){
        const clickedMarkerDetails = this.mapsOp.getClickedMarkerDetails();
        let that = this;

        //hide loading message when autoloading happening
        if(this.getAutoRefeshMode() == false){
          this.clearLogs();
        }

        this.getCurrentTime().then((response)  => {
          const input = this.updateJSONInputforPagination();
           
            if(response && response.data && response.data.errorCode === "0x0"){
              serverCurrentTime = response.data.result;
              const headers = {'AccessKey':JSON.stringify(this.getAcessKey(serverCurrentTime))};

              //live data
              let liveStartLogs ="";
              if(this.selectedEventType == eventRange.eventType || this.selectedEventType == eventRange.liveStart){
                let cssClass = logs.green;
                liveStartLogs = that.getLogsLiveRow(clickedMarkerDetails, cssClass);
              }

              //history data
              if(this.selectedEventType == eventRange.eventType || this.selectedEventType == eventRange.liveStop){
                this.postData(input, headers)
                .then(function(responseJson) {
                   let filterData = "";
                   if(responseJson && responseJson.data && responseJson.data.result){
                      filterData = responseJson.data.result.resultList;
                      that.updatePaginationDetails(responseJson.data.result.totalPageNum, responseJson.data.result.currentPageNum, responseJson.data.result.totalNum, responseJson.data.result.everyPageNum);
                    }
                    const rowsStartStop = liveStartLogs + that.getLogsHistoryRows(filterData);
                    that.showLogs = rowsStartStop && rowsStartStop.length ? rowsStartStop : that.paragraphElement("", noDataFound);
                  } 
                )
                .catch(err => {console.log(err);}
                );
              }
              else{
                that.showLogs = liveStartLogs && liveStartLogs.length ? liveStartLogs : that.paragraphElement("", noDataFound); 
              }

            }
            else{
              serverCurrentTime = "";
              console.log("Error after fetching data from getTime API");
            }

            this.clearIntervalReloadMarkerAndLogs();
          } 
        ).catch(err => {  
          console.log(err);
          }
        )

        
      },

      /*
      //formate date to yyyy-MM-dd
      */
      formatDate1 : function (date) {
        var dd = date.getDate();
        var mm = date.getMonth() + 1;
        var yyyy = date.getFullYear();
        if (dd < 10) {
          dd = '0' + dd;
        }
        if (mm < 10) {
          mm = '0' + mm;
        }
        return yyyy + '-' + mm + '-' +dd ;
      },

      /*
      //clear interval and reload the marker and logs data 
      */
      clearIntervalReloadMarkerAndLogs: function(){
        let that = this;
        this.clearInterval();
        intervalId = setInterval(
          () => {
            that.setAutoRefeshMode(true);
            that.resetZoomLevelDataBeforeCallAPI();
            that.callAPIAndDisplayData().then(function(){
              /*
              if(that.autoRefeshMode == true && that.isEnableIcon == true) {
                  that.filterHandler();
              }
              */
            })
          },
          refreshTime);
      },
      /*
      // Clear the interval
      */
      clearInterval : function (){

        //console.log("----clearInterval----start----", intervalId);

        if(intervalId){
          //console.log("----clearInterval----");
          clearInterval(intervalId);
          intervalId = "";
        }

        //console.log("----clearInterval----end----", intervalId);
      },

      /*
      // not using 
      */
      filterByEventTypeAndDate: function(){

        //console.log("filterList --> ", filterList);

        let data = this.cloneData(filterList);

        //console.log("data --> ", data);

        let filterData = data.filter(
          jsonObj => {

            // when liveTime in seconds i.e. "liveTime": 1568078362
            return this.startDate <= jsonObj.liveTime * 1000  && this.endDate >= jsonObj.liveTime * 1000  ? true : false ;
            
            // when liveTime in milliseconds i.e. "liveTime": 1568078362000
            //return this.startDate <= jsonObj.liveTime  && this.endDate >= jsonObj.liveTime  ? true : false ;
          }
        )

        return filterData;
      },

      /*
      //set clone data
      */
      cloneData: function(_data){
        var data = JSON.parse(JSON.stringify(_data));
        return data;
      },

      /*
      //Get icon based on the type
      */    
      getIcon: function(_receiverType, _iconType){
        //console.log(_receiverType + " = " + receiver.source + " , "+ _iconType + " = " + icon.default)
        //return require('../images/map-marker_yellow.png');
        let iconImageDyn = markerImageCyan;
        if(_receiverType == receiver.source && _iconType == icon.default){
          iconImageDyn = iconImage.source;
        }else if(_receiverType == receiver.source && _iconType == icon.clicked){
          iconImageDyn = iconImage.sourceClick;
        }else if(_receiverType == receiver.destination && _iconType == icon.default){
          iconImageDyn = iconImage.destination;
        }else if(_receiverType == receiver.destination && _iconType == icon.clicked){
          iconImageDyn = iconImage.destinationClick;
        }

        return iconImageDyn;
      },

      /*
      //Get unique icon based on the _colorIcon
      */    
      getIconNew: function(_colorIcon){
        let iconImageDyn = _colorIcon ? _colorIcon :  markerImageCyan
        return iconImageDyn;
      },

      /*
      //Populate icon list for showing at Overlapping Markers
      */
      populateIconListNew : function(_data, _rpidData, _dataMarkerInstance){
        let length = _data.length;
        let color = markerImageCyan;
        let instance = null;
        let otherInstance = null;

        for(let index=0; index<length; index++ ){
          let id = _data[index];
          let firstInstance = _rpidData[id].instance[0];      
          if(id === _dataMarkerInstance[firstInstance].marker1Coordinates.id){
          instance = _dataMarkerInstance[firstInstance].marker1;
          otherInstance = _dataMarkerInstance[firstInstance].marker2
          if (otherInstance && _rpidData[id].click % 2 == 1) {
            color = markerImageRed;
          }
          else {
            color = markerImageGreen;
          }
          }
          else{
          instance = _dataMarkerInstance[firstInstance].marker2;
          otherInstance = _dataMarkerInstance[firstInstance].marker1;
          if (otherInstance && _rpidData[id].click % 2 == 1) {
            color = markerImageOrange;
          }
          else {
            color = markerImageCyan;
          }          
          }
          if(_rpidData[id].instance.length>1){
            color = markerImagePurple;
          }

          this.$data.images.push({id: index,  url: color, instance: instance });

        }
      },

      /*
      //reset the icon list 
      */
      enableIconList: function(_data=null, _rpidData=null, _dataMarkerInstance=null){
        this.resetPaginationDetails();

        this.lastIconList = _data;
        this.clearIcon();
        this.clearInterval();

        //console.log("enableIconList --> this.mapsOp.map.getZoom() --> " , this.mapsOp.map.getZoom());
        if(_data && _data.length > 0 ){
          this.populateIconListNew(_data, _rpidData, _dataMarkerInstance);  
          this.enableIcon();
          this.filterHandler();
        }
        else{
          //this.clearIntervalReloadMarkerAndLogs();          
          this.disableIcon();
        }              
      },

      /*
      //click event on icon list
      */
      iconsList: function(_instance){
        this.mapsOp.commonClick(_instance);
      },
      
      /*
      //
      */    
      summaryItem: function(e) {
      },

      /*
      //toggle isShow value
      */
      add: function(e) {
        e.preventDefault();
        this.$data.isShow = !this.$data.isShow;
      },

      /*
      //
      */
      changeSummaryData: function(e) {
      },

      /*
      //
      */
      startInterval: function() {
      },

      /*
      //get data from API
      */
      getData(data) {
        return apiDataActions.getData(data);
      },
   
      /*
      //get time from API
      */
      getCurrentTime() {
        return apiDataActions.getCurrentTime();
      },   

      //Get corner data of the screen
      getCornerData(_obj) {
        var bounds = _obj.getBounds();
        var NECorner = bounds.getNorthEast(); //right top
        var SWCorner = bounds.getSouthWest(); //left bottom
        var NWCorner = new google.maps.LatLng({
          lat: NECorner.lat(),
          lng: SWCorner.lng()
        }); //left top
        var SECorner = new google.maps.LatLng({
          lat: SWCorner.lat(),
          lng: NECorner.lng()
        }); //right bottom
        var dataToSend = {
          leftTop: NWCorner.lat() + "," + NWCorner.lng(),
          leftBottom: SWCorner.lat() + "," + SWCorner.lng(),
          rightTop: NECorner.lat() + "," + NECorner.lng(),
          rightBottom: SECorner.lat() + "," + SECorner.lng()
        };
        return dataToSend;
      },

      /*
      //read data and display marker on the page
      */
      showData(_data) {
        this.mapsOp.clearCollection();
        var length = 0;
        if (_data) length = _data.length;
        for (let index = 0; index < length; index++) {
            //get data
            var coordinates = [];
            if (_data[index].peerLat && _data[index].peerLng) {
                  coordinates.push({
                    lat: _data[index].peerLat * 1,
                    lng: _data[index].peerLng * 1,
                    peerID: _data[index].peerID,
                    id: _data[index].peerID,
                    receiverName:_data[index] && _data[index].peerReceiverName ? _data[index].peerReceiverName :"",
                    receiverAccount:_data[index] && _data[index].peerReceiverAccount ? _data[index].peerReceiverAccount :"",
                    receiverGroupName:_data[index] && _data[index].peerReceiverGroupName ? _data[index].peerReceiverGroupName : "",
                    liveTime:_data[index].liveTime,
                    liveStartTime: _data[index].liveStartTime
                  });
            }
            if (_data[index].livePeerLat && _data[index].livePeerLng) {
                  coordinates.push({
                    lat: _data[index].livePeerLat * 1,
                    lng: _data[index].livePeerLng * 1,
                    livePeerID: _data[index].livePeerID,
                    id: _data[index].livePeerID,
                    receiverName:_data[index] && _data[index].livePeerReceiverName ? _data[index].livePeerReceiverName : "",
                    receiverAccount:_data[index] && _data[index].livePeerReceiverAccount ? _data[index].livePeerReceiverAccount : "",
                    receiverGroupName:_data[index] && _data[index].livePeerReceiverGroupName ? _data[index].livePeerReceiverGroupName : "",
                    liveTime:_data[index].liveTime,
                    liveStartTime: _data[index].liveStartTime
                  });
            }

            //Create marker on the above data
            this.mapsOp.createMarker(coordinates, index);

            //Calculate popup data
            this.mapsOp.popupData(_data[index]);

            //Create line/curve and click listener
            this.mapsOp.polylineAndClickListener(coordinates, index);
          }

          //Create listener on marker and popup
          this.mapsOp.addMarkerListener();

          //Enable icon list at overlapping markers
          this.mapsOp.parentEnableIconList(this.enableIconList);

          const clickedMarkerDetails = this.mapsOp.getClickedMarkerDetails();
          if(clickedMarkerDetails && clickedMarkerDetails.activeInstance){
	          this.mapsOp.commonClick(clickedMarkerDetails[clickedMarkerDetails.activeInstance]);
          }
          else{
            this.mapsOp.commonClick();
            //Disable the icon when we click on the line or curve
            this.mapsOp.parentDisableIcon(this.disableIcon);
          }

          //for testing....
         //this.mapsOp.commonClick(this.mapsOp.test());
      },

      /*
      //successfully read the data from API call and display data on page
      */
      successHandle(_data) {
          if(_data && _data.data){
            
                //assigning data to 
                let cloneResponseData =  this.cloneData(responseData);

                //console.log("successHandle --> responseData --> ", responseData);
                //console.log("successHandle --> start line --> this.IsZoomProjection --> ", this.IsZoomProjection)

                //console.log("_data.data--> ", _data.data);
                //responseData = _data.data.slice(0, 1);
                responseData = _data.data;
                //responseData = [  { "receiverName":"receiverName101", "receiverAccount":"receiveraccount101",   "peerID": "e2652720983d70c2",    "peerLat": "37.7131",    "peerLng": "-122.0381",    "livePeerID": "55524c204558544c",    "livePeerLat": null,    "livePeerLng": null,    "liveTime": 18087564  },  { "receiverName":"receiverName202", "receiverAccount":"receiveraccount202",   "peerID": "43fcf400d0085a1a",    "peerLat": "37.7131",    "peerLng": "-122.0381",    "livePeerID": "55524c204558544c",    "livePeerLat": null,    "livePeerLng": null,    "liveTime": 17487884  }];
                //responseData = [  {    "peerID": "d3f488f868a61ccc",    "peerLat": "45.4707",    "peerLng": "9.1889",    "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842",    "livePeerLng": "-84.3761",    "liveTime": 78848  },  {    "peerID": "63e4082a5db62071",    "peerLat": "31.0429665",    "peerLng": "121.4058353",    "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842",    "livePeerLng": "-84.3761",    "liveTime": 52246015  },  {    "peerID": "57b82baa5d951b15",    "peerLat": "37.5120813",    "peerLng": "126.9791609",    "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842",    "livePeerLng": "-84.3761",    "liveTime": 52218352  },    {    "peerID": "bd66ce3542cf0603",    "peerLat": "37.5120813",    "peerLng": "126.9791609",    "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842",    "livePeerLng": "-84.3761",    "liveTime": 52006779  },   {    "peerID": "7b908b6af473dbc5",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842",    "livePeerLng": "-84.3761",    "liveTime": 128687991  }  ];
                //responseData =  [  {    "peerID": "d3f488f868a61ccc",    "peerLat": "45.4707",    "peerLng": "9.1889",    "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842",    "livePeerLng": "-84.3761",    "liveTime": 78848  },  {    "peerID": "63e4082a5db62071",    "peerLat": "31.0429665",    "peerLng": "121.4058353",    "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842",    "livePeerLng": "-84.3761",    "liveTime": 52246015  }];
                //responseData = [  { "peerReceiverName":"peerReceiverName101", "peerReceiverAccount":"peerReceiverAccount101",  "peerReceiverGroupName":"peerReceiverGroupName101",    "peerID": "e2652720983d70c2",    "peerLat": "37.7131",    "peerLng": "-122.0381",   "livePeerReceiverName": "livePeerReceiverName101", "livePeerReceiverAccount":"livePeerReceiverAccount101","livePeerReceiverGroupName":"livePeerReceiverGroupName101",   "livePeerID": "55524c204558544c",    "livePeerLat": null,    "livePeerLng": null,    "liveTime": 18087564  },  { "peerReceiverName":"peerReceiverName202", "peerReceiverAccount":"peerReceiverAccount202",   "peerID": "43fcf400d0085a1a",    "peerLat": "37.7131",    "peerLng": "-122.0381", "livePeerReceiverName": "livePeerReceiverName202", "livePeerReceiverAccount":"livePeerReceiverAccount202", "livePeerReceiverGroupName":"livePeerReceiverGroupName202",    "livePeerID": "55524c204558544c", "peerReceiverGroupName":"peerReceiverGroupName202",     "livePeerLat": null,    "livePeerLng": null,    "liveTime": 17487884  }];
                //responseData =  [ 		{ "peerReceiverName":"peerReceiverName101", "peerReceiverAccount":"TVU Networks Shanghai Warehouse 101",  "peerReceiverGroupName":"top account 101",    "peerID": "d3f488f868a61ccc",    "peerLat": "45.4707", "peerLng": "9.1889",  "livePeerReceiverName": "livePeerReceiverNameLive101", "livePeerReceiverAccount":"TVU Networks Shanghai Warehouse live101", "livePeerReceiverGroupName":"top account Live101",  "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842", "livePeerLng": "-84.3761", "liveTime": 78848  },				{ "peerReceiverName":"peerReceiverName202", "peerReceiverAccount":"TVU Networks Shanghai Warehouse 202", "peerReceiverGroupName":"top account 202",  "peerID": "63e4082a5db62071",    "peerLat": "31.0429665",    "peerLng": "121.4058353", "livePeerReceiverName": "livePeerReceiverNameLive202", "livePeerReceiverAccount":"TVU Networks Shanghai Warehouse live202", "livePeerReceiverGroupName":"top account Live202", "livePeerID": "83cca10aa0972b15", "livePeerLat": "33.8842", "livePeerLng": "-84.3761", "liveTime": 52246015  }	];
                //responseData =  [ { "peerReceiverName":"peerReceiverName101", "peerReceiverAccount":"TVU Networks Shanghai Warehouse 101",  "peerReceiverGroupName":"top account 101",    "peerID": "d3f488f868a61ccc",    "peerLat": "45.4707", "peerLng": "9.1889",  "livePeerReceiverName": "livePeerReceiverNameLive101", "livePeerReceiverAccount":"TVU Networks Shanghai Warehouse live101", "livePeerReceiverGroupName":"top account Live101",  "livePeerID": "83cca10aa0972b15",    "livePeerLat": "33.8842", "livePeerLng": "-84.3761", "liveTime": 78848  },{ "peerReceiverName":"peerReceiverName202", "peerReceiverAccount":"TVU Networks Shanghai Warehouse 202", "peerReceiverGroupName":"top account 202",  "peerID": "63e4082a5db62071",    "peerLat": "31.0429665",    "peerLng": "31.0429665", "livePeerReceiverName": "livePeerReceiverNameLive202", "livePeerReceiverAccount":"TVU Networks Shanghai Warehouse live202", "livePeerReceiverGroupName":"top account Live202", "livePeerID": "83cca10aa0972b15", "livePeerLat": "33.8842", "livePeerLng": "-84.3761", "liveTime": 52246015  }, { "peerReceiverName":"peerReceiverName303", "peerReceiverAccount":"TVU Networks Shanghai Warehouse 303", "peerReceiverGroupName":"top account 303",  "peerID": "d3f488f868a61ccc",    "peerLat": "45.4707",    "peerLng": "9.1889", "livePeerReceiverName": "livePeerReceiverNameLive303", "livePeerReceiverAccount":"TVU Networks Shanghai Warehouse live303", "livePeerReceiverGroupName":"top account Live303", "livePeerID": "63e4082a5db62071", "livePeerLat": "31.0429665", "livePeerLng": "31.0429665", "liveTime": 52246015  }];        
                //responseData = [{"peerID":"5d53da972645e615","peerLat":"48","peerLng":"68","livePeerID":"839ba40c0e549c5d","livePeerLat":"51.1811","livePeerLng":"71.4278","liveTime":27383033},{"peerID":"34526439d7ef73fb","peerLat":"48","peerLng":"68","livePeerID":"34526439d7ef73fb","livePeerLat":"48","livePeerLng":"68","liveTime":41033564},{"peerID":"5d53da972645e615","peerLat":"48","peerLng":"68","livePeerID":"839ba40c0e549c5d","livePeerLat":"51.1811","livePeerLng":"71.4278","liveTime":27383033},{"peerID":"f5a86593cc1c960f","peerLat":"48","peerLng":"68","livePeerID":"d831cfb9ef7a976e","livePeerLat":"43.2648872","livePeerLng":"76.9320014","liveTime":2663332}];
                //responseData = [{"peerID":"34526439d7ef73fb111111111","peerLat":"48","peerLng":"68","livePeerID":"34526439d7ef73fb22222222222222","livePeerLat":"48","livePeerLng":"68","liveTime":41033564}];
                //responseData = [ { "peerID": "598392a3a6d2d5fa",  "peerLat": "48", "peerLng": "68", "livePeerID": "55524c2045585420",  "livePeerLat": "40",        "livePeerLng": "60",        "liveTime": 13405478,        "peerReceiverName": "name1",        "peerReceiverAccount": "account1",        "peerReceiverAffiliation": "affiliation1",        "peerReceiverGroupName": "groupname1",        "livePeerReceiverName": "name12",        "livePeerReceiverAccount": "account12",        "livePeerReceiverAffiliation": "affiliation12",        "livePeerReceiverGroupName": "groupname12",        "peerCountry": "USA",        "livePeerCountry": "USA"    } ,  { "peerID": "598392a3a6d2d5fa",  "peerLat": "30", "peerLng": "50", "livePeerID": "55524c2045585420",  "livePeerLat": "35",        "livePeerLng": "55",        "liveTime": 13405478,        "peerReceiverName": "peerReceiverName18292",        "peerReceiverAccount": "peerReceiverAccount1211",        "peerReceiverAffiliation": "peerReceiverAffiliation05928",        "peerReceiverGroupName": "peerReceiverGroupName12312",        "livePeerReceiverName": "livePeerReceiverName1234",        "livePeerReceiverAccount": "livePeerReceiverAccount2323",        "livePeerReceiverAffiliation": "livePeerReceiverAffiliation378493",        "livePeerReceiverGroupName": "livePeerReceiverGroupName12312",        "peerCountry": "india",        "livePeerCountry": "UK"    }	];
                //responseData = [{"peerID":"be165601df16009d","peerLat":"-14.7989","peerLng":"-57.4289","livePeerID":"331b028afa6eb8b8","livePeerLat":"-11.7641","livePeerLng":"-55.4402","liveTime":85529549,"peerReceiverName":"ROTA_TGS_CBA","peerReceiverAccount":"TV Centro America (TVCA)","peerReceiverAffiliation":null,"peerReceiverGroupName":"Line Up","livePeerReceiverName":"ROTA_SNP_CBA","livePeerReceiverAccount":"TV Centro America (TVCA)","livePeerReceiverAffiliation":null,"livePeerReceiverGroupName":"Line Up","peerCountry":"Brazil","livePeerCountry":"Brazil"},{"peerID":"331b028afa6eb8b8","peerLat":"-11.7641","peerLng":"-55.4402","livePeerID":"251a1b63c4a797dc","livePeerLat":"-16.2053","livePeerLng":"-54.8803","liveTime":108812245,"peerReceiverName":"ROTA_SNP_CBA","peerReceiverAccount":"TV Centro America (TVCA)","peerReceiverAffiliation":null,"peerReceiverGroupName":"Line Up","livePeerReceiverName":"ROTA_CBA_SNP","livePeerReceiverAccount":"TV Centro America (TVCA)","livePeerReceiverAffiliation":null,"livePeerReceiverGroupName":"Line Up","peerCountry":"Brazil","livePeerCountry":"Brazil"}];
                //responseData = [{"peerID":"be165601df16009d","peerLat":"-14.7989","peerLng":"-57.4289","livePeerID":"331b028afa6eb8b8","livePeerLat":"-11.7641","livePeerLng":"-55.4402","liveTime":85529549,"peerReceiverName":"ROTA_TGS_CBA","peerReceiverAccount":"TV Centro America (TVCA)","peerReceiverAffiliation":null,"peerReceiverGroupName":"Line Up","livePeerReceiverName":"ROTA_SNP_CBA","livePeerReceiverAccount":"TV Centro America (TVCA)","livePeerReceiverAffiliation":null,"livePeerReceiverGroupName":"Line Up","peerCountry":"Brazil","livePeerCountry":"Brazil"}];
                //responseData = [{"peerID":"331b028afa6eb8b8","peerLat":"-11.7641","peerLng":"-55.4402","livePeerID":"251a1b63c4a797dc","livePeerLat":"-16.2053","livePeerLng":"-54.8803","liveTime":108812245,"peerReceiverName":"ROTA_SNP_CBA","peerReceiverAccount":"TV Centro America (TVCA)","peerReceiverAffiliation":null,"peerReceiverGroupName":"Line Up","livePeerReceiverName":"ROTA_CBA_SNP","livePeerReceiverAccount":"TV Centro America (TVCA)","livePeerReceiverAffiliation":null,"livePeerReceiverGroupName":"Line Up","peerCountry":"Brazil","livePeerCountry":"Brazil"}];

                //responseData = [	{    "peerID": "e6a8c581a7c06004",    "peerLat": "55.7527",    "peerLng": "37.6172",    "livePeerID": "e6a8c581a7c06004",    "livePeerLat": "55.7527",    "livePeerLng": "37.6172",    "liveTime": 34547,    "peerReceiverName": "RegionalTVU3",    "peerReceiverAccount": "TVU Test Account",    "peerReceiverAffiliation": "Not applicable",    "peerReceiverGroupName": "TVU Test Account",    "livePeerReceiverName": "RegionalTVU3",    "livePeerReceiverAccount": "TVU Test Account",    "livePeerReceiverAffiliation": "Not applicable",    "livePeerReceiverGroupName": "TVU Test Account",    "peerCountry": "Russia",    "livePeerCountry": "Russia"	},    {    "peerID": "48a79f02aece1810",    "peerLat": "55.7386",    "peerLng": "37.6068",    "livePeerID": "48a79f02aece1810",    "livePeerLat": "55.7386",    "livePeerLng": "37.6068",    "liveTime": 96249,    "peerReceiverName": "RegionalTVU4",    "peerReceiverAccount": "TVU Test Account",    "peerReceiverAffiliation": "Not applicable",    "peerReceiverGroupName": "TVU Test Account",    "livePeerReceiverName": "RegionalTVU4",    "livePeerReceiverAccount": "TVU Test Account",    "livePeerReceiverAffiliation": "Not applicable",    "livePeerReceiverGroupName": "TVU Test Account",    "peerCountry": "Russia",    "livePeerCountry": "Russia"	},	{    "peerID": "308be907f9b03c09",    "peerLat": "55.7386",    "peerLng": "37.6068",    "livePeerID": "308be907f9b03c09",    "livePeerLat": "55.7386",    "livePeerLng": "37.6068",    "liveTime": 34609,    "peerReceiverName": "RegionalTVU8",    "peerReceiverAccount": null,    "peerReceiverAffiliation": null,    "peerReceiverGroupName": null,    "livePeerReceiverName": "RegionalTVU8",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "Russia",    "livePeerCountry": "Russia"  },    {    "peerID": "2fcfdd3a442db2aa",    "peerLat": "55.7386",    "peerLng": "37.6068",    "livePeerID": "2fcfdd3a442db2aa",    "livePeerLat": "55.7386",    "livePeerLng": "37.6068",    "liveTime": 34863,    "peerReceiverName": "RegionalTVU5",    "peerReceiverAccount": "TVU Russia",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "TVU Networks Corporation",    "livePeerReceiverName": "RegionalTVU5",    "livePeerReceiverAccount": "TVU Russia",    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": "TVU Networks Corporation",    "peerCountry": "Russia",    "livePeerCountry": "Russia"  }];
                //responseData = [  {    "peerID": "ba3e17e7ebdb1437",    "peerLat": "-6.1741",    "peerLng": "106.8296",    "livePeerID": "28c6ddde91d4faa5",    "livePeerLat": "33.8621",    "livePeerLng": "-84.4198",    "liveTime": 150648,    "peerReceiverName": "TVU_R1437",    "peerReceiverAccount": "ADM",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "ADM",    "livePeerReceiverName": "CNNi_R04",    "livePeerReceiverAccount": "CNNewsource",    "livePeerReceiverAffiliation": "Other;Not applicable",    "livePeerReceiverGroupName": "Turner Broadcasting",    "peerCountry": "Indonesia",    "livePeerCountry": "United States"  },{    "peerID": "11d048c384055184",    "peerLat": "23.4949538",    "peerLng": "121.0076455",    "livePeerID": "28c6ddde91d4faa5",    "livePeerLat": "33.8621",    "livePeerLng": "-84.4198",    "liveTime": 143489832,    "peerReceiverName": "TVU_RBYVS6511",    "peerReceiverAccount": "TTV (Tawian television)",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "TTV (Tawian television)",    "livePeerReceiverName": "CNNi_R04",    "livePeerReceiverAccount": "CNNewsource",    "livePeerReceiverAffiliation": "Other;Not applicable",    "livePeerReceiverGroupName": "Turner Broadcasting",    "peerCountry": "Taiwan",    "livePeerCountry": "United States"  },  {    "peerID": "eceb861960fcc49b",    "peerLat": "25.0449374",    "peerLng": "121.5356557",    "livePeerID": "28c6ddde91d4faa5",    "livePeerLat": "33.8621",    "livePeerLng": "-84.4198",    "liveTime": 72868890,    "peerReceiverName": "TVU_RBYPSF038",    "peerReceiverAccount": "TVBS",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "TVBS",    "livePeerReceiverName": "CNNi_R04",    "livePeerReceiverAccount": "CNNewsource",    "livePeerReceiverAffiliation": "Other;Not applicable",    "livePeerReceiverGroupName": "Turner Broadcasting",    "peerCountry": "Taiwan",    "livePeerCountry": "United States"  },  {    "peerID": "9c4babc044d197a1",    "peerLat": "23.4949538",    "peerLng": "121.0076455",    "livePeerID": "28c6ddde91d4faa5",    "livePeerLat": "33.8621",    "livePeerLng": "-84.4198",    "liveTime": 4166109,    "peerReceiverName": "TVU_RBYJBDB7A",    "peerReceiverAccount": "CTS Taiwan",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "CTS Taiwan",    "livePeerReceiverName": "CNNi_R04",    "livePeerReceiverAccount": "CNNewsource",    "livePeerReceiverAffiliation": "Other;Not applicable",    "livePeerReceiverGroupName": "Turner Broadcasting",    "peerCountry": "Taiwan",    "livePeerCountry": "United States"  },  {    "peerID": "5e51ab3a4cc09552",    "peerLat": "52.3824",    "peerLng": "4.8995",    "livePeerID": "28c6ddde91d4faa5",    "livePeerLat": "33.8621",    "livePeerLng": "-84.4198",    "liveTime": 65430289,    "peerReceiverName": "RTL_TVU_1",    "peerReceiverAccount": "RTL Nederland",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "RTL Nederland",    "livePeerReceiverName": "CNNi_R04",    "livePeerReceiverAccount": "CNNewsource",    "livePeerReceiverAffiliation": "Other;Not applicable",    "livePeerReceiverGroupName": "Turner Broadcasting",    "peerCountry": "Netherlands",    "livePeerCountry": "United States"  },  {    "peerID": "f2b83979bcedeff7",    "peerLat": "25.0420646",    "peerLng": "121.5394998",    "livePeerID": "28c6ddde91d4faa5",    "livePeerLat": "33.8621",    "livePeerLng": "-84.4198",    "liveTime": 88680911,    "peerReceiverName": "TVU_RBYZY056E",    "peerReceiverAccount": "Next TV News Taiwan",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "Next TV News Taiwan",    "livePeerReceiverName": "CNNi_R04",    "livePeerReceiverAccount": "CNNewsource",    "livePeerReceiverAffiliation": "Other;Not applicable",    "livePeerReceiverGroupName": "Turner Broadcasting",    "peerCountry": "Taiwan",    "livePeerCountry": "United States"  }];
                //responseData = [{    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //responseData = [ {    "peerID": "4d395edab05ed484",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "796b90410c9297e3",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },{    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "ef7755e3d19d4867",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "ef7755e3d19d4867",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 211234347,    "peerReceiverName": "KBNT_1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "KBNT_1",    "livePeerReceiverAccount": "KBNT-TV",    "livePeerReceiverAffiliation": "Univision",    "livePeerReceiverGroupName": "Entravision Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "78bb95f307e408eb",    "peerLat": "33.1366",    "peerLng": "-117.0611",    "livePeerID": "ef7755e3d19d4867",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 5733376,    "peerReceiverName": "KVYE_R1",    "peerReceiverAccount": "KVYE-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "KBNT_1",    "livePeerReceiverAccount": "KBNT-TV",    "livePeerReceiverAffiliation": "Univision",    "livePeerReceiverGroupName": "Entravision Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "5071304e2445e200",    "peerLat": "44.991",    "peerLng": "-122.7627",    "livePeerID": "ef7755e3d19d4867",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 16205079,    "peerReceiverName": "KSMS_R1",    "peerReceiverAccount": "KSMS-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "KBNT_1",    "livePeerReceiverAccount": "KBNT-TV",    "livePeerReceiverAffiliation": "Univision",    "livePeerReceiverGroupName": "Entravision Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }, {    "peerID": "75c2142ad26a074e",    "peerLat": "33.8584",    "peerLng": "-118.2554",    "livePeerID": "ef7755e3d19d4867",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 5735235,    "peerReceiverName": "KMIR_R1old",    "peerReceiverAccount": "KRCX-FM",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "KBNT_1",    "livePeerReceiverAccount": "KBNT-TV",    "livePeerReceiverAffiliation": "Univision",    "livePeerReceiverGroupName": "Entravision Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "497bca6966f53655",    "peerLat": "33.8584",    "peerLng": "-118.2554",    "livePeerID": "ef7755e3d19d4867",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 52383467,    "peerReceiverName": "KVER_R1",    "peerReceiverAccount": "KVER-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "KBNT_1",    "livePeerReceiverAccount": "KBNT-TV",    "livePeerReceiverAffiliation": "Univision",    "livePeerReceiverGroupName": "Entravision Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];

                //same lat and lng with different PID 
                //responseData =   [  {    "peerID": "4d395edab05ed484",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "796b90410c9297e3",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
        
                //color error ...
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "4d395edab05ed484",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "796b90410c9297e3",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //responseData = [  {    "peerID": "4d395edab05ed484",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "796b90410c9297e3",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                  
                //color error ...
                //responseData = [  {    "peerID": "1111111111",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "22222222222",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "3333333333",    "peerLat": "48.7967",    "peerLng": "-100.1367",    "livePeerID": "44444444444",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 5344345,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //color error ...
                //responseData = [  {    "peerID": "b3e6ed8a2bf258a9",    "peerLat": "32.7691",    "peerLng": "-96.6053",    "livePeerID": "84738ab79b475ac6",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 17474530,    "peerReceiverName": "Molasky_Recei",    "peerReceiverAccount": null,    "peerReceiverAffiliation": null,    "peerReceiverGroupName": null,    "livePeerReceiverName": "Molasky_Skycam",    "livePeerReceiverAccount": "KLAS-TV",    "livePeerReceiverAffiliation": "CBS",    "livePeerReceiverGroupName": "Nexstar Media Group",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "b2ccb91ba6944920",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "5dca249eacc9610f",    "livePeerLat": "33.51859",    "livePeerLng": "-86.81036",    "liveTime": 17293226,    "peerReceiverName": "WESH_TVUGR4",    "peerReceiverAccount": "WESH TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Hearst",    "livePeerReceiverName": "WVTM_TVUGR2",    "livePeerReceiverAccount": "WVTM-TV",    "livePeerReceiverAffiliation": "NBC",    "livePeerReceiverGroupName": "Hearst",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "edb0cc2590ac449a",    "peerLat": "32.2508",    "peerLng": "-80.8718",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 6161233,    "peerReceiverName": "WSAV_Lottery",    "peerReceiverAccount": "WSAV-TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];

                // no self pointed data  and unique with five outcoming
                //color error ...
                //responseData = [ {    "peerID": "39d106d4b3150be0",    "peerLat": "33.4724",    "peerLng": "-82.0889",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "edb0cc2590ac449a",    "peerLat": "32.2508",    "peerLng": "-80.8718",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 7068291,    "peerReceiverName": "WSAV_Lottery",    "peerReceiverAccount": "WSAV-TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "462d2d3e861b1863",    "peerLat": "33.8206",    "peerLng": "-84.0229",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 34911723,    "peerReceiverName": "WALB_Lottery",    "peerReceiverAccount": "WSB-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Cox Communications",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "7de1b9da9c55e5b2",    "peerLat": "32.4783",    "peerLng": "-84.8985",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 6081237,    "peerReceiverName": "WRBL_Lottery",    "peerReceiverAccount": "WRBL",    "peerReceiverAffiliation": "CBS",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },{    "peerID": "1299dd6f8faad555",    "peerLat": "32.8609",    "peerLng": "-83.61514",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 36621119,    "peerReceiverName": "WMAZ_Lottery",    "peerReceiverAccount": "WMAZ-TV",    "peerReceiverAffiliation": "CBS;Not applicable",    "peerReceiverGroupName": "TEGNA Inc.",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];


                //please test below line also because first one is source and destinaton are same
                
                //color error ...        
                //responseData = [{    "peerID": "989b0ee9a0886cdb",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 4491384,    "peerReceiverName": "Lottery_WSB",    "peerReceiverAccount": "WSB-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Cox Communications",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "39d106d4b3150be0",    "peerLat": "33.4724",    "peerLng": "-82.0889",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "edb0cc2590ac449a",    "peerLat": "32.2508",    "peerLng": "-80.8718",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 7068291,    "peerReceiverName": "WSAV_Lottery",    "peerReceiverAccount": "WSAV-TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "462d2d3e861b1863",    "peerLat": "33.8206",    "peerLng": "-84.0229",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 34911723,    "peerReceiverName": "WALB_Lottery",    "peerReceiverAccount": "WSB-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Cox Communications",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "7de1b9da9c55e5b2",    "peerLat": "32.4783",    "peerLng": "-84.8985",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 6081237,    "peerReceiverName": "WRBL_Lottery",    "peerReceiverAccount": "WRBL",    "peerReceiverAffiliation": "CBS",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },{    "peerID": "1299dd6f8faad555",    "peerLat": "32.8609",    "peerLng": "-83.61514",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 36621119,    "peerReceiverName": "WMAZ_Lottery",    "peerReceiverAccount": "WMAZ-TV",    "peerReceiverAffiliation": "CBS;Not applicable",    "peerReceiverGroupName": "TEGNA Inc.",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //suffle some data from above point 
                
                //color error ...                
                //responseData = [  {    "peerID": "989b0ee9a0886cdb",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 4491384,    "peerReceiverName": "Lottery_WSB",    "peerReceiverAccount": "WSB-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Cox Communications",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "989b0ee9a0886cdb",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "39d106d4b3150be0",    "livePeerLat": "33.4724",    "livePeerLng": "-82.0889",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "edb0cc2590ac449a",    "peerLat": "32.2508",    "peerLng": "-80.8718",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 7068291,    "peerReceiverName": "WSAV_Lottery",    "peerReceiverAccount": "WSAV-TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "462d2d3e861b1863",    "peerLat": "33.8206",    "peerLng": "-84.0229",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 34911723,    "peerReceiverName": "WALB_Lottery",    "peerReceiverAccount": "WSB-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Cox Communications",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "7de1b9da9c55e5b2",    "peerLat": "32.4783",    "peerLng": "-84.8985",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 6081237,    "peerReceiverName": "WRBL_Lottery",    "peerReceiverAccount": "WRBL",    "peerReceiverAffiliation": "CBS",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1299dd6f8faad555",    "peerLat": "32.8609",    "peerLng": "-83.61514",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 36621119,    "peerReceiverName": "WMAZ_Lottery",    "peerReceiverAccount": "WMAZ-TV",    "peerReceiverAffiliation": "CBS;Not applicable",    "peerReceiverGroupName": "TEGNA Inc.",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];

                //one data set
                //responseData = [ {    "peerID": "989b0ee9a0886cdb",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "39d106d4b3150be0",    "livePeerLat": "33.4724",    "livePeerLng": "-82.0889",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                // two data set
                //responseData = [{    "peerID": "989b0ee9a0886cdb",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "39d106d4b3150be0",    "livePeerLat": "33.4724",    "livePeerLng": "-82.0889",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "edb0cc2590ac449a",    "peerLat": "32.2508",    "peerLng": "-80.8718",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 7068291,    "peerReceiverName": "WSAV_Lottery",    "peerReceiverAccount": "WSAV-TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //responseData = [  {    "peerID": "edb0cc2590ac449a",    "peerLat": "32.2508",    "peerLng": "-80.8718",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 7068291,    "peerReceiverName": "WSAV_Lottery",    "peerReceiverAccount": "WSAV-TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "989b0ee9a0886cdb",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "39d106d4b3150be0",    "livePeerLat": "33.4724",    "livePeerLng": "-82.0889",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }    ];

                // same lat and lng with same PID  
                //responseData = [	  {		"peerID": "1ae8163d39ef3c9b",		"peerLat": "32.7967",		"peerLng": "-117.1367",		"livePeerID": "f0dc8d2edc81ac5f",		"livePeerLat": "40.7308",		"livePeerLng": "-73.9975",		"liveTime": 22203455,		"peerReceiverName": "KITV_Reciv",		"peerReceiverAccount": "KITV-TV",		"peerReceiverAffiliation": "ABC",		"peerReceiverGroupName": "SJL Broadcast Management",		"livePeerReceiverName": "NY13_Reciv",		"livePeerReceiverAccount": "ABC News",		"livePeerReceiverAffiliation": "ABC",		"livePeerReceiverGroupName": "The Walt Disney Company",		"peerCountry": "United States",		"livePeerCountry": "United States"	  },	  {		"peerID": "1ae8163d39ef3c9b",		"peerLat": "32.7967",		"peerLng": "-117.1367",		"livePeerID": "1ae8163d39ef3c9b",		"livePeerLat": "32.7967",		"livePeerLng": "-117.1367",		"liveTime": 93363309,		"peerReceiverName": "XHAS_R1",		"peerReceiverAccount": "KBNT-TV",		"peerReceiverAffiliation": "Univision",		"peerReceiverGroupName": "Entravision Communications",		"livePeerReceiverName": "XHAS_R1_OLD",		"livePeerReceiverAccount": null,		"livePeerReceiverAffiliation": null,		"livePeerReceiverGroupName": null,		"peerCountry": "United States",		"livePeerCountry": "United States"	  }	]

                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999",    "livePeerLat": "42.7967",    "livePeerLng": "-67.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];

                //unique with one incoming and one outcoming i.e. purple marker have one end simple marker and another end simple marker 
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "2132asdasd12323q",    "peerLat": "42.7967",    "peerLng": "-117.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //unique with two incoming and one outcoming
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }  ,  {    "peerID": "asasdasd123323",    "peerLat": "48.7967",    "peerLng": "-100.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 5344345,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                
                //unique with two outcoming
                //responseData = [  {    "peerID": "2132asdasd12323q",    "peerLat": "42.7967",    "peerLng": "-117.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "asasdasd123323",    "peerLat": "48.7967",    "peerLng": "-100.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 5344345,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //unique with two incoming
                //responseData = [	  {		"peerID": "1ae8163d39ef3c9b",		"peerLat": "32.7967",		"peerLng": "-117.1367",		"livePeerID": "f0dc8d2edc81ac5f",		"livePeerLat": "40.7308",		"livePeerLng": "-73.9975",		"liveTime": 22203455,		"peerReceiverName": "KITV_Reciv",		"peerReceiverAccount": "KITV-TV",		"peerReceiverAffiliation": "ABC",		"peerReceiverGroupName": "SJL Broadcast Management",		"livePeerReceiverName": "NY13_Reciv",		"livePeerReceiverAccount": "ABC News",		"livePeerReceiverAffiliation": "ABC",		"livePeerReceiverGroupName": "The Walt Disney Company",		"peerCountry": "United States",		"livePeerCountry": "United States"	  },	  {		"peerID": "1ae8163d39ef3c9b",		"peerLat": "32.7967",		"peerLng": "-117.1367",		"livePeerID": "2132asdasd12323q",		"livePeerLat": "42.7967",		"livePeerLng": "-117.1367",		"liveTime": 93363309,		"peerReceiverName": "XHAS_R1",		"peerReceiverAccount": "KBNT-TV",		"peerReceiverAffiliation": "Univision",		"peerReceiverGroupName": "Entravision Communications",		"livePeerReceiverName": "XHAS_R1_OLD",		"livePeerReceiverAccount": null,		"livePeerReceiverAffiliation": null,		"livePeerReceiverGroupName": null,		"peerCountry": "United States",		"livePeerCountry": "United States"	  }	];
                //unique with two outcoming and two incoming
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f123",    "peerLat": "41.7308",    "peerLng": "-83.9975",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f456",    "peerLat": "44.7308",    "peerLng": "-63.9975",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]

                // first unique with two incoming and second unique with one incoming and one outcoming
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999",    "livePeerLat": "42.7967",    "livePeerLng": "-67.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //shuffle 
                //responseData = [   {     "peerID": "1ae8163d39ef3c9b",     "peerLat": "32.7967",     "peerLng": "-117.1367",     "livePeerID": "2132asdasd12323q",     "livePeerLat": "42.7967",     "livePeerLng": "-117.1367",     "liveTime": 93363309,     "peerReceiverName": "XHAS_R1",     "peerReceiverAccount": "KBNT-TV",     "peerReceiverAffiliation": "Univision",     "peerReceiverGroupName": "Entravision Communications",     "livePeerReceiverName": "XHAS_R1_OLD",     "livePeerReceiverAccount": null,     "livePeerReceiverAffiliation": null,     "livePeerReceiverGroupName": null,     "peerCountry": "United States",     "livePeerCountry": "United States"   },   {     "peerID": "f0dc8d2edc81ac5f",     "peerLat": "40.7308",     "peerLng": "-93.9975",     "livePeerID": "9ae8163d39ef3999",     "livePeerLat": "42.7967",     "livePeerLng": "-67.1367",     "liveTime": 22203455,     "peerReceiverName": "KITV_Reciv",     "peerReceiverAccount": "KITV-TV",     "peerReceiverAffiliation": "ABC",     "peerReceiverGroupName": "SJL Broadcast Management",     "livePeerReceiverName": "NY13_Reciv",     "livePeerReceiverAccount": "ABC News",     "livePeerReceiverAffiliation": "ABC",     "livePeerReceiverGroupName": "The Walt Disney Company",     "peerCountry": "United States",     "livePeerCountry": "United States"   },   {     "peerID": "1ae8163d39ef3c9b",     "peerLat": "32.7967",     "peerLng": "-117.1367",     "livePeerID": "f0dc8d2edc81ac5f",     "livePeerLat": "40.7308",     "livePeerLng": "-93.9975",     "liveTime": 22203455,     "peerReceiverName": "KITV_Reciv",     "peerReceiverAccount": "KITV-TV",     "peerReceiverAffiliation": "ABC",     "peerReceiverGroupName": "SJL Broadcast Management",     "livePeerReceiverName": "NY13_Reciv",     "livePeerReceiverAccount": "ABC News",     "livePeerReceiverAffiliation": "ABC",     "livePeerReceiverGroupName": "The Walt Disney Company",     "peerCountry": "United States",     "livePeerCountry": "United States"   } ]
                
                // first unique with one incoming and one outcoming and second unique with two incoming
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999",    "livePeerLat": "42.7967",    "livePeerLng": "-67.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //responseData = [   {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }, {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999",    "livePeerLat": "42.7967",    "livePeerLng": "-67.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //responseData = [  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999",    "livePeerLat": "42.7967",    "livePeerLng": "-67.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                // still error ???
                //responseData = [  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999",    "livePeerLat": "42.7967",    "livePeerLng": "-67.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }];

                //two data set , 
                //first data is one to one and 
                //second is unique
                //first unique with two incoming and second unique with two outcoming 
                //responseData = [ {    "peerID": "989b0ee9a0886cdb",    "peerLat": "37.751",    "peerLng": "-97.822",    "livePeerID": "39d106d4b3150be0",    "livePeerLat": "33.4724",    "livePeerLng": "-82.0889",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },   {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];

                //first unique with two incoming and second unique with two outcoming
                //first
                //responseData = [   {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                
                //responseData = [   {     "peerID": "1ae8163d39ef3c9b",     "peerLat": "32.7967",     "peerLng": "-117.1367",     "livePeerID": "2132asdasd12323q",     "livePeerLat": "42.7967",     "livePeerLng": "-117.1367",     "liveTime": 93363309,     "peerReceiverName": "XHAS_R1",     "peerReceiverAccount": "KBNT-TV",     "peerReceiverAffiliation": "Univision",     "peerReceiverGroupName": "Entravision Communications",     "livePeerReceiverName": "XHAS_R1_OLD",     "livePeerReceiverAccount": null,     "livePeerReceiverAffiliation": null,     "livePeerReceiverGroupName": null,     "peerCountry": "United States",     "livePeerCountry": "United States"   },   {     "peerID": "f0dc8d2edc81ac5f",     "peerLat": "40.7308",     "peerLng": "-93.9975",     "livePeerID": "1ae8163d39ef3c9b",     "livePeerLat": "32.7967",     "livePeerLng": "-117.1367",     "liveTime": 22203455,     "peerReceiverName": "KITV_Reciv",     "peerReceiverAccount": "KITV-TV",     "peerReceiverAffiliation": "ABC",     "peerReceiverGroupName": "SJL Broadcast Management",     "livePeerReceiverName": "NY13_Reciv",     "livePeerReceiverAccount": "ABC News",     "livePeerReceiverAffiliation": "ABC",     "livePeerReceiverGroupName": "The Walt Disney Company",     "peerCountry": "United States",     "livePeerCountry": "United States"   },   {     "peerID": "9ae8163d39ef3999",     "peerLat": "42.7967",     "peerLng": "-67.1367",     "livePeerID": "f0dc8d2edc81ac5f",     "livePeerLat": "40.7308",     "livePeerLng": "-93.9975",     "liveTime": 22203455,     "peerReceiverName": "KITV_Reciv",     "peerReceiverAccount": "KITV-TV",     "peerReceiverAffiliation": "ABC",     "peerReceiverGroupName": "SJL Broadcast Management",     "livePeerReceiverName": "NY13_Reciv",     "livePeerReceiverAccount": "ABC News",     "livePeerReceiverAffiliation": "ABC",     "livePeerReceiverGroupName": "The Walt Disney Company",     "peerCountry": "United States",     "livePeerCountry": "United States"   } ];
                //responseData = [   {     "peerID": "f0dc8d2edc81ac5f",     "peerLat": "40.7308",     "peerLng": "-93.9975",     "livePeerID": "1ae8163d39ef3c9b",     "livePeerLat": "32.7967",     "livePeerLng": "-117.1367",     "liveTime": 22203455,     "peerReceiverName": "KITV_Reciv",     "peerReceiverAccount": "KITV-TV",     "peerReceiverAffiliation": "ABC",     "peerReceiverGroupName": "SJL Broadcast Management",     "livePeerReceiverName": "NY13_Reciv",     "livePeerReceiverAccount": "ABC News",     "livePeerReceiverAffiliation": "ABC",     "livePeerReceiverGroupName": "The Walt Disney Company",     "peerCountry": "United States",     "livePeerCountry": "United States"   },     {     "peerID": "1ae8163d39ef3c9b",     "peerLat": "32.7967",     "peerLng": "-117.1367",     "livePeerID": "2132asdasd12323q",     "livePeerLat": "42.7967",     "livePeerLng": "-117.1367",     "liveTime": 93363309,     "peerReceiverName": "XHAS_R1",     "peerReceiverAccount": "KBNT-TV",     "peerReceiverAffiliation": "Univision",     "peerReceiverGroupName": "Entravision Communications",     "livePeerReceiverName": "XHAS_R1_OLD",     "livePeerReceiverAccount": null,     "livePeerReceiverAffiliation": null,     "livePeerReceiverGroupName": null,     "peerCountry": "United States",     "livePeerCountry": "United States"   },  {     "peerID": "9ae8163d39ef3999",     "peerLat": "42.7967",     "peerLng": "-67.1367",     "livePeerID": "f0dc8d2edc81ac5f",     "livePeerLat": "40.7308",     "livePeerLng": "-93.9975",     "liveTime": 22203455,     "peerReceiverName": "KITV_Reciv",     "peerReceiverAccount": "KITV-TV",     "peerReceiverAffiliation": "ABC",     "peerReceiverGroupName": "SJL Broadcast Management",     "livePeerReceiverName": "NY13_Reciv",     "livePeerReceiverAccount": "ABC News",     "livePeerReceiverAffiliation": "ABC",     "livePeerReceiverGroupName": "The Walt Disney Company",     "peerCountry": "United States",     "livePeerCountry": "United States"   } ];
                
                //shuffle of first
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //shuffle of first
                //responseData = [  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //shuffle of first
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]

                //purple marker have one end purple marker and another end purple marker
       //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3gggg",    "livePeerLat": "59",    "livePeerLng": "-117",    "liveTime": 22203456,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999q",    "livePeerLat": "32",    "livePeerLng": "-87",    "liveTime": 22203457,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5faa",    "peerLat": "20",    "peerLng": "-100",    "livePeerID": "9ae8163d39ef3999q",    "livePeerLat": "32",    "livePeerLng": "-87",    "liveTime": 22203458,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203459,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3gggg",    "livePeerLat": "59",    "livePeerLng": "-117",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5faa",    "peerLat": "20",    "peerLng": "-100",    "livePeerID": "9ae8163d39ef3999q",    "livePeerLat": "32",    "livePeerLng": "-87",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999q",    "livePeerLat": "32",    "livePeerLng": "-87",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3gggg",    "livePeerLat": "59",    "livePeerLng": "-117",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999q",    "livePeerLat": "32",    "livePeerLng": "-87",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999q",    "peerLat": "32",    "peerLng": "-87",    "livePeerID": "f0dc8d2edc81ac5faa",    "livePeerLat": "20",    "livePeerLng": "-100",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "2132asdasd12323q",    "livePeerLat": "42.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3gggg",    "livePeerLat": "59",    "livePeerLng": "-117",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999q",    "peerLat": "32",    "peerLng": "-87",    "livePeerID": "f0dc8d2edc81ac5faa",    "livePeerLat": "20",    "livePeerLng": "-100",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "f0dc8d2edc81ac5f",    "peerLat": "40.7308",    "peerLng": "-93.9975",    "livePeerID": "9ae8163d39ef3999q",    "livePeerLat": "32",    "livePeerLng": "-87",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "9ae8163d39ef3999",    "peerLat": "42.7967",    "peerLng": "-67.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-93.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]

                //one list , self pointing with different rid 
                //responseData = [{    "peerID": "414a7891bcdc8827",    "peerLat": "-25.5026",    "peerLng": "-49.2916",    "livePeerID": "ed68b6eca6b99d9f",    "livePeerLat": "-25.5026",    "livePeerLng": "-49.2916",    "liveTime": 25805407,    "peerReceiverName": "CTATVU02",    "peerReceiverAccount": "Rede Massa",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "Rede Massa",    "livePeerReceiverName": "MGATVU01",    "livePeerReceiverAccount": "Rede Massa",    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": "Rede Massa",    "peerCountry": "Brazil",    "livePeerCountry": "Brazil"  }];
                //one list , self pointing with same rid 
                //responseData = [{    "peerID": "414a7891bcdc8827",    "peerLat": "-25.5026",    "peerLng": "-49.2916",    "livePeerID": "414a7891bcdc8827",    "livePeerLat": "-25.5026",    "livePeerLng": "-49.2916",    "liveTime": 25805407,    "peerReceiverName": "CTATVU02",    "peerReceiverAccount": "Rede Massa",    "peerReceiverAffiliation": null,    "peerReceiverGroupName": "Rede Massa",    "livePeerReceiverName": "MGATVU01",    "livePeerReceiverAccount": "Rede Massa",    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": "Rede Massa",    "peerCountry": "Brazil",    "livePeerCountry": "Brazil"  }];
                
                //Working on same lat and lng with different PID 
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "2132asdasd12323q",    "peerLat": "42.7967",    "peerLng": "-117.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //responseData = [  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "2132asdasd12323q",    "peerLat": "42.7967",    "peerLng": "-117.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "asdasdsdadsa",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "asdas",    "livePeerLat": "45",    "livePeerLng": "-80",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                
                //for client demo 
                //responseData = [  {    "peerID": "2132asdasd12323q",    "peerLat": "42.7967",    "peerLng": "-117.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "sASSsSAsasasa",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "gfsdffdfdffsdf",    "livePeerLat": "35",    "livePeerLng": "-80",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "asdasdsdadsa",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "asdas",    "livePeerLat": "50",    "livePeerLng": "-80",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //responseData = [  {    "peerID": "2132asdasd12323q",    "peerLat": "42.7967",    "peerLng": "-117.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 93363309,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "sASSsSAsasasa",    "peerLat": "35",    "peerLng": "-80",    "livePeerID": "gfsdffdfdffsdf",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "asdasdsdadsa",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "asdas",    "livePeerLat": "50",    "livePeerLng": "-80",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 22203455,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }] ;
                
                // for close location
                //one records
                //responseData = [  {    "peerID": "989b0ee9a0886cdb",    "peerLat": "33.4724",    "peerLng": "-82.0889",    "livePeerID": "39d106d4b3150be0",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //two records
                //responseData = [  {    "peerID": "989b0ee9a0886cdb",    "peerLat": "33.4724",    "peerLng": "-82.0889",    "livePeerID": "39d106d4b3150be0",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "989b0eeasdasd6cdb",    "peerLat": "50",    "peerLng": "-70",    "livePeerID": "39d106d4b31asdasde0",    "livePeerLat": "37",    "livePeerLng": "-97",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //three records 
                //responseData = [  {    "peerID": "989b0ee9a0886cdb",    "peerLat": "33.4724",    "peerLng": "-82.0889",    "livePeerID": "39d106d4b3150be0",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "989b0eeasdasd6cdb",    "peerLat": "50",    "peerLng": "-70",    "livePeerID": "39d106d4b31asdasde0",    "livePeerLat": "37",    "livePeerLng": "-97",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "989b0eeasdassdsad",    "peerLat": "20",    "peerLng": "-90",    "livePeerID": "39d106d4b31asdasd",    "livePeerLat": "37.5",    "livePeerLng": "-97.5",    "liveTime": 18381162,    "peerReceiverName": "WJBF_Lottery_GA",    "peerReceiverAccount": "WJBF",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];

                //error in color 
                // responseData = [{    "peerID": "47008106926410e7",    "peerLat": "26.1042",    "peerLng": "-80.126",    "livePeerID": "55524c204558544c",    "livePeerLat": null,    "livePeerLng": null,    "liveTime": 299416,    "peerReceiverName": "WPBF_REM5",    "peerReceiverAccount": "WPBF-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Hearst",    "livePeerReceiverName": null,    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": null  }];
                //responseData = [{"peerID":"b3e6ed8a2bf258a9","peerLat":"32.7691","peerLng":"-96.6053","livePeerID":"84738ab79b475ac6","livePeerLat":"32.749","livePeerLng":"-96.4629","liveTime":108652800,"peerReceiverName":"Molasky_Recei","peerReceiverAccount":null,"peerReceiverAffiliation":null,"peerReceiverGroupName":null,"livePeerReceiverName":"Molasky_Skycam","livePeerReceiverAccount":"KLAS-TV","livePeerReceiverAffiliation":"CBS","livePeerReceiverGroupName":"Nexstar Media Group","peerCountry":"United States","livePeerCountry":"United States"}];

                //logs related testing... (modify the date for liveTime) ---> According to month
                //seconds
                //responseData = [  {    "peerID": "2132asdasd12323q",    "peerLat": "42.7967",    "peerLng": "-117.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 1568942362,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "sASSsSAsasasa",    "peerLat": "35",    "peerLng": "-80",    "livePeerID": "gfsdffdfdffsdf",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 1564961705,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "asdasdsdadsa",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "asdas",    "livePeerLat": "50",    "livePeerLng": "-80",    "liveTime": 1562733610,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 1560573915,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }];
                //responseData = [    {    "peerID": "b2ccb91ba6944920",    "peerLat": "28.6120637",    "peerLng": "-81.3857364",    "livePeerID": "5dca249eacc9610f",    "livePeerLat": "33.51859",    "livePeerLng": "-86.81036",    "liveTime": 1568942362,    "peerReceiverName": "WESH_TVUGR4",    "peerReceiverAccount": "WESH TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Hearst",    "livePeerReceiverName": "WVTM_TVUGR2",    "livePeerReceiverAccount": "WVTM-TV",    "livePeerReceiverAffiliation": "NBC",    "livePeerReceiverGroupName": "Hearst",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "0ede68cd3363ac30",    "peerLat": "44.9325",    "peerLng": "-93.088",    "livePeerID": "cb21ec26c0e79",    "livePeerLat": "39.4332",    "livePeerLng": "-76.6546",    "liveTime": 1564961705,    "peerReceiverName": "KSTP_Reciv",    "peerReceiverAccount": "KSTP-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Hubbard Corporate",    "livePeerReceiverName": "DC5_Reciv",    "livePeerReceiverAccount": "ABC Television Group",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "ef7755e3d19d4867",    "peerLat": "32.9164",    "peerLng": "-117.1393",    "livePeerID": "ef7755e3d19d4867",    "livePeerLat": "32.9164",    "livePeerLng": "-117.1393",    "liveTime": 1562733610,    "peerReceiverName": "KBNT_1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "KBNT_1",    "livePeerReceiverAccount": "KBNT-TV",    "livePeerReceiverAffiliation": "Univision",    "livePeerReceiverGroupName": "Entravision Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "be7d4c320d5f7133",    "peerLat": "47.54",    "peerLng": "-122.3032",    "livePeerID": "92d432a426d8c5f1",    "livePeerLat": "41.1166",    "livePeerLng": "-87.8696",    "liveTime": 1560573915,    "peerReceiverName": "KIVI_Grid",    "peerReceiverAccount": "KIVI-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Scripps",    "livePeerReceiverName": "WEWS_Grid",    "livePeerReceiverAccount": "WEWS-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Scripps",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "edb0cc2590ac449a",    "peerLat": "33.7984581",    "peerLng": "-84.3882828",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 1557012905,    "peerReceiverName": "WSAV_Lottery",    "peerReceiverAccount": "WSAV-TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //milliseconds
                //responseData =[  {    "peerID": "2132asdasd12323q",    "peerLat": "42.7967",    "peerLng": "-117.1367",    "livePeerID": "1ae8163d39ef3c9b",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 1568942362000,    "peerReceiverName": "XHAS_R1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "XHAS_R1_OLD",    "livePeerReceiverAccount": null,    "livePeerReceiverAffiliation": null,    "livePeerReceiverGroupName": null,    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "sASSsSAsasasa",    "peerLat": "35",    "peerLng": "-80",    "livePeerID": "gfsdffdfdffsdf",    "livePeerLat": "32.7967",    "livePeerLng": "-117.1367",    "liveTime": 1564961705000,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "asdasdsdadsa",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "asdas",    "livePeerLat": "50",    "livePeerLng": "-80",    "liveTime": 1562733610000,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "1ae8163d39ef3c9b",    "peerLat": "32.7967",    "peerLng": "-117.1367",    "livePeerID": "f0dc8d2edc81ac5f",    "livePeerLat": "40.7308",    "livePeerLng": "-73.9975",    "liveTime": 1560573915000,    "peerReceiverName": "KITV_Reciv",    "peerReceiverAccount": "KITV-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "SJL Broadcast Management",    "livePeerReceiverName": "NY13_Reciv",    "livePeerReceiverAccount": "ABC News",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]
                //responseData = [    {    "peerID": "b2ccb91ba6944920",    "peerLat": "28.6120637",    "peerLng": "-81.3857364",    "livePeerID": "5dca249eacc9610f",    "livePeerLat": "33.51859",    "livePeerLng": "-86.81036",    "liveTime": 1568942362000,    "peerReceiverName": "WESH_TVUGR4",    "peerReceiverAccount": "WESH TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Hearst",    "livePeerReceiverName": "WVTM_TVUGR2",    "livePeerReceiverAccount": "WVTM-TV",    "livePeerReceiverAffiliation": "NBC",    "livePeerReceiverGroupName": "Hearst",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "0ede68cd3363ac30",    "peerLat": "44.9325",    "peerLng": "-93.088",    "livePeerID": "cb21ec00026c0e79",    "livePeerLat": "39.4332",    "livePeerLng": "-76.6546",    "liveTime": 1564961705000,    "peerReceiverName": "KSTP_Reciv",    "peerReceiverAccount": "KSTP-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Hubbard Corporate",    "livePeerReceiverName": "DC5_Reciv",    "livePeerReceiverAccount": "ABC Television Group",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "The Walt Disney Company",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "ef7755e3d19d4867",    "peerLat": "32.9164",    "peerLng": "-117.1393",    "livePeerID": "ef7755e3d19d4867",    "livePeerLat": "32.9164",    "livePeerLng": "-117.1393",    "liveTime": 1562733610000,    "peerReceiverName": "KBNT_1",    "peerReceiverAccount": "KBNT-TV",    "peerReceiverAffiliation": "Univision",    "peerReceiverGroupName": "Entravision Communications",    "livePeerReceiverName": "KBNT_1",    "livePeerReceiverAccount": "KBNT-TV",    "livePeerReceiverAffiliation": "Univision",    "livePeerReceiverGroupName": "Entravision Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "be7d4c320d5f7133",    "peerLat": "47.54",    "peerLng": "-122.3032",    "livePeerID": "92d432a426d8c5f1",    "livePeerLat": "41.1166",    "livePeerLng": "-87.8696",    "liveTime": 1560573915000,    "peerReceiverName": "KIVI_Grid",    "peerReceiverAccount": "KIVI-TV",    "peerReceiverAffiliation": "ABC",    "peerReceiverGroupName": "Scripps",    "livePeerReceiverName": "WEWS_Grid",    "livePeerReceiverAccount": "WEWS-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Scripps",    "peerCountry": "United States",    "livePeerCountry": "United States"  },  {    "peerID": "edb0cc2590ac449a",    "peerLat": "33.7984581",    "peerLng": "-84.3882828",    "livePeerID": "989b0ee9a0886cdb",    "livePeerLat": "37.751",    "livePeerLng": "-97.822",    "liveTime": 1557012905000,    "peerReceiverName": "WSAV_Lottery",    "peerReceiverAccount": "WSAV-TV",    "peerReceiverAffiliation": "NBC",    "peerReceiverGroupName": "Media General",    "livePeerReceiverName": "Lottery_WSB",    "livePeerReceiverAccount": "WSB-TV",    "livePeerReceiverAffiliation": "ABC",    "livePeerReceiverGroupName": "Cox Communications",    "peerCountry": "United States",    "livePeerCountry": "United States"  }]

                //console.log("responseData--> ", responseData);
                filterList = responseData;
                if(this.inputSearchData){
                  filterList = this.filterData(responseData);
                  //console.log("asdasdsa");
                }
                
                //let filterData = this.filterByEventTypeAndDate();

                this.showData(filterList);
                //Reload Marker And Logs after refreshTime 
                this.clearIntervalReloadMarkerAndLogs();
          }
          return _data;
      },

      /*
      //display error
      */
      errorHandle(_error) {
        console.log(_error);
      },

      /*
      //handle the search data on inputbox
      */
      inputChangeHandleSearchData(){
        this.clearInterval();
        this.clearIcon();
        this.disableIcon();
        if(this.inputSearchData === "")
        {
          this.inputHandleSearchData();
        }
      },

      /*
      //handle the search data on inputbox
      */
      inputHandleSearchData(){
        //console.log("this.lastIconList----->", this.lastIconList);
        filterList = this.inputSearchData ? this.filterData(responseData) : responseData ;
        if (filterList) {
          this.showData(filterList);
        }
        this.enableIconList(null);
      },

      /*
      //filter the data from collection
      */
      filterData(_responseData){
        //console.log("_responseData--->>>", _responseData);
        let filterContainData = [];
        let inputSearchDataAtUI = this.inputSearchData.toUpperCase() ;
        filterContainData = _responseData.filter((data) => {

          let strPeerID = data.peerID.toUpperCase() + "";
          let strLivePeerID = data.livePeerID.toUpperCase() + "";

          let strPeerReceiverName = data.peerReceiverName ? data.peerReceiverName.toUpperCase() + "" : ""; 
          let strLivePeerReceiverName = data.livePeerReceiverName ? data.livePeerReceiverName.toUpperCase() + "" : ""; 

          let strPeerReceiverAccount = data.peerReceiverAccount ? data.peerReceiverAccount.toUpperCase() + "" : ""; 
          let strLivePeerReceiverAccount = data.livePeerReceiverAccount ? data.livePeerReceiverAccount.toUpperCase() + "" : ""; 

          let strPeerReceiverGroupName = data.peerReceiverGroupName ? data.peerReceiverGroupName.toUpperCase() + "" : ""; 
          let strLivePeerReceiverGroupName = data.livePeerReceiverGroupName ? data.livePeerReceiverGroupName.toUpperCase() + "" : ""; 

          let strPeerReceiverAffiliation = data.peerReceiverAffiliation ? data.peerReceiverAffiliation.toUpperCase() + "" : ""; 
          let strLivePeerReceiverAffiliation = data.livePeerReceiverAffiliation ? data.livePeerReceiverAffiliation.toUpperCase() + "" : ""; 

          let strPeerCountry = data.peerCountry ? data.peerCountry.toUpperCase() + "" : ""; 
          let strLivePeerCountry = data.livePeerCountry ? data.livePeerCountry.toUpperCase() + "" : ""; 

          return (
            strPeerID.indexOf(inputSearchDataAtUI) >= 0 || 
            strLivePeerID.indexOf(inputSearchDataAtUI) >= 0 ||

            strPeerReceiverName.indexOf(inputSearchDataAtUI) >= 0 ||
            strLivePeerReceiverName.indexOf(inputSearchDataAtUI) >= 0 ||
            
            strPeerReceiverAccount.indexOf(inputSearchDataAtUI) >= 0 ||
            strLivePeerReceiverAccount.indexOf(inputSearchDataAtUI) >= 0 ||
            
            strPeerReceiverGroupName.indexOf(inputSearchDataAtUI) >= 0 ||
            strLivePeerReceiverGroupName.indexOf(inputSearchDataAtUI) >= 0 ||

            strPeerReceiverAffiliation.indexOf(inputSearchDataAtUI) >= 0 ||
            strLivePeerReceiverAffiliation.indexOf(inputSearchDataAtUI) >= 0 ||

            strPeerCountry.indexOf(inputSearchDataAtUI) >= 0 ||
            strLivePeerCountry.indexOf(inputSearchDataAtUI) >= 0 

          ) ? true : false;
        });      
        return filterContainData;
      },

      /*
      //toggle autoRefeshMode value
      */
      toggleAutoRefeshMode(){
        this.autoRefeshMode = !this.autoRefeshMode;
      },

      /*
      //set autoRefeshMode value
      */
      setAutoRefeshMode(_autoRefeshMode){
        this.autoRefeshMode = _autoRefeshMode;
      },

      /*
      //get autoRefeshMode value
      */
      getAutoRefeshMode(){
        return this.autoRefeshMode;
      },

      /*
      // update the pagination details 
      */
      updatePaginationDetails(_totalPageNum, _currentPageNum, _totalNum, _everyPageNum ){
        this.paginationDetails = {
            message: _currentPageNum + " of " + _totalPageNum,
            totalPageNum: _totalPageNum,
            currentPageNum: _currentPageNum,
            totalNum: _totalNum,
            everyPageNum: _everyPageNum
        }
      },
      
      /*
      // update the input for pagination
      */
      updateJSONInputforPagination (){
        if(this.selectedDateRange == dateRange.accordingMonth){
          this.endDate =  this.setLastDay(this.startDate);
        }
        
        let currentInfoData = this.mapsOp.getInfoWindowContent();
        let receiverId = "";
        let gridSourceId = "";
        let incoming = currentInfoData.incoming;
        let outcoming = currentInfoData.outcoming;

        if(outcoming == 0 && incoming >= 1)
        {
          receiverId = currentInfoData.id;
          gridSourceId = "";
        }
        else
        {
          receiverId = "";
          gridSourceId = currentInfoData.id;
        }

        const startdate = this.formatDate(this.startDate, "yyyy-MM-dd");
        const endDate = this.formatDate(this.endDate, "yyyy-MM-dd");
        const input = {
          "startDate": startdate,
          "endDate": endDate,
          "receiverName":"",
          "receiverId":receiverId,
          "gridSourceId":gridSourceId, 
          "gridSourceName":"",
          "currentPageNum":this.paginationDetails.currentPageNum,
          "everyPageNum":config.everyPageNum
        }

        return input
      },

      /*
      // Set the pagination details 
      */
      onChangePage(_pageNum) {
        //console.log("----", _pageNum);
        //this.paginationDetails.message = _pageNum + " of " + 10 ;
        this.paginationDetails.currentPageNum = _pageNum;

        //update the  JSON request object for liveDetail API
        this.filterHandler();
      },    

      /*
      //Reset the value of pagination
      */
      resetPaginationDetails(){
        this.paginationDetails = {
          message: "", 
          totalPageNum: 0, 
          currentPageNum: 0, 
          totalNum: 0, 
          everyPageNum: 0
        }
      }
    }, //end methods

    data() {
      return {
        isShow: false,
        errors: {},
        summaryCheckboxes: [],//summaryItems.summaryItems,
        summaryData: {},// summaryItems.summaryData[0],
        inputSearchData: "",
        stringData: " icon from data",
        isEnableIcon: false,
        isEnableLog: false,
        images: [],
        counter: 1,
        //lastIconList: [],
        data: {},
        selectedEventType: 'eventType',
        selectedDateRange: 'latestWeek',
        format: "yyyy-MM-dd",
        startDate: new Date(),
        endDate: new Date(),
        showLogs: selectLoadingText,
        isDisplayDateRange: true,
        isDisabled: true,
        viewType:'day',
        formatViewType:'yyyy-MM',
        IsZoomProjection:0,
        autoRefeshMode: false,
        paginationDetails:{message:"0 of 0", totalPageNum:0, currentPageNum:0, totalNum:0, everyPageNum:0 }
      };
    }, //end data

    computed: {
      checkBackgroundColor: function () {
        return {
         whitebackground  :  this.selectedDateRange == dateRange.accordingMonth
        }
      },

      isEnablePagination: function () {
        //return true
        //console.log("this.showLogs ---> ", this.showLogs);
        return !(this.showLogs === loadingText || this.showLogs === selectLoadingText || this.showLogs === noDataFound || this.showLogs === noDataFoundWithClass ) ? true : false
      }     
    }//end computed

  };
</script>

<style>
	.search{
		margin: 0px;
		padding: 0px;
		position: absolute;
		right: 60px;
		top: 67px;
		display: flex;
	}

	.search input[type="text"]{
		margin: 0px;
		padding: 10px 10px;
		background: #FFF;
		border: 1px solid #ccc;
		width: 140px;
		font-size: 14px;
		outline: none;
	}

	.search button{
		margin: 0px;
		padding: 11px 11px;
		background: #14232f;
		color: #fff;
		border: none;
		outline: none;
		font-size: 15px;
		font-weight: 600;
		cursor: pointer;
	}

	.search-icon{
		position: absolute;
		width: 41px;
		height: 41px;
		background: red;
		right: 10px;
		top: 65px;
		background: #fff url("../images/search.png") no-repeat center center; 
		cursor: pointer;
		-webkit-box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
		box-shadow: 0px 0px 8px 0px rgba(0, 0, 0, 0.4);
		border-radius: 3px;
	}

	.search-icon:hover{ background: #fff url("../images/search-active.png") no-repeat center center; }

	.serch-section-opt2 .search{
		right: 50px;
		top: 65px;
	}

	.serch-section-opt2 .search-icon {
		top: 65px;
		right: 10px;
		box-shadow: none;
		border-radius: 0;
		height: 40px;
	}

	.serch-section-opt2 .search input[type="text"] {
		margin: 0px;
		padding: 12px 10px;
		border: none;
	}

	.map-img{
		margin:0px 0 15px 0;
		padding: 0px;
		position: relative;
		right: 9px;
		top: 0;
		display: -webkit-box;
		display: -ms-flexbox;
		display: flex;
		max-width: 200px;
		height: auto;
		-ms-flex-wrap: wrap;
		flex-wrap: wrap;
		border-radius: 2px;
		-webkit-box-pack: justify;
		-ms-flex-pack: justify;
		justify-content: space-between;
		float: right;
	}

	.map-img img{ 
		margin:0px 10px 10px 10px;
	}

	.map-img .title{
		margin: 0px 0px 0px 0px;
		font-family: Arial, Helvetica, sans-serif;
		padding: 10px 8px;
		background: #ffffff;
		color: #000;
		font-size: 13px;
		border-radius: 0;
		position: relative;
		border-bottom: 1px solid #ccc;
		width: 100%  
	}

	.map-img .map-img-innner{
		margin: 0px;
		padding: 10px 0px 0px 0px;
		display: -webkit-box;
		display: -ms-flexbox;
		display: flex;
		background: rgba(255, 255, 255);
		width: 200px;
		flex-wrap: wrap;
		box-shadow: rgba(0, 0, 0, 0.3) 0px 1px 4px -1px;
		overflow-y: auto;
		border-bottom: 1px solid #ccc;
		height: 100px;
	}

	.right-fixed-section{
		position: absolute;
		top: 116px;
		right: 0px;
	}

	.right-fixed-section-show-hide{
		position: absolute;
		top: 274px;
		right: 0px;
	}

	.right-fixed-section-logs{
		position: absolute;
		top: 311px;
		right: 0px;
	}

	.clearfix:after {
		content: " "; /* Older browser do not support empty content */
		visibility: hidden;
		display: block;
		height: 0;
		clear: both;
	}

	.show-hide-log{
		position: relative;
		right: 10px;
		top: 0px;
	}

	.show-hide-log > button{
		margin: 0px;
		padding: 10px 8px;
		background: #FFF;
		border: 1px solid #ccc;
		width: 200px;
		font-size: 13px;
		outline: none;
		position: relative;
		top: 0;
		right: 0px;
		cursor: pointer;
		text-align: left;
		float: right;
	}

	.show-hide-log .logs-section{
		position: relative;
		top: 0px;
		background: #fff;
		border: 1px solid #ccc;
		margin: 0px 0 0px 0;
	}

	.show-hide-log .logs-section  .vdp-datepicker__calendar{
		right: 0;
	}

	.whitebackground{
		background: #fff;
	}

	.show-hide-log .logs-section .logs{
		padding:10px;
		min-height: 150px;
		overflow-y: auto;
		max-height: 250px;
		min-width: 700px;
	}

	.show-hide-log .logs-section .pagination{
		padding:10px;
	}

	.show-hide-log .logs-section .logs p{
		margin:0 0 8px 0 ;
		font-size: 14px;
	}

	.show-hide-log .logs-header{
		background: #edeef0;
		padding: 7px 5px;
		display: flex;
	}

	.show-hide-log .logs-header button{
		background: #5bb862;
		color: #fff;
		border: none;
		padding:9px 9px;
		border-radius: 4px;
		cursor:pointer;
		margin-left: 5px;
	}

	.show-hide-log .logs-header select{
		border: 1px solid #5bb862;
		width: 160px;
		padding: 8px 5px;
		font-size: 12px;
		border-radius: 4px;
		margin:0 10px 0 0;
	}

	.show-hide-log .logs-header input[type="text"]{
		border: 1px solid #5bb862;
		width: 110px;
		padding: 8px 5px 8px 30px;
		font-size: 12px;
		border-radius: 4px;
		background: transparent url("../images/calender-icon.png") no-repeat 8px 6px;
	}

	.to{
		margin: 10px 10px 0 10px;
		text-align: center;
	}
	
	/* row of the logs */
	.show-hide-log .logs-green{ color:#5ab761;}
	.show-hide-log .logs-blue{ color:#117ccf;}
	.show-hide-log .logs-black{ color:#000;}
	.show-hide-log .logs-red{ color:#ff0000;}

	.pagination{
		background: #edeef0;
		border-top: 2px solid #ccc;
		padding: 8px;
		font-family: Arial, Helvetica, sans-serif;
	}

	.pagination ul li a{
		cursor: pointer;
		padding: 6px 12px;
		display: block;
		float: left;
		background: #5bb862;
		color: #fff;
		font-size: 13px;
		margin: 0 6px 0 0;
		border-radius: 4px;    
	}

	/* disabled class for inacive pagination tabs  */
	.pagination ul li a.disabled{
		background: #b9b9b9;
		cursor: auto;
		color: #797777;
		pointer-events: none;
	}

	/* pagination at center  */
	.pagination-center{
		display: flex!important;
		align-items: center;
		justify-content: center;
	}

	/* pagination at right  */
	.pagination-right{
		display: flex!important;
		align-items: center;
		justify-content: flex-end;
	}
</style>