Merge remote-tracking branch 'origin/dev_third_stage' into dev_third_stage
This commit is contained in:
+52
-13
@@ -127,7 +127,7 @@ public class ParamsInfoEOServiceImpl extends ServiceImpl<ParamsInfoEOMapper, Par
|
||||
// 校验认证类别参数项编号 同一nio下编号 不同类别间编号唯一
|
||||
List<CertCategoryParamsInfoEO> ccParamsInfoList = certCategoryParamsInfoEOList.stream()
|
||||
.collect(Collectors.collectingAndThen(Collectors
|
||||
.toCollection(() -> new TreeSet<>(Comparator.comparing(o -> o.getCertCategory() + ";" + o.getParamsNumber()))), ArrayList::new));
|
||||
.toCollection(() -> new TreeSet<>(Comparator.comparing(o -> o.getParamsNumber()))), ArrayList::new));
|
||||
if (ccParamsInfoList.size() < certCategoryParamsInfoEOList.size()) {
|
||||
if (CutEnum.CN.getValue().equals(paramsInfoEO.getCut())) {
|
||||
throw new JeroBootException("不同类别间参数编号必须唯一!");
|
||||
@@ -212,7 +212,7 @@ public class ParamsInfoEOServiceImpl extends ServiceImpl<ParamsInfoEOMapper, Par
|
||||
// 校验认证类别参数项编号 同一nio下编号 不同类别间编号唯一
|
||||
List<CertCategoryParamsInfoEO> ccParamsInfoList = certCategoryParamsInfoEOList.stream()
|
||||
.collect(Collectors.collectingAndThen(Collectors
|
||||
.toCollection(() -> new TreeSet<>(Comparator.comparing(o -> o.getCertCategory() + ";" + o.getParamsNumber()))), ArrayList::new));
|
||||
.toCollection(() -> new TreeSet<>(Comparator.comparing(o -> o.getParamsNumber()))), ArrayList::new));
|
||||
if (ccParamsInfoList.size() < certCategoryParamsInfoEOList.size()) {
|
||||
if (CutEnum.CN.getValue().equals(paramsInfoEO.getCut())) {
|
||||
throw new JeroBootException("不同类别间参数编号必须唯一!");
|
||||
@@ -260,7 +260,7 @@ public class ParamsInfoEOServiceImpl extends ServiceImpl<ParamsInfoEOMapper, Par
|
||||
String nioNumber = paramsInfoEO.getNioNumber();
|
||||
String paramsTemplateId = paramsInfoEO.getParamsTemplateId();
|
||||
certCategoryParamsInfoEOService.deleteByNioNumberList(Arrays.asList(nioNumber), paramsTemplateId);
|
||||
// TODO 关联删除附件模板文件信息和文件
|
||||
// 关联删除附件模板文件信息和文件 ---> 不能删 发布版用的同一文件
|
||||
return removeById(id);
|
||||
}
|
||||
|
||||
@@ -280,7 +280,7 @@ public class ParamsInfoEOServiceImpl extends ServiceImpl<ParamsInfoEOMapper, Par
|
||||
List<String> nioNumberList = paramsInfoEOList.stream().map(ParamsInfoEO::getNioNumber).collect(Collectors.toList());
|
||||
// 关联删除认证类别参数项
|
||||
certCategoryParamsInfoEOService.deleteByNioNumberList(nioNumberList, paramsTemplateId);
|
||||
// TODO 关联删除附件模板文件信息和文件
|
||||
// 关联删除附件模板文件信息和文件 ---> 不能删 发布版用的同一文件
|
||||
}
|
||||
|
||||
return removeByIds(ids);
|
||||
@@ -1098,11 +1098,11 @@ public class ParamsInfoEOServiceImpl extends ServiceImpl<ParamsInfoEOMapper, Par
|
||||
List<String> nioNumberImport = new ArrayList<>(); // 记录导入的nio编号
|
||||
|
||||
int i = 1; //记录行号
|
||||
int num = 0; //记录是第几条数据
|
||||
//循环验证数据
|
||||
for (ParamsInfoCnImport dto : paramsInfoEOList) {
|
||||
//判断此行数据是否全部为空,是则不读取
|
||||
if (checkObjAllFieldsIsNull(dto)) {
|
||||
i++;
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -1318,10 +1318,14 @@ public class ParamsInfoEOServiceImpl extends ServiceImpl<ParamsInfoEOMapper, Par
|
||||
for (Map.Entry<String, List<CertCategoryParamsInfoCnImport>> ccDtoMap : certCategoryParamsInfoEOListMap.entrySet()) {
|
||||
String certCategory = ccDtoMap.getKey();
|
||||
List<CertCategoryParamsInfoCnImport> ccDtoList = ccDtoMap.getValue();
|
||||
|
||||
List<String> ccNioNumberImport = new ArrayList<>(); // 记录导入的nio编号
|
||||
|
||||
int j = 1;
|
||||
for (CertCategoryParamsInfoCnImport ccDto : ccDtoList) {
|
||||
//判断此行数据是否全部为空,是则不读取
|
||||
if (checkObjAllFieldsIsNull(ccDto)) {
|
||||
j++;
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -1351,6 +1355,20 @@ public class ParamsInfoEOServiceImpl extends ServiceImpl<ParamsInfoEOMapper, Par
|
||||
}
|
||||
countError++;
|
||||
}
|
||||
if (CollectionUtil.isNotEmpty(ccNioNumberImport)) {
|
||||
if (ccNioNumberImport.contains(ccDto.getNioNumber())) {
|
||||
if (CutEnum.CN.getValue().equals(cut)) {
|
||||
errorMsg += "NIO编号重复!";
|
||||
} else {
|
||||
errorMsg += "NIO number already exists!";
|
||||
}
|
||||
countError++;
|
||||
} else {
|
||||
ccNioNumberImport.add(ccDto.getNioNumber());
|
||||
}
|
||||
} else {
|
||||
ccNioNumberImport.add(ccDto.getNioNumber());
|
||||
}
|
||||
}
|
||||
// 编号
|
||||
String paramsNumber = ccDto.getParamsNumber();
|
||||
@@ -1384,21 +1402,42 @@ public class ParamsInfoEOServiceImpl extends ServiceImpl<ParamsInfoEOMapper, Par
|
||||
stringMessage.add(errorMsg);
|
||||
}
|
||||
}
|
||||
// 校验同 nio下认证类别唯一
|
||||
List<CertCategoryParamsInfoCnImport> ccDtoAfterDistinct = ccDtoList.stream()
|
||||
.collect(Collectors.collectingAndThen(Collectors.toCollection(() ->
|
||||
new TreeSet<>(Comparator.comparing(o -> o.getNioNumber() + ";" + o.getCertCategory()))), ArrayList::new));
|
||||
if (ccDtoAfterDistinct.size() < ccDtoList.size()) {
|
||||
// 取差集
|
||||
String reduceOne = ccDtoList.stream()
|
||||
.filter(e->!ccDtoAfterDistinct.contains(e)).map(CertCategoryParamsInfoCnImport::getNioNumber).collect(Collectors.joining(","));
|
||||
if (StringUtils.isNotBlank(reduceOne)) {
|
||||
if (CutEnum.CN.getValue().equals(cut)) {
|
||||
stringMessage.add("导入数据中NIO编号:" + reduceOne + "下存在重复认证类别;");
|
||||
} else {
|
||||
stringMessage.add("Repeat cert category exist in NIO Number: " + reduceOne + ";");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
certCategoryParamsInfoEOList.addAll(ccDtoList);
|
||||
}
|
||||
// 校验同 nio下认证参数编号唯一
|
||||
List<CertCategoryParamsInfoCnImport> ccDtoAfterDistinct = certCategoryParamsInfoEOList.stream()
|
||||
List<CertCategoryParamsInfoCnImport> ccDtoAfterDistinctTwo = certCategoryParamsInfoEOList.stream()
|
||||
.collect(Collectors.collectingAndThen(Collectors.toCollection(() ->
|
||||
new TreeSet<>(Comparator.comparing(o -> o.getNioNumber() + ";" + o.getCertCategory()))), ArrayList::new));
|
||||
if (ccDtoAfterDistinct.size() < certCategoryParamsInfoEOList.size()) {
|
||||
if(CutEnum.CN.getValue().equals(cut)) {
|
||||
stringMessage.add("导入数据中存在重复认证编号;");
|
||||
} else {
|
||||
stringMessage.add("Repeat number exist in the Import Data;");
|
||||
new TreeSet<>(Comparator.comparing(o -> o.getNioNumber() + ";" + o.getParamsNumber()))), ArrayList::new));
|
||||
if (ccDtoAfterDistinctTwo.size() < certCategoryParamsInfoEOList.size()) {
|
||||
// 取差集
|
||||
String reduceTwo = certCategoryParamsInfoEOList.stream()
|
||||
.filter(e->!ccDtoAfterDistinctTwo.contains(e)).map(CertCategoryParamsInfoCnImport::getNioNumber).collect(Collectors.joining(","));
|
||||
if (StringUtils.isNotBlank(reduceTwo)) {
|
||||
if (CutEnum.CN.getValue().equals(cut)) {
|
||||
stringMessage.add("导入数据中NIO编号:" + reduceTwo + "下存在重复认证编号;");
|
||||
} else {
|
||||
stringMessage.add("Repeat number exist in NIO Number: " + reduceTwo + ";");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Map map = new HashMap();
|
||||
if (stringMessage.isEmpty()) {
|
||||
map.put("result", true);
|
||||
|
||||
@@ -729,6 +729,7 @@ module.exports = {
|
||||
ParameteItemCollectionList: 'Parameter item collection list',
|
||||
Areyousureparameteritems: 'Are you sure to submit the selected parameter items?',
|
||||
Theselectedconfiguration: 'The configuration can only be added when the parameter items in the parameter list are to be collected or changed',
|
||||
NoConfigurationNotStart: 'No configuration added, unable to start collection, please check',
|
||||
theCurrent: 'The current status of this data is',
|
||||
thisbuttonCompleted: 'This button can only be operated when the status is completed',
|
||||
Frozenstatus: 'Frozen status, can only be viewed',
|
||||
@@ -771,7 +772,9 @@ module.exports = {
|
||||
configure: 'Configure',
|
||||
parameter: 'Parameter',
|
||||
changeExtension: 'Change Extension',
|
||||
addDetailList: 'Add',
|
||||
detailedList: 'DetailedList',
|
||||
copyParamDetailList: 'Copy Parameter List',
|
||||
collectionCompletionTime: 'Collection Completion Time',
|
||||
parameterTemplateName: 'Parameter Template Name',
|
||||
onlyThree: 'Only letters, numbers and horizontal bars (-) can be entered',
|
||||
|
||||
@@ -740,6 +740,7 @@ module.exports = {
|
||||
ParameteItemCollectionList: '参数项收集清单',
|
||||
Areyousureparameteritems: '确认提交所选参数项嘛?',
|
||||
Theselectedconfiguration: '参数清单中参数项均为待发起收集或变更时,才能添加配置',
|
||||
NoConfigurationNotStart: '未添加任何配置,无法开始收集,请检查',
|
||||
theCurrent: '此数据当前状态为',
|
||||
thisbuttonCompleted: '当状态为"已完成"时,才可操作此按钮',
|
||||
Frozenstatus: '冻结状态,仅可以查看',
|
||||
@@ -782,7 +783,9 @@ module.exports = {
|
||||
configure: '配置',
|
||||
parameter: '参数',
|
||||
changeExtension: '变更扩展',
|
||||
addDetailList: '添加清单',
|
||||
detailedList: '清单',
|
||||
copyParamDetailList: '复制参数清单',
|
||||
collectionCompletionTime: '收集完成时间',
|
||||
parameterTemplateName: '参数模板名称',
|
||||
onlyThree: '只能输入字母,数字,横杠(-)三种内容',
|
||||
|
||||
@@ -112,7 +112,7 @@ import axios from 'axios'
|
||||
import { ACCESS_TOKEN } from '@/store/mutation-types'
|
||||
import Vue from 'vue'
|
||||
export default {
|
||||
name: 'ParameterItemCollectionList',
|
||||
name: 'managementdetails',
|
||||
data(){
|
||||
return{
|
||||
columns:[],
|
||||
|
||||
+9
-9
@@ -71,15 +71,15 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import TaskList from '@/views/projectManagement/components/TaskList'
|
||||
import listOfRegulations from '@/views/projectManagement/components/listOfRegulations'
|
||||
import ProjectDetailsName from '@/views/projectManagement/components/ProjectDetails'
|
||||
import ParameterItemCollectionList from '../../components/ParameterItemCollectionList'
|
||||
import nonConformance from '@/views/projectManagement/components/nonConformance'
|
||||
import updateLog from '@/components/UpdateLog/index'
|
||||
import historicalVersionList from '@/views/projectManagement/components/historicalVersionList'
|
||||
import commentList from '@/views/projectManagement/components/commentList'
|
||||
import { getAction, postAction, deleteAction, downloadFile } from '@/api/manage'
|
||||
import TaskList from '@views/projectManagement/components/TaskList'
|
||||
import listOfRegulations from '@views/projectManagement/components/listOfRegulations'
|
||||
import ProjectDetailsName from '@views/projectManagement/components/ProjectDetails'
|
||||
import ParameterItemCollectionList from '../components/ParameterItemCollectionList'
|
||||
import nonConformance from '@views/projectManagement/components/nonConformance'
|
||||
import updateLog from '@comp/UpdateLog'
|
||||
import historicalVersionList from '@views/projectManagement/components/historicalVersionList'
|
||||
import commentList from '@views/projectManagement/components/commentList'
|
||||
import { getAction, postAction, deleteAction, downloadFile } from '@api/manage'
|
||||
|
||||
export default {
|
||||
name: 'ProjectDetails',
|
||||
@@ -24,7 +24,7 @@
|
||||
<div class="table-operator">
|
||||
<div @click="handleAdd" class="operator-text">
|
||||
<a-icon type="plus"/>
|
||||
{{$t('add')}}{{ $t('detailedList') }}
|
||||
{{$t('addDetailList')}}
|
||||
</div>
|
||||
<div @click="handleModule" class="operator-text">
|
||||
<a-icon type="bulb"/>
|
||||
@@ -32,9 +32,9 @@
|
||||
</div>
|
||||
<div @click="handleCody" class="operator-text">
|
||||
<a-icon type="copy"/>
|
||||
{{$t('copy')}}{{$t('parameter')}}{{ $t('detailedList') }}
|
||||
{{$t('copyParamDetailList')}}
|
||||
</div>
|
||||
<div @click="handleDel" class="operator-text" v-has="'document:deleteBatch'">
|
||||
<div @click="handleDel" class="operator-text">
|
||||
<a-icon type="delete"/>
|
||||
{{$t('BatchDelete')}}
|
||||
</div>
|
||||
@@ -92,8 +92,7 @@
|
||||
<project-collection-parameters v-if='drawerVisible' @areaVisible='drawerhandleCancel' :templateTitle='templatetitle' @copysubmit='copysubmit'
|
||||
:selectedRowKeyS='selectedRowKeys' :rowId='rowId' :version='version' :url='url'
|
||||
:projectId='this.$route.query.id'></project-collection-parameters>
|
||||
|
||||
</a-modal>
|
||||
</a-modal>
|
||||
</a-card>
|
||||
</template>
|
||||
|
||||
@@ -107,6 +106,7 @@
|
||||
import axios from 'axios'
|
||||
import Vue from 'vue'
|
||||
import { ACCESS_TOKEN } from '@/store/mutation-types'
|
||||
import eventBUs from '@/common/event'
|
||||
|
||||
export default {
|
||||
name: 'TaskParameterCollection',
|
||||
@@ -177,7 +177,8 @@
|
||||
deleteAll: 'params/manifest/deleteBatch',
|
||||
conAdd: 'params/config/addBatch',
|
||||
conList: 'params/config/list',
|
||||
changeExtension:'params/manifest/changeExtension'
|
||||
changeExtension:'params/manifest/changeExtension',
|
||||
verifyConfig: 'params/manifest/verifyConfig'
|
||||
},
|
||||
loading: false,
|
||||
dataSource: [],
|
||||
@@ -206,12 +207,20 @@
|
||||
},
|
||||
methods: {
|
||||
paramsManifestClick(item) {
|
||||
localStorage.setItem('paramsManifest', JSON.stringify(item))
|
||||
let newUrl = this.$router.resolve({
|
||||
path: '/ParameterItemCollection',
|
||||
query: item,
|
||||
let _this = this
|
||||
// 先调取接口判断是否有配置信息
|
||||
getAction(this.url.verifyConfig, { paramsManifestId: item.id }).then((res) => {
|
||||
if (res.result) {
|
||||
localStorage.setItem('paramsManifest', JSON.stringify(item))
|
||||
let newUrl = _this.$router.resolve({
|
||||
path: '/ParameterItemCollection',
|
||||
query: item,
|
||||
})
|
||||
window.open(newUrl.href, '_blank')
|
||||
} else {
|
||||
_this.$message.success(_this.$t('NoConfigurationNotStart'))
|
||||
}
|
||||
})
|
||||
window.open(newUrl.href, '_blank')
|
||||
},
|
||||
deleteLib(val) {
|
||||
if(val.state === '已完成' || val.state === 'Finished' ) {
|
||||
@@ -381,7 +390,7 @@
|
||||
/deep/ .ant-table td {
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
|
||||
.doc-detail {
|
||||
background: #fff;
|
||||
height: 100%;
|
||||
|
||||
@@ -52,8 +52,13 @@
|
||||
:rowSelection='{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}'
|
||||
@change='handleTableChange'>
|
||||
<span slot='click' slot-scope='text, record'>
|
||||
<a class='action-edit' @click='editArea(record)' v-has="'area:edit'">{{ text }}</a>
|
||||
|
||||
</span>
|
||||
|
||||
<span slot="parameterTemplateSlot" slot-scope="text,record">
|
||||
<a class='action-edit' @click='parameterTemplateSlotHandler(record)'>{{ text }}</a>
|
||||
</span>
|
||||
|
||||
</a-table>
|
||||
<div class="page" style='display: flex;justify-content: flex-end;'>
|
||||
<a-pagination
|
||||
@@ -85,7 +90,7 @@ import ParameterTemplate from '../dialog/ParameterTemplate'
|
||||
import { ACCESS_TOKEN } from '@/store/mutation-types'
|
||||
|
||||
export default {
|
||||
name: 'diolagArea',
|
||||
name: 'ProjectCollectionParameters',
|
||||
components: {
|
||||
ParameterTemplate
|
||||
},
|
||||
@@ -115,7 +120,8 @@ export default {
|
||||
title: this.$t('parameterTemplate'),
|
||||
align: 'center',
|
||||
dataIndex: 'paramsTemplateName',
|
||||
ellipsis: true
|
||||
ellipsis: true,
|
||||
scopedSlots: { customRender: 'parameterTemplateSlot' }
|
||||
}
|
||||
],
|
||||
newVisible: false,
|
||||
@@ -181,7 +187,7 @@ export default {
|
||||
console.log(this.areaTable,'this.areaTable')
|
||||
this.listVisible = false
|
||||
},
|
||||
editArea(val) {
|
||||
parameterTemplateSlotHandler(val) {
|
||||
this.listVisibleRowDate = val
|
||||
console.log(val)
|
||||
this.listVisible = true
|
||||
|
||||
Reference in New Issue
Block a user