From 05d45bd440ffc92e14e6c8728ac8956a0488c0ab Mon Sep 17 00:00:00 2001 From: xiejun <xj@2023> Date: 星期四, 07 十二月 2023 17:20:26 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/MdmProductCodeService.java | 10 Source/UBCS-WEB/src/views/modeling/LinkType.vue | 60 ++- Source/UBCS-WEB/src/views/code/code.vue | 495 ++++++++++++++-------------- Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java | 140 +++++++- Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue | 39 +- Source/UBCS-WEB/src/views/integration/systemInfo.vue | 3 Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/constant/MdmEngineConstant.java | 2 Source/UBCS-WEB/src/const/code/codebasic.js | 2 Source/UBCS-WEB/src/const/code/mdmrule.js | 2 Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/UniversalInterfaceImpl.java | 15 Source/UBCS-WEB/src/views/statistic/statisticPage.vue | 2 Source/UBCS-WEB/src/components/Master/MasterTransfer.vue | 32 + Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue | 12 Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue | 94 ---- Source/UBCS-WEB/src/components/BatchImport/index.vue | 3 Source/UBCS-WEB/src/views/modeling/Business.vue | 74 ++- Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/controller/MdmEngineController.java | 1 Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmProductCodeServiceImpl.java | 2 18 files changed, 542 insertions(+), 446 deletions(-) diff --git a/Source/UBCS-WEB/src/components/BatchImport/index.vue b/Source/UBCS-WEB/src/components/BatchImport/index.vue index cb8caaa..d9f082b 100644 --- a/Source/UBCS-WEB/src/components/BatchImport/index.vue +++ b/Source/UBCS-WEB/src/components/BatchImport/index.vue @@ -61,7 +61,7 @@ > </el-upload> <template #footer> - <div style="display: inline-block"> + <div style="display: inline-block" v-if="type != 'groupCode'"> <el-button v-if="type !== 'bulkEdit' " :loading="downloadLoading" @@ -323,6 +323,7 @@ } }, onSuccess(res) { + console.log(res) if (Object.keys(res.data).length === 0) { this.$message.success(this.title + "瀵煎叆鎴愬姛锛�"); this.resetTable() diff --git a/Source/UBCS-WEB/src/components/Master/MasterTransfer.vue b/Source/UBCS-WEB/src/components/Master/MasterTransfer.vue index 00d593e..08d4d34 100644 --- a/Source/UBCS-WEB/src/components/Master/MasterTransfer.vue +++ b/Source/UBCS-WEB/src/components/Master/MasterTransfer.vue @@ -122,20 +122,22 @@ }, methods: { handlerFile(res) { - let reader = new FileReader(); - reader.readAsText(res.data); - reader.onload = (result) => { - try { - let resData = JSON.parse(result.target.result); // 瑙f瀽瀵硅薄鎴愬姛 - if (resData.code != 200) { - this.$message.error(resData.msg); - } - } catch (err) { - // console.log("err",err)// 瑙f瀽鎴愬璞″け璐ワ紝璇存槑鏄甯哥殑鏂囦欢娴� - func.downloadFileByBlobHandler(res); - this.$message.success('涓嬭浇鎴愬姛锛岃鏌ョ湅锛�'); - } - }; + // let reader = new FileReader(); + // reader.readAsText(res.data); + // reader.onload = (result) => { + // try { + // let resData = JSON.parse(result.target.result); // 瑙f瀽瀵硅薄鎴愬姛 + // if (resData.code != 200) { + // this.$message.error(resData.msg); + // } + // } catch (err) { + // // 瑙f瀽鎴愬璞″け璐ワ紝璇存槑鏄甯哥殑鏂囦欢娴� + // func.downloadFileByBlobHandler(res); + // this.$message.success('涓嬭浇鎴愬姛锛岃鏌ョ湅锛�'); + // } + // }; + func.downloadFileByBlobHandler(res); + this.$message.success('涓嬭浇鎴愬姛锛岃鏌ョ湅锛�'); }, escHandler() { this.$emit('update:visible', false); @@ -257,7 +259,7 @@ page: start, endPage: end }).then(res => { - console.log('res', res) + // console.log('res', res) this.handlerFile(res); this.escHandler(); }) diff --git a/Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue b/Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue index 4157faa..92973d5 100644 --- a/Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue +++ b/Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue @@ -578,24 +578,27 @@ exportGroupCodeExcel({ codeClassifyOid: this.codeClassifyOid, }).then(res => { - let reader = new FileReader(); - reader.readAsText(res.data) - reader.onload = (result) => { - try { - let resData = JSON.parse(result.target.result); // 瑙f瀽瀵硅薄鎴愬姛 - if (!resData.success) { - console.log("resData", resData) - this.$message.error(resData.msg); - this.isLoading = false; - } - } catch (err) { - // console.log("err",err)// 瑙f瀽鎴愬璞″け璐ワ紝璇存槑鏄甯哥殑鏂囦欢娴� - func.downloadFileByBlobHandler(res); - this.$message.success('涓嬭浇鎴愬姛锛岃鏌ョ湅锛�'); - this.isLoading = false; - } - }; - + // let reader = new FileReader(); + // reader.readAsText(res.data); + // reader.onload = () => { + // try { + // let resData = JSON.parse(reader.result); // 瑙f瀽瀵硅薄鎴愬姛 + // if (!resData.success) { + // this.$message.error(resData.msg); + // this.isLoading = false; + // } + // } catch (err) { + // // 瑙f瀽鎴愬璞″け璐ワ紝璇存槑鏄甯哥殑鏂囦欢娴� + // func.downloadFileByBlobHandler(res); + // this.$message.success('涓嬭浇鎴愬姛锛岃鏌ョ湅锛�'); + // this.isLoading = false; + // } + // }; + func.downloadFileByBlobHandler(res); + this.$message.success('涓嬭浇鎴愬姛锛岃鏌ョ湅锛�'); + this.isLoading = false; + }).catch(error=>{ + this.$message.error(error); }); }, //鏍囧噯鐢宠 diff --git a/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue b/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue index 0fe3d8e..91b2025 100644 --- a/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue +++ b/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue @@ -43,7 +43,7 @@ :defaultExpandAll="false" :option="Treeoption" class="classifyTree" - style="height: calc(100vh - 280px)" + style="height: calc(100vh - 290px)" @node-click="nodeClick" > </avue-tree> @@ -53,7 +53,7 @@ <el-dialog v-loading="AddLoading" :before-close="TreeEscHandler" :title="this.TreeFlag ? '娣诲姞鍒嗙被' :'娣诲姞涓婚搴�'" :visible.sync="TreeAddFormVisible" append-to-body style="width: 1700px;margin: auto"> - <el-form ref="myForm" :model="TreeAddform" :rules="rules"> + <el-form ref="myForm" :model="TreeAddform" :rules= "rules"> <el-form-item :label="this.TreeFlag ? '鍒嗙被缂栧彿锛�' :'涓婚搴撶紪鍙凤細'" label-width="150px" prop="id" style="display: inline-block"> <el-input v-model="TreeAddform.id" autocomplete="off" style="width: 170px"></el-input> @@ -892,7 +892,6 @@ this.$message.warning('璇疯嚦灏戦�夋嫨涓�鏉℃暟鎹紒') return; } - console.log(this.nodeClickList.oid) flowingDependencyGen(this.nodeClickList.oid).then(res => { this.$message.success('鎿嶄綔鎴愬姛') }).catch(res => { @@ -902,7 +901,6 @@ // switch switchChange() { this.TreeAddform.isParticipateCheck = this.TreeAddform.codeKeyAttrValue === true ? 1 : 0; - // console.log(this.TreeAddform.isParticipateCheck) }, //瀛樺偍鐨勪笟鍔$被鍨嬪叧闂� BtmEscHandler() { @@ -1346,7 +1344,7 @@ }); } } catch (error) { - console.error(error); + // console.error(error); } finally { this.loading = false; } @@ -1389,7 +1387,7 @@ }); } } catch (error) { - console.error(error); + // console.error(error); } finally { this.loading = false; } @@ -1459,7 +1457,7 @@ } }, treeClick(e) { - console.log(e); + // console.log(e); }, //鍩烘湰淇℃伅琛ㄥ崟鍒锋柊 referTreeForm() { diff --git a/Source/UBCS-WEB/src/const/code/codebasic.js b/Source/UBCS-WEB/src/const/code/codebasic.js index 712b74a..511f52b 100644 --- a/Source/UBCS-WEB/src/const/code/codebasic.js +++ b/Source/UBCS-WEB/src/const/code/codebasic.js @@ -1,5 +1,5 @@ export default { - height:'260', + tip: false, editBtn: false, addBtn: false, diff --git a/Source/UBCS-WEB/src/const/code/mdmrule.js b/Source/UBCS-WEB/src/const/code/mdmrule.js index 855f936..0b1d4c3 100644 --- a/Source/UBCS-WEB/src/const/code/mdmrule.js +++ b/Source/UBCS-WEB/src/const/code/mdmrule.js @@ -1,7 +1,5 @@ export default { - height:"270", tip: false, - editBtn:false, searchShow: true, searchMenuSpan: 6, border: true, diff --git a/Source/UBCS-WEB/src/views/code/code.vue b/Source/UBCS-WEB/src/views/code/code.vue index 9455958..03b6b62 100644 --- a/Source/UBCS-WEB/src/views/code/code.vue +++ b/Source/UBCS-WEB/src/views/code/code.vue @@ -2,144 +2,147 @@ <basic-container class="code-total" style=" height: 100%"> <!-- 缂栫爜瑙勫垯淇℃伅灞曠ず鍖哄煙 --> <basic-container class="code-rule-container"> - <p - style=" + <div style="height: 40vh;overflow: auto;"> + <p + style=" margin-top: -5px; margin-bottom: 4px; font-weight: 570; font-size: 19px; color: #0e2d5f; " - > - 缂栫爜瑙勫垯 - </p> - <avue-crud - ref="crud" - v-model="ruleForm" - :before-open="beforeOpen" - :data="data" - :option="optionRule" - :page.sync="page" - :permission="permissionList" - :table-loading="loading" - class="code-rule-crud" - @row-click="codeRuleRowClick" - @row-update="rowUpdate" - @row-save="rowSave" - @search-change="searchChange" - @search-reset="searchReset" - @selection-change="selectionChange" - @current-change="currentChange" - @size-change="sizeChange" - @refresh-change="refreshChange" - @on-load="onLoad" - > - <!-- 琛ㄦ牸鍐呮搷浣滄寜閽� --> - <template slot="menu" slot-scope="scope"> - <el-button v-if="permissionList.editBtn && (scope.row.lcStatus == 'Editing' ? true : false)" - icon="el-icon-edit" - plain - size="small" - type="text" - @click="openEdit(scope.row)" - >缂� 杈� - </el-button> - <el-button v-if="permissionList.releaseBtn && (scope.row.lcStatus == 'Editing' ? true : false)" - :loading="releadDisabled" - icon="el-icon-position" - plain - size="small" - type="text" - @click="enableOrDeactivatse(scope.row.oid, 'release')" - >鍙� 甯� - </el-button> - <el-button v-if="permissionList.deactivateBtn && (scope.row.lcStatus == 'Released' ? true : false)" - icon="el-icon-video-pause" - plain - size="small" - type="text" - @click="enableOrDeactivatse(scope.row.oid, 'disable')" - >鍋� 鐢� - </el-button> - <el-button v-if="permissionList.enableBtn && (scope.row.lcStatus == 'Disabled' ? true : false)" - icon="el-icon-video-play" - plain - size="small" - type="text" - @click="enableOrDeactivatse(scope.row.oid, 'enable')" - >鍚� 鐢� - </el-button> - </template> - <!-- 琛ㄦ牸涓婃柟鎸夐挳鍖哄煙 --> - <template slot="menuLeft" slot-scope="scope"> - <el-button v-if="permissionList.rulDelBtn" - icon="el-icon-delete" - plain - size="small" - type="danger" - @click="handleDelete" - > - 鍒� 闄� - </el-button> - <el-button v-if="permissionList.advancedQueryBtn" - icon="el-icon-search" - plain - size="small" - type="primary" - @click="openAdvancedQuery('codeRule')"> - 楂樼骇鏌ヨ - </el-button> - <el-button v-if="permissionList.cloneBtn" - icon="icon-kelong" - plain - size="small" - @click="openCodeRuleDialog" - > - 鍏� 闅� - </el-button> - <el-button v-if="permissionList.otherCloneBtn" - icon="icon-lianjiekelong" - plain - size="small" - style="font-size: 12px" - @click="openOtherCodeRuleDialog" - > - 浠庡叾浠栬鍒欎腑鍏嬮殕鐮佹 - </el-button> - <el-button v-if="permissionList.usescopeBtn" - icon="el-icon-s-help" - plain - size="small" - @click="handleRange" - > - 浣跨敤鑼冨洿 - </el-button> - <el-button v-if="permissionList.clearBtn" - icon="icon-qingkong" - plain - size="small" - @click="clearAllCodeSec" - > - 娓呯┖鐮佸�� - </el-button> - <el-button v-if="permissionList.escapeOwnerBtn" - icon="el-icon-guide" - plain - size="small" - @click="escapeOwner" - > - 杞Щ鎵�鏈夎�� - </el-button> - <el-button v-if="permissionList.maxSerialnumBtn" - icon="el-icon-data-analysis" - plain - size="small" - @click="maxSerialNum" - > - 鏈�澶ф祦姘村彿 - </el-button> - </template> - </avue-crud> + > + 缂栫爜瑙勫垯 + </p> + <avue-crud + ref="crud" + v-model="ruleForm" + :before-open="beforeOpen" + :data="data" + :option="optionRule" + :page.sync="page" + :permission="permissionList" + :table-loading="loading" + class="code-rule-crud" + @row-click="codeRuleRowClick" + @row-update="rowUpdate" + @row-save="rowSave" + @search-change="searchChange" + @search-reset="searchReset" + @selection-change="selectionChange" + @current-change="currentChange" + @size-change="sizeChange" + @refresh-change="refreshChange" + @on-load="onLoad" + > + <!-- 琛ㄦ牸鍐呮搷浣滄寜閽� --> + <template slot="menu" slot-scope="scope"> + <el-button v-if="permissionList.editBtn && (scope.row.lcStatus == 'Editing' ? true : false)" + icon="el-icon-edit" + plain + size="small" + type="text" + @click="openEdit(scope.row)" + >缂� 杈� + </el-button> + <el-button v-if="permissionList.releaseBtn && (scope.row.lcStatus == 'Editing' ? true : false)" + :loading="releadDisabled" + icon="el-icon-position" + plain + size="small" + type="text" + @click="enableOrDeactivatse(scope.row.oid, 'release')" + >鍙� 甯� + </el-button> + <el-button v-if="permissionList.deactivateBtn && (scope.row.lcStatus == 'Released' ? true : false)" + icon="el-icon-video-pause" + plain + size="small" + type="text" + @click="enableOrDeactivatse(scope.row.oid, 'disable')" + >鍋� 鐢� + </el-button> + <el-button v-if="permissionList.enableBtn && (scope.row.lcStatus == 'Disabled' ? true : false)" + icon="el-icon-video-play" + plain + size="small" + type="text" + @click="enableOrDeactivatse(scope.row.oid, 'enable')" + >鍚� 鐢� + </el-button> + </template> + <!-- 琛ㄦ牸涓婃柟鎸夐挳鍖哄煙 --> + <template slot="menuLeft" slot-scope="scope"> + <el-button v-if="permissionList.rulDelBtn" + icon="el-icon-delete" + plain + size="small" + type="danger" + @click="handleDelete" + > + 鍒� 闄� + </el-button> + <el-button v-if="permissionList.advancedQueryBtn" + icon="el-icon-search" + plain + size="small" + type="primary" + @click="openAdvancedQuery('codeRule')"> + 楂樼骇鏌ヨ + </el-button> + <el-button v-if="permissionList.cloneBtn" + icon="icon-kelong" + plain + size="small" + @click="openCodeRuleDialog" + > + 鍏� 闅� + </el-button> + <el-button v-if="permissionList.otherCloneBtn" + icon="icon-lianjiekelong" + plain + size="small" + style="font-size: 12px" + @click="openOtherCodeRuleDialog" + > + 浠庡叾浠栬鍒欎腑鍏嬮殕鐮佹 + </el-button> + <el-button v-if="permissionList.usescopeBtn" + icon="el-icon-s-help" + plain + size="small" + @click="handleRange" + > + 浣跨敤鑼冨洿 + </el-button> + <el-button v-if="permissionList.clearBtn" + icon="icon-qingkong" + plain + size="small" + @click="clearAllCodeSec" + > + 娓呯┖鐮佸�� + </el-button> + <el-button v-if="permissionList.escapeOwnerBtn" + icon="el-icon-guide" + plain + size="small" + @click="escapeOwner" + > + 杞Щ鎵�鏈夎�� + </el-button> + <el-button v-if="permissionList.maxSerialnumBtn" + icon="el-icon-data-analysis" + plain + size="small" + @click="maxSerialNum" + > + 鏈�澶ф祦姘村彿 + </el-button> + </template> + </avue-crud> + </div> + </basic-container> <!-- 楂樼骇鏌ヨ瀵硅瘽妗� --> @@ -217,105 +220,107 @@ <!-- 鍩虹鐮佹灞曠ず鍖哄煙 --> <basic-container class="code-basicsec-container"> - <p - style="margin-top: -5px; + <div style="height: 38.5vh;overflow: auto"> + <p + style="margin-top: -5px; margin-bottom: 4px; font-weight: 570; font-size: 19px; color: #0e2d5f;"> - 鐮佹绠$悊 - </p> - <avue-crud - ref="crudBasic" - :data="basicData" - :option="optionBasic" - :permission="basicPermissionList" - :table-loading="loadingBasic" - class="code-basic-crud" - @row-click="codeBasicSecRowClick" - @search-change="basicSearchChange" - @search-reset="basicSearchReset" - @selection-change="selectionBasicChange" - @refresh-change="refreshChangeBasicSec" - > - <!-- 鍩虹鐮佹琛ㄦ牸鍐呮搷浣滄寜閽� --> - <template slot="menu" slot-scope="scope"> - <el-button v-if="basicPermissionList.viewBtn && currentRuleLcStatus != 'Editing'" - icon="el-icon-view" - plain - size="small" - type="text" - @click="openBasicDialog('view', scope.row)" - >鏌ョ湅 - </el-button> - <el-button v-if="basicPermissionList.editBtn && currentRuleLcStatus === 'Editing'" - icon="el-icon-edit" - plain - size="small" - type="text" - @click="openBasicDialog('edit', scope.row)" - >缂栬緫 - </el-button> - <el-button - v-if="basicPermissionList.basicMgrBtn && (scope.row.secType === 'codeclassifysec' || scope.row.secType == 'codefixedsec')" - icon="el-icon-setting" - plain - size="small" - type="text" - @click="openBasicSecCodeValueMgr(scope.row)" - >鐮佸�肩鐞� - </el-button> - <el-button v-if="basicPermissionList.basicMoveupBtn && scope.row.orderNum > 1" - icon="el-icon-arrow-up" - plain - size="small" - type="text" - @click="upOrderNum(scope.row)" - >涓婄Щ - </el-button> - <el-button v-if="basicPermissionList.basicDownBtn" - icon="el-icon-arrow-down" - plain - size="small" - type="text" - @click="downOrderNum(scope.row)" - >涓嬬Щ - </el-button> - </template> + 鐮佹绠$悊 + </p> + <avue-crud + ref="crudBasic" + :data="basicData" + :option="optionBasic" + :permission="basicPermissionList" + :table-loading="loadingBasic" + class="code-basic-crud" + @row-click="codeBasicSecRowClick" + @search-change="basicSearchChange" + @search-reset="basicSearchReset" + @selection-change="selectionBasicChange" + @refresh-change="refreshChangeBasicSec" + > + <!-- 鍩虹鐮佹琛ㄦ牸鍐呮搷浣滄寜閽� --> + <template slot="menu" slot-scope="scope"> + <el-button v-if="basicPermissionList.viewBtn && currentRuleLcStatus != 'Editing'" + icon="el-icon-view" + plain + size="small" + type="text" + @click="openBasicDialog('view', scope.row)" + >鏌ョ湅 + </el-button> + <el-button v-if="basicPermissionList.editBtn && currentRuleLcStatus === 'Editing'" + icon="el-icon-edit" + plain + size="small" + type="text" + @click="openBasicDialog('edit', scope.row)" + >缂栬緫 + </el-button> + <el-button + v-if="basicPermissionList.basicMgrBtn && (scope.row.secType === 'codeclassifysec' || scope.row.secType == 'codefixedsec')" + icon="el-icon-setting" + plain + size="small" + type="text" + @click="openBasicSecCodeValueMgr(scope.row)" + >鐮佸�肩鐞� + </el-button> + <el-button v-if="basicPermissionList.basicMoveupBtn && scope.row.orderNum > 1" + icon="el-icon-arrow-up" + plain + size="small" + type="text" + @click="upOrderNum(scope.row)" + >涓婄Щ + </el-button> + <el-button v-if="basicPermissionList.basicDownBtn" + icon="el-icon-arrow-down" + plain + size="small" + type="text" + @click="downOrderNum(scope.row)" + >涓嬬Щ + </el-button> + </template> - <!-- 鍩虹鐮佹琛ㄦ牸宸︿笂鏂规寜閽尯鍩� --> - <template slot="menuLeft" slot-scope="scope"> - <el-button v-if="basicPermissionList.addBtn" - :disabled="selectionList.length <= 0" - icon="el-icon-plus" - size="small" - type="primary" - @click="openAddBasicCodeSec" - > - 鏂� 澧� - </el-button> - <el-button v-if="basicPermissionList.basicDelBtn" - :disabled="selectionList.length <= 0" - icon="el-icon-delete" - plain - size="small" - type="danger" - @click="deleteBasicCode(scope.row)" - > - 鍒� 闄� - </el-button> - <el-button v-if="basicPermissionList.basicAdvancedQueryBtn" - :disabled="selectionList.length <= 0" - icon="el-icon-search" - plain - size="small" - type="primary" - @click="openAdvancedQuery('codeBasicSec')" - > - 楂樼骇鏌ヨ - </el-button> - </template> - </avue-crud> + <!-- 鍩虹鐮佹琛ㄦ牸宸︿笂鏂规寜閽尯鍩� --> + <template slot="menuLeft" slot-scope="scope"> + <el-button v-if="basicPermissionList.addBtn" + :disabled="selectionList.length <= 0" + icon="el-icon-plus" + size="small" + type="primary" + @click="openAddBasicCodeSec" + > + 鏂� 澧� + </el-button> + <el-button v-if="basicPermissionList.basicDelBtn" + :disabled="selectionList.length <= 0" + icon="el-icon-delete" + plain + size="small" + type="danger" + @click="deleteBasicCode(scope.row)" + > + 鍒� 闄� + </el-button> + <el-button v-if="basicPermissionList.basicAdvancedQueryBtn" + :disabled="selectionList.length <= 0" + icon="el-icon-search" + plain + size="small" + type="primary" + @click="openAdvancedQuery('codeBasicSec')" + > + 楂樼骇鏌ヨ + </el-button> + </template> + </avue-crud> + </div> </basic-container> <!-- 鐮佹鐮佸�肩鐞嗗璇濇 --> @@ -587,7 +592,7 @@ > <!-- 绗竴灞傚璇濇,娣诲姞鐮佹淇℃伅瀵硅瘽妗嗕腑鐨勫唴瀹� --> <div class="add-basicsec-total"> - <el-form :model="form" class="add-basicsec-form" :rules="rules" > + <el-form :model="form" :rules="rules" class="add-basicsec-form"> <span class="left"> <el-form-item :label-width="leftFormLabelWidth" @@ -883,11 +888,11 @@ <template> <vciWebRefer ref="refer" - :referConfig="this.referConfig || {}" :display="true" - :value="form.customCodeSerialClass" - :text="form.customCodeSerialClassText" + :referConfig="this.referConfig || {}" :serialType="form.serialType" + :text="form.customCodeSerialClassText" + :value="form.customCodeSerialClass" @setReferValue="setReferValue" ></vciWebRefer> </template> @@ -1023,9 +1028,9 @@ <!-- 鏃ユ湡鐮佹 --> <div v-show="form.secType === 'codedatesec' ? true : false"> <el-form-item - prop="Dateformat" :label-width="rightFormLabelWidth" label="鏃ユ湡鏍煎紡:" + prop="Dateformat" > <el-input ref="codeDateFormatStr" @@ -1343,7 +1348,7 @@ import vciWebRefer from "../../components/refer/vciWebRefer"; export default { - components: { vciWebRefer }, + components: {vciWebRefer}, data() { return { rules: { @@ -1352,7 +1357,7 @@ required: true, trigger: 'blur', validator: (rule, value, callback) => { - const Formats = ['yy', 'yyyy', 'yyyy-MM', 'yy-MM', 'yyyy-MM-dd','yy-MM-dd', 'yyyy-MM-dd HH:mm:ss', 'yy-MM-dd HH:mm:ss', 'HH:mm:ss']; + const Formats = ['yy', 'yyyy', 'yyyy-MM', 'yy-MM', 'yyyy-MM-dd', 'yy-MM-dd', 'yyyy-MM-dd HH:mm:ss', 'yy-MM-dd HH:mm:ss', 'HH:mm:ss']; if (!Formats.includes(this.form.codeDateFormatStr)) { return callback(new Error('璇疯緭鍏ユ纭棩鏈熸牸寮忥紝渚嬪yyyy-MM-dd锛堝苟鍖哄垎澶у皬鍐欙級锛�')); } @@ -1361,19 +1366,19 @@ } ] }, - referConfig:{ + referConfig: { title: '鑷畾涔夋祦姘村弬鐓�', showField: 'customCodeSerialClassText', field: 'customCodeSerialClass', - fieldMap: { - serialType:"serialType" + fieldMap: { + serialType: "serialType" }, - placeholder:'璇烽�夋嫨鑷畾涔夋祦姘�', - options: { + placeholder: '璇烽�夋嫨鑷畾涔夋祦姘�', + options: { // 璁剧疆榛樿鐨勫睘鎬� url: 'api/ubcs-code/codeSerialAlgorithmController/gridCodeSerialAlgorithm', - textField:'name', - valueField:'classFullName', + textField: 'name', + valueField: 'classFullName', isMuti: false, type: "grid", method: 'get', @@ -1715,8 +1720,8 @@ }, methods: { //鑷畾涔夋祦姘村け鐒� - setReferValue(data){ - if(data.field){ + setReferValue(data) { + if (data.field) { this.form[data.field] = data.value || ""; this.form[data.showField] = data.text || ""; this.form.serialType = data.rawData[0].serialType || ""; @@ -2779,7 +2784,7 @@ } //console.log(this.form); //涓篺orm缁戝畾鍊� - this.changeSectypeFormItems(condition == "add" ? null:row); + this.changeSectypeFormItems(condition == "add" ? null : row); this.addBasicCodeSettingBox = true; }, /** 鏂板鍩虹鐮佹*/ @@ -3549,10 +3554,6 @@ font-size: 12px !important; } -.code-rule-crud > .avue-crud__search, -.code-basic-crud > .avue-crud__search { - margin-bottom: -15px; -} .clone-input-textarea > .el-form-item__content { width: 495px; diff --git a/Source/UBCS-WEB/src/views/integration/systemInfo.vue b/Source/UBCS-WEB/src/views/integration/systemInfo.vue index 56d9cd9..d7707ef 100644 --- a/Source/UBCS-WEB/src/views/integration/systemInfo.vue +++ b/Source/UBCS-WEB/src/views/integration/systemInfo.vue @@ -1,6 +1,7 @@ <template> <basic-container> - <avue-crud ref="crud" :data="data" :option="option" :page.sync="page" :permission="permissionList" :search.sync="search" + <avue-crud ref="crud" :data="data" :option="option" :page.sync="page" :permission="permissionList" + :search.sync="search" :table-loading="loading" @on-load="getDataList" @row-save="handleSave" @row-del="handleDelete" @row-update="handleEdit" @refresh-change="handleRefresh" @size-change="handleSizePage" @current-change="handleCurrentPage" diff --git a/Source/UBCS-WEB/src/views/modeling/Business.vue b/Source/UBCS-WEB/src/views/modeling/Business.vue index eef4952..fb9fdec 100644 --- a/Source/UBCS-WEB/src/views/modeling/Business.vue +++ b/Source/UBCS-WEB/src/views/modeling/Business.vue @@ -1,30 +1,30 @@ <template> <el-container> - <el-header class="businessHeader" style="height: 40px;padding:0 8px"> - <div> - <el-button v-if="permissionList.addBtn" icon="el-icon-plus" size="small" type="primary" @click="businessAdd" plain> - 鏂板 - </el-button> - <el-button v-if="permissionList.editBtn" icon="el-icon-edit" size="small" type="primary" @click="businessEdit" plain> - 淇敼 - </el-button> - <el-button v-if="permissionList.table" icon="el-icon-thumb" size="small" type="primary" - @click="selectFromTable" plain> 浠庡凡鏈変腑鑾峰彇 - </el-button> - </div> - </el-header> +<!-- <el-header class="businessHeader" style="height: 40px;padding:0 8px">--> + +<!-- </el-header>--> <el-container> - <el-aside style="width:250px"> + <el-aside style="width: 20%"> <basic-container class="businessTreeContainer"> <div class="app"> - <p style="margin-top: 10px;font-weight: 570;font-size: 19px">{{ treeOption.title }}</p> - <avue-tree id="basic" :data="treeData" :option="treeOption" class="businessTree" @node-click="nodeClick"> - <span slot-scope="{ node, data }" class="el-tree-node__label"> + <div style="display: flex;margin-bottom: 10px;justify-content: space-around;"> + <el-button v-if="permissionList.addBtn" size="mini" type="primary" @click="businessAdd" plain style="width: 60px"> + 鏂板 + </el-button> + <el-button v-if="permissionList.editBtn" size="mini" type="primary" @click="businessEdit" plain style="width: 60px"> + 淇敼 + </el-button> + <el-button v-if="permissionList.table" size="mini" type="primary" + @click="selectFromTable" plain> 浠庡凡鏈変腑鑾峰彇 + </el-button> + </div> + <avue-tree :data="treeData" :option="treeOption" class="businessTree" @node-click="nodeClick" style="width: fit-content;"> + <template slot-scope="{ node, data }" class="el-tree-node__label"> <span> <i :class="(node || {}).level === 2 ? 'el-icon-star-off' : 'el-icon-folder-opened'"></i> {{ (node || {}).label }} </span> - </span> + </template> </avue-tree> </div> @@ -171,7 +171,7 @@ selectionList: [], treeData: [], treeOption: { - defaultExpandAll: true, + defaultExpandAll: false, title: '涓氬姟绫诲瀷鏍�', addBtn: false, menu: false, @@ -186,8 +186,8 @@ btmType: {}, }, loadOption: { + height:'auto', border: true, - height: 478, editBtn: false, addBtn: false, menu: false, @@ -381,11 +381,7 @@ } </script> -<style lang="scss"> -#basic { - height: 770px; - border-radius: 10px; -} +<style lang="scss" scoped> .businessCrud > .el-card:nth-of-type(2) > .el-card__body > .avue-crud__menu { display: none !important; @@ -395,6 +391,28 @@ display: none !important; } -.businessTreeContainer > .el-card > .el-card__body { - height: 775px; -}</style> + +.app { + overflow: auto; + height: 84.3vh; +} + +.app::-webkit-scrollbar { + height: 15px; // 绾靛悜婊氬姩鏉� 蹇呭啓 + background: white; + border: white; + width: 10px; + +} + +// 婊氬姩鏉$殑婊戝潡 +.app::-webkit-scrollbar-thumb { + width: 10px; + height: 10px; + background-color: #ececec; + border-radius: 20px; + border: #ececec; +} + + +</style> diff --git a/Source/UBCS-WEB/src/views/modeling/LinkType.vue b/Source/UBCS-WEB/src/views/modeling/LinkType.vue index a26c55d..d28d2bc 100644 --- a/Source/UBCS-WEB/src/views/modeling/LinkType.vue +++ b/Source/UBCS-WEB/src/views/modeling/LinkType.vue @@ -1,30 +1,30 @@ <template> <el-container> <!-- 椤剁鎸夐挳 --> - <el-header class="businessHeader" style="height: 40px;"> - <div> - <el-button type="primary" @click="linkTypeAdd" size="small" icon="el-icon-plus" v-if="permissionList.addBtn" plain> - 鏂板 - </el-button> - <el-button type="primary" @click="linkTypeEdit" size="small" icon="el-icon-edit" v-if="permissionList.editBtn" plain> - 淇敼 - </el-button> - </div> - </el-header> + <!-- 渚ц竟鏍忔爲 --> <el-container> - <el-aside width="240px"> + <el-aside style="width: 20%;"> <basic-container class="businessTreeContainer"> - <p style="margin-top: 10px;font-weight: 570;font-size: 19px">{{ treeOption.title }}</p> - <avue-tree id="basic" :data="treeData" :option="treeOption" @node-click="nodeClick" - class="businessTree"> - <span class="el-tree-node__label" slot-scope="{ node, data }"> + <div class="app"> + <div style="display: flex;margin-bottom: 10px;"> + <el-button type="primary" @click="linkTypeAdd" size="mini" v-if="permissionList.addBtn" plain> + 鏂板 + </el-button> + <el-button type="primary" @click="linkTypeEdit" size="mini" v-if="permissionList.editBtn" plain> + 淇敼 + </el-button> + </div> + <avue-tree :data="treeData" :option="treeOption" @node-click="nodeClick" + class="businessTree"> + <template class="el-tree-node__label" slot-scope="{ node, data }"> <span> <i class="el-icon-star-on"></i> {{ (node || {}).label }} </span> - </span> + </template> </avue-tree> + </div> </basic-container> </el-aside> <el-container> @@ -178,7 +178,7 @@ }, loadOption: { border: true, - height: 395, + height: 'auto', editBtn: false, addBtn: false, menu: false, @@ -215,6 +215,7 @@ }, obj: {}, treeOption: { + height:'auto', defaultExpandAll: true, title: '閾炬帴绫诲瀷鏍�', addBtn: false, @@ -285,8 +286,31 @@ } </script> -<style lang="scss"> +<style lang="scss" scoped> .attributeCrud>.el-card:nth-of-type(2)>.el-card__body>.avue-crud__menu { display: none !important; } +.app { + overflow: auto; + height: 84.3vh; +} + +.app::-webkit-scrollbar { + height: 15px; // 绾靛悜婊氬姩鏉� 蹇呭啓 + background: white; + border: white; + width: 10px; + +} + +// 婊氬姩鏉$殑婊戝潡 +.app::-webkit-scrollbar-thumb { + width: 10px; + height: 10px; + background-color: #ececec; + border-radius: 20px; + border: #ececec; +} + + </style> diff --git a/Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue b/Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue index a92827c..32997d5 100644 --- a/Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue +++ b/Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue @@ -21,83 +21,21 @@ border style="width: 100%;height: calc(100vh - 320px)" @cell-click="cellClickHandler"> - <el-table-column - align="center" - label="1" - prop="1" - > - </el-table-column> - <el-table-column - align="center" - label="2" - prop="2" - > - </el-table-column> - <el-table-column - align="center" - label="3" - prop="3"> - </el-table-column> - <el-table-column - align="center" - label="4" - prop="4"> - </el-table-column> - <el-table-column - align="center" - label="5" - prop="5"> - </el-table-column> - <el-table-column - align="center" - label="6" - prop="6"> - </el-table-column> - <el-table-column - align="center" - label="7" - prop="7"> - </el-table-column> - <el-table-column - align="center" - label="8" - prop="8"> - </el-table-column> - <el-table-column - align="center" - label="9" - prop="9"> - </el-table-column> - <el-table-column - align="center" - label="10" - prop="10"> - </el-table-column> - <el-table-column - align="center" - label="11" - prop="11"> - </el-table-column> - <el-table-column - align="center" - label="12" - prop="12"> - </el-table-column> - <el-table-column - align="center" - label="13" - prop="13"> - </el-table-column> - <el-table-column - align="center" - label="14" - prop="14"> - </el-table-column> - <el-table-column - align="center" - label="15" - prop="15"> - </el-table-column> + <el-table-column align="center" label="1" prop="1"></el-table-column> + <el-table-column align="center" label="2" prop="2"></el-table-column> + <el-table-column align="center" label="3" prop="3"></el-table-column> + <el-table-column align="center" label="4" prop="4"></el-table-column> + <el-table-column align="center" label="5" prop="5"></el-table-column> + <el-table-column align="center" label="6" prop="6"></el-table-column> + <el-table-column align="center" label="7" prop="7"></el-table-column> + <el-table-column align="center" label="8" prop="8"></el-table-column> + <el-table-column align="center" label="9" prop="9"></el-table-column> + <el-table-column align="center" label="10" prop="10"></el-table-column> + <el-table-column align="center" label="11" prop="11"></el-table-column> + <el-table-column align="center" label="12" prop="12"></el-table-column> + <el-table-column align="center" label="13" prop="13"></el-table-column> + <el-table-column align="center" label="14" prop="14"></el-table-column> + <el-table-column align="center" label="15" prop="15"></el-table-column> </el-table> </el-main> <el-footer> @@ -230,7 +168,7 @@ // const targetObject = this.characterReleasedList.find(obj => obj.oid === this.selectValue); // const chartValue = targetObject.name; getList({codeRuleId: this.select, chartType: "charset", chartValue: this.characterValue}).then(res => { - console.log(res.data.data); + // console.log(res.data.data); this.tableData = res.data.data; this.loading = false; }); diff --git a/Source/UBCS-WEB/src/views/statistic/statisticPage.vue b/Source/UBCS-WEB/src/views/statistic/statisticPage.vue index 9403436..cf4ee2f 100644 --- a/Source/UBCS-WEB/src/views/statistic/statisticPage.vue +++ b/Source/UBCS-WEB/src/views/statistic/statisticPage.vue @@ -48,7 +48,7 @@ </span> </el-dialog> <!-- echarts缁勪欢--> - <div style="margin-top: 15px"> + <div style="margin-top: 15px;padding-bottom: 35px"> <lineChart v-for="(item,index) in lineList" :key="index" :chartName="item.menuName" :lineData="item.menuData"></lineChart> <pieChart v-for="(item,index) in pieList" :key="index" :chartName="item.menuName" diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/constant/MdmEngineConstant.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/constant/MdmEngineConstant.java index ae75383..d941f9a 100644 --- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/constant/MdmEngineConstant.java +++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/constant/MdmEngineConstant.java @@ -177,7 +177,7 @@ public static final List DEFAULT_SYNC_ATTR_LIST = new ArrayList(){{ add(CODE_FIELD); add(CODE_STATUS_FILED); - add(CODE_GROUP_FIELD); + //add(CODE_GROUP_FIELD); add(CODE_CLASSIFY_OID_FIELD); add(CODE_TEMPLATE_OID_FIELD); add(CODE_FULL_PATH_FILED); diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/controller/MdmEngineController.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/controller/MdmEngineController.java index c580a29..540cb51 100644 --- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/controller/MdmEngineController.java +++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/controller/MdmEngineController.java @@ -106,7 +106,6 @@ } } - /** * 瀵煎叆鎵归噺缂栬緫鏁版嵁 * @param codeClassifyOid 鍒嗙被鐨勪富閿� diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/MdmProductCodeService.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/MdmProductCodeService.java index 67b6fde..f22f48f 100644 --- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/MdmProductCodeService.java +++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/MdmProductCodeService.java @@ -2,6 +2,7 @@ import com.vci.ubcs.code.bo.CodeClassifyFullInfoBO; import com.vci.ubcs.code.dto.CodeOrderSecDTO; +import com.vci.ubcs.code.vo.pagemodel.CodeBasicSecVO; import com.vci.ubcs.code.vo.pagemodel.CodeClassifyTemplateVO; import com.vci.ubcs.code.vo.pagemodel.CodeRuleVO; import com.vci.ubcs.starter.revision.model.BaseModel; @@ -41,4 +42,13 @@ */ List<String> productCodeAndSaveDataBZ(CodeClassifyFullInfoBO classifyFullInfoBO, CodeClassifyTemplateVO templateVO, CodeRuleVO ruleVO, List<CodeOrderSecDTO> secDTOList, List<BaseModel> dataCBOList) throws Exception; + + /** + * 鐮佹鍓嶅悗缂�鎷兼帴 + * @param secVO + * @param secValue + * @return + */ + String joinPreffixAndSuffix(CodeBasicSecVO secVO, String secValue); + } diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java index 058a663..6b4bca3 100644 --- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java +++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java @@ -13,9 +13,7 @@ import com.vci.ubcs.code.bo.CodeTemplateAttrSqlBO; import com.vci.ubcs.code.dto.*; import com.vci.ubcs.code.entity.CodeAllCode; -import com.vci.ubcs.code.enumpack.CodeDefaultLC; -import com.vci.ubcs.code.enumpack.CodeLevelTypeEnum; -import com.vci.ubcs.code.enumpack.sysIntegrationPushTypeEnum; +import com.vci.ubcs.code.enumpack.*; import com.vci.ubcs.code.lifecycle.CodeAllCodeLC; import com.vci.ubcs.code.mapper.CommonsMapper; import com.vci.ubcs.code.service.*; @@ -383,7 +381,7 @@ CodeClassifyVO codeClassifyVO = classifyService.getObjectByOid(codeClassifyOid); //鑾峰彇鐮佹瀹藉害 - //String secWidth = getCodeSegmentWidth(codeClassifyVO.getOid()); + String secWidth = getCodeSegmentWidth(codeClassifyVO.getOid()); if(isHistory){ templateVOList= templateService.childTemplates(codeClassifyOid); @@ -434,6 +432,8 @@ excelDataList.add(new WriteExcelData(0,0,"鍒嗙被璺緞","")); excelDataList.add(new WriteExcelData(0,1,"鐮佹瀹藉害","")); excelDataList.add(new WriteExcelData(0,2,!CollectionUtils.isEmpty(idAttrVOList)?idAttrVOList.get(0).getName():"浼佷笟缂栫爜",idAttrVOList.get(0).getId())); + // 濉厖鐮佹 + excelDataList.add(new WriteExcelData(1,1,secWidth)); } for (int i = 0; i < templateAttrVOS.size(); i++) { CodeClassifyTemplateAttrVO attrVO = templateAttrVOS.get(i); @@ -620,22 +620,121 @@ * @return */ private String getCodeSegmentWidth(String codeClassifyOid){ - CodeClassifyVO codeClassifyVO = classifyService.getObjectByOid(codeClassifyOid); + CodeClassifyFullInfoBO classifyFullInfoBO = classifyService.getClassifyFullInfo(codeClassifyOid); // 瑕佽幏鍙栫爜娈靛搴︼紝鍏堣鑾峰彇瑙勫垯锛屽綋鍓嶆病鏈夊線涓婃壘 CodeRuleVO codeRuleByClassifyFullInfo = mdmEngineService.getCodeRuleByClassifyFullInfo(classifyService.getClassifyFullInfo(codeClassifyOid)); List<CodeBasicSecVO> secVOList = codeRuleByClassifyFullInfo.getSecVOList(); if(secVOList.isEmpty()){ return ""; } - StringBuffer secWidth = new StringBuffer(""); - - for (int j = 0; j < secVOList.size(); j++) { - CodeBasicSecVO secVO = secVOList.get(j); - int width = VciBaseUtil.getInt(secVO.getCodeSecLength()) + ((secVO.getPrefixCode() + secVO.getSuffixCode()).length()); - secWidth.append(width).append("#"); - } + secVOList.stream().forEach(item->{ + switch (item.getSecType().toLowerCase(Locale.ROOT)){ + case "codeclassifysec": + case "codevariablesec": + case "coderefersec": + case "codefixedsec": + case "codeattrsec": + case "codeserialsec": + countSecWith(item,secWidth); + break; + case "codelevelsec": + //灞傜骇鐮佹锛岄渶瑕佷粠鍒嗙被涓婅幏鍙栫浉搴旂殑淇℃伅 + String secValue = ""; + if (CodeLevelTypeEnum.MIN.getValue().equalsIgnoreCase(item.getCodeLevelType())) { + //鏈�灏忓眰锛屽洜涓烘垜浠彧鑳藉湪鍙跺瓙鑺傜偣涓婄敵璇风紪鐮侊紝鎵�浠ヨ繖涓氨鏄綋鍓嶅垎绫荤殑 + if (CodeGetValueTypeEnum.CURRENT.getValue().equalsIgnoreCase(item.getCodeGetValueType()) || CollectionUtils.isEmpty(classifyFullInfoBO.getParentClassifyVOs())) { + //灏辨槸褰撳墠鍒嗙被鐨� + secValue = classifyFullInfoBO.getCurrentClassifyVO().getId(); + } else { + //鎴戜滑闇�瑕佷粠椤跺眰寮�濮嬫壘鍒板綋鍓嶅垎绫讳负姝� + secValue = classifyFullInfoBO.getParentClassifyVOs().stream().sorted(((o1, o2) -> -o1.getDataLevel().compareTo(o2.getDataLevel()))).map(CodeClassifyVO::getId).collect(Collectors.joining()) + classifyFullInfoBO.getCurrentClassifyVO().getId(); + } + } else { + //鎸囧畾灞傦紝鎴戜滑闇�瑕侀�氳繃涓婄骇鐨勬潵鑾峰彇 + if (CollectionUtils.isEmpty(classifyFullInfoBO.getParentClassifyVOs())) { + //璇存槑褰撳墠宸茬粡鏄渶楂樼殑浜� + secValue = classifyFullInfoBO.getCurrentClassifyVO().getId(); + } else { + //杩欎釜鎴戜滑闇�瑕佺湅鐪�,灞傜骇鏄笉鏄ぇ浜庝簡鏈�澶у眰绾х殑鏁� + List<CodeClassifyVO> parentClassifyVOList = classifyFullInfoBO.getParentClassifyVOs().stream().sorted(((o1, o2) -> -o1.getDataLevel().compareTo(o2.getDataLevel()))).collect(Collectors.toList()); + if (item.getCodeLevelValue() > (parentClassifyVOList.size() + 1)) { + //鎸囧畾鐨勫眰绾ф瘮褰撳墠鐨勫眰绾ц繕澶т簡锛屾墍浠ュ彧鑳借幏鍙栧綋鍓嶅眰绾т簡 + if (CodeGetValueTypeEnum.CURRENT.getValue().equalsIgnoreCase(item.getCodeGetValueType())) { + secValue = classifyFullInfoBO.getCurrentClassifyVO().getId(); + } else { + secValue = parentClassifyVOList.stream().map(CodeClassifyVO::getId).collect(Collectors.joining()) + classifyFullInfoBO.getCurrentClassifyVO().getId(); + } + } else { + //鎴戜滑鑾峰彇鍏朵腑鎸囧畾灞傜殑鍐呭 + if (CodeGetValueTypeEnum.CURRENT.getValue().equalsIgnoreCase(item.getCodeGetValueType())) { + CodeClassifyVO classifyVO = parentClassifyVOList.stream().filter(s -> s.getDataLevel().intValue() == item.getCodeLevelValue().intValue()).findFirst().orElseGet(() -> null); + if (classifyVO != null) { + secValue = classifyVO.getId(); + } + } else { + //灏忎簬绛変簬鐨勫叏閮ㄦ嬁鍑烘潵 + secValue = parentClassifyVOList.stream().filter(s -> s.getDataLevel().intValue() <= item.getCodeLevelValue().intValue()).sorted(((o1, o2) -> -o1.getDataLevel().compareTo(o2.getDataLevel()))).map(CodeClassifyVO::getId).collect(Collectors.joining()); + } + } + } + } + //鐪嬬湅闀垮害鏄惁闇�瑕佹埅鏂� + if (!CodeCutTypeEnum.NONE.getValue().equalsIgnoreCase(item.getValueCutType()) && + item.getValueCutLength() != null && item.getValueCutLength() > 0 && secValue.length() > item.getValueCutLength()) { + if (CodeCutTypeEnum.RIGHT.getValue().equalsIgnoreCase(item.getValueCutType())) { + //宸︽埅鍙栨槸浠庡乏杈瑰壀鎺夛紝鍙虫埅鍙栨槸浠庡彸杈瑰壀鎺�--淇濈暀宸﹁竟 + secValue = secValue.substring(0, item.getValueCutLength()); + } else { + secValue = secValue.substring(secValue.length() - item.getValueCutLength()); + } + } + secValue = productCodeService.joinPreffixAndSuffix(item,secValue); + secWidth.append(secValue.length()).append("#"); + break; + case "codedatesec": + String dateFormatStr = item.getCodeDateFormatStr(); + if(Func.isNotEmpty(dateFormatStr)) { + // 鑾峰彇褰撳墠鏃堕棿 + Date currentDate = new Date(); + // 鎸囧畾鏃ユ湡鏍煎紡 + SimpleDateFormat dateFormat = new SimpleDateFormat(dateFormatStr); + // 灏嗗綋鍓嶆椂闂磋浆鎹负鎸囧畾鏃ユ湡鏍煎紡 + // 浣跨敤姝e垯琛ㄨ揪寮忓幓鎺夐櫎鏁板瓧浠ュ鐨勬墍鏈夊瓧绗︿覆 + String cleanedDate = dateFormat.format(currentDate).replaceAll("[^0-9]", ""); + int width = cleanedDate.length(); + if (Func.isNotEmpty(item.getPrefixCode())) { + width += item.getPrefixCode().length(); + } + if (Func.isNotEmpty(item.getSuffixCode())) { + width += item.getSuffixCode().length(); + } + secWidth.append(width).append("#"); + } + break; + } + }); return secWidth.toString().substring(0, secWidth.length() - 1); + } + + /** + * 璁$畻鐮佹闀垮害鍔犲墠鍚庣紑鐨勯暱搴� + * @param codeBasicSecVO + * @param secWidth + */ + private void countSecWith(CodeBasicSecVO codeBasicSecVO,StringBuffer secWidth){ + if(Func.isNotEmpty(codeBasicSecVO.getCodeSecLength())){ + int width = VciBaseUtil.getInt(codeBasicSecVO.getCodeSecLength()); + if(Func.isNotEmpty(codeBasicSecVO.getPrefixCode())){ + width += codeBasicSecVO.getPrefixCode().length(); + } + if(Func.isNotEmpty(codeBasicSecVO.getSuffixCode())){ + width += codeBasicSecVO.getSuffixCode().length(); + } + secWidth.append(width).append("#"); + }else { + secWidth.append(0).append("#"); + } } /** @@ -775,7 +874,7 @@ //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁琛ㄥ崟鏄剧ず鐨勫瓧娈垫墠瀵煎叆 List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s -> !DEFAULT_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); Map<String/**妯℃澘灞炴�у瓧娈祇id**/, String /**妯℃澘灞炴�у閮ㄥ悕绉�**/> fieldNameMap =attrVOS.stream().collect(Collectors.toMap(CodeClassifyTemplateAttrVO::getId,s->s.getName())); @@ -1588,7 +1687,7 @@ //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁琛ㄥ崟鏄剧ず鐨勫瓧娈垫墠瀵煎叆 List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s -> !DEFAULT_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); Map<Integer/**鍒楀彿**/,String/**瀛楁鐨勫悕绉�**/> fieldIndexMap = new HashMap<>(); List<String> titleRowData = dataSet.getColName(); @@ -1837,7 +1936,6 @@ " and lastr = '1'" + " and lastv='1'" + " and codeclsfpath like '%" + exportAttrDTO.getCodeClassifyOid() + "%'"; - //鍏堟煡璇㈡�绘暟 int total = 0; if(exportAttrDTO.getEndPage()!=null && exportAttrDTO.getEndPage()>0 @@ -2053,7 +2151,7 @@ //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁琛ㄥ崟鏄剧ず鐨勫瓧娈垫墠瀵煎叆 List<CodeClassifyTemplateAttrVO> attrVOS = codeClassifyTemplateVO.getAttributes().stream().filter(s -> !DEFAULT_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); String fullPath = getFullPath(classifyFullInfo); excelToCbo(classifyFullInfo,fieldIndexMap,rowDataList, codeClassifyTemplateVO,cboList,fullPath,!isImprot); @@ -2261,7 +2359,7 @@ //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁鍏锋湁鍒嗙被娉ㄥ叆鐨勬墠杩囨护鍑烘潵 List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter( s ->!DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); Map<Integer/**鍒楀彿**/,String/**瀛楁鐨勫悕绉�**/> fieldIndexMap = new HashMap<>(); List<String> titleRowData = dataObjectVO.getColName(); @@ -2632,7 +2730,7 @@ //checkTemplateSync(sheetDataSetList,templateVO); //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁琛ㄥ崟鏄剧ず鐨勫瓧娈垫墠瀵煎叆 List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s -> !DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); Map<Integer/**鍒楀彿**/, String/**瀛楁鐨勫悕绉�**/> fieldIndexMap = new HashMap<>(); List<String> titleRowData = dataObjectVO.getColName(); @@ -4631,7 +4729,7 @@ //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁琛ㄥ崟鏄剧ず鐨勫瓧娈垫墠瀵煎叆 List<CodeClassifyTemplateAttrVO> attrVOS = newTemplateVO.getAttributes().stream().filter(s -> !DEFAULT_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); Map<String/**涓枃鍚嶇О**/, String/**鑻辨枃鍚嶇О**/> attrNameIdMap = attrVOS.stream().collect(Collectors.toMap(s -> s.getName(), t -> t.getId())); List<String> fields=new ArrayList<>(); @@ -5113,7 +5211,7 @@ //鑾峰彇鏈�鏂扮殑妯℃澘 CodeClassifyTemplateVO templateVO = engineService.getUsedTemplateByClassifyOid(codeClassifyOid); //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁琛ㄥ崟鏄剧ず鐨勫瓧娈垫墠瀵煎叆 List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s ->!DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); ExecGroupCodePortDataDTO execGroupCodePortDataDTO=new ExecGroupCodePortDataDTO(); createExportGroupCodeMapConfig(templateVO,execGroupCodePortDataDTO);//缁勭粐鏁版嵁 @@ -5324,7 +5422,7 @@ } //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁琛ㄥ崟鏄剧ず鐨勫瓧娈垫墠瀵煎叆 List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s ->!fieldIndexMap.containsValue(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); attrVOS.stream().forEach(codeClassifyTemplateAttrVO -> {//灏嗕笉闇�瑕佹洿鏀圭殑榛樿瀛楁鎴栬�呬笉鏇存敼鐨勫睘鎬у鍒跺埌鏂扮殑鐗堟湰涓� String arrtibuteKey=codeClassifyTemplateAttrVO.getId(); diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmProductCodeServiceImpl.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmProductCodeServiceImpl.java index 37d80d8..a770015 100644 --- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmProductCodeServiceImpl.java +++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmProductCodeServiceImpl.java @@ -928,7 +928,7 @@ * @param secValue 鐮佸�� * @return */ - private String joinPreffixAndSuffix(CodeBasicSecVO secVO, String secValue){ + public String joinPreffixAndSuffix(CodeBasicSecVO secVO, String secValue){ StringBuilder joinSecValue = new StringBuilder(); // 鎷兼帴鍓嶇紑 if (Func.isNotEmpty(secVO.getPrefixCode()) && Func.isNotEmpty(secValue)) { diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/UniversalInterfaceImpl.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/UniversalInterfaceImpl.java index 2ad3958..301a208 100644 --- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/UniversalInterfaceImpl.java +++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/UniversalInterfaceImpl.java @@ -327,7 +327,7 @@ ApplyDatasVO applyDatasVO = classVO.getObjects(); DataObjectVO dataObjectVO = new DataObjectVO(); List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s -> !DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); this.getConfigDatas(finalSystemId, libray, applyDatasVO, attrVOS, dataObjectVO); log.info("end锛氭暟鎹粍缁囧畬姣�"); @@ -484,7 +484,7 @@ } List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s -> !DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); List<PersonMasterData> personMasterDataList= personData.getMasterData(); @@ -762,7 +762,7 @@ } List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s -> !DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); List<Map> dataList=new ArrayList<>(); List<String> codeList=new ArrayList<>(); @@ -1078,7 +1078,7 @@ DataObjectVO dataObjectVO = new DataObjectVO(); //灏嗛粯璁ょ殑灞炴�у叏閮ㄦ浛鎹㈡帀 List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s -> !DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); this.getConfigDatas(finalSystemId, libray, applyDatasVO, attrVOS, dataObjectVO); log.info("end锛氭暟鎹瀯寤哄畬姣�"); @@ -2083,7 +2083,7 @@ ApplyBZDatasVO applyBZDatasVO = classfyBZVO.getObjects(); DataObjectVO dataObjectVO = new DataObjectVO(); List<CodeClassifyTemplateAttrVO> attrVOS = templateVO.getAttributes().stream().filter(s -> !DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && - (Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag()) + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) ).collect(Collectors.toList()); List<ApplyBZDataVO> applyBZDataVOList= applyBZDatasVO.getObject(); if(applyBZDataVOList.size()>1){ @@ -2538,6 +2538,11 @@ //鏍规嵁鍒嗙被妯℃澘缁勭粐鏁版嵁 final int[] index = {0}; try { + //闄ゅ幓榛樿鐨勫睘鎬�.杩樻湁鍙湁鍏锋湁鍒嗙被娉ㄥ叆鐨勬墠杩囨护鍑烘潵 + codeClassifyTemplateAttrVOList = codeClassifyTemplateAttrVOList.stream().filter( + s ->!DEFAULT_SYNC_ATTR_LIST.contains(s.getId()) && + ((Func.isNotEmpty(s.getClassifyInvokeAttr()) || Func.isNotEmpty(s.getClassifyInvokeAttrName())) || VciBaseUtil.getBoolean(s.getFormDisplayFlag())) + ).collect(Collectors.toList()); codeClassifyTemplateAttrVOList.stream().forEach(codeClassifyTemplateAttrVO -> { String attrName = codeClassifyTemplateAttrVO.getName(); String field = codeClassifyTemplateAttrVO.getId(); -- Gitblit v1.9.3