add 工作中心-流程配置
This commit is contained in:
Vendored
+2
@@ -14,3 +14,5 @@ window._CONFIG.onlinePreviewDomainURL = 'http://127.0.0.1:8012/onlinePreview'
|
|||||||
window._CONFIG.onlyOfficeUrl = 'http://127.0.0.1:8080'
|
window._CONFIG.onlyOfficeUrl = 'http://127.0.0.1:8080'
|
||||||
// onlyOffice下载文件地址(暂时没用)
|
// onlyOffice下载文件地址(暂时没用)
|
||||||
window._CONFIG.onlyOfficeDownloadFileUrl = 'http://localhost:8184/sys/common/download'
|
window._CONFIG.onlyOfficeDownloadFileUrl = 'http://localhost:8184/sys/common/download'
|
||||||
|
// 流程图固定地址
|
||||||
|
window._CONFIG.flowchartFixedAddress = 'http://localhost:3334/laws-sinotruk/modeler.html?modelId='
|
||||||
|
|||||||
@@ -0,0 +1,8 @@
|
|||||||
|
import { getAction } from './manage.js'
|
||||||
|
|
||||||
|
// 流程配置-部署
|
||||||
|
const deployWorkFlow = (params) => getAction('/activitiModel/deploy', params)
|
||||||
|
|
||||||
|
export {
|
||||||
|
deployWorkFlow
|
||||||
|
}
|
||||||
@@ -65,5 +65,12 @@ module.exports = {
|
|||||||
leadershipAndNecessity: '立项标准的领先性与必要性',
|
leadershipAndNecessity: '立项标准的领先性与必要性',
|
||||||
initiatedProject: '立项目的及预期效果等',
|
initiatedProject: '立项目的及预期效果等',
|
||||||
uploadAttachment: '上传附件'
|
uploadAttachment: '上传附件'
|
||||||
|
},
|
||||||
|
// 流程配置
|
||||||
|
processConfig: {
|
||||||
|
processType: '流程类型',
|
||||||
|
editFlowchart: '编辑流程图',
|
||||||
|
editFlowNode: '编辑流程节点',
|
||||||
|
deploy: '部署'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
<!-- </a-tab-pane>-->
|
<!-- </a-tab-pane>-->
|
||||||
<!--</a-tabs>-->
|
<!--</a-tabs>-->
|
||||||
|
|
||||||
<breadcrumb/>
|
<breadcrumb v-if="!isEmbedded"/>
|
||||||
<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">
|
||||||
@@ -45,6 +45,7 @@ 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'
|
import BlankLayout from './BlankLayout.vue'
|
||||||
import Breadcrumb from '../tools/Breadcrumb.vue'
|
import Breadcrumb from '../tools/Breadcrumb.vue'
|
||||||
|
import { mapState } from 'vuex'
|
||||||
|
|
||||||
const indexKey = '/'
|
const indexKey = '/'
|
||||||
|
|
||||||
@@ -91,7 +92,11 @@ export default {
|
|||||||
// 是否外部打开
|
// 是否外部打开
|
||||||
isInternalOrExternal () {
|
isInternalOrExternal () {
|
||||||
return this.$route.meta.internalOrExternal
|
return this.$route.meta.internalOrExternal
|
||||||
}
|
},
|
||||||
|
...mapState({
|
||||||
|
// 是否嵌入在别的系统中
|
||||||
|
isEmbedded: state => state.app.isEmbedded
|
||||||
|
})
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
console.log(this.$route)
|
console.log(this.$route)
|
||||||
|
|||||||
@@ -103,7 +103,7 @@ const updatePageHeight = () => {
|
|||||||
const isEmbedded = store.getters.isEmbedded
|
const isEmbedded = store.getters.isEmbedded
|
||||||
const obj = {
|
const obj = {
|
||||||
'user-info-height': isEmbedded ? '0px' : '59px', // 用户信息的高度
|
'user-info-height': isEmbedded ? '0px' : '59px', // 用户信息的高度
|
||||||
'breadcrumb-height': '45px' // 面包屑的高度
|
'breadcrumb-height': isEmbedded ? '12px' : '45px' // 面包屑的高度
|
||||||
}
|
}
|
||||||
for (const key in obj) {
|
for (const key in obj) {
|
||||||
document
|
document
|
||||||
|
|||||||
+2
-1
@@ -14,7 +14,8 @@ whiteList.push(OAUTH2_LOGIN_PAGE_PATH)
|
|||||||
router.beforeEach((to, from, next) => {
|
router.beforeEach((to, from, next) => {
|
||||||
// 处理是否是嵌入其他系统,是需要隐藏左侧和上面,如果当前值是true,就不需要修改了
|
// 处理是否是嵌入其他系统,是需要隐藏左侧和上面,如果当前值是true,就不需要修改了
|
||||||
const isEmbedded = store.getters.isEmbedded
|
const isEmbedded = store.getters.isEmbedded
|
||||||
if (!isEmbedded && to.query.source === 'implant') {
|
// 用是否iframe嵌套判断
|
||||||
|
if (!isEmbedded && top.frames.length > 0) {
|
||||||
store.commit('SET_IS_EMBEDDED', true)
|
store.commit('SET_IS_EMBEDDED', true)
|
||||||
}
|
}
|
||||||
NProgress.start() // start progress bar
|
NProgress.start() // start progress bar
|
||||||
|
|||||||
@@ -0,0 +1,125 @@
|
|||||||
|
<template>
|
||||||
|
<a-card :bordered="false">
|
||||||
|
<div>
|
||||||
|
<j-table
|
||||||
|
:columns="columns"
|
||||||
|
:dataSource="dataSource"
|
||||||
|
:can-drag="true"
|
||||||
|
rowKey="id"
|
||||||
|
:pagination="false"
|
||||||
|
:scroll="{x: '100%'}"
|
||||||
|
:operation-list="operationList"
|
||||||
|
:loading="loading"
|
||||||
|
@change="handleTableChange"
|
||||||
|
@operationClick="operationClick">
|
||||||
|
</j-table>
|
||||||
|
</div>
|
||||||
|
</a-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import JTable from '../../../components/jero/JTable.vue'
|
||||||
|
import { JeroListMixin } from '../../../mixins/JeroListMixin.js'
|
||||||
|
import { deployWorkFlow } from '../../../api/workCenter.js'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: 'ProcessConfig',
|
||||||
|
components: { JTable },
|
||||||
|
mixins: [JeroListMixin],
|
||||||
|
data () {
|
||||||
|
return {
|
||||||
|
columns: [
|
||||||
|
// 序号
|
||||||
|
{
|
||||||
|
title: this.$t('serialNumber'),
|
||||||
|
dataIndex: '',
|
||||||
|
key: 'rowIndex',
|
||||||
|
width: 60,
|
||||||
|
align: 'center',
|
||||||
|
customRender: function (t, r, index) {
|
||||||
|
return parseInt(index) + 1
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 流程名称
|
||||||
|
{
|
||||||
|
dataIndex: 'name',
|
||||||
|
title: this.$t('processName'),
|
||||||
|
width: 250
|
||||||
|
},
|
||||||
|
// 流程类型
|
||||||
|
{
|
||||||
|
dataIndex: 'category',
|
||||||
|
title: this.$t('workCenter.processConfig.processType'),
|
||||||
|
width: 250
|
||||||
|
},
|
||||||
|
// 创建时间
|
||||||
|
{
|
||||||
|
dataIndex: 'createTime',
|
||||||
|
title: this.$t('createTime'),
|
||||||
|
width: 250
|
||||||
|
},
|
||||||
|
// 操作
|
||||||
|
{
|
||||||
|
title: this.$t('operation'),
|
||||||
|
fixed: 'right',
|
||||||
|
width: 180,
|
||||||
|
scopedSlots: { customRender: 'action' }
|
||||||
|
}
|
||||||
|
],
|
||||||
|
url: {
|
||||||
|
list: '/activitiModel/modelList'
|
||||||
|
},
|
||||||
|
operationList: [
|
||||||
|
// 编辑流程图
|
||||||
|
{
|
||||||
|
text: this.$t('workCenter.processConfig.editFlowchart'),
|
||||||
|
clickEvent: 'handleEditFlowchart',
|
||||||
|
has: ''
|
||||||
|
},
|
||||||
|
// 编辑流程节点
|
||||||
|
{
|
||||||
|
text: this.$t('workCenter.processConfig.editFlowNode'),
|
||||||
|
clickEvent: 'handleEditFlowNode',
|
||||||
|
has: ''
|
||||||
|
},
|
||||||
|
// 部署
|
||||||
|
{
|
||||||
|
text: this.$t('workCenter.processConfig.deploy'),
|
||||||
|
clickEvent: 'handleDeploy',
|
||||||
|
has: ''
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
/**
|
||||||
|
* 编辑流程图
|
||||||
|
* @param id
|
||||||
|
*/
|
||||||
|
handleEditFlowchart ({ id }) {
|
||||||
|
window.open(window._CONFIG.flowchartFixedAddress + id, '_blank')
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 部署
|
||||||
|
* @param id
|
||||||
|
*/
|
||||||
|
handleDeploy ({ id }) {
|
||||||
|
this.loading = true
|
||||||
|
deployWorkFlow({ modelId: id }).then(res => {
|
||||||
|
if (res.success) {
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.modalFormOk()
|
||||||
|
} else {
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
}).finally(() => {
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped lang="less">
|
||||||
|
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user