zoukankan      html  css  js  c++  java
  • 快速建立highChat数据曲线图表

    /**
     * 建立曲线图表
     * @auth:firmy
     * @param globalObj  对象ID,用于防止内存泄露
     * @param elementID  显示对象的elementID
     * @param title
     * @param subTitle
     * @param categories  X轴数据 一维数组
     * @param xName
     * @param yName
     * @param seriesArr Y轴数据 二维数组
     */
    function addLineChart(globalObj, elementID, title, subTitle, categories, xName, yName, seriesArr) {
        globalObj = new Highcharts.Chart({
            chart : {
                renderTo : elementID,
                defaultSeriesType : 'line',
                marginRight : 0,
                marginBottom : 80
            },
            title : {
                text : title,
                style : {
                    fontSize : '12px'
                },
                x : -20
            },
            xAxis : {
                title : {
                    text : xName
                },
                categories : categories,
                labels : {
                    rotation : -45,
                    align : 'right'
                }
            },
            yAxis : {
                title : {
                    text : yName
                },
                min : 0,
                plotLines : [ {
                    value : 0,
                    width : 1,
                    color : '#808080'
                } ]
            },
            tooltip : {
                formatter : function() {
                    return '<b>' + this.x + '</b><br/>' + this.series.name + ': '
                            + this.y + '个';
                }
            },
            legend : {
                layout : 'vertical',
                align : 'right',
                verticalAlign : 'top',
                x : 'left',
                y : -10,
                borderWidth : 0,
                layout : 'horizontal'
            },
            series : seriesArr
        });
    }



  • 相关阅读:
    MySQL配置文件mysql.ini参数详解、MySQL性能优化
    破解许可
    mysql本地可以访问 网络不能访问
    解决远程连接mysql很慢的方法(mysql_connect 打开连接慢)
    MYSQL数据库如何赋予远程某个IP访问权限
    linux网络编程 no route to host 解决方案
    CentOS添加路由表
    CentOS安装zip unzip命令
    Centos7下的systemctl命令与service和chkconfig
    header头参数不能带下划线
  • 原文地址:https://www.cnblogs.com/firmy/p/2784875.html
Copyright © 2011-2022 走看看