工器具台账 导出

main
weitingdong 12 months ago
parent 3c2bf14819
commit c7870e3428
  1. 2
      src/main/java/org/energy/modules/leger/entity/InventoryDocument.java
  2. 56
      src/main/java/org/energy/modules/leger/excel/ToolInventoryRecordExcel.java
  3. 27
      src/main/java/org/energy/modules/leger/mapper/ToolInventoryRecordMapper.xml
  4. 2
      src/main/java/org/energy/modules/system/util/EnumFileInfoType.java

@ -34,11 +34,13 @@ public class InventoryDocument extends BaseEntity {
/** /**
* 设备台账主键 * 设备台账主键
*/ */
@JsonSerialize(using = ToStringSerializer.class)
@ApiModelProperty(value = "设备台账主键") @ApiModelProperty(value = "设备台账主键")
private Long eqLedgerId; private Long eqLedgerId;
/** /**
* 工器具编码主键 * 工器具编码主键
*/ */
@JsonSerialize(using = ToStringSerializer.class)
@ApiModelProperty(value = "工器具编码主键") @ApiModelProperty(value = "工器具编码主键")
private Long toolsCodeId; private Long toolsCodeId;
/** /**

@ -35,56 +35,60 @@ public class ToolInventoryRecordExcel implements Serializable {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
@ColumnWidth(20) @ColumnWidth(20)
@ExcelProperty(value = "设备台账编码") @ExcelProperty(value = "工器具编码")
private String eqLedgerCode; private String toolsCodeId;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "设备描述") @ExcelProperty(value = "工器具名称")
private String deviceDescription; private String toolName;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "KKS编码") @ExcelProperty(value = "规格型号")
private String kksEncoding; private String modelSpecification;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "设备种类") @ExcelProperty(value = "配置日期")
private String eqType; private String configurationDate;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "资产编码") @ExcelProperty(value = "责任班组")
private String assetCode; private String responsibleTeam;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "制造商") @ExcelProperty(value = "场站")
private String manufacturer; private String stationsExt;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "制造商国家") @ExcelProperty(value = "工器具类别")
private String manufacturerCountry; private String toolCategory;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "制造商零件号") @ExcelProperty(value = "工器具状态")
private String manufacturerPartNo; private String toolStatus;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "制造年月") @ExcelProperty(value = "已用年限")
private String manufactureDate; private String yearsInUsed;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "制造序列号") @ExcelProperty(value = "责任人")
private String manufacturingSerialNo; private String responsiblPerson;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "型号") @ExcelProperty(value = "工器具类别描述")
private String model; private String toolTypeDescription;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "大小尺寸") @ExcelProperty(value = "工器具状态描述")
private String sizeAndSize; private String toolStatusDescription;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "对象重量") @ExcelProperty(value = "出厂编号")
private String objectWeight; private String factoryNo;
@ColumnWidth(15)
@ExcelProperty(value = "是否检验周期内")
private String isInspectionPeriodExt;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty(value = "审核状态") @ExcelProperty(value = "审核状态")

@ -34,9 +34,30 @@
</select> </select>
<select id="exportData" resultType="org.energy.modules.leger.excel.ToolInventoryRecordExcel"> <select id="exportData" resultType="org.energy.modules.leger.excel.ToolInventoryRecordExcel">
SELECT eq_ledger_code,device_description,kks_encoding,eq_type,asset_code,manufacturer, SELECT tools_code_id,
manufacturer_country,manufacturer_part_no,manufacture_date,manufacturing_serial_no, tool_name,
model,size_and_size,object_weight, model_specification,
configuration_date,
responsible_team,
CASE
WHEN stations = '1' THEN '景和光伏'
WHEN stations = '2' THEN '北沙一光伏'
WHEN stations = '3' THEN '北沙二光伏'
WHEN stations = '4' THEN '达坂城风电一场'
ELSE ''
END AS stations_ext,
tool_category,
tool_status,
years_in_used,
responsibl_person,
tool_type_description,
tool_status_description,
factory_no,
CASE
WHEN is_inspection_period = '1' THEN '否'
WHEN is_inspection_period = '2' THEN '是'
ELSE ''
END AS is_inspection_period_ext,
CASE CASE
WHEN check_status = '1' THEN '审核中' WHEN check_status = '1' THEN '审核中'
WHEN check_status = '2' THEN '已审核' WHEN check_status = '2' THEN '已审核'

@ -6,7 +6,7 @@ package org.energy.modules.system.util;
public enum EnumFileInfoType { public enum EnumFileInfoType {
STATIC_LEDGER_DOCUMENT_INVENTORY("1", "ST_LD_DOC_INV", "静态台账文档清册"), STATIC_LEDGER_DOCUMENT_INVENTORY("1", "ST_LD_DOC_INV", "静态台账文档清册"),
; STATIC_TOOLS_DOCUMENT_INVENTORY("2", "ST_TO_DOC_INV", "工器具台账文档清册"),;
private String key; private String key;
private String keyDesc; private String keyDesc;

Loading…
Cancel
Save