11.24 异步操作添加 导出字段删除 查询修改
This commit is contained in:
+13
@@ -161,4 +161,17 @@ public class SarStandAttrDetailsController extends BaseController<SarStandAttrDe
|
|||||||
public ResponseMessage<List<SelectionResult>> selectFileFieldForSel1(){
|
public ResponseMessage<List<SelectionResult>> selectFileFieldForSel1(){
|
||||||
return Result.success(sarStandAttrDetailsEOService.selectFileFieldForSel1(null));
|
return Result.success(sarStandAttrDetailsEOService.selectFileFieldForSel1(null));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "|SarStandAttrDetailsEO|查询标准中所有文件类型")
|
||||||
|
@GetMapping("/getListData")
|
||||||
|
// @RequiresPermissions("lawss:sarStandAttrDetails:get")
|
||||||
|
public ResponseMessage<List<SarStandAttrDetails>> getListData(){
|
||||||
|
QueryWrapper<SarStandAttrDetails> queryWrapper=new QueryWrapper<>();
|
||||||
|
queryWrapper.eq("ATTR_TYPE","file");
|
||||||
|
List<SarStandAttrDetails> sarStandAttrDetails=sarStandAttrDetailsEOService.list(queryWrapper);
|
||||||
|
return Result.success(sarStandAttrDetails);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,12 @@
|
|||||||
|
package com.adc.da.slrs.sarStandAttrDetails.entity;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class listDTO {
|
||||||
|
|
||||||
|
private String key;
|
||||||
|
|
||||||
|
private String value;
|
||||||
|
|
||||||
|
}
|
||||||
+1
-1
@@ -190,7 +190,7 @@ public class SarFileSplitItemsEOController extends BaseController<SarFileSplitIt
|
|||||||
nowFile.mkdirs();
|
nowFile.mkdirs();
|
||||||
String fileName = fileOriName + ".xls";
|
String fileName = fileOriName + ".xls";
|
||||||
HSSFSheet sheetItems = workbook.createSheet("条款内容");
|
HSSFSheet sheetItems = workbook.createSheet("条款内容");
|
||||||
String[] headers = {"条款号","条款名称","内容简介","责任部门","FO","责任工程师","SVPPS","适用车辆类型","要求类型","企标覆盖关系"};
|
String[] headers = {"条款号","条款名称","内容简介"};
|
||||||
HSSFCellStyle cellStyle =workbook.createCellStyle();
|
HSSFCellStyle cellStyle =workbook.createCellStyle();
|
||||||
cellStyle.setWrapText(true);
|
cellStyle.setWrapText(true);
|
||||||
// cellStyle.setAlignment(HSSFCellStyle.ALIGN_CENTER);
|
// cellStyle.setAlignment(HSSFCellStyle.ALIGN_CENTER);
|
||||||
|
|||||||
+15
-3
@@ -4,6 +4,7 @@ import com.adc.da.base.web.BaseController;
|
|||||||
import com.adc.da.http.PageInfo;
|
import com.adc.da.http.PageInfo;
|
||||||
import com.adc.da.person.dao.PersonCollectEODao;
|
import com.adc.da.person.dao.PersonCollectEODao;
|
||||||
import com.adc.da.person.dao.PersonShareEODao;
|
import com.adc.da.person.dao.PersonShareEODao;
|
||||||
|
import com.adc.da.slrs.standardSplit.dao.SarStandCompareHisEODao;
|
||||||
import com.adc.da.slrs.standardSplit.entity.SarStandCompareHisEO;
|
import com.adc.da.slrs.standardSplit.entity.SarStandCompareHisEO;
|
||||||
import com.adc.da.slrs.standardSplit.entity.SarStandCompareHisEOPage;
|
import com.adc.da.slrs.standardSplit.entity.SarStandCompareHisEOPage;
|
||||||
import com.adc.da.slrs.standardSplit.service.SarItemsCompareHisEOService;
|
import com.adc.da.slrs.standardSplit.service.SarItemsCompareHisEOService;
|
||||||
@@ -18,6 +19,7 @@ import io.swagger.annotations.ApiOperation;
|
|||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.scheduling.annotation.Async;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -46,6 +48,9 @@ public class SarStandCompareHisEOController extends BaseController<SarStandCompa
|
|||||||
@Autowired
|
@Autowired
|
||||||
private PersonCollectEODao personCollectEODao;
|
private PersonCollectEODao personCollectEODao;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private SarStandCompareHisEODao dao;
|
||||||
|
|
||||||
@ApiOperation(value = "|SarStandCompareHisEO|分页查询")
|
@ApiOperation(value = "|SarStandCompareHisEO|分页查询")
|
||||||
@GetMapping("/page")
|
@GetMapping("/page")
|
||||||
// @RequiresPermissions("lawss:sarStandCompareHis:page")
|
// @RequiresPermissions("lawss:sarStandCompareHis:page")
|
||||||
@@ -126,8 +131,15 @@ public class SarStandCompareHisEOController extends BaseController<SarStandCompa
|
|||||||
|
|
||||||
@ApiOperation(value = "全文比对")
|
@ApiOperation(value = "全文比对")
|
||||||
@PostMapping("/fullTextComparison")
|
@PostMapping("/fullTextComparison")
|
||||||
public ResponseMessage<Map<String,Object>> fullTextComparison(String leftStandard, String rightStandard) throws Exception {
|
public ResponseMessage<String> fullTextComparison(String leftStandard, String rightStandard) throws Exception {
|
||||||
Map<String,Object> resultMap = sarStandCompareHisEOService.fullTextComparison(leftStandard,rightStandard);
|
String id=UUIDUtils.randomUUID(32);
|
||||||
return Result.success(resultMap);
|
SarStandCompareHisEO sarStandCompareHisEO =new SarStandCompareHisEO();
|
||||||
|
sarStandCompareHisEO.setId(id);
|
||||||
|
sarStandCompareHisEO.setCompareStatus("比对中");
|
||||||
|
sarStandCompareHisEO.setCompareType("全文比对");
|
||||||
|
sarStandCompareHisEO.setCreateTime(new Date());
|
||||||
|
dao.insertSelective(sarStandCompareHisEO);
|
||||||
|
Map<String,Object> resultMap = sarStandCompareHisEOService.fullTextComparison(leftStandard,rightStandard,id);
|
||||||
|
return Result.success("标准正在比对中请稍后查看结果");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+3
@@ -2,6 +2,7 @@ package com.adc.da.slrs.standardSplit.entity;
|
|||||||
|
|
||||||
import com.adc.da.base.entity.BaseEntity;
|
import com.adc.da.base.entity.BaseEntity;
|
||||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
@@ -13,6 +14,7 @@ import java.util.List;
|
|||||||
* <b>日期:</b> 2020-02-24 <br>
|
* <b>日期:</b> 2020-02-24 <br>
|
||||||
* <b>版权所有:<b>版权归北京卡达克数据技术中心所有。<br>
|
* <b>版权所有:<b>版权归北京卡达克数据技术中心所有。<br>
|
||||||
*/
|
*/
|
||||||
|
@Data
|
||||||
public class SarStandCompareHisEO extends BaseEntity {
|
public class SarStandCompareHisEO extends BaseEntity {
|
||||||
|
|
||||||
private String compareType;
|
private String compareType;
|
||||||
@@ -36,6 +38,7 @@ public class SarStandCompareHisEO extends BaseEntity {
|
|||||||
private String newFileTypeShow;
|
private String newFileTypeShow;
|
||||||
private String newSarType;
|
private String newSarType;
|
||||||
private String collectId;
|
private String collectId;
|
||||||
|
private String compareStatus;
|
||||||
|
|
||||||
private List<SarStandItemsCompareHisEO> resLeftMapList = new ArrayList<>();
|
private List<SarStandItemsCompareHisEO> resLeftMapList = new ArrayList<>();
|
||||||
|
|
||||||
|
|||||||
+3
@@ -1,6 +1,7 @@
|
|||||||
package com.adc.da.slrs.standardSplit.entity;
|
package com.adc.da.slrs.standardSplit.entity;
|
||||||
|
|
||||||
import com.adc.da.base.page.BasePage;
|
import com.adc.da.base.page.BasePage;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <b>功能:</b>SAR_STAND_COMPARE_HIS SarStandCompareHisEOPage<br>
|
* <b>功能:</b>SAR_STAND_COMPARE_HIS SarStandCompareHisEOPage<br>
|
||||||
@@ -8,6 +9,7 @@ import com.adc.da.base.page.BasePage;
|
|||||||
* <b>日期:</b> 2020-02-24 <br>
|
* <b>日期:</b> 2020-02-24 <br>
|
||||||
* <b>版权所有:<b>版权归北京卡达克数据技术中心所有。<br>
|
* <b>版权所有:<b>版权归北京卡达克数据技术中心所有。<br>
|
||||||
*/
|
*/
|
||||||
|
@Data
|
||||||
public class SarStandCompareHisEOPage extends BasePage {
|
public class SarStandCompareHisEOPage extends BasePage {
|
||||||
|
|
||||||
private String compareType;
|
private String compareType;
|
||||||
@@ -50,6 +52,7 @@ public class SarStandCompareHisEOPage extends BasePage {
|
|||||||
private String oldNumOrName;
|
private String oldNumOrName;
|
||||||
|
|
||||||
private String newNumOrName;
|
private String newNumOrName;
|
||||||
|
private String compareStatus;
|
||||||
|
|
||||||
private String shunxu;
|
private String shunxu;
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -21,5 +21,5 @@ public interface SarStandCompareHisEOService {
|
|||||||
|
|
||||||
Map<String,Object> clauseComparison(String oldItemId, String newItemId, String standHisId);
|
Map<String,Object> clauseComparison(String oldItemId, String newItemId, String standHisId);
|
||||||
|
|
||||||
Map<String,Object> fullTextComparison(String leftStandard, String rightStandard) throws Exception;
|
Map<String,Object> fullTextComparison(String leftStandard, String rightStandard,String id) throws Exception;
|
||||||
}
|
}
|
||||||
|
|||||||
+7
-6
@@ -245,9 +245,9 @@ public class SarStandCompareHisEOServiceImpl implements SarStandCompareHisEOServ
|
|||||||
}
|
}
|
||||||
return resultMap;
|
return resultMap;
|
||||||
}
|
}
|
||||||
|
@Async
|
||||||
@Override
|
@Override
|
||||||
public Map<String, Object> fullTextComparison(String leftStandard, String rightStandard) throws Exception{
|
public Map<String, Object> fullTextComparison(String leftStandard, String rightStandard,String id) throws Exception{
|
||||||
Map<String,Object> resultMap = new HashMap<String,Object>();
|
Map<String,Object> resultMap = new HashMap<String,Object>();
|
||||||
List<Map<String,Object>> leftMapList = fullTextComparePackageData(leftStandard);
|
List<Map<String,Object>> leftMapList = fullTextComparePackageData(leftStandard);
|
||||||
List<Map<String,Object>> rightMapList = fullTextComparePackageData(rightStandard);
|
List<Map<String,Object>> rightMapList = fullTextComparePackageData(rightStandard);
|
||||||
@@ -281,7 +281,7 @@ public class SarStandCompareHisEOServiceImpl implements SarStandCompareHisEOServ
|
|||||||
resultMap.put("resRightMapList",resRightMapList);
|
resultMap.put("resRightMapList",resRightMapList);
|
||||||
}
|
}
|
||||||
//往全文比对历史表中添加数据
|
//往全文比对历史表中添加数据
|
||||||
addStandCompareHis(leftStandard,rightStandard,"全文比对",resLeftMapList,resRightMapList);
|
addStandCompareHis(leftStandard,rightStandard,"全文比对",resLeftMapList,resRightMapList,id);
|
||||||
return resultMap;
|
return resultMap;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -319,12 +319,12 @@ public class SarStandCompareHisEOServiceImpl implements SarStandCompareHisEOServ
|
|||||||
**/
|
**/
|
||||||
@Async
|
@Async
|
||||||
public void addStandCompareHis(String leftStandId,String rightStandId,String compareType,
|
public void addStandCompareHis(String leftStandId,String rightStandId,String compareType,
|
||||||
List<Map<String,Object>> resLeftMapList,List<Map<String,Object>> resRightMapList) throws Exception{
|
List<Map<String,Object>> resLeftMapList,List<Map<String,Object>> resRightMapList,String id) throws Exception{
|
||||||
SarFileSplitInfoEO leftInfo = sarFileSplitInfoEOService.selectByPrimaryKey(leftStandId);
|
SarFileSplitInfoEO leftInfo = sarFileSplitInfoEOService.selectByPrimaryKey(leftStandId);
|
||||||
SarFileSplitInfoEO rightInfo = sarFileSplitInfoEOService.selectByPrimaryKey(rightStandId);
|
SarFileSplitInfoEO rightInfo = sarFileSplitInfoEOService.selectByPrimaryKey(rightStandId);
|
||||||
//保存标准比对历史表数据
|
//保存标准比对历史表数据
|
||||||
SarStandCompareHisEO sarStandCompareHisEO = new SarStandCompareHisEO();
|
SarStandCompareHisEO sarStandCompareHisEO = new SarStandCompareHisEO();
|
||||||
String id = UUIDUtils.randomUUID20();
|
// String id = UUIDUtils.randomUUID20();
|
||||||
sarStandCompareHisEO.setId(id);
|
sarStandCompareHisEO.setId(id);
|
||||||
sarStandCompareHisEO.setOldStandId(leftStandId);
|
sarStandCompareHisEO.setOldStandId(leftStandId);
|
||||||
sarStandCompareHisEO.setNewStandId(rightStandId);
|
sarStandCompareHisEO.setNewStandId(rightStandId);
|
||||||
@@ -341,7 +341,8 @@ public class SarStandCompareHisEOServiceImpl implements SarStandCompareHisEOServ
|
|||||||
sarStandCompareHisEO.setCreateUser(LoginUserUtil.getUserId());
|
sarStandCompareHisEO.setCreateUser(LoginUserUtil.getUserId());
|
||||||
sarStandCompareHisEO.setModifyUser(LoginUserUtil.getUserId());
|
sarStandCompareHisEO.setModifyUser(LoginUserUtil.getUserId());
|
||||||
sarStandCompareHisEO.setCompareType(compareType);
|
sarStandCompareHisEO.setCompareType(compareType);
|
||||||
dao.insertSelective(sarStandCompareHisEO);
|
sarStandCompareHisEO.setCompareStatus("比对完成");
|
||||||
|
dao.updateByPrimaryKeySelective(sarStandCompareHisEO);
|
||||||
//保存标准的所有条款比对的历史数据
|
//保存标准的所有条款比对的历史数据
|
||||||
if(resLeftMapList!=null && !resLeftMapList.isEmpty()) {
|
if(resLeftMapList!=null && !resLeftMapList.isEmpty()) {
|
||||||
setStandCompareHisEO(resLeftMapList, id, "LEFT");
|
setStandCompareHisEO(resLeftMapList, id, "LEFT");
|
||||||
|
|||||||
+13
-3
@@ -19,11 +19,12 @@
|
|||||||
<result column="modify_time" property="modifyTime" />
|
<result column="modify_time" property="modifyTime" />
|
||||||
<result column="new_file_type" property="newFileType" />
|
<result column="new_file_type" property="newFileType" />
|
||||||
<result column="new_sar_type" property="newSarType" />
|
<result column="new_sar_type" property="newSarType" />
|
||||||
|
<result column="compare_status" property="compareStatus"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<!-- SAR_STAND_COMPARE_HIS table all fields -->
|
<!-- SAR_STAND_COMPARE_HIS table all fields -->
|
||||||
<sql id="Base_Column_List" >
|
<sql id="Base_Column_List" >
|
||||||
compare_type, id, old_stand_id, old_stand_num, old_stand_name, new_stand_id, new_stand_num, new_stand_name, old_file_type, old_sar_type, create_user, create_time, modify_user, modify_time, new_file_type, new_sar_type
|
compare_type, id, old_stand_id, old_stand_num, old_stand_name, new_stand_id, new_stand_num, new_stand_name, old_file_type, old_sar_type, create_user, create_time, modify_user, modify_time, new_file_type, new_sar_type ,compare_status
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<!-- 查询条件 -->
|
<!-- 查询条件 -->
|
||||||
@@ -89,6 +90,9 @@
|
|||||||
</if>
|
</if>
|
||||||
<if test="newSarType != null" >
|
<if test="newSarType != null" >
|
||||||
and new_sar_type ${newSarTypeOperator} #{newSarType}
|
and new_sar_type ${newSarTypeOperator} #{newSarType}
|
||||||
|
</if>
|
||||||
|
<if test="compareStatus != null" >
|
||||||
|
and compare_status = #{compareStatus}
|
||||||
</if>
|
</if>
|
||||||
<if test="oldNumOrName != null" >
|
<if test="oldNumOrName != null" >
|
||||||
and (old_stand_num like concat('%',#{oldNumOrName},'%') OR old_stand_name like concat('%',#{oldNumOrName},'%'))
|
and (old_stand_num like concat('%',#{oldNumOrName},'%') OR old_stand_name like concat('%',#{oldNumOrName},'%'))
|
||||||
@@ -105,7 +109,7 @@
|
|||||||
SELECT SEQ_SAR_STAND_COMPARE_HIS.NEXTVAL FROM DUAL
|
SELECT SEQ_SAR_STAND_COMPARE_HIS.NEXTVAL FROM DUAL
|
||||||
</selectKey> -->
|
</selectKey> -->
|
||||||
insert into SAR_STAND_COMPARE_HIS(<include refid="Base_Column_List" />)
|
insert into SAR_STAND_COMPARE_HIS(<include refid="Base_Column_List" />)
|
||||||
values (#{compareType, jdbcType=VARCHAR}, #{id, jdbcType=VARCHAR}, #{oldStandId, jdbcType=VARCHAR}, #{oldStandNum, jdbcType=VARCHAR}, #{oldStandName, jdbcType=VARCHAR}, #{newStandId, jdbcType=VARCHAR}, #{newStandNum, jdbcType=VARCHAR}, #{newStandName, jdbcType=VARCHAR}, #{oldFileType, jdbcType=VARCHAR}, #{oldSarType, jdbcType=VARCHAR}, #{createUser, jdbcType=VARCHAR}, #{createTime, jdbcType=TIMESTAMP}, #{modifyUser, jdbcType=VARCHAR}, #{modifyTime, jdbcType=TIMESTAMP}, #{newFileType, jdbcType=VARCHAR}, #{newSarType, jdbcType=VARCHAR})
|
values (#{compareType, jdbcType=VARCHAR}, #{id, jdbcType=VARCHAR}, #{oldStandId, jdbcType=VARCHAR}, #{oldStandNum, jdbcType=VARCHAR}, #{oldStandName, jdbcType=VARCHAR}, #{newStandId, jdbcType=VARCHAR}, #{newStandNum, jdbcType=VARCHAR}, #{newStandName, jdbcType=VARCHAR}, #{oldFileType, jdbcType=VARCHAR}, #{oldSarType, jdbcType=VARCHAR}, #{createUser, jdbcType=VARCHAR}, #{createTime, jdbcType=TIMESTAMP}, #{modifyUser, jdbcType=VARCHAR}, #{modifyTime, jdbcType=TIMESTAMP}, #{newFileType, jdbcType=VARCHAR}, #{newSarType, jdbcType=VARCHAR},#{compareStatus, jdbcType=VARCHAR})
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
<!-- 动态插入记录 主键是序列 -->
|
<!-- 动态插入记录 主键是序列 -->
|
||||||
@@ -131,6 +135,7 @@
|
|||||||
<if test="modifyTime != null" >modify_time,</if>
|
<if test="modifyTime != null" >modify_time,</if>
|
||||||
<if test="newFileType != null" >new_file_type,</if>
|
<if test="newFileType != null" >new_file_type,</if>
|
||||||
<if test="newSarType != null" >new_sar_type,</if>
|
<if test="newSarType != null" >new_sar_type,</if>
|
||||||
|
<if test="compareStatus != null" >compare_status,</if>
|
||||||
</trim>
|
</trim>
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides="," >
|
<trim prefix="values (" suffix=")" suffixOverrides="," >
|
||||||
<if test="compareType != null" >#{compareType, jdbcType=VARCHAR},</if>
|
<if test="compareType != null" >#{compareType, jdbcType=VARCHAR},</if>
|
||||||
@@ -149,6 +154,7 @@
|
|||||||
<if test="modifyTime != null" >#{modifyTime, jdbcType=TIMESTAMP},</if>
|
<if test="modifyTime != null" >#{modifyTime, jdbcType=TIMESTAMP},</if>
|
||||||
<if test="newFileType != null" >#{newFileType, jdbcType=VARCHAR},</if>
|
<if test="newFileType != null" >#{newFileType, jdbcType=VARCHAR},</if>
|
||||||
<if test="newSarType != null" >#{newSarType, jdbcType=VARCHAR},</if>
|
<if test="newSarType != null" >#{newSarType, jdbcType=VARCHAR},</if>
|
||||||
|
<if test="compareStatus != null" >#{compareStatus, jdbcType=VARCHAR},</if>
|
||||||
</trim>
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@@ -169,7 +175,8 @@
|
|||||||
modify_user = #{modifyUser},
|
modify_user = #{modifyUser},
|
||||||
modify_time = #{modifyTime},
|
modify_time = #{modifyTime},
|
||||||
new_file_type = #{newFileType},
|
new_file_type = #{newFileType},
|
||||||
new_sar_type = #{newSarType}
|
new_sar_type = #{newSarType},
|
||||||
|
compare_status = #{compareStatus}
|
||||||
where id = #{id}
|
where id = #{id}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
@@ -222,6 +229,9 @@
|
|||||||
<if test="newSarType != null" >
|
<if test="newSarType != null" >
|
||||||
new_sar_type = #{newSarType},
|
new_sar_type = #{newSarType},
|
||||||
</if>
|
</if>
|
||||||
|
<if test="compareStatus != null" >
|
||||||
|
compare_status = #{compareStatus},
|
||||||
|
</if>
|
||||||
</set>
|
</set>
|
||||||
where id = #{id}
|
where id = #{id}
|
||||||
</update>
|
</update>
|
||||||
|
|||||||
Reference in New Issue
Block a user