diff --git a/.settings/org.eclipse.m2e.core.prefs b/.settings/org.eclipse.m2e.core.prefs
index 14b697b..91377ac 100644
--- a/.settings/org.eclipse.m2e.core.prefs
+++ b/.settings/org.eclipse.m2e.core.prefs
@@ -1,4 +1,4 @@
-activeProfiles=
+activeProfiles=cc-mzone-profile
eclipse.preferences.version=1
resolveWorkspaceProjects=true
version=1
diff --git a/README.md b/README.md
index 4ec576b..304a959 100644
--- a/README.md
+++ b/README.md
@@ -67,6 +67,12 @@ maven
--------------------------
版本修改
--------------------------
+
+ - 2.2.0-SNAPSHOT
+ - !!!没有功能更新,但是groupId 改成org.jeecg,为了以后可以直接提交到中央库了
+ - 把test 那个模块删除了
+
+
- 2.1.1-release -小更新/防止下一个预览功能太久不能发布更新
- $fe标签
- 几个可能影响使用的bug
diff --git a/easypoi-annotation/pom.xml b/easypoi-annotation/pom.xml
index 584bc2f..d638667 100644
--- a/easypoi-annotation/pom.xml
+++ b/easypoi-annotation/pom.xml
@@ -2,9 +2,9 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
4.0.0
- org.jeecgframework
+ org.jeecg
easypoi
- 2.1.2-SNAPSHOT
+ 2.2.0-SNAPSHOT
easypoi-annotation
基础注解类,解耦合
diff --git a/easypoi-base/pom.xml b/easypoi-base/pom.xml
index 61fcd58..9b0bd4d 100644
--- a/easypoi-base/pom.xml
+++ b/easypoi-base/pom.xml
@@ -2,9 +2,9 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
4.0.0
- org.jeecgframework
+ org.jeecg
easypoi
- 2.1.2-SNAPSHOT
+ 2.2.0-SNAPSHOT
easypoi-base
@@ -59,7 +59,7 @@
- org.jeecgframework
+ org.jeecg
easypoi-annotation
diff --git a/easypoi-base/src/main/java/org/jeecgframework/poi/excel/imports/ExcelImportServer.java b/easypoi-base/src/main/java/org/jeecgframework/poi/excel/imports/ExcelImportServer.java
index 9ddb407..3180fcc 100644
--- a/easypoi-base/src/main/java/org/jeecgframework/poi/excel/imports/ExcelImportServer.java
+++ b/easypoi-base/src/main/java/org/jeecgframework/poi/excel/imports/ExcelImportServer.java
@@ -143,6 +143,9 @@ public class ExcelImportServer extends ImportBaseService {
case Cell.CELL_TYPE_NUMERIC:
obj = cell.getNumericCellValue();
break;
+ case Cell.CELL_TYPE_FORMULA:
+ obj = cell.getCellFormula();
+ break;
}
return obj == null ? null : obj.toString().trim();
}
diff --git a/easypoi-test/.classpath b/easypoi-test/.classpath
deleted file mode 100644
index f67a1d3..0000000
--- a/easypoi-test/.classpath
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/easypoi-test/.gitignore b/easypoi-test/.gitignore
deleted file mode 100644
index ea8c4bf..0000000
--- a/easypoi-test/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-/target
diff --git a/easypoi-test/.project b/easypoi-test/.project
deleted file mode 100644
index 8305fe2..0000000
--- a/easypoi-test/.project
+++ /dev/null
@@ -1,23 +0,0 @@
-
-
- easypoi-test
-
-
-
-
-
- org.eclipse.jdt.core.javabuilder
-
-
-
-
- org.eclipse.m2e.core.maven2Builder
-
-
-
-
-
- org.eclipse.jdt.core.javanature
- org.eclipse.m2e.core.maven2Nature
-
-
diff --git a/easypoi-test/.settings/org.eclipse.core.resources.prefs b/easypoi-test/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index 1f887b6..0000000
--- a/easypoi-test/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding//src/main/java=UTF-8
diff --git a/easypoi-test/.settings/org.eclipse.jdt.core.prefs b/easypoi-test/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 14f521d..0000000
--- a/easypoi-test/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,5 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
-org.eclipse.jdt.core.compiler.compliance=1.6
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
-org.eclipse.jdt.core.compiler.source=1.6
diff --git a/easypoi-test/.settings/org.eclipse.m2e.core.prefs b/easypoi-test/.settings/org.eclipse.m2e.core.prefs
deleted file mode 100644
index 14b697b..0000000
--- a/easypoi-test/.settings/org.eclipse.m2e.core.prefs
+++ /dev/null
@@ -1,4 +0,0 @@
-activeProfiles=
-eclipse.preferences.version=1
-resolveWorkspaceProjects=true
-version=1
diff --git a/easypoi-test/pom.xml b/easypoi-test/pom.xml
deleted file mode 100644
index b156a90..0000000
--- a/easypoi-test/pom.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-
- 4.0.0
-
- org.jeecgframework
- easypoi
- 2.1.2-SNAPSHOT
-
- easypoi-test
-
-
- org.jeecgframework
- easypoi-base
-
-
-
- org.slf4j
- slf4j-log4j12
-
-
-
- junit
- junit
-
-
-
\ No newline at end of file
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/excel/ExcelToHtmlUtilTest.java b/easypoi-test/src/main/java/org/jeecgframework/poi/excel/ExcelToHtmlUtilTest.java
deleted file mode 100644
index c5043d7..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/excel/ExcelToHtmlUtilTest.java
+++ /dev/null
@@ -1,91 +0,0 @@
-package org.jeecgframework.poi.excel;
-
-import static org.junit.Assert.*;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileWriter;
-import java.io.IOException;
-
-import org.apache.poi.hssf.usermodel.HSSFWorkbook;
-import org.apache.poi.ss.usermodel.Workbook;
-import org.jeecgframework.poi.util.PoiPublicUtil;
-import org.junit.Test;
-
-public class ExcelToHtmlUtilTest {
-
- //@Test
- public void testToTableHtmlWorkbook() {
- try {
- Workbook wb = new HSSFWorkbook(new FileInputStream(
- new File(
- PoiPublicUtil
- .getWebRootPath("org/jeecgframework/poi/test/excel/doc/专项支出用款申请书.xls"))));
- String html = ExcelToHtmlUtil.toTableHtml(wb);
- FileWriter fw = new FileWriter("d:/专项支出用款申请书_table.html");
- fw.write(html);
- fw.close();
- } catch (FileNotFoundException e) {
- e.printStackTrace();
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
-
- //@Test
- public void testToTableHtmlWorkbookInt() {
- try {
- Workbook wb = new HSSFWorkbook(new FileInputStream(new File(
- PoiPublicUtil
- .getWebRootPath("org/jeecgframework/poi/test/excel/doc/exportTemp.xls"))));
- String html = ExcelToHtmlUtil.toTableHtml(wb, 1);
- FileWriter fw = new FileWriter("d:/exportTemp_table.html");
- fw.write(html);
- fw.close();
- } catch (FileNotFoundException e) {
- e.printStackTrace();
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
-
- @Test
- public void testToAllHtmlWorkbook() {
-
- try {
- Workbook wb = new HSSFWorkbook(new FileInputStream(
- new File("d:/tt.xls")));
-// Workbook wb = new HSSFWorkbook(new FileInputStream(
-// new File(
-// PoiPublicUtil
-// .getWebRootPath("org/jeecgframework/poi/test/excel/doc/专项支出用款申请书.xls"))));
- String html = ExcelToHtmlUtil.toTableHtml(wb);
- FileWriter fw = new FileWriter("d:/专项支出用款申请书_all.html");
- fw.write(html);
- fw.close();
- } catch (FileNotFoundException e) {
- e.printStackTrace();
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
-
- //@Test
- public void testToAllHtmlWorkbookInt() {
- try {
- Workbook wb = new HSSFWorkbook(new FileInputStream(new File(
- PoiPublicUtil
- .getWebRootPath("org/jeecgframework/poi/test/excel/doc/exportTemp.xls"))));
- String html = ExcelToHtmlUtil.toAllHtml(wb, 1);
- FileWriter fw = new FileWriter("d:/exportTemp_all.html");
- fw.write(html);
- fw.close();
- } catch (FileNotFoundException e) {
- e.printStackTrace();
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/.gitignore b/easypoi-test/src/main/java/org/jeecgframework/poi/test/.gitignore
deleted file mode 100644
index d4e38ae..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-/read
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/UtilTest.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/UtilTest.java
deleted file mode 100644
index accd039..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/UtilTest.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package org.jeecgframework.poi.test;
-
-public class UtilTest {
-
- public static void main(String[] args) {
- String text = " {{ p in pList}}";
- text = text.replace("{{", "").replace("}}", "").replaceAll("\\s{1,}", " ").trim();
- System.out.println(text);
- System.out.println(text.length());
-
-
-
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/CourseEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/CourseEntity.java
deleted file mode 100644
index c18eee4..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/CourseEntity.java
+++ /dev/null
@@ -1,108 +0,0 @@
-package org.jeecgframework.poi.test.entity;
-
-import java.util.List;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecgframework.poi.excel.annotation.ExcelCollection;
-import org.jeecgframework.poi.excel.annotation.ExcelEntity;
-import org.jeecgframework.poi.excel.annotation.ExcelTarget;
-import org.jeecgframework.poi.excel.annotation.ExcelVerify;
-
-/**
- * @Title: Entity
- * @Description: 课程
- * @author JueYue
- * @date 2013-08-31 22:53:07
- * @version V1.0
- *
- */
-@SuppressWarnings("serial")
-@ExcelTarget("courseEntity")
-public class CourseEntity implements java.io.Serializable {
- /** 主键 */
- private String id;
- /** 课程名称 */
- @Excel(name = "课程名称", orderNum = "1", width = 15, needMerge = true)
- private String name;
- /** 老师主键 */
- @ExcelEntity(id = "yuwen")
- @ExcelVerify()
- private TeacherEntity teacher;
- /** 老师主键 */
- //@ExcelEntity(id = "shuxue")
- private TeacherEntity shuxueteacher;
-
- @ExcelCollection(name = "", orderNum = "4")
- private List students;
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String 主键
- */
-
- public String getId() {
- return this.id;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String 课程名称
- */
- public String getName() {
- return this.name;
- }
-
- public TeacherEntity getShuxueteacher() {
- return shuxueteacher;
- }
-
- public List getStudents() {
- return students;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String 老师主键
- */
- public TeacherEntity getTeacher() {
- return teacher;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String 主键
- */
- public void setId(String id) {
- this.id = id;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String 课程名称
- */
- public void setName(String name) {
- this.name = name;
- }
-
- public void setShuxueteacher(TeacherEntity shuxueteacher) {
- this.shuxueteacher = shuxueteacher;
- }
-
- public void setStudents(List students) {
- this.students = students;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String 老师主键
- */
- public void setTeacher(TeacherEntity teacher) {
- this.teacher = teacher;
- }
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/ExcelVerifyEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/ExcelVerifyEntity.java
deleted file mode 100644
index d513cac..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/ExcelVerifyEntity.java
+++ /dev/null
@@ -1,124 +0,0 @@
-package org.jeecgframework.poi.test.entity;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecgframework.poi.excel.annotation.ExcelVerify;
-
-/**
- * Excel导入校验类
- * @author JueYue
- * @date 2015年2月24日 下午2:21:07
- */
-public class ExcelVerifyEntity {
-
- /**
- * Email校验
- */
- @Excel(name = "Email", width = 25)
- @ExcelVerify(isEmail = true, notNull = true)
- private String email;
- /**
- * 手机号校验
- */
- @Excel(name = "Mobile", width = 20)
- @ExcelVerify(isMobile = true, notNull = true)
- private String mobile;
- /**
- * 电话校验
- */
- @Excel(name = "Tel", width = 20)
- @ExcelVerify(isTel = true, notNull = true)
- private String tel;
- /**
- * 最长校验
- */
- @Excel(name = "MaxLength")
- @ExcelVerify(maxLength = 15)
- private String maxLength;
- /**
- * 最短校验
- */
- @Excel(name = "MinLength")
- @ExcelVerify(minLength = 3)
- private String minLength;
- /**
- * 非空校验
- */
- @Excel(name = "NotNull")
- @ExcelVerify(notNull = true)
- private String notNull;
- /**
- * 正则校验
- */
- @Excel(name = "Regex")
- @ExcelVerify(regex = "[\u4E00-\u9FA5]*", regexTip = "不是中文")
- private String regex;
- /**
- * 接口校验
- */
- private String interHandler;
-
- public String getEmail() {
- return email;
- }
-
- public void setEmail(String email) {
- this.email = email;
- }
-
- public String getMobile() {
- return mobile;
- }
-
- public void setMobile(String mobile) {
- this.mobile = mobile;
- }
-
- public String getTel() {
- return tel;
- }
-
- public void setTel(String tel) {
- this.tel = tel;
- }
-
- public String getMaxLength() {
- return maxLength;
- }
-
- public void setMaxLength(String maxLength) {
- this.maxLength = maxLength;
- }
-
- public String getMinLength() {
- return minLength;
- }
-
- public void setMinLength(String minLength) {
- this.minLength = minLength;
- }
-
- public String getNotNull() {
- return notNull;
- }
-
- public void setNotNull(String notNull) {
- this.notNull = notNull;
- }
-
- public String getRegex() {
- return regex;
- }
-
- public void setRegex(String regex) {
- this.regex = regex;
- }
-
- public String getInterHandler() {
- return interHandler;
- }
-
- public void setInterHandler(String interHandler) {
- this.interHandler = interHandler;
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/MsgClient.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/MsgClient.java
deleted file mode 100644
index ec046a0..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/MsgClient.java
+++ /dev/null
@@ -1,146 +0,0 @@
-package org.jeecgframework.poi.test.entity;
-
-import java.util.Date;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecgframework.poi.excel.annotation.ExcelEntity;
-
-/**
- * @Title: Entity
- * @Description: 通讯录
- * @author JueYue
- * @date 2014-09-22 16:03:32
- * @version V1.0
- *
- */
-@SuppressWarnings("serial")
-public class MsgClient implements java.io.Serializable {
- /** id */
- private java.lang.String id;
- // 电话号码(主键)
- @Excel(name = "电话号码")
- private String clientPhone = null;
- // 客户姓名
- @Excel(name = "姓名")
- private String clientName = null;
- // 所属分组
- @ExcelEntity
- private MsgClientGroup group = null;
- // 备注
- @Excel(name = "备注")
- private String remark = null;
- // 生日
- @Excel(name = "出生日期")
- private Date birthday = null;
- // 创建人
- private String createBy = null;
-
- /**
- * 方法: 取得java.util.Date
- *
- * @return: java.util.Date 生日
- */
- public java.util.Date getBirthday() {
- return this.birthday;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String 客户姓名
- */
- public java.lang.String getClientName() {
- return this.clientName;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String 电话号码
- */
- public java.lang.String getClientPhone() {
- return this.clientPhone;
- }
-
- public String getCreateBy() {
- return createBy;
- }
-
- public MsgClientGroup getGroup() {
- return group;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String id
- */
-
- public java.lang.String getId() {
- return this.id;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String 备注
- */
- public java.lang.String getRemark() {
- return this.remark;
- }
-
- /**
- * 方法: 设置java.util.Date
- *
- * @param: java.util.Date 生日
- */
- public void setBirthday(java.util.Date birthday) {
- this.birthday = birthday;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String 客户姓名
- */
- public void setClientName(java.lang.String clientName) {
- this.clientName = clientName;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String 电话号码
- */
- public void setClientPhone(java.lang.String clientPhone) {
- this.clientPhone = clientPhone;
- }
-
- public void setCreateBy(String createBy) {
- this.createBy = createBy;
- }
-
- public void setGroup(MsgClientGroup group) {
- this.group = group;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String id
- */
- public void setId(java.lang.String id) {
- this.id = id;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param remark
- *
- * @param: java.lang.String 备注
- */
- public void setRemark(java.lang.String remark) {
- this.remark = remark;
- }
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/MsgClientGroup.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/MsgClientGroup.java
deleted file mode 100644
index 94501ea..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/MsgClientGroup.java
+++ /dev/null
@@ -1,55 +0,0 @@
-package org.jeecgframework.poi.test.entity;
-
-import java.io.Serializable;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-
-/**
- * 客户分组表
- *
- * @author yjl
- *
- */
-public class MsgClientGroup implements Serializable {
-
- /**
- *
- */
- private static final long serialVersionUID = 6946265640897464878L;
-
- // 组名
- @Excel(name = "分组")
- private String groupName = null;
- /**
- * 创建人
- */
- private String createBy;
-
- // 一个组下 可能存在N多客户
- //private List clients = null;
-
- /*@org.codehaus.jackson.annotate.JsonIgnore
- @OneToMany(cascade = CascadeType.REMOVE,fetch = FetchType.LAZY,mappedBy = "group")
- public List getClients() {
- return clients;
- }
-
- public void setClients(List clients) {
- this.clients = clients;
- }*/
- public String getCreateBy() {
- return createBy;
- }
-
- public String getGroupName() {
- return groupName;
- }
-
- public void setCreateBy(String createBy) {
- this.createBy = createBy;
- }
-
- public void setGroupName(String groupName) {
- this.groupName = groupName;
- }
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/StudentEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/StudentEntity.java
deleted file mode 100644
index 271b1ae..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/StudentEntity.java
+++ /dev/null
@@ -1,119 +0,0 @@
-package org.jeecgframework.poi.test.entity;
-
-import java.util.Date;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-
-/**
- * @author JueYue
- * @version V1.0
- * @Title: Entity
- * @Description: 学生
- * @date 2013-08-31 22:53:34
- */
-@SuppressWarnings("serial")
-public class StudentEntity implements java.io.Serializable {
- /**
- * id
- */
- private String id;
- /**
- * 学生姓名
- */
- @Excel(name = "学生姓名", height = 20, width = 30)
- private String name;
- /**
- * 学生性别
- */
- @Excel(name = "学生性别", replace = { "男_1", "女_2" }, suffix = "生")
- private int sex;
-
- @Excel(name = "出生日期", databaseFormat = "yyyyMMddHHmmss", format = "yyyy-MM-dd")
- private Date birthday;
-
- @Excel(name = "进校日期", databaseFormat = "yyyyMMddHHmmss", format = "yyyy-MM-dd")
- private java.sql.Time registrationDate;
- /**
- * 课程主键
- */
- private CourseEntity course;
-
- public CourseEntity getCourse() {
- return course;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String id
- */
- public String getId() {
- return this.id;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String 学生姓名
- */
- public String getName() {
- return this.name;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String 学生性别
- */
- public int getSex() {
- return this.sex;
- }
-
- public void setCourse(CourseEntity course) {
- this.course = course;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String id
- */
- public void setId(String id) {
- this.id = id;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String 学生姓名
- */
- public void setName(String name) {
- this.name = name;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String 学生性别
- */
- public void setSex(int sex) {
- this.sex = sex;
- }
-
- public Date getBirthday() {
- return birthday;
- }
-
- public void setBirthday(Date birthday) {
- this.birthday = birthday;
- }
-
- public java.sql.Time getRegistrationDate() {
- return registrationDate;
- }
-
- public void setRegistrationDate(java.sql.Time registrationDate) {
- this.registrationDate = registrationDate;
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/TeacherEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/TeacherEntity.java
deleted file mode 100644
index 35cacab..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/TeacherEntity.java
+++ /dev/null
@@ -1,72 +0,0 @@
-package org.jeecgframework.poi.test.entity;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecgframework.poi.excel.annotation.ExcelTarget;
-
-/**
- * @Title: Entity
- * @Description: 课程老师
- * @author JueYue
- * @date 2013-08-31 22:52:17
- * @version V1.0
- *
- */
-@SuppressWarnings("serial")
-@ExcelTarget("teacherEntity")
-public class TeacherEntity implements java.io.Serializable {
- /** id */
- @Excel(name = "老师ID_teacherEntity,老师属性_courseEntity", orderNum = "2", needMerge = false)
- private String id;
- /** name */
- @Excel(name = "老师姓名_yuwen,数学老师_shuxue", orderNum = "2", mergeVertical = true)
- private String name;
-
- /*
- * @Excel(exportName="老师照片",orderNum="3",exportType=2,exportFieldHeight=15,
- * exportFieldWidth=20) private String pic;
- */
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String id
- */
-
- public String getId() {
- return this.id;
- }
-
- /**
- * 方法: 取得java.lang.String
- *
- * @return: java.lang.String name
- */
- public String getName() {
- return this.name;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String id
- */
- public void setId(String id) {
- this.id = id;
- }
-
- /**
- * 方法: 设置java.lang.String
- *
- * @param: java.lang.String name
- */
- public void setName(String name) {
- this.name = name;
- }
-
- /*
- * public String getPic() { // if(StringUtils.isEmpty(pic)){ // pic =
- * "plug-in/login/images/jeecg.png"; // } return pic; }
- *
- * public void setPic(String pic) { this.pic = pic; }
- */
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/TestEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/TestEntity.java
deleted file mode 100644
index 6bb625d..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/TestEntity.java
+++ /dev/null
@@ -1,28 +0,0 @@
-package org.jeecgframework.poi.test.entity;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-
-public class TestEntity {
-
- @Excel(name = "蓝牙POS机")
- private String lanya;
- @Excel(name = "蓝牙点付宝")
- private String pos;
-
- public String getLanya() {
- return lanya;
- }
-
- public void setLanya(String lanya) {
- this.lanya = lanya;
- }
-
- public String getPos() {
- return pos;
- }
-
- public void setPos(String pos) {
- this.pos = pos;
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/samename/ClassName.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/samename/ClassName.java
deleted file mode 100644
index d84ff39..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/samename/ClassName.java
+++ /dev/null
@@ -1,46 +0,0 @@
-package org.jeecgframework.poi.test.entity.samename;
-
-import java.util.List;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecgframework.poi.excel.annotation.ExcelCollection;
-import org.jeecgframework.poi.test.entity.StudentEntity;
-
-public class ClassName {
-
- @Excel(name="班级")
- private String name;
-
- @ExcelCollection(name="小组A")
- private List arrA;
-
- @ExcelCollection(name="小组B")
- private List arrB;
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public List getArrA() {
- return arrA;
- }
-
- public void setArrA(List arrA) {
- this.arrA = arrA;
- }
-
- public List getArrB() {
- return arrB;
- }
-
- public void setArrB(List arrB) {
- this.arrB = arrB;
- }
-
-
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/statistics/StatisticEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/statistics/StatisticEntity.java
deleted file mode 100644
index 3848c9f..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/statistics/StatisticEntity.java
+++ /dev/null
@@ -1,80 +0,0 @@
-package org.jeecgframework.poi.test.entity.statistics;
-
-import java.math.BigDecimal;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-
-/**
- * 统计测试类
- * @author JueYue
- * @date 2014年12月17日 上午11:51:10
- */
-public class StatisticEntity {
-
- @Excel(name = "名称")
- private String name;
-
- @Excel(name = "int 测试", width = 15, isStatistics = true)
- private int intTest;
-
- @Excel(name = "long 测试", width = 15, isStatistics = true)
- private long longTest;
-
- @Excel(name = "double 测试", width = 15, isStatistics = true)
- private double doubleTest;
-
- @Excel(name = "string 测试", width = 15, isStatistics = true)
- private String stringTest;
-
- @Excel(name = "BigDecimal 测试", width = 15, isStatistics = true)
- private BigDecimal bigDecimalTest;
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public int getIntTest() {
- return intTest;
- }
-
- public void setIntTest(int intTest) {
- this.intTest = intTest;
- }
-
- public long getLongTest() {
- return longTest;
- }
-
- public void setLongTest(long longTest) {
- this.longTest = longTest;
- }
-
- public double getDoubleTest() {
- return doubleTest;
- }
-
- public void setDoubleTest(double doubleTest) {
- this.doubleTest = doubleTest;
- }
-
- public String getStringTest() {
- return stringTest;
- }
-
- public void setStringTest(String stringTest) {
- this.stringTest = stringTest;
- }
-
- public BigDecimal getBigDecimalTest() {
- return bigDecimalTest;
- }
-
- public void setBigDecimalTest(BigDecimal bigDecimalTest) {
- this.bigDecimalTest = bigDecimalTest;
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/BudgetAccountsEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/BudgetAccountsEntity.java
deleted file mode 100644
index a3be7ac..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/BudgetAccountsEntity.java
+++ /dev/null
@@ -1,34 +0,0 @@
-package org.jeecgframework.poi.test.entity.temp;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-
-/**
- * 预算
- * @author JueYue
- * @date 2014年12月27日 下午9:08:03
- */
-public class BudgetAccountsEntity {
-
- @Excel(name = "编码")
- private String code;
-
- @Excel(name = "名称")
- private String name;
-
- public String getCode() {
- return code;
- }
-
- public void setCode(String code) {
- this.code = code;
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/PayeeEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/PayeeEntity.java
deleted file mode 100644
index 1fa4919..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/PayeeEntity.java
+++ /dev/null
@@ -1,40 +0,0 @@
-package org.jeecgframework.poi.test.entity.temp;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-
-public class PayeeEntity {
-
- @Excel(name = "全称")
- private String name;
-
- @Excel(name = "银行账号")
- private String bankAccount;
-
- @Excel(name = "开户银行")
- private String bankName;
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public String getBankAccount() {
- return bankAccount;
- }
-
- public void setBankAccount(String bankAccount) {
- this.bankAccount = bankAccount;
- }
-
- public String getBankName() {
- return bankName;
- }
-
- public void setBankName(String bankName) {
- this.bankName = bankName;
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/TemplateExcelExportEntity.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/TemplateExcelExportEntity.java
deleted file mode 100644
index b33914f..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/entity/temp/TemplateExcelExportEntity.java
+++ /dev/null
@@ -1,99 +0,0 @@
-package org.jeecgframework.poi.test.entity.temp;
-
-import java.io.Serializable;
-import java.util.List;
-
-import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecgframework.poi.excel.annotation.ExcelCollection;
-import org.jeecgframework.poi.excel.annotation.ExcelEntity;
-
-/**
- * 模板导出 测试类
- * @author JueYue
- * @date 2014年12月26日 上午9:39:13
- */
-public class TemplateExcelExportEntity implements Serializable {
-
- /**
- *
- */
- private static final long serialVersionUID = 1L;
-
- @Excel(name = "序号")
- private String index;
-
- @Excel(name = "资金性质")
- private String accountType;
-
- @ExcelCollection(name = "预算科目")
- private List budgetAccounts;
-
- @Excel(name = "项目名称")
- private String projectName;
-
- @ExcelEntity(name = "收款人")
- private PayeeEntity payee;
-
- @Excel(name = "申请金额")
- private String amountApplied;
-
- @Excel(name = "核定金额")
- private String approvedAmount;
-
- public String getIndex() {
- return index;
- }
-
- public void setIndex(String index) {
- this.index = index;
- }
-
- public String getAccountType() {
- return accountType;
- }
-
- public void setAccountType(String accountType) {
- this.accountType = accountType;
- }
-
- public List getBudgetAccounts() {
- return budgetAccounts;
- }
-
- public void setBudgetAccounts(List budgetAccounts) {
- this.budgetAccounts = budgetAccounts;
- }
-
- public String getProjectName() {
- return projectName;
- }
-
- public void setProjectName(String projectName) {
- this.projectName = projectName;
- }
-
- public PayeeEntity getPayee() {
- return payee;
- }
-
- public void setPayee(PayeeEntity payee) {
- this.payee = payee;
- }
-
- public String getAmountApplied() {
- return amountApplied;
- }
-
- public void setAmountApplied(String amountApplied) {
- this.amountApplied = amountApplied;
- }
-
- public String getApprovedAmount() {
- return approvedAmount;
- }
-
- public void setApprovedAmount(String approvedAmount) {
- this.approvedAmount = approvedAmount;
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/exportTemp.xls b/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/exportTemp.xls
deleted file mode 100644
index 545a407..0000000
Binary files a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/exportTemp.xls and /dev/null differ
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/foreach.xlsx b/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/foreach.xlsx
deleted file mode 100644
index 523a44e..0000000
Binary files a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/foreach.xlsx and /dev/null differ
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/专项支出用款申请书.xls b/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/专项支出用款申请书.xls
deleted file mode 100644
index 7528860..0000000
Binary files a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/doc/专项支出用款申请书.xls and /dev/null differ
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/styler/ExcelExportStatisticStyler.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/styler/ExcelExportStatisticStyler.java
deleted file mode 100644
index 396dad5..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/styler/ExcelExportStatisticStyler.java
+++ /dev/null
@@ -1,41 +0,0 @@
-package org.jeecgframework.poi.test.excel.styler;
-
-import org.apache.poi.hssf.usermodel.HSSFDataFormat;
-import org.apache.poi.ss.usermodel.BuiltinFormats;
-import org.apache.poi.ss.usermodel.CellStyle;
-import org.apache.poi.ss.usermodel.Workbook;
-import org.jeecgframework.poi.excel.entity.params.ExcelExportEntity;
-import org.jeecgframework.poi.excel.export.styler.ExcelExportStylerDefaultImpl;
-
-/**
- * Excel 自定义styler 的例子
- * @author JueYue
- * @date 2015年3月29日 下午9:04:41
- */
-public class ExcelExportStatisticStyler extends ExcelExportStylerDefaultImpl {
-
- private CellStyle numberCellStyle;
-
- public ExcelExportStatisticStyler(Workbook workbook) {
- super(workbook);
- createNumberCellStyler();
- }
-
- private void createNumberCellStyler() {
- numberCellStyle = workbook.createCellStyle();
- numberCellStyle.setAlignment(CellStyle.ALIGN_CENTER);
- numberCellStyle.setVerticalAlignment(CellStyle.VERTICAL_CENTER);
- numberCellStyle.setDataFormat((short) BuiltinFormats.getBuiltinFormat("0.00"));
- numberCellStyle.setWrapText(true);
- }
-
- @Override
- public CellStyle getStyles(boolean noneStyler, ExcelExportEntity entity) {
- if (entity != null
- && (entity.getName().contains("int") || entity.getName().contains("double"))) {
- return numberCellStyle;
- }
- return super.getStyles(noneStyler, entity);
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/ManySheetOneSyler.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/ManySheetOneSyler.java
deleted file mode 100644
index 3cf3ff5..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/ManySheetOneSyler.java
+++ /dev/null
@@ -1,41 +0,0 @@
-package org.jeecgframework.poi.test.excel.template;
-
-import org.apache.poi.ss.usermodel.CellStyle;
-import org.apache.poi.ss.usermodel.Workbook;
-import org.jeecgframework.poi.excel.export.styler.ExcelExportStylerDefaultImpl;
-
-public class ManySheetOneSyler extends ExcelExportStylerDefaultImpl {
-
- private static CellStyle stringSeptailStyle;
-
- private static CellStyle stringNoneStyle;
-
- public ManySheetOneSyler(Workbook workbook) {
- super(workbook);
- }
-
- @Override
- public CellStyle stringSeptailStyle(Workbook workbook, boolean isWarp) {
- if (stringSeptailStyle == null) {
- stringSeptailStyle = workbook.createCellStyle();
- stringSeptailStyle.setAlignment(CellStyle.ALIGN_CENTER);
- stringSeptailStyle.setVerticalAlignment(CellStyle.VERTICAL_CENTER);
- stringSeptailStyle.setDataFormat(STRING_FORMAT);
- stringSeptailStyle.setWrapText(true);
- }
- return stringSeptailStyle;
- }
-
- @Override
- public CellStyle stringNoneStyle(Workbook workbook, boolean isWarp) {
- if (stringNoneStyle == null) {
- stringNoneStyle = workbook.createCellStyle();
- stringNoneStyle.setAlignment(CellStyle.ALIGN_CENTER);
- stringNoneStyle.setVerticalAlignment(CellStyle.VERTICAL_CENTER);
- stringNoneStyle.setDataFormat(STRING_FORMAT);
- stringNoneStyle.setWrapText(true);
- }
- return stringNoneStyle;
- }
-
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/TemplateExcelExportTest.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/TemplateExcelExportTest.java
deleted file mode 100644
index 59a1488..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/TemplateExcelExportTest.java
+++ /dev/null
@@ -1,84 +0,0 @@
-package org.jeecgframework.poi.test.excel.template;
-
-import static org.junit.Assert.*;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.apache.poi.ss.usermodel.Workbook;
-import org.jeecgframework.poi.excel.ExcelExportUtil;
-import org.jeecgframework.poi.excel.entity.TemplateExportParams;
-import org.jeecgframework.poi.excel.export.styler.ExcelExportStylerBorderImpl;
-import org.jeecgframework.poi.excel.export.styler.ExcelExportStylerColorImpl;
-import org.jeecgframework.poi.excel.export.styler.ExcelExportStylerDefaultImpl;
-import org.jeecgframework.poi.test.entity.statistics.StatisticEntity;
-import org.jeecgframework.poi.test.entity.temp.BudgetAccountsEntity;
-import org.jeecgframework.poi.test.entity.temp.PayeeEntity;
-import org.jeecgframework.poi.test.entity.temp.TemplateExcelExportEntity;
-import org.junit.Test;
-
-import com.google.common.collect.Lists;
-
-public class TemplateExcelExportTest {
-
- @Test
- public void test() throws Exception {
- TemplateExportParams params = new TemplateExportParams(
- "org/jeecgframework/poi/test/excel/doc/专项支出用款申请书.xls");
- params.setHeadingStartRow(3);
- params.setHeadingRows(2);
- params.setStyle(ExcelExportStylerColorImpl.class);
- Map map = new HashMap();
- map.put("date", "2014-12-25");
- map.put("money", 2000000.00);
- map.put("upperMoney", "贰佰万");
- map.put("company", "执笔潜行科技有限公司");
- map.put("bureau", "财政局");
- map.put("person", "JueYue");
- map.put("phone", "1879740****");
-
- List list = new ArrayList();
-
- for (int i = 0; i < 4; i++) {
- TemplateExcelExportEntity entity = new TemplateExcelExportEntity();
- entity.setIndex(i + 1 + "");
- entity.setAccountType("开源项目");
- entity.setProjectName("EasyPoi " + i + "期");
- entity.setAmountApplied(i * 10000 + "");
- entity.setApprovedAmount((i + 1) * 10000 - 100 + "");
- List budgetAccounts = Lists.newArrayList();
- for (int j = 0; j < 1; j++) {
- BudgetAccountsEntity accountsEntity = new BudgetAccountsEntity();
- accountsEntity.setCode("A001");
- accountsEntity.setName("设计");
- budgetAccounts.add(accountsEntity);
- accountsEntity = new BudgetAccountsEntity();
- accountsEntity.setCode("A002");
- accountsEntity.setName("开发");
- budgetAccounts.add(accountsEntity);
- }
- entity.setBudgetAccounts(budgetAccounts);
- PayeeEntity payeeEntity = new PayeeEntity();
- payeeEntity.setBankAccount("6222 0000 1234 1234");
- payeeEntity.setBankName("中国银行");
- payeeEntity.setName("小明");
- entity.setPayee(payeeEntity);
- list.add(entity);
- }
-
- Workbook workbook = ExcelExportUtil.exportExcel(params, TemplateExcelExportEntity.class,
- list, map);
- File savefile = new File("d:/");
- if (!savefile.exists()) {
- savefile.mkdirs();
- }
- FileOutputStream fos = new FileOutputStream("d:/tt.xls");
- workbook.write(fos);
- fos.close();
- }
-}
diff --git a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/TemplateExcelSheetTest.java b/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/TemplateExcelSheetTest.java
deleted file mode 100644
index 102bba7..0000000
--- a/easypoi-test/src/main/java/org/jeecgframework/poi/test/excel/template/TemplateExcelSheetTest.java
+++ /dev/null
@@ -1,113 +0,0 @@
-package org.jeecgframework.poi.test.excel.template;
-
-import java.io.File;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.apache.poi.hssf.usermodel.HSSFWorkbook;
-import org.apache.poi.ss.usermodel.Workbook;
-import org.jeecgframework.poi.excel.entity.ExportParams;
-import org.jeecgframework.poi.excel.entity.TemplateExportParams;
-import org.jeecgframework.poi.excel.entity.params.ExcelExportEntity;
-import org.jeecgframework.poi.excel.export.ExcelExportServer;
-import org.jeecgframework.poi.excel.export.template.ExcelExportOfTemplateUtil;
-import org.junit.Test;
-
-public class TemplateExcelSheetTest {
-
- @Test
- public void test() throws Exception {
- ExcelExportServer util = new ExcelExportServer();
- Workbook workbook = new HSSFWorkbook();
- ExportParams entity = new ExportParams();
- entity.setCreateHeadRows(false);
- entity.setStyle(ManySheetOneSyler.class);
- List entityList = new ArrayList();
- ExcelExportEntity e = new ExcelExportEntity();
- e.setHeight(40);
- e.setWidth(40);
- e.setWrap(true);
- e.setName("one");
- e.setKey("one");
- entityList.add(e);
- e = new ExcelExportEntity();
- e.setHeight(40);
- e.setWidth(40);
- e.setWrap(true);
- e.setName("two");
- e.setKey("two");
- entityList.add(e);
- e = new ExcelExportEntity();
- e.setHeight(40);
- e.setWidth(40);
- e.setWrap(true);
- e.setName("three");
- e.setKey("three");
- entityList.add(e);
- e = new ExcelExportEntity();
- e.setHeight(40);
- e.setWidth(40);
- e.setWrap(true);
- e.setName("four");
- e.setKey("four");
- entityList.add(e);
- e = new ExcelExportEntity();
- e.setHeight(40);
- e.setWidth(40);
- e.setWrap(true);
- e.setName("five");
- e.setKey("five");
- entityList.add(e);
-
- //这里加入了40个数据源
- List