1.Highcharts 环境配置
1)安装 jQuery
2)安装 Highcharts
Highcharts 安装可以使用以下两种方式:
- 1、访问 highcharts.com 下载 Highcharts 包。
- 2、使用官方提供的 CDN 地址:http://code.highcharts.com/highcharts.js
2.新建spring-boot项目
PS:后台代码过程有点像单表查询!建项目请百度其它,菜单于下:
1)controller类
package com.highchart.controller;
import com.highchart.pojo.cylinder;
import com.highchart.service.cylinderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.List;
/**
* Created by dell on 2020/1/3.
*/
@Controller
public class higController {
@Autowired
private cylinderService cylinderService;
@RequestMapping("/index.html")
public Str