From a86556be815c72da0fa020eb2750fb2fa73c637a Mon Sep 17 00:00:00 2001
From: jyy <935090232@qq.com>
Date: Mon, 07 Dec 2020 07:50:16 +0800
Subject: [PATCH] 更新
---
zq-erp/src/main/resources/templates/views/admin/hive-erp/analysis/customerFlow.html | 12 +++---
zq-erp/src/main/resources/static/js/systools/ChartsUtils.js | 56 +++++++++++++++++++++++++++
2 files changed, 61 insertions(+), 7 deletions(-)
diff --git a/zq-erp/src/main/resources/static/js/systools/ChartsUtils.js b/zq-erp/src/main/resources/static/js/systools/ChartsUtils.js
index 93a7553..cb5a624 100644
--- a/zq-erp/src/main/resources/static/js/systools/ChartsUtils.js
+++ b/zq-erp/src/main/resources/static/js/systools/ChartsUtils.js
@@ -11,7 +11,6 @@
this.$unitSelect = $("#unitSelect");
//记录当前视图的格式化字符串
this.dateFmt = "";
-
//绑定搜索事件
$('#serach').on("click",{charts:this},this.updateChartsDate);
//时间单位选择变化
@@ -119,3 +118,58 @@
event.data.charts.loadChartData();
}
}
+
+/**
+ *指定图表的配置项和数据
+ */
+ChartsUtils.prototype.getption=function(title) {
+ return {
+ title: {
+ text: title,
+ padding: 20
+ },
+ legend: {},
+ toolbox: {
+ show: true,
+ feature: {
+ mark: {show: true},
+ dataView: {show: true, readOnly: false},
+ magicType: {show: true, type: ['line', 'bar']},
+ restore: {show: true},
+ saveAsImage: {show: true}
+ }
+ },
+ tooltip: {
+ trigger: 'axis'
+ },
+ xAxis: {
+ type: 'category',
+ boundaryGap: false,
+ axisLabel: {
+ rotate: 30
+ },
+ splitLine: {
+ show: false,
+ },
+ data: []
+ },
+ yAxis: {
+ type: 'value'
+ },
+ dataZoom: [
+ {
+ id: 'dataZoomX',
+ type: 'slider',
+ xAxisIndex: [0],
+ filterMode: 'filter'
+ }
+ ],
+ animation: true,
+ animationDuration: 1000,
+ animationDurationUpdate: 1000,
+ animationEasing: 'linear',
+ animationEasingUpdate: 'linear',
+ }
+
+};
+
diff --git a/zq-erp/src/main/resources/templates/views/admin/hive-erp/analysis/customerFlow.html b/zq-erp/src/main/resources/templates/views/admin/hive-erp/analysis/customerFlow.html
index 53c9190..2cbe29c 100644
--- a/zq-erp/src/main/resources/templates/views/admin/hive-erp/analysis/customerFlow.html
+++ b/zq-erp/src/main/resources/templates/views/admin/hive-erp/analysis/customerFlow.html
@@ -141,12 +141,12 @@
var myChart1 = echarts.init(document.getElementById('echarts-line-chart1'), 'macarons');
var myChart2 = echarts.init(document.getElementById('echarts-line-chart2'), 'macarons');
var myChart3 = echarts.init(document.getElementById('echarts-line-chart3'), 'macarons');
- /*
- 点击事件
- myChart1.on('click', function (params) {
- console.log(params);
- });
-*/
+ /*
+ 点击事件
+ myChart1.on('click', function (params) {
+ console.log(params);
+ });
+ */
// 指定图表的配置项和数据
function getption() {
return {
--
Gitblit v1.9.1