| | |
| | | <div id="div2" class='table1' onclick="getContent(2)" style="border-right: 1px solid #333;">运营统计</div> |
| | | <div id="div3" class='table1' onclick="getContent(3)" style="border-right: 1px solid #333;">教学统计</div> |
| | | </div> |
| | | |
| | | |
| | | <div class="row" id="content1" style="margin-left: 100px;"> |
| | | <div class="col-sm-11"> |
| | | <div class="form-group"> |
| | |
| | | <h2>课时数据</h2> |
| | | </br> |
| | | </br> |
| | | <span id="allCourse">现有课时总量:0小时</span> |
| | | <span>现有课时总量:0小时</span> |
| | | </br> |
| | | </br> |
| | | <div id="courseData" style="width: 1280px;height:500px;"></div> |
| | |
| | | <script src="${ctxPath}/modular/system/dataStatistics/echarts.min.js"></script> |
| | | <script src="${ctxPath}/static/js/plugins/switchery/switchery.js"></script> |
| | | <script> |
| | | function search1(){ |
| | | var time = $("#beginTime").val() |
| | | var ajax = new $ax(Feng.ctxPath + "/data/type1", function (data) { |
| | | |
| | | $("#fee1").text(data.fee1) |
| | | $("#fee2").text(data.fee2) |
| | | $("#fee3").text(data.fee3) |
| | | $("#fee4").text(data.fee4) |
| | | $("#fee5").text(data.fee5) |
| | | $("#fee7").text(data.fee7) |
| | | $("#day").val(data.dayone) |
| | | $("#month").val(data.monthone) |
| | | $("#quarter").val(data.quarterone) |
| | | $("#year").val(data.yearone) |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | var chartDom = document.getElementById('cookieTicket'); |
| | | var myChart = echarts.init(chartDom); |
| | | var option; |
| | | option = { |
| | | title: { |
| | | text: '门票收入', |
| | | subtext: '', |
| | | left: 'center' |
| | | }, |
| | | tooltip: { |
| | | trigger: 'item' |
| | | }, |
| | | |
| | | series: [ |
| | | { |
| | | name: 'Access From', |
| | | type: 'pie', |
| | | radius: '50%', |
| | | data: [ |
| | | { value: data.dayone, name: '日卡' }, |
| | | { value: data.monthone, name: '月卡' }, |
| | | { value: data.quarterone, name: '季卡' }, |
| | | { value: data.yearone, name: '年卡' }, |
| | | |
| | | ], |
| | | emphasis: { |
| | | itemStyle: { |
| | | shadowBlur: 10, |
| | | shadowOffsetX: 0, |
| | | shadowColor: 'rgba(0, 0, 0, 0.5)' |
| | | } |
| | | } |
| | | } |
| | | ] |
| | | }; |
| | | myChart.setOption(option); |
| | | |
| | | var chartDom = document.getElementById('cookieCourse'); |
| | | var myChart = echarts.init(chartDom); |
| | | var option; |
| | | option = { |
| | | title: { |
| | | text: '课程收入', |
| | | subtext: '', |
| | | left: 'center' |
| | | }, |
| | | tooltip: { |
| | | trigger: 'item' |
| | | }, |
| | | |
| | | series: [ |
| | | { |
| | | name: 'Access From', |
| | | type: 'pie', |
| | | radius: '50%', |
| | | data: data.courseData, |
| | | emphasis: { |
| | | itemStyle: { |
| | | shadowBlur: 10, |
| | | shadowOffsetX: 0, |
| | | shadowColor: 'rgba(0, 0, 0, 0.5)' |
| | | } |
| | | } |
| | | } |
| | | ] |
| | | }; |
| | | myChart.setOption(option); |
| | | |
| | | |
| | | var chartDom = document.getElementById('cookieBooking'); |
| | | var myChart = echarts.init(chartDom); |
| | | var option; |
| | | option = { |
| | | title: { |
| | | text: '订场收入', |
| | | subtext: '', |
| | | left: 'center' |
| | | }, |
| | | tooltip: { |
| | | trigger: 'item' |
| | | }, |
| | | |
| | | series: [ |
| | | { |
| | | name: 'Access From', |
| | | type: 'pie', |
| | | radius: '50%', |
| | | data: data.siteData, |
| | | emphasis: { |
| | | itemStyle: { |
| | | shadowBlur: 10, |
| | | shadowOffsetX: 0, |
| | | shadowColor: 'rgba(0, 0, 0, 0.5)' |
| | | } |
| | | } |
| | | } |
| | | ] |
| | | }; |
| | | myChart.setOption(option); |
| | | |
| | | |
| | | }, function (data) { |
| | | function search1() { |
| | | var time = $("#beginTime").val(); |
| | | var ajax9 = new $ax(Feng.ctxPath + "/data/type1", function(data){ |
| | | |
| | | }); |
| | | ajax.set("time",time); |
| | | ajax.start(); |
| | | ajax9.set("time",time); |
| | | ajax9.start(); |
| | | } |
| | | var ans = []; |
| | | var weekX = ["1周","2周","3周","4周"]; |
| | |
| | | for (var i = 1; i <= daysInMonth; i++) { |
| | | timeX.push(String(i)); |
| | | } |
| | | laydate.render({ |
| | | elem: '#beginTime' |
| | | , trigger: 'click' |
| | | , range: true |
| | | }); |
| | | |
| | | function getYears() { |
| | | var ajax2 = new $ax(Feng.ctxPath + "/data/getYears", function(data){ |
| | | yearX=data |
| | |
| | | getContent(1); |
| | | getContent1(1); |
| | | getContent2(1); |
| | | ptCourse(); |
| | | |
| | | |
| | | var ajax = new $ax(Feng.ctxPath + "/data/getIncomeData", function(resp){ |
| | |
| | | var myChart1 = echarts.init(document.getElementById('refund')); |
| | | |
| | | var myChart7 = echarts.init(document.getElementById('courseData')); |
| | | |
| | | |
| | | var ajax3 = new $ax(Feng.ctxPath + "/data/backPt", function(data){ |
| | | $("#back1").text(data.thisYear); |
| | | $("#back2").text(data.thisMonth); |
| | |
| | | ajax4.start(); |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | option7 = { |
| | | tooltip: { |
| | | trigger: 'axis' |
| | | }, |
| | | legend: { |
| | | data: ['年度耗课数量', '月度耗课数量', '周度耗课数量', '日度耗课数量'] |
| | | }, |
| | | grid: { |
| | | left: '3%', |
| | | right: '4%', |
| | | bottom: '3%', |
| | | containLabel: true |
| | | }, |
| | | toolbox: { |
| | | feature: { |
| | | saveAsImage: {} |
| | | } |
| | | }, |
| | | xAxis: { |
| | | type: 'category', |
| | | boundaryGap: false, |
| | | data: ['1月', '2月', '3月', '4月', '5月', '6月', '7月', '8月', '9月', '10月', '11月', '12月'] |
| | | }, |
| | | yAxis: { |
| | | type: 'value' |
| | | }, |
| | | series: [ |
| | | { |
| | | name: '年度耗课数量', |
| | | type: 'line', |
| | | stack: 'Total', |
| | | data: [120, 132, 101, 134, 90, 230, 160, 190, 410, 330, 210, 330] |
| | | }, |
| | | { |
| | | name: '月度耗课数量', |
| | | type: 'line', |
| | | stack: 'Total', |
| | | data: [220, 182, 191, 234, 290, 330, 310, 190, 210, 330, 410, 160] |
| | | }, |
| | | { |
| | | name: '周度耗课数量', |
| | | type: 'line', |
| | | stack: 'Total', |
| | | data: [150, 232, 201, 154, 190, 330, 410, 160, 210, 195, 210, 188] |
| | | }, |
| | | { |
| | | name: '日度耗课数量', |
| | | type: 'line', |
| | | stack: 'Total', |
| | | data: [320, 332, 301, 334, 390, 330, 320, 10, 195, 145, 188, 160] |
| | | } |
| | | ] |
| | | }; |
| | | myChart.on('legendselectchanged', obj => { |
| | | var options = myChart.getOption() |
| | | //这里是选择切换什么样的x轴,那么他会进行对Y值的切换 |
| | |
| | | myChart6.on('legendselectchanged', obj => { |
| | | var options = myChart6.getOption() |
| | | //这里是选择切换什么样的x轴,那么他会进行对Y值的切换 |
| | | console.log("看学员") |
| | | console.log(obj.name) |
| | | if (obj.name == '年度学员数') { |
| | | options.xAxis[0].data = yearX |
| | | } else if (obj.name == '月度学员数') { |
| | |
| | | } |
| | | myChart6.setOption(options, true) |
| | | }); |
| | | |
| | | |
| | | var ajax2 = new $ax(Feng.ctxPath + "/data/stuPt", function(data){ |
| | | console.log(data) |
| | | |
| | | $("#allUser").text(data.allUser) |
| | | |
| | | option6 = { |
| | | tooltip: { |
| | | trigger: 'axis' |
| | |
| | | }); |
| | | ajax2.start() |
| | | myChart6.setOption(option6); |
| | | } |
| | | |
| | | |
| | | function ptCourse() { |
| | | var myChart7 = echarts.init(document.getElementById('courseData')); |
| | | myChart7.on('legendselectchanged', obj => { |
| | | var options = myChart7.getOption() |
| | | //这里是选择切换什么样的x轴,那么他会进行对Y值的切换 |
| | | if (obj.name == '年度耗课数') { |
| | | options.xAxis[0].data = yearX |
| | | } else if (obj.name == '月度耗课数') { |
| | | options.xAxis[0].data = monthX |
| | | }else if (obj.name == '周度耗课数') { |
| | | options.xAxis[0].data = ["1周","2周","3周","4周"] |
| | | }else if (obj.name == '日度耗课数') { |
| | | options.xAxis[0].data = dataX |
| | | } |
| | | myChart7.setOption(options, true) |
| | | }); |
| | | |
| | | |
| | | var ajax2 = new $ax(Feng.ctxPath + "/data/coursePt", function(data){ |
| | | console.log(data) |
| | | $("#allCourse").text("现有课时总量:"+data.allCourse+"小时") |
| | | $("#allHour").text(data.allHour) |
| | | option7 = { |
| | | tooltip: { |
| | | trigger: 'axis' |
| | |
| | | ] |
| | | }; |
| | | }); |
| | | console.log("调用") |
| | | var myChart7 = echarts.init(document.getElementById('courseData')); |
| | | myChart7.on('legendselectchanged', obj => { |
| | | var options = myChart7.getOption() |
| | | //这里是选择切换什么样的x轴,那么他会进行对Y值的切换 |
| | | console.log("看看选择") |
| | | console.log(obj.name) |
| | | if (obj.name == '年度耗课数') { |
| | | console.log("看看年度轴") |
| | | options.xAxis[0].data = yearX |
| | | console.log(yearX) |
| | | } else if (obj.name == '月度耗课数') { |
| | | console.log("看看月度轴") |
| | | options.xAxis[0].data = monthX |
| | | console.log(monthX) |
| | | }else if (obj.name == '周度耗课数') { |
| | | options.xAxis[0].data = ["1周","2周","3周","4周"] |
| | | }else if (obj.name == '日度耗课数') { |
| | | console.log("看看日度轴") |
| | | options.xAxis[0].data = dataX |
| | | console.log(dataX) |
| | | } |
| | | myChart7.setOption(options, true) |
| | | }); |
| | | ajax2.start() |
| | | myChart7.setOption(option7); |
| | | } |
| | | |
| | | function ptCourse() { |
| | | var ajax2 = new $ax(Feng.ctxPath + "/data/coursePt", function(data){ |
| | | |
| | | $("#allHour").text(data.allHour) |
| | | console.log("周度") |
| | | console.log(data.weekData) |
| | | option7 = { |
| | | tooltip: { |
| | | trigger: 'axis' |
| | | }, |
| | | legend: { |
| | | data: ['年度耗课数', '月度耗课数', '周度耗课数', '日度耗课数'], |
| | | icon: 'stack', |
| | | selectedMode: 'single', // 单选 |
| | | selected: { |
| | | 年度耗课数: true, |
| | | 月度耗课数: false, |
| | | 周度耗课数: false, |
| | | 日度耗课数: false |
| | | }, |
| | | }, |
| | | grid: { |
| | | left: '3%', |
| | | right: '4%', |
| | | bottom: '3%', |
| | | containLabel: true |
| | | }, |
| | | toolbox: { |
| | | feature: { |
| | | saveAsImage: {} |
| | | } |
| | | }, |
| | | xAxis: { |
| | | type: 'category', |
| | | boundaryGap: false, |
| | | data: yearX |
| | | }, |
| | | yAxis: { |
| | | type: 'value' |
| | | }, |
| | | series: [ |
| | | { |
| | | name: '年度耗课数', |
| | | type: 'line', |
| | | stack: 'Total', |
| | | data: data.yearData |
| | | }, |
| | | { |
| | | name: '月度耗课数', |
| | | type: 'line', |
| | | stack: 'Total', |
| | | data: data.monthData |
| | | }, |
| | | { |
| | | name: '周度耗课数', |
| | | type: 'line', |
| | | stack: 'Total', |
| | | data: data.weekData |
| | | }, |
| | | { |
| | | name: '日度耗课数', |
| | | type: 'line', |
| | | stack: 'Total', |
| | | data: data.dayData |
| | | } |
| | | ] |
| | | }; |
| | | }); |
| | | console.log("调用") |
| | | var myChart7 = echarts.init(document.getElementById('courseData')); |
| | | myChart7.on('legendselectchanged', obj => { |
| | | var options = myChart7.getOption() |
| | | //这里是选择切换什么样的x轴,那么他会进行对Y值的切换 |
| | | console.log("看看选择") |
| | | console.log(obj.name) |
| | | if (obj.name == '年度耗课数') { |
| | | console.log("看看年度轴") |
| | | options.xAxis[0].data = yearX |
| | | console.log(yearX) |
| | | } else if (obj.name == '月度耗课数') { |
| | | console.log("看看月度轴") |
| | | options.xAxis[0].data = monthX |
| | | console.log(monthX) |
| | | }else if (obj.name == '周度耗课数') { |
| | | options.xAxis[0].data = ["1周","2周","3周","4周"] |
| | | }else if (obj.name == '日度耗课数') { |
| | | console.log("看看日度轴") |
| | | options.xAxis[0].data = dataX |
| | | console.log(dataX) |
| | | } |
| | | myChart7.setOption(options, true) |
| | | }); |
| | | |
| | | |
| | | ajax2.start() |
| | | myChart7.setOption(option7); |
| | | } |
| | |
| | | }); |
| | | ajax.start(); |
| | | ptStu() |
| | | ptCourse(); |
| | | |
| | | } |
| | | |
| | | |