标准详情,已被分解的的文本才有分解单按钮

This commit is contained in:
zhaokaiyao@91isoft.com
2021-09-15 18:01:06 +08:00
parent 180b755bec
commit d6331ab155
@@ -439,11 +439,16 @@ public class SarStandardsInfoServiceImpl extends ServiceImpl<SarStandardsInfoDao
return resultMap;
}
public void attrInfoShowDetails(List<SarStandardsInfo> sarlist) throws Exception {
for (SarStandardsInfo row : sarlist) {
attrInfoDetails(row);
Map<String, Object> getAttrMap = row.getAttrInfoMap();
if (getAttrMap != null && getAttrMap.size() > 0) {
//存在的分解单文本名称列表
LinkedList<String> itemExistList = new LinkedList<>();
getAttrMap.put("itemExistList",itemExistList);
for (Map.Entry<String, Object> entry : getAttrMap.entrySet()) {
String name = entry.getKey();
String value = "";
@@ -452,6 +457,15 @@ public class SarStandardsInfoServiceImpl extends ServiceImpl<SarStandardsInfoDao
if (StringUtils.isNotBlank(value)) {
List<AttFileEO> fileObj = attFileEOService.getMultiFileInfos(value);
entry.setValue(fileObj);
//以标准id和文本类型查询分解单表 有数据设标记为为 1
FindSarItemsPageReqDTO sarItemCount = new FindSarItemsPageReqDTO();
sarItemCount.setStandId(row.getId());
sarItemCount.setFileType(name);
Integer sarItemsCount = standItemsDao.sarItemCount(sarItemCount);
if (sarItemsCount>0){
//存在分解单的文本名称存入列表
itemExistList.add(name);
}
}
}else if (entry.getValue() != null && InitStandAttrUtil.selectionFieldList != null && InitStandAttrUtil.selectionFieldList.size() > 0 && InitStandAttrUtil.selectionFieldList.contains(name)) {
value = entry.getValue().toString();