xiaobai 3 years ago
parent
commit
62a7f39e2a
  1. 16
      .env.development
  2. 2
      .env.production
  3. 2
      .env.test
  4. 11
      src/api/template.js
  5. 41
      src/components/drawerDialog/index.vue
  6. 8
      src/store/modules/user.js
  7. 17
      src/views/document/index.vue

16
.env.development

@ -1,16 +1,16 @@
# 开发环境相关配置
# 微服务IP
VUE_APP_SERVER_ADDRESS = 'test.sdma.mingansei.com'
# 项目名称
VUE_APP_PROJECT_NAME = 'SJJY'
# 省局数据后台IP
VUE_APP_SJ_BASE_IP_ADDRESS = '192.168.1.130'
# 微服务IP
VUE_APP_SERVER_ADDRESS = '192.168.1.130'
# 微服务地址
VUE_APP_SERVER_API = 'http://${VUE_APP_SERVER_ADDRESS}'
VUE_APP_SERVER_API = 'http://${VUE_APP_SERVER_ADDRESS}:9100'
# 项目名称
VUE_APP_PROJECT_NAME = 'SJJY'
# 省局数据后台IP
VUE_APP_SJ_BASE_IP_ADDRESS = '192.168.1.130'
# 业务后台访问地址
VUE_APP_BASE_API = '${VUE_APP_SERVER_API}/sdma-manage/'
@ -25,4 +25,4 @@ VUE_APP_SJ_API = 'http://${VUE_APP_SJ_BASE_IP_ADDRESS}:9092/SJSE/'
VUE_APP_PREVIEW_API = '${VUE_APP_SERVER_API}/sdma-preview/'
# websocket连接地址
VUE_APP_WEBSOCKET = 'ws://${VUE_APP_SERVER_ADDRESS}:9100/sdma-manage/websocket/'
VUE_APP_WEBSOCKET = 'ws://${VUE_APP_SERVER_ADDRESS}:9100/sdma-websocket/websocket/'

2
.env.production

@ -22,4 +22,4 @@ VUE_APP_SJ_API = 'http://${VUE_APP_SJ_BASE_IP_ADDRESS}:9092/SJSE/'
VUE_APP_PREVIEW_API = '${VUE_APP_SERVER_API}/sdma-preview/'
# websocket连接地址
VUE_APP_WEBSOCKET = 'ws://${VUE_APP_SERVER_ADDRESS}:9100/sdma-manage/websocket/'
VUE_APP_WEBSOCKET = 'ws://${VUE_APP_SERVER_ADDRESS}:9100/sdma-websocket/websocket/'

2
.env.test

@ -22,4 +22,4 @@ VUE_APP_SJ_API = 'http://${VUE_APP_SJ_BASE_IP_ADDRESS}:9092/SJSE/'
VUE_APP_PREVIEW_API = '${VUE_APP_SERVER_API}/sdma-preview/'
# websocket连接地址
VUE_APP_WEBSOCKET = 'ws://${VUE_APP_SERVER_ADDRESS}:9100/sdma-manage/websocket/'
VUE_APP_WEBSOCKET = 'ws://${VUE_APP_SERVER_ADDRESS}:9100/sdma-websocket/websocket/'

11
src/api/template.js

@ -29,5 +29,16 @@ export default {
return qs.stringify(params, { indices: false })
}
})
},
deleteTemplateJyxm: (params) => {
console.log(params)
return api({
url: '/templateJyxm',
method: 'delete',
params,
paramsSerializer: function(params) {
return qs.stringify(params, { indices: false })
}
})
}
}

41
src/components/drawerDialog/index.vue

@ -502,7 +502,7 @@
prop="writeMode"
label-width="150px"
>
<el-radio-group v-model="form.writeMode" @change="changeWriteMode">
<el-radio-group v-model="form.writeMode">
<el-radio v-for="(item, writeModeIndex) in writeModes" :key="writeModeIndex" :label="writeModeIndex" :disabled="(form.tableMode === 0 && writeModeIndex === 1) || (form.tableMode === 1 && writeModeIndex !== 1)">
{{ item }}
</el-radio>
@ -794,30 +794,6 @@ export default {
break
}
},
changeWriteMode() {
switch (this.form.writeMode) {
case 0:
case 2:
case 3:
this.form.tableMode = 0
this.form.tableIndex = 1
this.form.tableStartRow = 1
this.form.tableRowCount = this.form.tableRowFindMode ? 0 : 1
this.form.affiliatedTableStartRow = 0
this.form.affiliatedTableRowCount = 0
break
case 1:
this.form.tableMode = 1
this.form.tableIndex = 0
this.form.tableStartRow = 0
this.form.tableRowCount = 0
this.form.affiliatedTableStartRow = 0
this.form.affiliatedTableRowCount = 0
break
default:
break
}
},
changeTableRowFindMode() {
this.form.tableRowCount = 0
this.form.affiliatedTableRowCount = 0
@ -872,9 +848,10 @@ export default {
// })
this.list = data.list
this.totalCount = data.total * 1
this.gridData = []
if (data.list[0]) {
this.getDemoList(data.list[0].id)
this.templateSettingId = data.list[0].id
this.getDemoList()
}
})
},
@ -888,7 +865,7 @@ export default {
deleteFn(row, index) {
const arr = []
arr.push(row.id)
TemplateApi.deleteSettingFn({
TemplateApi.deleteTemplateJyxm({
ids: arr
}).then((data) => {
this.getDemoList()
@ -898,9 +875,13 @@ export default {
//
return (this.listQuery.pageNum - 1) * this.listQuery.pageRow + $index + 1
},
getDemoList(id) {
getDemoList() {
if (!this.templateSettingId) {
this.$notify.error('未正确提供模板设置主键,无法加载检验项目列配置数据!')
return
}
//
this.jyxmParams.templateSettingId = id
this.jyxmParams.templateSettingId = this.templateSettingId
this.jyxmParams.templateId = this.id
this.api({
url: '/templateJyxm/list',
@ -1154,7 +1135,7 @@ export default {
}
this.templateSettingId = row.id
this.$refs.settingList.toggleRowSelection(row)
this.getDemoList(row.id)
this.getDemoList()
},
clearForm() {
this.formTemplate = {

8
src/store/modules/user.js

@ -5,8 +5,8 @@ import global from '../../utils/common.js'
import store from '../../store'
import router, { resetRouter } from '../../router'
import Vue from 'vue'
import { getOwnList, getRenwuListByPath } from '@/api/renwu'
import { getNeedRecordList } from '@/api/ysjl'
// import { getOwnList, getRenwuListByPath } from '@/api/renwu'
// import { getNeedRecordList } from '@/api/ysjl'
const user = {
state: {
@ -126,7 +126,7 @@ const user = {
setToken()
global.it = data.userVO.id
// 查询相关待办条数
const messagePush = []
/* const messagePush = []
const departmentId = user.state.departmentId
getOwnList({ // 我的任务
pageNum: 1, // 页码
@ -263,7 +263,7 @@ const user = {
})
})
}
user.state.messageCount = messagePush // 赋值要放在 set_user 后面,否则被冲刷掉了。
user.state.messageCount = messagePush*/ // 赋值要放在 set_user 后面否则被冲刷掉了
// 查询路由
const asyncRouter = filterAsyncRouter(data.menuList)
asyncRouter.push({ path: '*', redirect: '/404', hidden: true })

17
src/views/document/index.vue

@ -11,7 +11,6 @@
clearable
@keyup.enter.native="crud.toQuery"
/>
<query :crud="crud" />
<el-upload
ref="upload"
@ -57,10 +56,17 @@
<pagination />
<el-dialog title="查看历史版本" :visible.sync="dialogTableVisible">
<el-table :data="gridData">
<el-table-column :formatter="formatterFlowName" property="flowname" label="操作环节" />
<el-table-column :formatter="formatterFlowName" property="flowName" label="操作环节" width="80" />
<el-table-column property="filename" label="文件名称" />
<el-table-column :formatter="formatter.getChineseName" property="createBy" label="创建人" />
<el-table-column property="createTime" label="创建时间" />
<el-table-column :formatter="formatter.getChineseName" property="createBy" label="创建人" width="100" />
<el-table-column property="createTime" label="创建时间" width="150" />
<el-table-column label="操作" width="80">
<template v-slot="scope">
<el-button v-if="scope.row.flowName !== 0" type="text" @click="viewHistoryFile(scope.row)">
预览
</el-button>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="params.pageSize"
@ -189,6 +195,9 @@ export default {
downLoad(item) {
downloadFileUrl(this.url + '/' + item.id + item.suffix, item.filename, item.suffix)
},
viewHistoryFile(item) {
downloadFileUrl(this.url + '/' + item.inspectionSystemFileId + '_' + item.id + item.suffix, item.filename, item.suffix)
},
downLoadFn(item) {
download(this.url + '/' + item.id + item.suffix)
},

Loading…
Cancel
Save