版本同步
parent
95d37789b8
commit
3433578933
|
|
@ -1,9 +1,9 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="JAVA_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<output url="file://$MODULE_DIR$/bin" />
|
||||
<module type="WEB_MODULE" version="4">
|
||||
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
||||
<exclude-output />
|
||||
<content url="file://$MODULE_DIR$" />
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -5,7 +5,7 @@
|
|||
"author": "",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "webpack-dev-server --inline --progress --config build/webpack.dev.conf.js --host 192.168.0.69 --open",
|
||||
"dev": "webpack-dev-server --inline --progress --config build/webpack.dev.conf.js",
|
||||
"start": "npm run dev",
|
||||
"unit": "jest --config test/unit/jest.conf.js --coverage",
|
||||
"e2e": "node test/e2e/runner.js",
|
||||
|
|
@ -25,10 +25,15 @@
|
|||
"jspdf": "^2.5.1",
|
||||
"moment": "^2.29.1",
|
||||
"nprogress": "^0.2.0",
|
||||
"path-to-regexp": "^6.2.2",
|
||||
"qs": "^6.12.1",
|
||||
"quill": "^1.3.7",
|
||||
"video.js": "^8.10.0",
|
||||
"viewerjs": "^1.11.6",
|
||||
"vue": "^2.5.2",
|
||||
"vue-baidu-map": "^0.21.22",
|
||||
"vue-count-to": "^1.0.13",
|
||||
"vue-hot-reload-api": "^2.3.4",
|
||||
"vue-particles": "^1.0.9",
|
||||
"vue-pdf": "^4.3.0",
|
||||
"vue-print-nb": "^1.7.4",
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
</template>
|
||||
|
||||
<script>
|
||||
import pathToRegexp from 'path-to-regexp'
|
||||
import * as pathToRegexp from 'path-to-regexp'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -0,0 +1,119 @@
|
|||
<template>
|
||||
<div style="position: relative">
|
||||
<el-cascader
|
||||
ref="cascader"
|
||||
:value="value"
|
||||
:options="options"
|
||||
:props="props"
|
||||
:disabled = "disabled"
|
||||
:placeholder="placeholder"
|
||||
:filterable = "filterable"
|
||||
:clearable = "clearable"
|
||||
style="width: 100%"
|
||||
@change="cascaderChange" />
|
||||
<i v-show="loading" class="el-icon-loading" style="position: absolute;top: 10px;right: 25px;"/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { requestFN } from '@/utils/request'
|
||||
export default {
|
||||
name: 'CascaderDict',
|
||||
props: {
|
||||
/* 选项列表数据(树形结构的对象数组) */
|
||||
/* 初始值 */
|
||||
form: {
|
||||
type: Object,
|
||||
default: () => { return {} }
|
||||
},
|
||||
type: {
|
||||
type: String,
|
||||
default: () => { return 'search' }
|
||||
},
|
||||
dictId: {
|
||||
type: String,
|
||||
default: () => { return '' }
|
||||
},
|
||||
value: {
|
||||
type: Array,
|
||||
default: () => { return [] }
|
||||
},
|
||||
// 可搜索
|
||||
filterable: {
|
||||
type: Boolean,
|
||||
default: () => { return true }
|
||||
},
|
||||
/* 可清空 */
|
||||
clearable: {
|
||||
type: Boolean,
|
||||
default: () => { return true }
|
||||
},
|
||||
placeholder: {
|
||||
type: String,
|
||||
default: () => { return '请选择' }
|
||||
},
|
||||
/* props属性 */
|
||||
// 禁用
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: () => { return false }
|
||||
},
|
||||
// 可选任意级
|
||||
checkStrictly: {
|
||||
type: Boolean,
|
||||
default: () => { return true }
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
USER_LEVEL: JSON.parse(sessionStorage.getItem('user')).LEVEL || '2',
|
||||
options: [],
|
||||
props: {
|
||||
checkStrictly: this.checkStrictly
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.initHandle()
|
||||
},
|
||||
methods: {
|
||||
clearNodes() {
|
||||
this.$refs.cascader.clearCheckedNodes()
|
||||
},
|
||||
// 初始化值
|
||||
initHandle() {
|
||||
this.loading = true
|
||||
const url = '/dictionaries/listAllDictCetByParentId'
|
||||
return new Promise((resolve) => {
|
||||
requestFN(
|
||||
url,
|
||||
{
|
||||
DICTIONARIES_ID: this.dictId // 字典ID
|
||||
}
|
||||
).then((data) => {
|
||||
if (data.list.length > 0) {
|
||||
this.options = data.list
|
||||
}
|
||||
this.loading = false
|
||||
resolve()
|
||||
}).catch((e) => {
|
||||
})
|
||||
})
|
||||
},
|
||||
cascaderChange(e) {
|
||||
const value = e
|
||||
this.$emit('input', value)
|
||||
this.$emit('cascaderNames', this.$refs.cascader.getCheckedNodes()[0].pathLabels ? this.$refs.cascader.getCheckedNodes()[0].pathLabels.join(',') : '')
|
||||
this.$nextTick(() => {
|
||||
const dom = document.getElementsByClassName('el-radio is-checked')
|
||||
const radioDom = dom[dom.length - 1]
|
||||
const brother = radioDom.nextElementSibling
|
||||
if (radioDom.getElementsByClassName('el-radio__original')[0].value.split(',').length < 5) {
|
||||
brother.click()
|
||||
}
|
||||
this.$refs.cascader.dropDownVisible = false
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
@ -100,12 +100,12 @@ export default {
|
|||
this.$refs.selectTree.setCurrentKey(this.valueId) // 设置默认选中
|
||||
this.defaultExpandedKey = [this.valueId] // 设置默认展开
|
||||
}
|
||||
this.$nextTick(() => {
|
||||
const scrollWrap = document.querySelectorAll('.el-scrollbar .el-select-dropdown__wrap')[0]
|
||||
// const scrollBar = document.querySelectorAll('.el-scrollbar .el-scrollbar__bar')
|
||||
scrollWrap.style.cssText = 'margin: 0px; max-height: none; overflow: hidden;'
|
||||
// scrollBar.forEach(ele => ele.style.width = 0)
|
||||
})
|
||||
// this.$nextTick(() => {
|
||||
// const scrollWrap = document.querySelectorAll('.el-scrollbar .el-select-dropdown__wrap')[0]
|
||||
// // const scrollBar = document.querySelectorAll('.el-scrollbar .el-scrollbar__bar')
|
||||
// scrollWrap.style.cssText = 'margin: 0px; max-height: none; overflow: hidden;'
|
||||
// // scrollBar.forEach(ele => ele.style.width = 0)
|
||||
// })
|
||||
},
|
||||
// 切换选项
|
||||
handleNodeClick(node) {
|
||||
|
|
|
|||
|
|
@ -0,0 +1,502 @@
|
|||
.orso{
|
||||
padding: 0 20px;
|
||||
}
|
||||
.tip_text{
|
||||
font-size: 13px;
|
||||
padding: 10px 0;
|
||||
}
|
||||
.flex-layout{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.space-between{
|
||||
justify-content: space-between;
|
||||
}
|
||||
// 标准模板
|
||||
.app-ture {
|
||||
background-color: #fff;
|
||||
padding: 20px;
|
||||
}
|
||||
.app-warp {
|
||||
padding: 15px;
|
||||
|
||||
.app-structure {
|
||||
background-color: #fff;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.app-search {
|
||||
.app-search-form {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
padding-right: 10px;
|
||||
align-items: flex-start;
|
||||
|
||||
.form-item {
|
||||
width: 33.333%;
|
||||
|
||||
label {
|
||||
text-align: right;
|
||||
vertical-align: middle;
|
||||
float: left;
|
||||
font-size: 14px;
|
||||
color: #606266;
|
||||
line-height: 32px;
|
||||
padding: 0 12px 0 0;
|
||||
box-sizing: border-box;
|
||||
font-weight: 700;
|
||||
width: 90px;
|
||||
margin-bottom: 18px;
|
||||
white-space: nowrap;
|
||||
|
||||
}
|
||||
.el-input {
|
||||
float: left;
|
||||
width: calc(100% - 100px);
|
||||
}
|
||||
.el-select{
|
||||
float: left;
|
||||
width: calc(100% - 100px);
|
||||
.el-input {
|
||||
width: calc(100% - 0px);
|
||||
}
|
||||
}
|
||||
.el-date-editor{
|
||||
width: calc(100% - 100px);
|
||||
}
|
||||
}
|
||||
.four_more{
|
||||
label{
|
||||
width: 130px;
|
||||
}
|
||||
.el-input {
|
||||
float: left;
|
||||
width: calc(100% - 130px);
|
||||
}
|
||||
.el-select{
|
||||
float: left;
|
||||
width: calc(100% - 130px);
|
||||
.el-input {
|
||||
width: calc(100% - 0px);
|
||||
}
|
||||
}
|
||||
// .input_def{width: calc(100% - 140px)}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.app-tools {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
padding-bottom: 14px;
|
||||
align-items: center;
|
||||
|
||||
.app-minbtn {
|
||||
padding-right: 10px;
|
||||
|
||||
.screening {
|
||||
position: relative;
|
||||
margin-right: 6px;
|
||||
|
||||
}
|
||||
|
||||
.el-button {
|
||||
color: #000;
|
||||
font-size: 15px;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.app-statistical {
|
||||
padding: 8px 20px 8px 20px;
|
||||
border: 1px solid #abdcff;
|
||||
background-color: #f0faff;
|
||||
position: relative;
|
||||
border-radius: 4px;
|
||||
color: #515a6e;
|
||||
line-height: 16px;
|
||||
margin-bottom: 15px;
|
||||
|
||||
span {
|
||||
margin-right: 20px;
|
||||
font-size: 12px;
|
||||
|
||||
i {
|
||||
font-style: normal;
|
||||
font-weight: 700;
|
||||
color: rgb(45, 140, 240);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.app-container {
|
||||
padding: 0;
|
||||
.el-button{
|
||||
&:hover{
|
||||
text-decoration: underline;
|
||||
font-weight: 700;
|
||||
}
|
||||
}
|
||||
.status-dot{
|
||||
width: 6px;
|
||||
height: 6px;
|
||||
display: inline-block;
|
||||
border-radius: 50%;
|
||||
vertical-align: middle;
|
||||
position: relative;
|
||||
top: -1px;
|
||||
margin-right: 6px;
|
||||
}
|
||||
.status-green{
|
||||
background-color: #52c41a;
|
||||
}
|
||||
.status-red{
|
||||
background-color: #f51515;
|
||||
}
|
||||
.status-blue{
|
||||
background-color: #1E9FFF;
|
||||
}
|
||||
.status-orange{
|
||||
background-color: #e36c09;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.app-divider {
|
||||
margin: 0 8px;
|
||||
display: inline-block;
|
||||
height: .9em;
|
||||
width: 1px;
|
||||
vertical-align: middle;
|
||||
position: relative;
|
||||
top: -.06em;
|
||||
font-size: 14px;
|
||||
line-height: 1.5;
|
||||
color: #515a6e;
|
||||
box-sizing: border-box;
|
||||
padding: 0;
|
||||
list-style: none;
|
||||
background: #e8eaec;
|
||||
}
|
||||
|
||||
.app-checkbox-group {
|
||||
padding: 4px 10px;
|
||||
|
||||
.el-checkbox {
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
}
|
||||
|
||||
.appformwith {
|
||||
border: 0 solid red;
|
||||
}
|
||||
|
||||
//培训类型
|
||||
.type_field_box {
|
||||
display: flex;
|
||||
|
||||
.type_field_item {
|
||||
width: 220px;
|
||||
border-radius: 6px 6px 0 0;
|
||||
margin-right: 20px;
|
||||
|
||||
&:last-child {
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
.type_field_top {
|
||||
background-color: #40a3ff;
|
||||
border-radius: 5px 5px 0 0;
|
||||
color: #fff;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.type_field_content {
|
||||
height: 300px;
|
||||
border: 1px solid #ccc;
|
||||
border-top: none;
|
||||
overflow-y: auto;
|
||||
position: relative;
|
||||
transform: scale(1);
|
||||
.type_li{
|
||||
font-size: 14px;
|
||||
padding: 8px 0 8px 24px;
|
||||
|
||||
&:hover{
|
||||
background-color: #f5f7fa;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
}
|
||||
.type_li_active{
|
||||
background-color: #edf6ff;
|
||||
cursor: pointer;
|
||||
}
|
||||
.type_field_search{
|
||||
position: fixed;
|
||||
top: 0;
|
||||
z-index: 1;
|
||||
width: 304px;
|
||||
background-color: #fff;
|
||||
padding: 10px 6px 0 10px;
|
||||
}
|
||||
.type_tree{
|
||||
position: absolute;
|
||||
top: 44px;
|
||||
width: 100%;
|
||||
padding: 0 10px 10px;
|
||||
}
|
||||
}
|
||||
.type_pa{
|
||||
padding: 10px 0;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.m-scroll-style {
|
||||
/** 滚动条样式*/
|
||||
&::-webkit-scrollbar {
|
||||
width: 6px;
|
||||
// background-color: rgba(232, 232, 232, 1);
|
||||
border-left: 1px solid #ccc;
|
||||
border-radius: 0;
|
||||
}
|
||||
// &:hover::-webkit-scrollbar {
|
||||
// width: 6px;
|
||||
// background-color: rgba(61, 86, 267, 0.2);
|
||||
// border-radius: 10px;
|
||||
// }
|
||||
/** 滚动条里的滑块样式 */
|
||||
&::-webkit-scrollbar-thumb {
|
||||
background-color: rgba(232, 232, 232, 1);
|
||||
border-radius: 10px;
|
||||
}
|
||||
/* 火狐美化滚动条 */
|
||||
scrollbar-color: rgba(67, 102, 236, 1) rgba(61, 86, 267, 0.2);
|
||||
/* 滑块颜色 滚动条背景颜色 */
|
||||
scrollbar-width: thin;
|
||||
/* IE美化滚动条 */
|
||||
scrollbar-track-color: transparent;
|
||||
-ms-scrollbar-track-color: transparent;
|
||||
/* 滚动条宽度有三种:thin、auto、none */
|
||||
scrollbar-face-color: rgba(67, 102, 236, 1); /*滚动条3D表面(ThreedFace)的颜色*/
|
||||
scrollbar-highlight-color: #fff; /*滚动条3D界面的亮边(ThreedHighlight)颜色*/
|
||||
scrollbar-shadow-color: #eeeeee; /*滚动条3D界面的暗边(ThreedShadow)颜色*/
|
||||
scrollbar-3dlight-color: #eeeeee; /*滚动条亮边框颜色*/
|
||||
scrollbar-arrow-color:rgba(67, 102, 236, 1); /*滚动条方向箭头的颜色 */
|
||||
scrollbar-track-color: #fff; /*滚动条的拖动区域(TrackBar)颜色*/
|
||||
scrollbar-darkshadow-color: #fff; /*滚动条暗边框(ThreedDarkShadow)颜色*/
|
||||
}
|
||||
|
||||
|
||||
// 详情页样式
|
||||
.detail-structure{
|
||||
background: #fff;
|
||||
.detail-container{
|
||||
padding: 20px 40px 40px;
|
||||
.edit_form{
|
||||
width: 70%;
|
||||
padding:10px 20px;
|
||||
.el-select,.el-cascader{
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.detail_form{
|
||||
// border: 1px solid red;
|
||||
width: 70%;
|
||||
padding:10px 20px;
|
||||
clear: both;
|
||||
.el-select{
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.course_form{
|
||||
padding: 20px;
|
||||
width: 70%;
|
||||
}
|
||||
.detail_view{
|
||||
width: 70%;
|
||||
padding:0 20px 20px;
|
||||
}
|
||||
.detail_foot{
|
||||
clear: both;
|
||||
border-top: 1px dashed #eaeaea;
|
||||
padding-top: 40px;
|
||||
text-align: center;
|
||||
.el-button+.el-button{
|
||||
margin-left: 20px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
//身份证及证书上传
|
||||
.imgs_update{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.up_tip_test{
|
||||
padding-left: 24px;
|
||||
p{
|
||||
font-size: 12px;
|
||||
margin: 0;
|
||||
line-height: 1.8;
|
||||
color: #909399;
|
||||
|
||||
}
|
||||
.h1{
|
||||
font-size: 14px;
|
||||
color: #606266;
|
||||
}
|
||||
.a1{
|
||||
color: #3a8ee6;
|
||||
&:hover{
|
||||
cursor: pointer;
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.imgs_update .el-upload--picture-card{
|
||||
width: 210px;
|
||||
height: 132px;
|
||||
i{
|
||||
color: #c0ccda;
|
||||
}
|
||||
}
|
||||
.imgs_update .el-upload-list--picture-card .el-upload-list__item{
|
||||
width: 210px;
|
||||
height: 132px;
|
||||
}
|
||||
|
||||
.imgs_update .el-upload--picture-card .up_tip_icon{
|
||||
position: relative;
|
||||
text-align: center;
|
||||
.up_tip_i{
|
||||
line-height: 50px;
|
||||
margin-top: 25px;
|
||||
}
|
||||
.up_tip_text{
|
||||
line-height: 1;
|
||||
color: #c0ccda;
|
||||
}
|
||||
}
|
||||
.demo-image__preview{
|
||||
position: relative;
|
||||
width: 210px; height: 132px;
|
||||
.demo-closed{
|
||||
position: absolute;
|
||||
z-index: 2;
|
||||
background-color: #fff;
|
||||
border-radius: 100px;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
top: -4px;
|
||||
right: -4px;
|
||||
text-align: center;
|
||||
cursor: pointer;
|
||||
box-shadow: 2px 2px 5px #000;
|
||||
i{
|
||||
position: relative;
|
||||
top: -5px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 新增课程
|
||||
.course_warp{
|
||||
padding-bottom: 20px;
|
||||
.course_directory2{
|
||||
|
||||
.course_item{
|
||||
.course_row{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding:3px 10px;
|
||||
margin-bottom: 10px;
|
||||
&:hover{
|
||||
background-color: #f5f7fa;
|
||||
cursor: pointer;
|
||||
}
|
||||
div+div{
|
||||
margin-left: 10px;
|
||||
}
|
||||
.course_icon{
|
||||
color: #c0c4cc;
|
||||
font-size: 12px;
|
||||
width: 12px;
|
||||
height: 14px;
|
||||
display: block;
|
||||
}
|
||||
.course_play{
|
||||
color: #565656;
|
||||
font-size: 16px;
|
||||
width: 16px;
|
||||
height:15px;
|
||||
display: block;
|
||||
}
|
||||
.course_number{
|
||||
background-color: #e0f2ff;
|
||||
font-size: 13px;
|
||||
text-align: center;
|
||||
padding: 4px 5px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.course_input{
|
||||
width: 300px;
|
||||
font-size: 13px;
|
||||
}
|
||||
}
|
||||
.course_subrow{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding:3px 40px;
|
||||
margin-bottom: 10px;
|
||||
&:hover{
|
||||
background-color: #f5f7fa;
|
||||
cursor: pointer;
|
||||
}
|
||||
div+div{
|
||||
margin-left: 10px;
|
||||
}
|
||||
.course_icon{
|
||||
color: #c0c4cc;
|
||||
font-size: 12px;
|
||||
width: 12px;
|
||||
height: 14px;
|
||||
display: block;
|
||||
}
|
||||
.course_play{
|
||||
color: #565656;
|
||||
font-size: 16px;
|
||||
width: 16px;
|
||||
height:15px;
|
||||
display: block;
|
||||
}
|
||||
.course_number{
|
||||
background-color: #e0f2ff;
|
||||
font-size: 13px;
|
||||
text-align: center;
|
||||
padding: 4px 5px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.course_input{
|
||||
width: 270px;
|
||||
font-size: 13px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
.release_style{
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
|
@ -5,6 +5,7 @@
|
|||
@import './sidebar.scss';
|
||||
@import './btn.scss';
|
||||
@import './custom.scss';
|
||||
@import './business.scss';
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
|
|
|
|||
|
|
@ -123,11 +123,12 @@ export default {
|
|||
return data.NAME.indexOf(value) !== -1
|
||||
},
|
||||
append(data) {
|
||||
const newChild = { BUS_LABEL_FACTORY_ID: id++, label: 'test', children: [] }
|
||||
const newChild = { BUS_LABEL_FACTORY_ID: id++, label: 'test', NAME: '新子节点', children: [] }
|
||||
if (!data.children) {
|
||||
this.$set(data, 'children', [])
|
||||
}
|
||||
data.children.push(newChild)
|
||||
this.$forceUpdate()
|
||||
},
|
||||
edit(data) {
|
||||
this.$refs.editSonLabel.init(data)
|
||||
|
|
|
|||
|
|
@ -58,6 +58,10 @@ export default {
|
|||
this.dialogVisible = false
|
||||
},
|
||||
save() {
|
||||
if (!this.name) {
|
||||
this.$message.error('节点名称必填!')
|
||||
return
|
||||
}
|
||||
this.e.NAME = this.name
|
||||
this.$emit('getResult', this.e)
|
||||
this.dialogVisible = false
|
||||
|
|
|
|||
|
|
@ -0,0 +1,520 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="filter-container">
|
||||
<div class="filter-row">
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable"> 关键字:</div>
|
||||
<el-input v-model="KEYWORDS" placeholder="搜索" clearable style="width: 200px;" @clear="getQuery"/>
|
||||
</div>
|
||||
<el-button v-waves class="ml-10" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row
|
||||
>
|
||||
<el-table-column
|
||||
:reserve-selection="true"
|
||||
type="selection"
|
||||
width="55"
|
||||
align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="CORP_NAME" label="企业名称" />
|
||||
<el-table-column prop="DOCKING_KEY" label="对接KEY" align="center" />
|
||||
<el-table-column prop="DOCKING_IV" label="对接IV" />
|
||||
<el-table-column prop="DOCKING_URL" label="对接URL" />
|
||||
<el-table-column label="操作" align="center" width="360">
|
||||
<template slot-scope="{row}">
|
||||
<div class="clear_interval">
|
||||
<el-button type="success" icon="el-icon-delete" size="mini" @click="handleEdit(row.CORPINFO_ID)">编辑</el-button>
|
||||
<el-button type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.CORPINFO_ID)">删除</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button type="primary" icon="el-icon-plus" @click="handleAdd">新增</el-button>
|
||||
<el-button type="danger" icon="el-icon-delete" plain @click="batchDel">删除</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
<el-dialog :visible.sync="dialogFormEdit" :title="dialogType==='edit'?'修改':'新增'" width="600px">
|
||||
<el-form ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item label="企业名称" prop="CORP_NAME">
|
||||
<el-select v-model="form.CORP_NAME" :disabled="dialogType==='edit'" filterable clearable placeholder="请选择企业" style="width: 100%">
|
||||
<el-option v-for="item in corpList" :key="item.CORPINFO_ID" :label="item.CORP_NAME" :value="item.CORPINFO_ID" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接KEY" prop="DOCKING_KEY">
|
||||
<el-input id="DOCKING_KEY" ref="DOCKING_KEY" v-model="form.DOCKING_KEY" maxlength="255" placeholder="这里输入对接KEY..." title="对接KEY"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接IV" prop="DOCKING_IV">
|
||||
<el-input id="DOCKING_IV" ref="DOCKING_IV" v-model="form.DOCKING_IV" maxlength="255" placeholder="这里输入对接IV..." title="对接IV"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接URL" prop="DOCKING_URL">
|
||||
<el-input id="DOCKING_URL" ref="DOCKING_URL" v-model="form.DOCKING_URL" maxlength="255" placeholder="这里输入对接URL..." title="对接URL"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业CODE" prop="CODE">
|
||||
<el-input id="CODE" ref="CODE" v-model="form.CODE" maxlength="255" placeholder="这里输入企业CODE..." title="企业CODE"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业APPID" prop="APPID">
|
||||
<el-input id="APPID" ref="APPID" v-model="form.APPID" maxlength="255" placeholder="这里输入企业APPID..." title="企业APPID"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业SECRET" prop="SECRET">
|
||||
<el-input id="SECRET" ref="SECRET" v-model="form.SECRET" maxlength="255" placeholder="这里输入企业SECRET..." title="企业SECRET"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormEdit = false">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
// import { upload } from '@/utils/upload'
|
||||
import pdf from 'vue-pdf'
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
export default {
|
||||
components: { Pagination, pdf, SelectTree },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
KEYWORDS_USER: '',
|
||||
dates: [],
|
||||
userListQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
userTotal: 0,
|
||||
total: 0,
|
||||
config: config,
|
||||
KEYWORDS: '',
|
||||
FEEDBACK_TYPE: '',
|
||||
varList: [],
|
||||
pd: [],
|
||||
corpVarList: [],
|
||||
corpList: [],
|
||||
form: {
|
||||
CORPINFO_ID: '',
|
||||
DOCKING_KEY: '',
|
||||
DOCKING_IV: '',
|
||||
DOCKING_URL: '',
|
||||
CODE: '',
|
||||
APPID: '',
|
||||
SECRET: ''
|
||||
},
|
||||
defaultProps: {
|
||||
value: 'id',
|
||||
children: 'nodes',
|
||||
label: 'name'
|
||||
},
|
||||
multipleSelectionAll: [], // 所有选中的数据包含跨页数据
|
||||
multipleSelection: [], // 当前页选中的数据
|
||||
dialogFormEdit: false,
|
||||
dialogFormUser: false,
|
||||
dialogType: 'add',
|
||||
LearnerCategoryList: [],
|
||||
// pdf预览
|
||||
dialogViewPdf: false,
|
||||
serverurl: config.fileUrl,
|
||||
pdfUrl: '',
|
||||
pageNum: 1,
|
||||
pageTotalNum: 1, // 总页数
|
||||
loadedRatio: 0, // 当前页面的加载进度,范围是0-1 ,等于1的时候代表当前页已经完全加载完成了
|
||||
rules: {
|
||||
CORPINFO_ID: [{ required: true, message: '企业名称不能为空', trigger: 'blur' }],
|
||||
DOCKING_KEY: [{ required: true, message: '对接KEY不能为空', trigger: 'blur' }],
|
||||
DOCKING_IV: [{ required: true, message: '对接IV不能为空', trigger: 'blur' }],
|
||||
DOCKING_URL: [{ required: true, message: '对接URL不能为空', trigger: 'blur' }],
|
||||
CODE: [{ required: true, message: '对接CODE不能为空', trigger: 'blur' }],
|
||||
APPID: [{ required: true, message: '对接APPID不能为空', trigger: 'blur' }],
|
||||
SECRET: [{ required: true, message: '对接SECRET不能为空', trigger: 'blur' }]
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.getDict()
|
||||
// this.getIdcList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.SURVEY_ID
|
||||
},
|
||||
handleAdd() {
|
||||
this.dialogType = 'add'
|
||||
this.$refs.form && this.$refs.form.clearValidate()
|
||||
this.resetForm()
|
||||
this.dialogFormEdit = true
|
||||
this.getCorpList()
|
||||
},
|
||||
getCorpList() {
|
||||
requestFN(
|
||||
'/keyprocesses/CorplistAll',
|
||||
{
|
||||
}
|
||||
).then((data) => {
|
||||
if (data.result == 'success') {
|
||||
this.corpList = data.varList
|
||||
}
|
||||
}).catch((e) => {
|
||||
|
||||
})
|
||||
},
|
||||
handleEdit(ID) {
|
||||
this.$refs.form && this.$refs.form.clearValidate()
|
||||
this.getDict()
|
||||
this.dialogType = 'edit'
|
||||
requestFN(
|
||||
'/keyprocesses/goEdit',
|
||||
{
|
||||
CORPINFO_ID: ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.form = Object.assign({}, data.pd) // copy obj
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
this.dialogFormEdit = true
|
||||
},
|
||||
confirm() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/keyprocesses/' + this.dialogType,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.dialogFormEdit = false
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
},
|
||||
goKeyReset() {
|
||||
this.KEYWORDS = ''
|
||||
this.FEEDBACK_TYPE = ''
|
||||
this.getQuery()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/keyprocesses/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
KEYWORDS: this.KEYWORDS,
|
||||
FEEDBACK_TYPE: this.FEEDBACK_TYPE,
|
||||
CREAT_TIME: this.CREAT_TIME
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.pd = data.pd
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
|
||||
validStr(str) {
|
||||
if (str != null && str != '' && typeof (str) != 'undefined' && str != 0) { return true }
|
||||
return false
|
||||
},
|
||||
beforeDataFileUpload(file) {
|
||||
const types = ['doc', 'docx', 'pdf']
|
||||
const fileSuffix = file.name.slice(file.name.lastIndexOf('.') + 1)
|
||||
const isImage = types.includes(fileSuffix.toLowerCase())
|
||||
if (this.fileList.length > 0) {
|
||||
this.$message.error('文件超出个数限制!')
|
||||
return false
|
||||
}
|
||||
if (!isImage) {
|
||||
this.$message.error('上传文件格式只能是PDF 格式!')
|
||||
return false
|
||||
} else {
|
||||
const filistMap = {}
|
||||
filistMap.name = file.name
|
||||
filistMap.file = file
|
||||
this.fileList.push(filistMap)
|
||||
this.form.cfile = file
|
||||
this.form.COURSEWAREFILES = file
|
||||
this.$forceUpdate()
|
||||
return true
|
||||
}
|
||||
},
|
||||
handleRemoveData(file, fileList) { // 文件列表移除文件时的钩子
|
||||
if (file.file) {
|
||||
const types = ['doc', 'docx', 'pdf']
|
||||
const isImage = types.includes(file.file.type)
|
||||
if (isImage) {
|
||||
this.fileList = []
|
||||
}
|
||||
}
|
||||
},
|
||||
beforeCaptureFileUpload(file) {
|
||||
const types = ['image/jpeg', 'image/jpg', 'image/png']
|
||||
const isImage = types.includes(file.type)
|
||||
if (!isImage) {
|
||||
this.$message.error('上传图片只能是 JPG、JPEG、PNG 格式!')
|
||||
} else {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.$forceUpdate()
|
||||
return false
|
||||
}
|
||||
},
|
||||
handlePictureCardPreview(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.form.dialogImageUrl = file.url
|
||||
this.form.dialogVisible = true
|
||||
},
|
||||
handleRemove(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.hideUpload = fileList.length >= 1
|
||||
},
|
||||
handleEditChange(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.hideUpload = fileList.length >= 1
|
||||
},
|
||||
// pdf 预览
|
||||
goViewPdf(filePath) {
|
||||
this.pageNum = 1
|
||||
this.pdfUrl = this.serverurl + filePath
|
||||
this.dialogViewPdf = true
|
||||
},
|
||||
// 上一页
|
||||
prePage() {
|
||||
let page = this.pageNum
|
||||
page = page > 1 ? page - 1 : this.pageTotalNum
|
||||
this.pageNum = page
|
||||
},
|
||||
|
||||
// 下一页
|
||||
nextPage() {
|
||||
let page = this.pageNum
|
||||
page = page < this.pageTotalNum ? page + 1 : 1
|
||||
this.pageNum = page
|
||||
},
|
||||
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/keyprocesses/delete',
|
||||
{
|
||||
CORPINFO_ID: id
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
|
||||
batchDel() {
|
||||
const _selectData = this.$refs.multipleTable.selection
|
||||
if (_selectData == null || _selectData.length == 0) {
|
||||
this.$message({
|
||||
message: '请选中要删除的项...',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const ids = _selectData.map((item, index) => {
|
||||
return item.CORPINFO_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/keyprocesses/deleteAll',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
getDict: function() {
|
||||
// requestFN(
|
||||
// '/dictionaries/getLevels',
|
||||
// {
|
||||
// DICTIONARIES_ID: '532282f9c48346b8b646531909c739df'
|
||||
// }
|
||||
// ).then((data) => {
|
||||
// this.LearnerCategoryList = data.list
|
||||
// }).catch((e) => {
|
||||
//
|
||||
// })
|
||||
// requestFN(
|
||||
// '/dictionaries/getLevels',
|
||||
// {
|
||||
// DICTIONARIES_ID: '3c0d9b5e74834adfacb76139e5d731e5'
|
||||
// }
|
||||
// ).then((data) => {
|
||||
// this.dicListMap.outlineDicList = data.list
|
||||
// }).catch((e) => {
|
||||
// })
|
||||
},
|
||||
resetForm() {
|
||||
this.form = {
|
||||
TITLE: '',
|
||||
BEGIN_TIME: '',
|
||||
END_TIME: '',
|
||||
IS_PUBLISH: '',
|
||||
fileIsType: true,
|
||||
captureIsType: true
|
||||
}
|
||||
// if (this.$refs.pxTree) {
|
||||
// this.$refs.pxTree.clearHandle()
|
||||
// }
|
||||
// if (this.$refs.gwTree) {
|
||||
// this.$refs.gwTree.clearHandle()
|
||||
// }
|
||||
// if (this.$refs.dataUpload || this.fileList.length > 0) {
|
||||
// this.fileList = []
|
||||
// // this.form.ccfile = ''
|
||||
// // this.form.COURSEWARECAPTURE = ''
|
||||
// this.hideUpload = false
|
||||
// this.$refs.dataUpload.clearFiles()
|
||||
// }
|
||||
// if (this.$refs.dataCaptureUpload) {
|
||||
// this.form.cfile = ''
|
||||
// this.$refs.dataCaptureUpload.clearFiles()
|
||||
// }
|
||||
},
|
||||
getDicListByPID(pId, listName) {
|
||||
requestFN(
|
||||
'/dictionaries/listAllDictToParId',
|
||||
{
|
||||
parentId: pId
|
||||
}
|
||||
).then((data) => {
|
||||
this.dicListMap[listName] = JSON.parse(data.zTreeNodes)
|
||||
}).catch((e) => {
|
||||
|
||||
})
|
||||
},
|
||||
// getIdcList() {
|
||||
// this.getDicListByPID('052369aa22d242118236cde52d0c67ea', 'trainDicList')
|
||||
// this.getDicListByPID('f6a7c4f5602f46e291d06b1390a3f820', 'postDicList')
|
||||
// this.getDicListByPID('d538d11e4eec409ab428f5d2f3c67c24', 'trainingSectionList') // 培训板块
|
||||
// this.getDicListByPID('4459d3ff36d1475d8b2266da959fcc44', 'relatedTermList') // 相关词条
|
||||
// this.getTeacher()
|
||||
// },
|
||||
// 修改
|
||||
handleEditState(ID, state) {
|
||||
requestFN(
|
||||
'/survey/editState',
|
||||
{
|
||||
SURVEY_ID: ID,
|
||||
IS_PUBLISH: state
|
||||
}
|
||||
).then((data) => {
|
||||
this.$message({
|
||||
message: '发布成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
delFujian(item) {
|
||||
this.form.fileIsType = true
|
||||
this.form.COURSEWAREFILES = ''
|
||||
},
|
||||
delFujianTupian(item) {
|
||||
this.form.captureIsType = true
|
||||
this.form.COURSEWARECAPTURE = ''
|
||||
this.form.ccfile = ''
|
||||
this.hideUpload = false
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.hide .el-upload--picture-card {
|
||||
display: none;
|
||||
}
|
||||
div.popContainer {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
background: rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
</style>
|
||||
|
|
@ -0,0 +1,529 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="filter-container">
|
||||
<div class="filter-row">
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable"> 关键字:</div>
|
||||
<el-input v-model="KEYWORDS" placeholder="搜索" clearable style="width: 200px;" @clear="getQuery"/>
|
||||
</div>
|
||||
<el-button v-waves class="ml-10" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row
|
||||
>
|
||||
<el-table-column
|
||||
:reserve-selection="true"
|
||||
type="selection"
|
||||
width="55"
|
||||
align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="CORP_NAME" label="企业名称" />
|
||||
<el-table-column prop="DOCKING_KEY" label="对接KEY" align="center" />
|
||||
<el-table-column prop="DOCKING_IV" label="对接IV" />
|
||||
<el-table-column prop="DOCKING_URL" label="对接URL" />
|
||||
<el-table-column label="操作" align="center" width="360">
|
||||
<template slot-scope="{row}">
|
||||
<div class="clear_interval">
|
||||
<el-button type="success" icon="el-icon-delete" size="mini" @click="handleEdit(row.CORPINFO_ID)">编辑</el-button>
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.CORPINFO_ID)">删除</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button v-show="add" type="primary" icon="el-icon-plus" @click="handleAdd">新增</el-button>
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" plain @click="batchDel">删除</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
<el-dialog :visible.sync="dialogFormEdit" :title="dialogType==='edit'?'修改':'新增'" width="600px">
|
||||
<el-form ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item label="企业名称" prop="CORP_NAME">
|
||||
<el-select v-model="form.CORP_NAME" :disabled="dialogType==='edit'" filterable clearable placeholder="请选择企业" style="width: 100%">
|
||||
<el-option v-for="item in corpList" :key="item.CORPINFO_ID" :label="item.CORP_NAME" :value="item.CORPINFO_ID" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接KEY" prop="DOCKING_KEY">
|
||||
<el-input id="DOCKING_KEY" ref="DOCKING_KEY" v-model="form.DOCKING_KEY" maxlength="255" placeholder="这里输入对接KEY..." title="对接KEY"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接IV" prop="DOCKING_IV">
|
||||
<el-input id="DOCKING_IV" ref="DOCKING_IV" v-model="form.DOCKING_IV" maxlength="255" placeholder="这里输入对接IV..." title="对接IV"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接URL" prop="DOCKING_URL">
|
||||
<el-input id="DOCKING_URL" ref="DOCKING_URL" v-model="form.DOCKING_URL" maxlength="255" placeholder="这里输入对接URL..." title="对接URL"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业CODE" prop="CODE">
|
||||
<el-input id="CODE" ref="CODE" v-model="form.CODE" maxlength="255" placeholder="这里输入企业CODE..." title="企业CODE"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业APPID" prop="APPID">
|
||||
<el-input id="APPID" ref="APPID" v-model="form.APPID" maxlength="255" placeholder="这里输入企业APPID..." title="企业APPID"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业SECRET" prop="SECRET">
|
||||
<el-input id="SECRET" ref="SECRET" v-model="form.SECRET" maxlength="255" placeholder="这里输入企业SECRET..." title="企业SECRET"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormEdit = false">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
// import { upload } from '@/utils/upload'
|
||||
import pdf from 'vue-pdf'
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
export default {
|
||||
components: { Pagination, pdf, SelectTree },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
KEYWORDS_USER: '',
|
||||
dates: [],
|
||||
userListQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
userTotal: 0,
|
||||
total: 0,
|
||||
config: config,
|
||||
KEYWORDS: '',
|
||||
FEEDBACK_TYPE: '',
|
||||
varList: [],
|
||||
pd: [],
|
||||
corpVarList: [],
|
||||
corpList: [],
|
||||
form: {
|
||||
CORPINFO_ID: '',
|
||||
DOCKING_KEY: '',
|
||||
DOCKING_IV: '',
|
||||
DOCKING_URL: '',
|
||||
CODE: '',
|
||||
APPID: '',
|
||||
SECRET: ''
|
||||
},
|
||||
defaultProps: {
|
||||
value: 'id',
|
||||
children: 'nodes',
|
||||
label: 'name'
|
||||
},
|
||||
multipleSelectionAll: [], // 所有选中的数据包含跨页数据
|
||||
multipleSelection: [], // 当前页选中的数据
|
||||
dialogFormEdit: false,
|
||||
dialogFormUser: false,
|
||||
dialogType: 'add',
|
||||
LearnerCategoryList: [],
|
||||
// pdf预览
|
||||
dialogViewPdf: false,
|
||||
serverurl: config.fileUrl,
|
||||
pdfUrl: '',
|
||||
pageNum: 1,
|
||||
pageTotalNum: 1, // 总页数
|
||||
loadedRatio: 0, // 当前页面的加载进度,范围是0-1 ,等于1的时候代表当前页已经完全加载完成了
|
||||
rules: {
|
||||
CORPINFO_ID: [{ required: true, message: '企业名称不能为空', trigger: 'blur' }],
|
||||
DOCKING_KEY: [{ required: true, message: '对接KEY不能为空', trigger: 'blur' }],
|
||||
DOCKING_IV: [{ required: true, message: '对接IV不能为空', trigger: 'blur' }],
|
||||
DOCKING_URL: [{ required: true, message: '对接URL不能为空', trigger: 'blur' }],
|
||||
CODE: [{ required: true, message: '对接CODE不能为空', trigger: 'blur' }],
|
||||
APPID: [{ required: true, message: '对接APPID不能为空', trigger: 'blur' }],
|
||||
SECRET: [{ required: true, message: '对接SECRET不能为空', trigger: 'blur' }]
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.getDict()
|
||||
// this.getIdcList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.SURVEY_ID
|
||||
},
|
||||
handleAdd() {
|
||||
this.dialogType = 'add'
|
||||
this.$refs.form && this.$refs.form.clearValidate()
|
||||
this.resetForm()
|
||||
this.dialogFormEdit = true
|
||||
this.getCorpList()
|
||||
},
|
||||
getCorpList() {
|
||||
requestFN(
|
||||
'/responsibleperson/CorplistAll',
|
||||
{
|
||||
}
|
||||
).then((data) => {
|
||||
if (data.result == 'success') {
|
||||
this.corpList = data.varList
|
||||
}
|
||||
}).catch((e) => {
|
||||
|
||||
})
|
||||
},
|
||||
handleEdit(ID) {
|
||||
this.$refs.form && this.$refs.form.clearValidate()
|
||||
this.getDict()
|
||||
this.dialogType = 'edit'
|
||||
requestFN(
|
||||
'/responsibleperson/goEdit',
|
||||
{
|
||||
CORPINFO_ID: ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.form = Object.assign({}, data.pd) // copy obj
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
this.dialogFormEdit = true
|
||||
},
|
||||
confirm() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/responsibleperson/' + this.dialogType,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.dialogFormEdit = false
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
},
|
||||
goKeyReset() {
|
||||
this.KEYWORDS = ''
|
||||
this.FEEDBACK_TYPE = ''
|
||||
this.getQuery()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/responsibleperson/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
KEYWORDS: this.KEYWORDS,
|
||||
FEEDBACK_TYPE: this.FEEDBACK_TYPE,
|
||||
CREAT_TIME: this.CREAT_TIME
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.hasButton()
|
||||
this.total = data.page.totalResult
|
||||
this.pd = data.pd
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
|
||||
validStr(str) {
|
||||
if (str != null && str != '' && typeof (str) != 'undefined' && str != 0) { return true }
|
||||
return false
|
||||
},
|
||||
beforeDataFileUpload(file) {
|
||||
const types = ['doc', 'docx', 'pdf']
|
||||
const fileSuffix = file.name.slice(file.name.lastIndexOf('.') + 1)
|
||||
const isImage = types.includes(fileSuffix.toLowerCase())
|
||||
if (this.fileList.length > 0) {
|
||||
this.$message.error('文件超出个数限制!')
|
||||
return false
|
||||
}
|
||||
if (!isImage) {
|
||||
this.$message.error('上传文件格式只能是PDF 格式!')
|
||||
return false
|
||||
} else {
|
||||
const filistMap = {}
|
||||
filistMap.name = file.name
|
||||
filistMap.file = file
|
||||
this.fileList.push(filistMap)
|
||||
this.form.cfile = file
|
||||
this.form.COURSEWAREFILES = file
|
||||
this.$forceUpdate()
|
||||
return true
|
||||
}
|
||||
},
|
||||
handleRemoveData(file, fileList) { // 文件列表移除文件时的钩子
|
||||
if (file.file) {
|
||||
const types = ['doc', 'docx', 'pdf']
|
||||
const isImage = types.includes(file.file.type)
|
||||
if (isImage) {
|
||||
this.fileList = []
|
||||
}
|
||||
}
|
||||
},
|
||||
beforeCaptureFileUpload(file) {
|
||||
const types = ['image/jpeg', 'image/jpg', 'image/png']
|
||||
const isImage = types.includes(file.type)
|
||||
if (!isImage) {
|
||||
this.$message.error('上传图片只能是 JPG、JPEG、PNG 格式!')
|
||||
} else {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.$forceUpdate()
|
||||
return false
|
||||
}
|
||||
},
|
||||
handlePictureCardPreview(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.form.dialogImageUrl = file.url
|
||||
this.form.dialogVisible = true
|
||||
},
|
||||
handleRemove(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.hideUpload = fileList.length >= 1
|
||||
},
|
||||
handleEditChange(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.hideUpload = fileList.length >= 1
|
||||
},
|
||||
// pdf 预览
|
||||
goViewPdf(filePath) {
|
||||
this.pageNum = 1
|
||||
this.pdfUrl = this.serverurl + filePath
|
||||
this.dialogViewPdf = true
|
||||
},
|
||||
// 上一页
|
||||
prePage() {
|
||||
let page = this.pageNum
|
||||
page = page > 1 ? page - 1 : this.pageTotalNum
|
||||
this.pageNum = page
|
||||
},
|
||||
|
||||
// 下一页
|
||||
nextPage() {
|
||||
let page = this.pageNum
|
||||
page = page < this.pageTotalNum ? page + 1 : 1
|
||||
this.pageNum = page
|
||||
},
|
||||
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/responsibleperson/delete',
|
||||
{
|
||||
CORPINFO_ID: id
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
|
||||
batchDel() {
|
||||
const _selectData = this.$refs.multipleTable.selection
|
||||
if (_selectData == null || _selectData.length == 0) {
|
||||
this.$message({
|
||||
message: '请选中要删除的项...',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const ids = _selectData.map((item, index) => {
|
||||
return item.CORPINFO_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/responsibleperson/deleteAll',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
// 判断按钮权限,用于是否显示按钮
|
||||
hasButton: function() {
|
||||
this.add = true
|
||||
this.del = true // 删除权限
|
||||
this.edit = true // 修改权限
|
||||
},
|
||||
// 获取数据字典数据
|
||||
getDict: function() {
|
||||
// requestFN(
|
||||
// '/dictionaries/getLevels',
|
||||
// {
|
||||
// DICTIONARIES_ID: '532282f9c48346b8b646531909c739df'
|
||||
// }
|
||||
// ).then((data) => {
|
||||
// this.LearnerCategoryList = data.list
|
||||
// }).catch((e) => {
|
||||
//
|
||||
// })
|
||||
// requestFN(
|
||||
// '/dictionaries/getLevels',
|
||||
// {
|
||||
// DICTIONARIES_ID: '3c0d9b5e74834adfacb76139e5d731e5'
|
||||
// }
|
||||
// ).then((data) => {
|
||||
// this.dicListMap.outlineDicList = data.list
|
||||
// }).catch((e) => {
|
||||
// })
|
||||
},
|
||||
resetForm() {
|
||||
this.form = {
|
||||
CORPINFO_ID: '',
|
||||
DOCKING_KEY: '',
|
||||
DOCKING_IV: '',
|
||||
DOCKING_URL: '',
|
||||
CODE: '',
|
||||
APPID: '',
|
||||
SECRET: ''
|
||||
}
|
||||
// if (this.$refs.pxTree) {
|
||||
// this.$refs.pxTree.clearHandle()
|
||||
// }
|
||||
// if (this.$refs.gwTree) {
|
||||
// this.$refs.gwTree.clearHandle()
|
||||
// }
|
||||
// if (this.$refs.dataUpload || this.fileList.length > 0) {
|
||||
// this.fileList = []
|
||||
// // this.form.ccfile = ''
|
||||
// // this.form.COURSEWARECAPTURE = ''
|
||||
// this.hideUpload = false
|
||||
// this.$refs.dataUpload.clearFiles()
|
||||
// }
|
||||
// if (this.$refs.dataCaptureUpload) {
|
||||
// this.form.cfile = ''
|
||||
// this.$refs.dataCaptureUpload.clearFiles()
|
||||
// }
|
||||
},
|
||||
getDicListByPID(pId, listName) {
|
||||
requestFN(
|
||||
'/dictionaries/listAllDictToParId',
|
||||
{
|
||||
parentId: pId
|
||||
}
|
||||
).then((data) => {
|
||||
this.dicListMap[listName] = JSON.parse(data.zTreeNodes)
|
||||
}).catch((e) => {
|
||||
|
||||
})
|
||||
},
|
||||
// getIdcList() {
|
||||
// this.getDicListByPID('052369aa22d242118236cde52d0c67ea', 'trainDicList')
|
||||
// this.getDicListByPID('f6a7c4f5602f46e291d06b1390a3f820', 'postDicList')
|
||||
// this.getDicListByPID('d538d11e4eec409ab428f5d2f3c67c24', 'trainingSectionList') // 培训板块
|
||||
// this.getDicListByPID('4459d3ff36d1475d8b2266da959fcc44', 'relatedTermList') // 相关词条
|
||||
// this.getTeacher()
|
||||
// },
|
||||
// 修改
|
||||
handleEditState(ID, state) {
|
||||
requestFN(
|
||||
'/survey/editState',
|
||||
{
|
||||
SURVEY_ID: ID,
|
||||
IS_PUBLISH: state
|
||||
}
|
||||
).then((data) => {
|
||||
this.$message({
|
||||
message: '发布成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
delFujian(item) {
|
||||
this.form.fileIsType = true
|
||||
this.form.COURSEWAREFILES = ''
|
||||
},
|
||||
delFujianTupian(item) {
|
||||
this.form.captureIsType = true
|
||||
this.form.COURSEWARECAPTURE = ''
|
||||
this.form.ccfile = ''
|
||||
this.hideUpload = false
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.hide .el-upload--picture-card {
|
||||
display: none;
|
||||
}
|
||||
div.popContainer {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
background: rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
</style>
|
||||
|
|
@ -0,0 +1,528 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="filter-container">
|
||||
<div class="filter-row">
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable"> 关键字:</div>
|
||||
<el-input v-model="KEYWORDS" placeholder="搜索" clearable style="width: 200px;" @clear="getQuery"/>
|
||||
</div>
|
||||
<el-button v-waves class="ml-10" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row
|
||||
>
|
||||
<el-table-column
|
||||
:reserve-selection="true"
|
||||
type="selection"
|
||||
width="55"
|
||||
align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="CORP_NAME" label="企业名称" />
|
||||
<el-table-column prop="DOCKING_KEY" label="对接KEY" align="center" />
|
||||
<el-table-column prop="DOCKING_IV" label="对接IV" />
|
||||
<el-table-column prop="DOCKING_URL" label="对接URL" />
|
||||
<el-table-column label="操作" align="center" width="360">
|
||||
<template slot-scope="{row}">
|
||||
<div class="clear_interval">
|
||||
<el-button type="success" icon="el-icon-delete" size="mini" @click="handleEdit(row.CORPINFO_ID)">编辑</el-button>
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.CORPINFO_ID)">删除</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button v-show="add" type="primary" icon="el-icon-plus" @click="handleAdd">新增</el-button>
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" plain @click="batchDel">删除</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
<el-dialog :visible.sync="dialogFormEdit" :title="dialogType==='edit'?'修改':'新增'" width="600px">
|
||||
<el-form ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item label="企业名称" prop="CORP_NAME">
|
||||
<el-select v-model="form.CORP_NAME" :disabled="dialogType==='edit'" filterable clearable placeholder="请选择企业" style="width: 100%">
|
||||
<el-option v-for="item in corpList" :key="item.CORPINFO_ID" :label="item.CORP_NAME" :value="item.CORPINFO_ID" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接KEY" prop="DOCKING_KEY">
|
||||
<el-input id="DOCKING_KEY" ref="DOCKING_KEY" v-model="form.DOCKING_KEY" maxlength="255" placeholder="这里输入对接KEY..." title="对接KEY"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接IV" prop="DOCKING_IV">
|
||||
<el-input id="DOCKING_IV" ref="DOCKING_IV" v-model="form.DOCKING_IV" maxlength="255" placeholder="这里输入对接IV..." title="对接IV"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="对接URL" prop="DOCKING_URL">
|
||||
<el-input id="DOCKING_URL" ref="DOCKING_URL" v-model="form.DOCKING_URL" maxlength="255" placeholder="这里输入对接URL..." title="对接URL"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业CODE" prop="CODE">
|
||||
<el-input id="CODE" ref="CODE" v-model="form.CODE" maxlength="255" placeholder="这里输入企业CODE..." title="企业CODE"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业APPID" prop="APPID">
|
||||
<el-input id="APPID" ref="APPID" v-model="form.APPID" maxlength="255" placeholder="这里输入企业APPID..." title="企业APPID"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="企业SECRET" prop="SECRET">
|
||||
<el-input id="SECRET" ref="SECRET" v-model="form.SECRET" maxlength="255" placeholder="这里输入企业SECRET..." title="企业SECRET"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormEdit = false">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves' // waves directive
|
||||
// import { upload } from '@/utils/upload'
|
||||
import pdf from 'vue-pdf'
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
export default {
|
||||
components: { Pagination, pdf, SelectTree },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
KEYWORDS_USER: '',
|
||||
dates: [],
|
||||
userListQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
userTotal: 0,
|
||||
total: 0,
|
||||
config: config,
|
||||
KEYWORDS: '',
|
||||
FEEDBACK_TYPE: '',
|
||||
varList: [],
|
||||
pd: [],
|
||||
corpVarList: [],
|
||||
corpList: [],
|
||||
form: {
|
||||
CORPINFO_ID: '',
|
||||
DOCKING_KEY: '',
|
||||
DOCKING_IV: '',
|
||||
DOCKING_URL: '',
|
||||
CODE: '',
|
||||
APPID: '',
|
||||
SECRET: ''
|
||||
},
|
||||
defaultProps: {
|
||||
value: 'id',
|
||||
children: 'nodes',
|
||||
label: 'name'
|
||||
},
|
||||
multipleSelectionAll: [], // 所有选中的数据包含跨页数据
|
||||
multipleSelection: [], // 当前页选中的数据
|
||||
dialogFormEdit: false,
|
||||
dialogFormUser: false,
|
||||
dialogType: 'add',
|
||||
LearnerCategoryList: [],
|
||||
// pdf预览
|
||||
dialogViewPdf: false,
|
||||
serverurl: config.fileUrl,
|
||||
pdfUrl: '',
|
||||
pageNum: 1,
|
||||
pageTotalNum: 1, // 总页数
|
||||
loadedRatio: 0, // 当前页面的加载进度,范围是0-1 ,等于1的时候代表当前页已经完全加载完成了
|
||||
rules: {
|
||||
CORPINFO_ID: [{ required: true, message: '企业名称不能为空', trigger: 'blur' }],
|
||||
DOCKING_KEY: [{ required: true, message: '对接KEY不能为空', trigger: 'blur' }],
|
||||
DOCKING_IV: [{ required: true, message: '对接IV不能为空', trigger: 'blur' }],
|
||||
DOCKING_URL: [{ required: true, message: '对接URL不能为空', trigger: 'blur' }],
|
||||
CODE: [{ required: true, message: '对接CODE不能为空', trigger: 'blur' }],
|
||||
APPID: [{ required: true, message: '对接APPID不能为空', trigger: 'blur' }],
|
||||
SECRET: [{ required: true, message: '对接SECRET不能为空', trigger: 'blur' }]
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.getDict()
|
||||
// this.getIdcList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.SURVEY_ID
|
||||
},
|
||||
handleAdd() {
|
||||
this.dialogType = 'add'
|
||||
this.$refs.form && this.$refs.form.clearValidate()
|
||||
this.resetForm()
|
||||
this.dialogFormEdit = true
|
||||
this.getCorpList()
|
||||
},
|
||||
getCorpList() {
|
||||
requestFN(
|
||||
'/specialInspection/CorplistAll',
|
||||
{
|
||||
}
|
||||
).then((data) => {
|
||||
if (data.result == 'success') {
|
||||
this.corpList = data.varList
|
||||
}
|
||||
}).catch((e) => {
|
||||
|
||||
})
|
||||
},
|
||||
handleEdit(ID) {
|
||||
this.$refs.form && this.$refs.form.clearValidate()
|
||||
this.getDict()
|
||||
this.dialogType = 'edit'
|
||||
requestFN(
|
||||
'/specialInspection/goEdit',
|
||||
{
|
||||
CORPINFO_ID: ID
|
||||
}
|
||||
).then((data) => {
|
||||
this.form = Object.assign({}, data.pd) // copy obj
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
this.dialogFormEdit = true
|
||||
},
|
||||
confirm() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/specialInspection/' + this.dialogType,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.dialogFormEdit = false
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
},
|
||||
goKeyReset() {
|
||||
this.KEYWORDS = ''
|
||||
this.FEEDBACK_TYPE = ''
|
||||
this.getQuery()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/specialInspection/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
KEYWORDS: this.KEYWORDS,
|
||||
FEEDBACK_TYPE: this.FEEDBACK_TYPE,
|
||||
CREAT_TIME: this.CREAT_TIME
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.hasButton()
|
||||
this.total = data.page.totalResult
|
||||
this.pd = data.pd
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
|
||||
validStr(str) {
|
||||
if (str != null && str != '' && typeof (str) != 'undefined' && str != 0) { return true }
|
||||
return false
|
||||
},
|
||||
beforeDataFileUpload(file) {
|
||||
const types = ['doc', 'docx', 'pdf']
|
||||
const fileSuffix = file.name.slice(file.name.lastIndexOf('.') + 1)
|
||||
const isImage = types.includes(fileSuffix.toLowerCase())
|
||||
if (this.fileList.length > 0) {
|
||||
this.$message.error('文件超出个数限制!')
|
||||
return false
|
||||
}
|
||||
if (!isImage) {
|
||||
this.$message.error('上传文件格式只能是PDF 格式!')
|
||||
return false
|
||||
} else {
|
||||
const filistMap = {}
|
||||
filistMap.name = file.name
|
||||
filistMap.file = file
|
||||
this.fileList.push(filistMap)
|
||||
this.form.cfile = file
|
||||
this.form.COURSEWAREFILES = file
|
||||
this.$forceUpdate()
|
||||
return true
|
||||
}
|
||||
},
|
||||
handleRemoveData(file, fileList) { // 文件列表移除文件时的钩子
|
||||
if (file.file) {
|
||||
const types = ['doc', 'docx', 'pdf']
|
||||
const isImage = types.includes(file.file.type)
|
||||
if (isImage) {
|
||||
this.fileList = []
|
||||
}
|
||||
}
|
||||
},
|
||||
beforeCaptureFileUpload(file) {
|
||||
const types = ['image/jpeg', 'image/jpg', 'image/png']
|
||||
const isImage = types.includes(file.type)
|
||||
if (!isImage) {
|
||||
this.$message.error('上传图片只能是 JPG、JPEG、PNG 格式!')
|
||||
} else {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.$forceUpdate()
|
||||
return false
|
||||
}
|
||||
},
|
||||
handlePictureCardPreview(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.form.dialogImageUrl = file.url
|
||||
this.form.dialogVisible = true
|
||||
},
|
||||
handleRemove(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.hideUpload = fileList.length >= 1
|
||||
},
|
||||
handleEditChange(file, fileList) {
|
||||
this.form.ccfile = file
|
||||
this.form.COURSEWARECAPTURE = file
|
||||
this.hideUpload = fileList.length >= 1
|
||||
},
|
||||
// pdf 预览
|
||||
goViewPdf(filePath) {
|
||||
this.pageNum = 1
|
||||
this.pdfUrl = this.serverurl + filePath
|
||||
this.dialogViewPdf = true
|
||||
},
|
||||
// 上一页
|
||||
prePage() {
|
||||
let page = this.pageNum
|
||||
page = page > 1 ? page - 1 : this.pageTotalNum
|
||||
this.pageNum = page
|
||||
},
|
||||
|
||||
// 下一页
|
||||
nextPage() {
|
||||
let page = this.pageNum
|
||||
page = page < this.pageTotalNum ? page + 1 : 1
|
||||
this.pageNum = page
|
||||
},
|
||||
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/specialInspection/delete',
|
||||
{
|
||||
CORPINFO_ID: id
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
|
||||
batchDel() {
|
||||
const _selectData = this.$refs.multipleTable.selection
|
||||
if (_selectData == null || _selectData.length == 0) {
|
||||
this.$message({
|
||||
message: '请选中要删除的项...',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const ids = _selectData.map((item, index) => {
|
||||
return item.CORPINFO_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/specialInspection/deleteAll',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
// 判断按钮权限,用于是否显示按钮
|
||||
hasButton: function() {
|
||||
this.add = true // 新增权限
|
||||
this.del = true // 删除权限
|
||||
this.edit = true // 修改权限
|
||||
},
|
||||
// 获取数据字典数据
|
||||
getDict: function() {
|
||||
// requestFN(
|
||||
// '/dictionaries/getLevels',
|
||||
// {
|
||||
// DICTIONARIES_ID: '532282f9c48346b8b646531909c739df'
|
||||
// }
|
||||
// ).then((data) => {
|
||||
// this.LearnerCategoryList = data.list
|
||||
// }).catch((e) => {
|
||||
//
|
||||
// })
|
||||
// requestFN(
|
||||
// '/dictionaries/getLevels',
|
||||
// {
|
||||
// DICTIONARIES_ID: '3c0d9b5e74834adfacb76139e5d731e5'
|
||||
// }
|
||||
// ).then((data) => {
|
||||
// this.dicListMap.outlineDicList = data.list
|
||||
// }).catch((e) => {
|
||||
// })
|
||||
},
|
||||
resetForm() {
|
||||
this.form = {
|
||||
TITLE: '',
|
||||
BEGIN_TIME: '',
|
||||
END_TIME: '',
|
||||
IS_PUBLISH: '',
|
||||
fileIsType: true,
|
||||
captureIsType: true
|
||||
}
|
||||
// if (this.$refs.pxTree) {
|
||||
// this.$refs.pxTree.clearHandle()
|
||||
// }
|
||||
// if (this.$refs.gwTree) {
|
||||
// this.$refs.gwTree.clearHandle()
|
||||
// }
|
||||
// if (this.$refs.dataUpload || this.fileList.length > 0) {
|
||||
// this.fileList = []
|
||||
// // this.form.ccfile = ''
|
||||
// // this.form.COURSEWARECAPTURE = ''
|
||||
// this.hideUpload = false
|
||||
// this.$refs.dataUpload.clearFiles()
|
||||
// }
|
||||
// if (this.$refs.dataCaptureUpload) {
|
||||
// this.form.cfile = ''
|
||||
// this.$refs.dataCaptureUpload.clearFiles()
|
||||
// }
|
||||
},
|
||||
getDicListByPID(pId, listName) {
|
||||
requestFN(
|
||||
'/dictionaries/listAllDictToParId',
|
||||
{
|
||||
parentId: pId
|
||||
}
|
||||
).then((data) => {
|
||||
this.dicListMap[listName] = JSON.parse(data.zTreeNodes)
|
||||
}).catch((e) => {
|
||||
|
||||
})
|
||||
},
|
||||
// getIdcList() {
|
||||
// this.getDicListByPID('052369aa22d242118236cde52d0c67ea', 'trainDicList')
|
||||
// this.getDicListByPID('f6a7c4f5602f46e291d06b1390a3f820', 'postDicList')
|
||||
// this.getDicListByPID('d538d11e4eec409ab428f5d2f3c67c24', 'trainingSectionList') // 培训板块
|
||||
// this.getDicListByPID('4459d3ff36d1475d8b2266da959fcc44', 'relatedTermList') // 相关词条
|
||||
// this.getTeacher()
|
||||
// },
|
||||
// 修改
|
||||
handleEditState(ID, state) {
|
||||
requestFN(
|
||||
'/survey/editState',
|
||||
{
|
||||
SURVEY_ID: ID,
|
||||
IS_PUBLISH: state
|
||||
}
|
||||
).then((data) => {
|
||||
this.$message({
|
||||
message: '发布成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
delFujian(item) {
|
||||
this.form.fileIsType = true
|
||||
this.form.COURSEWAREFILES = ''
|
||||
},
|
||||
delFujianTupian(item) {
|
||||
this.form.captureIsType = true
|
||||
this.form.COURSEWARECAPTURE = ''
|
||||
this.form.ccfile = ''
|
||||
this.hideUpload = false
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.hide .el-upload--picture-card {
|
||||
display: none;
|
||||
}
|
||||
div.popContainer {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
background: rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
</style>
|
||||
|
|
@ -0,0 +1,127 @@
|
|||
<template>
|
||||
<el-dialog v-if="visible" :visible.sync="visible" :title="title" width="600px" @close="close">
|
||||
<el-form v-loading="loading" ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item label="行业类型" prop="INDUSTRY_TYPE_ARR">
|
||||
<cascader-dict
|
||||
ref="refIndustryType"
|
||||
v-model = "form.INDUSTRY_TYPE_ARR"
|
||||
:form.sync="form"
|
||||
:dict-id = "dictId"
|
||||
@cascaderNames="cascaderNames"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="标准名称" prop="CHECK_STANDARD_NAME">
|
||||
<el-input id="CHECK_STANDARD_NAME" ref="CHECK_STANDARD_NAME" v-model="form.CHECK_STANDARD_NAME" maxlength="255" placeholder="这里输入标准名称..." title="标准名称"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="COMMON_STATUS">
|
||||
<el-select v-model="form.COMMON_STATUS" placeholder="状态" style="width: 100px" class="filter-item">
|
||||
<el-option v-for="item in commonStatusList" :key="item.id" :label="item.name" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="close">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import CascaderDict from '../../../../components/CascaderDict'
|
||||
export default {
|
||||
components: { CascaderDict },
|
||||
directives: { waves },
|
||||
props: {
|
||||
title: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
dialogType: 'add',
|
||||
dictId: 'f2598ba72e864eadabf0ca4b664d26b9', // 行业类型
|
||||
commonStatusList: [
|
||||
{ id: 1, name: '有效' },
|
||||
{ id: 2, name: '停用' }
|
||||
],
|
||||
form: {
|
||||
COMMON_ID: '',
|
||||
INDUSTRY_TYPE_ARR: [],
|
||||
INDUSTRY_TYPE_TREE: '',
|
||||
CHECK_STANDARD_NAME: '',
|
||||
COMMON_STATUS: ''
|
||||
},
|
||||
rules: {
|
||||
INDUSTRY_TYPE_ARR: [{ required: true, message: '行业类型不能为空', trigger: 'blur' }],
|
||||
CHECK_STANDARD_NAME: [{ required: true, message: '标准名称不能为空', trigger: 'blur' }],
|
||||
COMMON_STATUS: [{ required: true, message: '状态不能为空', trigger: 'blur' }]
|
||||
},
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
corp_info_list: [],
|
||||
risk_unit_list: [],
|
||||
visible: false,
|
||||
info: {}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
if (e) {
|
||||
this.dialogType = 'edit'
|
||||
this.form = e
|
||||
this.$set(this.form, 'INDUSTRY_TYPE_ARR', this.form.INDUSTRY_TYPE_TREE ? this.form.INDUSTRY_TYPE_TREE.split(',') : [])
|
||||
console.log(this.form)
|
||||
}
|
||||
},
|
||||
cascaderNames(e) {
|
||||
this.form.INDUSTRY_TYPE_NAMES = e
|
||||
},
|
||||
confirm() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
this.loading = true
|
||||
this.form.INDUSTRY_TYPE = this.form.INDUSTRY_TYPE_ARR[this.form.INDUSTRY_TYPE_ARR.length - 1]
|
||||
this.form.INDUSTRY_TYPE_TREE = this.form.INDUSTRY_TYPE_ARR.join(',')
|
||||
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/' + this.dialogType,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.loading = false
|
||||
this.close()
|
||||
this.$emit('beforeClose', '')
|
||||
this.$message.success('操作成功')
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
resetForm() {
|
||||
// this.$refs.refIndustryType.clearNodes()
|
||||
this.form = {
|
||||
COMMON_ID: '',
|
||||
INDUSTRY_TYPE_ARR: [],
|
||||
INDUSTRY_TYPE_TREE: '',
|
||||
CHECK_STANDARD_NAME: '',
|
||||
COMMON_STATUS: ''
|
||||
}
|
||||
},
|
||||
close() {
|
||||
this.resetForm()
|
||||
this.visible = false
|
||||
},
|
||||
getDicTree() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,115 @@
|
|||
<template>
|
||||
<el-dialog :visible.sync="visible" :title="title" width="95%">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<td class="tbg">行业类型</td>
|
||||
<td colspan="3">{{ form.INDUSTRY_TYPE_NAMES.replaceAll(',', ' / ') }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">标准名称</td>
|
||||
<td colspan="3">{{ form.CHECK_STANDARD_NAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">状态</td>
|
||||
<td colspan="3">{{ form.COMMON_STATUS ? (form.COMMON_STATUS === 1 ? '有效' : '停用') : '' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">标准明细</td>
|
||||
<td colspan="3" style="padding:0;">
|
||||
<table style="padding:0;width:100%" class="table-vi">
|
||||
<tr>
|
||||
<th class="title">检查类别</th>
|
||||
<th class="title">检查类别</th>
|
||||
<th class="title">检查项目</th>
|
||||
<th class="title">检查内容</th>
|
||||
<th class="title">检查标准</th>
|
||||
<th class="title">参考依据</th>
|
||||
<th class="title">检查合格项</th>
|
||||
<th class="title">检查不合格项</th>
|
||||
<th class="title">操作类型</th>
|
||||
</tr>
|
||||
<tbody v-if="form.itemList.length > 0">
|
||||
<tr v-for="(item,index) in form.itemList" :key="index">
|
||||
<td class="title">{{ index + 1 }}</td>
|
||||
<td class="title">{{ item.CHECK_CATEGORY_NAME }}</td>
|
||||
<td class="title">{{ item.CHECK_ITEM_NAME }}</td>
|
||||
<td class="title">{{ item.CHECK_CONTENT }}</td>
|
||||
<td class="title">{{ item.CHECK_STANDARD }}</td>
|
||||
<td class="title">{{ item.REFERENCE_BASIS }}</td>
|
||||
<td class="title">{{ item.CHECK_QUALIFIED }}</td>
|
||||
<td class="title">{{ item.CHECK_UNQUALIFIED }}</td>
|
||||
<td class="title">{{ item.OPERATION_TYPE ? (item.OPERATION_TYPE === 1 ? '选择' : '填写') : '' }}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tbody v-else>
|
||||
<tr>
|
||||
<td colspan="9" style="text-align: center">暂无数据</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="close">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import waves from '@/directive/waves'
|
||||
import { requestFN } from '@/utils/request'
|
||||
export default {
|
||||
directives: { waves },
|
||||
props: {
|
||||
title: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: true,
|
||||
visible: false,
|
||||
form: {
|
||||
COMMON_ID: '',
|
||||
INDUSTRY_TYPE_NAMES: '',
|
||||
CHECK_STANDARD_NAME: '',
|
||||
COMMON_STATUS: '',
|
||||
itemList: []
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
if (e) {
|
||||
this.getData(e)
|
||||
}
|
||||
},
|
||||
getData(COMMON_ID) {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/getInfo',
|
||||
{ COMMON_ID: COMMON_ID }
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.form = data.pd
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
close() {
|
||||
this.visible = false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.tbg{
|
||||
width: 110px !important;
|
||||
}
|
||||
</style>
|
||||
|
|
@ -0,0 +1,264 @@
|
|||
<template>
|
||||
<el-dialog v-if="visible" :visible.sync="visible" :title="title" width="600px" @close="close">
|
||||
<el-form v-loading="loading" ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item label="标准类别" prop="CHECK_CATEGORY">
|
||||
<div class="uo-flex">
|
||||
<el-select v-if="form.CHECK_CATEGORY_WAY === 'select'" v-model="form.CHECK_CATEGORY" placeholder="选择标准类别..." clearable style="width: 100%" class="filter-item" @change="changeCategory">
|
||||
<el-option v-for="item in checkCategoryList" :key="item.DICTIONARY_ID" :label="item.DICTIONARY_NAME" :value="item.DICTIONARY_ID" />
|
||||
</el-select>
|
||||
<el-input v-if="form.CHECK_CATEGORY_WAY === 'value'" id="leaPostVal" :disabled="form.CHECK_CATEGORY_WAY === 'select'" v-model="form.CHECK_CATEGORY" placeholder="这里输入新的标准类别..." />
|
||||
<el-button
|
||||
type="success"
|
||||
style="margin-left: 5px;height: 32px;"
|
||||
size="mini"
|
||||
@click="changeEditWay">{{ form.CHECK_CATEGORY_WAY === 'select' ? '输入' : '选择' }}</el-button>
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item label="标准项目" prop="CHECK_ITEM">
|
||||
<div class="uo-flex">
|
||||
<el-select v-if="form.CHECK_ITEM_WAY === 'select'" v-model="form.CHECK_ITEM" placeholder="选择标准项目..." clearable style="width: 100%" class="filter-item">
|
||||
<el-option v-for="item in checkItemList" :key="item.DICTIONARY_ID" :label="item.DICTIONARY_NAME" :value="item.DICTIONARY_ID" />
|
||||
</el-select>
|
||||
<el-input v-if="form.CHECK_ITEM_WAY === 'value'" id="leaPostVal" :disabled="form.CHECK_ITEM_WAY === 'select'" v-model="form.CHECK_ITEM" placeholder="这里输入新的标准项目..." />
|
||||
<el-button
|
||||
:disabled="form.CHECK_CATEGORY_WAY === 'value'"
|
||||
type="success"
|
||||
style="margin-left: 5px;height: 32px;"
|
||||
size="mini"
|
||||
@click="changeEditItemWay">{{ form.CHECK_ITEM_WAY === 'select' ? '输入' : '选择' }}</el-button>
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item label="检查内容" prop="CHECK_CONTENT">
|
||||
<el-input v-model="form.CHECK_CONTENT" :autosize="{ minRows: 1}" type="textarea" maxlength="500" placeholder="输入检查内容..." />
|
||||
</el-form-item>
|
||||
<el-form-item label="检查标准" prop="CHECK_STANDARD">
|
||||
<el-input v-model="form.CHECK_STANDARD" :autosize="{ minRows: 1}" type="textarea" maxlength="500" placeholder="输入检查标准..." />
|
||||
</el-form-item>
|
||||
<el-form-item label="参考依据" prop="REFERENCE_BASIS">
|
||||
<el-input v-model="form.REFERENCE_BASIS" :autosize="{ minRows: 1}" type="textarea" maxlength="500" placeholder="输入参考依据..." />
|
||||
</el-form-item>
|
||||
<el-form-item label="检查合格项" prop="CHECK_QUALIFIED">
|
||||
<el-input v-model="form.CHECK_QUALIFIED" :autosize="{ minRows: 1}" type="textarea" maxlength="500" placeholder="输入检查合格项..." />
|
||||
</el-form-item>
|
||||
<el-form-item label="检查不合格项" prop="CHECK_UNQUALIFIED">
|
||||
<el-input v-model="form.CHECK_UNQUALIFIED" :autosize="{ minRows: 1}" type="textarea" maxlength="500" placeholder="输入检查不合格项..." />
|
||||
</el-form-item>
|
||||
<el-form-item label="操作类型" prop="OPERATION_TYPE">
|
||||
<el-select v-model="form.OPERATION_TYPE" placeholder="选择操作类型..." style="width: 100%" class="filter-item">
|
||||
<el-option v-for="item in operationTypeList" :key="item.id" :label="item.name" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="排序" prop="COMMON_ITEM_SORT">
|
||||
<el-input-number :min="1" :precision="0" v-model="form.COMMON_ITEM_SORT" style="width: 100%;" controls-position="right" autocomplete="off" placeholder="这里输入排序..." />
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="COMMON_ITEM_STATUS">
|
||||
<el-select v-model="form.COMMON_ITEM_STATUS" placeholder="状态" style="width: 100px" class="filter-item">
|
||||
<el-option v-for="item in commonItemStatusList" :key="item.id" :label="item.name" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="close">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import CascaderDict from '../../../../components/CascaderDict'
|
||||
export default {
|
||||
components: { CascaderDict },
|
||||
directives: { waves },
|
||||
props: {
|
||||
title: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
dialogType: 'addItem',
|
||||
checkCategoryList: [], // 标准类别
|
||||
checkItemAllList: [], // 标准项目
|
||||
checkItemList: [], // 标准项目
|
||||
operationTypeList: [
|
||||
{ id: 1, name: '选择' },
|
||||
{ id: 2, name: '填写' }
|
||||
],
|
||||
commonItemStatusList: [
|
||||
{ id: 1, name: '有效' },
|
||||
{ id: 2, name: '停用' }
|
||||
],
|
||||
tempData: {
|
||||
CHECK_CATEGORY: '',
|
||||
CHECK_ITEM: ''
|
||||
},
|
||||
form: {
|
||||
COMMON_ITEM_ID: '',
|
||||
COMMON_ID: this.$parent.COMMON_ID,
|
||||
CHECK_CATEGORY_WAY: 'select',
|
||||
CHECK_ITEM_WAY: 'select',
|
||||
CHECK_CATEGORY: '',
|
||||
CHECK_ITEM: '',
|
||||
CHECK_CONTENT: '',
|
||||
CHECK_STANDARD: '',
|
||||
REFERENCE_BASIS: '',
|
||||
CHECK_QUALIFIED: '',
|
||||
CHECK_UNQUALIFIED: '',
|
||||
OPERATION_TYPE: '',
|
||||
COMMON_ITEM_SORT: '',
|
||||
COMMON_ITEM_STATUS: ''
|
||||
},
|
||||
rules: {
|
||||
CHECK_CATEGORY: [{ required: true, message: '标准类别不能为空', trigger: 'blur' }],
|
||||
CHECK_ITEM: [{ required: true, message: '标准项目不能为空', trigger: 'blur' }],
|
||||
CHECK_CONTENT: [{ required: true, message: '检查内容不能为空', trigger: 'blur' }],
|
||||
CHECK_STANDARD: [{ required: true, message: '检查标准不能为空', trigger: 'blur' }],
|
||||
REFERENCE_BASIS: [{ required: true, message: '参考依据不能为空', trigger: 'blur' }],
|
||||
CHECK_QUALIFIED: [{ required: true, message: '检查合格项不能为空', trigger: 'blur' }],
|
||||
CHECK_UNQUALIFIED: [{ required: true, message: '检查不合格项不能为空', trigger: 'blur' }],
|
||||
OPERATION_TYPE: [{ required: true, message: '操作类型不能为空', trigger: 'blur' }],
|
||||
COMMON_ITEM_SORT: [{ required: true, message: '排序不能为空', trigger: 'blur' }],
|
||||
COMMON_ITEM_STATUS: [{ required: true, message: '状态不能为空', trigger: 'blur' }]
|
||||
},
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
corp_info_list: [],
|
||||
risk_unit_list: [],
|
||||
visible: false,
|
||||
info: {}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
this.checkCategoryList = e.checkCategoryList
|
||||
this.checkItemAllList = e.checkItemAllList
|
||||
this.form.COMMON_ID = e.form.COMMON_ID
|
||||
this.form.COMMON_ITEM_SORT = e.form.COMMON_ITEM_SORT
|
||||
if (e.form.COMMON_ITEM_ID) {
|
||||
this.checkItemList = this.checkItemAllList.filter(item => item.PARENT_IDS.includes(e.form.CHECK_CATEGORY))
|
||||
this.$forceUpdate()
|
||||
this.dialogType = 'editItem'
|
||||
this.form = e.form
|
||||
this.tempData.CHECK_CATEGORY = e.form.CHECK_CATEGORY
|
||||
this.tempData.CHECK_ITEM = e.form.CHECK_ITEM
|
||||
this.$set(this.form, 'CHECK_CATEGORY_WAY', 'select')
|
||||
this.$set(this.form, 'CHECK_ITEM_WAY', 'select')
|
||||
}
|
||||
console.log(this.form)
|
||||
},
|
||||
changeEditWay() {
|
||||
this.form.CHECK_CATEGORY_WAY = this.form.CHECK_CATEGORY_WAY === 'select' ? 'value' : 'select'
|
||||
this.form.CHECK_ITEM_WAY = this.form.CHECK_CATEGORY_WAY
|
||||
if (this.form.CHECK_CATEGORY_WAY === 'select') {
|
||||
this.form.CHECK_CATEGORY = this.tempData.CHECK_CATEGORY
|
||||
this.form.CHECK_ITEM = this.tempData.CHECK_ITEM
|
||||
} else {
|
||||
this.form.CHECK_CATEGORY = ''
|
||||
this.form.CHECK_ITEM = ''
|
||||
}
|
||||
},
|
||||
changeEditItemWay() {
|
||||
this.form.CHECK_ITEM_WAY = this.form.CHECK_ITEM_WAY === 'select' ? 'value' : 'select'
|
||||
if (this.form.CHECK_ITEM_WAY === 'select') {
|
||||
this.form.CHECK_ITEM = this.tempData.CHECK_ITEM
|
||||
} else {
|
||||
this.form.CHECK_ITEM = ''
|
||||
}
|
||||
},
|
||||
changeCategory() {
|
||||
this.form.CHECK_ITEM = ''
|
||||
this.checkItemList = []
|
||||
this.checkItemAllList.forEach((item) => {
|
||||
if (item.PARENT_IDS.includes(this.form.CHECK_CATEGORY)) {
|
||||
this.checkItemList.push(item)
|
||||
}
|
||||
})
|
||||
this.$forceUpdate()
|
||||
},
|
||||
async confirm() {
|
||||
this.$refs.form.validate(async valid => {
|
||||
if (valid) {
|
||||
if (this.form.CHECK_CATEGORY_WAY === 'value') {
|
||||
const { count } = await requestFN(
|
||||
'/hiddenDangerCheckStandardDictionary/validateExist',
|
||||
{
|
||||
DICTIONARY_NAME: this.form.CHECK_CATEGORY,
|
||||
DICTIONARY_LEVEL: 1
|
||||
}
|
||||
)
|
||||
if (count > 0) {
|
||||
this.$message.warning('新标准类别名称已存在!')
|
||||
return
|
||||
}
|
||||
}
|
||||
if (this.form.CHECK_ITEM_WAY === 'value') {
|
||||
const { count } = await requestFN(
|
||||
'/hiddenDangerCheckStandardDictionary/validateExist',
|
||||
{
|
||||
DICTIONARY_NAME: this.form.CHECK_ITEM,
|
||||
PARENT_ID: this.form.CHECK_CATEGORY,
|
||||
DICTIONARY_LEVEL: 2
|
||||
}
|
||||
)
|
||||
if (count > 0) {
|
||||
this.$message.warning('新标准项目名称已存在!')
|
||||
return
|
||||
}
|
||||
}
|
||||
this.loading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/' + this.dialogType,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.loading = false
|
||||
this.close()
|
||||
this.$emit('beforeClose', '')
|
||||
this.$message.success('操作成功')
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
resetForm() {
|
||||
// this.$refs.refIndustryType.clearNodes()
|
||||
this.form = {
|
||||
COMMON_ITEM_ID: '',
|
||||
COMMON_ID: this.$parent.COMMON_ID,
|
||||
CHECK_CATEGORY: '',
|
||||
CHECK_ITEM: '',
|
||||
CHECK_CONTENT: '',
|
||||
CHECK_STANDARD: '',
|
||||
REFERENCE_BASIS: '',
|
||||
CHECK_QUALIFIED: '',
|
||||
CHECK_UNQUALIFIED: '',
|
||||
OPERATION_TYPE: '',
|
||||
COMMON_ITEM_SORT: '',
|
||||
COMMON_ITEM_STATUS: ''
|
||||
}
|
||||
},
|
||||
close() {
|
||||
this.resetForm()
|
||||
this.visible = false
|
||||
},
|
||||
getDicTree() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.uo-flex {
|
||||
display: flex;
|
||||
}
|
||||
</style>
|
||||
|
||||
|
|
@ -0,0 +1,99 @@
|
|||
<template>
|
||||
<el-dialog :visible.sync="visible" :title="title" width="800px">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<td class="tbg" style="width: 150px">行业类型</td>
|
||||
<td colspan="2">{{ form.CHECK_CATEGORY_NAME }}</td>
|
||||
<td class="tbg">标准项目</td>
|
||||
<td colspan="2">{{ form.CHECK_ITEM_NAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">检查内容</td>
|
||||
<td colspan="5">{{ form.CHECK_CONTENT }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">检查标准</td>
|
||||
<td colspan="5">{{ form.CHECK_STANDARD }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">参考依据</td>
|
||||
<td colspan="5">{{ form.REFERENCE_BASIS }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">检查合格项</td>
|
||||
<td colspan="5">{{ form.CHECK_QUALIFIED }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">检查不合格项</td>
|
||||
<td colspan="5">{{ form.CHECK_UNQUALIFIED }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">操作类型</td>
|
||||
<td>{{ form.OPERATION_TYPE ? (form.OPERATION_TYPE === 1 ? '选择' : '填写') : '' }}</td>
|
||||
<td class="tbg">状态</td>
|
||||
<td>{{ form.COMMON_ITEM_STATUS ? (form.COMMON_ITEM_STATUS === 1 ? '有效' : '停用') : '' }}</td>
|
||||
<td class="tbg">排序</td>
|
||||
<td>{{ form.COMMON_ITEM_SORT }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="close">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import waves from '@/directive/waves'
|
||||
export default {
|
||||
components: { Pagination },
|
||||
directives: { waves },
|
||||
props: {
|
||||
title: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: true,
|
||||
visible: false,
|
||||
form: {
|
||||
COMMON_ITEM_ID: '',
|
||||
COMMON_ID: '',
|
||||
CHECK_CATEGORY: '',
|
||||
CHECK_CATEGORY_NAME: '',
|
||||
CHECK_ITEM: '',
|
||||
CHECK_ITEM_NAME: '',
|
||||
CHECK_CONTENT: '',
|
||||
CHECK_STANDARD: '',
|
||||
REFERENCE_BASIS: '',
|
||||
CHECK_QUALIFIED: '',
|
||||
CHECK_UNQUALIFIED: '',
|
||||
OPERATION_TYPE: '',
|
||||
COMMON_ITEM_SORT: '',
|
||||
COMMON_ITEM_STATUS: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
if (e) {
|
||||
this.form = e
|
||||
}
|
||||
},
|
||||
close() {
|
||||
this.visible = false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.tbg{
|
||||
width: 110px !important;
|
||||
}
|
||||
</style>
|
||||
|
|
@ -0,0 +1,327 @@
|
|||
<template>
|
||||
<div>
|
||||
<div class="app-container">
|
||||
<div class="filter-container">
|
||||
<el-row :gutter="20">
|
||||
<el-form label-width="80px">
|
||||
<el-col :span="4">
|
||||
<el-form-item label="标准类别">
|
||||
<el-select v-model="searchForm.CHECK_CATEGORY" placeholder="标准类别" clearable style="width: 150px" class="filter-item">
|
||||
<el-option v-for="item in checkCategoryList" :key="item.DICTIONARY_ID" :label="item.DICTIONARY_NAME" :value="item.DICTIONARY_ID" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="4">
|
||||
<el-form-item label="标准项目">
|
||||
<el-select v-model="searchForm.CHECK_ITEM" placeholder="标准项目" clearable style="width: 200px" class="filter-item">
|
||||
<el-option v-for="item in checkItemList" :key="item.DICTIONARY_ID" :label="item.DICTIONARY_NAME" :value="item.DICTIONARY_ID" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="检查内容">
|
||||
<el-input v-model="searchForm.CHECK_CONTENT" placeholder="搜索检查内容..." class="filter-item" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6" >
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh-left" @click="resetting">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
</el-row>
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row
|
||||
>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="CHECK_CATEGORY_NAME" label="检查类别" width="100" />
|
||||
<el-table-column prop="CHECK_ITEM_NAME" label="检查项目" width="150" />
|
||||
<el-table-column prop="CHECK_CONTENT" label="检查内容" />
|
||||
<el-table-column prop="CHECK_STANDARD" label="检查标准" />
|
||||
<el-table-column prop="REFERENCE_BASIS" label="参考依据" />
|
||||
<el-table-column prop="CHECK_QUALIFIED" label="检查合格项" />
|
||||
<el-table-column prop="CHECK_UNQUALIFIED" label="检查不合格项" />
|
||||
<el-table-column prop="OPERATION_TYPE" label="操作类型" width="70" align="center" >
|
||||
<template slot-scope="{row}">
|
||||
{{ row.OPERATION_TYPE ? (row.OPERATION_TYPE === 1 ? '选择' : '填写') : '' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="COMMON_ITEM_STATUS" label="状态" width="60" align="center" >
|
||||
<template slot-scope="{row}">
|
||||
{{ row.COMMON_ITEM_STATUS ? (row.COMMON_ITEM_STATUS === 1 ? '有效' : '停用') : '' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" width="300">
|
||||
<template slot-scope="{row}">
|
||||
<el-row :gutter="20">
|
||||
<el-button type="success" icon="el-icon-view" size="mini" @click="getInfo(row)">查看</el-button>
|
||||
<el-button v-show="edit" :disabled="row.COUNT_CUSTOM !== 0" type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row)">编辑</el-button>
|
||||
<el-button v-show="del" :disabled="row.COUNT_CUSTOM !== 0" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.COMMON_ITEM_ID)">删除</el-button>
|
||||
</el-row>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button v-show="add" type="primary" icon="el-icon-plus" @click="handleAdd">新建</el-button>
|
||||
<el-button v-show="false" type="danger" icon="el-icon-delete" plain @click="batchDel">删除</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
<item-edit ref="edit" :title="title" href="edit" @beforeClose="refreshDict"/>
|
||||
<item-info ref="info" :title="title"/>
|
||||
</div>
|
||||
<div class="ui-height" />
|
||||
<div class="ui-foot">
|
||||
<el-button plain type="info" @click="goBack">返 回</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import ItemEdit from './itemEdit.vue'
|
||||
import ItemInfo from './itemInfo.vue'
|
||||
export default {
|
||||
components: { Pagination, ItemEdit, ItemInfo },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
varList: [],
|
||||
title: '新增',
|
||||
checkCategoryAllList: [], // 标准类别
|
||||
checkCategoryList: [], // 标准类别
|
||||
checkItemAllList: [], // 标准项目
|
||||
checkItemList: [], // 标准项目
|
||||
commonStatusList: [
|
||||
{ id: 1, name: '有效' },
|
||||
{ id: 2, name: '停用' }
|
||||
],
|
||||
searchForm: {
|
||||
CHECK_CATEGORY: '',
|
||||
CHECK_ITEM: '',
|
||||
CHECK_CONTENT: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
'searchForm.CHECK_CATEGORY': {
|
||||
handler() {
|
||||
this.changeCategory(this.searchForm.CHECK_CATEGORY)
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getDictCheckCategory()
|
||||
this.getDictCheckItem()
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.COMMON_ITEM_ID
|
||||
},
|
||||
changeCategory(CHECK_CATEGORY) {
|
||||
this.searchForm.CHECK_ITEM = ''
|
||||
this.checkItemList = []
|
||||
this.checkItemAllList.forEach((item) => {
|
||||
if (item.PARENT_IDS.includes(CHECK_CATEGORY)) {
|
||||
this.checkItemList.push(item)
|
||||
}
|
||||
})
|
||||
this.$forceUpdate()
|
||||
},
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
resetting() {
|
||||
this.searchForm = {
|
||||
CHECK_CATEGORY: '',
|
||||
CHECK_ITEM: '',
|
||||
CHECK_CONTENT: ''
|
||||
}
|
||||
this.getList()
|
||||
},
|
||||
refreshDict() {
|
||||
this.getDictCheckCategory()
|
||||
this.getDictCheckItem()
|
||||
this.getList()
|
||||
},
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/pageItem?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
COMMON_ID: this.$parent.COMMON_ID,
|
||||
CHECK_CATEGORY: this.searchForm.CHECK_CATEGORY,
|
||||
CHECK_ITEM: this.searchForm.CHECK_ITEM,
|
||||
CHECK_CONTENT: this.searchForm.CHECK_CONTENT
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
handleAdd() {
|
||||
const data = {}
|
||||
data.form = JSON.parse(JSON.stringify({ COMMON_ID: this.$parent.COMMON_ID, COMMON_ITEM_SORT: this.total + 1 }))
|
||||
data.checkCategoryList = this.checkCategoryList
|
||||
data.checkItemAllList = this.checkItemAllList
|
||||
this.$refs.edit.init(data)
|
||||
this.title = '新增'
|
||||
},
|
||||
handleEdit(row) {
|
||||
const data = {}
|
||||
data.form = JSON.parse(JSON.stringify(row))
|
||||
data.checkCategoryList = this.checkCategoryList
|
||||
data.checkItemAllList = this.checkItemAllList
|
||||
this.$refs.edit.init(data)
|
||||
this.title = '编辑'
|
||||
},
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/deleteItem',
|
||||
{ COMMON_ITEM_ID: id }
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
batchDel() {
|
||||
const _selectData = this.$refs.multipleTable.selection
|
||||
if (_selectData == null || _selectData.length == 0) {
|
||||
this.$message({
|
||||
message: '请选中要删除的项...',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const ids = _selectData.map((item, index) => {
|
||||
return item.COMMON_ITEM_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/deleteAll',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'hiddenDangerCheckStandardCommon:add,hiddenDangerCheckStandardCommon:del,hiddenDangerCheckStandardCommon:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.hiddenDangerCheckStandardCommonfhadminadd // 新增权限
|
||||
this.del = data.hiddenDangerCheckStandardCommonfhadmindel // 删除权限
|
||||
this.edit = data.hiddenDangerCheckStandardCommonfhadminedit // 修改权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
async getDictCheckCategory() {
|
||||
const { list } = await requestFN(
|
||||
'/hiddenDangerCheckStandardDictionary/listSelect',
|
||||
{
|
||||
COMMON_ID: this.COMMON_ID, // 标准ID
|
||||
DICTIONARY_LEVEL: 1 // 标准类别
|
||||
}
|
||||
)
|
||||
this.checkCategoryList = list
|
||||
},
|
||||
async getDictCheckItem() {
|
||||
const { list } = await requestFN(
|
||||
'/hiddenDangerCheckStandardDictionary/listSelect',
|
||||
{
|
||||
COMMON_ID: this.COMMON_ID, // 标准ID
|
||||
DICTIONARY_LEVEL: 2 // 标准类别
|
||||
}
|
||||
)
|
||||
this.checkItemAllList = list
|
||||
},
|
||||
getInfo(e) {
|
||||
this.$refs.info.init(e)
|
||||
this.title = '详情'
|
||||
},
|
||||
getResult(e) {
|
||||
this.getList()
|
||||
},
|
||||
goBack() {
|
||||
this.$parent.activeName = 'List'
|
||||
this.$parent.COMMON_ID = ''
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,333 @@
|
|||
<template>
|
||||
<div class="app-warp">
|
||||
<div class="app-structure">
|
||||
<div class="app-search">
|
||||
<el-form label-width="80px">
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="行业类型">
|
||||
<cascader-dict
|
||||
v-model = "searchForm.INDUSTRY_TYPE_ARR"
|
||||
:form.sync="searchForm"
|
||||
:dict-id = "dictId"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="标准名称">
|
||||
<el-input v-model="searchForm.CHECK_STANDARD_NAME" placeholder="搜索标准名称..." class="filter-item" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-show="!searchFromCollapse" :span="6">
|
||||
<el-form-item label="导入时间">
|
||||
<el-date-picker
|
||||
v-model="searchForm.CREATE_TIME"
|
||||
type="daterange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
format="yyyy-MM-dd"
|
||||
value-format="yyyy-MM-dd"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-show="!searchFromCollapse" :span="6">
|
||||
<el-form-item label="状态">
|
||||
<el-select v-model="searchForm.COMMON_STATUS" placeholder="状态" clearable style="width: 100%" class="filter-item">
|
||||
<el-option v-for="item in commonStatusList" :key="item.id" :label="item.name" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="!searchFromCollapse ? 24 : 12" >
|
||||
<el-form-item style="text-align: right">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh-left" @click="resetting">
|
||||
重置
|
||||
</el-button>
|
||||
<el-button type="text" @click="searchFromCollapse = !searchFromCollapse">{{ searchFromCollapse ? '展开' : '合并' }} <i :class="searchFromCollapse ? 'el-icon-arrow-down' : 'el-icon-arrow-up'"/></el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
</div>
|
||||
<div class="app-tools">
|
||||
<div class="app-function">
|
||||
<el-button v-show="add" type="primary" icon="el-icon-plus" size="mini" @click="handleAdd">新增</el-button>
|
||||
<el-button v-show="false" type="danger" icon="el-icon-delete" size="mini" plain @click="batchDel">删除</el-button>
|
||||
<el-button type="primary" icon="el-icon-document-add" size="mini" @click="importExcel('import')">
|
||||
导入标准表
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="app-container">
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="INDUSTRY_TYPE_NAMES" label="行业类型" >
|
||||
<template slot-scope="{row}">
|
||||
{{ row.INDUSTRY_TYPE_NAMES.replaceAll(',', ' / ') }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="CHECK_STANDARD_NAME" label="隐患排查标准名称" />
|
||||
<el-table-column prop="CREATE_TIME" label="导入时间" width="140" align="center" />
|
||||
<el-table-column prop="COMMON_STATUS" label="状态" width="60" align="center" >
|
||||
<template slot-scope="{row}">
|
||||
{{ row.COMMON_STATUS ? (row.COMMON_STATUS === 1 ? '有效' : '停用') : '' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" width="320">
|
||||
<template slot-scope="{row}">
|
||||
<el-row :gutter="20" style="margin-bottom: 5px">
|
||||
<el-button type="success" icon="el-icon-view" size="mini" @click="getInfo(row)">查看</el-button>
|
||||
<el-button v-show="edit" type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row)">编辑</el-button>
|
||||
<el-button v-show="del" :disabled="row.COUNT_CUSTOM !== 0" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.COMMON_ID)">删除</el-button>
|
||||
</el-row>
|
||||
<el-row :gutter="20">
|
||||
<el-button type="success" icon="el-icon-tickets" size="mini" @click="getCommonItem(row)">清单详细</el-button>
|
||||
<el-button type="primary" icon="el-icon-refresh" size="mini" @click="importExcel('reimport', row)">重新导入</el-button>
|
||||
<el-button type="primary" icon="el-icon-circle-plus-outline" size="mini" @click="importExcel('appendImport', row)">追加导入</el-button>
|
||||
</el-row>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div />
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<edit ref="edit" :title="title" href="edit" @beforeClose="getList"/>
|
||||
<info ref="info" :title="title"/>
|
||||
<update-file ref="updateFile" @logical-end="getResult"/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import edit from './edit.vue'
|
||||
import info from './info.vue'
|
||||
import Info from '../../../onlinexxks/stage/exam/components/info.vue'
|
||||
import updateFile from './updateFile.vue'
|
||||
import CascaderDict from '../../../../components/CascaderDict'
|
||||
export default {
|
||||
components: { updateFile, Info, edit, Pagination, info, CascaderDict },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
varList: [],
|
||||
title: '新增',
|
||||
dictId: 'f2598ba72e864eadabf0ca4b664d26b9', // 行业类型
|
||||
commonStatusList: [
|
||||
{ id: 1, name: '有效' },
|
||||
{ id: 2, name: '停用' }
|
||||
],
|
||||
searchFromCollapse: true,
|
||||
searchForm: {
|
||||
INDUSTRY_TYPE_ARR: [],
|
||||
INDUSTRY_TYPE_TREE: '',
|
||||
CHECK_STANDARD_NAME: '',
|
||||
COMMON_STATUS: '',
|
||||
CREATE_TIME: []
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.getDict()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.COMMON_ID
|
||||
},
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
resetting() {
|
||||
this.searchForm = {
|
||||
INDUSTRY_TYPE_ARR: [],
|
||||
INDUSTRY_TYPE_TREE: '',
|
||||
CHECK_STANDARD_NAME: '',
|
||||
COMMON_STATUS: '',
|
||||
CREATE_TIME: []
|
||||
}
|
||||
this.getList()
|
||||
},
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
this.searchForm.INDUSTRY_TYPE_TREE = this.searchForm.INDUSTRY_TYPE_ARR.join(',')
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
INDUSTRY_TYPE_TREE: this.searchForm.INDUSTRY_TYPE_TREE,
|
||||
CHECK_STANDARD_NAME: this.searchForm.CHECK_STANDARD_NAME,
|
||||
COMMON_STATUS: this.searchForm.COMMON_STATUS,
|
||||
CREATE_TIME_BEGIN: this.searchForm.CREATE_TIME[0] || '',
|
||||
CREATE_TIME_END: this.searchForm.CREATE_TIME[1] || ''
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
handleAdd() {
|
||||
this.$refs.edit.init()
|
||||
this.title = '新增'
|
||||
},
|
||||
handleEdit(row) {
|
||||
this.$refs.edit.init(JSON.parse(JSON.stringify(row)))
|
||||
this.title = '编辑'
|
||||
},
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/delete',
|
||||
{ COMMON_ID: id }
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
batchDel() {
|
||||
const _selectData = this.$refs.multipleTable.selection
|
||||
if (_selectData == null || _selectData.length == 0) {
|
||||
this.$message({
|
||||
message: '请选中要删除的项...',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const ids = _selectData.map((item, index) => {
|
||||
return item.COMMON_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardCommon/deleteAll',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'hiddenDangerCheckStandardCommon:add,hiddenDangerCheckStandardCommon:del,hiddenDangerCheckStandardCommon:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.hiddenDangerCheckStandardCommonfhadminadd // 新增权限
|
||||
this.del = data.hiddenDangerCheckStandardCommonfhadmindel // 删除权限
|
||||
this.edit = data.hiddenDangerCheckStandardCommonfhadminedit // 修改权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
getDict: function() {
|
||||
requestFN(
|
||||
'dictionaries/getLevels', { DICTIONARIES_ID: 'f2598ba72e864eadabf0ca4b664d26b9' }
|
||||
).then((data) => {
|
||||
this.industry_type_list = data.list
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
requestFN(
|
||||
'/dictionaries/getLevels', { DICTIONARIES_ID: 'b4a7325f96af40808ec64c85c162933d' }
|
||||
).then((data) => {
|
||||
this.hidden_types_list = data.list
|
||||
}).catch((e) => { console.log(e) })
|
||||
},
|
||||
getInfo(row) {
|
||||
this.$refs.info.init(row.COMMON_ID)
|
||||
this.title = '详情'
|
||||
},
|
||||
getCommonItem(row) {
|
||||
this.$parent.activeName = 'ItemList'
|
||||
this.$parent.COMMON_ID = row.COMMON_ID
|
||||
},
|
||||
importExcel(importType, row) {
|
||||
const data = {}
|
||||
if (importType !== 'import') {
|
||||
data.form = JSON.parse(JSON.stringify(row))
|
||||
}
|
||||
data.importType = importType
|
||||
this.$refs.updateFile.init(data)
|
||||
},
|
||||
getResult(e) {
|
||||
this.getList()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style lang="sass" scoped>
|
||||
.filter-container
|
||||
position: relative
|
||||
.filter-flot
|
||||
position: absolute
|
||||
padding-bottom: 33px
|
||||
right: 0
|
||||
bottom: 0
|
||||
</style>
|
||||
|
|
@ -0,0 +1,192 @@
|
|||
<template>
|
||||
<el-dialog v-loading="loading" v-if="visible" :visible.sync="visible" :title="title" width="600" @close="goBack">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="150px">
|
||||
<el-form-item label="行业类型" prop="INDUSTRY_TYPE_ARR">
|
||||
<cascader-dict
|
||||
v-model = "form.INDUSTRY_TYPE_ARR"
|
||||
:form.sync="form"
|
||||
:dict-id = "dictId"
|
||||
:disabled="importType !== 'import'"
|
||||
@cascaderNames="cascaderNames"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="标准名称" prop="CHECK_STANDARD_NAME">
|
||||
<el-input
|
||||
id="CHECK_STANDARD_NAME"
|
||||
ref="CHECK_STANDARD_NAME"
|
||||
v-model="form.CHECK_STANDARD_NAME"
|
||||
:disabled="importType !== 'import'"
|
||||
maxlength="255"
|
||||
placeholder="这里输入标准名称..."
|
||||
title="标准名称"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="导入标准Excel:" prop="excelFileList">
|
||||
<el-upload
|
||||
ref="fileRef"
|
||||
:on-change="uploadChange"
|
||||
:before-remove="uploadBeforeRemove"
|
||||
:on-remove="uploadRemoved"
|
||||
:auto-upload="false"
|
||||
:file-list="form.excelFileList"
|
||||
:limit="1"
|
||||
class="avatar-uploader"
|
||||
action="#"
|
||||
accept=".xls">
|
||||
<el-button size="small" type="primary">点击上传</el-button>
|
||||
<div slot="tip" class="el-upload__tip">只能上传xls文件</div>
|
||||
</el-upload>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="downloadTemplate">下载模板</el-button>
|
||||
<el-button @click="goBack">取 消</el-button>
|
||||
<el-button type="primary" @click="save">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
|
||||
import Pagination from '@/components/Pagination'
|
||||
import waves from '@/directive/waves'
|
||||
import { upload } from '@/utils/upload'
|
||||
import uploadFile from '../../../../components/UploadFile/index.vue'
|
||||
import CascaderDict from '../../../../components/CascaderDict'
|
||||
|
||||
export default {
|
||||
components: { Pagination, uploadFile, CascaderDict },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
config: config,
|
||||
visible: false,
|
||||
importType: '',
|
||||
title: '',
|
||||
dictId: 'f2598ba72e864eadabf0ca4b664d26b9', // 行业类型
|
||||
form: {
|
||||
INDUSTRY_TYPE_ARR: [],
|
||||
INDUSTRY_TYPE: '',
|
||||
INDUSTRY_TYPE_TREE: '',
|
||||
INDUSTRY_TYPE_NAMES: '',
|
||||
CHECK_STANDARD_NAME: '',
|
||||
excelFileList: []
|
||||
},
|
||||
rules: {
|
||||
INDUSTRY_TYPE_ARR: [{ required: true, message: '行业类型不能为空', trigger: 'blur' }],
|
||||
CHECK_STANDARD_NAME: [{ required: true, message: '标准名称不能为空', trigger: 'blur' }],
|
||||
excelFileList: [{ required: true, message: '导入文件不能为空', trigger: 'blur' }]
|
||||
},
|
||||
loading: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
this.importType = e.importType
|
||||
switch (e.importType) {
|
||||
case 'reimport':
|
||||
this.title = '重新导入'
|
||||
break
|
||||
case 'appendImport':
|
||||
this.title = '追加导入'
|
||||
break
|
||||
default:
|
||||
this.title = '导入标准表'
|
||||
break
|
||||
}
|
||||
if (e.importType !== 'import') {
|
||||
this.form = e.form
|
||||
this.$set(this.form, 'INDUSTRY_TYPE_ARR', this.form.INDUSTRY_TYPE_TREE ? this.form.INDUSTRY_TYPE_TREE.split(',') : [])
|
||||
this.$set(this.form, 'excelFileList', [])
|
||||
}
|
||||
},
|
||||
goBack() {
|
||||
this.resetForm()
|
||||
this.visible = false
|
||||
},
|
||||
cascaderNames(e) {
|
||||
this.form.INDUSTRY_TYPE_NAMES = e
|
||||
},
|
||||
/** 上传组件 Begin */
|
||||
uploadChange(file, fileList) {
|
||||
const types = ['application/vnd.ms-excel']
|
||||
const isImage = types.includes(file.raw.type)
|
||||
if (!isImage) {
|
||||
this.$message.error('上传文件只能是 XLS 格式!')
|
||||
fileList.pop()
|
||||
} else {
|
||||
this.form.excelFileList = fileList
|
||||
}
|
||||
},
|
||||
uploadBeforeRemove(file, fileList) {
|
||||
return this.$confirm(`确定移除 ${file.name}?`)
|
||||
},
|
||||
uploadRemoved(file, fileList) {
|
||||
this.form.excelFileList = fileList
|
||||
},
|
||||
save() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
const loading = this.$loading({
|
||||
lock: true,
|
||||
text: '上传中...',
|
||||
spinner: 'el-icon-loading',
|
||||
background: 'rgba(0, 0, 0, 0.7)'
|
||||
})
|
||||
this.form.INDUSTRY_TYPE = this.form.INDUSTRY_TYPE_ARR[this.form.INDUSTRY_TYPE_ARR.length - 1]
|
||||
this.form.INDUSTRY_TYPE_TREE = this.form.INDUSTRY_TYPE_ARR.join(',')
|
||||
const formData = new FormData()
|
||||
Object.keys(this.form).map(key => {
|
||||
formData.append(key, this.form[key])
|
||||
})
|
||||
formData.append('importType', this.importType)
|
||||
formData.delete('INDUSTRY_TYPE_ARR')
|
||||
formData.delete('excelFileList')
|
||||
for (let i = 0; i < this.form.excelFileList.length; i++) {
|
||||
if (this.form.excelFileList[i].raw) {
|
||||
formData.append('FILE', this.form.excelFileList[i].raw)
|
||||
}
|
||||
}
|
||||
upload(
|
||||
'/hiddenDangerCheckStandardCommon/importExcel',
|
||||
formData
|
||||
).then((data) => {
|
||||
loading.close()
|
||||
if (data.resultStr) {
|
||||
this.$message({
|
||||
dangerouslyUseHTMLString: true,
|
||||
message: data.resultStr,
|
||||
type: data.resultType,
|
||||
showClose: true,
|
||||
duration: 5 * 1000
|
||||
})
|
||||
}
|
||||
this.resetForm()
|
||||
this.visible = false
|
||||
this.$emit('logical-end', { result: 'OK' })
|
||||
}).catch((e) => {
|
||||
loading.close()
|
||||
console.log(e)
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
resetForm() {
|
||||
this.$refs.fileRef.clearFiles()
|
||||
this.form = {
|
||||
INDUSTRY_TYPE_ARR: [],
|
||||
INDUSTRY_TYPE: '',
|
||||
INDUSTRY_TYPE_TREE: '',
|
||||
INDUSTRY_TYPE_NAMES: '',
|
||||
CHECK_STANDARD_NAME: '',
|
||||
excelFileList: []
|
||||
}
|
||||
},
|
||||
downloadTemplate() {
|
||||
window.open(config.templatefileUrl + '/templateAdmin/hiddenDangerCheckStandardTemplate.xls')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
<template>
|
||||
<div>
|
||||
<List v-show="activeName==='List'" ref="list" />
|
||||
<ItemList v-if="activeName === 'ItemList'"/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import List from './components/list.vue'
|
||||
import ItemList from './components/itemList.vue'
|
||||
export default {
|
||||
components: { List, ItemList },
|
||||
data() {
|
||||
return {
|
||||
activeName: 'List',
|
||||
COMMON_ID: ''
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,125 @@
|
|||
<template>
|
||||
<el-dialog v-if="visible" :visible.sync="visible" :title="title" width="600px" @close="close">
|
||||
<el-form v-loading="loading" ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item v-if="form.DICTIONARY_LEVEL === 2" label="所属标准类别" prop="PARENT_NAME">
|
||||
<el-input id="PARENT_NAME" ref="PARENT_NAME" v-model="form.PARENT_NAME" disabled maxlength="255" placeholder="这里输入所属标准类别..." title="所属标准类别"/>
|
||||
</el-form-item>
|
||||
<el-form-item :label="label.DICTIONARY_NAME" prop="DICTIONARY_NAME">
|
||||
<el-input id="DICTIONARY_NAME" ref="DICTIONARY_NAME" v-model="form.DICTIONARY_NAME" :placeholder="'这里输入'+label.DICTIONARY_NAME+'...'" :title="label.DICTIONARY_NAME" maxlength="255"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="排序" prop="DICTIONARY_SORT">
|
||||
<el-input-number :min="1" :precision="0" v-model="form.DICTIONARY_SORT" style="width: 100%;" controls-position="right" autocomplete="off" placeholder="这里输入排序..." />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="close">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import CascaderDict from '../../../../components/CascaderDict'
|
||||
export default {
|
||||
components: { CascaderDict },
|
||||
directives: { waves },
|
||||
props: {
|
||||
title: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
dialogType: 'add',
|
||||
dictId: 'f2598ba72e864eadabf0ca4b664d26b9', // 行业类型
|
||||
commonStatusList: [
|
||||
{ id: 1, name: '有效' },
|
||||
{ id: 2, name: '停用' }
|
||||
],
|
||||
label: {
|
||||
DICTIONARY_NAME: ''
|
||||
},
|
||||
form: {
|
||||
DICTIONARY_ID: '',
|
||||
DICTIONARY_NAME: '',
|
||||
PARENT_ID: '',
|
||||
PARENT_IDS: '',
|
||||
PARENT_NAME: '',
|
||||
DICTIONARY_NAMES: '',
|
||||
DICTIONARY_LEVEL: '',
|
||||
DICTIONARY_SORT: '',
|
||||
DICTIONARY_SOURCE: ''
|
||||
},
|
||||
rules: {
|
||||
DICTIONARY_NAME: [{ required: true, message: '类目名称不能为空', trigger: 'blur' }],
|
||||
DICTIONARY_SORT: [{ required: true, message: '排序不能为空', trigger: 'blur' }]
|
||||
},
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
visible: false,
|
||||
info: {}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
if (e) {
|
||||
this.dialogType = 'edit'
|
||||
this.form = e
|
||||
if (this.form.DICTIONARY_LEVEL === 2) {
|
||||
this.label.DICTIONARY_NAME = '标准项目'
|
||||
this.$set(this.form, 'PARENT_NAME', this.form.DICTIONARY_NAMES.substr(0, this.form.DICTIONARY_NAMES.lastIndexOf(',')))
|
||||
this.rules.DICTIONARY_NAME = [{ required: true, message: '标准项目不能为空', trigger: 'blur' }]
|
||||
} else {
|
||||
this.label.DICTIONARY_NAME = '标准类别'
|
||||
this.rules.DICTIONARY_NAME = [{ required: true, message: '标准类别不能为空', trigger: 'blur' }]
|
||||
}
|
||||
console.log(this.form)
|
||||
}
|
||||
},
|
||||
confirm() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
this.loading = true
|
||||
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardDictionary/' + this.dialogType,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.loading = false
|
||||
this.close()
|
||||
this.$emit('beforeClose', '')
|
||||
this.$message.success('操作成功')
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
resetForm() {
|
||||
// this.$refs.refIndustryType.clearNodes()
|
||||
this.form = {
|
||||
COMMON_ID: '',
|
||||
INDUSTRY_TYPE_ARR: [],
|
||||
INDUSTRY_TYPE_TREE: '',
|
||||
DICTIONARY_NAME: '',
|
||||
COMMON_STATUS: ''
|
||||
}
|
||||
},
|
||||
close() {
|
||||
this.resetForm()
|
||||
this.visible = false
|
||||
},
|
||||
getDicTree() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,81 @@
|
|||
<template>
|
||||
<el-dialog :visible.sync="visible" :title="title" width="600">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<td class="tbg">类目名称</td>
|
||||
<td>{{ form.DICTIONARY_NAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">类别</td>
|
||||
<td>{{ form.DICTIONARY_LEVEL ? (form.DICTIONARY_LEVEL === 1 ? '标准类别' : '标准项目') : '' }}</td>
|
||||
</tr>
|
||||
<tr v-if="form.DICTIONARY_LEVEL !== 1">
|
||||
<td class="tbg">标准类别</td>
|
||||
<td>{{ form.DICTIONARY_NAMES.substr(0,form.DICTIONARY_NAMES.lastIndexOf(',')) }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">来源</td>
|
||||
<td>{{ form.DICTIONARY_SOURCE ? (form.DICTIONARY_SOURCE === 1 ? '运营添加' : '企业自建') : '' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">排序</td>
|
||||
<td>{{ form.DICTIONARY_SORT }}</td>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<td class="tbg">状态</td>
|
||||
<td colspan="3">{{ form.COMMON_STATUS ? (form.COMMON_STATUS === 1 ? '有效' : '停用') : '' }}</td>
|
||||
</tr>-->
|
||||
</table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="close">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import waves from '@/directive/waves'
|
||||
export default {
|
||||
directives: { waves },
|
||||
props: {
|
||||
title: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: true,
|
||||
visible: false,
|
||||
form: {
|
||||
DICTIONARY_ID: '',
|
||||
DICTIONARY_NAME: '',
|
||||
PARENT_ID: '',
|
||||
PARENT_IDS: '',
|
||||
DICTIONARY_NAMES: '',
|
||||
DICTIONARY_LEVEL: '',
|
||||
DICTIONARY_SORT: '',
|
||||
DICTIONARY_SOURCE: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
if (e) {
|
||||
this.form = e
|
||||
}
|
||||
},
|
||||
close() {
|
||||
this.visible = false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.tbg{
|
||||
width: 110px !important;
|
||||
}
|
||||
</style>
|
||||
|
|
@ -0,0 +1,242 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="filter-container">
|
||||
<!-- <el-row :gutter="20">
|
||||
<el-form label-width="80px">
|
||||
<el-col :span="6">
|
||||
<el-form-item label="名称">
|
||||
<el-input v-model="searchForm.DICTIONARY_NAMES" placeholder="搜索名称..." class="filter-item" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6" >
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh-left" @click="resetting">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
</el-row>-->
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
:tree-props="{children: 'children', hasChildren: 'hasChildren'}"
|
||||
default-expand-all>
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row
|
||||
>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="DICTIONARY_NAME" label="类目名称" />
|
||||
<el-table-column prop="DICTIONARY_LEVEL" label="类别" width="140" align="center" >
|
||||
<template slot-scope="{row}">
|
||||
{{ row.DICTIONARY_LEVEL ? (row.DICTIONARY_LEVEL === 1 ? '标准类别' : '标准项目') : '' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="DICTIONARY_SOURCE" label="来源" width="140" align="center" >
|
||||
<template slot-scope="{row}">
|
||||
{{ row.DICTIONARY_SOURCE ? (row.DICTIONARY_SOURCE === 1 ? '运营添加' : '企业自建') : '' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="DICTIONARY_SORT" label="排序" width="60" align="center" />
|
||||
<el-table-column label="操作" align="center" width="300">
|
||||
<template slot-scope="{row}">
|
||||
<el-row :gutter="20">
|
||||
<el-button type="success" icon="el-icon-view" size="mini" @click="getInfo(row)">查看</el-button>
|
||||
<el-button v-show="edit" :disabled="row.DICTIONARY_SOURCE !== 1 || row.COUNT_USE !== 1" type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row)">编辑</el-button>
|
||||
<el-button v-show="del" :disabled="row.DICTIONARY_SOURCE !== 1 || row.COUNT_USE !== 1" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.DICTIONARY_ID)">删除</el-button>
|
||||
</el-row>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button type="primary" icon="el-icon-refresh" @click="getList">刷新</el-button>
|
||||
<!-- <el-button v-show="add" type="primary" icon="el-icon-plus" @click="handleAdd">新增</el-button>-->
|
||||
<!-- <el-button v-show="false" type="danger" icon="el-icon-delete" plain @click="batchDel">删除</el-button>-->
|
||||
</div>
|
||||
<!-- <pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />-->
|
||||
</div>
|
||||
<edit ref="edit" :title="title" href="edit" @beforeClose="getList"/>
|
||||
<info ref="info" :title="title"/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import edit from './edit.vue'
|
||||
import Info from './info.vue'
|
||||
export default {
|
||||
components: { Info, edit, Pagination },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
varList: [],
|
||||
title: '新增',
|
||||
dictId: 'f2598ba72e864eadabf0ca4b664d26b9', // 行业类型
|
||||
commonStatusList: [
|
||||
{ id: 1, name: '有效' },
|
||||
{ id: 2, name: '停用' }
|
||||
],
|
||||
searchForm: {
|
||||
DICTIONARY_NAMES: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.getDict()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.DICTIONARY_ID
|
||||
},
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
resetting() {
|
||||
this.searchForm = {
|
||||
DICTIONARY_NAMES: ''
|
||||
}
|
||||
this.getList()
|
||||
},
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardDictionary/listTree?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
DICTIONARY_NAMES: this.searchForm.DICTIONARY_NAMES
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
handleAdd() {
|
||||
this.$refs.edit.init()
|
||||
this.title = '新增'
|
||||
},
|
||||
handleEdit(row) {
|
||||
this.$refs.edit.init(JSON.parse(JSON.stringify(row)))
|
||||
this.title = '编辑'
|
||||
},
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardDictionary/delete',
|
||||
{ DICTIONARY_ID: id }
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
batchDel() {
|
||||
const _selectData = this.$refs.multipleTable.selection
|
||||
if (_selectData == null || _selectData.length == 0) {
|
||||
this.$message({
|
||||
message: '请选中要删除的项...',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const ids = _selectData.map((item, index) => {
|
||||
return item.DICTIONARY_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenDangerCheckStandardDictionary/deleteAll',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'hiddenDangerCheckStandardDictionary:add,hiddenDangerCheckStandardDictionary:del,hiddenDangerCheckStandardDictionary:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
console.log(data)
|
||||
this.add = data.hiddenDangerCheckStandardDictionaryfhadminadd // 新增权限
|
||||
this.del = data.hiddenDangerCheckStandardDictionaryfhadmindel // 删除权限
|
||||
this.edit = data.hiddenDangerCheckStandardDictionaryfhadminedit // 修改权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
getDict: function() {
|
||||
},
|
||||
getInfo(row) {
|
||||
this.$refs.info.init(row)
|
||||
this.title = '详情'
|
||||
},
|
||||
getResult(e) {
|
||||
this.getList()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
<template>
|
||||
<div>
|
||||
<List v-show="activeName==='List'" ref="list" />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import List from './components/list.vue'
|
||||
export default {
|
||||
components: { List },
|
||||
data() {
|
||||
return {
|
||||
activeName: 'List',
|
||||
COMMON_ID: ''
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -6,7 +6,13 @@
|
|||
<div class="login-top">
|
||||
<img :src="imgUrl2" alt="">
|
||||
</div>
|
||||
<el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form" autocomplete="on" label-position="left">
|
||||
<el-form
|
||||
ref="loginForm"
|
||||
:model="loginForm"
|
||||
:rules="loginRules"
|
||||
class="login-form"
|
||||
autocomplete="on"
|
||||
label-position="left">
|
||||
|
||||
<div class="title-container">
|
||||
<h3 class="title">企业用户登录</h3>
|
||||
|
|
@ -14,41 +20,56 @@
|
|||
|
||||
<el-form-item prop="username">
|
||||
<span class="svg-container">
|
||||
<svg-icon icon-class="user" />
|
||||
<svg-icon icon-class="user"/>
|
||||
</span>
|
||||
<el-input ref="username" v-model="loginForm.username" placeholder="用户名" type="text" tabindex="1" autocomplete="on" />
|
||||
<el-input
|
||||
ref="username"
|
||||
v-model="loginForm.username"
|
||||
placeholder="用户名"
|
||||
type="text"
|
||||
tabindex="1"
|
||||
autocomplete="on"/>
|
||||
</el-form-item>
|
||||
|
||||
<el-tooltip v-model="capsTooltip" content="Caps lock is On" placement="right" manual>
|
||||
<el-form-item prop="password">
|
||||
<span class="svg-container">
|
||||
<svg-icon icon-class="password" />
|
||||
<svg-icon icon-class="password"/>
|
||||
</span>
|
||||
|
||||
<el-input ref="password" :key="passwordType" v-model="loginForm.password" :type="passwordType" placeholder="密码" tabindex="2" autocomplete="on" @keyup.native="checkCapslock" @blur="capsTooltip = false" />
|
||||
<el-input
|
||||
ref="password"
|
||||
:key="passwordType"
|
||||
v-model="loginForm.password"
|
||||
:type="passwordType"
|
||||
placeholder="密码"
|
||||
tabindex="2"
|
||||
autocomplete="on"
|
||||
@keyup.native="checkCapslock"
|
||||
@blur="capsTooltip = false"/>
|
||||
|
||||
</el-form-item>
|
||||
</el-tooltip>
|
||||
<validation ref="validation" />
|
||||
<el-button :loading="loading" :disabled="flag" type="primary" size="medium" style="width:100%;margin:30px 0;" @click.native.prevent="handleLogin">登录</el-button>
|
||||
<!-- <div style="position:relative">-->
|
||||
<!-- <div class="tips">-->
|
||||
<!-- <span @click="goqrcode">秦安双控APP下载</span>-->
|
||||
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<validation ref="validation"/>
|
||||
<el-button
|
||||
:loading="loading"
|
||||
:disabled="flag"
|
||||
type="primary"
|
||||
size="medium"
|
||||
style="width:100%;margin:30px 0;"
|
||||
@click.native.prevent="handleLogin">登录
|
||||
</el-button>
|
||||
</el-form>
|
||||
|
||||
<el-dialog :visible.sync="showDialog" title="Or connect with">
|
||||
Can not be simulated on local, so please combine you own business simulation! ! !
|
||||
<br>
|
||||
<br>
|
||||
<br>
|
||||
<social-sign />
|
||||
<social-sign/>
|
||||
</el-dialog>
|
||||
<el-dialog :visible.sync="dialogFormQrcode" title="秦安双控APP下载" width="340px">
|
||||
<el-form ref="form" label-width="110px" style="width: 300px;">
|
||||
<vue-qr :text="qrcodeStr" :margin="0" :size="300" color-dark="#000" color-light="#fff" />
|
||||
<vue-qr :text="qrcodeStr" :margin="0" :size="300" color-dark="#000" color-light="#fff"/>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormQrcode = false">取 消</el-button>
|
||||
|
|
@ -65,6 +86,7 @@ import { requestFN } from '@/utils/request'
|
|||
import validation from './components/validation'
|
||||
import vueQr from 'vue-qr'
|
||||
import axios from 'axios'
|
||||
|
||||
export default {
|
||||
name: 'Login',
|
||||
components: { vueQr, validation },
|
||||
|
|
@ -150,18 +172,7 @@ export default {
|
|||
})
|
||||
},
|
||||
handleLogin() {
|
||||
this.flag = true
|
||||
// 设置定时器,1秒后,按钮可用
|
||||
setTimeout(() => {
|
||||
this.flag = false
|
||||
}, 5000)
|
||||
this.$refs.loginForm.validate(valid => {
|
||||
/* if (this.rangeStatus) {
|
||||
console.info(this.rangeStatus)
|
||||
} else {
|
||||
console.info(this.rangeStatus)
|
||||
}*/
|
||||
|
||||
if (this.$refs.validation.rangeStatus) {
|
||||
if (valid) {
|
||||
this.loading = true
|
||||
|
|
@ -172,19 +183,23 @@ export default {
|
|||
}
|
||||
).then((data) => {
|
||||
sessionStorage.setItem('user', JSON.stringify(data))
|
||||
this.$router.push({ path: '/index' })
|
||||
this.loading = false
|
||||
requestFN(
|
||||
'/main/index', {}
|
||||
).then((data) => {
|
||||
sessionStorage.setItem('router', JSON.stringify(data.menuList))
|
||||
this.$router.push({ path: '/index' })
|
||||
this.loading = false
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
})
|
||||
.catch((e) => {
|
||||
this.flag = false
|
||||
this.loading = false
|
||||
})
|
||||
} else {
|
||||
this.flag = false
|
||||
return false
|
||||
}
|
||||
} else {
|
||||
this.flag = false
|
||||
this.$message({
|
||||
message: '请进行登录验证',
|
||||
type: 'error'
|
||||
|
|
@ -214,18 +229,22 @@ export default {
|
|||
|
||||
<style>
|
||||
/* 修复input 背景不协调 和光标变色 */
|
||||
/* Detail see https://github.com/PanJiaChen/vue-element-admin/pull/927 */hasUser
|
||||
/* Detail see https://github.com/PanJiaChen/vue-element-admin/pull/927 */
|
||||
hasUser
|
||||
|
||||
@supports (-webkit-mask: none) and (not (cater-color: #fff)) {
|
||||
.login-container .el-input input {
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
|
||||
/* reset element-ui css */
|
||||
.login-container .el-input {
|
||||
display: inline-block;
|
||||
height: 42px;
|
||||
width: 85%;
|
||||
}
|
||||
|
||||
.login-container .el-input input {
|
||||
background: transparent;
|
||||
border: 0px;
|
||||
|
|
@ -236,10 +255,12 @@ export default {
|
|||
line-height: 42px;
|
||||
/* caret-color: #fff; */
|
||||
}
|
||||
|
||||
.login-container .el-input input:-webkit-autofill {
|
||||
box-shadow: 0 0 0px 1000px #fff inset !important;
|
||||
-webkit-text-fill-color: #000 !important;
|
||||
}
|
||||
|
||||
.login-container .el-form-item {
|
||||
border: 1px solid #aad5ff;
|
||||
/* background: rgba(0, 0, 0, 0.1); */
|
||||
|
|
@ -248,27 +269,31 @@ export default {
|
|||
}
|
||||
</style>
|
||||
|
||||
<style >
|
||||
<style>
|
||||
.login-logo {
|
||||
position: absolute;
|
||||
top: 50px;
|
||||
left: 50px;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.login-logo img {
|
||||
width: 490px;
|
||||
height: 82px;
|
||||
}
|
||||
|
||||
.login-top {
|
||||
position: absolute;
|
||||
top: 290px;
|
||||
left: 300px;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.login-top img {
|
||||
width: 675px;
|
||||
height: 435px;
|
||||
}
|
||||
|
||||
.login-container {
|
||||
height: 100vh;
|
||||
width: 100%;
|
||||
|
|
@ -277,6 +302,7 @@ export default {
|
|||
background: url(../../assets/images/login-bg.png) no-repeat;
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
|
||||
.login-foot {
|
||||
font-size: 14px;
|
||||
color: rgba(255, 255, 255, 0.5);
|
||||
|
|
@ -285,6 +311,7 @@ export default {
|
|||
bottom: 60px;
|
||||
left: 42%;
|
||||
}
|
||||
|
||||
.login-container .login-form {
|
||||
position: absolute;
|
||||
width: 400px;
|
||||
|
|
@ -297,15 +324,18 @@ export default {
|
|||
right: 14%;
|
||||
top: 24%;
|
||||
}
|
||||
|
||||
.login-name {
|
||||
position: absolute;
|
||||
right: 9.5%;
|
||||
top: 15%;
|
||||
}
|
||||
|
||||
.login-name img {
|
||||
width: 422px;
|
||||
height: 53px;
|
||||
}
|
||||
|
||||
.login-container .tips {
|
||||
font-size: 14px;
|
||||
color: #464646;
|
||||
|
|
@ -321,15 +351,18 @@ export default {
|
|||
width: 30px;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.login-container .title-container {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.login-container .title-container .title {
|
||||
font-size: 20px;
|
||||
color: #000;
|
||||
font-weight: normal;
|
||||
font-family: "微软雅黑", "宋体", "Arial Narrow", Helvetica, sans-serif;
|
||||
}
|
||||
|
||||
.login-container .show-pwd {
|
||||
position: absolute;
|
||||
right: 10px;
|
||||
|
|
@ -339,11 +372,13 @@ export default {
|
|||
cursor: pointer;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.login-container .thirdparty-button {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
bottom: 6px;
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 470px) {
|
||||
.login-container .thirdparty-button {
|
||||
display: none;
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
<div class="filter-row mb-10">
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable">请输入课程:</div>
|
||||
<el-input v-model="KEYWORDS" placeholder="请输入课程名称或课程简介或课程目的" style="width: 200px;" />
|
||||
<el-input v-model="KEYWORDS" placeholder="请输入课程名称" style="width: 200px;" />
|
||||
</div>
|
||||
<!-- <div class="filter-group">-->
|
||||
<!-- <div class="filter-lable"> 培训行业类型:</div>-->
|
||||
|
|
@ -1134,7 +1134,7 @@ export default {
|
|||
if (type == '1') {
|
||||
this.videoMap.KEYWORDS = ''
|
||||
this.videoMap.tarinTypeID = ''
|
||||
this.$refs.keyvidHyRef.clearHandle()
|
||||
// this.$refs.keyvidHyRef.clearHandle()
|
||||
this.videoMap = { // 视频课件数据
|
||||
list: [],
|
||||
total: 0,
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<div class="filter-row mb-10">
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable"> 课程名称:</div>
|
||||
<el-input v-model="KEYWORDS" placeholder="搜索课件名称或主讲人" clearable style="width: 200px;" @clear="getQuery"/>
|
||||
<el-input v-model="KEYWORDS" placeholder="搜索课件名称" clearable style="width: 200px;" @clear="getQuery"/>
|
||||
</div>
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable"> 培训教师:</div>
|
||||
|
|
@ -262,8 +262,10 @@ import waves from '@/directive/waves' // waves directive
|
|||
import { upload } from '@/utils/upload'
|
||||
import pdf from 'vue-pdf'
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
import Treeselect from '@riophae/vue-treeselect'
|
||||
|
||||
export default {
|
||||
components: { Pagination, pdf, SelectTree },
|
||||
components: { Pagination, pdf, SelectTree, Treeselect },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -11,8 +11,10 @@
|
|||
<el-input v-model="teacherKey" placeholder="搜索教师名称" clearable style="width: 200px;" />
|
||||
</div>
|
||||
<div class="filter-group">
|
||||
<!-- {{ dicListMap.trainingSectionList }}-->
|
||||
<div class="filter-lable"> 培训板块类型:</div>
|
||||
<SelectTree ref="trainingSectionRef" :options="dicListMap.trainingSectionList" :props="defaultProps" v-model="trainingSectionKey" placeholder="请选择培训板块类型" />
|
||||
<!-- <Treeselect ref="trainingSectionRef" :options="dicListMap.trainingSectionList" :props="defaultProps" v-model="trainingSectionKey" placeholder="请选择培训板块类型" />-->
|
||||
</div>
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable"> 培训行业类型:</div>
|
||||
|
|
@ -249,9 +251,11 @@ import waves from '@/directive/waves' // waves directive
|
|||
import { videoPlayer } from 'vue-video-player'
|
||||
import 'video.js/dist/video-js.css'
|
||||
import SelectTree from '@/components/SelectTree'
|
||||
import Treeselect from '@riophae/vue-treeselect'
|
||||
|
||||
import axios from 'axios'
|
||||
export default {
|
||||
components: { Pagination, videoPlayer, SelectTree },
|
||||
components: { Pagination, videoPlayer, SelectTree, Treeselect },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
|
|
@ -546,7 +550,7 @@ export default {
|
|||
}
|
||||
})
|
||||
this.form.isEditVideo = this.isEditVideo
|
||||
if (this.dialogType == 'add' || (this.dialogType == 'edit' && this.isEditVideo)) {
|
||||
if ((this.dialogType == 'add' && this.uploader) || (this.dialogType == 'edit' && this.isEditVideo)) {
|
||||
this.authUpload()
|
||||
this.dialogFormEdit = false
|
||||
this.isShowProgress = true
|
||||
|
|
|
|||
|
|
@ -9,7 +9,22 @@
|
|||
</el-button>
|
||||
</div>
|
||||
<div class="filter-flot">
|
||||
<el-button v-waves class="filter-item" type="info" icon="el-icon-bottom-right" size="mini" plain @click="dialogFormDaoru = true">
|
||||
<el-button
|
||||
v-waves
|
||||
class="filter-item"
|
||||
type="info"
|
||||
icon="el-icon-bottom-right"
|
||||
size="mini"
|
||||
plain
|
||||
@click="() =>{
|
||||
dialogFormDaoru = true;
|
||||
|
||||
daoruFrom= {
|
||||
FFILE: '',
|
||||
FFILEName: ''
|
||||
};
|
||||
}
|
||||
">
|
||||
导入
|
||||
</el-button>
|
||||
<!-- <el-button v-waves size="mini" plain type="info" icon="el-icon-bottom-right" @click="dialogFormDaoru = true">
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,362 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="filter-container">
|
||||
<div class="filter-group ">
|
||||
<div class="filter-lable">
|
||||
企业名称:
|
||||
</div>
|
||||
<div class="filter-width">
|
||||
<el-input v-model="KEYWORDS" placeholder="搜索" class="filter-item"/>
|
||||
</div>
|
||||
</div>
|
||||
<div :style="{'margin-top': searchFromCollapse ? '0px' : '10px'}" class="filter-group">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-refresh" @click="goKeyReset">
|
||||
重置
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row
|
||||
>
|
||||
<el-table-column
|
||||
:reserve-selection="true"
|
||||
type="selection"
|
||||
width="55"
|
||||
align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="CORP_NAME" label="企业名称" />
|
||||
<el-table-column prop="IS_MAJOR_HAZARD" label="是否重大危险源企业" >
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.IS_MAJOR_HAZARD == '0'">否</span>
|
||||
<span v-if="row.IS_MAJOR_HAZARD == '1'">是</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="IS_MAJOR_HAZARD_PUSH" label="是否开启重大危险源企业数据推送" >
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.IS_MAJOR_HAZARD_PUSH == '0'">否</span>
|
||||
<span v-if="row.IS_MAJOR_HAZARD_PUSH == '1'">是</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="IS_MAIN_TECHNOLO" label="是否重点工艺企业" >
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.IS_MAIN_TECHNOLO == '0'">否</span>
|
||||
<span v-if="row.IS_MAIN_TECHNOLO == '1'">是</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="IS_MAIN_TECHNOLO_PUSH" label="是否开启重点工艺企业数据推送" >
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.IS_MAIN_TECHNOLO_PUSH == '0'">否</span>
|
||||
<span v-if="row.IS_MAIN_TECHNOLO_PUSH == '1'">是</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="IS_MAIN_TECHNOLO" label="是否专项检查企业" >
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.IS_SPE_CORP == '0'">否</span>
|
||||
<span v-if="row.IS_SPE_CORP == '1'">是</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="IS_MAIN_TECHNOLO_PUSH" label="是否开启专项检查数据推送" >
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.IS_SPE_CORP_PUSH == '0'">否</span>
|
||||
<span v-if="row.IS_SPE_CORP_PUSH == '1'">是</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" >
|
||||
<template slot-scope="{row}">
|
||||
<el-button type="warning" icon="el-icon-edit" size="mini" @click="handleEdit(row)">配置企业类型</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div/>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
<el-dialog :visible.sync="dialogFormEdit" title="配置企业类型" width="600px">
|
||||
<el-form ref="form" :model="form" label-width="250px" style="width: 500px;">
|
||||
<el-form-item label="是否重大危险源企业" prop="IS_MAIN_TECHNOLO">
|
||||
<el-radio v-model="form.IS_MAJOR_HAZARD" label="1">是</el-radio>
|
||||
<el-radio v-model="form.IS_MAJOR_HAZARD" label="0">否</el-radio>
|
||||
</el-form-item>
|
||||
<el-form-item label="是否开启重大危险源企业数据推送" prop="IS_MAIN_TECHNOLO">
|
||||
<el-radio v-model="form.IS_MAJOR_HAZARD_PUSH" label="1">是</el-radio>
|
||||
<el-radio v-model="form.IS_MAJOR_HAZARD_PUSH" label="0">否</el-radio>
|
||||
</el-form-item>
|
||||
<el-form-item label="是否重点工艺企业" prop="IS_MAIN_TECHNOLO">
|
||||
<el-radio v-model="form.IS_MAIN_TECHNOLO" label="1">是</el-radio>
|
||||
<el-radio v-model="form.IS_MAIN_TECHNOLO" label="0">否</el-radio>
|
||||
</el-form-item>
|
||||
<el-form-item label="是否开启重点工艺企业数据推送" prop="IS_MAIN_TECHNOLO_PUSH">
|
||||
<el-radio v-model="form.IS_MAIN_TECHNOLO_PUSH" label="1">是</el-radio>
|
||||
<el-radio v-model="form.IS_MAIN_TECHNOLO_PUSH" label="0">否</el-radio>
|
||||
</el-form-item>
|
||||
<el-form-item label="是否专项检查企业" prop="IS_SPE_CORP">
|
||||
<el-radio v-model="form.IS_SPE_CORP" label="1">是</el-radio>
|
||||
<el-radio v-model="form.IS_SPE_CORP" label="0">否</el-radio>
|
||||
</el-form-item>
|
||||
<el-form-item label="是否开启专项检查数据推送" prop="IS_SPE_CORP_PUSH">
|
||||
<el-radio v-model="form.IS_SPE_CORP_PUSH" label="1">是</el-radio>
|
||||
<el-radio v-model="form.IS_SPE_CORP_PUSH" label="0">否</el-radio>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormEdit = false">取 消</el-button>
|
||||
<el-button type="primary" @click="fnUpdCorpType">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
// waves directive
|
||||
export default {
|
||||
components: { Pagination },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
varList: [],
|
||||
total: 0,
|
||||
form: {
|
||||
IS_MAJOR_HAZARD: '0',
|
||||
IS_MAJOR_HAZARD_PUSH: '0',
|
||||
IS_MAIN_TECHNOLO_PUSH: '0',
|
||||
IS_MAIN_TECHNOLO: '0',
|
||||
IS_SPE_CORP: '0',
|
||||
IS_SPE_CORP_PUSH: '0'
|
||||
},
|
||||
dialogFormEdit: false,
|
||||
KEYWORDS: '',
|
||||
CORPINFO_ID: '',
|
||||
searchFromCollapse: true,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
var user = sessionStorage.getItem('user')
|
||||
var obj = JSON.parse(user)
|
||||
if (obj && (obj.AGENCY_MANAGEMENT_ID === '' || obj.AGENCY_MANAGEMENT_ID == null)) {
|
||||
this.isAdmin = true
|
||||
}
|
||||
this.getList(this.ROLE_ID)
|
||||
this.getDict()
|
||||
this.getDictByDicId('e725d2a91b8248f4b8f49889038df7de').then(data => {
|
||||
this.areaList = data
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
|
||||
getRowKey(row) {
|
||||
return row.CORPINFO_ID
|
||||
},
|
||||
// 搜索
|
||||
getQuery() {
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
},
|
||||
// 获取列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
this.POSSESSION
|
||||
var possession = ''
|
||||
var possessionLevel = ''
|
||||
if (this.POSSESSION && this.POSSESSION.length > 0) {
|
||||
possession = this.POSSESSION[this.POSSESSION.length - 1]
|
||||
possessionLevel = this.POSSESSION.length
|
||||
}
|
||||
requestFN(
|
||||
'/corpinfo/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
{
|
||||
KEYWORDS: this.KEYWORDS,
|
||||
ISSMALL: '2',
|
||||
PAGETYPE: '1',
|
||||
POSSESSION: possession,
|
||||
POSSESSIONLEVEL: possessionLevel
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
this.pd = data.pd
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
// 重置
|
||||
goKeyReset() {
|
||||
this.KEYWORDS = ''
|
||||
this.getQuery()
|
||||
},
|
||||
// 修改
|
||||
handleEdit(row) {
|
||||
this.CORPINFO_ID = row.CORPINFO_ID
|
||||
this.form.IS_MAIN_TECHNOLO = row.IS_MAIN_TECHNOLO
|
||||
this.form.IS_MAJOR_HAZARD_PUSH = row.IS_MAJOR_HAZARD_PUSH
|
||||
this.form.IS_MAIN_TECHNOLO_PUSH = row.IS_MAIN_TECHNOLO_PUSH
|
||||
this.form.IS_MAJOR_HAZARD = row.IS_MAJOR_HAZARD
|
||||
this.form.IS_SPE_CORP = row.IS_SPE_CORP
|
||||
this.form.IS_SPE_CORP_PUSH = row.IS_SPE_CORP_PUSH
|
||||
this.dialogFormEdit = true
|
||||
},
|
||||
fnUpdCorpType() {
|
||||
this.$confirm('确定要修改企业类型吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/corpinfo/updCorpType',
|
||||
{
|
||||
CORPINFO_ID: this.CORPINFO_ID,
|
||||
IS_MAIN_TECHNOLO: this.form.IS_MAIN_TECHNOLO,
|
||||
IS_MAJOR_HAZARD_PUSH: this.form.IS_MAJOR_HAZARD_PUSH,
|
||||
IS_MAIN_TECHNOLO_PUSH: this.form.IS_MAIN_TECHNOLO_PUSH,
|
||||
IS_MAJOR_HAZARD: this.form.IS_MAJOR_HAZARD,
|
||||
IS_SPE_CORP: this.form.IS_SPE_CORP,
|
||||
IS_SPE_CORP_PUSH: this.form.IS_SPE_CORP_PUSH
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '修改成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.dialogFormEdit = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
this.listLoading = false
|
||||
}).catch(() => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/corpinfo/delete',
|
||||
{
|
||||
CORPINFO_ID: id
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
|
||||
// 判断按钮权限,用于是否显示按钮
|
||||
hasButton: function() {
|
||||
var keys = 'corpinfo:add,corpinfo:del,corpinfo:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.corpinfofhadminadd // 新增权限
|
||||
this.del = data.corpinfofhadmindel // 删除权限
|
||||
this.edit = data.corpinfofhadminedit // 修改权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
|
||||
// 获取数据字典数据
|
||||
getDictByDicId(dicId) {
|
||||
var dicListVal = []
|
||||
return new Promise((resolve) => {
|
||||
let id = ''
|
||||
if (!dicId) {
|
||||
id = '0'
|
||||
} else {
|
||||
id = dicId
|
||||
}
|
||||
requestFN(
|
||||
'/dictionaries/getLevelsAndSCount',
|
||||
{
|
||||
DICTIONARIES_ID: id
|
||||
}
|
||||
).then((data) => {
|
||||
if (data.list.length > 0) {
|
||||
dicListVal = data.list.map((e) => {
|
||||
if (e.zcount == '0') {
|
||||
return { value: e.DICTIONARIES_ID.toString(), numValue: e.BIANMA.toString(), label: e.NAME, id: e.DICTIONARIES_ID, leaf: true }
|
||||
} else {
|
||||
return { value: e.DICTIONARIES_ID.toString(), numValue: e.BIANMA.toString(), label: e.NAME, id: e.DICTIONARIES_ID, children: [], leaf: false }
|
||||
}
|
||||
})
|
||||
} else {
|
||||
dicListVal = undefined
|
||||
}
|
||||
return resolve(dicListVal)
|
||||
}).catch((e) => {
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<style>
|
||||
.el-table .yellow-row {
|
||||
background: rgba(248, 231, 28, 0.2);
|
||||
|
||||
}
|
||||
|
||||
.el-table .red-row {
|
||||
background: rgba(252, 2, 33, 0.2);
|
||||
}
|
||||
.el-table .green-row {
|
||||
background: rgba(26, 208, 22, 0.2);
|
||||
}
|
||||
|
||||
</style>
|
||||
<style lang="sass" scoped>
|
||||
.uo-flex
|
||||
display: flex
|
||||
.filter-container
|
||||
position: relative
|
||||
.filter-flot
|
||||
position: absolute
|
||||
right: 0
|
||||
top: 0
|
||||
|
||||
</style>
|
||||
|
||||
|
|
@ -0,0 +1,345 @@
|
|||
<template>
|
||||
<div>
|
||||
<div class="app-container">
|
||||
<div class="level-title">
|
||||
<h1>基本信息</h1>
|
||||
</div>
|
||||
<div class="mb-20">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<td class="tbg">会员级别</td>
|
||||
<td>{{ pd.ROLE_NAME }}</td>
|
||||
<td class="tbg"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">企业名称</td>
|
||||
<td>{{ pd.CORP_NAME }}</td>
|
||||
<td class="tbg">邮政编码</td>
|
||||
<td>{{ pd.POSTAL_CODE }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">统一社会信用代码</td>
|
||||
<td>{{ pd.CODE }}</td>
|
||||
<td class="tbg">市行业监管部门</td>
|
||||
<td>{{ pd.INDUSTRY_DEPARTMENTName }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">属地</td>
|
||||
<td >{{ pd.COMPANY_AREA }}</td>
|
||||
<!-- <td class="tbg">监管类型</td>-->
|
||||
<!-- <td>{{ pd.REGULARTYPE_NAME }}</td>-->
|
||||
<td class="tbg"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">经济类型</td>
|
||||
<td>{{ pd.ECO_TYPE_NAME }}</td>
|
||||
<td class="tbg">所属行业</td>
|
||||
<td>{{ pd.CORP_TYPE_NAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">企事业单位经营地址</td>
|
||||
<td>{{ pd.ADDRESS_BUSINESS }}</td>
|
||||
<td class="tbg">企业状态</td>
|
||||
<td>{{ pd.CORP_STATE_NAME }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">经度</td>
|
||||
<td>{{ pd.LONGITUDE }}</td>
|
||||
<td class="tbg">纬度</td>
|
||||
<td>{{ pd.LATITUDE }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">主要负责人</td>
|
||||
<td>{{ pd.CONTACTS }}</td>
|
||||
<td class="tbg">主要负责人电话</td>
|
||||
<td>{{ pd.CONTACTS_PHONE }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">法定代表人</td>
|
||||
<td>{{ pd.LR_NAME }}</td>
|
||||
<td class="tbg">法人手机号</td>
|
||||
<td>{{ pd.LR_PHONE }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">占地面积(㎡)</td>
|
||||
<td>{{ pd.AREA_COVERED }}</td>
|
||||
<td class="tbg">职工人数(人)</td>
|
||||
<td>{{ pd.EMPLOYEES }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">成立时间</td>
|
||||
<td>{{ pd.CREATE_DATE }}</td>
|
||||
<td class="tbg">注册资金(万元)</td>
|
||||
<td>{{ pd.REGCAPITAL }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">资产总额(万元)</td>
|
||||
<td>{{ pd.TOTALASSETS }}</td>
|
||||
<td class="tbg">隶属关系</td>
|
||||
<td>{{ pd.SUBORDINATIONNAME }}</td>
|
||||
</tr>
|
||||
<!-- <tr>-->
|
||||
<!-- <td class="tbg">企业类型</td>-->
|
||||
<!-- <td>{{ pd.CORP_OF_TYPE_NAME?pd.CORP_OF_TYPE_NAME:'' }}{{ pd.CORP_OF_TYPE_NAME&&pd.CORP_OF_TYPE_NAME2?'/':'' }}{{ pd.CORP_OF_TYPE_NAME2?pd.CORP_OF_TYPE_NAME2:'' }}</td>-->
|
||||
|
||||
<!-- </tr>-->
|
||||
<tr>
|
||||
<td class="tbg">规模</td>
|
||||
<td>{{ pd.SCALE_NAME }}</td>
|
||||
<td class="tbg">是否规模以上</td>
|
||||
<td>
|
||||
|
||||
<template v-if="pd.SCALE_TYPE=='0'">否</template>
|
||||
<template v-if="pd.SCALE_TYPE=='1'">是</template>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">培训行业类型</td>
|
||||
<td>{{ pd.TRAINTYPE_NAME }}</td>
|
||||
<td class="tbg">企业可新建用户数量</td>
|
||||
<td>{{ pd.USERS_NUM }}</td>
|
||||
</tr>
|
||||
|
||||
<tr v-if="pd.FOURTYPE== '1'">
|
||||
<td class="tbg">四色图</td>
|
||||
<td colspan="3">
|
||||
<div class="img-flex">
|
||||
<viewer :images="four_images">
|
||||
<img v-for="item in four_images" :src="config.fileUrl + item.FILEPATH" :key="item.IMGFILES_ID" width="100" height="100" style="margin-left:10px;">
|
||||
</viewer>
|
||||
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="tbg">营业执照</td>
|
||||
<td colspan="3">
|
||||
<div class="img-flex">
|
||||
<viewer :images="bus_images">
|
||||
<img v-for="item in bus_images" :src="config.fileUrl + item.FILEPATH" :key="item.IMGFILES_ID" width="100" height="100" style="margin-left:10px;">
|
||||
</viewer>
|
||||
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div class="level-title">
|
||||
<h1>安全负责人信息</h1>
|
||||
</div>
|
||||
<div class="mb-20">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<td class="tbg">姓名</td>
|
||||
<td>{{ pd.SAFETY_NAME }}</td>
|
||||
<td class="tbg">职务</td>
|
||||
<td>{{ pd.SAFETY_POST }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">单位电话</td>
|
||||
<td>{{ pd.SAFETY_NUMBER }}</td>
|
||||
<td class="tbg">手机号码</td>
|
||||
<td>{{ pd.SAFETY_PHONE }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<!-- <div class="level-title">-->
|
||||
<!-- <h1>安全标准化</h1>-->
|
||||
<!-- </div>-->
|
||||
<!-- <div class="mb-20">-->
|
||||
<!-- <table class="table-ui">-->
|
||||
<!-- <tr>-->
|
||||
<!-- <td class="tbg">安全标准化等级</td>-->
|
||||
<!-- <td>{{ pd.AQ_BZ_LEVEL_NAME }}</td>-->
|
||||
<!-- <td class="tbg">安全标准化证书编号</td>-->
|
||||
<!-- <td>{{ pd.AQ_BZ_NO }}</td>-->
|
||||
<!-- </tr>-->
|
||||
<!-- <tr>-->
|
||||
<!-- <td class="tbg">安全标准化发证单位</td>-->
|
||||
<!-- <td>{{ pd.AQ_BZ_UNIT }}</td>-->
|
||||
<!-- <td class="tbg">安全标准化有效期</td>-->
|
||||
<!-- <td>{{ pd.AQ_BZ_TIME }}</td>-->
|
||||
<!-- </tr>-->
|
||||
<!-- </table>-->
|
||||
<!-- </div>-->
|
||||
<div class="level-title">
|
||||
<h1>企业相关属性</h1>
|
||||
</div>
|
||||
<div class="mb-20">
|
||||
<table class="table-ui">
|
||||
<tr>
|
||||
<td class="tbg">有无职业卫生信息</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_HYGIENE=='0'">无</template>
|
||||
<template v-if="pd.WHETHER_HYGIENE=='1'">有</template>
|
||||
</td>
|
||||
<td class="tbg">有无重大危险源</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_HAZARDS=='0'">无</template>
|
||||
<template v-if="pd.WHETHER_HAZARDS=='1'">有</template>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">是否有稀缺大型应急物资或设施</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_SCARCE=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_SCARCE=='1'">是</template>
|
||||
</td>
|
||||
<td class="tbg">是否涉及危化品</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_CHEMICALS=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_CHEMICALS=='1'">是</template>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">有无特种设备</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_SPECIALEQUIPMENT=='0'">无</template>
|
||||
<template v-if="pd.WHETHER_SPECIALEQUIPMENT=='1'">有</template>
|
||||
</td>
|
||||
<td class="tbg">有无特种作业人员</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_SPECIALPEOPLE=='0'">无</template>
|
||||
<template v-if="pd.WHETHER_SPECIALPEOPLE=='1'">有</template>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">是否涉及煤气</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_COALGAS=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_COALGAS=='1'">是</template>
|
||||
</td>
|
||||
<td class="tbg">是否属于消防重点单位</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_FIRE=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_FIRE=='1'">是</template>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">是否在受限空间作业</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_CONFINED=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_CONFINED=='1'">是</template>
|
||||
</td>
|
||||
<td class="tbg">是否存在涉爆粉尘作业</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_POWDER=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_POWDER=='1'">是</template>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">是否涉及防雷防静电</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_LIGHTNING=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_LIGHTNING=='1'">是</template>
|
||||
</td>
|
||||
<td class="tbg">是否持有放射源</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_ACTINOGEN=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_ACTINOGEN=='1'">是</template>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">是否涉及液氨制冷</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_LIQUIDAMMONIA=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_LIQUIDAMMONIA=='1'">是</template>
|
||||
</td>
|
||||
<td class="tbg">是否涉及危化品管道</td>
|
||||
<td>
|
||||
<template v-if="pd.WHETHER_PIPELINE=='0'">否</template>
|
||||
<template v-if="pd.WHETHER_PIPELINE=='1'">是</template>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui-height" />
|
||||
<div class="ui-foot">
|
||||
<el-button type="primary" icon="el-icon-edit" @click="handleEdit">修改</el-button>
|
||||
<el-button type="info" @click="goBack">返回</el-button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { requestFN } from '@/utils/request'
|
||||
import vueQr from 'vue-qr'
|
||||
export default {
|
||||
components: {
|
||||
vueQr
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
config: config,
|
||||
USER_ID: JSON.parse(sessionStorage.getItem('user')).USER_ID,
|
||||
ROLEID: JSON.parse(sessionStorage.getItem('user')).ROLEID,
|
||||
pd: [],
|
||||
bus_images: [],
|
||||
imgUrl: require('@/assets/images/map.png'),
|
||||
dialogFormShow: false,
|
||||
qrcodeStr: ''
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getData()
|
||||
},
|
||||
methods: {
|
||||
getData() {
|
||||
requestFN(
|
||||
'/corpinfo/goEdit',
|
||||
{
|
||||
CORPINFO_ID: this.$parent.CORPINFO_ID,
|
||||
AGENCY_MANAGEMENT_ID: this.$parent.AGENCY_MANAGEMENT_ID,
|
||||
tm: new Date().getTime()
|
||||
}
|
||||
).then((data) => {
|
||||
this.pd = data.pd
|
||||
this.bus_images = data.busImgs
|
||||
this.four_images = data.fourImgs
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
|
||||
goBack() {
|
||||
this.$parent.activeName = 'CorpList'
|
||||
},
|
||||
// 修改
|
||||
handleEdit() {
|
||||
this.$parent.activeName = 'corpEdit'
|
||||
},
|
||||
chooseMap() {
|
||||
if (this.pd.CORPINFO_ID) {
|
||||
this.dialogFormShow = true
|
||||
this.qrcodeStr = this.config.weburl + 'static/qrcode/views/qiye/info.html?CORPINFO_ID=' + this.pd.CORPINFO_ID
|
||||
console.info(this.qrcodeStr)
|
||||
} else {
|
||||
this.$message.error('请重新获取二维码')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="sass" scoped>
|
||||
.table-ui
|
||||
td
|
||||
line-height: 34px
|
||||
.tbg
|
||||
width: 220px
|
||||
.img-flex
|
||||
display: flex
|
||||
.img-ui
|
||||
width: 110px
|
||||
height: 110px
|
||||
margin-right: 20px
|
||||
& img
|
||||
width: 100%
|
||||
height: 100%
|
||||
</style>
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
<template>
|
||||
<component :is="activeName" />
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import CorpEdit from './components/corpEdit'
|
||||
import CorpList from './components/corpList'
|
||||
import CorpView from './components/corpView'
|
||||
export default {
|
||||
components: {
|
||||
CorpEdit: CorpEdit,
|
||||
CorpList: CorpList,
|
||||
CorpView: CorpView
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
activeName: 'CorpList',
|
||||
CORPINFO_ID: ''
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
|
@ -58,19 +58,6 @@
|
|||
<el-cascader id="POSSESSION" ref="POSSESSION" v-model="form.POSSESSION" :options="areaList" :props="areaProps" placeholder="请选择省市县" style="width: 100%" @change="changeArea" @visible-change="changeArea1"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="监管类型" prop="REGULARTYPE">
|
||||
<Treeselect
|
||||
:options="varOList"
|
||||
:normalizer="normalizer"
|
||||
v-model="form.REGULARTYPE"
|
||||
placeholder="请选择监管类型"
|
||||
no-options-text="暂无数据"
|
||||
no-children-text="暂无数据"
|
||||
style="width: 100%;"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
|
|
@ -80,7 +67,6 @@
|
|||
v-model="form.INDUSTRYALL"
|
||||
:options="hylxList"
|
||||
:props="industryProps"
|
||||
:show-all-levels="false"
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
|
|
@ -199,6 +185,11 @@
|
|||
<el-input v-model="form.TOTALASSETS" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="密钥">
|
||||
<el-input v-model="form.CORPINFOKEY" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item label="隶属关系">
|
||||
|
|
@ -382,6 +373,65 @@
|
|||
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<template v-if="form.PERSONNEL_POSITION===0">
|
||||
<el-divider content-position="left">人员定位信息</el-divider>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="定位系统地址" prop="POST_URL">
|
||||
<el-input id="POST_URL" ref="POST_URL" v-model="form.POST_URL" maxlength="255" placeholder="请输入..." title="定位系统地址"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="账号" prop="ACCOUNT">
|
||||
<el-input id="ACCOUNT" ref="ACCOUNT" v-model="form.ACCOUNT" maxlength="255" placeholder="请输入..." title="账号"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="密码" prop="PASSWORD">
|
||||
<el-input id="PASSWORD" ref="PASSWORD" v-model="form.PASSWORD" maxlength="255" placeholder="请输入..." title="PASSWORD"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="地图格式" prop="USE_URL">
|
||||
<el-radio-group id="USE_URL" ref="USE_URL" v-model="form.USE_URL">
|
||||
<el-radio label="T">瓦片地图</el-radio>
|
||||
<el-radio label="p">倾斜摄影</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-if="form.USE_URL==='T'" :span="12">
|
||||
<el-form-item label="瓦片地址" prop="TILES3D_URL">
|
||||
<el-input id="TILES3D_URL" ref="TILES3D_URL" v-model="form.TILES3D_URL" maxlength="255" placeholder="请输入..." title="TILES3D_URL"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="定位版本" prop="PERSONNEL_TYPE">
|
||||
<el-radio-group id="PERSONNEL_TYPE" ref="PERSONNEL_TYPE" v-model="form.PERSONNEL_TYPE">
|
||||
<el-radio label="0">单体版</el-radio>
|
||||
<el-radio label="1">集团版</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-if="form.PERSONNEL_TYPE==='1'" :span="8">
|
||||
<el-form-item label="定位系统企业编码" prop="ENTERPRISE_CODE">
|
||||
<el-input id="ENTERPRISE_CODE" ref="ENTERPRISE_CODE" v-model="form.ENTERPRISE_CODE" maxlength="255" placeholder="请输入..." title="TILES3D_URL"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-if="form.PERSONNEL_TYPE==='1'" :span="8">
|
||||
<el-form-item label="根部门id" prop="DEPT_ID">
|
||||
<el-input id="DEPT_ID" ref="DEPT_ID" v-model="form.DEPT_ID" maxlength="255" placeholder="请输入..." title="TILES3D_URL"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</template>
|
||||
|
||||
<el-divider content-position="left">安全负责人信息</el-divider>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
|
|
@ -703,6 +753,7 @@ export default {
|
|||
EMPLOYEES: '', // 职工人数(人)
|
||||
AREA_COVERED: '', // 占地面积(㎡)
|
||||
TOTALASSETS: '', // 资产总额(万元)
|
||||
CORPINFOKEY: '', // 密钥
|
||||
REGCAPITAL: '', // 注册资金(万元)
|
||||
SALESREVENUE: '', // 上年度实际营收(万元)
|
||||
ANNUALPROFIT: '', // 年利润(万元)
|
||||
|
|
@ -763,30 +814,40 @@ export default {
|
|||
COUNTY: '',
|
||||
VILLAGE: '',
|
||||
CORP_EXAMINE: '1',
|
||||
WHETHER_HYGIENE: '', // 有无职业卫生信息
|
||||
WHETHER_HAZARDS: '', // 有无重大危险源
|
||||
WHETHER_SCARCE: '', // 是否有稀缺大型应急物资或设施
|
||||
WHETHER_CHEMICALS: '', // 是否涉及危化品
|
||||
WHETHER_SPECIALEQUIPMENT: '', // 有无特种设备
|
||||
WHETHER_SPECIALPEOPLE: '', // 有无特存种作业人员
|
||||
WHETHER_COALGAS: '', // 是否涉及煤气
|
||||
WHETHER_FIRE: '', // 是否属于消防重点单位
|
||||
WHETHER_CONFINED: '', // 是否在有限空间作业
|
||||
WHETHER_POWDER: '', // 是否存在涉爆粉尘作业
|
||||
WHETHER_LIGHTNING: '', // 是否涉及防雷防静电
|
||||
WHETHER_ACTINOGEN: '', // 是否持有放射源
|
||||
WHETHER_LIQUIDAMMONIA: '', // 是否涉及液氨制冷
|
||||
WHETHER_HYGIENE: 1, // 有无职业卫生信息
|
||||
WHETHER_HAZARDS: 1, // 有无重大危险源
|
||||
WHETHER_SCARCE: 1, // 是否有稀缺大型应急物资或设施
|
||||
WHETHER_CHEMICALS: 1, // 是否涉及危化品
|
||||
WHETHER_SPECIALEQUIPMENT: 1, // 有无特种设备
|
||||
WHETHER_SPECIALPEOPLE: 1, // 有无特存种作业人员
|
||||
WHETHER_COALGAS: 1, // 是否涉及煤气
|
||||
WHETHER_FIRE: 1, // 是否属于消防重点单位
|
||||
WHETHER_CONFINED: 1, // 是否在有限空间作业
|
||||
WHETHER_POWDER: 1, // 是否存在涉爆粉尘作业
|
||||
WHETHER_LIGHTNING: 1, // 是否涉及防雷防静电
|
||||
WHETHER_ACTINOGEN: 1, // 是否持有放射源
|
||||
WHETHER_LIQUIDAMMONIA: 1, // 是否涉及液氨制冷
|
||||
ISTRIAL: '0',
|
||||
WHETHER_PIPELINE: '', // 是否涉及危化品管道
|
||||
WHETHER_PIPELINE: 1, // 是否涉及危化品管道
|
||||
TRIALTIME: '',
|
||||
jinweidu: '',
|
||||
AGENT_NUMBER_ID: '',
|
||||
WHETHER_PRE_SALE_SERVICE: '',
|
||||
WHETHER_AFTER_SALES_SERVICE: '',
|
||||
VIPLEVEL: '',
|
||||
MARKETING_PERSON: '',
|
||||
PERSONNEL_POSITION: 0,
|
||||
MARKETING_PERSON: this.USER_ID,
|
||||
STATUS: '',
|
||||
VIP_GEAR: ''
|
||||
VIP_GEAR: '',
|
||||
|
||||
// 人员定位
|
||||
POST_URL: '',
|
||||
ACCOUNT: '',
|
||||
PASSWORD: '',
|
||||
USE_URL: 'p',
|
||||
PERSONNEL_TYPE: '0',
|
||||
DEPT_ID: '',
|
||||
TILES3D_URL: ''
|
||||
},
|
||||
vipGearList: [],
|
||||
MARKETING_PERSON: '',
|
||||
|
|
@ -809,6 +870,15 @@ export default {
|
|||
VIPLEVEL: [
|
||||
{ required: true, message: '会员级别不能为空', trigger: 'blur' }
|
||||
],
|
||||
PERSONNEL_TYPE: [
|
||||
{ required: true, message: '定位版本不能为空', trigger: 'blur' }
|
||||
],
|
||||
ENTERPRISE_CODE: [
|
||||
{ required: true, message: '企业编码不能为空', trigger: 'blur' }
|
||||
],
|
||||
DEPT_ID: [
|
||||
{ required: true, message: '根部门ID不能为空', trigger: 'blur' }
|
||||
],
|
||||
// AGENT_NUMBER_ID: [
|
||||
// { required: true, message: '会员级别不能为空', trigger: 'blur' }
|
||||
// ],
|
||||
|
|
@ -897,7 +967,12 @@ export default {
|
|||
pattern: /^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$/,
|
||||
message: '请输入正确的手机号码'
|
||||
}
|
||||
]
|
||||
],
|
||||
POST_URL: [{ required: true, message: '人员定位URL不能为空', trigger: 'blur' }],
|
||||
ACCOUNT: [{ required: true, message: '账号不能为空', trigger: 'blur' }],
|
||||
PASSWORD: [{ required: true, message: '密码不能为空', trigger: 'blur' }],
|
||||
USE_URL: [{ required: true, message: '人员定位URL不能为空', trigger: 'blur' }],
|
||||
TILES3D_URL: [{ required: true, message: '人员定位URL不能为空', trigger: 'blur' }]
|
||||
|
||||
// CITY: [
|
||||
// { required: true, message: '市不能为空', trigger: 'blur' }
|
||||
|
|
@ -940,23 +1015,20 @@ export default {
|
|||
label: 'label',
|
||||
children: 'children'
|
||||
},
|
||||
// agentNumList: [],
|
||||
agentNumList: [],
|
||||
// AGENT_NUMBER_ID: '',
|
||||
msg: 'edit',
|
||||
isAdmin: false
|
||||
}
|
||||
},
|
||||
// watch: {
|
||||
// 'form.AGENT_NUMBER_ID': {
|
||||
// handler() {
|
||||
// }
|
||||
// }
|
||||
// 'form.CITY': {
|
||||
// handler() {
|
||||
// this.getCountyList()
|
||||
// }
|
||||
// }
|
||||
// },
|
||||
watch: {
|
||||
'form.VIPLEVEL': {
|
||||
handler() {
|
||||
var HAS_PLS = this.agentNumList.find(item => item.ROLE_ID == this.form.VIPLEVEL).HAS_PLS
|
||||
this.form.PERSONNEL_POSITION = (HAS_PLS === 0 ? 1 : 0)
|
||||
}
|
||||
}
|
||||
},
|
||||
async created() {
|
||||
const loading = this.$loading({
|
||||
lock: true,
|
||||
|
|
@ -972,23 +1044,22 @@ export default {
|
|||
await this.getAreaDict('e725d2a91b8248f4b8f49889038df7de', '0').then(data => {
|
||||
this.areaList = data
|
||||
})
|
||||
await this.getDictByDicId('f2598ba72e864eadabf0ca4b664d26b9').then(data => {
|
||||
this.hylxList = data
|
||||
})
|
||||
this.getDictByDicId('688d2cf1c6cd4dab999a0106e09aec83').then(data => {
|
||||
this.jjlxList = data
|
||||
})
|
||||
await this.getTrainDicList()
|
||||
// this.getAgentAreaList()
|
||||
this.getAgentList()
|
||||
if (this.$parent.CORPINFO_ID) {
|
||||
this.CORPINFO_ID = this.$parent.CORPINFO_ID
|
||||
this.getData()
|
||||
this.getUserList()
|
||||
} else {
|
||||
this.msg = 'add'
|
||||
this.getDictByDicId('688d2cf1c6cd4dab999a0106e09aec83').then(data => {
|
||||
this.jjlxList = data
|
||||
})
|
||||
this.getDictByDicId('f2598ba72e864eadabf0ca4b664d26b9').then(data => {
|
||||
this.hylxList = data
|
||||
})
|
||||
this.getUserList()
|
||||
}
|
||||
this.getUserList()
|
||||
// this.getHylx()
|
||||
// this.getJjlx()
|
||||
// this.getDict()
|
||||
|
|
@ -1072,20 +1143,6 @@ export default {
|
|||
this.changeArea()
|
||||
this.form.REGULARTYPE = null
|
||||
},
|
||||
// changeArea1(event) {
|
||||
// if (event) {
|
||||
// this.unwatch = this.$watch(() => this.varOList, (newValue, oldValue) => {
|
||||
// if (newValue && oldValue) {
|
||||
// this.form.REGULARTYPE = null
|
||||
// }
|
||||
// }, { immediate: true })
|
||||
// } else {
|
||||
// if (this.unwatch) {
|
||||
// this.unwatch()
|
||||
// this.unwatch = null
|
||||
// }
|
||||
// }
|
||||
// },
|
||||
handleMap() {
|
||||
this.dialogFormMap = true
|
||||
this.LATITUDE = this.form.LATITUDE
|
||||
|
|
@ -1100,11 +1157,7 @@ export default {
|
|||
this.dialogFormMap = false
|
||||
this.$set(this.form, 'LATITUDE', this.LATITUDE)
|
||||
this.$set(this.form, 'LONGITUDE', this.LONGITUDE)
|
||||
// this.form.LATITUDE = this.LATITUDE
|
||||
// this.form.LONGITUDE = this.LONGITUDE
|
||||
// this.$forceUpdate()
|
||||
},
|
||||
|
||||
getData() {
|
||||
requestFN(
|
||||
'/corpinfo/goEdit',
|
||||
|
|
@ -1115,14 +1168,16 @@ export default {
|
|||
}
|
||||
).then(async(data) => {
|
||||
const POSSESSION = data.pd.POSSESSION
|
||||
const INDUSTRYALL = data.pd.INDUSTRYALL
|
||||
await this.getAreaOpts(POSSESSION, this.areaList, 0)
|
||||
await this.getHylxOpts(INDUSTRYALL, this.hylxList, 0)
|
||||
console.log(this.hylxList)
|
||||
this.OLDFOURTYPE = data.pd.FOURTYPE
|
||||
data.pd.MARKETING_PERSON = data.pd.MARKETING_PERSON || ''
|
||||
data.pd.MARKETING_PERSON = data.pd.MARKETING_PERSON || this.USER_ID
|
||||
if (data.pd.MARKETING_PERSON == null || data.pd.MARKETING_PERSON == '') {
|
||||
this.isOldData = '1'
|
||||
}
|
||||
this.form = data.pd
|
||||
console.log(this.form)
|
||||
this.changeArea()
|
||||
this.form.FOURTYPE = data.pd.FOURTYPE ? data.pd.FOURTYPE + '' : '1'
|
||||
if (data.pd.ecoOption && data.pd.ecoOption.length > 0) {
|
||||
|
|
@ -1132,33 +1187,21 @@ export default {
|
|||
this.jjlxList = data
|
||||
})
|
||||
}
|
||||
if (data.pd.industryOption && data.pd.industryOption.length > 0) {
|
||||
this.hylxList = data.pd.industryOption
|
||||
} else {
|
||||
this.getDictByDicId('f2598ba72e864eadabf0ca4b664d26b9').then(data => {
|
||||
this.hylxList = data
|
||||
})
|
||||
}
|
||||
// if (data.pd.posOption && data.pd.posOption.length > 0) {
|
||||
// this.areaList = data.pd.posOption
|
||||
// if (data.pd.industryOption && data.pd.industryOption.length > 0) {
|
||||
// this.hylxList = data.pd.industryOption
|
||||
// } else {
|
||||
// this.getDictByDicId('f2598ba72e864eadabf0ca4b664d26b9').then(data => {
|
||||
// this.hylxList = data
|
||||
// })
|
||||
// }
|
||||
|
||||
// this.hylxList = data.pd.industryOption
|
||||
|
||||
this.$nextTick(() => {
|
||||
this.$refs.ecoCascader.presentText = this.censusRegisterPlaceName
|
||||
})
|
||||
if (this.form.CORP_OF_TYPE2 && this.form.CORP_OF_TYPE2 != '') {
|
||||
const node = {}
|
||||
node.id = this.form.CORP_OF_TYPE2
|
||||
this.$nextTick(() => {
|
||||
this.$refs.corpOfTypeRef.handleNodeClick(node)
|
||||
})
|
||||
} else if (this.form.CORP_OF_TYPE && this.form.CORP_OF_TYPE != '') {
|
||||
if (this.form.CORP_OF_TYPE && this.form.CORP_OF_TYPE != '') {
|
||||
const node = {}
|
||||
node.id = this.form.CORP_OF_TYPE
|
||||
this.$nextTick(() => {
|
||||
this.$refs.corpOfTypeRef.handleNodeClick(node)
|
||||
this.$refs.industryCascader.handleNodeClick(node)
|
||||
})
|
||||
}
|
||||
const nodea = {}
|
||||
|
|
@ -1198,6 +1241,25 @@ export default {
|
|||
resolve()
|
||||
})
|
||||
},
|
||||
async getHylxOpts(values, list, index) {
|
||||
return new Promise(async(resolve, reject) => {
|
||||
let areaOpt = null
|
||||
let areaIndex = null
|
||||
list.forEach((item, k) => {
|
||||
if (item.id === values[index]) {
|
||||
areaOpt = item
|
||||
areaIndex = k
|
||||
}
|
||||
})
|
||||
areaOpt.children = await this.getDictByDicId(areaOpt.id)
|
||||
|
||||
if (values[index + 1]) {
|
||||
await this.getHylxOpts(values, areaOpt.children, index + 1)
|
||||
}
|
||||
this.$set(list, areaIndex, areaOpt)
|
||||
resolve()
|
||||
})
|
||||
},
|
||||
|
||||
deleteImage(index) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
|
|
@ -1244,217 +1306,121 @@ export default {
|
|||
})
|
||||
},
|
||||
confirm() {
|
||||
if (this.bus_images.length + this.$refs.upload.uploadFiles.length < 1) {
|
||||
this.$message({
|
||||
message: '请上传营业执照',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
if (this.form.ISTRIAL == 0) {
|
||||
this.form.STATUS = 2
|
||||
if (!this.form.TRIALTIME) {
|
||||
this.$confirm('此操作重置该企业主账号密码为Aa@123456, 是否继续?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
if (this.bus_images.length + this.$refs.upload.uploadFiles.length < 1) {
|
||||
this.$message({
|
||||
message: '请填写试用企业天数',
|
||||
message: '请上传营业执照',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
} else {
|
||||
this.form.STATUS = 1
|
||||
}
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
const loading = this.$loading({
|
||||
lock: true,
|
||||
text: '提交中...',
|
||||
spinner: 'el-icon-loading',
|
||||
background: 'rgba(0, 0, 0, 0.7)'
|
||||
})
|
||||
// this.form.COMPANY_AREA = this.$refs.PROVINCE.selected.label + this.$refs.CITY.selected.label + this.$refs.COUNTY.selected.label
|
||||
if (this.form.POSSESSION && this.form.POSSESSION.length > 0) {
|
||||
this.form.PROVINCE = this.form.POSSESSION[0] || ''
|
||||
this.form.CITY = this.form.POSSESSION[1] || ''
|
||||
this.form.COUNTY = this.form.POSSESSION[2] || ''
|
||||
this.form.VILLAGE = this.form.POSSESSION[3] || ''
|
||||
this.form.STREET = this.form.POSSESSION[4] || ''
|
||||
this.form.COMPANY_AREA = this.$refs.POSSESSION.getCheckedNodes()[0].pathLabels ? this.$refs.POSSESSION.getCheckedNodes()[0].pathLabels.join('') : ''
|
||||
if (this.form.ISTRIAL == 0) {
|
||||
this.form.STATUS = 2
|
||||
if (!this.form.TRIALTIME) {
|
||||
this.$message({
|
||||
message: '请填写试用企业天数',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
this.form.SMALL = '2'
|
||||
if (this.form.ECO_TYPEALL && this.form.ECO_TYPEALL.length > 0) {
|
||||
this.form.ECO_TYPE = this.form.ECO_TYPEALL[0] || ''
|
||||
this.form.ECO_TYPE2 = this.form.ECO_TYPEALL[1] || ''
|
||||
this.form.ECO_TYPE_NAME = this.$refs.ecoCascader.getCheckedNodes()[0].pathLabels ? this.$refs.ecoCascader.getCheckedNodes()[0].pathLabels.join('/') : ''
|
||||
}
|
||||
if (this.form.INDUSTRYALL && this.form.INDUSTRYALL.length > 0) {
|
||||
this.form.CORP_TYPE = this.form.INDUSTRYALL[0] || ''
|
||||
this.form.CORP_TYPE2 = this.form.INDUSTRYALL[1] || ''
|
||||
this.form.CORP_TYPE3 = this.form.INDUSTRYALL[2] || ''
|
||||
this.form.CORP_TYPE4 = this.form.INDUSTRYALL[3] || ''
|
||||
this.form.CORP_TYPE_NAME = this.$refs.industryCascader.getCheckedNodes()[0].pathLabels ? this.$refs.industryCascader.getCheckedNodes()[0].pathLabels.join('/') : ''
|
||||
}
|
||||
// this.form.ECO_TYPE = this.form.ECO_TYPEALL[this.form.ECO_TYPEALL.length - 1]
|
||||
// this.form.INDUSTRY = this.form.INDUSTRYALL[this.form.INDUSTRYALL.length - 1]
|
||||
} else {
|
||||
this.form.STATUS = 1
|
||||
}
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
const loading = this.$loading({
|
||||
lock: true,
|
||||
text: '提交中...',
|
||||
spinner: 'el-icon-loading',
|
||||
background: 'rgba(0, 0, 0, 0.7)'
|
||||
})
|
||||
|
||||
const formData = new FormData()
|
||||
Object.keys(this.form).map(key => {
|
||||
formData.append(key, this.form[key])
|
||||
})
|
||||
console.log(this.form.REGULARTYPE)
|
||||
if (this.$refs.upload.uploadFiles.length > 0) {
|
||||
for (var i = 0; i < this.$refs.upload.uploadFiles.length; i++) {
|
||||
if (this.$refs.upload.uploadFiles[i]) {
|
||||
formData.append('imgFiles', this.$refs.upload.uploadFiles[i].raw)
|
||||
}
|
||||
if (this.form.POSSESSION && this.form.POSSESSION.length > 0) {
|
||||
this.form.PROVINCE = this.form.POSSESSION[0] || ''
|
||||
this.form.CITY = this.form.POSSESSION[1] || ''
|
||||
this.form.COUNTY = this.form.POSSESSION[2] || ''
|
||||
this.form.VILLAGE = this.form.POSSESSION[3] || ''
|
||||
this.form.STREET = this.form.POSSESSION[4] || ''
|
||||
this.form.COMPANY_AREA = this.$refs.POSSESSION.getCheckedNodes()[0].pathLabels ? this.$refs.POSSESSION.getCheckedNodes()[0].pathLabels.join('') : ''
|
||||
}
|
||||
}
|
||||
if (this.form.FOURTYPE == '1') {
|
||||
if (this.$refs.fourUpload.uploadFiles.length > 0) {
|
||||
// eslint-disable-next-line no-redeclare
|
||||
for (var i = 0; i < this.$refs.fourUpload.uploadFiles.length; i++) {
|
||||
if (this.$refs.fourUpload.uploadFiles[i]) {
|
||||
formData.append('fourFiles', this.$refs.fourUpload.uploadFiles[i].raw)
|
||||
this.form.SMALL = '2'
|
||||
if (this.form.ECO_TYPEALL && this.form.ECO_TYPEALL.length > 0) {
|
||||
this.form.ECO_TYPE = this.form.ECO_TYPEALL[0] || ''
|
||||
this.form.ECO_TYPE2 = this.form.ECO_TYPEALL[1] || ''
|
||||
this.form.ECO_TYPE_NAME = this.$refs.ecoCascader.getCheckedNodes()[0].pathLabels ? this.$refs.ecoCascader.getCheckedNodes()[0].pathLabels.join('/') : ''
|
||||
}
|
||||
|
||||
if (this.form.INDUSTRYALL && this.form.INDUSTRYALL.length > 0) {
|
||||
this.form.CORP_TYPE = this.form.INDUSTRYALL[0] || ''
|
||||
this.form.CORP_TYPE2 = this.form.INDUSTRYALL[1] || ''
|
||||
this.form.CORP_TYPE3 = this.form.INDUSTRYALL[2] || ''
|
||||
this.form.CORP_TYPE4 = this.form.INDUSTRYALL[3] || ''
|
||||
// .pathLabels
|
||||
this.form.CORP_TYPE_NAME = this.$refs.industryCascader.getCheckedNodes()[0] ? this.$refs.industryCascader.getCheckedNodes()[0].pathLabels.join('/') : ''
|
||||
}
|
||||
|
||||
const formData = new FormData()
|
||||
Object.keys(this.form).map(key => {
|
||||
formData.append(key, this.form[key])
|
||||
})
|
||||
|
||||
if (this.$refs.upload.uploadFiles.length > 0) {
|
||||
for (var i = 0; i < this.$refs.upload.uploadFiles.length; i++) {
|
||||
if (this.$refs.upload.uploadFiles[i]) {
|
||||
formData.append('imgFiles', this.$refs.upload.uploadFiles[i].raw)
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (this.form.FOURTYPE == '2') {
|
||||
formData.append('fourFiles', this.FFILE)
|
||||
}
|
||||
|
||||
formData.append('isOldData', this.isOldData)
|
||||
formData.append('EDITFOURTYPE', this.form.FOURTYPE == this.OLDFOURTYPE)
|
||||
upload(
|
||||
'/corpinfo/' + this.msg,
|
||||
formData
|
||||
).then((data) => {
|
||||
loading.close()
|
||||
if (data.message) {
|
||||
this.$message({
|
||||
message: data.message,
|
||||
type: 'warning'
|
||||
})
|
||||
} else {
|
||||
this.$message({
|
||||
message: '操作成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.$parent.activeName = 'CorpList'
|
||||
if (this.form.FOURTYPE == '1') {
|
||||
if (this.$refs.fourUpload.uploadFiles.length > 0) {
|
||||
// eslint-disable-next-line no-redeclare
|
||||
for (var i = 0; i < this.$refs.fourUpload.uploadFiles.length; i++) {
|
||||
if (this.$refs.fourUpload.uploadFiles[i]) {
|
||||
formData.append('fourFiles', this.$refs.fourUpload.uploadFiles[i].raw)
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (this.form.FOURTYPE == '2') {
|
||||
formData.append('fourFiles', this.FFILE)
|
||||
}
|
||||
}).catch((e) => {
|
||||
loading.close()
|
||||
this.$message({
|
||||
message: '操作失败',
|
||||
type: 'error'
|
||||
|
||||
formData.append('isOldData', this.isOldData)
|
||||
formData.append('EDITFOURTYPE', this.form.FOURTYPE == this.OLDFOURTYPE)
|
||||
|
||||
upload(
|
||||
'/corpinfo/' + this.msg,
|
||||
formData
|
||||
).then((data) => {
|
||||
loading.close()
|
||||
if (data.message) {
|
||||
this.$message({
|
||||
message: data.message,
|
||||
type: 'warning'
|
||||
})
|
||||
} else {
|
||||
this.$message({
|
||||
message: '操作成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.$parent.activeName = 'CorpList'
|
||||
}
|
||||
}).catch((e) => {
|
||||
loading.close()
|
||||
this.$message({
|
||||
message: '操作失败',
|
||||
type: 'error'
|
||||
})
|
||||
}).finally(() => {
|
||||
loading.close()
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
})
|
||||
},
|
||||
// uploadImg() {
|
||||
// this.$refs.upload.submit()
|
||||
// const loading = this.$loading({
|
||||
// lock: true,
|
||||
// text: '上传中...',
|
||||
// spinner: 'el-icon-loading',
|
||||
// background: 'rgba(0, 0, 0, 0.7)'
|
||||
// })
|
||||
// const formData = new FormData()
|
||||
// for (var i = 0; i < this.$refs.upload.uploadFiles.length; i++) {
|
||||
// if (this.$refs.upload.uploadFiles[i]) {
|
||||
// formData.append('FFILE', this.$refs.upload.uploadFiles[i])
|
||||
// }
|
||||
// }
|
||||
// formData.append('FOREIGN_KEY', this.form.CORPINFO_ID)
|
||||
// formData.append('TYPE', 1)
|
||||
// upload(
|
||||
// '/imgfiles/add',
|
||||
// formData
|
||||
// ).then((data) => {
|
||||
// loading.close()
|
||||
// if (this.form.FOURTYPE == '1' && this.$refs.fourUpload.uploadFiles.length > 0) {
|
||||
// this.uploadFourImg()
|
||||
// } else if (this.form.FOURTYPE == '2' && this.FFILE != null && this.FFILE.length > 0) {
|
||||
// this.uploadFourFile()
|
||||
// } else {
|
||||
// this.$message({
|
||||
// message: '操作成功',
|
||||
// type: 'success'
|
||||
// })
|
||||
// this.$parent.activeName = 'CorpList'
|
||||
// }
|
||||
// }).catch((e) => {
|
||||
// loading.close()
|
||||
// this.$message({
|
||||
// message: '营业执照上传失败',
|
||||
// type: 'error'
|
||||
// })
|
||||
// })
|
||||
// },
|
||||
// uploadFourImg() {
|
||||
// this.$refs.fourUpload.submit()
|
||||
// const loading = this.$loading({
|
||||
// lock: true,
|
||||
// text: '上传中...',
|
||||
// spinner: 'el-icon-loading',
|
||||
// background: 'rgba(0, 0, 0, 0.7)'
|
||||
// })
|
||||
// const formData = new FormData()
|
||||
// for (var i = 0; i < this.four_files.length; i++) {
|
||||
// if (this.four_files[i]) {
|
||||
// formData.append('FFILE', this.four_files[i])
|
||||
// }
|
||||
// }
|
||||
// formData.append('FOREIGN_KEY', this.form.CORPINFO_ID)
|
||||
// formData.append('TYPE', 2)
|
||||
// formData.append('EDITFOURTYPE', this.form.FOURTYPE == this.OLDFOURTYPE)
|
||||
// upload(
|
||||
// '/imgfiles/add',
|
||||
// formData
|
||||
// ).then((data) => {
|
||||
// loading.close()
|
||||
// this.$message({
|
||||
// message: '操作成功',
|
||||
// type: 'success'
|
||||
// })
|
||||
// this.$parent.activeName = 'CorpList'
|
||||
// }).catch((e) => {
|
||||
// loading.close()
|
||||
// this.$message({
|
||||
// message: '四色图上传失败',
|
||||
// type: 'error'
|
||||
// })
|
||||
// })
|
||||
// },
|
||||
// uploadFourFile() {
|
||||
// const loading = this.$loading({
|
||||
// lock: true,
|
||||
// text: '上传中...',
|
||||
// spinner: 'el-icon-loading',
|
||||
// background: 'rgba(0, 0, 0, 0.7)'
|
||||
// })
|
||||
// const formData = new FormData()
|
||||
// formData.append('FFILE', this.FFILE)
|
||||
// formData.append('FOREIGN_KEY', this.form.CORPINFO_ID)
|
||||
// formData.append('TYPE', 2)
|
||||
// formData.append('EDITFOURTYPE', this.form.FOURTYPE == this.OLDFOURTYPE)
|
||||
// upload(
|
||||
// '/imgfiles/add',
|
||||
// formData
|
||||
// ).then((data) => {
|
||||
// loading.close()
|
||||
// this.$message({
|
||||
// message: '操作成功',
|
||||
// type: 'success'
|
||||
// })
|
||||
// this.$parent.activeName = 'CorpList'
|
||||
// }).catch((e) => {
|
||||
// loading.close()
|
||||
// this.$message({
|
||||
// message: '四色图上传失败',
|
||||
// type: 'error'
|
||||
// })
|
||||
// })
|
||||
// },
|
||||
beforeFileUpload(file, fileList) {
|
||||
const types = ['image/jpeg', 'image/jpg', 'image/png']
|
||||
const isImage = types.includes(file.raw.type)
|
||||
|
|
@ -1573,7 +1539,7 @@ export default {
|
|||
}
|
||||
).then((data) => {
|
||||
this.corpFoTypeList = JSON.parse(data.zTreeNodes)
|
||||
console.log(this.corpFoTypeList)
|
||||
|
||||
resolve()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
|
|
|
|||
|
|
@ -9,52 +9,6 @@
|
|||
<el-input v-model="KEYWORDS" placeholder="搜索" class="filter-item"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable">
|
||||
属地:
|
||||
</div>
|
||||
<div class="filter-width">
|
||||
<el-cascader id="POSSESSION" ref="POSSESSION" v-model="POSSESSION" :options="areaList" :props="areaProps" placeholder="请选择属地"/>
|
||||
<!-- <el-date-picker v-model="dates" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd" format="yyyy-MM-dd" class="filter-item" />-->
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="filter-group">-->
|
||||
<!-- <div class="filter-lable">-->
|
||||
<!-- 有效期:-->
|
||||
<!-- </div>-->
|
||||
<!-- <div class="filter-width">-->
|
||||
<!-- <el-select v-model="VALIDITY" placeholder="请选择">-->
|
||||
<!-- <el-option v-for="item in validityList" :key="item.ID" :label="item.NAME" :value="item.ID" />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<!-- <div class="filter-group">-->
|
||||
<!-- <div class="filter-lable">-->
|
||||
<!-- 状态:-->
|
||||
<!-- </div>-->
|
||||
<!-- <div class="filter-width">-->
|
||||
<!-- <el-select v-model="STEP" placeholder="请选择">-->
|
||||
<!-- <el-option v-for="item in stepList" :key="item.ID" :label="item.NAME" :value="item.ID" />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<div class="filter-group">
|
||||
<div class="filter-lable">
|
||||
交付日期:
|
||||
</div>
|
||||
<div class="filter-date">
|
||||
<el-date-picker v-model="dates" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd" format="yyyy-MM-dd" class="filter-item" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <div class="filter-group mr-10">-->
|
||||
<!-- <div class="filter-lable">-->
|
||||
<!-- 开户人:-->
|
||||
<!-- </div>-->
|
||||
<!-- <div class="filter-width">-->
|
||||
<!-- <el-input v-model="CREATOR" placeholder="开户人" class="filter-item" />-->
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<div :style="{'margin-top': searchFromCollapse ? '0px' : '10px'}" class="filter-group">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
|
|
@ -90,37 +44,15 @@
|
|||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="CORP_NAME" label="企业名称" />
|
||||
<el-table-column prop="CREATTIME" label="开户日期" />
|
||||
<el-table-column prop="DELIVERDATE" label="交付日期" />
|
||||
<el-table-column prop="USE_DATE_END" label="到期时间" />
|
||||
<!-- <el-table-column prop="MARKETING_PERSON" label="市场人员" />-->
|
||||
<!-- <el-table-column prop="PROJECT_LEADER" label="项目负责人" />-->
|
||||
<!-- <el-table-column prop="IMPLEMENTATION_PERRON" label="实施人员" />-->
|
||||
<!-- <el-table-column prop="MAINTENANCE_PERSON" label="运维人员" />-->
|
||||
<!-- <el-table-column prop="AGENCY_NAME" label="代理机构" >-->
|
||||
<!-- <template slot-scope="{row}">-->
|
||||
<!-- <template v-if="row.AGENCY_NAME">-->
|
||||
<!-- <div>{{ row.AGENCY_NAME }}</div>-->
|
||||
<!-- </template>-->
|
||||
<!-- <template v-else>-->
|
||||
<!-- <div>平台</div>-->
|
||||
<!-- </template>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
|
||||
<el-table-column prop="COMPANY_AREA" label="所属区域" />
|
||||
<el-table-column prop="VIPLEVELNAME" label="会员级别" />
|
||||
<!-- <el-table-column prop="STEP" label="状态" />-->
|
||||
|
||||
<el-table-column label="操作" align="left" width="680">
|
||||
<el-table-column label="操作" width="380" align="center" >
|
||||
<template slot-scope="{row}">
|
||||
<el-button v-show="edit" class="light-blue-btn" icon="el-icon-plus" size="mini" @click="goLogin(row.CORPINFO_ID)">登入</el-button>
|
||||
<el-button v-show="edit" type="primary" icon="el-icon-refresh" size="mini" @click="resetPwd(row.CORPINFO_ID)">重置密码</el-button>
|
||||
<el-button type="warning" icon="el-icon-edit" size="mini" @click="handleEdit(row)">查看</el-button>
|
||||
<el-button type="success" icon="el-icon-view" size="mini" @click="handleShow(row)">查看</el-button>
|
||||
<el-button type="warning" icon="el-icon-edit" size="mini" @click="handleEdit(row)">编辑</el-button>
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.CORPINFO_ID)">删除</el-button>
|
||||
<el-button v-if="row.ISUSE=='0'" type="danger" icon="el-icon-delete" size="mini" @click="updateISuse(row.CORPINFO_ID)">禁用</el-button>
|
||||
<el-button v-if="row.ISUSE=='1'" type="success" icon="el-icon-delete" size="mini" @click="goupdateISuse(row.CORPINFO_ID)">启用</el-button>
|
||||
<el-button v-if="row.STATUS ==1" type="info" icon="el-icon-video-pause" size="mini" @click="editStatus(row.CORPINFO_ID)">停用</el-button>
|
||||
<el-button v-if="row.ISDELIVER ==0" type="success" icon="el-icon-finished" size="mini" @click="goDeliver(row.CORPINFO_ID)">交付</el-button>
|
||||
<el-button v-if="row.ISDELIVER ==1 && row.REMAININGTIME <= 90" class="pink-btn " icon="el-icon-finished" size="mini" @click="goRenew(row.CORPINFO_ID)">续费</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
|
@ -180,7 +112,6 @@
|
|||
|
||||
<el-dialog :visible.sync="dialogFormStop" title="停用" width="600px">
|
||||
<el-form ref="form" :rules="stopRules" :model="form" label-width="110px" style="width: 500px;">
|
||||
|
||||
<el-form-item label="停用原因:" prop="STOPREASON">
|
||||
<el-input v-model="form.STOPREASON" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
|
|
@ -190,7 +121,6 @@
|
|||
<el-button type="primary" @click="goStop()">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog :visible.sync="dialogFormEdit" :title="dialogType==='edit'?'修改':'新增'" width="600px">
|
||||
<el-form ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item label="有效使用起始时间" prop="USE_DATE_START">
|
||||
|
|
@ -357,13 +287,6 @@ export default {
|
|||
})
|
||||
},
|
||||
methods: {
|
||||
|
||||
// keyWords(item) {
|
||||
// return item.NAME.replace(
|
||||
// new RegExp(this.inputmarket, 'g'),
|
||||
// )
|
||||
// },
|
||||
// 加载级联的方法
|
||||
lazyLoad(nodeValue, resolve) {
|
||||
if (nodeValue.data && (!nodeValue.children || nodeValue.children.length == 0)) {
|
||||
this.getDictByDicId(nodeValue.data.id).then(data => {
|
||||
|
|
@ -558,10 +481,14 @@ export default {
|
|||
this.$parent.CORPINFO_ID = ''
|
||||
this.$parent.activeName = 'corpEdit'
|
||||
},
|
||||
handleShow(row) {
|
||||
this.$parent.CORPINFO_ID = row.CORPINFO_ID
|
||||
this.$parent.activeName = 'corpView'
|
||||
},
|
||||
// 修改
|
||||
handleEdit(row) {
|
||||
this.$parent.CORPINFO_ID = row.CORPINFO_ID
|
||||
this.$parent.activeName = 'corpView'
|
||||
this.$parent.activeName = 'corpEdit'
|
||||
},
|
||||
// 保存
|
||||
confirm() {
|
||||
|
|
@ -780,7 +707,7 @@ export default {
|
|||
})
|
||||
},
|
||||
resetPwd(id) {
|
||||
this.$confirm('确定要进行密码重置吗?', {
|
||||
this.$confirm('确定要进行密码重置吗?默认密码为Aa@123456', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
|
|
|
|||
|
|
@ -27,8 +27,10 @@
|
|||
<tr>
|
||||
<td class="tbg">属地</td>
|
||||
<td >{{ pd.COMPANY_AREA }}</td>
|
||||
<td class="tbg">监管类型</td>
|
||||
<td>{{ pd.REGULARTYPE_NAME }}</td>
|
||||
<!-- <td class="tbg">监管类型</td>-->
|
||||
<!-- <td>{{ pd.REGULARTYPE_NAME }}</td>-->
|
||||
<td class="tbg"/>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tbg">经济类型</td>
|
||||
|
|
@ -258,7 +260,7 @@
|
|||
</div>
|
||||
<div class="ui-height" />
|
||||
<div class="ui-foot">
|
||||
<el-button type="primary" icon="el-icon-edit" @click="handleEdit(row)">修改</el-button>
|
||||
<el-button type="primary" icon="el-icon-edit" @click="handleEdit">修改</el-button>
|
||||
<el-button type="info" @click="goBack">返回</el-button>
|
||||
</div>
|
||||
|
||||
|
|
@ -309,7 +311,7 @@ export default {
|
|||
this.$parent.activeName = 'CorpList'
|
||||
},
|
||||
// 修改
|
||||
handleEdit(row) {
|
||||
handleEdit() {
|
||||
this.$parent.activeName = 'corpEdit'
|
||||
},
|
||||
chooseMap() {
|
||||
|
|
|
|||
|
|
@ -69,12 +69,12 @@
|
|||
<el-input-number :min="0" v-model="form.sort" style="width: 100%;" controls-position="right" autocomplete="off" placeholder="这里输入排序..." />
|
||||
</el-form-item>
|
||||
<!-- v-if="!isEditGroup" -->
|
||||
<el-form-item :label="insertLabel">
|
||||
<el-radio-group v-model="form.isMain">
|
||||
<el-radio :label="'1'">是</el-radio>
|
||||
<el-radio :label="'0'">否</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item :label="insertLabel">-->
|
||||
<!-- <el-radio-group v-model="form.isMain" >-->
|
||||
<!-- <el-radio :label="'1'">是</el-radio>-->
|
||||
<!-- <el-radio :label="'0'">否</el-radio>-->
|
||||
<!-- </el-radio-group>-->
|
||||
<!-- </el-form-item>-->
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormVisible = false">取 消</el-button>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,8 @@
|
|||
<el-button type="primary" icon="el-icon-document-add" @click="handleCreate(0)">新增组</el-button>
|
||||
<el-button type="primary" icon="el-icon-edit" @click="handleUpdate()">修改组</el-button>
|
||||
<el-button v-if="ROLE_ID!=1" type="primary" icon="el-icon-delete" @click="handleDelete()">删除组</el-button>
|
||||
<el-button type="primary" icon="el-icon-collection-tag" @click="handleTree('routeqx',activeTab)">账号菜单权限</el-button>
|
||||
<el-button type="primary" icon="el-icon-collection-tag" @click="handleTree('routeqx',activeTab)">账号菜单权限
|
||||
</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<el-tabs v-model="activeTab" type="border-card" @tab-click="handleClick">
|
||||
|
|
@ -20,34 +21,48 @@
|
|||
border
|
||||
fit
|
||||
highlight-current-row>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="role_NAME" label="角色" width="180" />
|
||||
<el-table-column prop="rnumber" label="编码" />
|
||||
<el-table-column label="增" align="center" width="60">
|
||||
<template slot-scope="{row}">
|
||||
<el-button icon="el-icon-document-add" circle @click="handleTree('routeqxButton',row.role_ID,'add_qx')" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="删" align="center" width="60">
|
||||
<template slot-scope="{row}">
|
||||
<el-button icon="el-icon-delete" circle @click="handleTree('routeqxButton',row.role_ID,'del_qx')"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="改" align="center" width="60">
|
||||
<template slot-scope="{row}">
|
||||
<el-button icon="el-icon-edit" circle @click="handleTree('routeqxButton',row.role_ID,'edit_qx')"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="查" align="center" width="60">
|
||||
<template slot-scope="{row}">
|
||||
<el-button icon="el-icon-view" circle @click="handleTree('routeqxButton',row.role_ID,'cha_qx')"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" width="290">
|
||||
<el-table-column type="index" label="序号" width="50" align="center"/>
|
||||
<el-table-column prop="role_NAME" label="角色" width="180"/>
|
||||
<el-table-column prop="rnumber" label="编码"/>
|
||||
<!-- <el-table-column label="增" align="center" width="60">-->
|
||||
<!-- <template slot-scope="{row}">-->
|
||||
<!-- <el-button icon="el-icon-document-add" circle @click="handleTree('routeqxButton',row.role_ID,'add_qx')"/>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<!-- <el-table-column label="删" align="center" width="60">-->
|
||||
<!-- <template slot-scope="{row}">-->
|
||||
<!-- <el-button icon="el-icon-delete" circle @click="handleTree('routeqxButton',row.role_ID,'del_qx')"/>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<!-- <el-table-column label="改" align="center" width="60">-->
|
||||
<!-- <template slot-scope="{row}">-->
|
||||
<!-- <el-button icon="el-icon-edit" circle @click="handleTree('routeqxButton',row.role_ID,'edit_qx')"/>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<!-- <el-table-column label="查" align="center" width="60">-->
|
||||
<!-- <template slot-scope="{row}">-->
|
||||
<!-- <el-button icon="el-icon-view" circle @click="handleTree('routeqxButton',row.role_ID,'cha_qx')"/>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<el-table-column label="操作" align="center" width="390">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="success" icon="el-icon-collection-tag" size="mini" @click="handleTree('routeqx',scope.row.role_ID)">权限</el-button>
|
||||
<el-button type="primary" icon="el-icon-edit" size="mini" @click="handleUpdate(scope.row)">编辑</el-button>
|
||||
<el-button type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(scope.row.role_ID, scope.row.role_NAME)">删除</el-button>
|
||||
<el-button
|
||||
type="success"
|
||||
icon="el-icon-collection-tag"
|
||||
size="mini"
|
||||
@click="handleTree('routeqx',scope.row.role_ID)">权限
|
||||
</el-button>
|
||||
<el-button type="success" icon="el-icon-collection-tag" size="mini" @click="handleNav(scope.row.role_ID)">
|
||||
导航权限
|
||||
</el-button>
|
||||
<el-button type="primary" icon="el-icon-edit" size="mini" @click="handleUpdate(scope.row)">编辑
|
||||
</el-button>
|
||||
<el-button
|
||||
type="danger"
|
||||
icon="el-icon-delete"
|
||||
size="mini"
|
||||
@click="handleDelete(scope.row.role_ID, scope.row.role_NAME)">删除
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
|
@ -57,22 +72,35 @@
|
|||
<div>
|
||||
<el-button type="primary" icon="el-icon-plus" @click="handleCreate(activeTab)">新增</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getRoleList" />
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getRoleList"/>
|
||||
</div>
|
||||
|
||||
<el-dialog :visible.sync="dialogFormVisible" :title="dialogType==='edit'?'编辑角色':'新增角色'" width="600px">
|
||||
<el-form ref="roleForm" :model="form" :rules="formRules" label-width="120px" style="width: 500px;">
|
||||
<el-form-item label="名称" prop="name">
|
||||
<el-input v-model="form.name" autocomplete="off" placeholder="这里输入名称..." />
|
||||
<el-input v-model="form.name" autocomplete="off" placeholder="这里输入名称..."/>
|
||||
</el-form-item>
|
||||
<el-form-item label="排序" prop="sort">
|
||||
<el-input-number :min="0" v-model="form.sort" style="width: 100%;" controls-position="right" autocomplete="off" placeholder="这里输入排序..." />
|
||||
<el-input-number
|
||||
:min="0"
|
||||
v-model="form.sort"
|
||||
style="width: 100%;"
|
||||
controls-position="right"
|
||||
autocomplete="off"
|
||||
placeholder="这里输入排序..."/>
|
||||
</el-form-item>
|
||||
<!-- v-if="!isEditGroup" -->
|
||||
<el-form-item :label="insertLabel">
|
||||
<el-radio-group v-model="form.isMain">
|
||||
<el-radio :label="'1'">是</el-radio>
|
||||
<el-radio :label="'0'">否</el-radio>
|
||||
<!-- <el-form-item :label="insertLabel">-->
|
||||
<!-- <el-radio-group v-model="form.isMain" disabled>-->
|
||||
<!-- <el-radio :label="'1'">是</el-radio>-->
|
||||
<!-- <el-radio :label="'0'">否</el-radio>-->
|
||||
<!-- </el-radio-group>-->
|
||||
<!-- </el-form-item>-->
|
||||
|
||||
<el-form-item v-if="form.parent_id == 0" label="开启人员定位">
|
||||
<el-radio-group v-model="form.has_PLS">
|
||||
<el-radio :label="1">是</el-radio>
|
||||
<el-radio :label="0">否</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
|
@ -94,11 +122,25 @@
|
|||
<el-button type="primary" @click="confirmTree">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog :visible.sync="dialogFormNav" title="导航权限" width="500px">
|
||||
<el-tree
|
||||
ref="nav_tree"
|
||||
:data="navData"
|
||||
:props="navProps"
|
||||
show-checkbox
|
||||
node-key="NAV_ID"/>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormNav = false">取 消</el-button>
|
||||
<el-button type="primary" @click="confirmNav">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
|
||||
export default {
|
||||
components: { Pagination },
|
||||
data() {
|
||||
|
|
@ -124,7 +166,8 @@ export default {
|
|||
parent_id: '',
|
||||
name: '',
|
||||
sort: 0,
|
||||
isMain: '0'
|
||||
isMain: '0',
|
||||
has_PLS: 1
|
||||
},
|
||||
formRules: {
|
||||
name: [
|
||||
|
|
@ -144,6 +187,16 @@ export default {
|
|||
defaultProps: {
|
||||
children: 'children',
|
||||
label: 'PARENT_NAME'
|
||||
},
|
||||
|
||||
dialogFormNav: false,
|
||||
navData: [],
|
||||
navProps: {
|
||||
children: 'children',
|
||||
label: 'TITLE'
|
||||
},
|
||||
confirmNavForm: {
|
||||
id: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
@ -208,6 +261,8 @@ export default {
|
|||
this.isEditGroup = true
|
||||
this.form.id = role.role_ID
|
||||
this.form.name = role.role_NAME
|
||||
this.form.isMain = role.ismain
|
||||
this.form.has_PLS = role.has_PLS
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -292,7 +347,8 @@ export default {
|
|||
ROLE_NAME: this.form.name,
|
||||
PARENT_ID: this.form.parent_id,
|
||||
SORT: this.form.sort,
|
||||
ISMAIN: this.form.isMain
|
||||
ISMAIN: this.form.isMain,
|
||||
HAS_PLS: this.form.has_PLS
|
||||
}
|
||||
).then((data) => {
|
||||
this.$message({
|
||||
|
|
@ -353,6 +409,51 @@ export default {
|
|||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
/*
|
||||
导航权限
|
||||
*/
|
||||
handleNav(roldId) {
|
||||
this.listLoading = true
|
||||
this.confirmNavForm.id = roldId
|
||||
requestFN(
|
||||
'/role/navqx',
|
||||
{
|
||||
ROLE_ID: roldId
|
||||
}
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.navData = data.navList
|
||||
this.dialogFormNav = true
|
||||
this.$nextTick(() => {
|
||||
this.$refs.nav_tree.setCheckedKeys(this.navData.map(item => {
|
||||
if (item.checked) return item.NAV_ID
|
||||
}).filter(item => item)) // 设置目前勾选的节点
|
||||
})
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
confirmNav() {
|
||||
this.listLoading = true
|
||||
const ids = this.$refs.nav_tree.getCheckedKeys()
|
||||
requestFN(
|
||||
'/role/savenavqx',
|
||||
{
|
||||
ROLE_ID: this.confirmNavForm.id,
|
||||
value: ids.join(',')
|
||||
}
|
||||
).then((data) => {
|
||||
this.$message({
|
||||
message: '设置成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.dialogFormNav = false
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -156,13 +156,13 @@
|
|||
title="设置图标"
|
||||
width="40%"
|
||||
@close="iconDialog.visible = false">
|
||||
<div>
|
||||
<div class="link">
|
||||
<a href="https://iconpark.oceanengine.com/official" target="_blank">
|
||||
点击此处
|
||||
</a>
|
||||
查看所有图标
|
||||
</div>
|
||||
<div class="mt">
|
||||
<div>
|
||||
<el-form label-width="80px">
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
|
|
@ -179,8 +179,8 @@
|
|||
</el-form>
|
||||
</div>
|
||||
<div class="icon_container">
|
||||
<div v-for="(item, index) in iconDialog.svgList" :key="index">
|
||||
<el-tooltip :content="item.title">
|
||||
<template v-for="(item, index) in iconDialog.svgList">
|
||||
<el-tooltip :content="item.title" :key="index">
|
||||
<div
|
||||
:class="{ active: iconDialog.iconIndex === index }"
|
||||
class="item"
|
||||
|
|
@ -189,23 +189,21 @@
|
|||
<component
|
||||
:is="'icon-' + item.name"
|
||||
:stroke-width="3"
|
||||
theme="filled"
|
||||
theme="outline"
|
||||
fill="#a5b2c2"
|
||||
size="38"
|
||||
/>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mt flex-end">
|
||||
<pagination
|
||||
:total="iconDialog.pagination.total"
|
||||
:page.sync="iconDialog.pagination.currentPage"
|
||||
:limit.sync="iconDialog.pagination.pageSize"
|
||||
small
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@pagination="fnSearchIcon" />
|
||||
</template>
|
||||
</div>
|
||||
<pagination
|
||||
:total="iconDialog.pagination.total"
|
||||
:page.sync="iconDialog.pagination.currentPage"
|
||||
:limit.sync="iconDialog.pagination.pageSize"
|
||||
small
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@pagination="fnSearchIcon" />
|
||||
<template #footer>
|
||||
<el-button type="primary" @click="confirmIcon">保存</el-button>
|
||||
<el-button @click="iconDialog.visible = false">关闭</el-button>
|
||||
|
|
@ -240,7 +238,10 @@ export default {
|
|||
{ title: '教育培训', model: 'educationAndTraining' },
|
||||
{ title: '高危作业管理', model: 'highRisk' },
|
||||
{ title: '监测预警', model: 'monitor' },
|
||||
{ title: '综合管理', model: 'comprehensive' }
|
||||
{ title: '综合管理', model: 'comprehensive' },
|
||||
{ title: '定位管理', model: 'positioning' },
|
||||
// 东方石油专用
|
||||
{ title: '企业管理-东方石油', model: 'dfPre' }
|
||||
],
|
||||
dialog: {
|
||||
visible: false,
|
||||
|
|
@ -258,6 +259,7 @@ export default {
|
|||
index: '',
|
||||
activeMenu: '',
|
||||
menuId: '',
|
||||
icon: '',
|
||||
isMenu: true,
|
||||
isLogin: true,
|
||||
breadcrumb: true,
|
||||
|
|
@ -301,8 +303,9 @@ export default {
|
|||
},
|
||||
fnAddRouter(row, type) {
|
||||
this.resetForm()
|
||||
this.dialogType = 'edit'
|
||||
this.dialogType = 'add'
|
||||
if (type === '编辑') {
|
||||
this.dialogType = 'edit'
|
||||
this.dialog.form = {
|
||||
menuId: row.ROUTE_ID,
|
||||
index: +row.ROUTE_ORDER,
|
||||
|
|
@ -320,7 +323,8 @@ export default {
|
|||
isLogin: row.meta.isLogin,
|
||||
breadcrumb: row.meta.breadcrumb,
|
||||
isBreadcrumb: row.meta.isBreadcrumb,
|
||||
isSubMenu: row.meta.isSubMenu
|
||||
isSubMenu: row.meta.isSubMenu,
|
||||
icon: row.meta.icon
|
||||
}
|
||||
} else if (type === '新增下级') {
|
||||
this.dialog.form.parentMenuId = row.ROUTE_ID
|
||||
|
|
@ -383,7 +387,8 @@ export default {
|
|||
isLogin: this.dialog.form.isLogin,
|
||||
breadcrumb: this.dialog.form.breadcrumb,
|
||||
isBreadcrumb: this.dialog.form.isBreadcrumb,
|
||||
isSubMenu: this.dialog.form.isSubMenu
|
||||
isSubMenu: this.dialog.form.isSubMenu,
|
||||
icon: this.dialog.form.icon
|
||||
}
|
||||
const params = {
|
||||
NAME: this.dialog.form.title,
|
||||
|
|
@ -402,7 +407,7 @@ export default {
|
|||
'/route/' + this.dialogType,
|
||||
{
|
||||
...params,
|
||||
ROUTE_ID: this.dialog.form.ROUTE_ID
|
||||
ROUTE_ID: this.dialog.form.menuId
|
||||
}
|
||||
).then((data) => {
|
||||
this.$message({
|
||||
|
|
@ -487,11 +492,13 @@ export default {
|
|||
},
|
||||
confirmIcon() {
|
||||
this.listLoading = true
|
||||
console.log(this.iconDialog.iconIndex)
|
||||
console.log(this.iconDialog.svgList[this.iconDialog.iconIndex].name)
|
||||
requestFN(
|
||||
'/route/icon',
|
||||
{
|
||||
ROUTE_ID: this.ROUTE_ID,
|
||||
ICON: this.iconDialog.iconIndex
|
||||
ICON: this.iconDialog.iconIndex !== ''
|
||||
? this.iconDialog.svgList[this.iconDialog.iconIndex].name
|
||||
: ''
|
||||
}
|
||||
|
|
@ -563,13 +570,20 @@ export default {
|
|||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.link{
|
||||
margin-bottom: 10px;
|
||||
a{
|
||||
color: #409EFF;
|
||||
}
|
||||
}
|
||||
.icon_container {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
margin-bottom: 10px;
|
||||
|
||||
.item {
|
||||
flex-basis: calc(5% - 10px);
|
||||
border: 1px solid #fff;
|
||||
flex-basis: calc(10% - 13px);
|
||||
border: 1px solid #ccc;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
|
|
|||
|
|
@ -127,10 +127,10 @@
|
|||
<el-dialog :visible.sync="dialogFormUser" title="查看" width="800px">
|
||||
<div class="filter-container">
|
||||
<el-input v-model="KEYWORDS_USER" placeholder="搜索" class="filter-item" clearable style="width: 200px;" />
|
||||
<div class="filter-lable w80">是否十小:</div>
|
||||
<el-select v-model="issmall" placeholder="请选择" clearable style="width: 100px" class="filter-item" >
|
||||
<el-option v-for="item in issmallList" :key="item.value" :label="item.label" :value="item.value" />
|
||||
</el-select>
|
||||
<!-- <div class="filter-lable w80">是否十小:</div>-->
|
||||
<!-- <el-select v-model="issmall" placeholder="请选择" clearable style="width: 100px" class="filter-item" >-->
|
||||
<!-- <el-option v-for="item in issmallList" :key="item.value" :label="item.label" :value="item.value" />-->
|
||||
<!-- </el-select>-->
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getCorpList">
|
||||
搜索
|
||||
</el-button>
|
||||
|
|
|
|||
|
|
@ -0,0 +1,108 @@
|
|||
<template>
|
||||
<el-dialog :visible.sync="visible" :title="title" width="600px">
|
||||
<el-form v-loading="loading" ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item label="编号" prop="TASK_NUM">
|
||||
<el-input id="TASK_NUM" ref="TASK_NUM" v-model="form.TASK_NUM" placeholder="这里输入隐患部位..." title="隐患部位"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="描述" prop="TERM_DESCRIBE">
|
||||
<el-input id="TERM_DESCRIBE" ref="TERM_DESCRIBE" v-model="form.TERM_DESCRIBE" type="textarea" placeholder="这里输入描述..." title="描述"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="归属类型" prop="WORK_TYPE">
|
||||
<el-select v-model="form.WORK_TYPE" clearable placeholder="请选择">
|
||||
<el-option value="1" label="主要负责人" />
|
||||
<el-option value="2" label="技术负责人" />
|
||||
<el-option value="3" label="操作负责人" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="排序" prop="SORT">
|
||||
<el-input id="SORT" ref="SORT" v-model="form.SORT" maxlength="255" placeholder="这里输入排序..." title="排序"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="close">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
export default {
|
||||
components: { Pagination },
|
||||
directives: { waves },
|
||||
props: {
|
||||
title: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
visible: false,
|
||||
dialogType: 'add',
|
||||
form: {
|
||||
TASK_NUM: '',
|
||||
TERM_DESCRIBE: '',
|
||||
WORK_TYPE: '',
|
||||
SORT: ''
|
||||
},
|
||||
rules: {
|
||||
TASK_NUM: [{ required: true, message: '编号不能为空', trigger: 'blur' },
|
||||
{ pattern: /^[0-9]{1,2}$/,
|
||||
message: '编号必须是1~2位数字' }],
|
||||
TERM_DESCRIBE: [{ required: true, message: '描述不能为空', trigger: 'blur' }],
|
||||
WORK_TYPE: [{ required: true, message: '归属类型不能为空', trigger: 'blur' }],
|
||||
SORT: [{ required: true, message: '排序不能为空', trigger: 'blur' }]
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
if (e) {
|
||||
this.dialogType = 'edit'
|
||||
this.form = e
|
||||
}
|
||||
},
|
||||
confirm() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
this.loading = true
|
||||
requestFN(
|
||||
'/hiddenTermLibrary/' + this.dialogType, this.form
|
||||
).then((data) => {
|
||||
this.loading = false
|
||||
this.close()
|
||||
this.$emit('beforeClose', '')
|
||||
this.$message.success('操作成功')
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
resetForm() {
|
||||
this.form = {
|
||||
TASK_NUM: '',
|
||||
TERM_DESCRIBE: '',
|
||||
WORK_TYPE: '',
|
||||
SORT: ''
|
||||
}
|
||||
},
|
||||
close() {
|
||||
this.visible = false
|
||||
this.form = {
|
||||
TASK_NUM: '',
|
||||
TERM_DESCRIBE: '',
|
||||
WORK_TYPE: '',
|
||||
SORT: ''
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,236 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="filter-container">
|
||||
<el-row :gutter="20">
|
||||
<el-form label-width="80px">
|
||||
<el-col :span="6">
|
||||
<el-form-item label="描述">
|
||||
<el-input v-model="form.KEYWORDS" placeholder="按关键字查询" class="filter-item" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="归属类型">
|
||||
<el-select v-model="form.WORK_TYPE" clearable placeholder="请选择">
|
||||
<el-option value="1" label="主要负责人" />
|
||||
<el-option value="2" label="技术负责人" />
|
||||
<el-option value="3" label="操作负责人" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12" >
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-search" @click="resetting">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
</el-row>
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row
|
||||
>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="TERM_DESCRIBE" label="描述" />
|
||||
<el-table-column label="归属类型" >
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.WORK_TYPE === '1'">主要负责人</span>
|
||||
<span v-if="row.WORK_TYPE === '2'">技术负责人</span>
|
||||
<span v-if="row.WORK_TYPE === '3'">操作负责人</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="CREATE_TIME" label="创建时间" />
|
||||
<el-table-column prop="SORT" label="顺序" />
|
||||
<el-table-column label="操作" align="center" width="250">
|
||||
<template slot-scope="{row}">
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="8">
|
||||
<el-button v-show="edit" type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row)">编辑</el-button>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.TERM_LIBRARY_ID)">删除</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button v-show="add" type="primary" icon="el-icon-plus" @click="handleAdd">新增</el-button>
|
||||
<el-button v-show="false" type="danger" icon="el-icon-delete" plain @click="batchDel">删除</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
<edit ref="edit" :title="title" href="edit" @beforeClose="getList"/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import edit from './edit.vue'
|
||||
export default {
|
||||
components: { edit, Pagination },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
varList: [],
|
||||
title: '新增',
|
||||
form: {
|
||||
KEYWORDS: '',
|
||||
WORK_TYPE: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.HIDDEN_LIBRARY_ID
|
||||
},
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenTermLibrary/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
handleAdd() {
|
||||
this.$refs.edit.init()
|
||||
this.title = '新增'
|
||||
},
|
||||
handleEdit(row) {
|
||||
this.$refs.edit.init(row)
|
||||
this.title = '编辑'
|
||||
},
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenTermLibrary/delete',
|
||||
{ TERM_LIBRARY_ID: id }
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
batchDel() {
|
||||
const _selectData = this.$refs.multipleTable.selection
|
||||
if (_selectData == null || _selectData.length == 0) {
|
||||
this.$message({
|
||||
message: '请选中要删除的项...',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const ids = _selectData.map((item, index) => {
|
||||
return item.TERM_LIBRARY_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/hiddenTermLibrary/deleteAll',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'hiddenTermLibrary:add,hiddenTermLibrary:del,hiddenTermLibrary:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.hiddenTermLibraryfhadminadd // 新增权限
|
||||
this.del = data.hiddenTermLibraryfhadmindel // 删除权限
|
||||
this.edit = data.hiddenTermLibraryfhadminedit // 修改权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
resetting() {
|
||||
this.form = {
|
||||
KEYWORDS: '',
|
||||
WORK_TYPE: ''
|
||||
}
|
||||
this.getList()
|
||||
},
|
||||
|
||||
getResult(e) {
|
||||
this.getList()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
<template>
|
||||
<div>
|
||||
<List v-show="activeName==='List'" ref="list" />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import List from './components/list.vue'
|
||||
export default {
|
||||
components: { List },
|
||||
data() {
|
||||
return {
|
||||
activeName: 'List'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,108 @@
|
|||
<template>
|
||||
<el-dialog :visible.sync="visible" :title="title" width="600px">
|
||||
<el-form v-loading="loading" ref="form" :rules="rules" :model="form" label-width="110px" style="width: 500px;">
|
||||
<el-form-item label="编号" prop="TASK_NUM">
|
||||
<el-input id="TASK_NUM" ref="TASK_NUM" v-model="form.TASK_NUM" placeholder="这里输入隐患部位..." title="隐患部位"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="描述" prop="TERM_DESCRIBE">
|
||||
<el-input id="TERM_DESCRIBE" ref="TERM_DESCRIBE" v-model="form.TERM_DESCRIBE" type="textarea" placeholder="这里输入描述..." title="描述"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="归属类型" prop="WORK_TYPE">
|
||||
<el-select v-model="form.WORK_TYPE" clearable placeholder="请选择">
|
||||
<el-option value="1" label="主要负责人" />
|
||||
<el-option value="2" label="技术负责人" />
|
||||
<el-option value="3" label="操作负责人" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="排序" prop="SORT">
|
||||
<el-input id="SORT" ref="SORT" v-model="form.SORT" maxlength="255" placeholder="这里输入排序..." title="排序"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="close">取 消</el-button>
|
||||
<el-button type="primary" @click="confirm">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
export default {
|
||||
components: { Pagination },
|
||||
directives: { waves },
|
||||
props: {
|
||||
title: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
visible: false,
|
||||
dialogType: 'add',
|
||||
form: {
|
||||
TASK_NUM: '',
|
||||
TERM_DESCRIBE: '',
|
||||
WORK_TYPE: '',
|
||||
SORT: ''
|
||||
},
|
||||
rules: {
|
||||
TASK_NUM: [{ required: true, message: '编号不能为空', trigger: 'blur' },
|
||||
{ pattern: /^[0-9]{1,2}$/,
|
||||
message: '编号必须是1~2位数字' }],
|
||||
TERM_DESCRIBE: [{ required: true, message: '描述不能为空', trigger: 'blur' }],
|
||||
WORK_TYPE: [{ required: true, message: '归属类型不能为空', trigger: 'blur' }],
|
||||
SORT: [{ required: true, message: '排序不能为空', trigger: 'blur' }]
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(e) {
|
||||
this.visible = true
|
||||
if (e) {
|
||||
this.dialogType = 'edit'
|
||||
this.form = e
|
||||
}
|
||||
},
|
||||
confirm() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (valid) {
|
||||
this.loading = true
|
||||
requestFN(
|
||||
'/riskTermLibrary/' + this.dialogType, this.form
|
||||
).then((data) => {
|
||||
this.loading = false
|
||||
this.close()
|
||||
this.$emit('beforeClose', '')
|
||||
this.$message.success('操作成功')
|
||||
}).catch((e) => {
|
||||
this.loading = false
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
},
|
||||
resetForm() {
|
||||
this.form = {
|
||||
TASK_NUM: '',
|
||||
TERM_DESCRIBE: '',
|
||||
WORK_TYPE: '',
|
||||
SORT: ''
|
||||
}
|
||||
},
|
||||
close() {
|
||||
this.visible = false
|
||||
this.form = {
|
||||
TASK_NUM: '',
|
||||
TERM_DESCRIBE: '',
|
||||
WORK_TYPE: '',
|
||||
SORT: ''
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,236 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="filter-container">
|
||||
<el-row :gutter="20">
|
||||
<el-form label-width="80px">
|
||||
<el-col :span="6">
|
||||
<el-form-item label="描述">
|
||||
<el-input v-model="form.KEYWORDS" placeholder="按关键字查询" class="filter-item" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="归属类型">
|
||||
<el-select v-model="form.WORK_TYPE" clearable placeholder="请选择">
|
||||
<el-option value="1" label="主要负责人" />
|
||||
<el-option value="2" label="技术负责人" />
|
||||
<el-option value="3" label="操作负责人" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12" >
|
||||
<el-form-item label-width="10px">
|
||||
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="getQuery">
|
||||
搜索
|
||||
</el-button>
|
||||
<el-button v-waves class="filter-item" type="success" icon="el-icon-search" @click="resetting">
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
</el-row>
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
ref="multipleTable"
|
||||
:data="varList"
|
||||
:row-key="getRowKey"
|
||||
:header-cell-style="{
|
||||
'font-weight': 'bold',
|
||||
'color': '#000'
|
||||
}"
|
||||
tooltip-effect="dark"
|
||||
border
|
||||
fit
|
||||
highlight-current-row
|
||||
>
|
||||
<el-table-column :reserve-selection="true" type="selection" width="55" align="center"/>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="TERM_DESCRIBE" label="描述" />
|
||||
<el-table-column label="归属类型" >
|
||||
<template slot-scope="{row}">
|
||||
<span v-if="row.WORK_TYPE === '1'">主要负责人</span>
|
||||
<span v-if="row.WORK_TYPE === '2'">技术负责人</span>
|
||||
<span v-if="row.WORK_TYPE === '3'">操作负责人</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="CREATE_TIME" label="创建时间" />
|
||||
<el-table-column prop="SORT" label="顺序" />
|
||||
<el-table-column label="操作" align="center" width="250">
|
||||
<template slot-scope="{row}">
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="8">
|
||||
<el-button v-show="edit" type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(row)">编辑</el-button>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-button v-show="del" type="danger" icon="el-icon-delete" size="mini" @click="handleDelete(row.TERM_LIBRARY_ID)">删除</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="page-btn-group">
|
||||
<div>
|
||||
<el-button v-show="add" type="primary" icon="el-icon-plus" @click="handleAdd">新增</el-button>
|
||||
<el-button v-show="false" type="danger" icon="el-icon-delete" plain @click="batchDel">删除</el-button>
|
||||
</div>
|
||||
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
|
||||
</div>
|
||||
<edit ref="edit" :title="title" href="edit" @beforeClose="getList"/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import Pagination from '@/components/Pagination' // 通过 el-pagination二次打包
|
||||
import { requestFN } from '@/utils/request'
|
||||
import waves from '@/directive/waves'
|
||||
import edit from './edit.vue'
|
||||
export default {
|
||||
components: { edit, Pagination },
|
||||
directives: { waves },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
add: false,
|
||||
del: false,
|
||||
edit: false,
|
||||
listQuery: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
},
|
||||
total: 0,
|
||||
KEYWORDS: '',
|
||||
varList: [],
|
||||
title: '新增',
|
||||
form: {
|
||||
KEYWORDS: '',
|
||||
WORK_TYPE: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getRowKey(row) {
|
||||
return row.HIDDEN_LIBRARY_ID
|
||||
},
|
||||
getQuery() {
|
||||
this.getList()
|
||||
},
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/riskTermLibrary/list?showCount=' + this.listQuery.limit + '¤tPage=' + this.listQuery.page,
|
||||
this.form
|
||||
).then((data) => {
|
||||
this.listLoading = false
|
||||
this.varList = data.varList
|
||||
this.total = data.page.totalResult
|
||||
this.hasButton()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
handleAdd() {
|
||||
this.$refs.edit.init()
|
||||
this.title = '新增'
|
||||
},
|
||||
handleEdit(row) {
|
||||
this.$refs.edit.init(row)
|
||||
this.title = '编辑'
|
||||
},
|
||||
handleDelete(id) {
|
||||
this.$confirm('确定要删除吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/riskTermLibrary/delete',
|
||||
{ TERM_LIBRARY_ID: id }
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
batchDel() {
|
||||
const _selectData = this.$refs.multipleTable.selection
|
||||
if (_selectData == null || _selectData.length == 0) {
|
||||
this.$message({
|
||||
message: '请选中要删除的项...',
|
||||
type: 'error'
|
||||
})
|
||||
return false
|
||||
}
|
||||
const ids = _selectData.map((item, index) => {
|
||||
return item.TERM_LIBRARY_ID
|
||||
}).join(',')
|
||||
|
||||
this.$confirm('确定要删除选中的数据吗?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.listLoading = true
|
||||
requestFN(
|
||||
'/riskTermLibrary/deleteAll',
|
||||
{
|
||||
DATA_IDS: ids
|
||||
}
|
||||
).then(() => {
|
||||
this.$message({
|
||||
message: '删除成功',
|
||||
type: 'success'
|
||||
})
|
||||
this.listLoading = false
|
||||
this.varList = []
|
||||
this.listQuery.page = 1
|
||||
this.$refs.multipleTable.clearSelection()
|
||||
this.getList()
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
}).catch(() => {
|
||||
})
|
||||
},
|
||||
hasButton: function() {
|
||||
var keys = 'hiddenTermLibrary:add,hiddenTermLibrary:del,hiddenTermLibrary:edit,toExcel'
|
||||
requestFN(
|
||||
'/head/hasButton',
|
||||
{
|
||||
keys: keys
|
||||
}
|
||||
).then((data) => {
|
||||
this.add = data.hiddenTermLibraryfhadminadd // 新增权限
|
||||
this.del = data.hiddenTermLibraryfhadmindel // 删除权限
|
||||
this.edit = data.hiddenTermLibraryfhadminedit // 修改权限
|
||||
}).catch((e) => {
|
||||
this.listLoading = false
|
||||
})
|
||||
},
|
||||
resetting() {
|
||||
this.form = {
|
||||
KEYWORDS: '',
|
||||
WORK_TYPE: ''
|
||||
}
|
||||
this.getList()
|
||||
},
|
||||
|
||||
getResult(e) {
|
||||
this.getList()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
<template>
|
||||
<div>
|
||||
<List v-show="activeName==='List'" ref="list" />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import List from './components/list.vue'
|
||||
export default {
|
||||
components: { List },
|
||||
data() {
|
||||
return {
|
||||
activeName: 'List'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
@ -3,10 +3,23 @@
|
|||
<el-table :data="list">
|
||||
<el-table-column prop="CREATE_TIME" label="日期"/>
|
||||
<el-table-column prop="CREATOR_NAME" label="姓名"/>
|
||||
<el-table-column prop="PATH" label="替换前附件">
|
||||
<template slot-scope="{row,$index}">
|
||||
<a v-if="$index !== list.length-1" style="color: blue" @click="goViewTxt(list[$index+1].PATH)">[预览]</a>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="PATH" label="替换后附件">
|
||||
<template slot-scope="{row}">
|
||||
<a style="color: blue" @click="goViewTxt(row.PATH)">[预览]</a>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="goBack">取 消</el-button>
|
||||
</div>
|
||||
<el-dialog :visible.sync="dialogViewTxt" title="查看" width="1200px" height = "500px" append-to-body>
|
||||
<iframe :src="dialogViewUrl" width="100%" height="500px" frameborder="1" />
|
||||
</el-dialog>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
|
|
@ -20,6 +33,8 @@ export default {
|
|||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
dialogViewTxt: false,
|
||||
dialogViewUrl: '',
|
||||
list: [],
|
||||
loading: false,
|
||||
id: ''
|
||||
|
|
@ -31,6 +46,11 @@ export default {
|
|||
this.id = e.BUS_TEXT_LIBRARY_ID
|
||||
this.getList()
|
||||
},
|
||||
goViewTxt(filePath) {
|
||||
this.dialogViewTxt = true
|
||||
this.dialogViewUrl = config.fileUrl + filePath
|
||||
},
|
||||
|
||||
goBack() {
|
||||
this.list = []
|
||||
this.visible = false
|
||||
|
|
|
|||
|
|
@ -3,10 +3,23 @@
|
|||
<el-table :data="list">
|
||||
<el-table-column prop="CREATE_TIME" label="日期"/>
|
||||
<el-table-column prop="CREATOR_NAME" label="姓名"/>
|
||||
<el-table-column prop="PATH" label="替换前附件">
|
||||
<template slot-scope="{row,$index}">
|
||||
<a v-if="$index !== list.length-1" style="color: blue" @click="goViewTxt(list[$index+1].PATH)">[预览]</a>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="PATH" label="替换后附件">
|
||||
<template slot-scope="{row}">
|
||||
<a style="color: blue" @click="goViewTxt(row.PATH)">[预览]</a>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="goBack">取 消</el-button>
|
||||
</div>
|
||||
<el-dialog :visible.sync="dialogViewTxt" title="查看" width="1200px" height = "500px" append-to-body>
|
||||
<iframe :src="dialogViewUrl" width="100%" height="500px" frameborder="1" />
|
||||
</el-dialog>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
|
|
@ -20,6 +33,8 @@ export default {
|
|||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
dialogViewTxt: false,
|
||||
dialogViewUrl: '',
|
||||
list: [],
|
||||
loading: false,
|
||||
id: ''
|
||||
|
|
@ -35,6 +50,10 @@ export default {
|
|||
this.list = []
|
||||
this.visible = false
|
||||
},
|
||||
goViewTxt(filePath) {
|
||||
this.dialogViewTxt = true
|
||||
this.dialogViewUrl = config.fileUrl + filePath
|
||||
},
|
||||
getList() {
|
||||
this.loading = true
|
||||
requestFN(
|
||||
|
|
|
|||
|
|
@ -3,10 +3,23 @@
|
|||
<el-table :data="list">
|
||||
<el-table-column prop="CREATE_TIME" label="日期"/>
|
||||
<el-table-column prop="CREATOR_NAME" label="姓名"/>
|
||||
<el-table-column prop="PATH" label="替换前附件">
|
||||
<template slot-scope="{row,$index}">
|
||||
<a v-if="$index !== list.length-1" style="color: blue" @click="goViewTxt(list[$index+1].PATH)">[预览]</a>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="PATH" label="替换后附件">
|
||||
<template slot-scope="{row}">
|
||||
<a style="color: blue" @click="goViewTxt(row.PATH)">[预览]</a>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="goBack">取 消</el-button>
|
||||
</div>
|
||||
<el-dialog :visible.sync="dialogViewTxt" title="查看" width="1200px" height = "500px" append-to-body>
|
||||
<iframe :src="dialogViewUrl" width="100%" height="500px" frameborder="1" />
|
||||
</el-dialog>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
|
|
@ -20,6 +33,8 @@ export default {
|
|||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
dialogViewTxt: false,
|
||||
dialogViewUrl: '',
|
||||
list: [],
|
||||
loading: false,
|
||||
id: ''
|
||||
|
|
@ -31,6 +46,10 @@ export default {
|
|||
this.id = e.BUS_TEXT_LIBRARY_ID
|
||||
this.getList()
|
||||
},
|
||||
goViewTxt(filePath) {
|
||||
this.dialogViewTxt = true
|
||||
this.dialogViewUrl = config.fileUrl + filePath
|
||||
},
|
||||
goBack() {
|
||||
this.list = []
|
||||
this.visible = false
|
||||
|
|
|
|||
|
|
@ -3,10 +3,23 @@
|
|||
<el-table :data="list">
|
||||
<el-table-column prop="CREATE_TIME" label="日期"/>
|
||||
<el-table-column prop="CREATOR_NAME" label="姓名"/>
|
||||
<el-table-column prop="PATH" label="替换前附件">
|
||||
<template slot-scope="{row,$index}">
|
||||
<a v-if="$index !== list.length-1" style="color: blue" @click="goViewTxt(list[$index+1].PATH)">[预览]</a>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="PATH" label="替换后附件">
|
||||
<template slot-scope="{row}">
|
||||
<a style="color: blue" @click="goViewTxt(row.PATH)">[预览]</a>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="goBack">取 消</el-button>
|
||||
</div>
|
||||
<el-dialog :visible.sync="dialogViewTxt" title="查看" width="1200px" height = "500px" append-to-body>
|
||||
<iframe :src="dialogViewUrl" width="100%" height="500px" frameborder="1" />
|
||||
</el-dialog>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
|
|
@ -20,6 +33,8 @@ export default {
|
|||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
dialogViewTxt: false,
|
||||
dialogViewUrl: '',
|
||||
list: [],
|
||||
loading: false,
|
||||
id: ''
|
||||
|
|
@ -31,6 +46,10 @@ export default {
|
|||
this.id = e.BUS_TEXT_LIBRARY_ID
|
||||
this.getList()
|
||||
},
|
||||
goViewTxt(filePath) {
|
||||
this.dialogViewTxt = true
|
||||
this.dialogViewUrl = config.fileUrl + filePath
|
||||
},
|
||||
goBack() {
|
||||
this.list = []
|
||||
this.visible = false
|
||||
|
|
|
|||
|
|
@ -344,7 +344,7 @@ export default {
|
|||
})
|
||||
},
|
||||
resetPwd(id, name) {
|
||||
this.$confirm('是否重置密码为666666?', {
|
||||
this.$confirm('是否重置密码为Aa@123456?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
|
|
|
|||
|
|
@ -360,7 +360,7 @@ export default {
|
|||
})
|
||||
},
|
||||
resetPwd(id, username) {
|
||||
this.$confirm('是否重置密码为666666?', {
|
||||
this.$confirm('是否重置密码为Aa@123456?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
const config = {
|
||||
weburl: 'http://192.168.0.112:8082/', // 前台地址
|
||||
httpurl: 'http://192.168.0.112:8098/', // 后台地址
|
||||
weburl: 'http://36.150.108.91:8501/', // 前台地址
|
||||
// httpurl: 'http://36.150.108.91:8501/zcloud-admin/', // 后台地址
|
||||
httpurl: 'http://192.168.0.79:8098/', // 后台地址
|
||||
// httpurl: 'https://operate.zcloudchina.com/', // 后台地址
|
||||
qyurl: 'https://qyag.zcloudchina.com/qyag/', // 企业前台
|
||||
adminurl: 'https://www.qdkjchina.com/qa-prevention-admin/',
|
||||
|
|
|
|||
Loading…
Reference in New Issue