angular.module('zhongxin', []) .controller('zhongxinCorl', ['$scope', '$http', function($scope, $http) { // $(window).resize(function() { // var width_frm = $(document.body).width(); // var height_frm = $(document.body).height(); // var width_div = width_frm / 2; // var height_div = height_frm / 2; // $('#th_nums').css("height", height_div); // $('#th_num').css("height", height_div); // $('#jtv_num').css("height", height_div); // }); $('#slhw').highcharts({ chart: { type: 'pie', backgroundColor: '#100e11', options3d: { enabled: true, alpha: 45, beta: 0 } }, title: { text: '受理渠道话务量', style: { color: '#fff', } }, //LOGO 去掉 credits: { enabled: false }, tooltip: { pointFormat: '{series.name}: {point.percentage:.1f}%' }, plotOptions: { pie: { allowPointSelect: true, cursor: 'pointer', depth: 35, dataLabels: { enabled: true, format: '{point.name}: {point.percentage:.1f}%' } } }, series: [{ type: 'pie', name: '受理渠道话务量', data: [ ['电话', 45.0], ['网站门户', 26.8], { name: 'APP', y: 12.8, sliced: true, selected: true }, ['微信', 8.5], ['短信', 6.2], ['微博', 0.7], ['邮件', 10.5], ] }] }); //通话数量 $('#th_num').highcharts({ chart: { type: 'line', backgroundColor: '#100e11' }, title: { text: '通话数量统计', style: { color: '#fff', } }, legend: { align: 'right', verticalAlign: 'top', x: 0, y: 50 }, //LOGO 去掉 credits: { enabled: false }, xAxis: { categories: [ '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', ], title: { text: '时间', align: 'high', rotation:0, y: -50 } }, yAxis: { gridLineColor: '#100e11', title: { text: '数量', rotation: 0, y: -160 } }, plotOptions: { line: { dataLabels: { enabled: true // 开启数据标签 }, enableMouseTracking: false // 关闭鼠标跟踪,对应的提示框、点击事件会失效 } }, series: [{ name: '咨询类', data: [7.0, 6.9, 9.5, 14.5, 18.4, 21.5, 25.2, 26.5, 23.3, 18.3, 13.9, 9.6] }, { name: '投诉类', data: [3.9, 4.2, 5.7, 8.5, 11, 15.2, 17.0, 16.6, 14.2, 10.3, 6.6, 4.8] }, { name: '来电举报类', data: [3.9, 5, 8, 8, 11, 8, 3, 16, 14, 10, 6, 4] }, { name: '建议类', data: [8, 4, 5, 8, 11, 15, 17, 16, 14, 10, 6, 4] }] }); //接通率报表 var jtv = echarts.init(document.getElementById('jtv_num')); option = { title: { text: '接通率统计', x: 'center', textStyle: { color: '#fff', fontSize: 16 } }, tooltip: { trigger: 'axis', axisPointer: { type: 'shadow', label: { show: true, backgroundColor: '#333' } } }, legend: { top: 30, data: ['接通量', '挂断量','未接量'], textStyle: { color: '#ccc' } }, xAxis: { data: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10,11,12,13,14,15,16,17,18,19,20,21,22,23,24], axisLine: { lineStyle: { color: '#ccc' } }, }, yAxis: { splitLine: { show: false }, axisLine: { lineStyle: { color: '#ccc' } } }, series: [{ name: '挂断量', type: 'line', smooth: true, showAllSymbol: true, symbol: 'emptyCircle', symbolSize: 15, data: [10, 15, 40, 44, 30, 50, 80, 62, 55, 32,40,45,48,50,55,80,88,55,45,20,15,10,40,10] }, { name: '接通量', type: 'bar', barWidth: 10, itemStyle: { normal: { barBorderRadius: 5, color: new echarts.graphic.LinearGradient( 0, 0, 0, 1, [ { offset: 0, color: '#14c8d4' }, { offset: 1, color: '#43eec6' } ] ) } }, data: [20, 33, 80, 14, 60, 42, 99, 22, 36, 19,25,30,45,80,65,55,42,50,55,66,36,23,20,21] }] }; jtv.setOption(option); //通话时长 var chart = new Highcharts.Chart('th_nums', { chart: { backgroundColor: '#100e11' }, title: { text: '平均通话时长统计', style: { color: '#fff', } }, //LOGO 去掉 credits: { enabled: false }, xAxis: { categories: ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12'] }, yAxis: { title: { rotation: 0, y: -170, text: '小时' }, plotLines: [{ value: 0, width: 1, color: '#808080' }] }, tooltip: { valueSuffix: 'h' }, legend: { align: 'right', verticalAlign: 'top', x: 0, y: 50 }, series: [{ name: '平均通话时长统计', data: [7.0, 6.9, 9.5, 14.5, 18.2, 21.5, 25.2, 26.5, 23.3, 18.3, 13.9, 9.6] }] }); }]);