add 标准详情;更新记录
This commit is contained in:
+13
-5
@@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-config-provider :locale="locale">
|
<a-config-provider :locale="locale">
|
||||||
<div id="app">
|
<div id="app">
|
||||||
<router-view v-if="isRouterAlive"/>
|
<router-view v-if="isRouterAlive" />
|
||||||
<div class="watermark" v-if="show" v-watermark="{text: watermark, textColor: 'rgba(180, 180, 180, 0.2)'}"></div>
|
<div class="watermark" v-if="show" v-watermark="{text: watermark, textColor: 'rgba(180, 180, 180, 0.2)'}"></div>
|
||||||
</div>
|
</div>
|
||||||
</a-config-provider>
|
</a-config-provider>
|
||||||
@@ -16,6 +16,7 @@ import 'moment/locale/zh-cn'
|
|||||||
import '@/utils/warterMark'
|
import '@/utils/warterMark'
|
||||||
// 引入自定义icon
|
// 引入自定义icon
|
||||||
import '@/assets/icon/iconfont.less'
|
import '@/assets/icon/iconfont.less'
|
||||||
|
import Vue from 'vue'
|
||||||
|
|
||||||
moment.locale('zh-cn')
|
moment.locale('zh-cn')
|
||||||
|
|
||||||
@@ -93,14 +94,21 @@ export default {
|
|||||||
moment.locale('en-us')
|
moment.locale('en-us')
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// 新标签页打开
|
||||||
|
Vue.prototype.$openPageNewSheet = (params) => {
|
||||||
|
const { href } = this.$router.resolve(params)
|
||||||
|
window.open(href, '_blank')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style scoped lang="less">
|
<style scoped lang="less">
|
||||||
#app {
|
#app {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
.watermark {
|
|
||||||
|
.watermark {
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
position: fixed;
|
position: fixed;
|
||||||
z-index: 999999999;
|
z-index: 999999999;
|
||||||
@@ -108,5 +116,5 @@ export default {
|
|||||||
left: 0;
|
left: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -16,6 +16,12 @@ const shareDomesticStandard = (params) => postAction('', params)
|
|||||||
const addDomesticSystemTree = (params) => postAction('', params)
|
const addDomesticSystemTree = (params) => postAction('', params)
|
||||||
// 国内标准-体系编辑
|
// 国内标准-体系编辑
|
||||||
const editDomesticSystemTree = (params) => postAction('', params)
|
const editDomesticSystemTree = (params) => postAction('', params)
|
||||||
|
// 国内标准-体系删除
|
||||||
|
const deleteDomesticSystemTree = (params) => postAction('', params)
|
||||||
|
// 国内标准-配置标准
|
||||||
|
const configDomesticStandard = (params) => postAction('', params)
|
||||||
|
// 国内标准-移出标准
|
||||||
|
const removeDomesticStandard = (params) => postAction('', params)
|
||||||
|
|
||||||
// 海外标准-获取查询条件
|
// 海外标准-获取查询条件
|
||||||
const getOverseasStandardSearchForm = (params) => getAction('/laws/standard/overseas/getQueryCondition', params)
|
const getOverseasStandardSearchForm = (params) => getAction('/laws/standard/overseas/getQueryCondition', params)
|
||||||
@@ -27,16 +33,22 @@ const getOverseasStandardDocumentInfo = (params) => getAction('/laws/standard/ov
|
|||||||
const getOverseasStandardTableHeader = (params) => getAction('/laws/standard/overseas/getCommonHeader', params)
|
const getOverseasStandardTableHeader = (params) => getAction('/laws/standard/overseas/getCommonHeader', params)
|
||||||
|
|
||||||
export {
|
export {
|
||||||
|
// 国内标准
|
||||||
getDomesticStandardSearchForm,
|
getDomesticStandardSearchForm,
|
||||||
getDomesticStandardFormModal,
|
getDomesticStandardFormModal,
|
||||||
getDomesticStandardDocumentInfo,
|
getDomesticStandardDocumentInfo,
|
||||||
getDomesticStandardTableHeader,
|
getDomesticStandardTableHeader,
|
||||||
getOverseasStandardSearchForm,
|
|
||||||
getOverseasStandardForm,
|
|
||||||
getOverseasStandardDocumentInfo,
|
|
||||||
getOverseasStandardTableHeader,
|
|
||||||
collectionDomesticStandard,
|
collectionDomesticStandard,
|
||||||
shareDomesticStandard,
|
shareDomesticStandard,
|
||||||
addDomesticSystemTree,
|
addDomesticSystemTree,
|
||||||
editDomesticSystemTree
|
editDomesticSystemTree,
|
||||||
|
deleteDomesticSystemTree,
|
||||||
|
configDomesticStandard,
|
||||||
|
removeDomesticStandard,
|
||||||
|
|
||||||
|
// 海外标准
|
||||||
|
getOverseasStandardSearchForm,
|
||||||
|
getOverseasStandardForm,
|
||||||
|
getOverseasStandardDocumentInfo,
|
||||||
|
getOverseasStandardTableHeader
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -338,6 +338,11 @@
|
|||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.can-click-table-text {
|
||||||
|
color: @primary-color;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
/* switch的样式 */
|
/* switch的样式 */
|
||||||
.table-operator-tab {
|
.table-operator-tab {
|
||||||
width: fit-content;
|
width: fit-content;
|
||||||
@@ -519,3 +524,151 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*详情样式start*/
|
||||||
|
.detail-page {
|
||||||
|
padding: 24px;
|
||||||
|
|
||||||
|
&-title {
|
||||||
|
font-size: 20px;
|
||||||
|
font-family: PingFang SC-Medium, PingFang SC, sans-serif;
|
||||||
|
color: #1D2129;
|
||||||
|
font-weight: 600;
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-part {
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid #E5E6EB;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-part-title {
|
||||||
|
height: 56px;
|
||||||
|
background: rgba(245, 245, 245, 0.6);
|
||||||
|
border-radius: 8px 8px 0 0;
|
||||||
|
opacity: 1;
|
||||||
|
border-bottom: 1px solid #E5E6EB;
|
||||||
|
padding: 0 20px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-part-title > span {
|
||||||
|
font-size: 16px;
|
||||||
|
font-family: PingFang SC-Medium, PingFang SC, sans-serif;
|
||||||
|
font-weight: 550;
|
||||||
|
color: #1D2129;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-part-title-operate-box {
|
||||||
|
.ant-btn > .anticon + span {
|
||||||
|
margin-left: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ant-btn > .iconfont + span {
|
||||||
|
margin-left: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ant-btn > .iconfont {
|
||||||
|
height: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&-part-form {
|
||||||
|
padding: 20px;
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
|
||||||
|
&-item {
|
||||||
|
width: calc((100% - 32px) / 3);
|
||||||
|
display: flex;
|
||||||
|
margin: 0 16px 16px 0;
|
||||||
|
|
||||||
|
label {
|
||||||
|
width: 40%;
|
||||||
|
font-size: 16px;
|
||||||
|
font-family: PingFang SC-Regular, PingFang SC, sans-serif;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #86909C;
|
||||||
|
}
|
||||||
|
|
||||||
|
span {
|
||||||
|
white-space: pre-wrap;
|
||||||
|
word-break: break-all;
|
||||||
|
font-size: 16px;
|
||||||
|
font-family: PingFang SC-Regular, PingFang SC, sans-serif;
|
||||||
|
color: #1D2129;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&-item:nth-child(3n) {
|
||||||
|
margin-right: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&-process-manuscript {
|
||||||
|
padding: 20px;
|
||||||
|
|
||||||
|
&-item {
|
||||||
|
padding: 20px 0;
|
||||||
|
border-bottom: 1px solid #E5E6EB;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-title {
|
||||||
|
font-size: 16px;
|
||||||
|
font-family: PingFang SC-Regular, PingFang SC, sans-serif;
|
||||||
|
color: #86909C;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
margin-bottom: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-file {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
margin-bottom: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-file:last-child {
|
||||||
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-file-info {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
color: @primary-color;
|
||||||
|
cursor: pointer;
|
||||||
|
flex: 1;
|
||||||
|
width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-file-info > .anticon {
|
||||||
|
margin-right: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-file-name {
|
||||||
|
white-space: nowrap;
|
||||||
|
overflow: hidden;
|
||||||
|
flex: 1;
|
||||||
|
width: 0;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-file-operate {
|
||||||
|
.ant-btn > .anticon + span, .ant-btn > .iconfont + span {
|
||||||
|
margin-left: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ant-btn:first-child {
|
||||||
|
margin-left: 15px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*详情样式end*/
|
||||||
|
|||||||
@@ -98,6 +98,7 @@ module.exports = {
|
|||||||
selectOne: 'Please select a data',
|
selectOne: 'Please select a data',
|
||||||
essentialInformation: 'General Information',
|
essentialInformation: 'General Information',
|
||||||
download: 'Download',
|
download: 'Download',
|
||||||
|
unwatermarkedDownload: 'Unwatermarked download',
|
||||||
fileName: 'File Name',
|
fileName: 'File Name',
|
||||||
fileDeclaration: 'File Declaration',
|
fileDeclaration: 'File Declaration',
|
||||||
newNode: 'New node',
|
newNode: 'New node',
|
||||||
|
|||||||
@@ -1,6 +1,12 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
configStandard: 'Configuration standard', // 配置标准
|
configStandard: 'Configuration standard', // 配置标准
|
||||||
removeStandard: 'Removal criteria', // 移出标准
|
removeStandard: 'Removal criteria', // 移出标准
|
||||||
|
nodeName: 'Node name', // 节点名称
|
||||||
|
configStandardNoTreeNode: 'Please select Level 2 and below system first', // 请先选择二级及以下体系
|
||||||
|
selectLeastOneTableData: 'Select at least one list data', // 选中至少一条列表数据
|
||||||
|
standardResolutionSheet: 'Standard resolution sheet', // 标准分解单
|
||||||
|
updateRecord: 'Update record', // 更新记录
|
||||||
|
submitQuestion: 'Submit a question', // 提交问题
|
||||||
// 国内标准
|
// 国内标准
|
||||||
domesticStandard: {
|
domesticStandard: {
|
||||||
treeSearchPlaceholder: 'Please enter the tree system', // 请输入树状图体系
|
treeSearchPlaceholder: 'Please enter the tree system', // 请输入树状图体系
|
||||||
|
|||||||
@@ -2,6 +2,11 @@ module.exports = {
|
|||||||
configStandard: '配置标准',
|
configStandard: '配置标准',
|
||||||
removeStandard: '移出标准',
|
removeStandard: '移出标准',
|
||||||
nodeName: '节点名称',
|
nodeName: '节点名称',
|
||||||
|
configStandardNoTreeNode: '请先选择二级及以下体系',
|
||||||
|
selectLeastOneTableData: '选中至少一条列表数据',
|
||||||
|
standardResolutionSheet: '标准分解单',
|
||||||
|
updateRecord: '更新记录',
|
||||||
|
submitQuestion: '提交问题',
|
||||||
// 国内标准
|
// 国内标准
|
||||||
domesticStandard: {
|
domesticStandard: {
|
||||||
treeSearchPlaceholder: '请输入树状图体系',
|
treeSearchPlaceholder: '请输入树状图体系',
|
||||||
@@ -10,5 +15,8 @@ module.exports = {
|
|||||||
exportFileName: '国内标准法规',
|
exportFileName: '国内标准法规',
|
||||||
exportZipName: '国内标准法规(带文件)',
|
exportZipName: '国内标准法规(带文件)',
|
||||||
templateName: '国内标准法规导入模板'
|
templateName: '国内标准法规导入模板'
|
||||||
|
},
|
||||||
|
standardDetail: {
|
||||||
|
title: ''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -98,6 +98,7 @@ module.exports = {
|
|||||||
selectOne: '请选择一条数据',
|
selectOne: '请选择一条数据',
|
||||||
essentialInformation: '基本信息',
|
essentialInformation: '基本信息',
|
||||||
download: '下载',
|
download: '下载',
|
||||||
|
unwatermarkedDownload: '无水印下载',
|
||||||
fileName: '文件名称',
|
fileName: '文件名称',
|
||||||
fileDeclaration: '文件说明',
|
fileDeclaration: '文件说明',
|
||||||
newNode: '新增节点',
|
newNode: '新增节点',
|
||||||
|
|||||||
@@ -1,7 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<global-layout @dynamicRouterShow="dynamicRouterShow">
|
<div>
|
||||||
|
<global-layout @dynamicRouterShow="dynamicRouterShow" v-if="!isInternalOrExternal">
|
||||||
<!-- update-begin- author:sunjianlei --- date:20191009 --- for: 提升右键菜单的层级 -->
|
<!-- update-begin- author:sunjianlei --- date:20191009 --- for: 提升右键菜单的层级 -->
|
||||||
<contextmenu :itemList="menuItemList" :visible.sync="menuVisible" style="z-index: 9999;" @select="onMenuSelect"/>
|
<contextmenu :itemList="menuItemList" :visible.sync="menuVisible" style="z-index: 9999;" @select="onMenuSelect" />
|
||||||
<!-- update-end- author:sunjianlei --- date:20191009 --- for: 提升右键菜单的层级 -->
|
<!-- update-end- author:sunjianlei --- date:20191009 --- for: 提升右键菜单的层级 -->
|
||||||
<a-tabs
|
<a-tabs
|
||||||
@contextmenu.native="e => onContextmenu(e)"
|
@contextmenu.native="e => onContextmenu(e)"
|
||||||
@@ -21,14 +22,16 @@
|
|||||||
<div style="margin: 12px 12px 0;">
|
<div style="margin: 12px 12px 0;">
|
||||||
<!-- update-begin-author:taoyan date:20201221 for:此处删掉transition标签 不知道为什么加上后 页面路由切换的时候即1及菜单切到2及菜单的时候 两个菜单页面会同时出现300-500秒左右 -->
|
<!-- update-begin-author:taoyan date:20201221 for:此处删掉transition标签 不知道为什么加上后 页面路由切换的时候即1及菜单切到2及菜单的时候 两个菜单页面会同时出现300-500秒左右 -->
|
||||||
<keep-alive v-if="multipage">
|
<keep-alive v-if="multipage">
|
||||||
<router-view v-if="reloadFlag"/>
|
<router-view v-if="reloadFlag" />
|
||||||
</keep-alive>
|
</keep-alive>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<router-view v-if="reloadFlag"/>
|
<router-view v-if="reloadFlag" />
|
||||||
</template>
|
</template>
|
||||||
<!-- update-end-author:taoyan date:20201221 for:此处删掉transition标签 不知道为什么加上后 页面路由切换的时候即1及菜单切到2及菜单的时候 两个菜单页面会同时出现300-500秒左右 -->
|
<!-- update-end-author:taoyan date:20201221 for:此处删掉transition标签 不知道为什么加上后 页面路由切换的时候即1及菜单切到2及菜单的时候 两个菜单页面会同时出现300-500秒左右 -->
|
||||||
</div>
|
</div>
|
||||||
</global-layout>
|
</global-layout>
|
||||||
|
<blank-layout v-else></blank-layout>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
@@ -38,12 +41,14 @@ import { mixin, mixinDevice } from '@/utils/mixin.js'
|
|||||||
import { triggerWindowResizeEvent } from '@/utils/util'
|
import { triggerWindowResizeEvent } from '@/utils/util'
|
||||||
import Vue from 'vue'
|
import Vue from 'vue'
|
||||||
import { CACHE_INCLUDED_ROUTES } from '@/store/mutation-types'
|
import { CACHE_INCLUDED_ROUTES } from '@/store/mutation-types'
|
||||||
|
import BlankLayout from './BlankLayout.vue'
|
||||||
|
|
||||||
const indexKey = '/'
|
const indexKey = '/'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'TabLayout',
|
name: 'TabLayout',
|
||||||
components: {
|
components: {
|
||||||
|
BlankLayout,
|
||||||
GlobalLayout,
|
GlobalLayout,
|
||||||
Contextmenu
|
Contextmenu
|
||||||
},
|
},
|
||||||
@@ -78,9 +83,14 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
return this.$store.state.app.multipage
|
return this.$store.state.app.multipage
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
// 是否外部打开
|
||||||
|
isInternalOrExternal () {
|
||||||
|
return this.$route.meta.internalOrExternal
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
|
console.log(this.$route)
|
||||||
// 复制一个route对象出来,不能影响原route
|
// 复制一个route对象出来,不能影响原route
|
||||||
const currentRoute = Object.assign({}, this.$route)
|
const currentRoute = Object.assign({}, this.$route)
|
||||||
currentRoute.meta = Object.assign({}, currentRoute.meta)
|
currentRoute.meta = Object.assign({}, currentRoute.meta)
|
||||||
@@ -299,36 +309,36 @@ export default {
|
|||||||
|
|
||||||
<style lang="less">
|
<style lang="less">
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The following styles are auto-applied to elements with
|
* The following styles are auto-applied to elements with
|
||||||
* transition="page-transition" when their visibility is toggled
|
* transition="page-transition" when their visibility is toggled
|
||||||
* by Vue.js.
|
* by Vue.js.
|
||||||
*
|
*
|
||||||
* You can easily play with the page transition by editing
|
* You can easily play with the page transition by editing
|
||||||
* these styles.
|
* these styles.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
.page-transition-enter {
|
.page-transition-enter {
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.page-transition-leave-active {
|
.page-transition-leave-active {
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.page-transition-enter .page-transition-container,
|
.page-transition-enter .page-transition-container,
|
||||||
.page-transition-leave-active .page-transition-container {
|
.page-transition-leave-active .page-transition-container {
|
||||||
-webkit-transform: scale(1.1);
|
-webkit-transform: scale(1.1);
|
||||||
transform: scale(1.1);
|
transform: scale(1.1);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*美化弹出Tab样式*/
|
/*美化弹出Tab样式*/
|
||||||
.ant-tabs-nav-container {
|
.ant-tabs-nav-container {
|
||||||
margin-top: 4px;
|
margin-top: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 修改 ant-tabs 样式 */
|
/* 修改 ant-tabs 样式 */
|
||||||
.tab-layout-tabs.ant-tabs {
|
.tab-layout-tabs.ant-tabs {
|
||||||
border-bottom: 1px solid #ccc;
|
border-bottom: 1px solid #ccc;
|
||||||
border-left: 1px solid #ccc;
|
border-left: 1px solid #ccc;
|
||||||
background-color: white;
|
background-color: white;
|
||||||
@@ -339,9 +349,9 @@ export default {
|
|||||||
border: none;
|
border: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.tab-layout-tabs.ant-tabs {
|
.tab-layout-tabs.ant-tabs {
|
||||||
|
|
||||||
&.ant-tabs-card .ant-tabs-tab {
|
&.ant-tabs-card .ant-tabs-tab {
|
||||||
|
|
||||||
@@ -367,16 +377,17 @@ export default {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.tab-layout-tabs.ant-tabs.ant-tabs-card > .ant-tabs-bar {
|
.tab-layout-tabs.ant-tabs.ant-tabs-card > .ant-tabs-bar {
|
||||||
.ant-tabs-tab {
|
.ant-tabs-tab {
|
||||||
border: none !important;
|
border: none !important;
|
||||||
border-bottom: 1px solid transparent !important;
|
border-bottom: 1px solid transparent !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ant-tabs-tab-active {
|
.ant-tabs-tab-active {
|
||||||
border-color: @primary-color!important;
|
border-color: @primary-color !important;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
+2
-2
@@ -94,8 +94,8 @@ export default class EsEnum {
|
|||||||
}
|
}
|
||||||
for (const i in this) {
|
for (const i in this) {
|
||||||
const e = this[i]
|
const e = this[i]
|
||||||
if (e.index !== undefined && e.index !== null && e.index.toString() === index.toString()) {
|
if (e.value !== undefined && e.value !== null && e.value.toString() === index.toString()) {
|
||||||
return e.name
|
return e.text
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return '--'
|
return '--'
|
||||||
|
|||||||
@@ -43,7 +43,8 @@ export const ConfigurableTableMixin = {
|
|||||||
filters: {}, // 固定的搜索条件
|
filters: {}, // 固定的搜索条件
|
||||||
needFilterTableBtn: true, // 是否需要过滤没有权限的按钮
|
needFilterTableBtn: true, // 是否需要过滤没有权限的按钮
|
||||||
tokenHeader: { 'X-Access-Token': Vue.ls.get(ACCESS_TOKEN) },
|
tokenHeader: { 'X-Access-Token': Vue.ls.get(ACCESS_TOKEN) },
|
||||||
getTableHeaderFunc: null // 获取表头的方法
|
getTableHeaderFunc: null, // 获取表头的方法
|
||||||
|
tableSlotField: [] // 表格需要使用插槽的字段,dbFieldName
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -124,6 +125,12 @@ export const ConfigurableTableMixin = {
|
|||||||
item.width = 215
|
item.width = 215
|
||||||
item.title = item.dbFieldTxt
|
item.title = item.dbFieldTxt
|
||||||
item.dataIndex = item.dbFieldName
|
item.dataIndex = item.dbFieldName
|
||||||
|
// 在各自页面写此页面需要使用插槽的字段
|
||||||
|
if (this.tableSlotField && this.tableSlotField.includes(item.dbFieldName)) {
|
||||||
|
item.scopedSlots = {
|
||||||
|
customRender: item.dbFieldName
|
||||||
|
}
|
||||||
|
}
|
||||||
tempColumns.push(item)
|
tempColumns.push(item)
|
||||||
})
|
})
|
||||||
if (this.showAction && this.operateColumn) {
|
if (this.showAction && this.operateColumn) {
|
||||||
|
|||||||
@@ -0,0 +1,146 @@
|
|||||||
|
<template>
|
||||||
|
<div class="detail-page">
|
||||||
|
<div class="detail-page-title">{{ pageTitle }}{{ $t('details') }}</div>
|
||||||
|
|
||||||
|
<div class="detail-page-part" v-for="(part, index) in partList" :key="part + index">
|
||||||
|
<div class="detail-page-part-title">
|
||||||
|
<span>{{ part }}</span>
|
||||||
|
<div class="detail-page-part-title-operate-box" v-if="index === 0">
|
||||||
|
<!-- 更新记录-->
|
||||||
|
<a-button type="link" @click="handleOpenUpdateRecord">
|
||||||
|
<i class="iconfont icon-root-list" />
|
||||||
|
{{ $t('standardRegulationLibrary.updateRecord') }}
|
||||||
|
</a-button>
|
||||||
|
<!-- 提交问题-->
|
||||||
|
<a-button type="link" @click="submitQuestion">
|
||||||
|
<a-icon type="database" />
|
||||||
|
{{ $t('standardRegulationLibrary.submitQuestion') }}
|
||||||
|
</a-button>
|
||||||
|
<!-- 分享-->
|
||||||
|
<a-button type="link"><i class="iconfont icon-root-list" />{{ $t('share') }}</a-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="detail-page-part-form" v-if="index !== 3">
|
||||||
|
<div class="detail-page-part-form-item" v-for="formItem in form[part]" :key="formItem.id">
|
||||||
|
<label>{{ formItem.dbFieldTxt }}</label>
|
||||||
|
<span>{{ detailData[formItem.dbFieldName] }}</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- 过程稿件特殊处理-->
|
||||||
|
<div class="detail-page-process-manuscript" v-if="index === 3">
|
||||||
|
<div class="detail-page-process-manuscript-item" v-for="formItem in form[part]" :key="formItem.id">
|
||||||
|
<div class="detail-page-process-manuscript-title">
|
||||||
|
<span>{{ formItem.dbFieldTxt }}</span>
|
||||||
|
<a-button type="primary" ghost icon="file-text">{{ $t('standardRegulationLibrary.standardResolutionSheet') }}</a-button>
|
||||||
|
</div>
|
||||||
|
<div class="detail-page-process-manuscript-file" v-for="file in detailData[formItem.dbFieldName]" :key="file.id">
|
||||||
|
<div class="detail-page-process-manuscript-file-info">
|
||||||
|
<a-icon type="link" />
|
||||||
|
<div class="detail-page-process-manuscript-file-name">{{ file.fileName }}</div>
|
||||||
|
</div>
|
||||||
|
<div class="detail-page-process-manuscript-file-operate">
|
||||||
|
<a-button type="link" icon="download">{{ $t('download') }}</a-button>
|
||||||
|
<a-button type="link">
|
||||||
|
<i class="iconfont icon-water-drop-slash"></i>
|
||||||
|
{{ $t('unwatermarkedDownload') }}
|
||||||
|
</a-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 更新记录-->
|
||||||
|
<upload-record-modal ref="uploadRecordModal" />
|
||||||
|
<!-- 提交问题-->
|
||||||
|
<submit-question-modal ref="submitQuestionModal" />
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import '@assets/less/common.less'
|
||||||
|
import { TagsTypeEnums } from '../../../enums/commonEnums'
|
||||||
|
import { getDomesticStandardFormModal } from '../../../api/standardRegulationLibraryApi'
|
||||||
|
import UploadRecordModal from './modules/UploadRecordModal.vue'
|
||||||
|
import SubmitQuestionModal from './modules/SubmitQuestionModal.vue'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: 'StandardDetailPage',
|
||||||
|
components: { UploadRecordModal, SubmitQuestionModal },
|
||||||
|
data () {
|
||||||
|
return {
|
||||||
|
partList: [], // 页面模块列表
|
||||||
|
form: {}, // 页面字段
|
||||||
|
detailData: {
|
||||||
|
modification_list: [
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
fileName: '国内文字占位符段落标题标准.pdf'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 2,
|
||||||
|
fileName: '国内标准国内文字占位符段落标题标准.pdf'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 3,
|
||||||
|
fileName: '国内标准国内标准.pdf'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
draft_for_review: [{
|
||||||
|
id: 11,
|
||||||
|
fileName: '国内文字占位符段落标题标准.pdf'
|
||||||
|
}],
|
||||||
|
draft_for_approval: [{
|
||||||
|
id: 21,
|
||||||
|
fileName: '国内标准国内文字占位符段落标题标准.pdf'
|
||||||
|
}],
|
||||||
|
draft_for_comment: [{
|
||||||
|
id: 31,
|
||||||
|
fileName: '国内标准国内标准.pdf'
|
||||||
|
}],
|
||||||
|
draft: [{
|
||||||
|
id: 311,
|
||||||
|
fileName: '国内标准国内标准.pdf'
|
||||||
|
}]
|
||||||
|
} // 页面数据
|
||||||
|
}
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
pageTitle () {
|
||||||
|
return TagsTypeEnums.nameOfIndex(this.$route.query.type)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created () {
|
||||||
|
this.initForm()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
initForm () {
|
||||||
|
getDomesticStandardFormModal().then(res => {
|
||||||
|
if (res.success) {
|
||||||
|
const data = res.result || {}
|
||||||
|
this.partList = Object.keys(data)
|
||||||
|
this.form = data
|
||||||
|
} else {
|
||||||
|
this.$message.warn(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 更新记录
|
||||||
|
*/
|
||||||
|
handleOpenUpdateRecord () {
|
||||||
|
this.$refs.uploadRecordModal.open()
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 提交问题
|
||||||
|
*/
|
||||||
|
submitQuestion () {
|
||||||
|
this.$refs.submitQuestionModal.open()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped lang="less">
|
||||||
|
|
||||||
|
</style>
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
<template>
|
||||||
|
<j-modal
|
||||||
|
:title="$t('standardRegulationLibrary.submitQuestion')"
|
||||||
|
:maskClosable="false"
|
||||||
|
:width="width"
|
||||||
|
:visible="visible"
|
||||||
|
:confirm-loading="confirmLoading"
|
||||||
|
@ok="handleOk"
|
||||||
|
@cancel="handleCancel">
|
||||||
|
|
||||||
|
<a-form :form="form">
|
||||||
|
<a-row :gutter="24">
|
||||||
|
<a-col :span="12">
|
||||||
|
<!-- 标题-->
|
||||||
|
<a-form-item :label="$t('title')" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||||
|
<a-input :placeholder="$t('pleaseEnter') + $t('title')"
|
||||||
|
@change="event => event.target.value = event.target.value.trim()"
|
||||||
|
:maxLength="50"
|
||||||
|
v-decorator="[ 'title', validatorRules.title]" />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-form>
|
||||||
|
</j-modal>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'SubmitQuestionModal',
|
||||||
|
data () {
|
||||||
|
return {
|
||||||
|
width: 800,
|
||||||
|
visible: false,
|
||||||
|
confirmLoading: false,
|
||||||
|
form: this.$form.createForm(this),
|
||||||
|
modal: {},
|
||||||
|
labelCol: {
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 4 }
|
||||||
|
},
|
||||||
|
wrapperCol: {
|
||||||
|
xs: { span: 24 },
|
||||||
|
sm: { span: 20 }
|
||||||
|
},
|
||||||
|
validatorRules: {
|
||||||
|
// 标题
|
||||||
|
title: {
|
||||||
|
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('title') }],
|
||||||
|
validateTrigger: 'blur'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
open () {
|
||||||
|
this.visible = true
|
||||||
|
},
|
||||||
|
handleOk () {
|
||||||
|
|
||||||
|
},
|
||||||
|
handleCancel () {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped lang="less">
|
||||||
|
|
||||||
|
</style>
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
<template>
|
||||||
|
<j-modal
|
||||||
|
:title="$t('standardRegulationLibrary.updateRecord')"
|
||||||
|
:maskClosable="false"
|
||||||
|
:width="width"
|
||||||
|
:visible="visible"
|
||||||
|
:confirm-loading="confirmLoading"
|
||||||
|
@cancel="handleCancel">
|
||||||
|
|
||||||
|
<div class="record-item" v-for="record in recordList" :key="record">
|
||||||
|
{{ record }}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<template v-slot:footer>
|
||||||
|
<a-button @click="handleCancel">{{ $t('close') }}</a-button>
|
||||||
|
</template>
|
||||||
|
</j-modal>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'UploadRecordModal',
|
||||||
|
data () {
|
||||||
|
return {
|
||||||
|
width: 800,
|
||||||
|
visible: false,
|
||||||
|
confirmLoading: false,
|
||||||
|
recordList: [
|
||||||
|
'111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111',
|
||||||
|
'222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
open () {
|
||||||
|
this.visible = true
|
||||||
|
},
|
||||||
|
handleCancel () {
|
||||||
|
this.visible = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped lang="less">
|
||||||
|
.record-item {
|
||||||
|
padding: 20px 0;
|
||||||
|
border-bottom: 1px solid #E5E6EB;
|
||||||
|
}
|
||||||
|
|
||||||
|
.record-item:first-child {
|
||||||
|
padding-top: 0;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -5,11 +5,14 @@
|
|||||||
<!-- $t('standardRegulationLibrary.domesticStandard.treeSearchPlaceholder')-->
|
<!-- $t('standardRegulationLibrary.domesticStandard.treeSearchPlaceholder')-->
|
||||||
<a-input-search v-model="treeInput" :placeholder="$t('standardRegulationLibrary.domesticStandard.treeSearchPlaceholder')"
|
<a-input-search v-model="treeInput" :placeholder="$t('standardRegulationLibrary.domesticStandard.treeSearchPlaceholder')"
|
||||||
@search="handleTreeSearch" />
|
@search="handleTreeSearch" />
|
||||||
<a-tree :show-line="true" :show-icon="true" :tree-data=treeData>
|
<a-tree :show-line="true" :show-icon="true" :tree-data=treeData :selected-keys="selectedTreeKeys">
|
||||||
<a-icon type="folder" slot="folder" class="tree-icon" />
|
<a-icon type="folder" slot="folder" class="tree-icon" />
|
||||||
|
|
||||||
<template #custom="record">
|
<template #custom="record">
|
||||||
<div class="tree-operate-node" @mouseenter="handleTreeMouseover(record.key)" @mouseleave="handleTreeMouseout(record.key)">
|
<div class="tree-operate-node"
|
||||||
|
@mouseenter="handleTreeMouseover(record.key)"
|
||||||
|
@mouseleave="handleTreeMouseout(record.key)"
|
||||||
|
@click="handleSelectTreeNode(record)">
|
||||||
<a-tooltip>
|
<a-tooltip>
|
||||||
<template #title>
|
<template #title>
|
||||||
{{ record.nodeName }}
|
{{ record.nodeName }}
|
||||||
@@ -18,13 +21,15 @@
|
|||||||
</a-tooltip>
|
</a-tooltip>
|
||||||
<template v-if="record.key === mouseInNodeKey">
|
<template v-if="record.key === mouseInNodeKey">
|
||||||
<!-- 新增-->
|
<!-- 新增-->
|
||||||
<a-button icon="plus" class="tree-operate-node-btn" @click="handleAddTreeNode(record)"></a-button>
|
<a-button icon="plus" class="tree-operate-node-btn" @click.stop="handleAddTreeNode(record)"></a-button>
|
||||||
<!-- 编辑-->
|
<!-- 编辑-->
|
||||||
<a-button class="tree-operate-node-btn" @click="handleEditTreeNode(record)">
|
<a-button class="tree-operate-node-btn" @click.stop="handleEditTreeNode(record)">
|
||||||
<i class="iconfont icon-bianji" />
|
<i class="iconfont icon-bianji" />
|
||||||
</a-button>
|
</a-button>
|
||||||
<!-- 删除,根节点不能删除-->
|
<!-- 删除,根节点不能删除-->
|
||||||
<a-button class="tree-operate-node-btn" v-if="record.nodeType !== StandardSystemTreeNodeType.ROOT_NODE.value">
|
<a-button class="tree-operate-node-btn"
|
||||||
|
v-if="record.nodeType !== StandardSystemTreeNodeType.ROOT_NODE.value"
|
||||||
|
@click.stop="handleDelTreeNode(record)">
|
||||||
<i class="iconfont icon-shanchu_" />
|
<i class="iconfont icon-shanchu_" />
|
||||||
</a-button>
|
</a-button>
|
||||||
</template>
|
</template>
|
||||||
@@ -75,9 +80,11 @@
|
|||||||
<!-- 批量删除-->
|
<!-- 批量删除-->
|
||||||
<a-button type="primary" icon="delete" ghost @click="batchDel">{{ $t('batchDelete') }}</a-button>
|
<a-button type="primary" icon="delete" ghost @click="batchDel">{{ $t('batchDelete') }}</a-button>
|
||||||
<!-- 配置标准-->
|
<!-- 配置标准-->
|
||||||
<a-button type="primary" icon="setting" ghost>{{ $t('standardRegulationLibrary.configStandard') }}</a-button>
|
<a-button type="primary" icon="setting" ghost @click="handleConfigStandard">{{ $t('standardRegulationLibrary.configStandard') }}</a-button>
|
||||||
<!-- 移出标准-->
|
<!-- 移出标准-->
|
||||||
<a-button type="primary" icon="minus-circle" ghost>{{ $t('standardRegulationLibrary.removeStandard') }}</a-button>
|
<a-button type="primary" icon="minus-circle" ghost @click="handleRemoveStandard">
|
||||||
|
{{ $t('standardRegulationLibrary.removeStandard') }}
|
||||||
|
</a-button>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<j-table
|
<j-table
|
||||||
@@ -91,6 +98,24 @@
|
|||||||
:scroll="{x: '100%'}"
|
:scroll="{x: '100%'}"
|
||||||
@change="tableOnChange">
|
@change="tableOnChange">
|
||||||
|
|
||||||
|
<!-- 标准编号-->
|
||||||
|
<template v-slot:standard_number="{text, record}">
|
||||||
|
<a-tooltip overlay-class-name="tooltip-style">
|
||||||
|
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
|
||||||
|
<div class="table-text can-click-table-text" v-if="text || text === 0" @click="toDetailPage(record)">{{ text }}</div>
|
||||||
|
<div v-else class="table-text">{{ global.emptyLine }}</div>
|
||||||
|
</a-tooltip>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<!-- 标准名称-->
|
||||||
|
<template v-slot:standard_name="{text, record}">
|
||||||
|
<a-tooltip overlay-class-name="tooltip-style">
|
||||||
|
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
|
||||||
|
<div class="table-text can-click-table-text" v-if="text || text === 0" @click="toDetailPage(record)">{{ text }}</div>
|
||||||
|
<div v-else class="table-text">{{ global.emptyLine }}</div>
|
||||||
|
</a-tooltip>
|
||||||
|
</template>
|
||||||
|
|
||||||
<template v-slot:operation="{text, record}">
|
<template v-slot:operation="{text, record}">
|
||||||
<!-- 收藏-->
|
<!-- 收藏-->
|
||||||
<a @click="operationClick(operationList[0],record)">
|
<a @click="operationClick(operationList[0],record)">
|
||||||
@@ -127,6 +152,8 @@
|
|||||||
<user-select-modal ref="userSelectModal" type="checkbox" @change="continueShare" />
|
<user-select-modal ref="userSelectModal" type="checkbox" @change="continueShare" />
|
||||||
<!-- 树新增、编辑-->
|
<!-- 树新增、编辑-->
|
||||||
<domestic-system-tree-modal ref="treeModal" @ok="modalFormOk" />
|
<domestic-system-tree-modal ref="treeModal" @ok="modalFormOk" />
|
||||||
|
<!-- 配置标准-->
|
||||||
|
<standard-selection-modal ref="standardSelectionModal" @change="continueConfigStandard" />
|
||||||
</a-card>
|
</a-card>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -136,10 +163,18 @@ import { ConfigurableTableMixin } from '../../../mixins/ConfigurableTableMixin'
|
|||||||
import Search from '../../../components/customField/Search.vue'
|
import Search from '../../../components/customField/Search.vue'
|
||||||
import JTable from '../../../components/jero/JTable.vue'
|
import JTable from '../../../components/jero/JTable.vue'
|
||||||
import DomesticStandardModal from './modules/DomesticStandardModal.vue'
|
import DomesticStandardModal from './modules/DomesticStandardModal.vue'
|
||||||
import { getDomesticStandardTableHeader, getDomesticStandardSearchForm, shareDomesticStandard } from '../../../api/standardRegulationLibraryApi'
|
import {
|
||||||
import { YesOrNoEnum, StandardSystemTreeNodeType } from '../../../enums/commonEnums'
|
getDomesticStandardTableHeader,
|
||||||
|
getDomesticStandardSearchForm,
|
||||||
|
shareDomesticStandard,
|
||||||
|
deleteDomesticSystemTree,
|
||||||
|
configDomesticStandard,
|
||||||
|
removeDomesticStandard
|
||||||
|
} from '../../../api/standardRegulationLibraryApi'
|
||||||
|
import { YesOrNoEnum, StandardSystemTreeNodeType, TagsTypeEnums } from '../../../enums/commonEnums'
|
||||||
import UserSelectModal from '../../../components/selection/UserSelectModal.vue'
|
import UserSelectModal from '../../../components/selection/UserSelectModal.vue'
|
||||||
import DomesticSystemTreeModal from './modules/DomesticSystemTreeModal.vue'
|
import DomesticSystemTreeModal from './modules/DomesticSystemTreeModal.vue'
|
||||||
|
import StandardSelectionModal from '../../../components/selection/StandardSelectionModal.vue'
|
||||||
|
|
||||||
const apiTreeData = [
|
const apiTreeData = [
|
||||||
{
|
{
|
||||||
@@ -166,7 +201,7 @@ const apiTreeData = [
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'DomesticStandardList',
|
name: 'DomesticStandardList',
|
||||||
components: { Search, JTable, DomesticStandardModal, UserSelectModal, DomesticSystemTreeModal },
|
components: { Search, JTable, DomesticStandardModal, UserSelectModal, DomesticSystemTreeModal, StandardSelectionModal },
|
||||||
mixins: [ConfigurableTableMixin],
|
mixins: [ConfigurableTableMixin],
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
@@ -208,10 +243,12 @@ export default {
|
|||||||
exportZipUrl: '', // 带文件导出
|
exportZipUrl: '', // 带文件导出
|
||||||
importExcelUrl: '' // 导入
|
importExcelUrl: '' // 导入
|
||||||
},
|
},
|
||||||
dataSource: [{ id: 1, collectionFlag: '1' }],
|
dataSource: [{ id: 1, collectionFlag: '1', standard_name: '标准001', standard_number: 'BZ001' }],
|
||||||
yesValue: YesOrNoEnum.YES.value,
|
yesValue: YesOrNoEnum.YES.value,
|
||||||
noValue: YesOrNoEnum.NO.value,
|
noValue: YesOrNoEnum.NO.value,
|
||||||
nowShareId: null // 当前正在分享的数据的id
|
nowShareId: null, // 当前正在分享的数据的id
|
||||||
|
selectedTreeKeys: [], // 选中的树节点
|
||||||
|
tableSlotField: ['standard_name', 'standard_number'] // 表格中需要插槽的字段
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -324,11 +361,118 @@ export default {
|
|||||||
// 清空列表选中
|
// 清空列表选中
|
||||||
this.onClearSelected()
|
this.onClearSelected()
|
||||||
},
|
},
|
||||||
|
/**
|
||||||
|
* 新增树节点
|
||||||
|
* @param dataRef
|
||||||
|
*/
|
||||||
handleAddTreeNode ({ dataRef }) {
|
handleAddTreeNode ({ dataRef }) {
|
||||||
this.$refs.treeModal.add({ parentId: dataRef.key })
|
this.$refs.treeModal.add({ parentId: dataRef.key })
|
||||||
},
|
},
|
||||||
|
/**
|
||||||
|
* 编辑树节点
|
||||||
|
* @param dataRef
|
||||||
|
*/
|
||||||
handleEditTreeNode ({ dataRef }) {
|
handleEditTreeNode ({ dataRef }) {
|
||||||
this.$refs.treeModal.edit(dataRef)
|
this.$refs.treeModal.edit(dataRef)
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 删除树节点
|
||||||
|
* @param dataRef
|
||||||
|
*/
|
||||||
|
handleDelTreeNode ({ dataRef }) {
|
||||||
|
this.$confirm({
|
||||||
|
title: this.$t('confirmDeletion'),
|
||||||
|
content: this.$t('areYouSure'),
|
||||||
|
onOk: () => {
|
||||||
|
deleteDomesticSystemTree({ ids: dataRef.id }).then((res) => {
|
||||||
|
if (res.success) {
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.modalFormOk()
|
||||||
|
} else {
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 选中树节点
|
||||||
|
* @param dataRef
|
||||||
|
*/
|
||||||
|
handleSelectTreeNode ({ dataRef }) {
|
||||||
|
this.selectedTreeKeys = [dataRef.key]
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 配置标准
|
||||||
|
*/
|
||||||
|
handleConfigStandard () {
|
||||||
|
// 没选择左侧树节点,需要提示“请先选择二级及以下体系”
|
||||||
|
if (!this.selectedTreeKeys || this.selectedTreeKeys.length === 0) {
|
||||||
|
this.$message.warn(this.$t('standardRegulationLibrary.configStandardNoTreeNode'))
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.$refs.standardSelectionModal.open()
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 配置标准-提交
|
||||||
|
* @param dbFieldName
|
||||||
|
* @param standardIds
|
||||||
|
*/
|
||||||
|
continueConfigStandard (dbFieldName, standardIds) {
|
||||||
|
this.loading = true
|
||||||
|
const params = {
|
||||||
|
nodeId: this.selectedTreeKeys[0],
|
||||||
|
standardIds
|
||||||
|
}
|
||||||
|
configDomesticStandard(params).then(res => {
|
||||||
|
if (res.success) {
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.modalFormOk()
|
||||||
|
} else {
|
||||||
|
this.$message.warn(res.message)
|
||||||
|
}
|
||||||
|
}).finally(() => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 移出标准
|
||||||
|
*/
|
||||||
|
handleRemoveStandard () {
|
||||||
|
// 没选择左侧树节点,需要提示“请先选择二级及以下体系”
|
||||||
|
if (!this.selectedTreeKeys || this.selectedTreeKeys.length === 0) {
|
||||||
|
this.$message.warn(this.$t('standardRegulationLibrary.configStandardNoTreeNode'))
|
||||||
|
return
|
||||||
|
}
|
||||||
|
// 没有选择列表数据,需要提示“选中至少一条列表数据”
|
||||||
|
if (!this.selectedRowKeys || this.selectedRowKeys.length === 0) {
|
||||||
|
this.$message.warning(this.$t('standardRegulationLibrary.selectLeastOneTableData'))
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.loading = true
|
||||||
|
const params = {
|
||||||
|
nodeId: this.selectedTreeKeys[0],
|
||||||
|
ids: this.selectedRowKeys.join(',')
|
||||||
|
}
|
||||||
|
removeDomesticStandard(params).then(res => {
|
||||||
|
if (res.success) {
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.modalFormOk()
|
||||||
|
} else {
|
||||||
|
this.$message.warn(res.message)
|
||||||
|
}
|
||||||
|
}).finally(() => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
toDetailPage ({ id }) {
|
||||||
|
this.$openPageNewSheet({
|
||||||
|
path: '/standardRegulationLibrary/DomesticStandardDetail',
|
||||||
|
query: {
|
||||||
|
id,
|
||||||
|
type: TagsTypeEnums.DOMESTIC_LIST.value
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -42,7 +42,7 @@ export default {
|
|||||||
sm: { span: 20 }
|
sm: { span: 20 }
|
||||||
},
|
},
|
||||||
validatorRules: {
|
validatorRules: {
|
||||||
// 上级节点
|
// 节点名称
|
||||||
nodeName: {
|
nodeName: {
|
||||||
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('standardRegulationLibrary.nodeName') }],
|
rules: [{ required: true, message: this.$t('pleaseEnter') + this.$t('standardRegulationLibrary.nodeName') }],
|
||||||
validateTrigger: 'blur'
|
validateTrigger: 'blur'
|
||||||
|
|||||||
Reference in New Issue
Block a user