阿里easyexcel处理表格数据
1.首先在responsity中找到easy所需要的jar包,完成下载并导入到项目所需的lib中
<!– https://mvnrepository.com/artifact/com.alibaba/easyexcel –>
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>easyexcel</artifactId>
<version>1.0.4</version> //此处是easyexcel的版本
</dependency>
2.自己新建一个excel工具类,一个excelListener(继承自analysiseventListener),处理从表格中读取的数据。
3.所有的实体都继承自baseRowModel,来自表格的属性前面加上@ExcelProperty(index=xxx),xxx从0开始递增
版权声明:本文为lqyfirst原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。