Browse Source

报表展现 导入

Althars123 2 years ago
parent
commit
64c9fe8987

+ 1 - 1
xxgl-admin/src/main/resources/application.yml

@@ -9,7 +9,7 @@ miaxis:
   # 实例演示开关
   demoEnabled: true
   # 文件路径,使用jvm系统变量,兼容windows和linux;
-  profile: ${user.dir}/miaxis/uploadPath
+  profile: /data/uploadPath
   # 获取ip地址开关
   addressEnabled: false
   # 验证码类型 math 数组计算 char 字符验证

+ 1 - 1
xxgl-common/src/main/java/com/miaxis/common/utils/poi/ExcelUtil.java

@@ -182,7 +182,7 @@ public class ExcelUtil<T>
                 {
                     // 设置类的私有字段属性可访问.
                     field.setAccessible(true);
-                    Integer column =Integer.valueOf(attr.name());
+                    Integer column =attr.sort();
                     if (column != null)
                     {
                         fieldsMap.put(column-1, field);

+ 29 - 29
xxgl-service/src/main/java/com/miaxis/price/domain/PriceInfo.java

@@ -33,175 +33,175 @@ public class PriceInfo extends BaseBusinessEntity{
 
 
     /** 机组型号 */
-    @Excel(name = "1")
+    @Excel(name = "机组型号", sort=1)
     @TableField("unit_model")
     @ApiModelProperty(value = "机组型号")
     private String unitModel;
 
     /** 机组功率(kw) */
-    @Excel(name = "2")
+    @Excel(name = "机组功率(kw)", sort=2)
     @TableField("unit_power_kw")
     @ApiModelProperty(value = "机组功率(kw)")
     private BigDecimal unitPowerKw;
 
     /** 机组功率(kva) */
-    @Excel(name = "3")
+    @Excel(name = "机组功率(kva)", sort=3)
     @TableField("unit_power_kva")
     @ApiModelProperty(value = "机组功率(kva)")
     private BigDecimal unitPowerKva;
 
     /** 频率(Hz) */
-    @Excel(name = "4")
+    @Excel(name = "频率(Hz)", sort=4)
     @TableField("rate")
     @ApiModelProperty(value = "频率(Hz)")
     private Integer rate;
 
     /** 品牌 */
-    @Excel(name = "5")
+    @Excel(name = "品牌", sort=5)
     @TableField("brand")
     @ApiModelProperty(value = "品牌")
     private String brand;
 
     /** 柴油机型号 */
-    @Excel(name = "6")
+    @Excel(name = "柴油机型号", sort=6)
     @TableField("diesel_engine_model")
     @ApiModelProperty(value = "柴油机型号")
     private String dieselEngineModel;
 
     /** 转速 */
-    @Excel(name = "7")
+    @Excel(name = "转速", sort=7)
     @TableField("speed")
     @ApiModelProperty(value = "转速")
     private Integer speed;
 
     /** 动力价格 */
-    @Excel(name = "8")
+    @Excel(name = "动力价格", sort=8)
     @TableField("power_price")
     @ApiModelProperty(value = "动力价格")
     private BigDecimal powerPrice;
 
     /** 发电机型号 */
-    @Excel(name = "9")
+    @Excel(name = "发电机型号", sort=9)
     @TableField("generator_model")
     @ApiModelProperty(value = "发电机型号")
     private String generatorModel;
 
     /** 发电机价格 */
-    @Excel(name = "10")
+    @Excel(name = "发电机价格", sort=10)
     @TableField("generator_price")
     @ApiModelProperty(value = "发电机价格")
     private BigDecimal generatorPrice;
 
     /** 静音机壳价格 */
-    @Excel(name = "11")
+    @Excel(name = "静音机壳价格", sort=11)
     @TableField("mute_price")
     @ApiModelProperty(value = "静音机壳价格")
     private BigDecimal mutePrice;
 
     /** 开架价格 */
-    @Excel(name = "12")
+    @Excel(name = "开架价格", sort=12)
     @TableField("open_price")
     @ApiModelProperty(value = "开架价格")
     private BigDecimal openPrice;
 
     /** ATS型号 */
-    @Excel(name = "13")
+    @Excel(name = "ATS型号", sort=13)
     @TableField("ats_model")
     @ApiModelProperty(value = "ATS型号")
     private String atsModel;
 
     /** ATS价格 */
-    @Excel(name = "14")
+    @Excel(name = "ATS价格", sort=14)
     @TableField("ats_price")
     @ApiModelProperty(value = "ATS价格")
     private BigDecimal atsPrice;
 
     /** 电瓶型号 */
-    @Excel(name = "15")
+    @Excel(name = "电瓶型号", sort=15)
     @TableField("battery_model")
     @ApiModelProperty(value = "电瓶型号")
     private String batteryModel;
 
     /** 电瓶价格 */
-    @Excel(name = "16")
+    @Excel(name = "电瓶价格", sort=16)
     @TableField("battery_price")
     @ApiModelProperty(value = "电瓶价格")
     private BigDecimal batteryPrice;
 
     /** 控制器铭贝 */
-    @Excel(name = "17")
+    @Excel(name = "控制器铭贝", sort=17)
     @TableField("controller_minbei")
     @ApiModelProperty(value = "控制器铭贝")
     private String controllerMinbei;
 
     /** 控制器价格 */
-    @Excel(name = "18")
+    @Excel(name = "控制器价格", sort=18)
     @TableField("controller_price")
     @ApiModelProperty(value = "控制器价格")
     private BigDecimal controllerPrice;
 
     /** 合计含税成本(静音) */
-    @Excel(name = "19")
+    @Excel(name = "合计含税成本(静音)", sort=19)
     @TableField("total_cost_mute")
     @ApiModelProperty(value = "合计含税成本(静音)")
     private BigDecimal totalCostMute;
 
     /** 合计含税成本(开架) */
-    @Excel(name = "20")
+    @Excel(name = "合计含税成本(开架)", sort=20)
     @TableField("total_cost_open")
     @ApiModelProperty(value = "合计含税成本(开架)")
     private BigDecimal totalCostOpen;
 
     /** 静音尺寸(长) */
-    @Excel(name = "21")
+    @Excel(name = "静音尺寸(长)", sort=21)
     @TableField("mute_long")
     @ApiModelProperty(value = "静音尺寸(长)")
     private BigDecimal muteLong;
 
     /** 静音尺寸(宽) */
-    @Excel(name = "22")
+    @Excel(name = "静音尺寸(宽)", sort=22)
     @TableField("mute_width")
     @ApiModelProperty(value = "静音尺寸(宽)")
     private BigDecimal muteWidth;
 
     /** 静音尺寸(高) */
-    @Excel(name = "23")
+    @Excel(name = "静音尺寸(高)", sort=23)
     @TableField("mute_high")
     @ApiModelProperty(value = "静音尺寸(高)")
     private BigDecimal muteHigh;
 
     /** 开架尺寸(长) */
-    @Excel(name = "24")
+    @Excel(name = "开架尺寸(长)", sort=24)
     @TableField("open_long")
     @ApiModelProperty(value = "开架尺寸(长)")
     private BigDecimal openLong;
 
     /** 开架尺寸(宽) */
-    @Excel(name = "25")
+    @Excel(name = "开架尺寸(宽)", sort=25)
     @TableField("open_width")
     @ApiModelProperty(value = "开架尺寸(宽)")
     private BigDecimal openWidth;
 
     /** 开架尺寸(高) */
-    @Excel(name = "26")
+    @Excel(name = "开架尺寸(高)", sort=26)
     @TableField("open_high")
     @ApiModelProperty(value = "开架尺寸(高)")
     private BigDecimal openHigh;
 
     /** CKD尺寸(长) */
-    @Excel(name = "27")
+    @Excel(name = "CKD尺寸(长)", sort=27)
     @TableField("ckd_long")
     @ApiModelProperty(value = "CKD尺寸(长)")
     private BigDecimal ckdLong;
 
     /** CKD尺寸(宽) */
-    @Excel(name = "28")
+    @Excel(name = "CKD尺寸(宽)", sort=28)
     @TableField("ckd_width")
     @ApiModelProperty(value = "CKD尺寸(宽)")
     private BigDecimal ckdWidth;
 
     /** CKD尺寸(高) */
-    @Excel(name = "29")
+    @Excel(name = "CKD尺寸(高)", sort=29)
     @TableField("ckd_high")
     @ApiModelProperty(value = "CKD尺寸(高)")
     private BigDecimal ckdHigh;