diff --git a/mock/role/index.js b/mock/role/index.js index 4643f006..e1c5bab1 100644 --- a/mock/role/index.js +++ b/mock/role/index.js @@ -27,8 +27,8 @@ const roles = [ children: [ { path: 'dashboard', - name: 'Dashboard', - meta: { title: 'dashboard', icon: 'dashboard' } + name: '安全生产', + meta: { title: '安全生产', icon: 'dashboard' } } ] }] diff --git a/mock/role/routes.js b/mock/role/routes.js index d33f1624..1ba6711a 100644 --- a/mock/role/routes.js +++ b/mock/role/routes.js @@ -40,8 +40,8 @@ const constantRoutes = [ { path: 'dashboard', component: 'views/dashboard/index', - name: 'Dashboard', - meta: { title: 'Dashboard', icon: 'dashboard', affix: true } + name: '安全生产', + meta: { title: '安全生产', icon: 'dashboard', affix: true } } ] }, diff --git a/src/api/public.js b/src/api/public.js index 36ee43e2..14971e2b 100644 --- a/src/api/public.js +++ b/src/api/public.js @@ -7,5 +7,19 @@ export default { method: 'post', data: `funid=queryevent&eventcode=query_loadtb&selpfunid=&selfunid=${funid}&selpagetype=editgrid&user_id=administrator&dataType=json&query_type=0&has_page=0` }).then(response => response.data) + }, + getFormBtn(funid) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=queryevent&eventcode=query_loadtb&selpfunid=&selfunid=${funid}&selpagetype=form&user_id=administrator&dataType=json&query_type=0&has_page=0` + }).then(response => response.data) + }, + getTypeSel(funid) { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_control&user_id=administrator`, + method: 'post', + data: `start=0&limit=50&where_sql=(funall_control.control_code = ? )&where_value=${funid}&where_type=string&is_query=1&query_type=0&sort=funall_control__control_code` + }).then(response => response.data) } } diff --git a/src/assets/login/portrait.jpg b/src/assets/login/portrait.jpg new file mode 100644 index 00000000..3ec5b7ad Binary files /dev/null and b/src/assets/login/portrait.jpg differ diff --git a/src/components/Breadcrumb/index.vue b/src/components/Breadcrumb/index.vue index e224ff73..11682e70 100644 --- a/src/components/Breadcrumb/index.vue +++ b/src/components/Breadcrumb/index.vue @@ -37,7 +37,7 @@ export default { const first = matched[0] if (!this.isDashboard(first)) { - matched = [{ path: '/dashboard', meta: { title: 'Dashboard' }}].concat(matched) + matched = [{ path: '/', meta: { title: '安全生产' }}].concat(matched) } this.levelList = matched.filter(item => item.meta && item.meta.title && item.meta.breadcrumb !== false) diff --git a/src/components/Buttons/index.vue b/src/components/Buttons/index.vue index 9f5a62b2..70e57ed7 100644 --- a/src/components/Buttons/index.vue +++ b/src/components/Buttons/index.vue @@ -48,6 +48,15 @@ export default { }, upload() { this.$emit('upload') + }, + save() { + this.$emit('save') + }, + create() { + this.$emit('Create') + }, + del() { + this.$emit('Del') } } } diff --git a/src/components/RightPanel/index.vue b/src/components/RightPanel/index.vue index 55e8c1e5..f9e4e997 100644 --- a/src/components/RightPanel/index.vue +++ b/src/components/RightPanel/index.vue @@ -23,7 +23,7 @@ export default { type: Boolean }, buttonTop: { - default: 250, + default: 650, type: Number } }, diff --git a/src/components/formBtn/index.vue b/src/components/formBtn/index.vue new file mode 100644 index 00000000..7990c877 --- /dev/null +++ b/src/components/formBtn/index.vue @@ -0,0 +1,57 @@ + + + {{ d.text }} + + + + + + + diff --git a/src/components/selDept/api/index.js b/src/components/selDept/api/index.js new file mode 100644 index 00000000..864cf6e4 --- /dev/null +++ b/src/components/selDept/api/index.js @@ -0,0 +1,49 @@ +import request from '@/utils/request' + +export default { + getDept(pageSize, pageNo, isWhereSql, whereValue) { + let whereSql = '' + let whereType = '' + if (isWhereSql) { + whereSql = `sys_dept.dept_id like ?` + whereType = 'string' + } + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, + method: 'post', + data: `start=${pageNo}&limit=${pageSize}&where_sql=${whereSql}&where_value=${whereValue}&where_type=${whereType}&is_query=1&query_type=0` + }).then(response => response.data) + }, + getDeptTree() { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, + method: 'post', + data: `start=0&limit=10000&where_sql=&where_value=&where_type=&is_query=1&query_type=0` + }).then(response => response.data) + }, + Crerte(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + auditSave(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + Delete(ids) { + let keys = '' + ids.forEach(d => { + keys += 'keyid=' + d + '&' + }) + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=sys_dept&${keys}pagetype=editgrid&eventcode=delete_eg&user_id=administrator&dataType=json` + }).then(response => response.data) + } +} diff --git a/src/components/selDept/components/auditDept.vue b/src/components/selDept/components/auditDept.vue new file mode 100644 index 00000000..452d67a4 --- /dev/null +++ b/src/components/selDept/components/auditDept.vue @@ -0,0 +1,92 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/components/selDept/index.vue b/src/components/selDept/index.vue new file mode 100644 index 00000000..e3551a90 --- /dev/null +++ b/src/components/selDept/index.vue @@ -0,0 +1,353 @@ + + + + + + + + + + + + + + + + + {{ + scope.row.sys_dept__is_novalid == 0 ? '否' : '是' + }} + + + + + + {{ scope.row[d.prop] }} + + + + + + + + + + + + + diff --git a/src/components/selUser/api/index.js b/src/components/selUser/api/index.js new file mode 100644 index 00000000..1b934115 --- /dev/null +++ b/src/components/selUser/api/index.js @@ -0,0 +1,56 @@ +import request from '@/utils/request' + +export default { + getUser(pageSize, pageNo, isWhereSql, whereValue) { + let whereSql = '' + let whereType = '' + if (isWhereSql) { + whereSql = `sys_dept.dept_id like ?` + whereType = 'string' + } + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_user&user_id=administrator`, + method: 'post', + data: `start=${pageNo}&limit=${pageSize}&where_sql=${whereSql}&where_value=${whereValue}&where_type=${whereType}&is_query=1&query_type=0` + }).then(response => response.data) + }, + getDeptTree() { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, + method: 'post', + data: `start=0&limit=10000&where_sql=&where_value=&where_type=&is_query=1&query_type=0` + }).then(response => response.data) + }, + Crerte(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + auditSave(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + Delete(ids) { + let keys = '' + ids.forEach(d => { + keys += 'keyid=' + d + '&' + }) + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=sys_user&${keys}pagetype=editgrid&eventcode=delete_eg&user_id=administrator&dataType=json` + }).then(response => response.data) + }, + getSelect(control_code) { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_control&user_id=administrator`, + method: 'post', + data: `start=0&limit=50&where_sql=(funall_control.control_code = ? )&where_value=${control_code}&where_type=string&is_query=1&query_type=0` + }).then(response => response.data) + } +} diff --git a/src/components/selUser/components/auditUser.vue b/src/components/selUser/components/auditUser.vue new file mode 100644 index 00000000..d8a0aa1c --- /dev/null +++ b/src/components/selUser/components/auditUser.vue @@ -0,0 +1,211 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 取 消 + 确 定 + + + + + + + + diff --git a/src/components/selUser/index.vue b/src/components/selUser/index.vue new file mode 100644 index 00000000..3e166bef --- /dev/null +++ b/src/components/selUser/index.vue @@ -0,0 +1,408 @@ + + + + + + 安全组织架构 + + + + + + + + + + + + {{ + scope.row.sys_user__is_leader == 0 ? '否' : '是' + }} + + + {{ + scope.row.sys_user__sex == 0 ? '女' : '男' + }} + + + {{ + scope.row.sys_user__is_novalid == 0 ? '否' : '是' + }} + + + + + + {{ scope.row[d.prop] }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/layout/components/Navbar.vue b/src/layout/components/Navbar.vue index 37bc1e69..abac0401 100644 --- a/src/layout/components/Navbar.vue +++ b/src/layout/components/Navbar.vue @@ -12,15 +12,15 @@ - + - + @@ -51,7 +51,7 @@ import Breadcrumb from '@/components/Breadcrumb' import Hamburger from '@/components/Hamburger' import ErrorLog from '@/components/ErrorLog' import Screenfull from '@/components/Screenfull' -import SizeSelect from '@/components/SizeSelect' +// import SizeSelect from '@/components/SizeSelect' import Search from '@/components/HeaderSearch' export default { @@ -60,7 +60,7 @@ export default { Hamburger, ErrorLog, Screenfull, - SizeSelect, + // SizeSelect, Search }, computed: { @@ -148,8 +148,8 @@ export default { .user-avatar { cursor: pointer; - width: 40px; - height: 40px; + width: 38px; + height: 35px; border-radius: 10px; } diff --git a/src/layout/components/Sidebar/index.vue b/src/layout/components/Sidebar/index.vue index fb014a23..9a04a855 100644 --- a/src/layout/components/Sidebar/index.vue +++ b/src/layout/components/Sidebar/index.vue @@ -3,6 +3,7 @@ { // determine whether the user has logged in const hasToken = getToken() - if (hasToken) { if (to.path === '/login') { // if is logged in, redirect to the home page diff --git a/src/router/index.js b/src/router/index.js index c06e6e2c..911e0362 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -78,35 +78,94 @@ export const constantRoutes = [ { path: 'dashboard', component: () => import('@/views/dashboard/index'), - name: 'Dashboard', - meta: { title: 'Dashboard', icon: 'dashboard', affix: true } + meta: { title: '安全生产看板', icon: 'dashboard', affix: true } } ] }, { - path: '/guide', + path: '/insp', component: Layout, - redirect: '/guide/index', + redirect: '/insp/safe_insp', + name: '安全点巡检', + meta: { + title: '安全点巡检', + icon: 'clipboard' + }, children: [ { - path: 'index', - component: () => import('@/views/guide/index'), - name: 'Guide', - meta: { title: 'Guide', icon: 'guide', noCache: true } + path: 'safe_insp', + component: () => import('@/views/safe_insp/index'), + name: '安全点巡检', + meta: { title: '安全点巡检', icon: 'list', noCache: true } + }, + { + path: 'edit_form/:id', + component: () => import('@/views/safe_insp/components/edit_form/index'), + name: 'EditForm', + hidden: true, + meta: { title: '安全点巡检编辑', icon: 'list', noCache: true } + }, + { + path: 'insp_name', + component: () => import('@/views/insp_name/index'), + name: '点巡检标准项', + meta: { title: '点巡检标准项', icon: 'edit', noCache: true } } ] }, { - path: '/profile', + path: '/hidden_danger', component: Layout, - redirect: '/profile/index', - hidden: true, + redirect: '/hidden_danger/hidden_check', + name: '隐患排查治理', + meta: { + title: '隐患排查治理', + icon: 'el-icon-s-order' + }, + children: [ + { + path: 'hidden_check', + component: () => import('@/views/hidden_check/index'), + name: '隐患排查', + meta: { title: '隐患排查', icon: 'form', noCache: true } + }, + { + path: 'hidden_reform', + component: () => import('@/views/hidden_reform/index'), + name: '隐患整改', + meta: { title: '隐患整改', icon: 'el-icon-s-management', noCache: true } + }, + { + path: 'hidden_review', + component: () => import('@/views/hidden_review/index'), + name: '隐患验收', + meta: { title: '隐患验收', icon: 'el-icon-s-opportunity', noCache: true } + } + ] + }, + { + path: '/sys_dept', + component: Layout, + redirect: '/sys_dept/index', children: [ { path: 'index', - component: () => import('@/views/profile/index'), - name: 'Profile', - meta: { title: 'Profile', icon: 'user', noCache: true } + component: () => import('@/views/sys_dept/index'), + name: '组织管理', + meta: { title: '组织管理', icon: 'guide', noCache: true } + } + ] + }, + { + path: '/sys_user', + component: Layout, + redirect: '/sys_user/index', + children: [ + { + path: 'index', + component: () => import('@/views/sys_user/index'), + name: '用户管理', + meta: { title: '用户管理', icon: 'guide', noCache: true } } ] } @@ -205,7 +264,7 @@ export const asyncRoutes = [ path: 'list', component: () => import('@/views/example/list'), name: 'ArticleList', - meta: { title: 'Article List', icon: 'list' } + meta: { title: 'Article List', icon: 'v' } } ] }, diff --git a/src/store/modules/user.js b/src/store/modules/user.js index dbaf3f01..3a710a1e 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -1,3 +1,4 @@ +import Vue from 'vue' import { login, getInfo } from '@/api/user' import { getToken, setToken, removeToken } from '@/utils/auth' import router, { resetRouter } from '@/router' @@ -34,13 +35,16 @@ const actions = { const { username, password } = userInfo return new Promise((resolve, reject) => { login(`funid=login&eventcode=login&pagetype=login&user_code=${username.trim()}&user_pass=${password}`).then(res => { - console.log(res.data.data, 'res') - commit('SET_ROLES', res.data.data.role_id) - // const { data } = res.data - commit('SET_TOKEN', '123') - setToken('123') - sessionStorage.setItem('ROLES', res.data.data.role_id) - resolve() + if (res.data.success) { + commit('SET_ROLES', res.data.data.role_id) + // const { data } = res.data + commit('SET_TOKEN', '123') + setToken('123') + sessionStorage.setItem('ROLES', res.data.data.role_id) + resolve() + } else { + Vue.prototype.$message.error(res.data.message) + } }).catch(err => { reject(err) }) diff --git a/src/styles/layer.scss b/src/styles/layer.scss new file mode 100644 index 00000000..21599329 --- /dev/null +++ b/src/styles/layer.scss @@ -0,0 +1,34 @@ +@import "./element-variables"; + +.compact-layout{ + .v-form-item__label, .v-form-item__content{ + @include inputHeight($input-list); + } + // v-form + .v-form-line{ + margin-top: -1px!important; + } + .v-form-item__content{ + font-size: 12px!important; + } + .v-form-item__label{ + font-size: 12px!important; + height: 22px !important; + color: #111 !important; + line-height: 22px!important; + padding-right: 6px !important; + font-weight: normal; + } + .v-form-item__content{ + line-height: 27px!important; + } + +} + +.el-table .v-form-line{ + margin-top: 0!important; +} + .v-layer { + // height: 22px; + line-height: 20px; + } \ No newline at end of file diff --git a/src/styles/layout.scss b/src/styles/layout.scss new file mode 100644 index 00000000..2d6ccb48 --- /dev/null +++ b/src/styles/layout.scss @@ -0,0 +1,66 @@ +/* layout style */ + +/* margin +----------------*/ +$start: 1; +$end: 6; +@for $i from $start to $end { + .m-t-#{$i*5} { + margin-top: #{$i*5px} + } + .m-b-#{$i*5} { + margin-bottom: #{$i*5px} + } + .m-r-#{$i*5} { + margin-right: #{$i*5px} + } + .m-l-#{$i*5} { + margin-left: #{$i*5px} + } +} + +/* text +----------------*/ +.t-a-l{ + text-align: left; +} +.t-a-c{ + text-align: center; +} +.t-a-r{ + text-align: right; +} + +/* float +----------------*/ +.f-l{ + float: left; +} +.f-r{ + float: right; +} + +/* table +--------*/ +.table{ + display: table; +} +.table-cell{ + display: table-cell; +} + +/* flex +--------*/ +.f-j{ + display: flex; + justify-content: space-between; +} + +.flex-y-c{ + display: flex; + align-items: center; +} + +.d-f{ + display: flex; +} \ No newline at end of file diff --git a/src/views/dashboard/admin/components/PanelGroup.vue b/src/views/dashboard/admin/components/PanelGroup.vue index 589236ed..1bab36cd 100644 --- a/src/views/dashboard/admin/components/PanelGroup.vue +++ b/src/views/dashboard/admin/components/PanelGroup.vue @@ -7,7 +7,7 @@ - New Visits + 安全生产 @@ -20,7 +20,7 @@ - Messages + 为时不晚 @@ -33,7 +33,7 @@ - Purchases + 日常巡检 @@ -46,7 +46,7 @@ - Shoppings + 隐患治理 diff --git a/src/views/dashboard/admin/index.vue b/src/views/dashboard/admin/index.vue index 8cb557be..3d2324ad 100644 --- a/src/views/dashboard/admin/index.vue +++ b/src/views/dashboard/admin/index.vue @@ -28,7 +28,7 @@ - + @@ -47,7 +47,6 @@ import LineChart from './components/LineChart' import RaddarChart from './components/RaddarChart' import PieChart from './components/PieChart' import BarChart from './components/BarChart' -import TransactionTable from './components/TransactionTable' import TodoList from './components/TodoList' import BoxCard from './components/BoxCard' @@ -79,7 +78,6 @@ export default { RaddarChart, PieChart, BarChart, - TransactionTable, TodoList, BoxCard }, diff --git a/src/views/guide/api/index.js b/src/views/guide/api/index.js index 0dd530dd..1f2765ff 100644 --- a/src/views/guide/api/index.js +++ b/src/views/guide/api/index.js @@ -1,11 +1,36 @@ import request from '@/utils/request' export default { - getDept() { + getDept(pageSize, pageNo) { return request({ url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, method: 'post', - data: `start=0&limit=50&where_sql=&where_value=&where_type=&is_query=1&query_type=0` + data: `start=${pageNo}&limit=${pageSize}&where_sql=&where_value=&where_type=&is_query=1&query_type=0` + }).then(response => response.data) + }, + Crerte(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + auditSave(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + Delete(ids) { + let keys = '' + ids.forEach(d => { + keys += 'keyid=' + d + '&' + }) + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=sys_dept&${keys}pagetype=editgrid&eventcode=delete_eg&user_id=administrator&dataType=json` }).then(response => response.data) } } diff --git a/src/views/guide/components/auditDept.vue b/src/views/guide/components/auditDept.vue new file mode 100644 index 00000000..452d67a4 --- /dev/null +++ b/src/views/guide/components/auditDept.vue @@ -0,0 +1,92 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/views/guide/index.vue b/src/views/guide/index.vue index 7e5e6917..0456b0f3 100644 --- a/src/views/guide/index.vue +++ b/src/views/guide/index.vue @@ -7,10 +7,13 @@ v-loading="loading" :data="data" style="width: 100%" + @selection-change="handleSelectionChange" @cell-dblclick="cellDblclick" > + + + + + {{ scope.row[d.prop] }} @@ -36,54 +43,133 @@ @current-change="pageChange" /> + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/views/hidden_check/index.vue b/src/views/hidden_check/index.vue new file mode 100644 index 00000000..e69de29b diff --git a/src/views/hidden_reform/index.vue b/src/views/hidden_reform/index.vue new file mode 100644 index 00000000..e69de29b diff --git a/src/views/hidden_review/index.vue b/src/views/hidden_review/index.vue new file mode 100644 index 00000000..e69de29b diff --git a/src/views/insp_name/index.vue b/src/views/insp_name/index.vue new file mode 100644 index 00000000..59fec047 --- /dev/null +++ b/src/views/insp_name/index.vue @@ -0,0 +1,13 @@ + + 123 + + + + + diff --git a/src/views/safe_insp/api/index.js b/src/views/safe_insp/api/index.js new file mode 100644 index 00000000..454e1331 --- /dev/null +++ b/src/views/safe_insp/api/index.js @@ -0,0 +1,63 @@ +import request from '@/utils/request' + +export default { + getDate(pageSize, pageNo, isWhereSql, whereValue) { + let whereSql = '' + let whereType = '' + if (isWhereSql) { + whereSql = `dept_id like ?` + whereType = 'string' + } + return request({ + url: `commonAction.do?eventcode=query_data&funid=queryevent&pagetype=grid&query_funid=safe_insp&user_id=administrator`, + method: 'post', + data: `start=${pageNo}&limit=${pageSize}&where_sql=${whereSql}&where_value=${whereValue}&where_type=${whereType}&is_query=1&query_type=0` + }).then(response => response.data) + }, + getDeptTree() { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, + method: 'post', + data: `start=0&limit=10000&where_sql=&where_value=&where_type=&is_query=1&query_type=0` + }).then(response => response.data) + }, + Crerte(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + auditSave(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + Delete(ids) { + let keys = '' + ids.forEach(d => { + keys += 'keyid=' + d + '&' + }) + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=sys_dept&${keys}pagetype=editgrid&eventcode=delete_eg&user_id=administrator&dataType=json` + }).then(response => response.data) + }, + getFormDate(id) { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=grid&query_funid=safe_insp&user_id=administrator`, + method: 'post', + data: `start=0&limit=10&where_sql=safe_insp.safe_insp_id = ?&where_value=${id}&where_type=string&is_query=1&query_type=0` + }).then(response => response.data) + }, + Save(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=safe_insp&keyid=${data.safe_insp__safe_insp_id}&safe_insp__insp_code=${data.safe_insp__insp_code}&safe_insp__insp_name=${data.safe_insp__insp_name}&safe_insp__insp_man=${data.safe_insp__insp_man}&safe_insp__insp_times=${data.safe_insp__insp_times}&safe_insp__insp_name_id=${data.safe_insp__insp_name_id}&safe_insp__org_id=${data.safe_insp__org_id}&safe_insp__insp_state=${data.safe_insp__insp_state}&safe_insp__insp_date=${data.safe_insp__insp_date}&safe_insp__insp_memo=${data.safe_insp__insp_memo}&safe_insp__safe_insp_id=${data.safe_insp__safe_insp_id}&safe_insp__dept_id=${data.safe_insp__dept_id}&safe_insp__insp_man_id=${data.safe_insp__insp_man_id}&safe_insp__insp_ed=&safe_insp__insp_ing=${data.safe_insp__insp_ing}&safe_insp__insp_non=&pagetype=form&eventcode=save&dirtyfields=safe_insp.insp_man;safe_insp.insp_times;safe_insp.insp_date;safe_insp.insp_memo;safe_insp.insp_man_id;safe_insp.insp_name;safe_insp.insp_name_id;&fkValue=&user_id=administrator&dataType=json` + }).then(response => response.data) + } +} diff --git a/src/views/safe_insp/components/edit_form/index.vue b/src/views/safe_insp/components/edit_form/index.vue new file mode 100644 index 00000000..774b172c --- /dev/null +++ b/src/views/safe_insp/components/edit_form/index.vue @@ -0,0 +1,196 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 取 消 + 确 定 + + + + + + + + diff --git a/src/views/safe_insp/components/insp_det/api/index.js b/src/views/safe_insp/components/insp_det/api/index.js new file mode 100644 index 00000000..51c355d0 --- /dev/null +++ b/src/views/safe_insp/components/insp_det/api/index.js @@ -0,0 +1,63 @@ +import request from '@/utils/request' + +export default { + getDate(id, pageSize, pageNo, isWhereSql, whereValue) { + let whereSql = '' + let whereType = '' + if (isWhereSql) { + whereSql = `dept_id like ?` + whereType = 'string' + } + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=subeditgrid&query_funid=insp_det&user_id=administrator`, + method: 'post', + data: `start=${pageNo}&limit=${pageSize}&where_sql=(insp_det.safe_insp_id = ?)${whereSql}&where_value=${id}${whereValue}&where_type=string${whereType}&is_query=1&query_type=0` + }).then(response => response.data) + }, + getDeptTree() { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, + method: 'post', + data: `start=0&limit=10000&where_sql=&where_value=&where_type=&is_query=1&query_type=0` + }).then(response => response.data) + }, + Crerte(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + auditSave(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + Delete(ids) { + let keys = '' + ids.forEach(d => { + keys += 'keyid=' + d + '&' + }) + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=insp_det&${keys}pagetype=editgrid&eventcode=delete_eg&user_id=administrator&dataType=json` + }).then(response => response.data) + }, + getFormDate(id) { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=grid&query_funid=safe_insp&user_id=administrator`, + method: 'post', + data: `start=0&limit=10&where_sql=safe_insp.safe_insp_id = ?&where_value=${id}&where_type=string&is_query=1&query_type=0` + }).then(response => response.data) + }, + Save(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=safe_insp&keyid=${data.safe_insp__safe_insp_id}&safe_insp__insp_code=${data.safe_insp__insp_code}&safe_insp__insp_name=${data.safe_insp__insp_name}&safe_insp__insp_man=${data.safe_insp__insp_man}&safe_insp__insp_times=${data.safe_insp__insp_times}&safe_insp__insp_name_id=${data.safe_insp__insp_name_id}&safe_insp__org_id=${data.safe_insp__org_id}&safe_insp__insp_state=${data.safe_insp__insp_state}&safe_insp__insp_date=${data.safe_insp__insp_date}&safe_insp__insp_memo=${data.safe_insp__insp_memo}&safe_insp__safe_insp_id=${data.safe_insp__safe_insp_id}&safe_insp__dept_id=${data.safe_insp__dept_id}&safe_insp__insp_man_id=${data.safe_insp__insp_man_id}&safe_insp__insp_ed=&safe_insp__insp_ing=${data.safe_insp__insp_ing}&safe_insp__insp_non=&pagetype=form&eventcode=save&dirtyfields=safe_insp.insp_man;safe_insp.insp_times;safe_insp.insp_date;safe_insp.insp_memo;safe_insp.insp_man_id;safe_insp.insp_name;safe_insp.insp_name_id;&fkValue=&user_id=administrator&dataType=json` + }).then(response => response.data) + } +} diff --git a/src/views/safe_insp/components/insp_det/index.vue b/src/views/safe_insp/components/insp_det/index.vue new file mode 100644 index 00000000..dacf505f --- /dev/null +++ b/src/views/safe_insp/components/insp_det/index.vue @@ -0,0 +1,303 @@ + + + + + + + + + + + {{ + scope.row.insp_det__det_result === '1' ? '符合' : scope.row.insp_det__det_result === '0' ? '不符合' : null + }} + + + {{ + scope.row.insp_det__reform_flag === '1' ? '已整改' : scope.row.insp_det__reform_flag === '0' ? '未整改' : null + }} + + + + + + {{ scope.row[d.prop] }} + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/views/safe_insp/index.vue b/src/views/safe_insp/index.vue new file mode 100644 index 00000000..cebf69fe --- /dev/null +++ b/src/views/safe_insp/index.vue @@ -0,0 +1,405 @@ + + + + + + + + + + + {{ + scope.row.ssafe_insp__insp_state == 1 ? '巡检中' : '已巡检' + }} + + + + + + {{ scope.row[d.prop] }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/views/sys_dept/api/index.js b/src/views/sys_dept/api/index.js new file mode 100644 index 00000000..864cf6e4 --- /dev/null +++ b/src/views/sys_dept/api/index.js @@ -0,0 +1,49 @@ +import request from '@/utils/request' + +export default { + getDept(pageSize, pageNo, isWhereSql, whereValue) { + let whereSql = '' + let whereType = '' + if (isWhereSql) { + whereSql = `sys_dept.dept_id like ?` + whereType = 'string' + } + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, + method: 'post', + data: `start=${pageNo}&limit=${pageSize}&where_sql=${whereSql}&where_value=${whereValue}&where_type=${whereType}&is_query=1&query_type=0` + }).then(response => response.data) + }, + getDeptTree() { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, + method: 'post', + data: `start=0&limit=10000&where_sql=&where_value=&where_type=&is_query=1&query_type=0` + }).then(response => response.data) + }, + Crerte(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + auditSave(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + Delete(ids) { + let keys = '' + ids.forEach(d => { + keys += 'keyid=' + d + '&' + }) + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=sys_dept&${keys}pagetype=editgrid&eventcode=delete_eg&user_id=administrator&dataType=json` + }).then(response => response.data) + } +} diff --git a/src/views/sys_dept/components/auditDept.vue b/src/views/sys_dept/components/auditDept.vue new file mode 100644 index 00000000..452d67a4 --- /dev/null +++ b/src/views/sys_dept/components/auditDept.vue @@ -0,0 +1,92 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/views/sys_dept/index.vue b/src/views/sys_dept/index.vue new file mode 100644 index 00000000..d70b7e0f --- /dev/null +++ b/src/views/sys_dept/index.vue @@ -0,0 +1,405 @@ + + + + + + + + + + + + + + + + + + {{ + scope.row.sys_dept__is_novalid == 0 ? '否' : '是' + }} + + + + + + {{ scope.row[d.prop] }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/views/sys_user/api/index.js b/src/views/sys_user/api/index.js new file mode 100644 index 00000000..1b934115 --- /dev/null +++ b/src/views/sys_user/api/index.js @@ -0,0 +1,56 @@ +import request from '@/utils/request' + +export default { + getUser(pageSize, pageNo, isWhereSql, whereValue) { + let whereSql = '' + let whereType = '' + if (isWhereSql) { + whereSql = `sys_dept.dept_id like ?` + whereType = 'string' + } + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_user&user_id=administrator`, + method: 'post', + data: `start=${pageNo}&limit=${pageSize}&where_sql=${whereSql}&where_value=${whereValue}&where_type=${whereType}&is_query=1&query_type=0` + }).then(response => response.data) + }, + getDeptTree() { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_dept&user_id=administrator`, + method: 'post', + data: `start=0&limit=10000&where_sql=&where_value=&where_type=&is_query=1&query_type=0` + }).then(response => response.data) + }, + Crerte(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + auditSave(data) { + return request({ + url: `/commonAction.do`, + method: 'post', + data: `${data}` + }).then(response => response.data) + }, + Delete(ids) { + let keys = '' + ids.forEach(d => { + keys += 'keyid=' + d + '&' + }) + return request({ + url: `/commonAction.do`, + method: 'post', + data: `funid=sys_user&${keys}pagetype=editgrid&eventcode=delete_eg&user_id=administrator&dataType=json` + }).then(response => response.data) + }, + getSelect(control_code) { + return request({ + url: `/commonAction.do?eventcode=query_data&funid=queryevent&pagetype=editgrid&query_funid=sys_control&user_id=administrator`, + method: 'post', + data: `start=0&limit=50&where_sql=(funall_control.control_code = ? )&where_value=${control_code}&where_type=string&is_query=1&query_type=0` + }).then(response => response.data) + } +} diff --git a/src/views/sys_user/components/auditUser.vue b/src/views/sys_user/components/auditUser.vue new file mode 100644 index 00000000..9d60136a --- /dev/null +++ b/src/views/sys_user/components/auditUser.vue @@ -0,0 +1,211 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 取 消 + 确 定 + + + + + + + + diff --git a/src/views/sys_user/index.vue b/src/views/sys_user/index.vue new file mode 100644 index 00000000..f2161c2a --- /dev/null +++ b/src/views/sys_user/index.vue @@ -0,0 +1,451 @@ + + + + + + + 安全组织架构 + + + + + + + + + + + + {{ + scope.row.sys_user__is_leader == 0 ? '否' : '是' + }} + + + {{ + scope.row.sys_user__sex == 0 ? '女' : '男' + }} + + + {{ + scope.row.sys_user__is_novalid == 0 ? '否' : '是' + }} + + + + + + {{ scope.row[d.prop] }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +