(window.webpackJsonp=window.webpackJsonp||[]).push([[794],{1375:function(t,e,r){"use strict";r.r(e);var o=r(63),n=(r(4),r(8),r(208),r(25),r(15),r(70)),c=r(370),l=r(393),h=r(391);Object(n.a)([c.a,l.a,h.a]);var d={props:{chartData:{type:Array,required:!0},getChartSerie:{type:Function,required:!0},chartType:{type:String,required:!0},handleSelect:{type:Function,default:function(){return null}}},computed:{chartOption:function(){var t=this,option={title:{text:"Monitoração"},tooltip:{trigger:"item"},legend:{top:"bottom"},xAxis:[{type:"category",data:[]}],yAxis:[{type:"value"}],series:[]};return"AC"===this.chartType?option.title.text+=" - Acesso":"OC"===this.chartType&&(option.title.text+=" - Ocupação"),this.chartData.forEach((function(e){var r=e.classificacao,n=e.kilometro,c=e.situacoes;r===t.chartType&&(option.xAxis[0].data.push(n),c.forEach((function(e){var r=e.tipo,n=e.contagem,c=option.series.findIndex((function(s){return s.name.toLowerCase()===r.toLowerCase()}));if(-1===c){var l=t.getChartSerie(r),h=l.data||[];l.data=[].concat(Object(o.a)(h),[n]),l.name&&option.series.push(l)}else option.series[c].data.push(n)})))})),option}}},f=r(42),component=Object(f.a)(d,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("b-card",[r("b-row",[r("b-col",[0===t.chartData.length?r("b-alert",{attrs:{show:"",variant:"info"}},[r("fa-icon",{staticClass:"mr-1",staticStyle:{"font-size":"1.2rem"},attrs:{icon:"circle-info"}}),t._v(" "),r("span",[t._v(" Não há dados para o filtro informado. ")])],1):t._e(),t._v(" "),r("v-chart",{staticClass:"chart",attrs:{autoresize:"",option:t.chartOption},on:{click:t.handleSelect}})],1)],1)],1)}),[],!1,null,null,null);e.default=component.exports}}]);
//# sourceMappingURL=9d802cd-1.2.11.js.map