easypoi(史上最简单,最全面,最xxx的导出excel教程)

1.依赖引入



    cn.afterturn
    easypoi-base
    3.2.0


    cn.afterturn
    easypoi-web
    3.2.0


    cn.afterturn
    easypoi-annotation
    3.2.0

2.实体类(注意添加注解)

public class Person {

@Excel(name = "付费金额", orderNum = "0")

private Integer pay_money;

@Excel(name = "作者", orderNum = "1")

private Integer author;

public ReportsMonth(Integer pay_money, Integer author_uv) {

     this.pay_money = pay_money;

     this.author_uv = author_uv;

}

//省略setter和getter方法

}

3.控制层

easypoi(史上最简单,最全面,最xxx的导出excel教程)_第1张图片

4.访问

http://localhost:8888/common/exportExcels

你可能感兴趣的:(easypoi)