init new
This commit is contained in:
@@ -0,0 +1,201 @@
|
||||
package com.point.strategy.oaDocking.bean;
|
||||
/**
|
||||
* 文书简化原文实体
|
||||
*/
|
||||
public class DocOriginalOaEntity {
|
||||
|
||||
private Integer id;
|
||||
private Integer entityId;
|
||||
private Integer recid;
|
||||
private String fileName;
|
||||
private String fileNameServer;
|
||||
private String fileType;
|
||||
private Float fileLen;
|
||||
private String filePath;
|
||||
private String openType;
|
||||
private Integer pageNo;
|
||||
private String version;
|
||||
private String authorName;
|
||||
private String fileRemark;
|
||||
private String fileDes;
|
||||
private Integer downs;
|
||||
private Integer veiws;
|
||||
private String metadataValue;
|
||||
private Integer metadataType;
|
||||
private Integer ocrCheck;
|
||||
private Integer fileStatus;
|
||||
private Integer fileAttr;
|
||||
private String md5Code;
|
||||
private String md5CheckDate;
|
||||
private String dataContent;
|
||||
private String fileContent;
|
||||
private Integer isDivided;
|
||||
private String dividedContent;
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
public Integer getEntityId() {
|
||||
return entityId;
|
||||
}
|
||||
public void setEntityId(Integer entityId) {
|
||||
this.entityId = entityId;
|
||||
}
|
||||
|
||||
public Integer getRecid() {
|
||||
return recid;
|
||||
}
|
||||
public void setRecid(Integer recid) {
|
||||
this.recid = recid;
|
||||
}
|
||||
public String getFileName() {
|
||||
return fileName;
|
||||
}
|
||||
public void setFileName(String fileName) {
|
||||
this.fileName = fileName;
|
||||
}
|
||||
public String getFileNameServer() {
|
||||
return fileNameServer;
|
||||
}
|
||||
public void setFileNameServer(String fileNameServer) {
|
||||
this.fileNameServer = fileNameServer;
|
||||
}
|
||||
public String getFileType() {
|
||||
return fileType;
|
||||
}
|
||||
public void setFileType(String fileType) {
|
||||
this.fileType = fileType;
|
||||
}
|
||||
public Float getFileLen() {
|
||||
return fileLen;
|
||||
}
|
||||
public void setFileLen(Float fileLen) {
|
||||
this.fileLen = fileLen;
|
||||
}
|
||||
public String getFilePath() {
|
||||
return filePath;
|
||||
}
|
||||
public void setFilePath(String filePath) {
|
||||
this.filePath = filePath;
|
||||
}
|
||||
public String getOpenType() {
|
||||
return openType;
|
||||
}
|
||||
public void setOpenType(String openType) {
|
||||
this.openType = openType;
|
||||
}
|
||||
public Integer getPageNo() {
|
||||
return pageNo;
|
||||
}
|
||||
public void setPageNo(Integer pageNo) {
|
||||
this.pageNo = pageNo;
|
||||
}
|
||||
public String getVersion() {
|
||||
return version;
|
||||
}
|
||||
public void setVersion(String version) {
|
||||
this.version = version;
|
||||
}
|
||||
public String getAuthorName() {
|
||||
return authorName;
|
||||
}
|
||||
public void setAuthorName(String authorName) {
|
||||
this.authorName = authorName;
|
||||
}
|
||||
public String getFileRemark() {
|
||||
return fileRemark;
|
||||
}
|
||||
public void setFileRemark(String fileRemark) {
|
||||
this.fileRemark = fileRemark;
|
||||
}
|
||||
public String getFileDes() {
|
||||
return fileDes;
|
||||
}
|
||||
public void setFileDes(String fileDes) {
|
||||
this.fileDes = fileDes;
|
||||
}
|
||||
public Integer getDowns() {
|
||||
return downs;
|
||||
}
|
||||
public void setDowns(Integer downs) {
|
||||
this.downs = downs;
|
||||
}
|
||||
public Integer getVeiws() {
|
||||
return veiws;
|
||||
}
|
||||
public void setVeiws(Integer veiws) {
|
||||
this.veiws = veiws;
|
||||
}
|
||||
public String getMetadataValue() {
|
||||
return metadataValue;
|
||||
}
|
||||
public void setMetadataValue(String metadataValue) {
|
||||
this.metadataValue = metadataValue;
|
||||
}
|
||||
public Integer getMetadataType() {
|
||||
return metadataType;
|
||||
}
|
||||
public void setMetadataType(Integer metadataType) {
|
||||
this.metadataType = metadataType;
|
||||
}
|
||||
public Integer getOcrCheck() {
|
||||
return ocrCheck;
|
||||
}
|
||||
public void setOcrCheck(Integer ocrCheck) {
|
||||
this.ocrCheck = ocrCheck;
|
||||
}
|
||||
public Integer getFileStatus() {
|
||||
return fileStatus;
|
||||
}
|
||||
public void setFileStatus(Integer fileStatus) {
|
||||
this.fileStatus = fileStatus;
|
||||
}
|
||||
public Integer getFileAttr() {
|
||||
return fileAttr;
|
||||
}
|
||||
public void setFileAttr(Integer fileAttr) {
|
||||
this.fileAttr = fileAttr;
|
||||
}
|
||||
public String getMd5Code() {
|
||||
return md5Code;
|
||||
}
|
||||
|
||||
public String getDividedContent() {
|
||||
return dividedContent;
|
||||
}
|
||||
|
||||
public void setDividedContent(String dividedContent) {
|
||||
this.dividedContent = dividedContent;
|
||||
}
|
||||
|
||||
public void setMd5Code(String md5Code) {
|
||||
this.md5Code = md5Code;
|
||||
}
|
||||
public String getMd5CheckDate() {
|
||||
return md5CheckDate;
|
||||
}
|
||||
public void setMd5CheckDate(String md5CheckDate) {
|
||||
this.md5CheckDate = md5CheckDate;
|
||||
}
|
||||
public String getDataContent() {
|
||||
return dataContent;
|
||||
}
|
||||
public void setDataContent(String dataContent) {
|
||||
this.dataContent = dataContent;
|
||||
}
|
||||
public String getFileContent() {
|
||||
return fileContent;
|
||||
}
|
||||
public void setFileContent(String fileContent) {
|
||||
this.fileContent = fileContent;
|
||||
}
|
||||
public Integer getIsDivided() {
|
||||
return isDivided;
|
||||
}
|
||||
public void setIsDivided(Integer isDivided) {
|
||||
this.isDivided = isDivided;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,512 @@
|
||||
package com.point.strategy.oaDocking.bean;
|
||||
|
||||
import com.point.strategy.common.PageBean;
|
||||
|
||||
import java.io.Serializable;
|
||||
/**
|
||||
* 文书简化实体
|
||||
*/
|
||||
public class DocSimpleArrangeOa extends PageBean implements Serializable {
|
||||
private Integer id = 0;
|
||||
private String caseNo;
|
||||
private String mlh;
|
||||
private String archiveNo;
|
||||
private String note ;
|
||||
private String pigeonholeDate;
|
||||
private String archiveCtgNo;
|
||||
private String archiveCtgNoCode;
|
||||
private String retention;
|
||||
private String retentionCode;
|
||||
private Integer filingYear = 0 ;
|
||||
private String fondsNo;
|
||||
private String fondsNoCode;
|
||||
private String sbtWord;
|
||||
private String docNo;
|
||||
private String dagdm;
|
||||
private String dagdmCode;
|
||||
private String createdDate;
|
||||
private Integer objectQuantity = 0;
|
||||
private String securityClass;
|
||||
private String securityClassCode;
|
||||
private Integer quantity = 0;
|
||||
private Integer pieceNo = 0;
|
||||
private String kzbs;
|
||||
private String kzbsCode;
|
||||
private String folderLocation;
|
||||
private String damldm;
|
||||
private String damldmCode;
|
||||
private String maintitle;
|
||||
private String responsibleby;
|
||||
private String createPerson;
|
||||
private String createDate;
|
||||
private String isPackeep;
|
||||
private String isPackeepCode;
|
||||
private String md5Code;
|
||||
private String md5CheckDate;
|
||||
private String batchId;
|
||||
private String batchName;
|
||||
private String backToUpdateState;
|
||||
private Integer isProcess = 0;
|
||||
private String testtestCode;
|
||||
private Integer archiveFileNum = 0;
|
||||
private String departname;
|
||||
private String departnameCode;
|
||||
private String lb;
|
||||
private String lbCode;
|
||||
private String lm;
|
||||
private String lmCode;
|
||||
private String archiveFlag;
|
||||
//主题词
|
||||
private String keyWords;
|
||||
//目录号
|
||||
private String catalogNumber;
|
||||
//案件级档号
|
||||
private String folderNo;
|
||||
//案卷号
|
||||
private String fileNumber;
|
||||
//文件开始时间
|
||||
private String fileStartTime;
|
||||
//文件结束时间
|
||||
private String fileEndTime;
|
||||
|
||||
public String getFolderNo() {
|
||||
return folderNo;
|
||||
}
|
||||
|
||||
public void setFolderNo(String folderNo) {
|
||||
this.folderNo = folderNo;
|
||||
}
|
||||
|
||||
public String getFileNumber() {
|
||||
return fileNumber;
|
||||
}
|
||||
|
||||
public void setFileNumber(String fileNumber) {
|
||||
this.fileNumber = fileNumber;
|
||||
}
|
||||
|
||||
public String getFileStartTime() {
|
||||
return fileStartTime;
|
||||
}
|
||||
|
||||
public void setFileStartTime(String fileStartTime) {
|
||||
this.fileStartTime = fileStartTime;
|
||||
}
|
||||
|
||||
public String getFileEndTime() {
|
||||
return fileEndTime;
|
||||
}
|
||||
|
||||
public void setFileEndTime(String fileEndTime) {
|
||||
this.fileEndTime = fileEndTime;
|
||||
}
|
||||
|
||||
public String getKeyWords() {
|
||||
return keyWords;
|
||||
}
|
||||
|
||||
public void setKeyWords(String keyWords) {
|
||||
this.keyWords = keyWords;
|
||||
}
|
||||
|
||||
public String getCatalogNumber() {
|
||||
return catalogNumber;
|
||||
}
|
||||
|
||||
public void setCatalogNumber(String catalogNumber) {
|
||||
this.catalogNumber = catalogNumber;
|
||||
}
|
||||
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getCaseNo() {
|
||||
return caseNo;
|
||||
}
|
||||
|
||||
public void setCaseNo(String caseNo) {
|
||||
this.caseNo = caseNo;
|
||||
}
|
||||
|
||||
public String getMlh() {
|
||||
return mlh;
|
||||
}
|
||||
|
||||
public void setMlh(String mlh) {
|
||||
this.mlh = mlh;
|
||||
}
|
||||
|
||||
public String getArchiveNo() {
|
||||
return archiveNo;
|
||||
}
|
||||
|
||||
public void setArchiveNo(String archiveNo) {
|
||||
this.archiveNo = archiveNo;
|
||||
}
|
||||
|
||||
public String getNote() {
|
||||
return note;
|
||||
}
|
||||
|
||||
public void setNote(String note) {
|
||||
this.note = note;
|
||||
}
|
||||
|
||||
public String getPigeonholeDate() {
|
||||
return pigeonholeDate;
|
||||
}
|
||||
|
||||
public void setPigeonholeDate(String pigeonholeDate) {
|
||||
this.pigeonholeDate = pigeonholeDate;
|
||||
}
|
||||
|
||||
public String getArchiveCtgNo() {
|
||||
return archiveCtgNo;
|
||||
}
|
||||
|
||||
public void setArchiveCtgNo(String archiveCtgNo) {
|
||||
this.archiveCtgNo = archiveCtgNo;
|
||||
}
|
||||
|
||||
public String getArchiveCtgNoCode() {
|
||||
return archiveCtgNoCode;
|
||||
}
|
||||
|
||||
public void setArchiveCtgNoCode(String archiveCtgNoCode) {
|
||||
this.archiveCtgNoCode = archiveCtgNoCode;
|
||||
}
|
||||
|
||||
public String getRetention() {
|
||||
return retention;
|
||||
}
|
||||
|
||||
public void setRetention(String retention) {
|
||||
this.retention = retention;
|
||||
}
|
||||
|
||||
public String getRetentionCode() {
|
||||
return retentionCode;
|
||||
}
|
||||
|
||||
public void setRetentionCode(String retentionCode) {
|
||||
this.retentionCode = retentionCode;
|
||||
}
|
||||
|
||||
public Integer getFilingYear() {
|
||||
return filingYear;
|
||||
}
|
||||
|
||||
public void setFilingYear(Integer filingYear) {
|
||||
this.filingYear = filingYear;
|
||||
}
|
||||
|
||||
public String getFondsNo() {
|
||||
return fondsNo;
|
||||
}
|
||||
|
||||
public void setFondsNo(String fondsNo) {
|
||||
this.fondsNo = fondsNo;
|
||||
}
|
||||
|
||||
public String getFondsNoCode() {
|
||||
return fondsNoCode;
|
||||
}
|
||||
|
||||
public void setFondsNoCode(String fondsNoCode) {
|
||||
this.fondsNoCode = fondsNoCode;
|
||||
}
|
||||
|
||||
public String getSbtWord() {
|
||||
return sbtWord;
|
||||
}
|
||||
|
||||
public void setSbtWord(String sbtWord) {
|
||||
this.sbtWord = sbtWord;
|
||||
}
|
||||
|
||||
public String getDocNo() {
|
||||
return docNo;
|
||||
}
|
||||
|
||||
public void setDocNo(String docNo) {
|
||||
this.docNo = docNo;
|
||||
}
|
||||
|
||||
public String getDagdm() {
|
||||
return dagdm;
|
||||
}
|
||||
|
||||
public void setDagdm(String dagdm) {
|
||||
this.dagdm = dagdm;
|
||||
}
|
||||
|
||||
public String getDagdmCode() {
|
||||
return dagdmCode;
|
||||
}
|
||||
|
||||
public void setDagdmCode(String dagdmCode) {
|
||||
this.dagdmCode = dagdmCode;
|
||||
}
|
||||
|
||||
public String getCreatedDate() {
|
||||
return createdDate;
|
||||
}
|
||||
|
||||
public void setCreatedDate(String createdDate) {
|
||||
this.createdDate = createdDate;
|
||||
}
|
||||
|
||||
public Integer getObjectQuantity() {
|
||||
return objectQuantity;
|
||||
}
|
||||
|
||||
public void setObjectQuantity(Integer objectQuantity) {
|
||||
this.objectQuantity = objectQuantity;
|
||||
}
|
||||
|
||||
public String getSecurityClass() {
|
||||
return securityClass;
|
||||
}
|
||||
|
||||
public void setSecurityClass(String securityClass) {
|
||||
this.securityClass = securityClass;
|
||||
}
|
||||
|
||||
public String getSecurityClassCode() {
|
||||
return securityClassCode;
|
||||
}
|
||||
|
||||
public void setSecurityClassCode(String securityClassCode) {
|
||||
this.securityClassCode = securityClassCode;
|
||||
}
|
||||
|
||||
public Integer getQuantity() {
|
||||
return quantity;
|
||||
}
|
||||
|
||||
public void setQuantity(Integer quantity) {
|
||||
this.quantity = quantity;
|
||||
}
|
||||
|
||||
public Integer getPieceNo() {
|
||||
return pieceNo;
|
||||
}
|
||||
|
||||
public void setPieceNo(Integer pieceNo) {
|
||||
this.pieceNo = pieceNo;
|
||||
}
|
||||
|
||||
public String getKzbs() {
|
||||
return kzbs;
|
||||
}
|
||||
|
||||
public void setKzbs(String kzbs) {
|
||||
this.kzbs = kzbs;
|
||||
}
|
||||
|
||||
public String getKzbsCode() {
|
||||
return kzbsCode;
|
||||
}
|
||||
|
||||
public void setKzbsCode(String kzbsCode) {
|
||||
this.kzbsCode = kzbsCode;
|
||||
}
|
||||
|
||||
public String getFolderLocation() {
|
||||
return folderLocation;
|
||||
}
|
||||
|
||||
public void setFolderLocation(String folderLocation) {
|
||||
this.folderLocation = folderLocation;
|
||||
}
|
||||
|
||||
public String getDamldm() {
|
||||
return damldm;
|
||||
}
|
||||
|
||||
public void setDamldm(String damldm) {
|
||||
this.damldm = damldm;
|
||||
}
|
||||
|
||||
public String getDamldmCode() {
|
||||
return damldmCode;
|
||||
}
|
||||
|
||||
public void setDamldmCode(String damldmCode) {
|
||||
this.damldmCode = damldmCode;
|
||||
}
|
||||
|
||||
public String getMaintitle() {
|
||||
return maintitle;
|
||||
}
|
||||
|
||||
public void setMaintitle(String maintitle) {
|
||||
this.maintitle = maintitle;
|
||||
}
|
||||
|
||||
public String getResponsibleby() {
|
||||
return responsibleby;
|
||||
}
|
||||
|
||||
public void setResponsibleby(String responsibleby) {
|
||||
this.responsibleby = responsibleby;
|
||||
}
|
||||
|
||||
public String getCreatePerson() {
|
||||
return createPerson;
|
||||
}
|
||||
|
||||
public void setCreatePerson(String createPerson) {
|
||||
this.createPerson = createPerson;
|
||||
}
|
||||
|
||||
public String getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
||||
public void setCreateDate(String createDate) {
|
||||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
public String getIsPackeep() {
|
||||
return isPackeep;
|
||||
}
|
||||
|
||||
public void setIsPackeep(String isPackeep) {
|
||||
this.isPackeep = isPackeep;
|
||||
}
|
||||
|
||||
public String getIsPackeepCode() {
|
||||
return isPackeepCode;
|
||||
}
|
||||
|
||||
public void setIsPackeepCode(String isPackeepCode) {
|
||||
this.isPackeepCode = isPackeepCode;
|
||||
}
|
||||
|
||||
public String getMd5Code() {
|
||||
return md5Code;
|
||||
}
|
||||
|
||||
public void setMd5Code(String md5Code) {
|
||||
this.md5Code = md5Code;
|
||||
}
|
||||
|
||||
public String getMd5CheckDate() {
|
||||
return md5CheckDate;
|
||||
}
|
||||
|
||||
public void setMd5CheckDate(String md5CheckDate) {
|
||||
this.md5CheckDate = md5CheckDate;
|
||||
}
|
||||
|
||||
public String getBatchId() {
|
||||
return batchId;
|
||||
}
|
||||
|
||||
public void setBatchId(String batchId) {
|
||||
this.batchId = batchId;
|
||||
}
|
||||
|
||||
public String getBatchName() {
|
||||
return batchName;
|
||||
}
|
||||
|
||||
public void setBatchName(String batchName) {
|
||||
this.batchName = batchName;
|
||||
}
|
||||
|
||||
public String getBackToUpdateState() {
|
||||
return backToUpdateState;
|
||||
}
|
||||
|
||||
public void setBackToUpdateState(String backToUpdateState) {
|
||||
this.backToUpdateState = backToUpdateState;
|
||||
}
|
||||
|
||||
public Integer getIsProcess() {
|
||||
return isProcess;
|
||||
}
|
||||
|
||||
public void setIsProcess(Integer isProcess) {
|
||||
this.isProcess = isProcess;
|
||||
}
|
||||
|
||||
public String getTesttestCode() {
|
||||
return testtestCode;
|
||||
}
|
||||
|
||||
public void setTesttestCode(String testtestCode) {
|
||||
this.testtestCode = testtestCode;
|
||||
}
|
||||
|
||||
public Integer getArchiveFileNum() {
|
||||
return archiveFileNum;
|
||||
}
|
||||
|
||||
public void setArchiveFileNum(Integer archiveFileNum) {
|
||||
this.archiveFileNum = archiveFileNum;
|
||||
}
|
||||
|
||||
public String getDepartname() {
|
||||
return departname;
|
||||
}
|
||||
|
||||
public void setDepartname(String departname) {
|
||||
this.departname = departname;
|
||||
}
|
||||
|
||||
public String getDepartnameCode() {
|
||||
return departnameCode;
|
||||
}
|
||||
|
||||
public void setDepartnameCode(String departnameCode) {
|
||||
this.departnameCode = departnameCode;
|
||||
}
|
||||
|
||||
public String getLb() {
|
||||
return lb;
|
||||
}
|
||||
|
||||
public void setLb(String lb) {
|
||||
this.lb = lb;
|
||||
}
|
||||
|
||||
public String getLbCode() {
|
||||
return lbCode;
|
||||
}
|
||||
|
||||
public void setLbCode(String lbCode) {
|
||||
this.lbCode = lbCode;
|
||||
}
|
||||
|
||||
public String getLm() {
|
||||
return lm;
|
||||
}
|
||||
|
||||
public void setLm(String lm) {
|
||||
this.lm = lm;
|
||||
}
|
||||
|
||||
public String getLmCode() {
|
||||
return lmCode;
|
||||
}
|
||||
|
||||
public void setLmCode(String lmCode) {
|
||||
this.lmCode = lmCode;
|
||||
}
|
||||
|
||||
public String getArchiveFlag() {
|
||||
return archiveFlag;
|
||||
}
|
||||
|
||||
public void setArchiveFlag(String archiveFlag) {
|
||||
this.archiveFlag = archiveFlag;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,458 @@
|
||||
package com.point.strategy.oaDocking.bean;
|
||||
|
||||
import com.point.strategy.common.PageBean;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 文书案卷传统实体
|
||||
*/
|
||||
public class DocTraditionArrangeFileOa extends PageBean implements Serializable {
|
||||
private Integer id = 0;
|
||||
private Integer archiveFileNum = 0;
|
||||
private String folderNo;
|
||||
private Integer js = 0;
|
||||
private String folderLocation;
|
||||
private String maintitle;
|
||||
private String securityClass;
|
||||
private String securityClassCode;
|
||||
private String fondsNo;
|
||||
private String fondsNoCode;
|
||||
private Integer filingYear;
|
||||
private String retention;
|
||||
private String retentionCode;
|
||||
private String archiveCtgNo;
|
||||
private String archiveCtgNoCode;
|
||||
private String yearFolderNo;
|
||||
private Integer quantity = 0;
|
||||
private String docStartTime;
|
||||
private String docEndTime;
|
||||
private String sbtWord;
|
||||
private String pigeonholeDate;
|
||||
private String note;
|
||||
private String mlh;
|
||||
private String sssq;
|
||||
private String sssqCode;
|
||||
private String dagdm;
|
||||
private String dagdmCode;
|
||||
private String zqbs;
|
||||
private String zqbsCode;
|
||||
private String kzbs;
|
||||
private String kzbsCode;
|
||||
private String damldm;
|
||||
private String damldmCode;
|
||||
private String createPerson;
|
||||
private String createDate;
|
||||
private String archiveFlag;
|
||||
private String isPackeep;
|
||||
private String isPackeepCode;
|
||||
private String md5Code;
|
||||
private String md5CheckDate;
|
||||
private String batchId;
|
||||
private String batchName;
|
||||
private String backToUpdateState;
|
||||
private Integer isProcess = 0;
|
||||
private String archiveEntityStatus;
|
||||
|
||||
//部门编码
|
||||
private String departnameCode;
|
||||
//部门名称
|
||||
private String departname;
|
||||
|
||||
private Integer fileStatus;
|
||||
|
||||
private List<String> idsList;
|
||||
|
||||
public String getDepartnameCode() {
|
||||
return departnameCode;
|
||||
}
|
||||
|
||||
public void setDepartnameCode(String departnameCode) {
|
||||
this.departnameCode = departnameCode;
|
||||
}
|
||||
|
||||
public String getDepartname() {
|
||||
return departname;
|
||||
}
|
||||
|
||||
public void setDepartname(String departname) {
|
||||
this.departname = departname;
|
||||
}
|
||||
|
||||
public Integer getFileStatus() {
|
||||
return fileStatus;
|
||||
}
|
||||
|
||||
public void setFileStatus(Integer fileStatus) {
|
||||
this.fileStatus = fileStatus;
|
||||
}
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Integer getArchiveFileNum() {
|
||||
return archiveFileNum;
|
||||
}
|
||||
|
||||
public void setArchiveFileNum(Integer archiveFileNum) {
|
||||
this.archiveFileNum = archiveFileNum;
|
||||
}
|
||||
|
||||
public String getFolderNo() {
|
||||
return folderNo;
|
||||
}
|
||||
|
||||
public void setFolderNo(String folderNo) {
|
||||
this.folderNo = folderNo;
|
||||
}
|
||||
|
||||
public Integer getJs() {
|
||||
return js;
|
||||
}
|
||||
|
||||
public void setJs(Integer js) {
|
||||
this.js = js;
|
||||
}
|
||||
|
||||
public String getFolderLocation() {
|
||||
return folderLocation;
|
||||
}
|
||||
|
||||
public void setFolderLocation(String folderLocation) {
|
||||
this.folderLocation = folderLocation;
|
||||
}
|
||||
|
||||
public String getMaintitle() {
|
||||
return maintitle;
|
||||
}
|
||||
|
||||
public void setMaintitle(String maintitle) {
|
||||
this.maintitle = maintitle;
|
||||
}
|
||||
|
||||
public String getSecurityClass() {
|
||||
return securityClass;
|
||||
}
|
||||
|
||||
public void setSecurityClass(String securityClass) {
|
||||
this.securityClass = securityClass;
|
||||
}
|
||||
|
||||
public String getSecurityClassCode() {
|
||||
return securityClassCode;
|
||||
}
|
||||
|
||||
public void setSecurityClassCode(String securityClassCode) {
|
||||
this.securityClassCode = securityClassCode;
|
||||
}
|
||||
|
||||
public String getFondsNo() {
|
||||
return fondsNo;
|
||||
}
|
||||
|
||||
public void setFondsNo(String fondsNo) {
|
||||
this.fondsNo = fondsNo;
|
||||
}
|
||||
|
||||
public String getFondsNoCode() {
|
||||
return fondsNoCode;
|
||||
}
|
||||
|
||||
public void setFondsNoCode(String fondsNoCode) {
|
||||
this.fondsNoCode = fondsNoCode;
|
||||
}
|
||||
|
||||
public Integer getFilingYear() {
|
||||
return filingYear;
|
||||
}
|
||||
|
||||
public void setFilingYear(Integer filingYear) {
|
||||
this.filingYear = filingYear;
|
||||
}
|
||||
|
||||
public String getRetention() {
|
||||
return retention;
|
||||
}
|
||||
|
||||
public void setRetention(String retention) {
|
||||
this.retention = retention;
|
||||
}
|
||||
|
||||
public String getRetentionCode() {
|
||||
return retentionCode;
|
||||
}
|
||||
|
||||
public void setRetentionCode(String retentionCode) {
|
||||
this.retentionCode = retentionCode;
|
||||
}
|
||||
|
||||
public String getArchiveCtgNo() {
|
||||
return archiveCtgNo;
|
||||
}
|
||||
|
||||
public void setArchiveCtgNo(String archiveCtgNo) {
|
||||
this.archiveCtgNo = archiveCtgNo;
|
||||
}
|
||||
|
||||
public String getArchiveCtgNoCode() {
|
||||
return archiveCtgNoCode;
|
||||
}
|
||||
|
||||
public void setArchiveCtgNoCode(String archiveCtgNoCode) {
|
||||
this.archiveCtgNoCode = archiveCtgNoCode;
|
||||
}
|
||||
|
||||
public String getYearFolderNo() {
|
||||
return yearFolderNo;
|
||||
}
|
||||
|
||||
public void setYearFolderNo(String yearFolderNo) {
|
||||
this.yearFolderNo = yearFolderNo;
|
||||
}
|
||||
|
||||
public Integer getQuantity() {
|
||||
return quantity;
|
||||
}
|
||||
|
||||
public void setQuantity(Integer quantity) {
|
||||
this.quantity = quantity;
|
||||
}
|
||||
|
||||
public String getDocStartTime() {
|
||||
return docStartTime;
|
||||
}
|
||||
|
||||
public void setDocStartTime(String docStartTime) {
|
||||
this.docStartTime = docStartTime;
|
||||
}
|
||||
|
||||
public String getDocEndTime() {
|
||||
return docEndTime;
|
||||
}
|
||||
|
||||
public void setDocEndTime(String docEndTime) {
|
||||
this.docEndTime = docEndTime;
|
||||
}
|
||||
|
||||
public String getSbtWord() {
|
||||
return sbtWord;
|
||||
}
|
||||
|
||||
public void setSbtWord(String sbtWord) {
|
||||
this.sbtWord = sbtWord;
|
||||
}
|
||||
|
||||
public String getPigeonholeDate() {
|
||||
return pigeonholeDate;
|
||||
}
|
||||
|
||||
public void setPigeonholeDate(String pigeonholeDate) {
|
||||
this.pigeonholeDate = pigeonholeDate;
|
||||
}
|
||||
|
||||
public String getNote() {
|
||||
return note;
|
||||
}
|
||||
|
||||
public void setNote(String note) {
|
||||
this.note = note;
|
||||
}
|
||||
|
||||
public String getMlh() {
|
||||
return mlh;
|
||||
}
|
||||
|
||||
public void setMlh(String mlh) {
|
||||
this.mlh = mlh;
|
||||
}
|
||||
|
||||
public String getSssq() {
|
||||
return sssq;
|
||||
}
|
||||
|
||||
public void setSssq(String sssq) {
|
||||
this.sssq = sssq;
|
||||
}
|
||||
|
||||
public String getSssqCode() {
|
||||
return sssqCode;
|
||||
}
|
||||
|
||||
public void setSssqCode(String sssqCode) {
|
||||
this.sssqCode = sssqCode;
|
||||
}
|
||||
|
||||
public String getDagdm() {
|
||||
return dagdm;
|
||||
}
|
||||
|
||||
public void setDagdm(String dagdm) {
|
||||
this.dagdm = dagdm;
|
||||
}
|
||||
|
||||
public String getDagdmCode() {
|
||||
return dagdmCode;
|
||||
}
|
||||
|
||||
public void setDagdmCode(String dagdmCode) {
|
||||
this.dagdmCode = dagdmCode;
|
||||
}
|
||||
|
||||
public String getZqbs() {
|
||||
return zqbs;
|
||||
}
|
||||
|
||||
public void setZqbs(String zqbs) {
|
||||
this.zqbs = zqbs;
|
||||
}
|
||||
|
||||
public String getZqbsCode() {
|
||||
return zqbsCode;
|
||||
}
|
||||
|
||||
public void setZqbsCode(String zqbsCode) {
|
||||
this.zqbsCode = zqbsCode;
|
||||
}
|
||||
|
||||
public String getKzbs() {
|
||||
return kzbs;
|
||||
}
|
||||
|
||||
public void setKzbs(String kzbs) {
|
||||
this.kzbs = kzbs;
|
||||
}
|
||||
|
||||
public String getKzbsCode() {
|
||||
return kzbsCode;
|
||||
}
|
||||
|
||||
public void setKzbsCode(String kzbsCode) {
|
||||
this.kzbsCode = kzbsCode;
|
||||
}
|
||||
|
||||
public String getDamldm() {
|
||||
return damldm;
|
||||
}
|
||||
|
||||
public void setDamldm(String damldm) {
|
||||
this.damldm = damldm;
|
||||
}
|
||||
|
||||
public String getDamldmCode() {
|
||||
return damldmCode;
|
||||
}
|
||||
|
||||
public void setDamldmCode(String damldmCode) {
|
||||
this.damldmCode = damldmCode;
|
||||
}
|
||||
|
||||
public String getCreatePerson() {
|
||||
return createPerson;
|
||||
}
|
||||
|
||||
public void setCreatePerson(String createPerson) {
|
||||
this.createPerson = createPerson;
|
||||
}
|
||||
|
||||
public String getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
||||
public void setCreateDate(String createDate) {
|
||||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
public String getArchiveFlag() {
|
||||
return archiveFlag;
|
||||
}
|
||||
|
||||
public void setArchiveFlag(String archiveFlag) {
|
||||
this.archiveFlag = archiveFlag;
|
||||
}
|
||||
|
||||
public String getIsPackeep() {
|
||||
return isPackeep;
|
||||
}
|
||||
|
||||
public void setIsPackeep(String isPackeep) {
|
||||
this.isPackeep = isPackeep;
|
||||
}
|
||||
|
||||
public String getIsPackeepCode() {
|
||||
return isPackeepCode;
|
||||
}
|
||||
|
||||
public void setIsPackeepCode(String isPackeepCode) {
|
||||
this.isPackeepCode = isPackeepCode;
|
||||
}
|
||||
|
||||
public String getMd5Code() {
|
||||
return md5Code;
|
||||
}
|
||||
|
||||
public void setMd5Code(String md5Code) {
|
||||
this.md5Code = md5Code;
|
||||
}
|
||||
|
||||
public String getMd5CheckDate() {
|
||||
return md5CheckDate;
|
||||
}
|
||||
|
||||
public void setMd5CheckDate(String md5CheckDate) {
|
||||
this.md5CheckDate = md5CheckDate;
|
||||
}
|
||||
|
||||
public String getBatchId() {
|
||||
return batchId;
|
||||
}
|
||||
|
||||
public void setBatchId(String batchId) {
|
||||
this.batchId = batchId;
|
||||
}
|
||||
|
||||
public String getBatchName() {
|
||||
return batchName;
|
||||
}
|
||||
|
||||
public void setBatchName(String batchName) {
|
||||
this.batchName = batchName;
|
||||
}
|
||||
|
||||
public String getBackToUpdateState() {
|
||||
return backToUpdateState;
|
||||
}
|
||||
|
||||
public void setBackToUpdateState(String backToUpdateState) {
|
||||
this.backToUpdateState = backToUpdateState;
|
||||
}
|
||||
|
||||
public Integer getIsProcess() {
|
||||
return isProcess;
|
||||
}
|
||||
|
||||
public void setIsProcess(Integer isProcess) {
|
||||
this.isProcess = isProcess;
|
||||
}
|
||||
|
||||
public String getArchiveEntityStatus() {
|
||||
return archiveEntityStatus;
|
||||
}
|
||||
|
||||
public void setArchiveEntityStatus(String archiveEntityStatus) {
|
||||
this.archiveEntityStatus = archiveEntityStatus;
|
||||
}
|
||||
|
||||
public List<String> getIdsList() {
|
||||
return idsList;
|
||||
}
|
||||
|
||||
public void setIdsList(List<String> idsList) {
|
||||
this.idsList = idsList;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,537 @@
|
||||
package com.point.strategy.oaDocking.bean;
|
||||
|
||||
import com.point.strategy.common.PageBean;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
//文书卷内传统实体
|
||||
public class DocTraditionArrangeOaVolume extends PageBean implements Serializable {
|
||||
private Integer id = 0;
|
||||
private Integer archiveFileNum = 0;
|
||||
private String archiveNo;
|
||||
private String folderNo;
|
||||
private String maintitle;
|
||||
private String createdDate;
|
||||
private String docNo;
|
||||
private String securityClass;
|
||||
private String securityClassCode;
|
||||
private String fondsNo;
|
||||
private String fondsNoCode;
|
||||
private String retention;
|
||||
private String retentionCode;
|
||||
private Integer filingYear = 0 ;
|
||||
private String archiveCtgNo;
|
||||
private String archiveCtgNoCode;
|
||||
private String yearFolderNo;
|
||||
private Integer pageNo = 0;
|
||||
private Integer pieceNo = 0;
|
||||
private Integer quantity = 0;
|
||||
private String responsibleby;
|
||||
private String sbtWord;
|
||||
private String folderLocation;
|
||||
private String pigeonholeDate;
|
||||
private String note;
|
||||
private Integer objectQuantity = 0;
|
||||
private String pageNoEnd;
|
||||
private String mlh;
|
||||
private String sssq;
|
||||
private String sssqCode;
|
||||
private String dagdm;
|
||||
private String dagdmCode;
|
||||
private String zqbs;
|
||||
private String zqbsCode;
|
||||
private String kzbs;
|
||||
private String kzbsCode;
|
||||
private String damldm;
|
||||
private String damldmCode;
|
||||
private String reportPage;
|
||||
private String pid;
|
||||
private String createPerson;
|
||||
private String createDate;
|
||||
private String archiveFlag;
|
||||
private String isPackeep;
|
||||
private String isPackeepCode;
|
||||
private String md5Code;
|
||||
private String md5CheckDate;
|
||||
private String batchId;
|
||||
private String batchName;
|
||||
private String backToUpdateState;
|
||||
private Integer isProcess = 0;
|
||||
private String archiveEntityStatus;
|
||||
private String archiveZjbs;
|
||||
private String tempNo;
|
||||
|
||||
//部门编码
|
||||
private String departnameCode;
|
||||
//部门名称
|
||||
private String departname;
|
||||
|
||||
private Integer fileStatus;
|
||||
|
||||
private List<String> idsList;
|
||||
|
||||
public String getDepartnameCode() {
|
||||
return departnameCode;
|
||||
}
|
||||
|
||||
public void setDepartnameCode(String departnameCode) {
|
||||
this.departnameCode = departnameCode;
|
||||
}
|
||||
|
||||
public String getDepartname() {
|
||||
return departname;
|
||||
}
|
||||
|
||||
public void setDepartname(String departname) {
|
||||
this.departname = departname;
|
||||
}
|
||||
|
||||
public Integer getFileStatus() {
|
||||
return fileStatus;
|
||||
}
|
||||
|
||||
public void setFileStatus(Integer fileStatus) {
|
||||
this.fileStatus = fileStatus;
|
||||
}
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Integer getArchiveFileNum() {
|
||||
return archiveFileNum;
|
||||
}
|
||||
|
||||
public void setArchiveFileNum(Integer archiveFileNum) {
|
||||
this.archiveFileNum = archiveFileNum;
|
||||
}
|
||||
|
||||
public String getFolderNo() {
|
||||
return folderNo;
|
||||
}
|
||||
|
||||
public void setFolderNo(String folderNo) {
|
||||
this.folderNo = folderNo;
|
||||
}
|
||||
|
||||
public String getFolderLocation() {
|
||||
return folderLocation;
|
||||
}
|
||||
|
||||
public void setFolderLocation(String folderLocation) {
|
||||
this.folderLocation = folderLocation;
|
||||
}
|
||||
|
||||
public String getMaintitle() {
|
||||
return maintitle;
|
||||
}
|
||||
|
||||
public void setMaintitle(String maintitle) {
|
||||
this.maintitle = maintitle;
|
||||
}
|
||||
|
||||
public String getSecurityClass() {
|
||||
return securityClass;
|
||||
}
|
||||
|
||||
public void setSecurityClass(String securityClass) {
|
||||
this.securityClass = securityClass;
|
||||
}
|
||||
|
||||
public String getSecurityClassCode() {
|
||||
return securityClassCode;
|
||||
}
|
||||
|
||||
public void setSecurityClassCode(String securityClassCode) {
|
||||
this.securityClassCode = securityClassCode;
|
||||
}
|
||||
|
||||
public String getFondsNo() {
|
||||
return fondsNo;
|
||||
}
|
||||
|
||||
public void setFondsNo(String fondsNo) {
|
||||
this.fondsNo = fondsNo;
|
||||
}
|
||||
|
||||
public String getFondsNoCode() {
|
||||
return fondsNoCode;
|
||||
}
|
||||
|
||||
public void setFondsNoCode(String fondsNoCode) {
|
||||
this.fondsNoCode = fondsNoCode;
|
||||
}
|
||||
|
||||
public Integer getFilingYear() {
|
||||
return filingYear;
|
||||
}
|
||||
|
||||
public void setFilingYear(Integer filingYear) {
|
||||
this.filingYear = filingYear;
|
||||
}
|
||||
|
||||
public String getRetention() {
|
||||
return retention;
|
||||
}
|
||||
|
||||
public void setRetention(String retention) {
|
||||
this.retention = retention;
|
||||
}
|
||||
|
||||
public String getRetentionCode() {
|
||||
return retentionCode;
|
||||
}
|
||||
|
||||
public void setRetentionCode(String retentionCode) {
|
||||
this.retentionCode = retentionCode;
|
||||
}
|
||||
|
||||
public String getArchiveCtgNo() {
|
||||
return archiveCtgNo;
|
||||
}
|
||||
|
||||
public void setArchiveCtgNo(String archiveCtgNo) {
|
||||
this.archiveCtgNo = archiveCtgNo;
|
||||
}
|
||||
|
||||
public String getArchiveCtgNoCode() {
|
||||
return archiveCtgNoCode;
|
||||
}
|
||||
|
||||
public void setArchiveCtgNoCode(String archiveCtgNoCode) {
|
||||
this.archiveCtgNoCode = archiveCtgNoCode;
|
||||
}
|
||||
|
||||
public String getYearFolderNo() {
|
||||
return yearFolderNo;
|
||||
}
|
||||
|
||||
public void setYearFolderNo(String yearFolderNo) {
|
||||
this.yearFolderNo = yearFolderNo;
|
||||
}
|
||||
|
||||
public Integer getQuantity() {
|
||||
return quantity;
|
||||
}
|
||||
|
||||
public void setQuantity(Integer quantity) {
|
||||
this.quantity = quantity;
|
||||
}
|
||||
|
||||
public String getSbtWord() {
|
||||
return sbtWord;
|
||||
}
|
||||
|
||||
public void setSbtWord(String sbtWord) {
|
||||
this.sbtWord = sbtWord;
|
||||
}
|
||||
|
||||
public String getPigeonholeDate() {
|
||||
return pigeonholeDate;
|
||||
}
|
||||
|
||||
public void setPigeonholeDate(String pigeonholeDate) {
|
||||
this.pigeonholeDate = pigeonholeDate;
|
||||
}
|
||||
|
||||
public String getNote() {
|
||||
return note;
|
||||
}
|
||||
|
||||
public void setNote(String note) {
|
||||
this.note = note;
|
||||
}
|
||||
|
||||
public String getMlh() {
|
||||
return mlh;
|
||||
}
|
||||
|
||||
public void setMlh(String mlh) {
|
||||
this.mlh = mlh;
|
||||
}
|
||||
|
||||
public String getSssq() {
|
||||
return sssq;
|
||||
}
|
||||
|
||||
public void setSssq(String sssq) {
|
||||
this.sssq = sssq;
|
||||
}
|
||||
|
||||
public String getSssqCode() {
|
||||
return sssqCode;
|
||||
}
|
||||
|
||||
public void setSssqCode(String sssqCode) {
|
||||
this.sssqCode = sssqCode;
|
||||
}
|
||||
|
||||
public String getDagdm() {
|
||||
return dagdm;
|
||||
}
|
||||
|
||||
public void setDagdm(String dagdm) {
|
||||
this.dagdm = dagdm;
|
||||
}
|
||||
|
||||
public String getDagdmCode() {
|
||||
return dagdmCode;
|
||||
}
|
||||
|
||||
public void setDagdmCode(String dagdmCode) {
|
||||
this.dagdmCode = dagdmCode;
|
||||
}
|
||||
|
||||
public String getZqbs() {
|
||||
return zqbs;
|
||||
}
|
||||
|
||||
public void setZqbs(String zqbs) {
|
||||
this.zqbs = zqbs;
|
||||
}
|
||||
|
||||
public String getZqbsCode() {
|
||||
return zqbsCode;
|
||||
}
|
||||
|
||||
public void setZqbsCode(String zqbsCode) {
|
||||
this.zqbsCode = zqbsCode;
|
||||
}
|
||||
|
||||
public String getKzbs() {
|
||||
return kzbs;
|
||||
}
|
||||
|
||||
public void setKzbs(String kzbs) {
|
||||
this.kzbs = kzbs;
|
||||
}
|
||||
|
||||
public String getKzbsCode() {
|
||||
return kzbsCode;
|
||||
}
|
||||
|
||||
public void setKzbsCode(String kzbsCode) {
|
||||
this.kzbsCode = kzbsCode;
|
||||
}
|
||||
|
||||
public String getDamldm() {
|
||||
return damldm;
|
||||
}
|
||||
|
||||
public void setDamldm(String damldm) {
|
||||
this.damldm = damldm;
|
||||
}
|
||||
|
||||
public String getDamldmCode() {
|
||||
return damldmCode;
|
||||
}
|
||||
|
||||
public void setDamldmCode(String damldmCode) {
|
||||
this.damldmCode = damldmCode;
|
||||
}
|
||||
|
||||
public String getCreatePerson() {
|
||||
return createPerson;
|
||||
}
|
||||
|
||||
public void setCreatePerson(String createPerson) {
|
||||
this.createPerson = createPerson;
|
||||
}
|
||||
|
||||
public String getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
||||
public void setCreateDate(String createDate) {
|
||||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
public String getArchiveFlag() {
|
||||
return archiveFlag;
|
||||
}
|
||||
|
||||
public void setArchiveFlag(String archiveFlag) {
|
||||
this.archiveFlag = archiveFlag;
|
||||
}
|
||||
|
||||
public String getIsPackeep() {
|
||||
return isPackeep;
|
||||
}
|
||||
|
||||
public void setIsPackeep(String isPackeep) {
|
||||
this.isPackeep = isPackeep;
|
||||
}
|
||||
|
||||
public String getIsPackeepCode() {
|
||||
return isPackeepCode;
|
||||
}
|
||||
|
||||
public void setIsPackeepCode(String isPackeepCode) {
|
||||
this.isPackeepCode = isPackeepCode;
|
||||
}
|
||||
|
||||
public String getMd5Code() {
|
||||
return md5Code;
|
||||
}
|
||||
|
||||
public void setMd5Code(String md5Code) {
|
||||
this.md5Code = md5Code;
|
||||
}
|
||||
|
||||
public String getMd5CheckDate() {
|
||||
return md5CheckDate;
|
||||
}
|
||||
|
||||
public void setMd5CheckDate(String md5CheckDate) {
|
||||
this.md5CheckDate = md5CheckDate;
|
||||
}
|
||||
|
||||
public String getBatchId() {
|
||||
return batchId;
|
||||
}
|
||||
|
||||
public void setBatchId(String batchId) {
|
||||
this.batchId = batchId;
|
||||
}
|
||||
|
||||
public String getBatchName() {
|
||||
return batchName;
|
||||
}
|
||||
|
||||
public void setBatchName(String batchName) {
|
||||
this.batchName = batchName;
|
||||
}
|
||||
|
||||
public String getBackToUpdateState() {
|
||||
return backToUpdateState;
|
||||
}
|
||||
|
||||
public void setBackToUpdateState(String backToUpdateState) {
|
||||
this.backToUpdateState = backToUpdateState;
|
||||
}
|
||||
|
||||
public Integer getIsProcess() {
|
||||
return isProcess;
|
||||
}
|
||||
|
||||
public void setIsProcess(Integer isProcess) {
|
||||
this.isProcess = isProcess;
|
||||
}
|
||||
|
||||
public String getArchiveEntityStatus() {
|
||||
return archiveEntityStatus;
|
||||
}
|
||||
|
||||
public void setArchiveEntityStatus(String archiveEntityStatus) {
|
||||
this.archiveEntityStatus = archiveEntityStatus;
|
||||
}
|
||||
|
||||
public String getArchiveNo() {
|
||||
return archiveNo;
|
||||
}
|
||||
|
||||
public void setArchiveNo(String archiveNo) {
|
||||
this.archiveNo = archiveNo;
|
||||
}
|
||||
|
||||
public String getCreatedDate() {
|
||||
return createdDate;
|
||||
}
|
||||
|
||||
public void setCreatedDate(String createdDate) {
|
||||
this.createdDate = createdDate;
|
||||
}
|
||||
|
||||
public String getDocNo() {
|
||||
return docNo;
|
||||
}
|
||||
|
||||
public void setDocNo(String docNo) {
|
||||
this.docNo = docNo;
|
||||
}
|
||||
|
||||
public Integer getPageNo() {
|
||||
return pageNo;
|
||||
}
|
||||
|
||||
public void setPageNo(Integer pageNo) {
|
||||
this.pageNo = pageNo;
|
||||
}
|
||||
|
||||
public String getResponsibleby() {
|
||||
return responsibleby;
|
||||
}
|
||||
|
||||
public void setResponsibleby(String responsibleby) {
|
||||
this.responsibleby = responsibleby;
|
||||
}
|
||||
|
||||
public Integer getObjectQuantity() {
|
||||
return objectQuantity;
|
||||
}
|
||||
|
||||
public void setObjectQuantity(Integer objectQuantity) {
|
||||
this.objectQuantity = objectQuantity;
|
||||
}
|
||||
|
||||
public String getPageNoEnd() {
|
||||
return pageNoEnd;
|
||||
}
|
||||
|
||||
public void setPageNoEnd(String pageNoEnd) {
|
||||
this.pageNoEnd = pageNoEnd;
|
||||
}
|
||||
|
||||
public String getReportPage() {
|
||||
return reportPage;
|
||||
}
|
||||
|
||||
public void setReportPage(String reportPage) {
|
||||
this.reportPage = reportPage;
|
||||
}
|
||||
|
||||
public String getPid() {
|
||||
return pid;
|
||||
}
|
||||
|
||||
public void setPid(String pid) {
|
||||
this.pid = pid;
|
||||
}
|
||||
|
||||
public String getArchiveZjbs() {
|
||||
return archiveZjbs;
|
||||
}
|
||||
|
||||
public void setArchiveZjbs(String archiveZjbs) {
|
||||
this.archiveZjbs = archiveZjbs;
|
||||
}
|
||||
|
||||
public String getTempNo() {
|
||||
return tempNo;
|
||||
}
|
||||
|
||||
public void setTempNo(String tempNo) {
|
||||
this.tempNo = tempNo;
|
||||
}
|
||||
|
||||
public Integer getPieceNo() {
|
||||
return pieceNo;
|
||||
}
|
||||
|
||||
public void setPieceNo(Integer pieceNo) {
|
||||
this.pieceNo = pieceNo;
|
||||
}
|
||||
|
||||
public List<String> getIdsList() {
|
||||
return idsList;
|
||||
}
|
||||
|
||||
public void setIdsList(List<String> idsList) {
|
||||
this.idsList = idsList;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,199 @@
|
||||
package com.point.strategy.oaDocking.bean;
|
||||
//文书卷内原文传统实体
|
||||
public class DocVolumeOriginalOaEntity {
|
||||
|
||||
private Integer id;
|
||||
private Integer entityId;
|
||||
private Integer recid;
|
||||
private String fileName;
|
||||
private String fileNameServer;
|
||||
private String fileType;
|
||||
private Float fileLen;
|
||||
private String filePath;
|
||||
private String openType;
|
||||
private Integer pageNo;
|
||||
private String version;
|
||||
private String authorName;
|
||||
private String fileRemark;
|
||||
private String fileDes;
|
||||
private Integer downs;
|
||||
private Integer veiws;
|
||||
private String metadataValue;
|
||||
private Integer metadataType;
|
||||
private Integer ocrCheck;
|
||||
private Integer fileStatus;
|
||||
private Integer fileAttr;
|
||||
private String md5Code;
|
||||
private String md5CheckDate;
|
||||
private String dataContent;
|
||||
private String fileContent;
|
||||
private Integer isDivided;
|
||||
private String dividedContent;
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
public Integer getEntityId() {
|
||||
return entityId;
|
||||
}
|
||||
public void setEntityId(Integer entityId) {
|
||||
this.entityId = entityId;
|
||||
}
|
||||
|
||||
public Integer getRecid() {
|
||||
return recid;
|
||||
}
|
||||
public void setRecid(Integer recid) {
|
||||
this.recid = recid;
|
||||
}
|
||||
public String getFileName() {
|
||||
return fileName;
|
||||
}
|
||||
public void setFileName(String fileName) {
|
||||
this.fileName = fileName;
|
||||
}
|
||||
public String getFileNameServer() {
|
||||
return fileNameServer;
|
||||
}
|
||||
public void setFileNameServer(String fileNameServer) {
|
||||
this.fileNameServer = fileNameServer;
|
||||
}
|
||||
public String getFileType() {
|
||||
return fileType;
|
||||
}
|
||||
public void setFileType(String fileType) {
|
||||
this.fileType = fileType;
|
||||
}
|
||||
public Float getFileLen() {
|
||||
return fileLen;
|
||||
}
|
||||
public void setFileLen(Float fileLen) {
|
||||
this.fileLen = fileLen;
|
||||
}
|
||||
public String getFilePath() {
|
||||
return filePath;
|
||||
}
|
||||
public void setFilePath(String filePath) {
|
||||
this.filePath = filePath;
|
||||
}
|
||||
public String getOpenType() {
|
||||
return openType;
|
||||
}
|
||||
public void setOpenType(String openType) {
|
||||
this.openType = openType;
|
||||
}
|
||||
public Integer getPageNo() {
|
||||
return pageNo;
|
||||
}
|
||||
public void setPageNo(Integer pageNo) {
|
||||
this.pageNo = pageNo;
|
||||
}
|
||||
public String getVersion() {
|
||||
return version;
|
||||
}
|
||||
public void setVersion(String version) {
|
||||
this.version = version;
|
||||
}
|
||||
public String getAuthorName() {
|
||||
return authorName;
|
||||
}
|
||||
public void setAuthorName(String authorName) {
|
||||
this.authorName = authorName;
|
||||
}
|
||||
public String getFileRemark() {
|
||||
return fileRemark;
|
||||
}
|
||||
public void setFileRemark(String fileRemark) {
|
||||
this.fileRemark = fileRemark;
|
||||
}
|
||||
public String getFileDes() {
|
||||
return fileDes;
|
||||
}
|
||||
public void setFileDes(String fileDes) {
|
||||
this.fileDes = fileDes;
|
||||
}
|
||||
public Integer getDowns() {
|
||||
return downs;
|
||||
}
|
||||
public void setDowns(Integer downs) {
|
||||
this.downs = downs;
|
||||
}
|
||||
public Integer getVeiws() {
|
||||
return veiws;
|
||||
}
|
||||
public void setVeiws(Integer veiws) {
|
||||
this.veiws = veiws;
|
||||
}
|
||||
public String getMetadataValue() {
|
||||
return metadataValue;
|
||||
}
|
||||
public void setMetadataValue(String metadataValue) {
|
||||
this.metadataValue = metadataValue;
|
||||
}
|
||||
public Integer getMetadataType() {
|
||||
return metadataType;
|
||||
}
|
||||
public void setMetadataType(Integer metadataType) {
|
||||
this.metadataType = metadataType;
|
||||
}
|
||||
public Integer getOcrCheck() {
|
||||
return ocrCheck;
|
||||
}
|
||||
public void setOcrCheck(Integer ocrCheck) {
|
||||
this.ocrCheck = ocrCheck;
|
||||
}
|
||||
public Integer getFileStatus() {
|
||||
return fileStatus;
|
||||
}
|
||||
public void setFileStatus(Integer fileStatus) {
|
||||
this.fileStatus = fileStatus;
|
||||
}
|
||||
public Integer getFileAttr() {
|
||||
return fileAttr;
|
||||
}
|
||||
public void setFileAttr(Integer fileAttr) {
|
||||
this.fileAttr = fileAttr;
|
||||
}
|
||||
public String getMd5Code() {
|
||||
return md5Code;
|
||||
}
|
||||
|
||||
public String getDividedContent() {
|
||||
return dividedContent;
|
||||
}
|
||||
|
||||
public void setDividedContent(String dividedContent) {
|
||||
this.dividedContent = dividedContent;
|
||||
}
|
||||
|
||||
public void setMd5Code(String md5Code) {
|
||||
this.md5Code = md5Code;
|
||||
}
|
||||
public String getMd5CheckDate() {
|
||||
return md5CheckDate;
|
||||
}
|
||||
public void setMd5CheckDate(String md5CheckDate) {
|
||||
this.md5CheckDate = md5CheckDate;
|
||||
}
|
||||
public String getDataContent() {
|
||||
return dataContent;
|
||||
}
|
||||
public void setDataContent(String dataContent) {
|
||||
this.dataContent = dataContent;
|
||||
}
|
||||
public String getFileContent() {
|
||||
return fileContent;
|
||||
}
|
||||
public void setFileContent(String fileContent) {
|
||||
this.fileContent = fileContent;
|
||||
}
|
||||
public Integer getIsDivided() {
|
||||
return isDivided;
|
||||
}
|
||||
public void setIsDivided(Integer isDivided) {
|
||||
this.isDivided = isDivided;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,107 @@
|
||||
package com.point.strategy.oaDocking.bean;
|
||||
|
||||
public class UploadFileEntity {
|
||||
private String fileName;//文件名称 不带扩展名
|
||||
private String fileFullName;//文件名 带扩展名
|
||||
private String fimeType;//文件类型
|
||||
private String fileHardPath;//文件硬盘路径
|
||||
private String fileWebPath;//文件网络路径
|
||||
private String fileInfoPath;//文件预览路径
|
||||
private Long fileSize;// 文件大小
|
||||
private String filePath;//文件所在文件夹路径
|
||||
private String originalfileName;//文件原始名称
|
||||
private String originalfileNameNotExtension;//文件原始名称 不带扩展名
|
||||
|
||||
public String getOriginalfileNameNotExtension() {
|
||||
return originalfileNameNotExtension;
|
||||
}
|
||||
|
||||
public void setOriginalfileNameNotExtension(String originalfileNameNotExtension) {
|
||||
this.originalfileNameNotExtension = originalfileNameNotExtension;
|
||||
}
|
||||
|
||||
public String getOriginalfileName() {
|
||||
return originalfileName;
|
||||
}
|
||||
|
||||
public void setOriginalfileName(String originalfileName) {
|
||||
this.originalfileName = originalfileName;
|
||||
}
|
||||
|
||||
public String getFilePath() {
|
||||
return filePath;
|
||||
}
|
||||
|
||||
public void setFilePath(String filePath) {
|
||||
this.filePath = filePath;
|
||||
}
|
||||
|
||||
public String getFileFullName() {
|
||||
return fileFullName;
|
||||
}
|
||||
|
||||
public void setFileFullName(String fileFullName) {
|
||||
this.fileFullName = fileFullName;
|
||||
}
|
||||
|
||||
public String getFileName() {
|
||||
return fileName;
|
||||
}
|
||||
|
||||
public void setFileName(String fileName) {
|
||||
this.fileName = fileName;
|
||||
}
|
||||
|
||||
public String getFimeType() {
|
||||
return fimeType;
|
||||
}
|
||||
|
||||
public void setFimeType(String fimeType) {
|
||||
this.fimeType = fimeType;
|
||||
}
|
||||
|
||||
public String getFileHardPath() {
|
||||
return fileHardPath;
|
||||
}
|
||||
|
||||
public void setFileHardPath(String fileHardPath) {
|
||||
this.fileHardPath = fileHardPath;
|
||||
}
|
||||
|
||||
public String getFileWebPath() {
|
||||
return fileWebPath;
|
||||
}
|
||||
|
||||
public void setFileWebPath(String fileWebPath) {
|
||||
this.fileWebPath = fileWebPath;
|
||||
}
|
||||
|
||||
public String getFileInfoPath() {
|
||||
return fileInfoPath;
|
||||
}
|
||||
|
||||
public void setFileInfoPath(String fileInfoPath) {
|
||||
this.fileInfoPath = fileInfoPath;
|
||||
}
|
||||
|
||||
public Long getFileSize() {
|
||||
return fileSize;
|
||||
}
|
||||
|
||||
public void setFileSize(Long fileSize) {
|
||||
this.fileSize = fileSize;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "UploadFileEntity{" +
|
||||
"fileName='" + fileName + '\'' +
|
||||
", fileFullName='" + fileFullName + '\'' +
|
||||
", fimeType='" + fimeType + '\'' +
|
||||
", fileHardPath='" + fileHardPath + '\'' +
|
||||
", fileWebPath='" + fileWebPath + '\'' +
|
||||
", fileInfoPath='" + fileInfoPath + '\'' +
|
||||
", fileSize=" + fileSize +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,223 @@
|
||||
package com.point.strategy.oaDocking.controller;
|
||||
|
||||
import com.bstek.ureport.Utils;
|
||||
import com.bstek.ureport.export.ExportConfigure;
|
||||
import com.bstek.ureport.export.ExportConfigureImpl;
|
||||
import com.bstek.ureport.export.ExportManager;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.point.strategy.common.AjaxJson;
|
||||
import com.point.strategy.docSimpleArrange.bean.DocSimpleArrange;
|
||||
import com.point.strategy.oaDocking.bean.DocOriginalOaEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocSimpleArrangeOa;
|
||||
import com.point.strategy.oaDocking.service.DocSimpleOaService;
|
||||
import com.point.strategy.user.bean.UserRole;
|
||||
import com.point.strategy.user.service.UserService;
|
||||
import com.point.strategy.webSocket.WebSocket;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.poi.hssf.usermodel.HSSFCell;
|
||||
import org.apache.poi.hssf.usermodel.HSSFRow;
|
||||
import org.apache.poi.hssf.usermodel.HSSFSheet;
|
||||
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.*;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/v/docSimpleOa")
|
||||
@Api(tags = "预归档文书简化整理", value = "DocSimpleOaController")
|
||||
public class DocSimpleOaController {
|
||||
|
||||
private static final Logger logger = LoggerFactory.getLogger(DocSimpleOaController.class);
|
||||
|
||||
@Autowired
|
||||
private DocSimpleOaService docSimpleService;
|
||||
|
||||
@RequestMapping(value="/getDocSimpleWithPage" , method= RequestMethod.GET)
|
||||
@ApiOperation(value = "分页查询简化方法整理信息")
|
||||
public AjaxJson getDocSimpleWithPage(String fondsNo,String fondsNoCode,Integer page,Integer limit) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
DocSimpleArrangeOa docSimpleArrange = new DocSimpleArrangeOa();
|
||||
docSimpleArrange.setFondsNo(fondsNo);
|
||||
docSimpleArrange.setFondsNoCode(fondsNoCode);
|
||||
if(page!=null)
|
||||
{
|
||||
docSimpleArrange.setPage(page);
|
||||
|
||||
}
|
||||
if(limit!=null)
|
||||
{
|
||||
|
||||
docSimpleArrange.setLimit(limit);
|
||||
}
|
||||
|
||||
List list = docSimpleService.getDocSimpleWithPage(docSimpleArrange);
|
||||
PageInfo pageInfo = new PageInfo(list);
|
||||
long total = pageInfo.getTotal();
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
json.put("total", total);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("分页查询简化方法整理信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/saveDocSimple" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "保存简化方法整理信息")
|
||||
public AjaxJson saveDocSimple(@RequestBody DocSimpleArrangeOa docSimpleArrange) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
int num = docSimpleService.saveDocSimple(docSimpleArrange);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("保存简化方法整理信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/deleteDocSimple" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "删除简化方法整理信息,批量删除用逗号隔开id值")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "逗号拼接的id字符串", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson deleteDocSimple(String ids) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
int num = docSimpleService.deleteDocSimple(ids);
|
||||
json = AjaxJson.returnInfo("成功删除"+num+"条记录");
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("删除简化方法整理信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/updateDocSimple" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "修改简化方法整理信息")
|
||||
public AjaxJson updateDocSimple(@RequestBody DocSimpleArrangeOa docSimpleArrange) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docSimpleService.updateDocSimple(docSimpleArrange);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("修改简化方法整理信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@RequestMapping(value="/queryDocOriginalEntity" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "查询原文信息")
|
||||
public AjaxJson queryDocOriginalEntity(@RequestParam(value = "recId",required = true)Integer recId) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
List list = docSimpleService.queryDocOriginalEntity(recId);
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("查询原文信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/updateDocOriginalEntity" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "原文入回收站")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "逗号拼接的id字符串", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson updateDocOriginalEntity(String ids,Integer recId) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
DocSimpleArrangeOa docSimpleArrange = new DocSimpleArrangeOa();
|
||||
int num =docSimpleService.updateDocOriginalEntity(ids);
|
||||
int fileNumber = docSimpleService.getDocOriginalEntityCount(recId);
|
||||
int archiveFileNum = fileNumber;
|
||||
//更新原文数量
|
||||
docSimpleArrange.setArchiveFileNum(archiveFileNum);
|
||||
docSimpleArrange.setId(recId);
|
||||
docSimpleService.updateDocSimple(docSimpleArrange);
|
||||
|
||||
json = AjaxJson.returnInfo("成功入回收站"+num+"条记录");
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("原文入回收站失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/queryDocOriginalEntityRecycle" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "查询原文回收站信息")
|
||||
public AjaxJson queryDocOriginalEntityRecycle(@RequestParam(value = "recId",required = true)Integer recId) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
List list = docSimpleService.queryDocOriginalEntityRecycle(recId);
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("查询原文回收站信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/updateDocOriginalEntityRecycle" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "原文回收站恢复")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "id", value = "原文主键id", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson updateDocOriginalEntityRecycle(Integer id) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docSimpleService.updateDocOriginalEntityRecycle(id);
|
||||
DocOriginalOaEntity docOriginalEntity = docSimpleService.queryDocOriginalEntityById(id);
|
||||
if(null != docOriginalEntity){
|
||||
Integer recId = docOriginalEntity.getRecid();
|
||||
int fileNumber = docSimpleService.getDocOriginalEntityCount(recId);
|
||||
int archiveFileNum = fileNumber;
|
||||
//更新原文数量
|
||||
DocSimpleArrangeOa docSimpleArrange = new DocSimpleArrangeOa();
|
||||
docSimpleArrange.setArchiveFileNum(archiveFileNum);
|
||||
docSimpleArrange.setId(recId);
|
||||
docSimpleService.updateDocSimple(docSimpleArrange);
|
||||
}
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("原文回收站恢复失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/deleteDocOriginalEntityRecycle" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "删除原文回收站,批量删除用逗号隔开id值")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "逗号拼接的id字符串", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson deleteDocOriginalEntityRecycle(String ids) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
int num = docSimpleService.deleteDocOriginalEntityRecycle(ids);
|
||||
json = AjaxJson.returnInfo("成功删除"+num+"条记录");
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("删除原文回收站信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,465 @@
|
||||
package com.point.strategy.oaDocking.controller;
|
||||
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.point.strategy.common.AjaxJson;
|
||||
import com.point.strategy.docTraditionArrange.docFile.bean.DocFileOriginalEntity;
|
||||
import com.point.strategy.docTraditionArrange.docFile.bean.DocTraditionArrangeFile;
|
||||
import com.point.strategy.oaDocking.bean.DocTraditionArrangeFileOa;
|
||||
import com.point.strategy.oaDocking.service.DocTraditionFileOaService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.poi.hssf.usermodel.HSSFCell;
|
||||
import org.apache.poi.hssf.usermodel.HSSFRow;
|
||||
import org.apache.poi.hssf.usermodel.HSSFSheet;
|
||||
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.ByteArrayOutputStream;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.*;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/v/docFileOa")
|
||||
@Api(tags = "预归档文书传统整理-案卷", value = "DocTraditionFileOaController")
|
||||
public class DocTraditionFileOaController {
|
||||
|
||||
private static final Logger logger = LoggerFactory.getLogger(DocTraditionFileOaController.class);
|
||||
|
||||
@Autowired
|
||||
private DocTraditionFileOaService docTraditionFileService;
|
||||
|
||||
@RequestMapping(value="/getDocFileWithPage" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "分页查询传统方法整理案卷信息")
|
||||
public AjaxJson getDocFileWithPage(String fondsNo,String fondsNoCode,Integer page,Integer limit) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
DocTraditionArrangeFileOa docTraditionArrangeFile = new DocTraditionArrangeFileOa();
|
||||
docTraditionArrangeFile.setFondsNo(fondsNo);
|
||||
docTraditionArrangeFile.setFondsNoCode(fondsNoCode);
|
||||
if(page!=null)
|
||||
{
|
||||
docTraditionArrangeFile.setPage(page);
|
||||
|
||||
}
|
||||
if(limit!=null)
|
||||
{
|
||||
|
||||
docTraditionArrangeFile.setLimit(limit);
|
||||
}
|
||||
List list = docTraditionFileService.getDocFileWithPage(docTraditionArrangeFile);
|
||||
PageInfo pageInfo = new PageInfo(list);
|
||||
long total = pageInfo.getTotal();
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
json.put("total", total);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("分页查询传统方法整理案卷信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/saveDocFile" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "保存传统方法整理案卷信息")
|
||||
// @ApiImplicitParams({
|
||||
// @ApiImplicitParam(paramType = "query", name = "folder_no", value = "案卷级档号", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "js", value = "总件数", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "folder_location", value = "存放位置", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "maintitle", value = "题名", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "security_class", value = "密级", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "security_class_code", value = "密级代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "fonds_no", value = "全宗名称", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "fonds_no_code", value = "全宗代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "retention", value = "保管期限", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "retention_code", value = "保管期限代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "filing_year", value = "归档年度", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "archive_ctg_no", value = "实体分类号", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "archive_ctg_no_code", value = "实体分类号代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "year_folder_no", value = "案卷号", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "quantity", value = "总页数", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "doc_start_time", value = "文件形成开始时间", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "doc_end_time", value = "文件形成结束时间", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "sbt_word", value = "关键字", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "pigeonhole_date", value = "归档日期", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "note", value = "备注", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "mlh", value = "目录号", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "sssq", value = "sssq", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "sssq_code", value = "sssq_code", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "dagdm", value = "档案馆", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "dagdm_code", value = "档案馆代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "zqbs", value = "zqbs", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "zqbs_code", value = "zqbs_code", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "kzbs", value = "控制标识", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "kzbs_code", value = "控制标识代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "damldm", value = "档案门类", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "damldm_code", value = "档案门类代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "create_person", value = "录入人", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "create_date", value = "录入日期", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "is_packeep", value = "是否打eep包", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "is_packeep_code", value = "是否打eep包代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "md5_code", value = "加密代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "md5_check_date", value = "加密检测日期", required = false, dataType = "String"),
|
||||
//
|
||||
// @ApiImplicitParam(paramType = "query", name = "archive_file_num", value = "原文数量", required = false, dataType = "String")
|
||||
// })
|
||||
public AjaxJson saveDocFile(@RequestBody DocTraditionArrangeFileOa docTraditionArrangeFile) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docTraditionArrangeFile.setFileStatus(1);
|
||||
int num = docTraditionFileService.saveDocFile(docTraditionArrangeFile);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("保存传统方法整理案卷信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/deleteDocFile" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "删除传统方法整理案卷信息,批量删除用逗号隔开id值")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "逗号拼接的id字符串", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson deleteDocFile(String ids) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
int num = docTraditionFileService.deleteDocFile(ids);
|
||||
json = AjaxJson.returnInfo("成功删除"+num+"条记录");
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("删除传统方法整理案卷信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/updateDocFile" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "修改传统方法整理案卷信息")
|
||||
// @ApiImplicitParams({
|
||||
// @ApiImplicitParam(paramType = "query", name = "id", value = "物理主键", required = false, dataType = "int"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "folder_no", value = "案卷级档号", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "js", value = "总件数", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "folder_location", value = "存放位置", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "maintitle", value = "题名", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "security_class", value = "密级", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "security_class_code", value = "密级代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "fonds_no", value = "全宗名称", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "fonds_no_code", value = "全宗代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "retention", value = "保管期限", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "retention_code", value = "保管期限代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "filing_year", value = "归档年度", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "archive_ctg_no", value = "实体分类号", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "archive_ctg_no_code", value = "实体分类号代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "year_folder_no", value = "案卷号", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "quantity", value = "总页数", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "doc_start_time", value = "文件形成开始时间", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "doc_end_time", value = "文件形成结束时间", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "sbt_word", value = "关键字", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "pigeonhole_date", value = "归档日期", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "note", value = "备注", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "mlh", value = "目录号", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "sssq", value = "sssq", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "sssq_code", value = "sssq_code", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "dagdm", value = "档案馆", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "dagdm_code", value = "档案馆代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "zqbs", value = "zqbs", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "zqbs_code", value = "zqbs_code", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "kzbs", value = "控制标识", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "kzbs_code", value = "控制标识代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "damldm", value = "档案门类", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "damldm_code", value = "档案门类代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "create_person", value = "录入人", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "create_date", value = "录入日期", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "is_packeep", value = "是否打eep包", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "is_packeep_code", value = "是否打eep包代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "md5_code", value = "加密代码", required = false, dataType = "String"),
|
||||
// @ApiImplicitParam(paramType = "query", name = "md5_check_date", value = "加密检测日期", required = false, dataType = "String"),
|
||||
//
|
||||
// @ApiImplicitParam(paramType = "query", name = "archive_file_num", value = "原文数量", required = false, dataType = "String")
|
||||
// })
|
||||
public AjaxJson updateDocFile(@RequestBody DocTraditionArrangeFileOa docTraditionArrangeFile) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docTraditionFileService.updateDocFile(docTraditionArrangeFile);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("修改传统方法整理案卷信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/queryDocFileOriginalEntity" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "查询原文信息")
|
||||
public AjaxJson queryDocFileOriginalEntity(@RequestParam(value = "recId",required = true)Integer recId) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
List list = docTraditionFileService.queryDocFileOriginalEntity(recId);
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("查询原文信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/updateDocFileOriginalEntity" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "原文入回收站")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "原文主键ids", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson updateDocFileOriginalEntity(@RequestParam(value = "ids",required = true) String ids) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
String[] idAarray=ids.split(",");
|
||||
for (String id:idAarray) {
|
||||
docTraditionFileService.updateDocFileOriginalEntity(Integer.parseInt(id));
|
||||
}
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("原文入回收站失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/queryDocFileOriginalList" , method= RequestMethod.POST)
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "recId", example = "1", value = "recId", dataType = "String", paramType = "query"),
|
||||
@ApiImplicitParam(name = "fileStatus", example = "1", value = "文件状态(1-上传文件数据,2-回收站数据)", dataType = "String", paramType = "query"),
|
||||
})
|
||||
@ApiOperation(value = "查询案卷原文文件列表信息")
|
||||
public AjaxJson queryDocFileOriginalList(
|
||||
@RequestParam(value = "recId",required = true)Integer recId,
|
||||
@RequestParam(value = "fileStatus",required = true)Integer fileStatus
|
||||
) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
Map<String,Object> map=new HashMap<>();
|
||||
map.put("recId",recId);
|
||||
map.put("fileStatus",fileStatus);
|
||||
List list = docTraditionFileService.queryDocFileOriginalEntityRecycle(map);
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("查询原文信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@RequestMapping(value="/updateDocFileOriginalEntityRecycle" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "原文回收站恢复")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "id", value = "原文主键id", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson updateDocFileOriginalEntityRecycle(Integer id) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docTraditionFileService.updateDocFileOriginalEntityRecycle(id);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("原文回收站恢复失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/deleteDocFileOriginalEntityRecycle" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "删除原文回收站,批量删除用逗号隔开id值")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "逗号拼接的id字符串", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson deleteDocFileOriginalEntityRecycle(String ids) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
int num = docTraditionFileService.deleteDocFileOriginalEntityRecycle(ids);
|
||||
json = AjaxJson.returnInfo("成功删除"+num+"条记录");
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("删除原文回收站信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/downloadDocFileExcelTemplate" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "下载文书传统整理案卷excel模板")
|
||||
public void downloadExcelTemplate(HttpServletResponse response)throws Exception{
|
||||
response.setHeader("Pragma", "No-cache");
|
||||
response.setHeader("Cache-Control", "no-cache");
|
||||
response.setDateHeader("Expires", 0);
|
||||
response.reset();
|
||||
response.setContentType("application/x-msdownload; charset=utf-8");
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss");
|
||||
String fileName = new String("文书传统整理模板".getBytes("utf-8"),"utf-8")+sdf.format(new Date())+".xls";
|
||||
response.setHeader("Content-disposition", "attachment; filename=" + fileName);
|
||||
|
||||
String[] columnsTitle = {"案卷级档号","总件数","存放位置","题名","密级","密级代码","全宗名称","全宗号",
|
||||
"归档年度","保管期限","保管期限代码","实体分类号","实体分类号代码","案卷号","总页数","文件形成开始时间",
|
||||
"文件形成结束时间","关键字","归档日期","备注","目录号","sssq","sssq_code","档案馆",
|
||||
"档案馆代码","zqbs","zqbs_code","控制标识","控制标识代码","档案门类","档案门类代码","录入人",
|
||||
"录入日期","组卷标识","是否打eep包","是否打eep包代码","加密代码","加密检测日期","batch_id","batch_name",
|
||||
"back_to_update_state","is_process","archive_entity_status"};
|
||||
|
||||
HSSFWorkbook wb = new HSSFWorkbook();
|
||||
HSSFSheet sheet = wb.createSheet("文书传统整理案卷模板");
|
||||
HSSFRow row = sheet.createRow(0);
|
||||
for(int i=0;i<columnsTitle.length;i++) {
|
||||
HSSFCell cell = row.createCell(i);
|
||||
sheet.setColumnWidth(i, 3766);
|
||||
cell.setCellValue(columnsTitle[i]);
|
||||
}
|
||||
|
||||
ByteArrayOutputStream bos = new ByteArrayOutputStream();
|
||||
wb.write(bos);
|
||||
response.setHeader("Content-Length", bos.toByteArray().length+"");
|
||||
bos.writeTo(response.getOutputStream());
|
||||
response.flushBuffer();
|
||||
}
|
||||
|
||||
/**
|
||||
* 传统-案卷
|
||||
* @param response
|
||||
* @param fondsNoCode
|
||||
* @throws Exception
|
||||
*/
|
||||
@RequestMapping(value="/downloadDocFileExcel" , method= RequestMethod.GET)
|
||||
@ApiOperation(value = "下载文书传统整理Excel")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "fondsNoCode", value = "全宗号代码", dataType = "String"),
|
||||
})
|
||||
public void downloadExcel(HttpServletResponse response,String fondsNoCode,String ids)throws Exception{
|
||||
response.setHeader("Pragma", "No-cache");
|
||||
response.setHeader("Cache-Control", "no-cache");
|
||||
response.setDateHeader("Expires", 0);
|
||||
response.reset();
|
||||
response.setContentType("application/x-msdownload; charset=utf-8");
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss");
|
||||
String fileName = new String("文书案卷目录".getBytes("utf-8"),"ISO-8859-1")+sdf.format(new Date())+".xls";
|
||||
response.setHeader("Content-disposition", "attachment; filename=" + fileName);
|
||||
|
||||
String[] columnsTitle = {"案卷级档号","总件数","存放位置","题名",
|
||||
"密级", "全宗号","归档年度",
|
||||
"保管期限","实体分类号","案卷号",
|
||||
"文件开始时间", "文件结束时间",
|
||||
"主题词","归档日期","备注","目录号",
|
||||
"档案所属历史时期", "档案馆代码","政权标识",
|
||||
"控制标识","档案门类代码","档案实体状态"};
|
||||
|
||||
String fieldName = "folder_no,js,folder_location,maintitle," +
|
||||
"security_class,fonds_no,filing_year," +
|
||||
"retention,archive_ctg_no,year_folder_no," +
|
||||
"doc_start_time,doc_end_time," +
|
||||
"maintitle,filing_year,note,mlh," +
|
||||
"pigeonhole_date,dagdm,zqbs," +
|
||||
"kzbs,damldm,archive_entity_status";
|
||||
String cols[] = fieldName.split(",");
|
||||
HSSFWorkbook wb = new HSSFWorkbook();
|
||||
HSSFSheet sheet = wb.createSheet("文书传统整理");
|
||||
HSSFRow row = sheet.createRow(0);
|
||||
for(int i=0;i<cols.length;i++) {
|
||||
HSSFCell cell = row.createCell(i);
|
||||
sheet.setColumnWidth(i, 3766);
|
||||
cell.setCellValue(columnsTitle[i]);
|
||||
}
|
||||
List<String> idsList=new ArrayList<>();
|
||||
if (ids!=null && !"".equals(ids)){
|
||||
String[] idArray=ids.split(",");
|
||||
for (String id:idArray) {
|
||||
idsList.add(id);
|
||||
}
|
||||
}
|
||||
|
||||
DocTraditionArrangeFileOa docTraditionArrangeFile = new DocTraditionArrangeFileOa();
|
||||
docTraditionArrangeFile.setFondsNoCode(fondsNoCode);
|
||||
docTraditionArrangeFile.setIdsList(idsList);
|
||||
|
||||
List list = docTraditionFileService.getDocFileWithPage(docTraditionArrangeFile);
|
||||
for (int i = 0; i < list.size(); i++) {
|
||||
HSSFRow rowi = sheet.createRow(i + 1);
|
||||
|
||||
rowi.createCell(0).setCellValue(((DocTraditionArrangeFile)list.get(i)).getFolderNo());
|
||||
rowi.createCell(1).setCellValue(((DocTraditionArrangeFile)list.get(i)).getJs());
|
||||
rowi.createCell(2).setCellValue(((DocTraditionArrangeFile)list.get(i)).getFolderLocation());
|
||||
rowi.createCell(3).setCellValue(((DocTraditionArrangeFile)list.get(i)).getMaintitle());
|
||||
|
||||
rowi.createCell(4).setCellValue(((DocTraditionArrangeFile)list.get(i)).getSecurityClass());
|
||||
rowi.createCell(5).setCellValue(((DocTraditionArrangeFile)list.get(i)).getFondsNo());
|
||||
rowi.createCell(6).setCellValue(((DocTraditionArrangeFile)list.get(i)).getFilingYear());
|
||||
|
||||
rowi.createCell(7).setCellValue(((DocTraditionArrangeFile)list.get(i)).getRetention());
|
||||
rowi.createCell(8).setCellValue(((DocTraditionArrangeFile)list.get(i)).getArchiveCtgNo());
|
||||
rowi.createCell(9).setCellValue(((DocTraditionArrangeFile)list.get(i)).getYearFolderNo());
|
||||
|
||||
rowi.createCell(10).setCellValue(((DocTraditionArrangeFile)list.get(i)).getDocStartTime());
|
||||
rowi.createCell(11).setCellValue(((DocTraditionArrangeFile)list.get(i)).getDocEndTime());
|
||||
|
||||
rowi.createCell(12).setCellValue(((DocTraditionArrangeFile)list.get(i)).getMaintitle());
|
||||
rowi.createCell(13).setCellValue(((DocTraditionArrangeFile)list.get(i)).getFilingYear());
|
||||
rowi.createCell(14).setCellValue(((DocTraditionArrangeFile)list.get(i)).getNote());
|
||||
rowi.createCell(15).setCellValue(((DocTraditionArrangeFile)list.get(i)).getMlh());
|
||||
|
||||
rowi.createCell(16).setCellValue(((DocTraditionArrangeFile)list.get(i)).getDocEndTime());
|
||||
rowi.createCell(17).setCellValue(((DocTraditionArrangeFile)list.get(i)).getSbtWord());
|
||||
rowi.createCell(18).setCellValue(((DocTraditionArrangeFile)list.get(i)).getPigeonholeDate());
|
||||
|
||||
rowi.createCell(19).setCellValue(((DocTraditionArrangeFile)list.get(i)).getKzbs());
|
||||
rowi.createCell(20).setCellValue(((DocTraditionArrangeFile)list.get(i)).getDamldm());
|
||||
rowi.createCell(21).setCellValue(((DocTraditionArrangeFile)list.get(i)).getArchiveEntityStatus());
|
||||
}
|
||||
|
||||
ByteArrayOutputStream bos = new ByteArrayOutputStream();
|
||||
wb.write(bos);
|
||||
response.setHeader("Content-Length", bos.toByteArray().length+"");
|
||||
bos.writeTo(response.getOutputStream());
|
||||
response.flushBuffer();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@RequestMapping(value="/saveBatchDocFiles" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "批量上传文书传统excel数据")
|
||||
public AjaxJson saveBatchDocFiles(@RequestParam("file") MultipartFile file)throws Exception {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docTraditionFileService.saveBatchDocFiles(file);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("批量上传文书传统整理失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/updateTempFile" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "更新文书传统案卷原文文件")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "ids", example = "1,2", value = "支持批量操作,多个用逗号隔开", dataType = "String", paramType = "query"),
|
||||
@ApiImplicitParam(name = "fileStatus", example = "1", value = "文件状态(1-上传文件数据,2-回收站数据)", dataType = "String", paramType = "query"),
|
||||
})
|
||||
public AjaxJson updateTempFile(@RequestParam(value = "ids",required = true)String ids,
|
||||
@RequestParam(value = "fileStatus",required = true)Integer fileStatus
|
||||
) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
String[] idArray= ids.split(",");
|
||||
for (String id:idArray) {
|
||||
DocFileOriginalEntity entity=new DocFileOriginalEntity();
|
||||
entity.setId(Integer.parseInt(id));
|
||||
entity.setFileStatus(fileStatus);
|
||||
docTraditionFileService.updateTempFile(entity);
|
||||
json = new AjaxJson();
|
||||
}
|
||||
DocFileOriginalEntity entity=docTraditionFileService.selectFileOneById(Integer.parseInt(idArray[0]));
|
||||
docTraditionFileService.wsajmlTempCount(entity.getRecid());
|
||||
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("更新文书传统案卷原文文件失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,292 @@
|
||||
package com.point.strategy.oaDocking.controller;
|
||||
|
||||
import com.bstek.ureport.Utils;
|
||||
import com.bstek.ureport.export.ExportConfigure;
|
||||
import com.bstek.ureport.export.ExportConfigureImpl;
|
||||
import com.bstek.ureport.export.ExportManager;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.point.strategy.common.AjaxJson;
|
||||
import com.point.strategy.docTraditionArrange.docVolume.bean.DocTraditionArrangeVolume;
|
||||
import com.point.strategy.docTraditionArrange.docVolume.bean.DocVolumeOriginalEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocTraditionArrangeOaVolume;
|
||||
import com.point.strategy.oaDocking.service.DocTraditionVolumeOaService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.*;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/v/docVolumeOa")
|
||||
@Api(tags = "预归档文书传统整理-卷内", value = "DocTraditionVolumeOaController")
|
||||
public class DocTraditionVolumeOaController {
|
||||
|
||||
private static final Logger logger = LoggerFactory.getLogger(DocTraditionVolumeOaController.class);
|
||||
@Autowired
|
||||
private DocTraditionVolumeOaService docTraditionVolumeService;
|
||||
|
||||
@RequestMapping(value="/getDocVolumeWithPage" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "分页查询传统方法整理卷内信息")
|
||||
public AjaxJson getDocVolumeWithPage(String fondsNo,String fondsNoCode,String pid,Integer page,Integer limit) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
DocTraditionArrangeOaVolume docTraditionArrangeVolume = new DocTraditionArrangeOaVolume();
|
||||
docTraditionArrangeVolume.setFondsNo(fondsNo);
|
||||
docTraditionArrangeVolume.setFondsNoCode(fondsNoCode);
|
||||
docTraditionArrangeVolume.setPid(pid);
|
||||
if(page!=null) {
|
||||
docTraditionArrangeVolume.setPage(page);
|
||||
}
|
||||
if(limit!=null) {
|
||||
docTraditionArrangeVolume.setLimit(limit);
|
||||
}
|
||||
List list = docTraditionVolumeService.getDocVolumeWithPage(docTraditionArrangeVolume);
|
||||
PageInfo pageInfo = new PageInfo(list);
|
||||
long total = pageInfo.getTotal();
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
json.put("total", total);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("分页查询传统方法整理卷内信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/saveDocVolume" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "保存传统方法整理卷内信息")
|
||||
@ApiImplicitParams({
|
||||
|
||||
})
|
||||
public AjaxJson saveDocVolume(@RequestBody DocTraditionArrangeOaVolume docTraditionArrangeVolume) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docTraditionArrangeVolume.setFileStatus(1);
|
||||
int num = docTraditionVolumeService.saveDocVolume(docTraditionArrangeVolume);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("保存传统方法整理卷内信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/deleteDocVolume" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "删除传统方法整理卷内信息,批量删除用逗号隔开id值")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "逗号拼接的id字符串", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson deleteDocVolume(String ids) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
int num = docTraditionVolumeService.deleteDocVolume(ids);
|
||||
json = AjaxJson.returnInfo("成功删除"+num+"条记录");
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("删除传统方法整理卷内信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/updateDocVolume" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "修改传统方法整理卷内信息")
|
||||
@ApiImplicitParams({
|
||||
|
||||
})
|
||||
public AjaxJson updateDocVolume(@RequestBody DocTraditionArrangeOaVolume docTraditionArrangeVolume) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docTraditionVolumeService.updateDocVolume(docTraditionArrangeVolume);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("修改传统方法整理卷内信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/downLoadDocVolumePdf" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "导出文书传统卷内pdf文件")
|
||||
public void downLoadPdf(HttpServletRequest request, HttpServletResponse response) throws Exception {
|
||||
request.setCharacterEncoding("UTF-8");
|
||||
String fileName = "创建文书传统卷内pdf文件.pdf";
|
||||
String downLoadPath = "C:\\\\ureportfiles\\\\"+fileName;
|
||||
response.setContentType("application/pdf");
|
||||
FileInputStream in = new FileInputStream(new File(downLoadPath));
|
||||
OutputStream out = response.getOutputStream();
|
||||
byte[] b = new byte[1024];
|
||||
while ((in.read(b))!=-1) {
|
||||
out.write(b);
|
||||
}
|
||||
out.flush();
|
||||
in.close();
|
||||
out.close();
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/createDocVolumePdf" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "创建文书传统卷内pdf文件")
|
||||
public void createDocVolumePdf(String fondsNo,String fondsNoCode) throws IOException {
|
||||
Map<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("fondsNo",fondsNo);
|
||||
map.put("fondsNoCode",fondsNoCode);
|
||||
OutputStream outputStream = null;
|
||||
try {
|
||||
String fileName = "创建文书传统卷内pdf文件.pdf";
|
||||
outputStream = new FileOutputStream(new File("C:\\ureportfiles\\"+fileName));
|
||||
ExportConfigure config = new ExportConfigureImpl("file:" + "创建文书传统卷内pdf文件.ureport.xml", map, outputStream);
|
||||
ExportManager exportManager = (ExportManager) Utils.getApplicationContext().getBean(ExportManager.BEAN_ID);
|
||||
exportManager.exportPdf(config);
|
||||
}catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/queryDocVolumeOriginalEntity" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "查询原文信息")
|
||||
public AjaxJson queryDocVolumeOriginalEntity(@RequestParam(value = "recId",required = true)Integer recId) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
List list = docTraditionVolumeService.queryDocVolumeOriginalEntity(recId);
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("查询原文信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/updateDocVolumeOriginalEntity" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "原文入回收站")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "原文主键ids", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson updateDocVolumeOriginalEntity(String ids) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
String[] idAarray=ids.split(",");
|
||||
for (String id:idAarray) {
|
||||
docTraditionVolumeService.updateDocVolumeOriginalEntity(Integer.parseInt(id));
|
||||
}
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("原文入回收站失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/queryDocVolumeOriginalEntityRecycle" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "查询原文回收站信息")
|
||||
public AjaxJson queryDocVolumeOriginalEntityRecycle(@RequestParam(value = "recId",required = true)Integer recId) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
List list = docTraditionVolumeService.queryDocVolumeOriginalEntityRecycle(recId);
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("查询原文回收站信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/queryDocVolumeOriginalEntityRecycle2" , method= RequestMethod.POST)
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "recId", example = "1", value = "recId", dataType = "String", paramType = "query"),
|
||||
@ApiImplicitParam(name = "fileStatus", example = "1", value = "文件状态(1-上传文件数据,2-回收站数据)", dataType = "String", paramType = "query"),
|
||||
})
|
||||
@ApiOperation(value = "查询原文文件信息")
|
||||
public AjaxJson queryDocVolumeOriginalEntityRecycle2(
|
||||
@RequestParam(value = "recId",required = true)Integer recId,
|
||||
@RequestParam(value = "fileStatus",required = true)Integer fileStatus
|
||||
) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
Map<String,Object> map=new HashMap<>();
|
||||
map.put("recId",recId);
|
||||
map.put("fileStatus",fileStatus);
|
||||
List list = docTraditionVolumeService.queryDocVolumeOriginalEntityRecycle2(map);
|
||||
json = new AjaxJson();
|
||||
json.put("list", list);
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("查询原文回收站信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@RequestMapping(value="/updateDocVolumeOriginalEntityRecycle" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "原文回收站恢复")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "id", value = "原文主键id", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson updateDocVolumeOriginalEntityRecycle(Integer id) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
docTraditionVolumeService.updateDocVolumeOriginalEntityRecycle(id);
|
||||
json = new AjaxJson();
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("原文回收站恢复失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@RequestMapping(value="/deleteDocVolumeOriginalEntityRecycle" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "删除原文回收站,批量删除用逗号隔开id值")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "query", name = "ids", value = "逗号拼接的id字符串", required = true, dataType = "String"),
|
||||
})
|
||||
public AjaxJson deleteDocVolumeOriginalEntityRecycle(String ids) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
int num = docTraditionVolumeService.deleteDocVolumeOriginalEntityRecycle(ids);
|
||||
json = AjaxJson.returnInfo("成功删除"+num+"条记录");
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("删除原文回收站信息失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value="/updateTempFile" , method= RequestMethod.POST)
|
||||
@ApiOperation(value = "把文件删除到回收站以及恢复")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "ids", example = "1,2", value = "支持批量操作", dataType = "String", paramType = "query"),
|
||||
@ApiImplicitParam(name = "fileStatus", example = "1", value = "文件状态(1-上传文件数据,2-回收站数据)", dataType = "String", paramType = "query"),
|
||||
})
|
||||
public AjaxJson updateTempFile(
|
||||
@RequestParam(value = "ids",required = true)String ids,
|
||||
@RequestParam(value = "fileStatus",required = true)Integer fileStatus
|
||||
) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
String[] idArray=ids.split(",");
|
||||
for (String id:idArray) {
|
||||
DocVolumeOriginalEntity entity=new DocVolumeOriginalEntity();
|
||||
entity.setId(Integer.parseInt(id));
|
||||
entity.setFileStatus(fileStatus);
|
||||
docTraditionVolumeService.updateTempFile(entity);
|
||||
json = new AjaxJson();
|
||||
}
|
||||
DocVolumeOriginalEntity entity=docTraditionVolumeService.selectFileOneById(Integer.parseInt(idArray[0]));
|
||||
docTraditionVolumeService.wsjnmlTempCount(entity.getRecid());
|
||||
}catch(Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("操作失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,328 @@
|
||||
package com.point.strategy.oaDocking.controller;
|
||||
|
||||
import cn.hutool.core.codec.Base64;
|
||||
import com.point.strategy.common.AjaxJson;
|
||||
import com.point.strategy.common.FileUtil;
|
||||
import com.point.strategy.oaDocking.bean.DocOriginalOaEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocSimpleArrangeOa;
|
||||
import com.point.strategy.oaDocking.mapper.DocSimpleOaMapper;
|
||||
import com.point.strategy.oaDocking.service.DocSimpleOaService;
|
||||
import com.point.strategy.user.bean.User;
|
||||
import com.point.strategy.user.bean.UserRole;
|
||||
import com.point.strategy.user.service.UserService;
|
||||
import com.point.strategy.webSocket.SessionUtils;
|
||||
import com.point.strategy.webSocket.WebSocket;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import net.sf.json.JSONObject;
|
||||
import org.apache.commons.collections.CollectionUtils;
|
||||
import org.apache.commons.io.IOUtils;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.mock.web.MockMultipartFile;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.websocket.Session;
|
||||
import java.io.*;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@RestController
|
||||
@Transactional
|
||||
@RequestMapping("/v/originBatchOa")
|
||||
@Api(tags = "预归档原文上传", value = "OriginBatchOaController")
|
||||
public class OriginBatchOaController {
|
||||
|
||||
private static final Logger logger = LoggerFactory.getLogger(OriginBatchOaController.class);
|
||||
@Autowired
|
||||
private DocSimpleOaService docSimpleService;
|
||||
@Autowired
|
||||
public DocSimpleOaMapper docSimpleMapper;
|
||||
|
||||
@Autowired
|
||||
private WebSocket webSocket;
|
||||
|
||||
@Autowired
|
||||
private UserService userService;
|
||||
|
||||
private AjaxJson uploadSimpleFile(MultipartFile file, String fondscode, Integer recId, HttpServletRequest request) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
//创建文件在服务器端存放路径
|
||||
//String dir = request.getServletContext().getRealPath("/WSJH_20201103104220949_TEMP_FILE/"+fondscode+"/"+recId);
|
||||
String dir = request.getRealPath("/") + "WSJH_20201103104220949_TEMP_FILE" + File.separator + fondscode + File.separator + recId;
|
||||
File fileDir = new File(dir);
|
||||
if (!fileDir.exists()) {
|
||||
fileDir.mkdirs();
|
||||
}
|
||||
DocOriginalOaEntity docOriginalEntity = new DocOriginalOaEntity();
|
||||
String originalFilename = file.getOriginalFilename();
|
||||
int index = originalFilename.lastIndexOf(".") + 1;
|
||||
String fileType = originalFilename.substring(index);
|
||||
|
||||
|
||||
docOriginalEntity.setFileName(originalFilename);
|
||||
docOriginalEntity.setRecid(recId);
|
||||
docOriginalEntity.setFileType(fileType);
|
||||
long fileLen = file.getSize() / 1024;//file.getSize()为b,file.getSize()/1024为kb,
|
||||
docOriginalEntity.setFileLen((float) fileLen);
|
||||
docOriginalEntity.setFilePath(dir);
|
||||
int pageNo = docSimpleService.getDocOriginalEntityCount(recId) + 1;
|
||||
//更新原文数量
|
||||
DocSimpleArrangeOa docSimpleArrange = new DocSimpleArrangeOa();
|
||||
docSimpleArrange.setArchiveFileNum(pageNo);
|
||||
docSimpleArrange.setId(recId);
|
||||
docSimpleService.updateDocSimple(docSimpleArrange);
|
||||
|
||||
docOriginalEntity.setPageNo(pageNo);
|
||||
docOriginalEntity.setFileStatus(1);
|
||||
docOriginalEntity.setIsDivided(-1);
|
||||
|
||||
/*if(pageNo<10)
|
||||
docOriginalEntity.setFileNameServer(archiveNo+".000"+pageNo+"."+fileType);
|
||||
else if(10<=pageNo && pageNo<100)
|
||||
docOriginalEntity.setFileNameServer(archiveNo+".00"+pageNo+"."+fileType);
|
||||
else if(100<=pageNo && pageNo<1000)
|
||||
docOriginalEntity.setFileNameServer(archiveNo+".0"+pageNo+"."+fileType);
|
||||
else
|
||||
docOriginalEntity.setFileNameServer(archiveNo+"."+pageNo+"."+fileType);
|
||||
*/
|
||||
docOriginalEntity.setFileNameServer(originalFilename);
|
||||
docSimpleService.saveDocOriginalEntity(docOriginalEntity);
|
||||
//String fileSuffix = originalFilename.substring(index);
|
||||
//String fileName= UUID.randomUUID().toString()+fileSuffix;
|
||||
File files = new File(fileDir + "/" + docOriginalEntity.getFileNameServer());
|
||||
//上传
|
||||
file.transferTo(files);
|
||||
json = AjaxJson.returnInfo("上传文件成功");
|
||||
} catch (Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("上传文件失败" + e);
|
||||
logger.info(file.getOriginalFilename() + "上传文件失败" + e);
|
||||
;
|
||||
}
|
||||
return json;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value = "/uploadSimpleFiles", method = RequestMethod.POST)
|
||||
@ApiOperation(value = "文书简化整理原文单个或者多个上传")
|
||||
//file要与表单上传的名字相同
|
||||
public AjaxJson uploadSimpleFiles(MultipartFile file[], String fondscode, Integer recId, HttpServletRequest request) {
|
||||
|
||||
Integer successNum = 0;
|
||||
Integer falseNum = 0;
|
||||
for (int i = 0; i < file.length; i++) {
|
||||
MultipartFile f = file[i];
|
||||
AjaxJson json2 = uploadSimpleFile(f, fondscode, recId, request);
|
||||
if ("101".equals(json2.getCode())) {
|
||||
falseNum++;
|
||||
}
|
||||
if ("100".equals(json2.getCode())) {
|
||||
successNum++;
|
||||
}
|
||||
}
|
||||
AjaxJson json = AjaxJson.returnInfo("成功上传数successNum,失败上传数falseNum");
|
||||
json.put("successNum", successNum);
|
||||
json.put("falseNum", falseNum);
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
private AjaxJson uploadFilesByPath(MultipartFile file, String fondscode, Integer recId, HttpServletRequest request, String archiveNo) throws IllegalStateException, IOException {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
String dir = request.getRealPath("/") + "/WSJH_20201103104220949_TEMP_FILE/" + fondscode + "/" + recId;
|
||||
File fileDir = new File(dir);
|
||||
if (!fileDir.exists()) {
|
||||
fileDir.mkdirs();
|
||||
}
|
||||
DocOriginalOaEntity docOriginalEntity = new DocOriginalOaEntity();
|
||||
String originalFilename = file.getOriginalFilename();
|
||||
int index = originalFilename.lastIndexOf(".") + 1;
|
||||
String fileType = originalFilename.substring(index);
|
||||
|
||||
|
||||
docOriginalEntity.setFileName(originalFilename);
|
||||
docOriginalEntity.setRecid(recId);
|
||||
docOriginalEntity.setFileType(fileType);
|
||||
long fileLen = file.getSize() / 1024;//file.getSize()为b,file.getSize()/1024为kb,
|
||||
docOriginalEntity.setFileLen((float) fileLen);
|
||||
docOriginalEntity.setFilePath(dir);
|
||||
int pageNo = docSimpleService.getDocOriginalEntityCount(recId) + 1;
|
||||
docOriginalEntity.setPageNo(pageNo);
|
||||
docOriginalEntity.setFileStatus(1);
|
||||
docOriginalEntity.setIsDivided(-1);
|
||||
|
||||
docOriginalEntity.setFileNameServer(originalFilename);
|
||||
docSimpleService.saveDocOriginalEntity(docOriginalEntity);
|
||||
File files = new File(fileDir + "/" + docOriginalEntity.getFileNameServer());
|
||||
file.transferTo(files);
|
||||
json = AjaxJson.returnInfo("文书简化挂接成功");
|
||||
logger.info(file.getOriginalFilename() + "文书简化挂接成功");
|
||||
} catch (Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("文书简化挂接失败" + e);
|
||||
logger.info(file.getOriginalFilename()+ "文书简化挂接失败" + e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
//文书简化整理的原文批量上传
|
||||
@RequestMapping(value = "/uploadFilesByPaths", method = RequestMethod.POST)
|
||||
@ApiOperation(value = "文书简化整理原文通过文件夹批量上传")
|
||||
public AjaxJson uploadFilesByPaths(String fondscode, String table, String methodType, String pathurl, HttpServletRequest request) {
|
||||
Integer successNum = 0;
|
||||
Integer falseNum = 0;
|
||||
Integer fileCount = 0;
|
||||
if ("1".equals(methodType) && "WSDA_20190528111300933_TEMP".equals(table.toUpperCase())) {
|
||||
File file = new File(pathurl);
|
||||
File[] fs = file.listFiles();
|
||||
if(null == fs || fs.length < 1){
|
||||
return AjaxJson.returnExceptionInfo("文件路径填写错误或不存在");
|
||||
}
|
||||
fileCount = FileUtil.getFileNum(file, 0);
|
||||
|
||||
UserRole userRole = userService.getUserRole(request);
|
||||
User user = userRole.getUser();
|
||||
String code = "";
|
||||
if(null != user){
|
||||
code = user.getUsername();
|
||||
}
|
||||
Session session = SessionUtils.get(code);
|
||||
for (int i = 0; i < fs.length; i++) {
|
||||
String archiveNo = fs[i].getName();
|
||||
DocSimpleArrangeOa docSimpleArrange = new DocSimpleArrangeOa();
|
||||
docSimpleArrange.setArchiveNo(archiveNo);
|
||||
List list = docSimpleService.getDocSimpleWithPage(docSimpleArrange);
|
||||
if(CollectionUtils.isEmpty(list)){
|
||||
return AjaxJson.returnExceptionInfo("文件存放路径错误");
|
||||
}
|
||||
|
||||
docSimpleArrange = (DocSimpleArrangeOa) list.get(0);
|
||||
Integer id = docSimpleArrange.getId();
|
||||
Integer recId = id;
|
||||
|
||||
//String dir = request.getServletContext().getRealPath("/WSJH_20201103104220949_TEMP_FILE/"+fondscode+"/"+recId);
|
||||
String dir = request.getRealPath("/") + "/WSJH_20201103104220949_TEMP_FILE/" + fondscode + "/" + recId;
|
||||
File fileDir = new File(dir);
|
||||
if (fileDir.exists()) {
|
||||
deleteDir(fileDir);
|
||||
}
|
||||
fileDir.mkdirs();
|
||||
|
||||
docSimpleMapper.deleteDocSimpleCascadeRecycle(recId);
|
||||
|
||||
/*String path = fs[i].getAbsolutePath();
|
||||
System.out.println(path + "===" + archiveNo);*/
|
||||
|
||||
File[] fs2 = fs[i].listFiles();
|
||||
for (int j = 0; j < fs2.length; j++) {
|
||||
FileInputStream input = null;
|
||||
try {
|
||||
input = new FileInputStream(fs2[j]);
|
||||
} catch (FileNotFoundException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
MultipartFile multipartFile = null;
|
||||
try {
|
||||
multipartFile = new MockMultipartFile("file", fs2[j].getName(), "text/plain", IOUtils.toByteArray(input));
|
||||
} catch (IOException e1) {
|
||||
// TODO Auto-generated catch block
|
||||
e1.printStackTrace();
|
||||
}
|
||||
String path = pathurl.replaceAll("\\\\", "/") + "/"+archiveNo+"/"+multipartFile.getOriginalFilename();
|
||||
try {
|
||||
AjaxJson json2 = uploadFilesByPath(multipartFile, fondscode, recId, request, archiveNo);
|
||||
String str = "";
|
||||
if ("101".equals(json2.getCode())) {
|
||||
falseNum++;
|
||||
str = "挂接失败";
|
||||
}
|
||||
if ("100".equals(json2.getCode())) {
|
||||
successNum++;
|
||||
str = "挂接成功";
|
||||
}
|
||||
if(null != session){
|
||||
AjaxJson ajaxJson = AjaxJson.returnInfo(path + str);
|
||||
ajaxJson.put("successNum", successNum);
|
||||
ajaxJson.put("falseNum", falseNum);
|
||||
ajaxJson.put("fileCount", fileCount);
|
||||
JSONObject jsonObject = JSONObject.fromObject(ajaxJson);
|
||||
webSocket.sendMessage(jsonObject.toString(), session);
|
||||
}
|
||||
|
||||
} catch (Exception e) {
|
||||
if(null != session) {
|
||||
AjaxJson ajaxJson = AjaxJson.returnInfo(path + "挂接失败");
|
||||
ajaxJson.put("successNum", successNum);
|
||||
ajaxJson.put("falseNum", falseNum);
|
||||
ajaxJson.put("fileCount", fileCount);
|
||||
JSONObject jsonObject = JSONObject.fromObject(ajaxJson);
|
||||
webSocket.sendMessage(jsonObject.toString(), session);
|
||||
}
|
||||
logger.error(path + "原文简化批量挂接失败" + e);
|
||||
|
||||
}
|
||||
|
||||
String filePath = fs2[j].getAbsolutePath();
|
||||
String fileName = fs2[j].getName();
|
||||
System.out.println(filePath + "===" + fileName);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
AjaxJson json = AjaxJson.returnInfo("成功上传数successNum,失败上传数falseNum");
|
||||
json.put("successNum", successNum);
|
||||
json.put("falseNum", falseNum);
|
||||
return json;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(value = "/getOriginImage", method = RequestMethod.POST)
|
||||
@ApiOperation(value = "获取原文图片,简化和传统都适用")
|
||||
public AjaxJson getOriginImage(String fileNameServer, String filePath) {
|
||||
AjaxJson json = null;
|
||||
try {
|
||||
String dir = filePath + File.separator + fileNameServer;
|
||||
//String dir = "F:\\简化\\005-2001-055-001\\0001.jpg";
|
||||
File fileDir = new File(dir);
|
||||
InputStream in = new FileInputStream(fileDir);
|
||||
ByteArrayOutputStream stream = new ByteArrayOutputStream();
|
||||
int k = in.read();
|
||||
while (k != -1) {
|
||||
stream.write(k);
|
||||
k = in.read();
|
||||
}
|
||||
String base64 = Base64.encode(stream.toByteArray());
|
||||
json = new AjaxJson();
|
||||
json.put("img", base64);
|
||||
} catch (Exception e) {
|
||||
json = AjaxJson.returnExceptionInfo("获取原文图片失败" + e);
|
||||
}
|
||||
return json;
|
||||
|
||||
}
|
||||
|
||||
private static boolean deleteDir(File dir) {
|
||||
if (dir.isDirectory()) {
|
||||
String[] children = dir.list();
|
||||
for (int i = 0; i < children.length; i++) {
|
||||
boolean success = deleteDir(new File(dir, children[i]));
|
||||
if (!success) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
// 目录此时为空,可以删除
|
||||
return dir.delete();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,343 @@
|
||||
package com.point.strategy.oaDocking.controller;
|
||||
|
||||
import cn.hutool.cron.CronException;
|
||||
import cn.hutool.http.HttpUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.TypeReference;
|
||||
import com.point.strategy.common.*;
|
||||
import com.point.strategy.docTraditionArrange.docVolume.service.DanganguanliService;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections.CollectionUtils;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.scheduling.annotation.Scheduled;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
|
||||
import java.io.*;
|
||||
import java.net.HttpURLConnection;
|
||||
import java.net.URL;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import static com.point.strategy.oaDocking.util.FileUtils.unzip;
|
||||
|
||||
|
||||
@Slf4j
|
||||
@Component
|
||||
public class Scheduler1 {
|
||||
|
||||
@Autowired
|
||||
private DanganguanliService danganguanliService;
|
||||
|
||||
@Value("${img.upload}")
|
||||
private String uploadPath;
|
||||
|
||||
|
||||
//定时任务早上5点,晚上23点执行
|
||||
@Scheduled(cron = "00 00 05,23 * * ?")
|
||||
public void resp1_64() {
|
||||
System.out.println("测试早上五点和晚上23点");
|
||||
System.out.println(new Date() + "测试每天早上5点");
|
||||
AjaxJson json = wsjhProject();
|
||||
//记录日志
|
||||
GlobalLog.writerLog(new Date()+"执行"+json.toString(),Scheduler1.class);
|
||||
}
|
||||
|
||||
// @Scheduled(cron = "0/1 * * * * ?")
|
||||
// public void aaa(){
|
||||
// System.out.println("测试");
|
||||
// }
|
||||
|
||||
|
||||
public AjaxJson wsjhProject() {
|
||||
AjaxJson json = null;
|
||||
String requestid = "";
|
||||
try {
|
||||
String tableName = "zhgl_20220629162353";
|
||||
String tempTableName = tableName + "_temp";
|
||||
String fileTableName = tableName + "_temp_file";
|
||||
String resultStr = HttpUtil.get("https://oa.jztey.com/jzt/getArchive.jsp");
|
||||
Map<String, Object> map1 = JSON.parseObject(resultStr, new TypeReference<Map<String, Object>>() {});
|
||||
List<Map<String,Object>> list = (List<Map<String, Object>>) map1.get("part");
|
||||
if(CollectionUtils.isNotEmpty(list)){
|
||||
for (Map<String, Object> map : list) {
|
||||
//把数据添加到简化表中
|
||||
String fieldName = "";
|
||||
String valueName = "";
|
||||
List<Map<String,Object>> fileList = null;
|
||||
for(Map.Entry<String, Object> entry:map.entrySet()){
|
||||
|
||||
if(entry.getKey().equals("requestid")){
|
||||
requestid = entry.getValue().toString();
|
||||
}
|
||||
|
||||
if (!entry.getKey().equals("damldm")&&!entry.getKey().equals("requestid")&&!entry.getKey().equals("fileList")){
|
||||
fieldName = fieldName + entry.getKey().toLowerCase() + ",";
|
||||
valueName = valueName + "'" + entry.getValue() + "',";
|
||||
}
|
||||
if (entry.getKey().equals("fileList")){
|
||||
fileList = (List<Map<String, Object>>) entry.getValue();
|
||||
}
|
||||
}
|
||||
fieldName = fieldName + "archive_flag";
|
||||
valueName = valueName + "'预归档未完成'";
|
||||
Map<String, Object> mapTwo = new HashMap<String, Object>();
|
||||
mapTwo.put("tableName", tempTableName);
|
||||
//其实我们知道是哪些字段
|
||||
mapTwo.put("fieldName", fieldName);
|
||||
mapTwo.put("valueName", valueName);
|
||||
danganguanliService.saveObject(mapTwo);
|
||||
int jhId = Integer.parseInt(mapTwo.get("id").toString());
|
||||
|
||||
String filePath = "uploadFile/" + fileTableName + "/" + jhId;
|
||||
String dir = uploadPath + File.separator + filePath;
|
||||
|
||||
if(CollectionUtils.isNotEmpty(fileList)){
|
||||
for (Map<String, Object> mapList : fileList) {
|
||||
String fileName = (String) mapList.get("fileName");
|
||||
String downloadAddress = (String) mapList.get("downloadAddress");
|
||||
String myuuid = StringUtil.generaterUUID();
|
||||
String fileNameServer =myuuid + fileName;
|
||||
File fileOne = new File(dir);
|
||||
if (!fileOne.exists()) {
|
||||
fileOne.mkdirs();
|
||||
}
|
||||
String fileUrl = dir+"/"+fileNameServer;
|
||||
String str = HttpUtil.get(downloadAddress);
|
||||
Map<String, Object> map2 = JSON.parseObject(str, new TypeReference<Map<String, Object>>() {});
|
||||
String fileBase64 = (String) map2.get("fileBase64");
|
||||
Base64Utils.decode2(fileUrl,fileBase64);
|
||||
int i = 1;
|
||||
String[] strings = fileName.split("\\.");
|
||||
String type = strings[strings.length - 1].toLowerCase();
|
||||
|
||||
//把文件数据添加到file表中
|
||||
String fieldNameFile =
|
||||
"rec_id, " +
|
||||
"file_name, " +
|
||||
"file_name_server, " +
|
||||
"file_path, " +
|
||||
"file_type," +
|
||||
|
||||
"page_no," +
|
||||
"file_des," +
|
||||
"file_status";
|
||||
String valueNameFile =
|
||||
"" + jhId + "," +
|
||||
"'" + fileName+ "'," +
|
||||
"'" + fileNameServer+ "'," +
|
||||
"'" + filePath + "'," +
|
||||
"'" + type + "'," +
|
||||
|
||||
i + "," +
|
||||
"'" + dir + "'," +
|
||||
"1";
|
||||
Map<String, Object> mapFile = new HashMap<String, Object>();
|
||||
mapFile.put("tableName", fileTableName);
|
||||
//其实我们知道是哪些字段
|
||||
mapFile.put("fieldName", fieldNameFile);
|
||||
mapFile.put("valueName", valueNameFile);
|
||||
danganguanliService.saveObject(mapFile);
|
||||
if(type.equals("jpg")||type.equals("png") ){
|
||||
//生成一份pdf文件,用于归档章的操作
|
||||
String newName_pdf=fileNameServer.replace("."+type,".pdf");
|
||||
PdfFileHelper.image2Pdf(dir+File.separator+fileNameServer,dir+File.separator+newName_pdf);
|
||||
|
||||
String newName_pdf_original=newName_pdf.replace(".pdf","_original.pdf");
|
||||
FileTool.copyFile(dir+File.separator+newName_pdf,dir+File.separator+newName_pdf_original);
|
||||
}
|
||||
i++;
|
||||
|
||||
}
|
||||
//更新原文数量
|
||||
Map<String, Object> map7=new HashMap<>();
|
||||
map7.put("tableName",tempTableName);
|
||||
map7.put("tableName2",fileTableName);
|
||||
map7.put("id",jhId);
|
||||
danganguanliService.wsajmlTempCount(map7);
|
||||
}
|
||||
|
||||
//处理结果成功反馈接口
|
||||
Map<String, Object> param = new HashMap<>();
|
||||
param.put("requestid",requestid);
|
||||
param.put("messages","SUCCESS");
|
||||
String resultStr11 = HttpUtil.get("https://oa.jztey.com/jzt/getArchiveResult.jsp",param);
|
||||
System.out.println(resultStr11);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
json = new AjaxJson();
|
||||
|
||||
|
||||
}catch(Exception e) {
|
||||
//处理结果失败反馈接口
|
||||
Map<String, Object> param = new HashMap<>();
|
||||
param.put("requestid",requestid);
|
||||
param.put("messages",e.toString());
|
||||
String resultStr11 = HttpUtil.get("https://oa.jztey.com/jzt/getArchiveResult.jsp",param);
|
||||
System.out.println(resultStr11);
|
||||
json = AjaxJson.returnExceptionInfo("获取OA接口失败"+e);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
// public AjaxJson wsjhProject() {
|
||||
// AjaxJson json = null;
|
||||
// String requestid = "";
|
||||
// try {
|
||||
// String tableName = "zhgl_20220629162353";
|
||||
// String tempTableName = tableName + "_temp";
|
||||
// String fileTableName = tableName + "_temp_file";
|
||||
// String resultStr = HttpUtil.get("https://oa.jztey.com/jzt/getArchive.jsp");
|
||||
// Map<String, Object> map1 = JSON.parseObject(resultStr, new TypeReference<Map<String, Object>>() {});
|
||||
// List<Map<String,Object>> list = (List<Map<String, Object>>) map1.get("part");
|
||||
// if(CollectionUtils.isNotEmpty(list)){
|
||||
// for (Map<String, Object> map : list) {
|
||||
// //把数据添加到简化表中
|
||||
// String fieldName = "";
|
||||
// String valueName = "";
|
||||
// List<Map<String,Object>> fileList = null;
|
||||
// for(Map.Entry<String, Object> entry:map.entrySet()){
|
||||
//
|
||||
// if(entry.getKey().equals("requestid")){
|
||||
// requestid = entry.getValue().toString();
|
||||
// }
|
||||
//
|
||||
// if (!entry.getKey().equals("damldm")&&!entry.getKey().equals("requestid")&&!entry.getKey().equals("fileList")){
|
||||
// fieldName = fieldName + entry.getKey().toLowerCase() + ",";
|
||||
// valueName = valueName + "'" + entry.getValue() + "',";
|
||||
// }
|
||||
// if (entry.getKey().equals("fileList")){
|
||||
// fileList = (List<Map<String, Object>>) entry.getValue();
|
||||
// }
|
||||
// }
|
||||
// fieldName = fieldName + "archive_flag";
|
||||
// valueName = valueName + "'预归档未完成'";
|
||||
// Map<String, Object> mapTwo = new HashMap<String, Object>();
|
||||
// mapTwo.put("tableName", tempTableName);
|
||||
// //其实我们知道是哪些字段
|
||||
// mapTwo.put("fieldName", fieldName);
|
||||
// mapTwo.put("valueName", valueName);
|
||||
// danganguanliService.saveObject(mapTwo);
|
||||
// int jhId = Integer.parseInt(mapTwo.get("id").toString());
|
||||
//
|
||||
// String filePath = "uploadFile/" + fileTableName + "/" + jhId;
|
||||
// String dir = uploadPath + File.separator + filePath;
|
||||
//
|
||||
// if(CollectionUtils.isNotEmpty(fileList)){
|
||||
// for (Map<String, Object> mapList : fileList) {
|
||||
// String fileName = (String) mapList.get("fileName");
|
||||
// String downloadAddress = (String) mapList.get("downloadAddress");
|
||||
// String myuuid = StringUtil.generaterUUID();
|
||||
// String fileNameServer =myuuid + fileName;
|
||||
// URL url1 = new URL(downloadAddress);
|
||||
// HttpURLConnection urlConnection = (HttpURLConnection)url1.openConnection();
|
||||
// urlConnection.connect();
|
||||
// if (urlConnection.getResponseCode() == HttpURLConnection.HTTP_OK) {
|
||||
// InputStream inputStream = urlConnection.getInputStream();
|
||||
// BufferedInputStream bi = new BufferedInputStream(inputStream);
|
||||
// String imgName = fileNameServer;
|
||||
// File fileOne = new File(dir);
|
||||
// if (!fileOne.exists()) {
|
||||
// fileOne.mkdirs();
|
||||
// }
|
||||
// FileOutputStream fos = new FileOutputStream(dir+"/"+imgName);
|
||||
// byte[] by = new byte[1024];
|
||||
// int len = 0;
|
||||
// while((len=bi.read(by))!=-1){
|
||||
// fos.write(by,0,len);
|
||||
// }
|
||||
//
|
||||
//
|
||||
// int i = 1;
|
||||
// String[] strings = fileName.split("\\.");
|
||||
// String type = strings[strings.length - 1].toLowerCase();
|
||||
// float length = (float)bi.available() / 1024;
|
||||
// //把文件数据添加到file表中
|
||||
// String fieldNameFile =
|
||||
// "rec_id, " +
|
||||
// "file_name, " +
|
||||
// "file_name_server, " +
|
||||
// "file_path, " +
|
||||
// "file_type," +
|
||||
// "file_len," +
|
||||
// "page_no," +
|
||||
// "file_des," +
|
||||
// "file_status";
|
||||
// String valueNameFile =
|
||||
// "" + jhId + "," +
|
||||
// "'" + fileName+ "'," +
|
||||
// "'" + fileNameServer+ "'," +
|
||||
// "'" + filePath + "'," +
|
||||
// "'" + type + "'," +
|
||||
// length + "," +
|
||||
// i + "," +
|
||||
// "'" + dir + "'," +
|
||||
// "1";
|
||||
// Map<String, Object> mapFile = new HashMap<String, Object>();
|
||||
// mapFile.put("tableName", fileTableName);
|
||||
// //其实我们知道是哪些字段
|
||||
// mapFile.put("fieldName", fieldNameFile);
|
||||
// mapFile.put("valueName", valueNameFile);
|
||||
// danganguanliService.saveObject(mapFile);
|
||||
// if(type.equals("jpg")||type.equals("png") ){
|
||||
// //生成一份pdf文件,用于归档章的操作
|
||||
// String newName_pdf=fileNameServer.replace("."+type,".pdf");
|
||||
// PdfFileHelper.image2Pdf(dir+File.separator+fileNameServer,dir+File.separator+newName_pdf);
|
||||
//
|
||||
// String newName_pdf_original=newName_pdf.replace(".pdf","_original.pdf");
|
||||
// FileTool.copyFile(dir+File.separator+newName_pdf,dir+File.separator+newName_pdf_original);
|
||||
// }
|
||||
// i++;
|
||||
//
|
||||
// fos.flush();
|
||||
// fos.close();
|
||||
// bi.close();
|
||||
// inputStream.close();
|
||||
//
|
||||
// }
|
||||
// }
|
||||
// //更新原文数量
|
||||
// Map<String, Object> map7=new HashMap<>();
|
||||
// map7.put("tableName",tempTableName);
|
||||
// map7.put("tableName2",fileTableName);
|
||||
// map7.put("id",jhId);
|
||||
// danganguanliService.wsajmlTempCount(map7);
|
||||
// }
|
||||
//
|
||||
// //处理结果成功反馈接口
|
||||
// Map<String, Object> param = new HashMap<>();
|
||||
// param.put("requestid",requestid);
|
||||
// param.put("messages","SUCCESS");
|
||||
// String resultStr11 = HttpUtil.get("https://oa.jztey.com/jzt/getArchiveResult.jsp",param);
|
||||
// System.out.println(resultStr11);
|
||||
// }
|
||||
// }
|
||||
//
|
||||
//
|
||||
// json = new AjaxJson();
|
||||
//
|
||||
//
|
||||
// }catch(Exception e) {
|
||||
// //处理结果失败反馈接口
|
||||
// Map<String, Object> param = new HashMap<>();
|
||||
// param.put("requestid",requestid);
|
||||
// param.put("messages",e.toString());
|
||||
// String resultStr11 = HttpUtil.get("https://oa.jztey.com/jzt/getArchiveResult.jsp",param);
|
||||
// System.out.println(resultStr11);
|
||||
// json = AjaxJson.returnExceptionInfo("获取OA接口失败"+e);
|
||||
// }
|
||||
// return json;
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
package com.point.strategy.oaDocking.mapper;
|
||||
|
||||
import com.point.strategy.oaDocking.bean.DocOriginalOaEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocSimpleArrangeOa;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@Mapper
|
||||
public interface DocSimpleOaMapper {
|
||||
List getDocSimpleWithPage(DocSimpleArrangeOa docSimpleArrange);
|
||||
public int saveDocSimple(DocSimpleArrangeOa docSimpleArrange);
|
||||
public int deleteDocSimple(Integer id);
|
||||
public int deleteDocSimpleCascadeRecycle(Integer recId);
|
||||
public int updateDocSimple(DocSimpleArrangeOa docSimpleArrange);
|
||||
public int getDocOriginalEntityCount(Integer recId);
|
||||
public void saveDocOriginalEntity(DocOriginalOaEntity docOriginalEntity);
|
||||
public void saveDocOriginalJnEntity(DocOriginalOaEntity docOriginalEntity);
|
||||
public List queryDocOriginalEntity(Integer recId);
|
||||
public int updateDocOriginalEntity(Integer id);
|
||||
public List queryDocOriginalEntityRecycle(Integer recId);
|
||||
public void updateDocOriginalEntityRecycle(Integer id);
|
||||
public int deleteDocOriginalEntityRecycle(Integer id);
|
||||
public void saveBatchDocSimple(Map map);
|
||||
DocOriginalOaEntity queryDocOriginalEntityById(Integer id);
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
package com.point.strategy.oaDocking.mapper;
|
||||
|
||||
import com.point.strategy.docTraditionArrange.docFile.bean.DocFileOriginalEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocTraditionArrangeFileOa;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
//文书案卷mapper
|
||||
@Mapper
|
||||
public interface DocTraditionFileOaMapper {
|
||||
List getDocFileWithPage(DocTraditionArrangeFileOa DocTraditionArrangeFile);
|
||||
public int saveDocFile(DocTraditionArrangeFileOa DocTraditionArrangeFile);
|
||||
public int deleteDocFile(Integer id);
|
||||
public int deleteDocFileCascadeRecycle(Integer recId);
|
||||
public int updateDocFile(DocTraditionArrangeFileOa DocTraditionArrangeFile);
|
||||
public int getDocFileOriginalEntityCount(Integer recId);
|
||||
public void saveDocFileOriginalEntity(DocFileOriginalEntity docFileOriginalEntity);
|
||||
public List queryDocFileOriginalEntity(Integer recId);
|
||||
public void updateDocFileOriginalEntity(Integer id);
|
||||
public List queryDocFileOriginalEntityRecycle(Integer recId);
|
||||
public List<DocFileOriginalEntity> queryDocFileOriginalEntityRecycle(Map<String,Object> map);
|
||||
public void updateDocFileOriginalEntityRecycle(Integer id);
|
||||
public int deleteDocFileOriginalEntityRecycle(Integer id);
|
||||
public void saveBatchDocFiles(Map map);
|
||||
//预归档-案卷-更新文书传统案卷原文文件
|
||||
public void updateTempFile(DocFileOriginalEntity entity);
|
||||
//预归档-案卷-更新档案文件数量
|
||||
public void wsajmlTempCount(Integer id);
|
||||
//预归档-案卷-查询文件对象
|
||||
public DocFileOriginalEntity selectFileOneById(Integer id);
|
||||
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
package com.point.strategy.oaDocking.mapper;
|
||||
|
||||
import com.point.strategy.docTraditionArrange.docVolume.bean.DocVolumeOriginalEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocTraditionArrangeOaVolume;
|
||||
import com.point.strategy.oaDocking.bean.DocVolumeOriginalOaEntity;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
//文书卷内
|
||||
@Mapper
|
||||
public interface DocTraditionVolumeOaMapper {
|
||||
List getDocVolumeWithPage(DocTraditionArrangeOaVolume docTraditionArrangeVolume);
|
||||
public int saveDocVolume(DocTraditionArrangeOaVolume docTraditionArrangeVolume);
|
||||
public int deleteDocVolume(Integer id);
|
||||
public int deleteDocVolumeCascadeRecycle(Integer recId);
|
||||
public int updateDocVolume(DocTraditionArrangeOaVolume docTraditionArrangeVolume);
|
||||
public int getDocVolumeOriginalEntityCount(Integer recId);
|
||||
public void saveDocVolumeOriginalEntity(DocVolumeOriginalOaEntity docVolumeOriginalEntity);
|
||||
public List queryDocVolumeOriginalEntity(Integer recId);
|
||||
public void updateDocVolumeOriginalEntity(Integer id);
|
||||
public List queryDocVolumeOriginalEntityRecycle(Integer recId);
|
||||
public List<DocVolumeOriginalOaEntity> queryDocVolumeOriginalEntityRecycle2(Map<String,Object> map);
|
||||
public void updateDocVolumeOriginalEntityRecycle(Integer id);
|
||||
public int deleteDocVolumeOriginalEntityRecycle(Integer id);
|
||||
public void saveBatchDocVolumes(Map map);
|
||||
|
||||
//卷内-更新文书传统卷内原文文件
|
||||
public void updateTempFile(DocVolumeOriginalEntity entity);
|
||||
//卷内-更新档案文件数量
|
||||
public void wsjnmlTempCount(Integer id);
|
||||
//卷内-查询文件id
|
||||
public DocVolumeOriginalEntity selectFileOneById(Integer id);
|
||||
}
|
||||
@@ -0,0 +1,205 @@
|
||||
package com.point.strategy.oaDocking.service;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.point.strategy.docSimpleArrange.bean.DocOriginalEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocOriginalOaEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocSimpleArrangeOa;
|
||||
import com.point.strategy.oaDocking.mapper.DocSimpleOaMapper;
|
||||
import jxl.Cell;
|
||||
import jxl.Sheet;
|
||||
import jxl.Workbook;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.InputStream;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
//文书简化
|
||||
@Service
|
||||
@Transactional
|
||||
public class DocSimpleOaService {
|
||||
// @Resource
|
||||
@Autowired
|
||||
public DocSimpleOaMapper docSimpleMapper;
|
||||
|
||||
public List getDocSimpleWithPage(DocSimpleArrangeOa docSimpleArrange) {
|
||||
PageHelper.startPage(docSimpleArrange.getPage(), docSimpleArrange.getLimit());
|
||||
List docSimpleArranges= docSimpleMapper.getDocSimpleWithPage(docSimpleArrange);
|
||||
return docSimpleArranges;
|
||||
}
|
||||
|
||||
public int saveDocSimple(DocSimpleArrangeOa docSimpleArrange) {
|
||||
return docSimpleMapper.saveDocSimple(docSimpleArrange);
|
||||
}
|
||||
|
||||
public int deleteDocSimple(String ids) {
|
||||
int num = 0;
|
||||
if(ids!=null && !"".equals(ids) && ids.length()>0){
|
||||
String id[] = ids.split(",");
|
||||
for(int i=0;i<id.length;i++){
|
||||
String index = id[i];
|
||||
Integer t = Integer.valueOf(index);
|
||||
int j = docSimpleMapper.deleteDocSimple(t);
|
||||
docSimpleMapper.deleteDocSimpleCascadeRecycle(t);
|
||||
if(j>0) {
|
||||
num = num + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
public int updateDocSimple(DocSimpleArrangeOa docSimpleArrange) {
|
||||
return docSimpleMapper.updateDocSimple(docSimpleArrange);
|
||||
}
|
||||
|
||||
public DocOriginalOaEntity queryDocOriginalEntityById(Integer id){
|
||||
return docSimpleMapper.queryDocOriginalEntityById(id);
|
||||
}
|
||||
|
||||
//下载文件url写法http://localhost:8081/ureport/pdf?_u=file:rr.ureport.xml&name=du,name值在第三个参数map里面
|
||||
public List docSimplePdf(String dataSourceName,String dataSetName,Map paramMap) {
|
||||
DocSimpleArrangeOa docSimpleArrange = new DocSimpleArrangeOa();
|
||||
docSimpleArrange.setFondsNo((String)paramMap.get("fondsNo"));
|
||||
docSimpleArrange.setFondsNoCode((String)paramMap.get("fondsNoCode"));
|
||||
List docSimpleArranges= docSimpleMapper.getDocSimpleWithPage(docSimpleArrange);
|
||||
return docSimpleArranges;
|
||||
}
|
||||
|
||||
public int getDocOriginalEntityCount(Integer recId) {
|
||||
return docSimpleMapper.getDocOriginalEntityCount(recId);
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void saveDocOriginalEntity(DocOriginalOaEntity docOriginalEntity) {
|
||||
docSimpleMapper.saveDocOriginalEntity(docOriginalEntity);
|
||||
}
|
||||
|
||||
public void saveDocOriginalJnEntity(DocOriginalOaEntity docOriginalEntity) {
|
||||
docSimpleMapper.saveDocOriginalJnEntity(docOriginalEntity);
|
||||
}
|
||||
|
||||
|
||||
public List queryDocOriginalEntity(Integer recId) {
|
||||
return docSimpleMapper.queryDocOriginalEntity(recId);
|
||||
}
|
||||
|
||||
|
||||
public int updateDocOriginalEntity(String ids){
|
||||
int num = 0;
|
||||
if(ids!=null && !"".equals(ids) && ids.length()>0){
|
||||
String id[] = ids.split(",");
|
||||
for(int i=0;i<id.length;i++){
|
||||
String index = id[i];
|
||||
Integer t = Integer.valueOf(index);
|
||||
int j = docSimpleMapper.updateDocOriginalEntity(t);
|
||||
if(j>0) {
|
||||
num = num + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
return num;
|
||||
|
||||
}
|
||||
|
||||
public List queryDocOriginalEntityRecycle(Integer recId) {
|
||||
return docSimpleMapper.queryDocOriginalEntityRecycle(recId);
|
||||
}
|
||||
|
||||
public void updateDocOriginalEntityRecycle(Integer id){
|
||||
docSimpleMapper.updateDocOriginalEntityRecycle(id);
|
||||
}
|
||||
|
||||
|
||||
public int deleteDocOriginalEntityRecycle(String ids) {
|
||||
int num = 0;
|
||||
if(ids!=null && !"".equals(ids) && ids.length()>0){
|
||||
String id[] = ids.split(",");
|
||||
for(int i=0;i<id.length;i++){
|
||||
String index = id[i];
|
||||
Integer t = Integer.valueOf(index);
|
||||
int j = docSimpleMapper.deleteDocOriginalEntityRecycle(t);
|
||||
if(j>0) {
|
||||
num = num + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
public void saveBatchDocSimple(MultipartFile file)throws Exception {
|
||||
String tableName = "wsda_20190528111300933_temp_oa";
|
||||
String fieldName = "case_no," +
|
||||
" mlh," +
|
||||
" archive_no," +
|
||||
" note ," +
|
||||
" pigeonhole_date," +
|
||||
" archive_ctg_no," +
|
||||
" archive_ctg_no_code," +
|
||||
" retention," +
|
||||
" retention_code," +
|
||||
" filing_year," +
|
||||
" fonds_no," +
|
||||
" fonds_no_code," +
|
||||
" sbt_word," +
|
||||
" doc_no," +
|
||||
" dagdm," +
|
||||
" dagdm_code," +
|
||||
" created_date," +
|
||||
" object_quantity," +
|
||||
" security_class," +
|
||||
" security_class_code," +
|
||||
" quantity," +
|
||||
" piece_no," +
|
||||
" kzbs," +
|
||||
" kzbs_code," +
|
||||
" folder_location," +
|
||||
" damldm," +
|
||||
" damldm_code," +
|
||||
" maintitle," +
|
||||
" responsibleby," +
|
||||
" create_person," +
|
||||
" create_date," +
|
||||
" is_packeep," +
|
||||
" is_packeep_code," +
|
||||
" md5_code," +
|
||||
" md5_check_date," +
|
||||
" batch_id," +
|
||||
" batch_name," +
|
||||
" back_to_update_state," +
|
||||
" is_process," +
|
||||
" testtest_code," +
|
||||
" archive_file_num," +
|
||||
" departname," +
|
||||
" departname_code," +
|
||||
" lb," +
|
||||
" lb_code," +
|
||||
" lm," +
|
||||
" lm_code," +
|
||||
" archive_flag";
|
||||
InputStream in = file.getInputStream();
|
||||
Workbook boxExcel = Workbook.getWorkbook(in);
|
||||
Sheet boxSheet = boxExcel.getSheet(0);
|
||||
for (int i = 1; i < boxSheet.getRows(); i++) {
|
||||
StringBuffer valueNameBuffer = new StringBuffer();
|
||||
Map map = new HashMap();
|
||||
for (int j = 0; j <boxSheet.getColumns(); j++) {
|
||||
Cell boxCell = boxSheet.getCell(j, i);
|
||||
String val = boxCell.getContents();
|
||||
if("".equals(val))val=null;
|
||||
if(j==0)valueNameBuffer.append(val);
|
||||
else valueNameBuffer.append(","+val);
|
||||
}
|
||||
String valueName = valueNameBuffer.toString();
|
||||
map.put("tableName", tableName);
|
||||
map.put("fieldName", fieldName);
|
||||
map.put("valueName", valueName);
|
||||
docSimpleMapper.saveBatchDocSimple(map);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,201 @@
|
||||
package com.point.strategy.oaDocking.service;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.point.strategy.docTraditionArrange.docFile.bean.DocFileOriginalEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocTraditionArrangeFileOa;
|
||||
import com.point.strategy.oaDocking.mapper.DocTraditionFileOaMapper;
|
||||
import jxl.Cell;
|
||||
import jxl.Sheet;
|
||||
import jxl.Workbook;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.InputStream;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
//文书案卷
|
||||
@Service
|
||||
@Transactional
|
||||
public class DocTraditionFileOaService {
|
||||
@Autowired
|
||||
public DocTraditionFileOaMapper docTraditionFileMapper;
|
||||
|
||||
public List getDocFileWithPage(DocTraditionArrangeFileOa docTraditionArrangeFile) {
|
||||
PageHelper.startPage(docTraditionArrangeFile.getPage(), docTraditionArrangeFile.getLimit());
|
||||
List docFiles= docTraditionFileMapper.getDocFileWithPage(docTraditionArrangeFile);
|
||||
return docFiles;
|
||||
}
|
||||
|
||||
public int saveDocFile(DocTraditionArrangeFileOa docTraditionArrangeFile) {
|
||||
return docTraditionFileMapper.saveDocFile(docTraditionArrangeFile);
|
||||
}
|
||||
|
||||
public int deleteDocFile(String ids) {
|
||||
int num = 0;
|
||||
if(ids!=null && !"".equals(ids) && ids.length()>0){
|
||||
String id[] = ids.split(",");
|
||||
for(int i=0;i<id.length;i++){
|
||||
String index = id[i];
|
||||
Integer t = Integer.valueOf(index);
|
||||
int j = docTraditionFileMapper.deleteDocFile(t);
|
||||
// docTraditionFileMapper.deleteDocFileCascadeRecycle(t);
|
||||
if(j>0) {
|
||||
num = num + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
public int updateDocFile(DocTraditionArrangeFileOa docTraditionArrangeFile) {
|
||||
return docTraditionFileMapper.updateDocFile(docTraditionArrangeFile);
|
||||
}
|
||||
|
||||
//下载文件url写法http://localhost:8081/ureport/pdf?_u=file:rr.ureport.xml&name=du,name值在第三个参数map里面
|
||||
public List docFilePdf(String dataSourceName,String dataSetName,Map paramMap) {
|
||||
DocTraditionArrangeFileOa docTraditionArrangeFile = new DocTraditionArrangeFileOa();
|
||||
docTraditionArrangeFile.setFondsNo((String)paramMap.get("fondsNo"));
|
||||
docTraditionArrangeFile.setFondsNoCode((String)paramMap.get("fondsNoCode"));
|
||||
List docFiles= docTraditionFileMapper.getDocFileWithPage(docTraditionArrangeFile);
|
||||
return docFiles;
|
||||
}
|
||||
|
||||
public int getDocFileOriginalEntityCount(Integer recId) {
|
||||
return docTraditionFileMapper.getDocFileOriginalEntityCount(recId);
|
||||
}
|
||||
|
||||
public void saveDocFileOriginalEntity(DocFileOriginalEntity docFileOriginalEntity) {
|
||||
docTraditionFileMapper.saveDocFileOriginalEntity(docFileOriginalEntity);
|
||||
}
|
||||
|
||||
public List queryDocFileOriginalEntity(Integer recId) {
|
||||
return docTraditionFileMapper.queryDocFileOriginalEntity(recId);
|
||||
}
|
||||
|
||||
|
||||
public void updateDocFileOriginalEntity(Integer id){
|
||||
docTraditionFileMapper.updateDocFileOriginalEntity(id);
|
||||
}
|
||||
|
||||
|
||||
public List queryDocFileOriginalEntityRecycle(Map<String,Object> map) {
|
||||
return docTraditionFileMapper.queryDocFileOriginalEntityRecycle(map);
|
||||
}
|
||||
|
||||
public List queryDocFileOriginalEntityRecycle(Integer recId) {
|
||||
return docTraditionFileMapper.queryDocFileOriginalEntityRecycle(recId);
|
||||
}
|
||||
|
||||
public void updateDocFileOriginalEntityRecycle(Integer id){
|
||||
docTraditionFileMapper.updateDocFileOriginalEntityRecycle(id);
|
||||
}
|
||||
|
||||
|
||||
public int deleteDocFileOriginalEntityRecycle(String ids) {
|
||||
int num = 0;
|
||||
if(ids!=null && !"".equals(ids) && ids.length()>0){
|
||||
String id[] = ids.split(",");
|
||||
for(int i=0;i<id.length;i++){
|
||||
String index = id[i];
|
||||
Integer t = Integer.valueOf(index);
|
||||
int j = docTraditionFileMapper.deleteDocFileOriginalEntityRecycle(t);
|
||||
if(j>0) {
|
||||
num = num + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
public void saveBatchDocFiles(MultipartFile file)throws Exception {
|
||||
String tableName = "wsajml_20201104084106585_temp_oa";
|
||||
String fieldName = "folder_no," +
|
||||
"js," +
|
||||
"folder_location," +
|
||||
"maintitle," +
|
||||
"security_class," +
|
||||
"security_class_code," +
|
||||
"fonds_no," +
|
||||
"fonds_no_code," +
|
||||
"filing_year," +
|
||||
"retention," +
|
||||
"retention_code," +
|
||||
"archive_ctg_no," +
|
||||
"archive_ctg_no_code," +
|
||||
"year_folder_no," +
|
||||
"quantity," +
|
||||
"doc_start_time," +
|
||||
"doc_end_time," +
|
||||
"sbt_word," +
|
||||
"pigeonhole_date," +
|
||||
"note," +
|
||||
"mlh," +
|
||||
"sssq," +
|
||||
"sssq_code," +
|
||||
"dagdm," +
|
||||
"dagdm_code," +
|
||||
"zqbs," +
|
||||
"zqbs_code," +
|
||||
"kzbs," +
|
||||
"kzbs_code," +
|
||||
"damldm," +
|
||||
"damldm_code," +
|
||||
"create_person," +
|
||||
"create_date," +
|
||||
"archive_flag," +
|
||||
"is_packeep," +
|
||||
"is_packeep_code," +
|
||||
"md5_code," +
|
||||
"md5_check_date," +
|
||||
"batch_id," +
|
||||
"batch_name," +
|
||||
"back_to_update_state," +
|
||||
"is_process," +
|
||||
"archive_entity_status";
|
||||
InputStream in = file.getInputStream();
|
||||
Workbook boxExcel = Workbook.getWorkbook(in);
|
||||
Sheet boxSheet = boxExcel.getSheet(0);
|
||||
for (int i = 1; i < boxSheet.getRows(); i++) {
|
||||
StringBuffer valueNameBuffer = new StringBuffer();
|
||||
Map map = new HashMap();
|
||||
for (int j = 0; j <boxSheet.getColumns(); j++) {
|
||||
Cell boxCell = boxSheet.getCell(j, i);
|
||||
String val = boxCell.getContents();
|
||||
// if("".equals(val))val=null; SQL语句需要加上'(单引号)
|
||||
if(j==0)valueNameBuffer.append("'"+val+"'");
|
||||
else valueNameBuffer.append(",'"+val+"'");
|
||||
}
|
||||
String valueName = valueNameBuffer.toString();
|
||||
map.put("tableName", tableName);
|
||||
map.put("fieldName", fieldName);
|
||||
map.put("valueName", valueName);
|
||||
docTraditionFileMapper.saveBatchDocFiles(map);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新文书传统案卷原文文件
|
||||
* @param entity
|
||||
*/
|
||||
public void updateTempFile(DocFileOriginalEntity entity){
|
||||
docTraditionFileMapper.updateTempFile(entity);
|
||||
}
|
||||
//更新档案文件数量
|
||||
public void wsajmlTempCount(Integer id){
|
||||
docTraditionFileMapper.wsajmlTempCount(id);
|
||||
}
|
||||
//案卷-查询文件对象
|
||||
public DocFileOriginalEntity selectFileOneById(Integer id){
|
||||
return docTraditionFileMapper.selectFileOneById(id);
|
||||
}
|
||||
|
||||
//删除卷内文件
|
||||
public int deleteDocFileCascadeRecycle(Integer recid) {
|
||||
return docTraditionFileMapper.deleteDocFileCascadeRecycle(recid);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,221 @@
|
||||
package com.point.strategy.oaDocking.service;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.point.strategy.common.AjaxJson;
|
||||
import com.point.strategy.docTraditionArrange.docVolume.bean.DocVolumeOriginalEntity;
|
||||
import com.point.strategy.oaDocking.bean.DocTraditionArrangeOaVolume;
|
||||
import com.point.strategy.oaDocking.bean.DocVolumeOriginalOaEntity;
|
||||
import com.point.strategy.oaDocking.mapper.DocTraditionVolumeOaMapper;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import jxl.Cell;
|
||||
import jxl.Sheet;
|
||||
import jxl.Workbook;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.InputStream;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
//文书卷内
|
||||
@Service
|
||||
@Transactional
|
||||
public class DocTraditionVolumeOaService {
|
||||
@Autowired
|
||||
public DocTraditionVolumeOaMapper docTraditionVolumeMapper;
|
||||
|
||||
public List getDocVolumeWithPage(DocTraditionArrangeOaVolume docTraditionArrangeVolume) {
|
||||
PageHelper.startPage(docTraditionArrangeVolume.getPage(), docTraditionArrangeVolume.getLimit());
|
||||
List docVolumes= docTraditionVolumeMapper.getDocVolumeWithPage(docTraditionArrangeVolume);
|
||||
return docVolumes;
|
||||
}
|
||||
|
||||
public int saveDocVolume(DocTraditionArrangeOaVolume docTraditionArrangeVolume) {
|
||||
return docTraditionVolumeMapper.saveDocVolume(docTraditionArrangeVolume);
|
||||
}
|
||||
|
||||
public int deleteDocVolume(String ids) {
|
||||
int num = 0;
|
||||
if(ids!=null && !"".equals(ids) && ids.length()>0){
|
||||
String id[] = ids.split(",");
|
||||
for(int i=0;i<id.length;i++){
|
||||
String index = id[i];
|
||||
Integer t = Integer.valueOf(index);
|
||||
int j = docTraditionVolumeMapper.deleteDocVolume(t);
|
||||
docTraditionVolumeMapper.deleteDocVolumeCascadeRecycle(t);
|
||||
if(j>0) {
|
||||
num = num + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
public int updateDocVolume(DocTraditionArrangeOaVolume docTraditionArrangeVolume) {
|
||||
return docTraditionVolumeMapper.updateDocVolume(docTraditionArrangeVolume);
|
||||
}
|
||||
|
||||
//下载文件url写法http://localhost:8081/ureport/pdf?_u=file:rr.ureport.xml&name=du,name值在第三个参数map里面
|
||||
public List docVolumePdf(String dataSourceName,String dataSetName,Map paramMap) {
|
||||
DocTraditionArrangeOaVolume docTraditionArrangeVolume = new DocTraditionArrangeOaVolume();
|
||||
docTraditionArrangeVolume.setFondsNo((String)paramMap.get("fondsNo"));
|
||||
docTraditionArrangeVolume.setFondsNoCode((String)paramMap.get("fondsNoCode"));
|
||||
List docVolumes= docTraditionVolumeMapper.getDocVolumeWithPage(docTraditionArrangeVolume);
|
||||
return docVolumes;
|
||||
}
|
||||
|
||||
public int getDocVolumeOriginalEntityCount(Integer recId) {
|
||||
return docTraditionVolumeMapper.getDocVolumeOriginalEntityCount(recId);
|
||||
}
|
||||
|
||||
public void saveDocVolumeOriginalEntity(DocVolumeOriginalOaEntity docVolumeOriginalEntity) {
|
||||
docTraditionVolumeMapper.saveDocVolumeOriginalEntity(docVolumeOriginalEntity);
|
||||
}
|
||||
|
||||
public List queryDocVolumeOriginalEntity(Integer recId) {
|
||||
return docTraditionVolumeMapper.queryDocVolumeOriginalEntity(recId);
|
||||
}
|
||||
|
||||
|
||||
public void updateDocVolumeOriginalEntity(Integer id){
|
||||
docTraditionVolumeMapper.updateDocVolumeOriginalEntity(id);
|
||||
}
|
||||
|
||||
public List queryDocVolumeOriginalEntityRecycle(Integer recId) {
|
||||
return docTraditionVolumeMapper.queryDocVolumeOriginalEntityRecycle(recId);
|
||||
}
|
||||
|
||||
public List queryDocVolumeOriginalEntityRecycle2(Map<String,Object> map) {
|
||||
return docTraditionVolumeMapper.queryDocVolumeOriginalEntityRecycle2(map);
|
||||
}
|
||||
|
||||
public void updateDocVolumeOriginalEntityRecycle(Integer id){
|
||||
docTraditionVolumeMapper.updateDocVolumeOriginalEntityRecycle(id);
|
||||
}
|
||||
|
||||
|
||||
public int deleteDocVolumeOriginalEntityRecycle(String ids) {
|
||||
int num = 0;
|
||||
if(ids!=null && !"".equals(ids) && ids.length()>0){
|
||||
String id[] = ids.split(",");
|
||||
for(int i=0;i<id.length;i++){
|
||||
String index = id[i];
|
||||
Integer t = Integer.valueOf(index);
|
||||
int j = docTraditionVolumeMapper.deleteDocVolumeOriginalEntityRecycle(t);
|
||||
if(j>0) {
|
||||
num = num + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
public void saveBatchDocVolumes(MultipartFile file)throws Exception {
|
||||
String tableName = "wsjnml_20201104084119220_temp_oa";
|
||||
String fieldName = "archive_no," +
|
||||
"folder_no," +
|
||||
"maintitle," +
|
||||
"created_date," +
|
||||
"doc_no," +
|
||||
"security_class," +
|
||||
"security_class_code," +
|
||||
"fonds_no," +
|
||||
"fonds_no_code," +
|
||||
"filing_year," +
|
||||
"retention," +
|
||||
"retention_code," +
|
||||
"archive_ctg_no," +
|
||||
"archive_ctg_no_code," +
|
||||
"year_folder_no," +
|
||||
"page_no," +
|
||||
"piece_no," +
|
||||
"quantity," +
|
||||
"responsibleby," +
|
||||
"sbt_word," +
|
||||
"folder_location," +
|
||||
"pigeonhole_date," +
|
||||
"note," +
|
||||
"object_quantity," +
|
||||
"page_no_end," +
|
||||
"mlh," +
|
||||
"sssq," +
|
||||
"sssq_code," +
|
||||
"dagdm," +
|
||||
"dagdm_code," +
|
||||
"kzbs," +
|
||||
"kzbs_code," +
|
||||
"zqbs," +
|
||||
"zqbs_code," +
|
||||
"damldm," +
|
||||
"damldm_code," +
|
||||
"report_page," +
|
||||
"pid," +
|
||||
"create_person," +
|
||||
"create_date," +
|
||||
"archive_flag," +
|
||||
"is_packeep," +
|
||||
"is_packeep_code," +
|
||||
"md5_code," +
|
||||
"md5_check_date," +
|
||||
"batch_id," +
|
||||
"batch_name," +
|
||||
"back_to_update_state," +
|
||||
"is_process," +
|
||||
"archive_entity_status," +
|
||||
"archive_zjbs," +
|
||||
"temp_no";
|
||||
InputStream in = file.getInputStream();
|
||||
Workbook boxExcel = Workbook.getWorkbook(in);
|
||||
Sheet boxSheet = boxExcel.getSheet(0);
|
||||
for (int i = 1; i < boxSheet.getRows(); i++) {
|
||||
StringBuffer valueNameBuffer = new StringBuffer();
|
||||
Map map = new HashMap();
|
||||
for (int j = 0; j <boxSheet.getColumns(); j++) {
|
||||
Cell boxCell = boxSheet.getCell(j, i);
|
||||
String val = boxCell.getContents();
|
||||
// if("".equals(val))val=null; SQL语句需要加上'(单引号)
|
||||
if(j==0)valueNameBuffer.append("'"+val+"'");
|
||||
else valueNameBuffer.append(",'"+val+"'");
|
||||
}
|
||||
String valueName = valueNameBuffer.toString();
|
||||
map.put("tableName", tableName);
|
||||
map.put("fieldName", fieldName);
|
||||
map.put("valueName", valueName);
|
||||
docTraditionVolumeMapper.saveBatchDocVolumes(map);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新文书传统卷内原文文件
|
||||
* @param entity
|
||||
*/
|
||||
public void updateTempFile(DocVolumeOriginalEntity entity){
|
||||
docTraditionVolumeMapper.updateTempFile(entity);
|
||||
}
|
||||
|
||||
//卷内-更新档案文件数量
|
||||
public void wsjnmlTempCount(Integer id){
|
||||
docTraditionVolumeMapper.wsjnmlTempCount(id);
|
||||
}
|
||||
|
||||
//卷内-查询文件id
|
||||
public DocVolumeOriginalEntity selectFileOneById(Integer id){
|
||||
return docTraditionVolumeMapper.selectFileOneById(id);
|
||||
}
|
||||
|
||||
public int deleteDocVolumeCascadeRecycle(Integer recid) {
|
||||
return docTraditionVolumeMapper.deleteDocVolumeCascadeRecycle(recid);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,110 @@
|
||||
package com.point.strategy.oaDocking.service;
|
||||
|
||||
import com.point.strategy.common.Base64Utils;
|
||||
import com.point.strategy.common.SystemProperty;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
import java.sql.*;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
public class YcjSystemIntegration {
|
||||
private static final Logger LOGGER = Logger.getLogger(YcjSystemIntegration.class.getName());
|
||||
|
||||
private static final String driver_dm = SystemProperty.getKeyValue("ycj.driverClassName", "application.properties");
|
||||
private static final String url = SystemProperty.getKeyValue("ycj.url", "application.properties");
|
||||
private static final String user = SystemProperty.getKeyValue("ycj.username", "application.properties");
|
||||
private static final String password = SystemProperty.getKeyValue("ycj.password", "application.properties");
|
||||
|
||||
// 获取数据库连接
|
||||
private static Connection getConnection() throws Exception {
|
||||
Class.forName(driver_dm);
|
||||
return DriverManager.getConnection(url, user, password);
|
||||
}
|
||||
|
||||
// 查询
|
||||
public static ResultSet executeQuery(String sql) throws Exception {
|
||||
Connection conn = null;
|
||||
Statement st = null;
|
||||
try {
|
||||
conn = getConnection();
|
||||
st = conn.createStatement();
|
||||
return st.executeQuery(sql);
|
||||
} catch (Exception e) {
|
||||
LOGGER.log(Level.SEVERE, "执行查询时出错: " + sql, e);
|
||||
closeResources(conn, st, null);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
// 修改
|
||||
public static int executeUpdate(String sql) throws Exception {
|
||||
Connection conn = null;
|
||||
Statement st = null;
|
||||
try {
|
||||
conn = getConnection();
|
||||
st = conn.createStatement();
|
||||
return st.executeUpdate(sql);
|
||||
} catch (Exception e) {
|
||||
LOGGER.log(Level.SEVERE, "执行更新时出错: " + sql, e);
|
||||
throw e;
|
||||
} finally {
|
||||
closeResources(conn, st, null);
|
||||
}
|
||||
}
|
||||
|
||||
// 关闭资源
|
||||
public static void closeResources(Connection conn, Statement st, ResultSet rs) {
|
||||
try {
|
||||
if (rs != null) rs.close();
|
||||
if (st != null) st.close();
|
||||
if (conn != null) conn.close();
|
||||
} catch (Exception e) {
|
||||
LOGGER.log(Level.WARNING, "关闭资源时出错", e);
|
||||
}
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
// Connection conn = null;
|
||||
// Statement st = null;
|
||||
// ResultSet resultSet = null;
|
||||
// try {
|
||||
//
|
||||
// String imageBytes = Base64Utils.encode2("D:\\2\\222.pdf");
|
||||
// conn = getConnection();
|
||||
// String sql = "INSERT INTO fujian (fawen_index,fujian_id,sound_image) VALUES (?,?,?)";
|
||||
// PreparedStatement pstmt = conn.prepareStatement(sql);
|
||||
// pstmt.setInt(1, 1);
|
||||
// pstmt.setInt(2, 5);
|
||||
// pstmt.setString(3, imageBytes);
|
||||
// pstmt.executeUpdate();
|
||||
//
|
||||
// System.out.println("图像已成功转换为longblob并存储到数据库。");
|
||||
// } catch (Exception e) {
|
||||
// e.printStackTrace();
|
||||
// }
|
||||
|
||||
|
||||
Connection conn = null;
|
||||
Statement st = null;
|
||||
ResultSet resultSet = null;
|
||||
try (FileInputStream fis = new FileInputStream(new File("D:\\2\\222.pdf"))) {
|
||||
|
||||
byte[] imageBytes = new byte[(int) new File("D:\\2\\222.pdf").length()];
|
||||
fis.read(imageBytes);
|
||||
conn = getConnection();
|
||||
String sql = "INSERT INTO fujian (fawen_index,fujian_id,sound_image) VALUES (?,?,?)";
|
||||
PreparedStatement pstmt = conn.prepareStatement(sql);
|
||||
pstmt.setInt(1, 1);
|
||||
pstmt.setInt(2, 3);
|
||||
pstmt.setBytes(3, imageBytes);
|
||||
pstmt.executeUpdate();
|
||||
|
||||
System.out.println("图像已成功转换为longblob并存储到数据库。");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
40
src/main/java/com/point/strategy/oaDocking/util/Duwenyi.java
Normal file
40
src/main/java/com/point/strategy/oaDocking/util/Duwenyi.java
Normal file
@@ -0,0 +1,40 @@
|
||||
package com.point.strategy.oaDocking.util;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.parsers.DocumentBuilder;
|
||||
import javax.xml.parsers.DocumentBuilderFactory;
|
||||
import javax.xml.parsers.ParserConfigurationException;
|
||||
|
||||
import org.apache.tools.zip.ZipEntry;
|
||||
import org.apache.tools.zip.ZipFile;
|
||||
import org.w3c.dom.Document;
|
||||
import org.w3c.dom.NodeList;
|
||||
import org.xml.sax.SAXException;
|
||||
|
||||
public class Duwenyi {
|
||||
|
||||
public static void main(String[] args) throws IOException, ParserConfigurationException, SAXException {
|
||||
// TODO Auto-generated method stub
|
||||
String base64 = FileUtils.GetZipStr("C:\\Users\\Administrator\\Desktop\\典策\\webservice归档接口文档2020(1)\\webservice接口文档\\测试zip包\\简化模板.zip");
|
||||
System.out.println(base64);
|
||||
File file = FileUtils.base64ToFile(base64);
|
||||
ZipFile zipFile = new ZipFile(file,"gbk");
|
||||
List<ZipEntry> zipEntrys = FileUtils.unzip(zipFile);
|
||||
for (ZipEntry zipEntry : zipEntrys) {
|
||||
String entryName = zipEntry.getName();
|
||||
|
||||
//以/进行分割
|
||||
String[] ss = entryName.split("\\/");
|
||||
//以点进行分割
|
||||
String[] spots = entryName.split("\\.");
|
||||
//System.out.println(entryName);
|
||||
|
||||
if(ss[ss.length-1].equals("基本信息描述.xml")){}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
300
src/main/java/com/point/strategy/oaDocking/util/FileUtils.java
Normal file
300
src/main/java/com/point/strategy/oaDocking/util/FileUtils.java
Normal file
@@ -0,0 +1,300 @@
|
||||
package com.point.strategy.oaDocking.util;
|
||||
|
||||
import cn.hutool.core.codec.Base64;
|
||||
import cn.hutool.core.io.FileTypeUtil;
|
||||
import cn.hutool.core.io.FileUtil;
|
||||
import com.point.strategy.common.StringUtil;
|
||||
import com.point.strategy.oaDocking.bean.UploadFileEntity;
|
||||
import org.apache.tools.zip.ZipEntry;
|
||||
import org.apache.tools.zip.ZipFile;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.w3c.dom.Node;
|
||||
import org.w3c.dom.NodeList;
|
||||
import sun.misc.BASE64Decoder;
|
||||
import sun.misc.BASE64Encoder;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Enumeration;
|
||||
import java.util.List;
|
||||
|
||||
public class FileUtils {
|
||||
public static UploadFileEntity writeToHardDisk(MultipartFile file, String writePath) throws IOException {
|
||||
|
||||
//写入路径
|
||||
StringBuilder hardPath = new StringBuilder(writePath);
|
||||
|
||||
//文件名字 带扩展名
|
||||
String originalfileName = file.getOriginalFilename();//原始名称
|
||||
|
||||
hardPath.append(TimeUtil.getNowTimeString());
|
||||
hardPath.append(originalfileName);
|
||||
|
||||
//创建目录 存在则直接返回该目录
|
||||
FileUtil.mkdir(writePath);
|
||||
File dest = new File(hardPath.toString());
|
||||
file.transferTo(dest);//写文件
|
||||
|
||||
|
||||
File f = FileUtil.file(dest);
|
||||
String type = FileTypeUtil.getType(f);
|
||||
String name = FileUtil.mainName(f);//文件名 不带扩展名
|
||||
|
||||
UploadFileEntity ufe = new UploadFileEntity();
|
||||
ufe.setOriginalfileName(originalfileName);//设置原始名称
|
||||
ufe.setFileFullName(f.getName());//设置新名称
|
||||
ufe.setFileName(name);//设置文件名 没有扩展名
|
||||
ufe.setFimeType(type);//设置文件类型
|
||||
ufe.setFileSize(file.getSize()/1024);//KB大小
|
||||
ufe.setFileHardPath(hardPath.toString());//
|
||||
ufe.setFilePath(writePath);
|
||||
|
||||
return ufe;
|
||||
}
|
||||
|
||||
/**
|
||||
* 把文件写入到磁盘
|
||||
* @param file
|
||||
* @param writePath 写入路径,格式为:d:/report/path/
|
||||
* @return
|
||||
* @throws IOException
|
||||
*/
|
||||
public static UploadFileEntity writeToHardDisk2(MultipartFile file, String writePath) {
|
||||
UploadFileEntity ufe = null;
|
||||
try {
|
||||
//写入路径
|
||||
StringBuilder hardPath = new StringBuilder(writePath);
|
||||
//文件名字 带扩展名
|
||||
String originalfileName = file.getOriginalFilename();//原始名称
|
||||
//设置原始名称 没有扩展名
|
||||
String originalfileNameNotExtension=originalfileName.substring(0,originalfileName.indexOf("."));
|
||||
String extension=originalfileName.substring(originalfileName.indexOf(".")+1,originalfileName.length());
|
||||
hardPath.append(StringUtil.generaterUUID()+"."+extension);
|
||||
//创建目录 存在则直接返回该目录
|
||||
FileUtil.mkdir(writePath);
|
||||
File dest = new File(hardPath.toString());
|
||||
file.transferTo(dest);//写文件
|
||||
File f = FileUtil.file(dest);
|
||||
String type = FileTypeUtil.getType(f);
|
||||
String name = FileUtil.mainName(f);//文件名 不带扩展名
|
||||
ufe = new UploadFileEntity();
|
||||
ufe.setOriginalfileName(originalfileName);//设置原始名称
|
||||
ufe.setOriginalfileNameNotExtension(originalfileNameNotExtension); //设置原始名称 没有扩展名
|
||||
ufe.setFileFullName(f.getName());//设置新名称
|
||||
ufe.setFileName(name);//设置文件名 没有扩展名
|
||||
ufe.setFimeType(type);//设置文件类型
|
||||
ufe.setFileSize(file.getSize() / 1024);//KB大小
|
||||
ufe.setFileHardPath(hardPath.toString());//
|
||||
ufe.setFilePath(writePath);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
}
|
||||
return ufe;
|
||||
}
|
||||
|
||||
/**
|
||||
* 解压zip包
|
||||
* */
|
||||
public static void unzip(String source,String target) throws IOException {
|
||||
unzip(new File(source),target);
|
||||
}
|
||||
|
||||
public static String unzip(File source,String target) throws IOException {
|
||||
InputStream inputStream = null;
|
||||
OutputStream outputStream = null;
|
||||
File targetFile = new File(target);
|
||||
if(!targetFile.exists()){
|
||||
targetFile.mkdirs();
|
||||
}
|
||||
//解决文件名乱码问题
|
||||
ZipFile zipFile = new ZipFile(source,"gbk");
|
||||
for(Enumeration entries = zipFile.getEntries(); entries.hasMoreElements();){
|
||||
ZipEntry zipEntry = (ZipEntry) entries.nextElement();
|
||||
String entryName = zipEntry.getName();
|
||||
String[] ss = entryName.split("\\.");
|
||||
System.out.println(entryName);
|
||||
System.out.println(entryName.indexOf("案卷模板/2/")!=-1);
|
||||
inputStream = zipFile.getInputStream(zipEntry);
|
||||
String outPath = (target+"/"+entryName).replaceAll("\\*","/");
|
||||
File file = new File(outPath.substring(0,outPath.lastIndexOf("/")));
|
||||
if(!file.exists()){
|
||||
file.mkdirs();
|
||||
}
|
||||
if(new File(outPath).isDirectory()){
|
||||
continue;
|
||||
}
|
||||
outputStream = new FileOutputStream(outPath);
|
||||
byte[] bytes = new byte[1024];
|
||||
int length;
|
||||
while ((length = inputStream.read(bytes))>0){
|
||||
outputStream.write(bytes,0,length);
|
||||
}
|
||||
}
|
||||
outputStream.flush();
|
||||
outputStream.close();
|
||||
inputStream.close();
|
||||
zipFile.close();
|
||||
System.gc();
|
||||
return "success";
|
||||
}
|
||||
public static List<ZipEntry> unzip(ZipFile zipFile) throws IOException {
|
||||
|
||||
//解决文件名乱码问题
|
||||
// ZipFile zipFile = new ZipFile(source,"gbk");
|
||||
List<ZipEntry> zipEntries = new ArrayList<>();
|
||||
for(Enumeration entries = zipFile.getEntries(); entries.hasMoreElements();){
|
||||
ZipEntry zipEntry = (ZipEntry) entries.nextElement();
|
||||
zipEntries.add(zipEntry);
|
||||
|
||||
}
|
||||
zipFile.close();
|
||||
System.gc();
|
||||
return zipEntries;
|
||||
}
|
||||
|
||||
//获取文件里面所有的内容
|
||||
public static void readFiles(String inputFile) throws Exception {
|
||||
File srcFile = new File(inputFile);
|
||||
if (srcFile.isDirectory()) {
|
||||
File next[] = srcFile.listFiles();
|
||||
for (int i = 0; i < next.length; i++) {
|
||||
System.out.println(next[i].getName());
|
||||
if(!next[i].isDirectory()){
|
||||
BufferedReader br = new BufferedReader(new FileReader(next[i]));
|
||||
List<String> arr1 = new ArrayList<>();
|
||||
String contentLine ;
|
||||
while ((contentLine = br.readLine()) != null) {
|
||||
// JSONObject js = JSONObject.parseObject(contentLine);
|
||||
arr1.add(contentLine);
|
||||
}
|
||||
System.out.println(arr1);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
//base64字符串转文件
|
||||
public static File base64ToFile(String base64) {
|
||||
if(base64==null||"".equals(base64)) {
|
||||
return null;
|
||||
}
|
||||
byte[] buff= Base64.decode(base64);
|
||||
File file=null;
|
||||
FileOutputStream fout=null;
|
||||
try {
|
||||
file = File.createTempFile("tmp", null);
|
||||
fout=new FileOutputStream(file);
|
||||
fout.write(buff);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}finally {
|
||||
if(fout!=null) {
|
||||
try {
|
||||
fout.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
return file;
|
||||
}
|
||||
/**
|
||||
* 将文件转化为字节数组字符串,并对其进行Base64编码处理
|
||||
* @param zipFile
|
||||
* @return
|
||||
*/
|
||||
public static String GetZipStr(String zipFile) {
|
||||
InputStream in = null;
|
||||
byte[] data = null;
|
||||
// 读取文件字节数组
|
||||
try {
|
||||
in = new FileInputStream(zipFile);
|
||||
data = new byte[in.available()];
|
||||
in.read(data);
|
||||
in.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
// 对字节数组Base64编码
|
||||
BASE64Encoder encoder = new BASE64Encoder();
|
||||
// 返回Base64编码过的字节数组字符串
|
||||
return encoder.encode(data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据字节数组字符串进行Base64解码并生成文件
|
||||
* @param imgStr
|
||||
* @param savedImagePath
|
||||
* @return
|
||||
*/
|
||||
public static boolean GenerateZip(String imgStr, String savedImagePath) {
|
||||
// 文件字节数组字符串数据为空
|
||||
if (imgStr == null)
|
||||
return false;
|
||||
BASE64Decoder decoder = new BASE64Decoder();
|
||||
try {
|
||||
// Base64解码
|
||||
byte[] b = decoder.decodeBuffer(imgStr);
|
||||
for (int i = 0; i < b.length; ++i) {
|
||||
{// 调整异常数据
|
||||
if (b[i] < 0)
|
||||
b[i] += 256;
|
||||
}
|
||||
}
|
||||
// 生成文件
|
||||
// String sangImageStr = "D:/My Documents/ip.jpg" ; // 要生成文件的路径.
|
||||
OutputStream out = new FileOutputStream(savedImagePath);
|
||||
out.write(b);
|
||||
out.flush();
|
||||
out.close();
|
||||
return true;
|
||||
} catch (Exception e) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
//解析xml
|
||||
public static void node(NodeList list){
|
||||
for (int i = 0; i <list.getLength() ; i++) {
|
||||
Node node = list.item(i);
|
||||
NodeList childNodes = node.getChildNodes();
|
||||
for (int j = 0; j <childNodes.getLength() ; j++) {
|
||||
if (childNodes.item(j).getNodeType()==Node.ELEMENT_NODE) {
|
||||
System.out.print(childNodes.item(j).getNodeName() + ":");
|
||||
System.out.println(childNodes.item(j).getFirstChild().getNodeValue());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
//1.创建DocumentBuilderFactory对象
|
||||
// DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
|
||||
// //2.创建DocumentBuilder对象
|
||||
// try {
|
||||
// DocumentBuilder builder = factory.newDocumentBuilder();
|
||||
// Document d = builder.parse("file:///E:/案卷基本信息.xml");
|
||||
// //通过输入流进行解析
|
||||
//// InputStream stream = new ByteArrayInputStream(buffer.toString().getBytes());
|
||||
//// Document document = db.parse(stream);
|
||||
// NodeList sList = d.getElementsByTagName("description");
|
||||
// node(sList);
|
||||
// } catch (Exception e) {
|
||||
// e.printStackTrace();
|
||||
// }
|
||||
String str = GetZipStr("E:/arc/archives/简化模板.zip");
|
||||
System.out.println(str);
|
||||
File file = base64ToFile(str);
|
||||
try {
|
||||
unzip(file,"E:/arc/archives/");
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
System.out.println(file);
|
||||
// boolean flag = GenerateZip(str, "E:/arc/archives/20210302163847案卷模板B.zip");
|
||||
// System.out.println(flag);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
package com.point.strategy.oaDocking.util;
|
||||
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
|
||||
public class TimeUtil {
|
||||
|
||||
/**
|
||||
* 返回字符串时间格式:2020-12-16 10:11:48
|
||||
* */
|
||||
public static String getNowTime(){
|
||||
return DateUtil.now();//2020-12-16 10:11:48
|
||||
}
|
||||
|
||||
/**
|
||||
* 返回字符串时间格式:20201216101448
|
||||
* */
|
||||
public static String getNowTimeString(){
|
||||
return DateUtil.now().replace("-","").replace(":","").replace(" ","");
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
System.out.println(TimeUtil.getNowTimeString());
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user