123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358 |
- @extends('admin/layout')
- @section('header')
- <style>
- .box-my {
- width: 60%;
- margin: 0 auto;
- border-radius: 12px;
- background-color: white;
- }
- .box-my > .box-my-header {
- border-radius: 12px 12px 0 0;
- background: #2A94E0;
- padding-top: 14px;
- height: 50px;
- color: white;
- text-align: center;
- }
- .box-my > .box-my-content {
- padding: 10px 20px;
- }
- .box-my > .box-my-content .status {
- text-align: center;
- font-size: 20px;
- }
- .box-my > .box-my-content .status img {
- margin-bottom: 4px;
- /*position: absolute;*/
- /*top: 8px;*/
- /*left: 40%*/
- }
- .my-detail {
- margin-top: 10px;
- }
- .my-detail:after {
- content: '';
- display: block;
- clear: both;
- }
- .my-detail .day-title {
- float: left;
- font-size: 16px;
- }
- .my-detail b {
- font-size: 16px;
- float: right;
- }
- </style>
- @endsection
- @section('content')
- <body class="wrapper wrapper-content" style="background-color: #F3F3F4">
- {{--<div class="row">
- <div class="col-sm-4">
- <div class="box-my">
- <div class="box-my-header">
- <img src="/img/kzt-img-01.png" alt="">
- 流量
- </div>
- <div class="box-my-content">
- <div class="status" style="position: relative">
- @if($trafficLine['yAxis'][0]>=$trafficLine['yAxis'][1])
- <img src="/img/kzt-top-img.png" alt="">
- @else
- <img src="/img/kzt-down-img.png" alt="">
- @endif
- {{number_format($trafficLine['yAxis'][0]-$trafficLine['yAxis'][1],0,'.',', ')}}
- </div>
- <div class="my-detail"><span class="day-title">昨天</span> <b>{{$trafficLine['yAxis'][0]}}</b></div>
- <div class="my-detail"><span class="day-title">前天</span> <b>{{$trafficLine['yAxis'][1]}}</b></div>
- </div>
- </div>
- </div>
- <div class="col-sm-4">
- <div class="box-my">
- <div class="box-my-header">
- <img src="/img/kzt-img-01.png" alt="">
- 询盘
- </div>
- <div class="box-my-content">
- <div class="status" style="position: relative">
- @if($inquireLine['yAxis'][0]>=$inquireLine['yAxis'][1])
- <img src="/img/kzt-top-img.png" alt="">
- @else
- <img src="/img/kzt-down-img.png" alt="">
- @endif
- {{number_format($inquireLine['yAxis'][0]-$inquireLine['yAxis'][1],0,'.',', ')}}
- </div>
- <div class="my-detail"><span class="day-title">昨天</span> <b>{{$inquireLine['yAxis'][0]}}</b></div>
- <div class="my-detail"><span class="day-title">前天</span> <b>{{$inquireLine['yAxis'][1]}}</b></div>
- </div>
- </div>
- </div>
- <div class="col-sm-4">
- <div class="box-my">
- <div class="box-my-header">
- <img src="/img/kzt-img-01.png" alt="">
- 首页关键词
- </div>
- <div class="box-my-content">
- <div class="status" style="position: relative">
- @if($keywordLine['yAxis'][0]>=$keywordLine['yAxis'][1])
- <img src="/img/kzt-top-img.png" alt="">
- @else
- <img src="/img/kzt-down-img.png" alt="">
- @endif
- {{number_format($keywordLine['yAxis'][0]-$keywordLine['yAxis'][1],0,'.',', ')}}
- </div>
- <div class="my-detail"><span class="day-title">昨天</span> <b>{{$keywordLine['yAxis'][0]}}</b></div>
- <div class="my-detail"><span class="day-title">前天</span> <b>{{$keywordLine['yAxis'][1]}}</b></div>
- </div>
- </div>
- </div>
- </div>--}}
- <br>
- <div class="row">
- <div class="col-sm-4">
- <div class="ibox float-e-margins">
- <div class="ibox-title" style="border-style: none">
- <h5>流量趋势图</h5>
- </div>
- <div class="ibox-content">
- <div id="trafficLine" style="width: 100%;height: 300px;"></div>
- </div>
- </div>
- </div>
- <div class="col-sm-4">
- <div class="ibox float-e-margins">
- <div class="ibox-title" style="border-style: none">
- <h5>询盘趋势图</h5>
- </div>
- <div class="ibox-content">
- <div id="inquireLine" style="width: 100%;height: 300px;"></div>
- </div>
- </div>
- </div>
- <div class="col-sm-4">
- <div class="ibox float-e-margins">
- <div class="ibox-title" style="border-style: none">
- <h5>关键词趋势图</h5>
- </div>
- <div class="ibox-content">
- <div id="keywordLine" style="width: 100%;height: 300px;"></div>
- </div>
- </div>
- </div>
- </div>
- </body>
- @endsection
- @section('footer')
- <script src="{{asset('js/jquery.min.js?v=2.1.4')}}"></script>
- {{--echarts--}}
- <script src="{{asset('js/plugins/echarts/echarts.min.js')}}"></script>
- <script src="{{asset('js/plugins/wonderland/wonderland.js?v=1.3')}}"></script>
- <script>
- // 流量折线图
- var trafficLineChart = echarts.init(document.getElementById('trafficLine'),'wonderland');
- // var trafficLineXAxis = [];
- var trafficLineXAxis = JSON.parse('{!! json_encode($trafficLine['xAxis']) !!}');
- var trafficLineYAix = JSON.parse('{!! json_encode($trafficLine['yAxis']) !!}');
- var trafficLineOption = {
- tooltip: {
- trigger: 'axis',
- axisPointer: {
- type: 'cross',
- crossStyle: {
- color: '#999'
- }
- }
- },
- toolbox: {
- feature: {
- dataView: {show: true, readOnly: false},
- magicType: {show: true, type: ['bar', 'pie']},
- restore: {show: true},
- saveAsImage: {show: true}
- }
- },
- legend: {
- data: ['流量']
- },
- xAxis: [
- {
- type: 'category',
- data: trafficLineXAxis,
- axisPointer: {
- type: 'shadow'
- },
- splitLine: {
- show: false
- }
- }
- ],
- yAxis: [
- {
- type: 'value',
- name: '',
- min: 0,
- axisLabel: {
- formatter: '{value}'
- },
- axisLine: {
- show: false //隐藏Y轴
- }
- }
- ],
- series: [
- {
- name: '流量',
- type: 'line',
- data: trafficLineYAix
- }
- ]
- };
- trafficLineChart.setOption(trafficLineOption);
- // 询盘折线图
- var inquireLineChart = echarts.init(document.getElementById('inquireLine'),'wonderland');
- var inquireLineXAxis = JSON.parse('{!! json_encode($inquireLine['xAxis']) !!}');
- var inquireLineYAix = JSON.parse('{!! json_encode($inquireLine['yAxis']) !!}');
- var inquireLineOption = {
- tooltip: {
- trigger: 'axis',
- axisPointer: {
- type: 'cross',
- crossStyle: {
- color: '#999'
- }
- }
- },
- toolbox: {
- feature: {
- dataView: {show: true, readOnly: false},
- magicType: {show: true, type: ['bar', 'pie']},
- restore: {show: true},
- saveAsImage: {show: true}
- }
- },
- legend: {
- data: ['询盘']
- },
- xAxis: [
- {
- type: 'category',
- data: inquireLineXAxis,
- axisPointer: {
- type: 'shadow'
- },
- splitLine: {
- show: false
- }
- }
- ],
- yAxis: [
- {
- type: 'value',
- name: '',
- min: 0,
- axisLabel: {
- formatter: '{value}'
- },
- axisLine: {
- show: false //隐藏Y轴
- }
- }
- ],
- series: [
- {
- name: '询盘',
- type: 'line',
- data: inquireLineYAix
- }
- ]
- };
- inquireLineChart.setOption(inquireLineOption);
- var keywordLineChart = echarts.init(document.getElementById('keywordLine'),'wonderland');
- var keywordLineXAxis = JSON.parse('{!! json_encode($keywordLine['xAxis']) !!}');
- var keywordLineYAix = JSON.parse('{!! json_encode($keywordLine['yAxis']) !!}');
- var keywordLineOption = {
- tooltip: {
- trigger: 'axis',
- axisPointer: {
- type: 'cross',
- crossStyle: {
- color: '#999'
- }
- }
- },
- toolbox: {
- feature: {
- dataView: {show: true, readOnly: false},
- magicType: {show: true, type: ['bar', 'pie']},
- restore: {show: true},
- saveAsImage: {show: true}
- }
- },
- legend: {
- data: ['关键词']
- },
- xAxis: [
- {
- type: 'category',
- data: keywordLineXAxis,
- axisPointer: {
- type: 'shadow'
- },
- splitLine: {
- show: false
- }
- }
- ],
- yAxis: [
- {
- type: 'value',
- name: '',
- min: 0,
- axisLabel: {
- formatter: '{value}'
- },
- axisLine: {
- show: false //隐藏Y轴
- }
- }
- ],
- series: [
- {
- name: '关键词',
- type: 'line',
- data: keywordLineYAix
- }
- ]
- };
- keywordLineChart.setOption(keywordLineOption);
- </script>
- @endsection
|