Commit c21fb5b063207288661bc9b553e37d4c7b7001cd

Authored by monkeyhouyi
1 parent 5330d757

巡查上报页面

package.json
@@ -21,6 +21,7 @@ @@ -21,6 +21,7 @@
21 "nprogress": "^0.2.0", 21 "nprogress": "^0.2.0",
22 "reconnecting-websocket": "^4.4.0", 22 "reconnecting-websocket": "^4.4.0",
23 "sass-loader": "^14.2.1", 23 "sass-loader": "^14.2.1",
  24 + "screenfull": "^4.2.0",
24 "style-loader": "^4.0.0", 25 "style-loader": "^4.0.0",
25 "vue": "^2.6.14", 26 "vue": "^2.6.14",
26 "vue-i18n": "^7.3.2", 27 "vue-i18n": "^7.3.2",
src/api/permission/authorize.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 获取岗位/角色/用户权限树形结构及数据
  4 +export const getAuthorizeValues = (objectId, data) => {
  5 + return request({
  6 + url: `/permission/Authority/Data/${objectId}/Values`,
  7 + method: 'POST',
  8 + data
  9 + })
  10 +}
  11 +
  12 +// 更新岗位/角色/用户权限
  13 +export const updateAuthorizeList = (objectId, data) => {
  14 + return request({
  15 + url: `/permission/Authority/Data/${objectId}`,
  16 + method: 'PUT',
  17 + data
  18 + })
  19 +}
  20 +
  21 +// 批量设置权限
  22 +export const updateBatchAuthorize = (data) => {
  23 + return request({
  24 + url: `/permission/Authority/Data/Batch`,
  25 + method: 'POST',
  26 + data
  27 + })
  28 +}
  29 +// 获取功能权限数据
  30 +export const getModelData = (id, ObjectType) => {
  31 + return request({
  32 + url: `/permission/Authority/Model/${id}/${ObjectType}`,
  33 + method: 'GET'
  34 + })
  35 +}
  36 +// 设置/更新功能权限
  37 +export const setModelData = (id, data) => {
  38 + return request({
  39 + url: `/permission/Authority/Model/${id}`,
  40 + method: 'PUT',
  41 + data
  42 + })
  43 +}
src/api/permission/department.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 获取部门列表
  4 +export const getDepartmentList = (companyId, data) => {
  5 + return request({
  6 + url: `/permission/Organize/${companyId}/Department`,
  7 + method: 'GET',
  8 + data
  9 + })
  10 +}
  11 +
  12 +// 获取部门下拉框列表(公司+部门)
  13 +export const getDepartmentSelector = (id) => {
  14 + return request({
  15 + url: '/permission/Organize/Department/Selector/' + (!!id ? id : 0),
  16 + method: 'GET'
  17 + })
  18 +}
  19 +
  20 +// 新建部门
  21 +export const createDepartment = (data) => {
  22 + return request({
  23 + url: '/permission/Organize/Department',
  24 + method: 'POST',
  25 + data
  26 + })
  27 +}
  28 +
  29 +// 修改部门
  30 +export const updateDepartment = (data) => {
  31 + return request({
  32 + url: `/permission/Organize/Department/${data.id}`,
  33 + method: 'PUT',
  34 + data
  35 + })
  36 +}
  37 +
  38 +// 获取部门信息
  39 +export const getDepartmentInfo = (id) => {
  40 + return request({
  41 + url: `/permission/Organize/Department/${id}`,
  42 + method: 'GET'
  43 + })
  44 +}
  45 +
  46 +// 删除部门
  47 +export const delDepartment = (id) => {
  48 + return request({
  49 + url: `/permission/Organize/Department/${id}`,
  50 + method: 'DELETE'
  51 + })
  52 +}
  53 +
  54 +// 更新部门状态
  55 +export const updateDepartmentState = (id) => {
  56 + return request({
  57 + url: `/permission/Organize/Department/${id}/Actions/State`,
  58 + method: 'PUT'
  59 + })
  60 +}
0 \ No newline at end of file 61 \ No newline at end of file
src/api/permission/onlineUser.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 获取在线用户列表
  4 +export const getOnlineUser = (data) => {
  5 + return request({
  6 + url: '/system/OnlineUser',
  7 + method: 'GET',
  8 + data
  9 + })
  10 +}
  11 +// 强制下线
  12 +export const deleteOnlineUser = (id) => {
  13 + return request({
  14 + url: `/system/OnlineUser/${id}`,
  15 + method: 'DELETE'
  16 + })
  17 +}
src/api/permission/organize.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 获取组织/公司列表
  4 +export const getOrganizeList = (data) => {
  5 + return request({
  6 + url: '/permission/Organize',
  7 + method: 'GET',
  8 + data
  9 + })
  10 +}
  11 +
  12 +// 获取组织/公司下拉框列表
  13 +export const getOrganizeSelector = (id) => {
  14 + return request({
  15 + url: '/permission/Organize/Selector/' + (!!id ? id : 0),
  16 + method: 'GET'
  17 + })
  18 +}
  19 +
  20 +// 获取组织/公司树形
  21 +export const getOrganizeTree = () => {
  22 + return request({
  23 + url: '/permission/Organize/Tree',
  24 + method: 'GET'
  25 + })
  26 +}
  27 +
  28 +// 新建组织/公司
  29 +export const createOrganize = (data) => {
  30 + return request({
  31 + url: '/permission/Organize',
  32 + method: 'POST',
  33 + data
  34 + })
  35 +}
  36 +
  37 +// 修改组织/公司
  38 +export const updateOrganize = (data) => {
  39 + return request({
  40 + url: `/permission/Organize/${data.id}`,
  41 + method: 'PUT',
  42 + data
  43 + })
  44 +}
  45 +
  46 +// 获取组织/公司信息
  47 +export const getOrganizeInfo = (id) => {
  48 + return request({
  49 + url: `/permission/Organize/${id}`,
  50 + method: 'GET'
  51 + })
  52 +}
  53 +
  54 +// 删除组织/公司
  55 +export const delOrganize = (id) => {
  56 + return request({
  57 + url: `/permission/Organize/${id}`,
  58 + method: 'DELETE'
  59 + })
  60 +}
  61 +
  62 +// 更新组织/公司状态
  63 +export const updateOrganizeState = (id) => {
  64 + return request({
  65 + url: `/permission/Organize/${id}/Actions/State`,
  66 + method: 'PUT'
  67 + })
  68 +}
  69 +// 获取分级管理
  70 +export const getOrganizeTrator = (organizeId) => {
  71 + return request({
  72 + url: `/permission/organizeAdminIsTrator/${organizeId}`,
  73 + method: 'get'
  74 + })
  75 +}
  76 +// 更新分级管理
  77 +export const setOrganizeTrator = (data) => {
  78 + return request({
  79 + url: `/permission/organizeAdminIsTrator/${data.organizeId}`,
  80 + method: 'PUT',
  81 + data
  82 + })
  83 +}
0 \ No newline at end of file 84 \ No newline at end of file
src/api/permission/position.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 获取岗位列表(分页)
  4 +export const getPositionList = (data) => {
  5 + return request({
  6 + url: '/permission/Position',
  7 + method: 'GET',
  8 + data
  9 + })
  10 +}
  11 +
  12 +// 获取岗位下拉列表(公司+部门+岗位)
  13 +export const getPositionSelector = () => {
  14 + return request({
  15 + url: '/permission/Position/Selector',
  16 + method: 'GET'
  17 + })
  18 +}
  19 +
  20 +// 新建岗位
  21 +export const createPosition = (data) => {
  22 + return request({
  23 + url: '/permission/Position',
  24 + method: 'POST',
  25 + data
  26 + })
  27 +}
  28 +
  29 +// 修改岗位
  30 +export const updatePosition = (data) => {
  31 + return request({
  32 + url: `/permission/Position/${data.id}`,
  33 + method: 'PUT',
  34 + data
  35 + })
  36 +}
  37 +
  38 +// 获取岗位信息
  39 +export const getPositionInfo = (id) => {
  40 + return request({
  41 + url: `/permission/Position/${id}`,
  42 + method: 'GET'
  43 + })
  44 +}
  45 +
  46 +// 删除岗位
  47 +export const delPosition = (id) => {
  48 + return request({
  49 + url: `/permission/Position/${id}`,
  50 + method: 'DELETE'
  51 + })
  52 +}
  53 +
  54 +// 更新岗位状态
  55 +export const updatePositionState = (id) => {
  56 + return request({
  57 + url: `/permission/Position/${id}/Actions/State`,
  58 + method: 'PUT'
  59 + })
  60 +}
  61 +
  62 +// 获取全部岗位管理信息列表
  63 +export const getPositionListAll = () => {
  64 + return request({
  65 + url: '/permission/Position/All',
  66 + method: 'GET'
  67 + })
  68 +}
src/api/permission/role.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 获取角色列表
  4 +export const getRoleList = (data) => {
  5 + return request({
  6 + url: '/permission/Role',
  7 + method: 'GET',
  8 + data
  9 + })
  10 +}
  11 +
  12 +// 获取角色下拉框列表
  13 +export const getRoleSelector = () => {
  14 + return request({
  15 + url: '/permission/Role/Selector',
  16 + method: 'GET'
  17 + })
  18 +}
  19 +
  20 +// 新建角色
  21 +export const createRole = (data) => {
  22 + return request({
  23 + url: '/permission/Role',
  24 + method: 'POST',
  25 + data
  26 + })
  27 +}
  28 +
  29 +// 修改角色
  30 +export const updateRole = (data) => {
  31 + return request({
  32 + url: `/permission/Role/${data.id}`,
  33 + method: 'PUT',
  34 + data
  35 + })
  36 +}
  37 +
  38 +// 获取角色信息
  39 +export const getRoleInfo = (id) => {
  40 + return request({
  41 + url: `/permission/Role/${id}`,
  42 + method: 'GET'
  43 + })
  44 +}
  45 +
  46 +// 删除角色
  47 +export const delRole = (id) => {
  48 + return request({
  49 + url: `/permission/Role/${id}`,
  50 + method: 'DELETE'
  51 + })
  52 +}
  53 +
  54 +// 更新角色状态
  55 +export const updateRoleState = (id) => {
  56 + return request({
  57 + url: `/permission/Role/${id}/Actions/State`,
  58 + method: 'PUT'
  59 + })
  60 +}
  61 +
  62 +// 获取角色类型
  63 +export const getRoleTypeSelector = () => {
  64 + return request({
  65 + url: '/system/DictionaryData/4501f6f26a384757bce12d4c4b03342c/Data/Selector',
  66 + method: 'GET'
  67 + })
  68 +}
src/api/permission/user.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 获取用户列表
  4 +export const getUserList = (data) => {
  5 + return request({
  6 + url: '/permission/Users',
  7 + method: 'GET',
  8 + data
  9 + })
  10 +}
  11 +
  12 +// 获取所有用户列表
  13 +export const UserListAll = () => {
  14 + return request({
  15 + url: '/permission/Users/All',
  16 + method: 'GET'
  17 + })
  18 +}
  19 +
  20 +// 获取用户下拉框列表(公司+部门+用户)
  21 +export const getUserSelector = () => {
  22 + return request({
  23 + url: '/permission/Users/Selector',
  24 + method: 'GET'
  25 + })
  26 +}
  27 +
  28 +// 新建用户
  29 +export const createUser = (data) => {
  30 + return request({
  31 + url: '/permission/Users',
  32 + method: 'POST',
  33 + data
  34 + })
  35 +}
  36 +
  37 +// 修改用户
  38 +export const updateUser = (data) => {
  39 + return request({
  40 + url: `/permission/Users/${data.id}`,
  41 + method: 'PUT',
  42 + data
  43 + })
  44 +}
  45 +
  46 +// 获取用户信息
  47 +export const getUserInfo = (id) => {
  48 + return request({
  49 + url: `/permission/Users/${id}`,
  50 + method: 'GET'
  51 + })
  52 +}
  53 +
  54 +// 删除用户
  55 +export const delUser = (id) => {
  56 + return request({
  57 + url: `/permission/Users/${id}`,
  58 + method: 'DELETE'
  59 + })
  60 +}
  61 +
  62 +// 修改用户密码
  63 +export const resetUserPassword = (data) => {
  64 + return request({
  65 + url: `/permission/Users/${data.id}/Actions/ResetPassword`,
  66 + method: 'POST',
  67 + data
  68 + })
  69 +}
  70 +
  71 +// 更新用户状态
  72 +export const updateUserState = (id) => {
  73 + return request({
  74 + url: `/permission/Users/${id}/Actions/State`,
  75 + method: 'PUT'
  76 + })
  77 +}
  78 +
  79 +// IM通讯获取用户
  80 +export const getImUser = data => {
  81 + return request({
  82 + url: '/permission/Users/ImUser',
  83 + method: 'GET',
  84 + data
  85 + })
  86 +}
  87 +
  88 +// 获取用户下拉框列表
  89 +export const getImUserSelector = (organizeId, keyword) => {
  90 + return request({
  91 + url: `/permission/Users/ImUser/Selector/${organizeId}`,
  92 + method: 'post',
  93 + data: { keyword }
  94 + })
  95 +}
  96 +
  97 +// 获取用户基本信息
  98 +export const getUserInfoList = userId => {
  99 + return request({
  100 + url: '/permission/Users/getUserList',
  101 + method: 'post',
  102 + data: { userId }
  103 + })
  104 +}
0 \ No newline at end of file 105 \ No newline at end of file
src/api/permission/userRelation.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 获取岗位/角色成员列表
  4 +export const getUserRelationList = (objectId) => {
  5 + return request({
  6 + url: `/permission/UserRelation/${objectId}`,
  7 + method: 'GET'
  8 + })
  9 +}
  10 +
  11 +
  12 +// 添加/更新岗位或角色成员
  13 +export const createUserRelation = (data) => {
  14 + return request({
  15 + url: `/permission/UserRelation/${data.objectId}`,
  16 + method: 'POST',
  17 + data
  18 + })
  19 +}
src/api/permission/userSetting.js 0 → 100644
  1 +import request from '@/utils/request'
  2 +
  3 +// 更新当前用户头像
  4 +export function UpdateAvatar(name) {
  5 + return request({
  6 + url: `/permission/Users/Current/Avatar/${name}`,
  7 + method: 'PUT'
  8 + })
  9 +}
  10 +// 获取当前用户个人资料
  11 +export function UserSettingInfo() {
  12 + return request({
  13 + url: '/permission/Users/Current/BaseInfo',
  14 + method: 'GET'
  15 + })
  16 +}
  17 +// 更新当前用户个人资料
  18 +export function UpdateUser(data) {
  19 + return request({
  20 + url: '/permission/Users/Current/BaseInfo',
  21 + method: 'PUT',
  22 + data
  23 + })
  24 +}
  25 +// 修改当前用户密码
  26 +export function UpdatePassword(data) {
  27 + return request({
  28 + url: '/permission/Users/Current/Actions/ModifyPassword',
  29 + method: 'POST',
  30 + data
  31 + })
  32 +}
  33 +// 更新当前用户系统主题
  34 +export function UpdateTheme(data) {
  35 + return request({
  36 + url: '/permission/Users/Current/SystemTheme',
  37 + method: 'PUT',
  38 + data
  39 + })
  40 +}
  41 +// 更新当前用户系统语言配置
  42 +export function UpdateLanguage(data) {
  43 + return request({
  44 + url: `/permission/Users/Current/SystemLanguage`,
  45 + method: 'PUT',
  46 + data
  47 + })
  48 +}
  49 +// 获取我的下属
  50 +export function getSubordinate() {
  51 + return request({
  52 + url: `/permission/Users/Current/Subordinate`,
  53 + method: 'GET'
  54 + })
  55 +}
  56 +// 获取当前用户系统权限
  57 +export function AuthorizeList() {
  58 + return request({
  59 + url: '/permission/Users/Current/Authorize',
  60 + method: 'GET'
  61 + })
  62 +}
  63 +// 获取系统日志
  64 +export function LogList(data) {
  65 + return request({
  66 + url: `/permission/Users/Current/SystemLog`,
  67 + method: 'GET',
  68 + data
  69 + })
  70 +}
0 \ No newline at end of file 71 \ No newline at end of file
src/api/systemData/commonFields.js
@@ -3,7 +3,7 @@ import request from '@/utils/request' @@ -3,7 +3,7 @@ import request from '@/utils/request'
3 // 获取字段列表 3 // 获取字段列表
4 export function getList(data) { 4 export function getList(data) {
5 return request({ 5 return request({
6 - url: '/api/system/CommonFields', 6 + url: '/system/CommonFields',
7 method: 'get', 7 method: 'get',
8 data 8 data
9 }) 9 })
@@ -11,21 +11,21 @@ export function getList(data) { @@ -11,21 +11,21 @@ export function getList(data) {
11 // 获取字段信息 11 // 获取字段信息
12 export function getInfo(id) { 12 export function getInfo(id) {
13 return request({ 13 return request({
14 - url: `/api/system/CommonFields/${id}`, 14 + url: `/system/CommonFields/${id}`,
15 method: 'get' 15 method: 'get'
16 }) 16 })
17 } 17 }
18 // 删除字段 18 // 删除字段
19 export function Delete(id) { 19 export function Delete(id) {
20 return request({ 20 return request({
21 - url: `/api/system/CommonFields/${id}`, 21 + url: `/system/CommonFields/${id}`,
22 method: 'DELETE' 22 method: 'DELETE'
23 }) 23 })
24 } 24 }
25 // 修改字段 25 // 修改字段
26 export function Update(data) { 26 export function Update(data) {
27 return request({ 27 return request({
28 - url: `/api/system/CommonFields/${data.id}`, 28 + url: `/system/CommonFields/${data.id}`,
29 method: 'PUT', 29 method: 'PUT',
30 data 30 data
31 }) 31 })
@@ -33,7 +33,7 @@ export function Update(data) { @@ -33,7 +33,7 @@ export function Update(data) {
33 // 新建字段 33 // 新建字段
34 export function Create(data) { 34 export function Create(data) {
35 return request({ 35 return request({
36 - url: '/api/system/CommonFields', 36 + url: '/system/CommonFields',
37 method: 'post', 37 method: 'post',
38 data 38 data
39 }) 39 })
src/api/systemData/dataBackup.js
@@ -3,7 +3,7 @@ import request from '@/utils/request' @@ -3,7 +3,7 @@ import request from '@/utils/request'
3 // 获取数据备份列表(带分页) 3 // 获取数据备份列表(带分页)
4 export function getDataBackupList(data) { 4 export function getDataBackupList(data) {
5 return request({ 5 return request({
6 - url: '/api/system/DataBackup', 6 + url: '/system/DataBackup',
7 method: 'GET', 7 method: 'GET',
8 data 8 data
9 }) 9 })
@@ -12,7 +12,7 @@ export function getDataBackupList(data) { @@ -12,7 +12,7 @@ export function getDataBackupList(data) {
12 // 添加数据备份 12 // 添加数据备份
13 export function createDataBackup() { 13 export function createDataBackup() {
14 return request({ 14 return request({
15 - url: '/api/system/DataBackup', 15 + url: '/system/DataBackup',
16 method: 'POST' 16 method: 'POST'
17 }) 17 })
18 } 18 }
@@ -20,7 +20,7 @@ export function createDataBackup() { @@ -20,7 +20,7 @@ export function createDataBackup() {
20 // 删除数据备份 20 // 删除数据备份
21 export function delDataBackup(id) { 21 export function delDataBackup(id) {
22 return request({ 22 return request({
23 - url: `/api/system/DataBackup/${id}`, 23 + url: `/system/DataBackup/${id}`,
24 method: 'DELETE' 24 method: 'DELETE'
25 }) 25 })
26 } 26 }
27 \ No newline at end of file 27 \ No newline at end of file
src/api/systemData/dataInterface.js
1 import request from '@/utils/request' 1 import request from '@/utils/request'
2 2
  3 +// 获取字段列表
  4 +export function getList(data) {
  5 + return request({
  6 + url: `/Extend/BaseInspectionReport`,
  7 + method: 'GET',
  8 + data
  9 + })
  10 +}
  11 +
  12 +
3 // 获取接口列表(分页) 13 // 获取接口列表(分页)
4 export function getDataInterfaceList(data) { 14 export function getDataInterfaceList(data) {
5 return request({ 15 return request({
6 - url: '/api/system/DataInterface', 16 + url: '/system/DataInterface',
7 method: 'GET', 17 method: 'GET',
8 data 18 data
9 }) 19 })
@@ -12,7 +22,7 @@ export function getDataInterfaceList(data) { @@ -12,7 +22,7 @@ export function getDataInterfaceList(data) {
12 // 获取接口列表下拉框 22 // 获取接口列表下拉框
13 export function getDataInterfaceSelector() { 23 export function getDataInterfaceSelector() {
14 return request({ 24 return request({
15 - url: '/api/system/DataInterface/Selector', 25 + url: '/system/DataInterface/Selector',
16 method: 'GET' 26 method: 'GET'
17 }) 27 })
18 } 28 }
@@ -20,7 +30,7 @@ export function getDataInterfaceSelector() { @@ -20,7 +30,7 @@ export function getDataInterfaceSelector() {
20 // 添加接口 30 // 添加接口
21 export function createDataInterface(data) { 31 export function createDataInterface(data) {
22 return request({ 32 return request({
23 - url: '/api/system/DataInterface', 33 + url: '/system/DataInterface',
24 method: 'POST', 34 method: 'POST',
25 data 35 data
26 }) 36 })
@@ -29,7 +39,7 @@ export function createDataInterface(data) { @@ -29,7 +39,7 @@ export function createDataInterface(data) {
29 // 修改接口 39 // 修改接口
30 export function updateDataInterface(data) { 40 export function updateDataInterface(data) {
31 return request({ 41 return request({
32 - url: `/api/system/DataInterface/${data.id}`, 42 + url: `/system/DataInterface/${data.id}`,
33 method: 'PUT', 43 method: 'PUT',
34 data 44 data
35 }) 45 })
@@ -38,7 +48,7 @@ export function updateDataInterface(data) { @@ -38,7 +48,7 @@ export function updateDataInterface(data) {
38 // 获取接口数据 48 // 获取接口数据
39 export function getDataInterfaceInfo(id) { 49 export function getDataInterfaceInfo(id) {
40 return request({ 50 return request({
41 - url: `/api/system/DataInterface/${id}`, 51 + url: `/system/DataInterface/${id}`,
42 method: 'GET' 52 method: 'GET'
43 }) 53 })
44 } 54 }
@@ -46,7 +56,7 @@ export function getDataInterfaceInfo(id) { @@ -46,7 +56,7 @@ export function getDataInterfaceInfo(id) {
46 // 删除接口数据 56 // 删除接口数据
47 export function delDataInterface(id) { 57 export function delDataInterface(id) {
48 return request({ 58 return request({
49 - url: `/api/system/DataInterface/${id}`, 59 + url: `/system/DataInterface/${id}`,
50 method: 'DELETE' 60 method: 'DELETE'
51 }) 61 })
52 } 62 }
@@ -54,7 +64,7 @@ export function delDataInterface(id) { @@ -54,7 +64,7 @@ export function delDataInterface(id) {
54 // 更新接口状态 64 // 更新接口状态
55 export function updateDataInterfaceState(id) { 65 export function updateDataInterfaceState(id) {
56 return request({ 66 return request({
57 - url: `/api/system/DataInterface/${id}/Actions/State`, 67 + url: `/system/DataInterface/${id}/Actions/State`,
58 method: 'PUT' 68 method: 'PUT'
59 }) 69 })
60 } 70 }
@@ -62,7 +72,7 @@ export function updateDataInterfaceState(id) { @@ -62,7 +72,7 @@ export function updateDataInterfaceState(id) {
62 // 获取接口分类 72 // 获取接口分类
63 export function getDataInterfaceTypeSelector() { 73 export function getDataInterfaceTypeSelector() {
64 return request({ 74 return request({
65 - url: '/api/system/DictionaryData/9c43287481364d348c0ea0d0f64b38be/Data/Selector', 75 + url: '/system/DictionaryData/9c43287481364d348c0ea0d0f64b38be/Data/Selector',
66 method: 'GET' 76 method: 'GET'
67 }) 77 })
68 } 78 }
@@ -70,7 +80,7 @@ export function getDataInterfaceTypeSelector() { @@ -70,7 +80,7 @@ export function getDataInterfaceTypeSelector() {
70 // 获取接口数据 80 // 获取接口数据
71 export function previewDataInterface(id) { 81 export function previewDataInterface(id) {
72 return request({ 82 return request({
73 - url: `/api/system/DataInterface/${id}/Actions/Response`, 83 + url: `/system/DataInterface/${id}/Actions/Response`,
74 method: 'GET' 84 method: 'GET'
75 }) 85 })
76 } 86 }
@@ -78,7 +88,7 @@ export function previewDataInterface(id) { @@ -78,7 +88,7 @@ export function previewDataInterface(id) {
78 // 导出数据接口数据 88 // 导出数据接口数据
79 export function exportData(id) { 89 export function exportData(id) {
80 return request({ 90 return request({
81 - url: `/api/system/DataInterface/${id}/Action/Export`, 91 + url: `/system/DataInterface/${id}/Action/Export`,
82 method: 'GET' 92 method: 'GET'
83 }) 93 })
84 } 94 }
@@ -86,7 +96,7 @@ export function exportData(id) { @@ -86,7 +96,7 @@ export function exportData(id) {
86 // 获取数据接口调用日志列表 96 // 获取数据接口调用日志列表
87 export function getDataInterfaceLog(id, data) { 97 export function getDataInterfaceLog(id, data) {
88 return request({ 98 return request({
89 - url: `/api/system/DataInterfaceLog/${id}`, 99 + url: `/system/DataInterfaceLog/${id}`,
90 method: 'GET', 100 method: 'GET',
91 data 101 data
92 }) 102 })
src/api/systemData/dataModel.js
@@ -3,7 +3,7 @@ import request from '@/utils/request' @@ -3,7 +3,7 @@ import request from '@/utils/request'
3 // 获取数据库表列表 3 // 获取数据库表列表
4 export function DataModelList(id, data) { 4 export function DataModelList(id, data) {
5 return request({ 5 return request({
6 - url: `/api/system/DataModel/${id}/Tables`, 6 + url: `/system/DataModel/${id}/Tables`,
7 method: 'get', 7 method: 'get',
8 data 8 data
9 }) 9 })
@@ -11,7 +11,7 @@ export function DataModelList(id, data) { @@ -11,7 +11,7 @@ export function DataModelList(id, data) {
11 // 添加数据表 11 // 添加数据表
12 export function DataModelCreate(linkId, data) { 12 export function DataModelCreate(linkId, data) {
13 return request({ 13 return request({
14 - url: `/api/system/DataModel/${linkId}/Table`, 14 + url: `/system/DataModel/${linkId}/Table`,
15 method: 'post', 15 method: 'post',
16 data 16 data
17 }) 17 })
@@ -19,7 +19,7 @@ export function DataModelCreate(linkId, data) { @@ -19,7 +19,7 @@ export function DataModelCreate(linkId, data) {
19 // 预览数据库表 19 // 预览数据库表
20 export function DataModelData(linkId, table, data) { 20 export function DataModelData(linkId, table, data) {
21 return request({ 21 return request({
22 - url: `/api/system/DataModel/${linkId}/Table/${table}/Preview`, 22 + url: `/system/DataModel/${linkId}/Table/${table}/Preview`,
23 method: 'get', 23 method: 'get',
24 data 24 data
25 }) 25 })
@@ -27,28 +27,28 @@ export function DataModelData(linkId, table, data) { @@ -27,28 +27,28 @@ export function DataModelData(linkId, table, data) {
27 // 删除数据表 27 // 删除数据表
28 export function DataModelDelete(linkId, id) { 28 export function DataModelDelete(linkId, id) {
29 return request({ 29 return request({
30 - url: `/api/system/DataModel/${linkId}/Table/${id}`, 30 + url: `/system/DataModel/${linkId}/Table/${id}`,
31 method: 'delete', 31 method: 'delete',
32 }) 32 })
33 } 33 }
34 // 获取数据库表字段列表 34 // 获取数据库表字段列表
35 export function DataModelFieldList(linkId, table, type) { 35 export function DataModelFieldList(linkId, table, type) {
36 return request({ 36 return request({
37 - url: `/api/system/DataModel/${linkId}/Tables/${table}/Fields?type=${type}`, 37 + url: `/system/DataModel/${linkId}/Tables/${table}/Fields?type=${type}`,
38 method: 'get' 38 method: 'get'
39 }) 39 })
40 } 40 }
41 // 获取数据表 41 // 获取数据表
42 export function DataModelInfo(linkId, id) { 42 export function DataModelInfo(linkId, id) {
43 return request({ 43 return request({
44 - url: `/api/system/DataModel/${linkId}/Table/${id}`, 44 + url: `/system/DataModel/${linkId}/Table/${id}`,
45 method: 'get', 45 method: 'get',
46 }) 46 })
47 } 47 }
48 // 修改数据表 48 // 修改数据表
49 export function DataModelUpdate(linkId, data) { 49 export function DataModelUpdate(linkId, data) {
50 return request({ 50 return request({
51 - url: `/api/system/DataModel/${linkId}/Table`, 51 + url: `/system/DataModel/${linkId}/Table`,
52 method: 'put', 52 method: 'put',
53 data 53 data
54 }) 54 })
@@ -56,7 +56,7 @@ export function DataModelUpdate(linkId, data) { @@ -56,7 +56,7 @@ export function DataModelUpdate(linkId, data) {
56 // 导出 56 // 导出
57 export function exportTpl(linkId, id) { 57 export function exportTpl(linkId, id) {
58 return request({ 58 return request({
59 - url: `/api/system/DataModel/${linkId}/Table/${id}/Action/Export`, 59 + url: `/system/DataModel/${linkId}/Table/${id}/Action/Export`,
60 method: 'get' 60 method: 'get'
61 }) 61 })
62 } 62 }
63 \ No newline at end of file 63 \ No newline at end of file
src/api/systemData/dataSource.js
@@ -2,53 +2,53 @@ import request from '@/utils/request' @@ -2,53 +2,53 @@ import request from '@/utils/request'
2 2
3 export function getDataSourceList(data) { 3 export function getDataSourceList(data) {
4 return request({ 4 return request({
5 - url: '/api/system/DataSource', 5 + url: '/system/DataSource',
6 method: 'get', 6 method: 'get',
7 data 7 data
8 }) 8 })
9 } 9 }
10 export function DataSourceCreate(data) { 10 export function DataSourceCreate(data) {
11 return request({ 11 return request({
12 - url: '/api/system/DataSource', 12 + url: '/system/DataSource',
13 method: 'post', 13 method: 'post',
14 data 14 data
15 }) 15 })
16 } 16 }
17 export function DataSourceDelete(id) { 17 export function DataSourceDelete(id) {
18 return request({ 18 return request({
19 - url: `/api/system/DataSource/${id}`, 19 + url: `/system/DataSource/${id}`,
20 method: 'delete', 20 method: 'delete',
21 }) 21 })
22 } 22 }
23 export function DataSourceInfo(id) { 23 export function DataSourceInfo(id) {
24 return request({ 24 return request({
25 - url: `/api/system/DataSource/${id}`, 25 + url: `/system/DataSource/${id}`,
26 method: 'get', 26 method: 'get',
27 }) 27 })
28 } 28 }
29 export function DataSourceUpdate(data) { 29 export function DataSourceUpdate(data) {
30 return request({ 30 return request({
31 - url: `/api/system/DataSource/${data.id}`, 31 + url: `/system/DataSource/${data.id}`,
32 method: 'put', 32 method: 'put',
33 data 33 data
34 }) 34 })
35 } 35 }
36 export function TestDbConnection(data) { 36 export function TestDbConnection(data) {
37 return request({ 37 return request({
38 - url: `/api/system/DataSource/Actions/Test`, 38 + url: `/system/DataSource/Actions/Test`,
39 method: 'post', 39 method: 'post',
40 data 40 data
41 }) 41 })
42 } 42 }
43 export function getDataSourceListAll() { 43 export function getDataSourceListAll() {
44 return request({ 44 return request({
45 - url: '/api/system/DataSource/Selector', 45 + url: '/system/DataSource/Selector',
46 method: 'get', 46 method: 'get',
47 }) 47 })
48 } 48 }
49 export function Execute(data) { 49 export function Execute(data) {
50 return request({ 50 return request({
51 - url: `/api/system/DataSync/Actions/Execute`, 51 + url: `/system/DataSync/Actions/Execute`,
52 method: 'post', 52 method: 'post',
53 data 53 data
54 }) 54 })
src/api/systemData/dictionary.js
@@ -3,7 +3,7 @@ import request from '@/utils/request' @@ -3,7 +3,7 @@ import request from '@/utils/request'
3 // 获取数据字典分类 3 // 获取数据字典分类
4 export function getDictionaryType() { 4 export function getDictionaryType() {
5 return request({ 5 return request({
6 - url: '/api/system/DictionaryType', 6 + url: '/system/DictionaryType',
7 method: 'GET' 7 method: 'GET'
8 }) 8 })
9 } 9 }
@@ -11,7 +11,7 @@ export function getDictionaryType() { @@ -11,7 +11,7 @@ export function getDictionaryType() {
11 // 获取字典分类下拉框列表 11 // 获取字典分类下拉框列表
12 export function getDictionaryTypeSelector(id) { 12 export function getDictionaryTypeSelector(id) {
13 return request({ 13 return request({
14 - url: '/api/system/DictionaryType/Selector/' + (!!id ? id : 0), 14 + url: '/system/DictionaryType/Selector/' + (!!id ? id : 0),
15 method: 'GET' 15 method: 'GET'
16 }) 16 })
17 } 17 }
@@ -19,7 +19,7 @@ export function getDictionaryTypeSelector(id) { @@ -19,7 +19,7 @@ export function getDictionaryTypeSelector(id) {
19 // 添加数据字典分类 19 // 添加数据字典分类
20 export function createDictionaryType(data) { 20 export function createDictionaryType(data) {
21 return request({ 21 return request({
22 - url: `/api/system/DictionaryType`, 22 + url: `/system/DictionaryType`,
23 method: 'POST', 23 method: 'POST',
24 data 24 data
25 }) 25 })
@@ -28,7 +28,7 @@ export function createDictionaryType(data) { @@ -28,7 +28,7 @@ export function createDictionaryType(data) {
28 // 修改数据字典分类 28 // 修改数据字典分类
29 export function updateDictionaryType(data) { 29 export function updateDictionaryType(data) {
30 return request({ 30 return request({
31 - url: `/api/system/DictionaryType/${data.id}`, 31 + url: `/system/DictionaryType/${data.id}`,
32 method: 'PUT', 32 method: 'PUT',
33 data 33 data
34 }) 34 })
@@ -37,7 +37,7 @@ export function updateDictionaryType(data) { @@ -37,7 +37,7 @@ export function updateDictionaryType(data) {
37 // 获取数据字典分类信息 37 // 获取数据字典分类信息
38 export function getDictionaryTypeInfo(id) { 38 export function getDictionaryTypeInfo(id) {
39 return request({ 39 return request({
40 - url: `/api/system/DictionaryType/${id}`, 40 + url: `/system/DictionaryType/${id}`,
41 method: 'GET' 41 method: 'GET'
42 }) 42 })
43 } 43 }
@@ -45,7 +45,7 @@ export function getDictionaryTypeInfo(id) { @@ -45,7 +45,7 @@ export function getDictionaryTypeInfo(id) {
45 // 删除数据字典分类 45 // 删除数据字典分类
46 export function delDictionaryType(id) { 46 export function delDictionaryType(id) {
47 return request({ 47 return request({
48 - url: `/api/system/DictionaryType/${id}`, 48 + url: `/system/DictionaryType/${id}`,
49 method: 'DELETE' 49 method: 'DELETE'
50 }) 50 })
51 } 51 }
@@ -53,7 +53,7 @@ export function delDictionaryType(id) { @@ -53,7 +53,7 @@ export function delDictionaryType(id) {
53 // 获取数据字典列表 53 // 获取数据字典列表
54 export function getDictionaryDataList(typeId, data) { 54 export function getDictionaryDataList(typeId, data) {
55 return request({ 55 return request({
56 - url: `/api/system/DictionaryData/${typeId}`, 56 + url: `/system/DictionaryData/${typeId}`,
57 method: 'GET', 57 method: 'GET',
58 data 58 data
59 }) 59 })
@@ -62,7 +62,7 @@ export function getDictionaryDataList(typeId, data) { @@ -62,7 +62,7 @@ export function getDictionaryDataList(typeId, data) {
62 // 获取数据字典列表(分类+内容) 62 // 获取数据字典列表(分类+内容)
63 export function getDictionaryAll() { 63 export function getDictionaryAll() {
64 return request({ 64 return request({
65 - url: `/api/system/DictionaryData/All`, 65 + url: `/system/DictionaryData/All`,
66 method: 'GET' 66 method: 'GET'
67 }) 67 })
68 } 68 }
@@ -70,7 +70,7 @@ export function getDictionaryAll() { @@ -70,7 +70,7 @@ export function getDictionaryAll() {
70 // 获取字典分类下拉框(项目上级) 70 // 获取字典分类下拉框(项目上级)
71 export function getDictionaryDataTypeSelector(dictionaryTypeId, isTree, id) { 71 export function getDictionaryDataTypeSelector(dictionaryTypeId, isTree, id) {
72 return request({ 72 return request({
73 - url: `/api/system/DictionaryData/${dictionaryTypeId}/Selector/` + (!!id ? id : 0), 73 + url: `/system/DictionaryData/${dictionaryTypeId}/Selector/` + (!!id ? id : 0),
74 method: 'GET', 74 method: 'GET',
75 data: { isTree } 75 data: { isTree }
76 }) 76 })
@@ -79,7 +79,7 @@ export function getDictionaryDataTypeSelector(dictionaryTypeId, isTree, id) { @@ -79,7 +79,7 @@ export function getDictionaryDataTypeSelector(dictionaryTypeId, isTree, id) {
79 // 获取字典数据下拉框列表 79 // 获取字典数据下拉框列表
80 export function getDictionaryDataSelector(dictionaryTypeId) { 80 export function getDictionaryDataSelector(dictionaryTypeId) {
81 return request({ 81 return request({
82 - url: `/api/system/DictionaryData/${dictionaryTypeId}/Data/Selector`, 82 + url: `/system/DictionaryData/${dictionaryTypeId}/Data/Selector`,
83 method: 'GET' 83 method: 'GET'
84 }) 84 })
85 } 85 }
@@ -87,7 +87,7 @@ export function getDictionaryDataSelector(dictionaryTypeId) { @@ -87,7 +87,7 @@ export function getDictionaryDataSelector(dictionaryTypeId) {
87 // 添加数据字典 87 // 添加数据字典
88 export function createDictionaryData(data) { 88 export function createDictionaryData(data) {
89 return request({ 89 return request({
90 - url: '/api/system/DictionaryData', 90 + url: '/system/DictionaryData',
91 method: 'POST', 91 method: 'POST',
92 data 92 data
93 }) 93 })
@@ -96,7 +96,7 @@ export function createDictionaryData(data) { @@ -96,7 +96,7 @@ export function createDictionaryData(data) {
96 // 修改数据字典 96 // 修改数据字典
97 export function updateDictionaryData(data) { 97 export function updateDictionaryData(data) {
98 return request({ 98 return request({
99 - url: `/api/system/DictionaryData/${data.id}`, 99 + url: `/system/DictionaryData/${data.id}`,
100 method: 'PUT', 100 method: 'PUT',
101 data 101 data
102 }) 102 })
@@ -105,7 +105,7 @@ export function updateDictionaryData(data) { @@ -105,7 +105,7 @@ export function updateDictionaryData(data) {
105 // 获取数据字典信息 105 // 获取数据字典信息
106 export function getDictionaryDataInfo(id) { 106 export function getDictionaryDataInfo(id) {
107 return request({ 107 return request({
108 - url: `/api/system/DictionaryData/${id}/Info`, 108 + url: `/system/DictionaryData/${id}/Info`,
109 method: 'GET' 109 method: 'GET'
110 }) 110 })
111 } 111 }
@@ -113,7 +113,7 @@ export function getDictionaryDataInfo(id) { @@ -113,7 +113,7 @@ export function getDictionaryDataInfo(id) {
113 // 删除数据字典信息 113 // 删除数据字典信息
114 export function delDictionaryData(id) { 114 export function delDictionaryData(id) {
115 return request({ 115 return request({
116 - url: `/api/system/DictionaryData/${id}`, 116 + url: `/system/DictionaryData/${id}`,
117 method: 'DELETE' 117 method: 'DELETE'
118 }) 118 })
119 } 119 }
@@ -121,7 +121,7 @@ export function delDictionaryData(id) { @@ -121,7 +121,7 @@ export function delDictionaryData(id) {
121 // 更新字典状态 121 // 更新字典状态
122 export function updateDictionaryState(id) { 122 export function updateDictionaryState(id) {
123 return request({ 123 return request({
124 - url: `/api/system/DictionaryData/${id}/Actions/State`, 124 + url: `/system/DictionaryData/${id}/Actions/State`,
125 method: 'PUT' 125 method: 'PUT'
126 }) 126 })
127 } 127 }
@@ -129,7 +129,7 @@ export function updateDictionaryState(id) { @@ -129,7 +129,7 @@ export function updateDictionaryState(id) {
129 // 导出数据字典数据 129 // 导出数据字典数据
130 export function exportData(id) { 130 export function exportData(id) {
131 return request({ 131 return request({
132 - url: `/api/system/DictionaryData/${id}/Action/Export`, 132 + url: `/system/DictionaryData/${id}/Action/Export`,
133 method: 'GET' 133 method: 'GET'
134 }) 134 })
135 } 135 }
136 \ No newline at end of file 136 \ No newline at end of file
src/components/NCC-treeSelect/index.vue 0 → 100644
  1 +<template>
  2 + <el-select :value="valueTitle" :clearable="clearable" :disabled="disabled" @clear="clearHandle"
  3 + ref='elSelect' :placeholder="placeholder" :popper-class="`NCC-select-tree blue`"
  4 + @focus="selectFocus" :filterable="filterable" :filter-method="selectFilter"
  5 + class="NCC-selectTree">
  6 + <el-option :value="valueTitle" :label="valueTitle" class="options">
  7 + <el-tree id="tree-option" ref="selectTree" :accordion="accordion" :data="options"
  8 + :default-expand-all="defaultExpandAll" :props="props" :node-key="props.value"
  9 + :default-expanded-keys="defaultExpandedKey" @node-click="handleNodeClick"
  10 + :filter-node-method="filterNode" :show-checkbox="multiple" :check-on-click-node="multiple"
  11 + :class="{'single':!multiple}" :expand-on-click-node="!multiple" @check="check"
  12 + v-show="options.length">
  13 + <span class="custom-tree-node" slot-scope="{ node, data }">
  14 + <slot :data="{ node, data }">
  15 + <i :class="data.icon" v-if="data.icon"></i>
  16 + <span class="text">{{node.label}}</span>
  17 + </slot>
  18 + <!-- 自定义slot示例 开始 -->
  19 + <!-- <template slot-scope="{data}">
  20 + <i :class="data.data.icon"></i>
  21 + <span class="text">{{data.node.label}}</span>
  22 + </template> -->
  23 + <!-- 自定义slot示例 结束 -->
  24 + </span>
  25 + </el-tree>
  26 + <p v-show="!options.length" class="empty-text">无数据</p>
  27 + </el-option>
  28 + </el-select>
  29 +</template>
  30 +
  31 +<script>
  32 +import { mapState } from 'vuex'
  33 +export default {
  34 + name: "el-tree-select",
  35 + props: {
  36 + // 配置项
  37 + props: {
  38 + type: Object,
  39 + default: () => ({
  40 + value: 'id', // ID字段名
  41 + label: 'fullName', // 显示名称
  42 + children: 'children', // 子级字段名
  43 + })
  44 + },
  45 + // 是否禁用
  46 + disabled: { type: Boolean, default: false },
  47 + // 选项列表数据(树形结构的对象数组)
  48 + options: { type: Array, default: () => [] },
  49 + placeholder: { type: String, default: '请选择' },
  50 + // 初始值
  51 + value: '',
  52 + // 可清空选项
  53 + clearable: { type: Boolean, default: false },
  54 + // 能否搜索
  55 + filterable: { type: Boolean, default: false },
  56 + // 只能选择最后一层的数值
  57 + lastLevel: { type: Boolean, default: false },
  58 + // 只能选择最后一层的数值时,需要根据 lastLevelKey来判断是否最后一层
  59 + lastLevelKey: { type: String, default: "hasChildren" },
  60 + lastLevelValue: { default: false },
  61 + // 自动收起
  62 + accordion: { type: Boolean, default: false },
  63 + defaultExpandAll: { type: Boolean, default: true },
  64 + multiple: { type: Boolean, default: false }, // 是否多选,默认单选
  65 + },
  66 + computed: {
  67 + // ...mapState({
  68 + // themeClass: state => state.settings.themeClass
  69 + // })
  70 + },
  71 + data() {
  72 + return {
  73 + valueTitle: '',
  74 + defaultExpandedKey: []
  75 + }
  76 + },
  77 + mounted() {
  78 + if (this.value) {
  79 + this.initHandle()
  80 + }
  81 + },
  82 + methods: {
  83 + selectFilter(val) {
  84 + if (this.options.length) this.$refs.selectTree.filter(val);
  85 + },
  86 + filterNode(value, data) {
  87 + if (!value) return true;
  88 + return data[this.props.label].indexOf(value) !== -1;
  89 + },
  90 + selectFocus() {
  91 + this.initHandle()
  92 + },
  93 + // 初始化值
  94 + initHandle() {
  95 + this.$refs.selectTree.filter('');
  96 + if (this.value) {
  97 + if (this.multiple) {
  98 + setTimeout(() => {
  99 + let arr = this.value.split(','), titleList = []
  100 + this.$refs.selectTree.setCheckedKeys(arr)
  101 + if (this.lastLevel) {
  102 + titleList = this.$refs.selectTree.getCheckedNodes(true).map(o => o[this.props.label])
  103 + } else {
  104 + titleList = this.$refs.selectTree.getCheckedNodes().map(o => o[this.props.label])
  105 + }
  106 + this.valueTitle = titleList.join(',')
  107 + }, 10)
  108 + } else {
  109 + setTimeout(() => {
  110 + this.valueTitle = this.$refs.selectTree.getNode(this.value) ? this.$refs.selectTree.getNode(this.value).data[this.props.label] : '' // 初始化显示
  111 + this.$refs.selectTree.setCurrentKey(this.value) // 设置默认选中
  112 + this.defaultExpandedKey = [this.value] // 设置默认展开
  113 + }, 10);
  114 + }
  115 + } else {
  116 + this.valueTitle = ''
  117 + if (this.multiple) {
  118 + this.$refs.selectTree.setCheckedKeys([])
  119 + } else {
  120 + this.$refs.selectTree.setCurrentKey(null)
  121 + }
  122 + }
  123 + this.initScroll()
  124 + },
  125 + // 初始化滚动条
  126 + initScroll() {
  127 + this.$nextTick(() => {
  128 + let list = document.querySelectorAll('.NCC-select-tree .el-scrollbar .el-select-dropdown__wrap')
  129 + // 有多个下拉框,造成页面错位
  130 + let index = list.length - 1
  131 + let scrollWrap = list[index]
  132 + let scrollBar = document.querySelectorAll('.el-scrollbar .el-scrollbar__bar')
  133 + scrollWrap.style && (scrollWrap.style.cssText = 'margin: 0px; max-height: none; overflow: hidden;')
  134 + for (let i = 0; i < scrollBar.length; i++) {
  135 + scrollBar[i].style.width = 0
  136 + }
  137 + })
  138 + },
  139 + // 单选切换选项
  140 + handleNodeClick(node) {
  141 + if (!this.multiple) {
  142 + if (this.lastLevel && node[this.lastLevelKey] && node[this.lastLevelKey] != this.lastLevelValue) return
  143 + this.valueTitle = node[this.props.label]
  144 + this.$emit('input', node[this.props.value], node)
  145 + this.$emit('change', node[this.props.value], node)
  146 + this.defaultExpandedKey = []
  147 + this.$refs.elSelect.blur()
  148 + }
  149 + },
  150 + // 多选选择
  151 + check(node) {
  152 + if (!this.multiple) return
  153 + let selectedData = [], titleList = [], selectedTextData = []
  154 + if (this.lastLevel) {
  155 + selectedTextData = this.$refs.selectTree.getCheckedNodes(true)
  156 + for (let i = 0; i < selectedTextData.length; i++) {
  157 + const e = selectedTextData[i];
  158 + if (e[this.lastLevelKey] == this.lastLevelValue) {
  159 + selectedData.push(e[this.props.value])
  160 + titleList.push(e[this.props.label])
  161 + }
  162 + }
  163 + } else {
  164 + selectedTextData = this.$refs.selectTree.getCheckedNodes()
  165 + for (let i = 0; i < selectedTextData.length; i++) {
  166 + const e = selectedTextData[i];
  167 + selectedData.push(e[this.props.value])
  168 + titleList.push(e[this.props.label])
  169 + }
  170 + }
  171 + this.valueTitle = titleList.join(',')
  172 + this.$emit('input', selectedData.join(','), selectedTextData)
  173 + this.$emit('change', selectedData.join(','), selectedTextData)
  174 + },
  175 + // 清除选中
  176 + clearHandle() {
  177 + this.valueTitle = ''
  178 + this.$emit('input', '')
  179 + this.$emit('change', '')
  180 + this.defaultExpandedKey = []
  181 + this.clearSelected()
  182 + if (this.multiple) this.$refs.selectTree.setCheckedKeys([])
  183 + },
  184 + // 清空选中样式
  185 + clearSelected() {
  186 + let allNode = document.querySelectorAll('#tree-option .el-tree-node')
  187 + for (let i = 0; i < allNode.length; i++) {
  188 + allNode[i].classList.remove('is-current')
  189 + }
  190 + }
  191 + },
  192 + watch: {
  193 + value(val) {
  194 + this.initHandle()
  195 + },
  196 + options(val) {
  197 + if (this.value) this.initHandle()
  198 + }
  199 + }
  200 +}
  201 +</script>
  202 +
  203 +<style lang="scss" scoped>
  204 +.NCC-selectTree {
  205 + width: 100%;
  206 +}
  207 +.el-scrollbar .el-scrollbar__view .el-select-dropdown__item {
  208 + height: auto;
  209 + max-height: 274px;
  210 + padding: 0;
  211 + overflow: hidden;
  212 + overflow-y: auto;
  213 +}
  214 +.el-select-dropdown__item.selected {
  215 + font-weight: normal;
  216 +}
  217 +ul li::-webkit-scrollbar-track {
  218 + border-radius: 0;
  219 + background-color: #fff;
  220 +}
  221 +ul li >>> .el-tree .el-tree-node__content {
  222 + height: auto;
  223 + padding: 0 20px;
  224 +}
  225 +.el-tree-node__label {
  226 + font-weight: normal;
  227 +}
  228 +.el-tree.single >>> .is-current .el-tree-node__label {
  229 + color: #409eff;
  230 + font-weight: 700;
  231 +}
  232 +.el-tree.single >>> .is-current .el-tree-node__content .custom-tree-node {
  233 + color: #409eff;
  234 + font-weight: 700;
  235 +}
  236 +.el-tree.single >>> .is-current .el-tree-node__children .custom-tree-node {
  237 + color: #606266;
  238 + font-weight: normal;
  239 +}
  240 +.el-tree.single >>> .is-current .el-tree-node__children .el-tree-node__label {
  241 + color: #606266;
  242 + font-weight: normal;
  243 +}
  244 +.empty-text {
  245 + margin: 0;
  246 + text-align: center;
  247 + color: #999;
  248 + font-size: 14px;
  249 + background: #fff;
  250 + cursor: auto;
  251 + padding: 0;
  252 + line-height: 24px;
  253 +}
  254 +</style>
0 \ No newline at end of file 255 \ No newline at end of file
src/components/Screenfull/index.vue 0 → 100644
  1 +<template>
  2 + <el-tooltip effect="dark"
  3 + :content="isFullscreen?$t('common.outFullScreen'):$t('common.fullScreen')" placement="top">
  4 + <el-link
  5 + :icon="`icon-ym ${isFullscreen?'icon-ym-compress-screen1':'icon-ym-full-screen1'} NCC-common-head-icon`"
  6 + :underline="false" @click="click()" />
  7 + </el-tooltip>
  8 +</template>
  9 +
  10 +<script>
  11 +import screenfull from 'screenfull'
  12 +
  13 +export default {
  14 + props: {
  15 + isContainer: {
  16 + type: Boolean,
  17 + default: true
  18 + }
  19 + },
  20 + name: 'Screenfull',
  21 + data() {
  22 + return {
  23 + refEle: '',
  24 + isFullscreen: false
  25 + }
  26 + },
  27 + mounted() {
  28 + this.init()
  29 + this.refEle = this.$options.parent.$el
  30 + },
  31 + beforeDestroy() {
  32 + this.destroy()
  33 + },
  34 + methods: {
  35 + click() {
  36 + if (!screenfull.enabled) {
  37 + this.$message({
  38 + message: '不支持全屏',
  39 + type: 'warning'
  40 + })
  41 + return false
  42 + }
  43 + if (this.isContainer) {
  44 + screenfull.toggle(this.refEle)
  45 + } else {
  46 + screenfull.toggle()
  47 + }
  48 + },
  49 + change() {
  50 + this.isFullscreen = screenfull.isFullscreen
  51 + },
  52 + init() {
  53 + if (screenfull.enabled) {
  54 + screenfull.on('change', this.change)
  55 + }
  56 + },
  57 + destroy() {
  58 + if (screenfull.enabled) {
  59 + screenfull.off('change', this.change)
  60 + }
  61 + }
  62 + }
  63 +}
  64 +</script>
0 \ No newline at end of file 65 \ No newline at end of file
src/components/index.js
@@ -7,6 +7,9 @@ import Pagination from &#39;@/components/Pagination&#39; @@ -7,6 +7,9 @@ import Pagination from &#39;@/components/Pagination&#39;
7 import NCCTable from '@/components/NCC-table' 7 import NCCTable from '@/components/NCC-table'
8 import NCCUploadFz from '@/components/Generator/components/Upload/UploadFz' 8 import NCCUploadFz from '@/components/Generator/components/Upload/UploadFz'
9 import NCCQuill from '@/components/NCCEditor/quill' 9 import NCCQuill from '@/components/NCCEditor/quill'
  10 +import DepSelect from '@/components/Generator/components/DepSelect'
  11 +import Screenfull from '@/components/Screenfull'
  12 +import NCCTreeSelect from '@/components/NCC-treeSelect'
10 13
11 export default { 14 export default {
12 install(Vue, options) { 15 install(Vue, options) {
@@ -19,6 +22,10 @@ export default { @@ -19,6 +22,10 @@ export default {
19 Vue.component('NCCTable', NCCTable) 22 Vue.component('NCCTable', NCCTable)
20 Vue.component('NCCUploadFz', NCCUploadFz) 23 Vue.component('NCCUploadFz', NCCUploadFz)
21 Vue.component('NCCQuill', NCCQuill) 24 Vue.component('NCCQuill', NCCQuill)
  25 + Vue.component('DepSelect', DepSelect)
  26 + Vue.component('NCCTreeSelect', NCCTreeSelect)
  27 + Vue.component('Screenfull', Screenfull)
  28 +
22 29
23 } 30 }
24 } 31 }
25 \ No newline at end of file 32 \ No newline at end of file
src/store/index.js
@@ -4,6 +4,7 @@ import user from &#39;./modules/user&#39; @@ -4,6 +4,7 @@ import user from &#39;./modules/user&#39;
4 import meta from './modules/meta' 4 import meta from './modules/meta'
5 import getters from './getters' 5 import getters from './getters'
6 import permission from './modules/permission' 6 import permission from './modules/permission'
  7 +import generator from './modules/generator'
7 8
8 Vue.use(Vuex) 9 Vue.use(Vuex)
9 10
@@ -12,6 +13,7 @@ const store = new Vuex.Store({ @@ -12,6 +13,7 @@ const store = new Vuex.Store({
12 user, 13 user,
13 meta, 14 meta,
14 permission, 15 permission,
  16 + generator
15 }, 17 },
16 getters 18 getters
17 }) 19 })
src/store/modules/generator.js 0 → 100644
  1 +import { getOrganizeTree } from '@/api/permission/organize'
  2 +import { getDepartmentSelector } from '@/api/permission/department'
  3 +import { getDictionaryType } from '@/api/systemData/dictionary'
  4 +
  5 +const state = {
  6 + companyTree: [],
  7 + depTree: [],
  8 + dicTree: [],
  9 + formItemList: [],
  10 + subTable: [],
  11 + hasTable: false,
  12 + relationData: {}
  13 +}
  14 +
  15 +const mutations = {
  16 + SET_COMPANY_TREE: (state, companyTree) => {
  17 + state.companyTree = companyTree
  18 + },
  19 + SET_DEP_TREE: (state, depTree) => {
  20 + state.depTree = depTree
  21 + },
  22 + SET_DIC_TREE: (state, dicTree) => {
  23 + state.dicTree = dicTree
  24 + },
  25 + UPDATE_FORMITEM_LIST(state, list) {
  26 + state.formItemList = list
  27 + },
  28 + UPDATE_SUB_TABLE(state, subTable) {
  29 + state.subTable = subTable
  30 + },
  31 + SET_TABLE(state, val) {
  32 + state.hasTable = val
  33 + },
  34 + UPDATE_RELATION_DATA(state, val) {
  35 + state.relationData = val
  36 + }
  37 +}
  38 +
  39 +const actions = {
  40 + getCompanyTree({ state, commit }) {
  41 + return new Promise((resolve, reject) => {
  42 + if (!state.companyTree.length) {
  43 + getOrganizeTree().then(res => {
  44 + commit('SET_COMPANY_TREE', res.data.list)
  45 + resolve(res.data.list)
  46 + }).catch(error => {
  47 + reject(error)
  48 + })
  49 + } else {
  50 + resolve(state.companyTree)
  51 + }
  52 + })
  53 + },
  54 + getDepTree({ state, commit }) {
  55 + return new Promise((resolve, reject) => {
  56 + if (!state.depTree.length) {
  57 + getDepartmentSelector().then(res => {
  58 + commit('SET_DEP_TREE', res.data.list)
  59 + resolve(res.data.list)
  60 + }).catch(error => {
  61 + reject(error)
  62 + })
  63 + } else {
  64 + resolve(state.depTree)
  65 + }
  66 + })
  67 + },
  68 + getDicTree({ state, commit }) {
  69 + return new Promise((resolve, reject) => {
  70 + if (!state.dicTree.length) {
  71 + getDictionaryType().then(res => {
  72 + commit('SET_DIC_TREE', res.data.list)
  73 + resolve(res.data.list)
  74 + }).catch(error => {
  75 + reject(error)
  76 + })
  77 + } else {
  78 + resolve(state.dicTree)
  79 + }
  80 + })
  81 + },
  82 +}
  83 +
  84 +export default {
  85 + namespaced: true,
  86 + state,
  87 + mutations,
  88 + actions
  89 +}
0 \ No newline at end of file 90 \ No newline at end of file
src/views/baseComapnyInfo/index.vue
@@ -7,7 +7,7 @@ @@ -7,7 +7,7 @@
7 <el-row class="NCC-common-search-box" :gutter="16"> 7 <el-row class="NCC-common-search-box" :gutter="16">
8 <el-form @submit.native.prevent size="mini"> 8 <el-form @submit.native.prevent size="mini">
9 <el-col :span="5"> 9 <el-col :span="5">
10 - <el-form-item label="公司名称"> 10 + <el-form-item label="">
11 <el-input 11 <el-input
12 v-model="query.companyName" 12 v-model="query.companyName"
13 placeholder="公司名称" 13 placeholder="公司名称"
@@ -16,7 +16,7 @@ @@ -16,7 +16,7 @@
16 </el-form-item> 16 </el-form-item>
17 </el-col> 17 </el-col>
18 <el-col :span="5"> 18 <el-col :span="5">
19 - <el-form-item label="公司法人"> 19 + <el-form-item label="">
20 <el-input 20 <el-input
21 v-model="query.legalPerson" 21 v-model="query.legalPerson"
22 placeholder="公司法人" 22 placeholder="公司法人"
@@ -25,7 +25,7 @@ @@ -25,7 +25,7 @@
25 </el-form-item> 25 </el-form-item>
26 </el-col> 26 </el-col>
27 <el-col :span="5"> 27 <el-col :span="5">
28 - <el-form-item label="社会信用代"> 28 + <el-form-item label="">
29 <el-input 29 <el-input
30 v-model="query.socialCreditAgency" 30 v-model="query.socialCreditAgency"
31 placeholder="社会信用代" 31 placeholder="社会信用代"
@@ -61,6 +61,7 @@ @@ -61,6 +61,7 @@
61 type="primary" 61 type="primary"
62 icon="el-icon-plus" 62 icon="el-icon-plus"
63 @click="addOrUpdateHandle()" 63 @click="addOrUpdateHandle()"
  64 + size="mini"
64 >新增</el-button 65 >新增</el-button
65 > 66 >
66 </div> 67 </div>
@@ -70,21 +71,25 @@ @@ -70,21 +71,25 @@
70 <el-table-column 71 <el-table-column
71 prop="companyName" 72 prop="companyName"
72 label="公司名称" 73 label="公司名称"
  74 + show-overflow-tooltip
73 align="left" 75 align="left"
74 /> 76 />
75 <el-table-column 77 <el-table-column
76 prop="socialCreditAgency" 78 prop="socialCreditAgency"
77 label="社会信用代" 79 label="社会信用代"
  80 + show-overflow-tooltip
78 align="left" 81 align="left"
79 /> 82 />
80 <el-table-column 83 <el-table-column
81 prop="legalPerson" 84 prop="legalPerson"
82 label="公司法人" 85 label="公司法人"
  86 + show-overflow-tooltip
83 align="left" 87 align="left"
84 /> 88 />
85 <el-table-column prop="address" label="公司地址" align="left" /> 89 <el-table-column prop="address" label="公司地址" align="left" />
86 <el-table-column 90 <el-table-column
87 prop="contactInformation" 91 prop="contactInformation"
  92 + show-overflow-tooltip
88 label="联系方式" 93 label="联系方式"
89 align="left" 94 align="left"
90 /> 95 />
@@ -257,5 +262,8 @@ export default { @@ -257,5 +262,8 @@ export default {
257 height: calc(100% - 47px); 262 height: calc(100% - 47px);
258 overflow-y: scroll; 263 overflow-y: scroll;
259 } 264 }
  265 + .item-body {
  266 + height: calc(100% - 35px);
  267 + }
260 } 268 }
261 </style> 269 </style>
src/views/baseInspectionReport/ExportBox.vue 0 → 100644
  1 +<template>
  2 + <el-dialog title="导出数据" :close-on-click-modal="false" :visible.sync="visible"
  3 + class="NCC-dialog NCC-dialog_center" lock-scroll width="600px">
  4 + <el-form label-position="top" label-width="80px">
  5 + <el-form-item label="数据选择">
  6 + <el-radio-group v-model="type">
  7 + <el-radio :label="0">当前页面数据</el-radio>
  8 + <el-radio :label="1">全部页面数据</el-radio>
  9 + </el-radio-group>
  10 + </el-form-item>
  11 + <el-form-item label="导出字段">
  12 + <el-checkbox :indeterminate="isIndeterminate" v-model="checkAll"
  13 + @change="handleCheckAllChange">全选</el-checkbox>
  14 + <el-checkbox-group v-model="columns" @change="handleCheckedChange">
  15 + <el-checkbox v-for="item in columnList" :label="item.prop" :key="item.prop">
  16 + {{item.label}}
  17 + </el-checkbox>
  18 + </el-checkbox-group>
  19 + </el-form-item>
  20 + </el-form>
  21 + <span slot="footer" class="dialog-footer">
  22 + <el-button @click="visible=false">取 消</el-button>
  23 + <el-button type="primary" @click="downLoad">导 出</el-button>
  24 + </span>
  25 + </el-dialog>
  26 +</template>
  27 +
  28 +<script>
  29 +export default {
  30 + data() {
  31 + return {
  32 + visible: false,
  33 + btnLoading: false,
  34 + type: 0,
  35 + columns: [],
  36 + checkAll: true,
  37 + isIndeterminate: false,
  38 + columnList: []
  39 + }
  40 + },
  41 + methods: {
  42 + init(columnList) {
  43 + this.visible = true
  44 + this.columnList = columnList
  45 + this.columns = columnList.map(o => o.prop)
  46 + },
  47 + handleCheckAllChange(val) {
  48 + this.columns = val ? this.columnList.map(o => o.prop) : [];
  49 + this.isIndeterminate = false;
  50 + },
  51 + handleCheckedChange(value) {
  52 + let checkedCount = value.length;
  53 + this.checkAll = checkedCount === this.columnList.length;
  54 + this.isIndeterminate = checkedCount > 0 && checkedCount < this.columnList.length;
  55 + },
  56 + downLoad() {
  57 + this.$emit('download', { dataType: this.type, selectKey: this.columns.join(',') })
  58 + }
  59 + }
  60 +}
  61 +</script>
  62 +<style lang="scss" scoped>
  63 +>>> .el-dialog__body {
  64 + padding: 20px !important;
  65 +}
  66 +</style>
0 \ No newline at end of file 67 \ No newline at end of file
src/views/baseInspectionReport/Form.vue 0 → 100644
  1 +<template>
  2 + <el-dialog :title="!dataForm.id ? '新建' : isDetail ? '详情':'编辑'" :close-on-click-modal="false" :visible.sync="visible" class="NCC-dialog NCC-dialog_center" lock-scroll width="70%">
  3 + <el-row :gutter="15" class="" >
  4 + <el-form ref="elForm" :model="dataForm" size="small" label-width="100px" label-position="right" :disabled="!!isDetail" :rules="rules">
  5 + <el-col :span="24" v-if="false" >
  6 + <el-form-item label="主键" prop="id">
  7 + <el-input v-model="dataForm.id" placeholder="请输入" clearable :style='{"width":"100%"}' >
  8 + </el-input>
  9 + </el-form-item>
  10 + </el-col>
  11 + <el-col :span="24">
  12 + <el-form-item label="来源" prop="source">
  13 + <el-select v-model="dataForm.source" placeholder="请选择" clearable :style='{"width":"100%"}' >
  14 + <el-option v-for="(item, index) in sourceOptions" :key="index" :label="item.fullName" :value="item.id" ></el-option>
  15 + </el-select>
  16 + </el-form-item>
  17 + </el-col>
  18 + <el-col :span="24">
  19 + <el-form-item label="平台名称" prop="platformName">
  20 + <el-input v-model="dataForm.platformName" placeholder="请输入" clearable :style='{"width":"100%"}' >
  21 + </el-input>
  22 + </el-form-item>
  23 + </el-col>
  24 + <el-col :span="24">
  25 + <el-form-item label="平台类型" prop="platformType">
  26 + <el-select v-model="dataForm.platformType" placeholder="请选择" clearable :style='{"width":"100%"}' >
  27 + <el-option v-for="(item, index) in platformTypeOptions" :key="index" :label="item.fullName" :value="item.id" ></el-option>
  28 + </el-select>
  29 + </el-form-item>
  30 + </el-col>
  31 + <el-col :span="24">
  32 + <el-form-item label="部门" prop="department">
  33 + <dep-select v-model="dataForm.department" placeholder="请选择" clearable >
  34 + </dep-select>
  35 + </el-form-item>
  36 + </el-col>
  37 + <el-col :span="24">
  38 + <el-form-item label="问题类型" prop="questionType">
  39 + <el-radio-group v-model="dataForm.questionType" :style='{}' >
  40 + <el-radio v-for="(item, index) in questionTypeOptions" :key="index" :label="item.id" >{{item.fullName}}</el-radio>
  41 + </el-radio-group>
  42 + </el-form-item>
  43 + </el-col>
  44 + <el-col :span="24">
  45 + <el-form-item label="问题分类" prop="questionClass">
  46 + <el-select v-model="dataForm.questionClass" placeholder="请选择" clearable :style='{"width":"100%"}' >
  47 + <el-option v-for="(item, index) in questionClassOptions" :key="index" :label="item.fullName" :value="item.id" ></el-option>
  48 + </el-select>
  49 + </el-form-item>
  50 + </el-col>
  51 + <el-col :span="24">
  52 + <el-form-item label="问题内容" prop="questionContent">
  53 + <el-input v-model="dataForm.questionContent" placeholder="请输入" show-word-limit :style='{"width":"100%"}' type='textarea' :autosize='{"minRows":4,"maxRows":4}' >
  54 + </el-input>
  55 + </el-form-item>
  56 + </el-col>
  57 + <el-col :span="24">
  58 + <el-form-item label="有害链接" prop="link">
  59 + <el-input v-model="dataForm.link" placeholder="请输入" clearable :style='{"width":"100%"}' >
  60 + </el-input>
  61 + </el-form-item>
  62 + </el-col>
  63 + <el-col :span="24">
  64 + <el-form-item label="取证内容" prop="obtainEvidence">
  65 + <NCC-UploadFz v-model="dataForm.obtainEvidence" :fileSize="5" sizeUnit="MB" :limit="9" buttonText="点击上传" >
  66 + </NCC-UploadFz>
  67 + </el-form-item>
  68 + </el-col>
  69 + <el-col :span="24">
  70 + <el-form-item label="附件上传" prop="annex">
  71 + <NCC-UploadFz v-model="dataForm.annex" :fileSize="5" sizeUnit="MB" :limit="9" buttonText="点击上传" >
  72 + </NCC-UploadFz>
  73 + </el-form-item>
  74 + </el-col>
  75 + <el-col :span="24">
  76 + <el-form-item label="处置建议" prop="disposalSuggestions">
  77 + <el-input v-model="dataForm.disposalSuggestions" placeholder="请输入" show-word-limit :style='{"width":"100%"}' type='textarea' :autosize='{"minRows":4,"maxRows":4}' >
  78 + </el-input>
  79 + </el-form-item>
  80 + </el-col>
  81 + <el-col :span="24">
  82 + <el-form-item label="阶段" prop="stage">
  83 + <el-select v-model="dataForm.stage" placeholder="请选择" clearable :style='{"width":"100%"}' >
  84 + <el-option v-for="(item, index) in stageOptions" :key="index" :label="item.fullName" :value="item.id" ></el-option>
  85 + </el-select>
  86 + </el-form-item>
  87 + </el-col>
  88 + <el-col :span="24" v-if="false" >
  89 + <el-form-item label="创建用户" prop="creatorUserId">
  90 + <el-input v-model="dataForm.creatorUserId" placeholder="系统自动生成" readonly >
  91 + </el-input>
  92 + </el-form-item>
  93 + </el-col>
  94 + <el-col :span="24" v-if="false" >
  95 + <el-form-item label="创建时间" prop="creatorTime">
  96 + <el-input v-model="dataForm.creatorTime" placeholder="系统自动生成" readonly >
  97 + </el-input>
  98 + </el-form-item>
  99 + </el-col>
  100 + <el-col :span="24" v-if="false" >
  101 + <el-form-item label="修改用户" prop="lastModifyUserId">
  102 + <el-input v-model="dataForm.lastModifyUserId" placeholder="系统自动生成" readonly >
  103 + </el-input>
  104 + </el-form-item>
  105 + </el-col>
  106 + <el-col :span="24" v-if="false" >
  107 + <el-form-item label="修改时间" prop="lastModifyTime">
  108 + <el-input v-model="dataForm.lastModifyTime" placeholder="系统自动生成" readonly >
  109 + </el-input>
  110 + </el-form-item>
  111 + </el-col>
  112 + </el-form>
  113 + </el-row>
  114 + <span slot="footer" class="dialog-footer">
  115 + <el-button @click="visible = false">取 消</el-button>
  116 + <el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail">确 定</el-button>
  117 + </span>
  118 + </el-dialog>
  119 +</template>
  120 +<script>
  121 + import request from '@/utils/request'
  122 + import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
  123 + import { previewDataInterface } from '@/api/systemData/dataInterface'
  124 + export default {
  125 + components: {},
  126 + props: [],
  127 + data() {
  128 + return {
  129 + loading: false,
  130 + visible: false,
  131 + isDetail: false,
  132 + dataForm: {
  133 + id:'',
  134 + id:undefined,
  135 + source:undefined,
  136 + platformName:undefined,
  137 + platformType:undefined,
  138 + department:undefined,
  139 + questionType:undefined,
  140 + questionClass:undefined,
  141 + questionContent:undefined,
  142 + link:undefined,
  143 + obtainEvidence:[],
  144 + annex:[],
  145 + disposalSuggestions:undefined,
  146 + stage:undefined,
  147 + creatorUserId:undefined,
  148 + creatorTime:undefined,
  149 + lastModifyUserId:undefined,
  150 + lastModifyTime:undefined,
  151 + },
  152 + rules: {
  153 + },
  154 + sourceOptions:[{"fullName":"市网信办线索","id":"市网信办线索"},{"fullName":"自主巡查发现","id":"自主巡查发现"}],
  155 + platformTypeOptions : [],
  156 + questionTypeOptions : [],
  157 + questionClassOptions:[{"fullName":"选项一","id":"1"},{"fullName":"选项二","id":"2"}],
  158 + stageOptions:[{"fullName":"选项一","id":"1"},{"fullName":"选项二","id":"2"}],
  159 + }
  160 + },
  161 + computed: {},
  162 + watch: {},
  163 + created() {
  164 + this.getplatformTypeOptions();
  165 + this.getquestionTypeOptions();
  166 + },
  167 + mounted() {
  168 + },
  169 + methods: {
  170 + getplatformTypeOptions(){
  171 + getDictionaryDataSelector('576279943168656645').then(res => {
  172 + this.platformTypeOptions = res.data.list
  173 + });
  174 + },
  175 + getquestionTypeOptions(){
  176 + getDictionaryDataSelector('577006814432855301').then(res => {
  177 + this.questionTypeOptions = res.data.list
  178 + });
  179 + },
  180 + goBack() {
  181 + this.$emit('refresh')
  182 + },
  183 + init(id, isDetail) {
  184 + this.dataForm.id = id || 0;
  185 + this.visible = true;
  186 + this.isDetail = isDetail || false;
  187 + this.$nextTick(() => {
  188 + this.$refs['elForm'].resetFields();
  189 + if (this.dataForm.id) {
  190 + request({
  191 + url: '/Extend/BaseInspectionReport/' + this.dataForm.id,
  192 + method: 'get'
  193 + }).then(res =>{
  194 + this.dataForm = res.data;
  195 + if(!this.dataForm.obtainEvidence)this.dataForm.obtainEvidence=[];
  196 + if(!this.dataForm.annex)this.dataForm.annex=[];
  197 + })
  198 + }
  199 + })
  200 + },
  201 + dataFormSubmit() {
  202 + this.$refs['elForm'].validate((valid) => {
  203 + if (valid) {
  204 + if (!this.dataForm.id) {
  205 + request({
  206 + url: `/Extend/BaseInspectionReport`,
  207 + method: 'post',
  208 + data: this.dataForm,
  209 + }).then((res) => {
  210 + this.$message({
  211 + message: res.msg,
  212 + type: 'success',
  213 + duration: 1000,
  214 + onClose: () => {
  215 + this.visible = false,
  216 + this.$emit('refresh', true)
  217 + }
  218 + })
  219 + })
  220 + } else {
  221 + request({
  222 + url: '/Extend/BaseInspectionReport/' + this.dataForm.id,
  223 + method: 'PUT',
  224 + data: this.dataForm
  225 + }).then((res) => {
  226 + this.$message({
  227 + message: res.msg,
  228 + type: 'success',
  229 + duration: 1000,
  230 + onClose: () => {
  231 + this.visible = false
  232 + this.$emit('refresh', true)
  233 + }
  234 + })
  235 + })
  236 + }
  237 + }
  238 + })
  239 + },
  240 + }
  241 + }
  242 +</script>
src/views/baseInspectionReport/FormPage.vue 0 → 100644
  1 +<template>
  2 + <div style="width: 100%;height: 100%;background-color: #FFF;padding-top: 10px;">
  3 + <el-row :gutter="15" class="" >
  4 + <el-form ref="elForm" :model="dataForm" size="small" label-width="100px" label-position="right" :disabled="!!isDetail" :rules="rules">
  5 + <el-col :span="24" v-if="false" >
  6 + <el-form-item label="主键" prop="id">
  7 + <el-input v-model="dataForm.id" placeholder="请输入" clearable :style='{"width":"100%"}' >
  8 + </el-input>
  9 + </el-form-item>
  10 + </el-col>
  11 + <el-col :span="24">
  12 + <el-form-item label="来源" prop="source">
  13 + <el-select v-model="dataForm.source" placeholder="请选择" clearable :style='{"width":"100%"}' >
  14 + <el-option v-for="(item, index) in sourceOptions" :key="index" :label="item.fullName" :value="item.id" ></el-option>
  15 + </el-select>
  16 + </el-form-item>
  17 + </el-col>
  18 + <el-col :span="24">
  19 + <el-form-item label="平台名称" prop="platformName">
  20 + <el-input v-model="dataForm.platformName" placeholder="请输入" clearable :style='{"width":"100%"}' >
  21 + </el-input>
  22 + </el-form-item>
  23 + </el-col>
  24 + <el-col :span="24">
  25 + <el-form-item label="平台类型" prop="platformType">
  26 + <el-select v-model="dataForm.platformType" placeholder="请选择" clearable :style='{"width":"100%"}' >
  27 + <el-option v-for="(item, index) in platformTypeOptions" :key="index" :label="item.fullName" :value="item.id" ></el-option>
  28 + </el-select>
  29 + </el-form-item>
  30 + </el-col>
  31 + <el-col :span="24">
  32 + <el-form-item label="部门" prop="department">
  33 + <dep-select v-model="dataForm.department" placeholder="请选择" clearable >
  34 + </dep-select>
  35 + </el-form-item>
  36 + </el-col>
  37 + <el-col :span="24">
  38 + <el-form-item label="问题类型" prop="questionType">
  39 + <el-radio-group v-model="dataForm.questionType" :style='{}' >
  40 + <el-radio v-for="(item, index) in questionTypeOptions" :key="index" :label="item.id" >{{item.fullName}}</el-radio>
  41 + </el-radio-group>
  42 + </el-form-item>
  43 + </el-col>
  44 + <el-col :span="24">
  45 + <el-form-item label="问题分类" prop="questionClass">
  46 + <el-select v-model="dataForm.questionClass" placeholder="请选择" clearable :style='{"width":"100%"}' >
  47 + <el-option v-for="(item, index) in questionClassOptions" :key="index" :label="item.fullName" :value="item.id" ></el-option>
  48 + </el-select>
  49 + </el-form-item>
  50 + </el-col>
  51 + <el-col :span="24">
  52 + <el-form-item label="问题内容" prop="questionContent">
  53 + <el-input v-model="dataForm.questionContent" placeholder="请输入" show-word-limit :style='{"width":"100%"}' type='textarea' :autosize='{"minRows":4,"maxRows":4}' >
  54 + </el-input>
  55 + </el-form-item>
  56 + </el-col>
  57 + <el-col :span="24">
  58 + <el-form-item label="有害链接" prop="link">
  59 + <el-input v-model="dataForm.link" placeholder="请输入" clearable :style='{"width":"100%"}' >
  60 + </el-input>
  61 + </el-form-item>
  62 + </el-col>
  63 + <el-col :span="24">
  64 + <el-form-item label="取证内容" prop="obtainEvidence">
  65 + <NCC-UploadFz v-model="dataForm.obtainEvidence" :fileSize="5" sizeUnit="MB" :limit="9" buttonText="点击上传" >
  66 + </NCC-UploadFz>
  67 + </el-form-item>
  68 + </el-col>
  69 + <el-col :span="24">
  70 + <el-form-item label="附件上传" prop="annex">
  71 + <NCC-UploadFz v-model="dataForm.annex" :fileSize="5" sizeUnit="MB" :limit="9" buttonText="点击上传" >
  72 + </NCC-UploadFz>
  73 + </el-form-item>
  74 + </el-col>
  75 + <el-col :span="24">
  76 + <el-form-item label="处置建议" prop="disposalSuggestions">
  77 + <el-input v-model="dataForm.disposalSuggestions" placeholder="请输入" show-word-limit :style='{"width":"100%"}' type='textarea' :autosize='{"minRows":4,"maxRows":4}' >
  78 + </el-input>
  79 + </el-form-item>
  80 + </el-col>
  81 + <el-col :span="24">
  82 + <el-form-item label="阶段" prop="stage">
  83 + <el-select v-model="dataForm.stage" placeholder="请选择" clearable :style='{"width":"100%"}' >
  84 + <el-option v-for="(item, index) in stageOptions" :key="index" :label="item.fullName" :value="item.id" ></el-option>
  85 + </el-select>
  86 + </el-form-item>
  87 + </el-col>
  88 + <el-col :span="24" v-if="false" >
  89 + <el-form-item label="创建用户" prop="creatorUserId">
  90 + <el-input v-model="dataForm.creatorUserId" placeholder="系统自动生成" readonly >
  91 + </el-input>
  92 + </el-form-item>
  93 + </el-col>
  94 + <el-col :span="24" v-if="false" >
  95 + <el-form-item label="创建时间" prop="creatorTime">
  96 + <el-input v-model="dataForm.creatorTime" placeholder="系统自动生成" readonly >
  97 + </el-input>
  98 + </el-form-item>
  99 + </el-col>
  100 + <el-col :span="24" v-if="false" >
  101 + <el-form-item label="修改用户" prop="lastModifyUserId">
  102 + <el-input v-model="dataForm.lastModifyUserId" placeholder="系统自动生成" readonly >
  103 + </el-input>
  104 + </el-form-item>
  105 + </el-col>
  106 + <el-col :span="24" v-if="false" >
  107 + <el-form-item label="修改时间" prop="lastModifyTime">
  108 + <el-input v-model="dataForm.lastModifyTime" placeholder="系统自动生成" readonly >
  109 + </el-input>
  110 + </el-form-item>
  111 + </el-col>
  112 + </el-form>
  113 + </el-row>
  114 + <span slot="footer" class="dialog-footer">
  115 + <el-button @click="visible = false">取 消</el-button>
  116 + <el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail">确 定</el-button>
  117 + </span>
  118 + </div>
  119 +</template>
  120 +<script>
  121 + import request from '@/utils/request'
  122 + import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
  123 + import { previewDataInterface } from '@/api/systemData/dataInterface'
  124 + export default {
  125 + components: {},
  126 + props: [],
  127 + data() {
  128 + return {
  129 + loading: false,
  130 + visible: false,
  131 + isDetail: false,
  132 + dataForm: {
  133 + id:'',
  134 + id:undefined,
  135 + source:undefined,
  136 + platformName:undefined,
  137 + platformType:undefined,
  138 + department:undefined,
  139 + questionType:undefined,
  140 + questionClass:undefined,
  141 + questionContent:undefined,
  142 + link:undefined,
  143 + obtainEvidence:[],
  144 + annex:[],
  145 + disposalSuggestions:undefined,
  146 + stage:undefined,
  147 + creatorUserId:undefined,
  148 + creatorTime:undefined,
  149 + lastModifyUserId:undefined,
  150 + lastModifyTime:undefined,
  151 + },
  152 + rules: {
  153 + },
  154 + sourceOptions:[{"fullName":"市网信办线索","id":"市网信办线索"},{"fullName":"自主巡查发现","id":"自主巡查发现"}],
  155 + platformTypeOptions : [],
  156 + questionTypeOptions : [],
  157 + questionClassOptions:[{"fullName":"选项一","id":"1"},{"fullName":"选项二","id":"2"}],
  158 + stageOptions:[{"fullName":"选项一","id":"1"},{"fullName":"选项二","id":"2"}],
  159 + }
  160 + },
  161 + computed: {},
  162 + watch: {},
  163 + created() {
  164 + this.getplatformTypeOptions();
  165 + this.getquestionTypeOptions();
  166 + },
  167 + mounted() {
  168 + },
  169 + methods: {
  170 + getplatformTypeOptions(){
  171 + getDictionaryDataSelector('576279943168656645').then(res => {
  172 + this.platformTypeOptions = res.data.list
  173 + });
  174 + },
  175 + getquestionTypeOptions(){
  176 + getDictionaryDataSelector('577006814432855301').then(res => {
  177 + this.questionTypeOptions = res.data.list
  178 + });
  179 + },
  180 + goBack() {
  181 + this.$emit('refresh')
  182 + },
  183 + init(id, isDetail) {
  184 + this.dataForm.id = id || 0;
  185 + this.visible = true;
  186 + this.isDetail = isDetail || false;
  187 + this.$nextTick(() => {
  188 + this.$refs['elForm'].resetFields();
  189 + if (this.dataForm.id) {
  190 + request({
  191 + url: '/Extend/BaseInspectionReport/' + this.dataForm.id,
  192 + method: 'get'
  193 + }).then(res =>{
  194 + this.dataForm = res.data;
  195 + if(!this.dataForm.obtainEvidence)this.dataForm.obtainEvidence=[];
  196 + if(!this.dataForm.annex)this.dataForm.annex=[];
  197 + })
  198 + }
  199 + })
  200 + },
  201 + dataFormSubmit() {
  202 + this.$refs['elForm'].validate((valid) => {
  203 + if (valid) {
  204 + if (!this.dataForm.id) {
  205 + request({
  206 + url: `/Extend/BaseInspectionReport`,
  207 + method: 'post',
  208 + data: this.dataForm,
  209 + }).then((res) => {
  210 + this.$message({
  211 + message: res.msg,
  212 + type: 'success',
  213 + duration: 1000,
  214 + onClose: () => {
  215 + this.visible = false,
  216 + this.$emit('refresh', true)
  217 + }
  218 + })
  219 + })
  220 + } else {
  221 + request({
  222 + url: '/Extend/BaseInspectionReport/' + this.dataForm.id,
  223 + method: 'PUT',
  224 + data: this.dataForm
  225 + }).then((res) => {
  226 + this.$message({
  227 + message: res.msg,
  228 + type: 'success',
  229 + duration: 1000,
  230 + onClose: () => {
  231 + this.visible = false
  232 + this.$emit('refresh', true)
  233 + }
  234 + })
  235 + })
  236 + }
  237 + }
  238 + })
  239 + },
  240 + }
  241 + }
  242 +</script>
src/views/baseInspectionReport/index.vue 0 → 100644
  1 +<template>
  2 + <div class="SystemInfo item-box common-info-box">
  3 + <div class="item-title">应用信息</div>
  4 + <div class="item-body">
  5 + <div class="NCC-common-layout">
  6 + <div class="NCC-common-layout-center">
  7 + <el-row class="NCC-common-search-box" :gutter="16">
  8 + <el-form @submit.native.prevent size="mini">
  9 + <el-col :span="4">
  10 + <el-form-item label="">
  11 + <el-input v-model="query.platformName" placeholder="平台名称" clearable />
  12 + </el-form-item>
  13 + </el-col>
  14 + <el-col :span="4">
  15 + <el-form-item label="">
  16 + <el-select v-model="query.platformType" placeholder="平台类型" clearable >
  17 + <el-option v-for="(item, index) in platformTypeOptions" :key="index" :label="item.fullName" :value="item.id" />
  18 + </el-select>
  19 + </el-form-item>
  20 + </el-col>
  21 + <el-col :span="4">
  22 + <el-form-item label="">
  23 + <depSelect v-model="query.department" placeholder="请选择部门" />
  24 + </el-form-item>
  25 + </el-col>
  26 + <el-col :span="4">
  27 + <el-form-item label="">
  28 + <el-select v-model="query.questionType" placeholder="问题类型" >
  29 + <el-option v-for="(item, index) in questionTypeOptions" :key="index" :label="item.fullName" :value="item.id" />
  30 + </el-select>
  31 + </el-form-item>
  32 + </el-col>
  33 + <el-col :span="4">
  34 + <el-form-item label="">
  35 + <el-select v-model="query.questionClass" placeholder="问题分类" clearable >
  36 + <el-option v-for="(item, index) in questionClassOptions" :key="index" :label="item.fullName" :value="item.id" />
  37 + </el-select>
  38 + </el-form-item>
  39 + </el-col>
  40 + <el-col :span="4">
  41 + <el-form-item>
  42 + <el-button type="primary" icon="el-icon-search" @click="search()">查询</el-button>
  43 + </el-form-item>
  44 + </el-col>
  45 + </el-form>
  46 + </el-row>
  47 + <div class="NCC-common-layout-main NCC-flex-main">
  48 + <div class="NCC-common-head">
  49 + <div>
  50 + <el-button type="primary" icon="el-icon-plus" @click="addOrUpdateHandle()" size="mini">新增</el-button>
  51 + </div>
  52 + </div>
  53 + <NCC-table v-loading="listLoading" :data="list">
  54 + <el-table-column show-overflow-tooltip prop="platformName" label="平台名称" align="left" />
  55 + <el-table-column show-overflow-tooltip label="平台类型" prop="platformType" align="left">
  56 + <template slot-scope="scope">{{ scope.row.platformType | dynamicText(platformTypeOptions) }}</template>
  57 + </el-table-column>
  58 + <el-table-column show-overflow-tooltip label="问题类型" prop="questionType" align="left">
  59 + <template slot-scope="scope">{{ scope.row.questionType | dynamicText(questionTypeOptions) }}</template>
  60 + </el-table-column>
  61 + <el-table-column show-overflow-tooltip prop="link" label="有害链接" align="left" />
  62 + <el-table-column show-overflow-tooltip prop="disposalSuggestions" label="处置建议" align="left" />
  63 + <el-table-column show-overflow-tooltip prop="id" label="主键" align="left" />
  64 + <el-table-column show-overflow-tooltip prop="department" label="部门" align="left" />
  65 + <el-table-column show-overflow-tooltip label="问题分类" prop="questionClass" align="left">
  66 + <template slot-scope="scope">{{ scope.row.questionClass | dynamicText(questionClassOptions) }}</template>
  67 + </el-table-column>
  68 + <el-table-column show-overflow-tooltip label="阶段" prop="stage" align="left">
  69 + <template slot-scope="scope">{{ scope.row.stage | dynamicText(stageOptions) }}</template>
  70 + </el-table-column>
  71 + <el-table-column label="操作" fixed="right" width="100">
  72 + <template slot-scope="scope">
  73 + <el-button type="text" @click="addOrUpdateHandle(scope.row.id)" >编辑</el-button>
  74 + <el-button type="text" @click="handleDel(scope.row.id)" class="NCC-table-delBtn" >删除</el-button>
  75 + </template>
  76 + </el-table-column>
  77 + </NCC-table>
  78 + <pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize" @pagination="initData" />
  79 + </div>
  80 + </div>
  81 + <NCC-Form v-if="formVisible" ref="NCCForm" @refresh="refresh" />
  82 + <ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download" />
  83 + </div>
  84 + </div>
  85 + </div>
  86 +
  87 +</template>
  88 +<script>
  89 + import request from '@/utils/request'
  90 + import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
  91 + import NCCForm from './Form'
  92 + import ExportBox from './ExportBox'
  93 + import { getList, previewDataInterface } from '@/api/systemData/dataInterface'
  94 + export default {
  95 + components: { NCCForm, ExportBox },
  96 + data() {
  97 + return {
  98 + showAll: false,
  99 + query: {
  100 + platformName:undefined,
  101 + platformType:undefined,
  102 + department:undefined,
  103 + questionType:undefined,
  104 + questionClass:undefined,
  105 + },
  106 + list: [],
  107 + listLoading: true,
  108 + multipleSelection: [], total: 0,
  109 + listQuery: {
  110 + currentPage: 1,
  111 + pageSize: 20,
  112 + sort: "desc",
  113 + sidx: "",
  114 + },
  115 + formVisible: false,
  116 + exportBoxVisible: false,
  117 + columnList: [
  118 + { prop: 'platformName', label: '平台名称' },
  119 + { prop: 'platformType', label: '平台类型' },
  120 + { prop: 'questionType', label: '问题类型' },
  121 + { prop: 'link', label: '有害链接' },
  122 + { prop: 'disposalSuggestions', label: '处置建议' },
  123 + { prop: 'id', label: '主键' },
  124 + { prop: 'department', label: '部门' },
  125 + { prop: 'questionClass', label: '问题分类' },
  126 + { prop: 'stage', label: '阶段' },
  127 + ],
  128 + sourceOptions:[{"fullName":"市网信办线索","id":"市网信办线索"},{"fullName":"自主巡查发现","id":"自主巡查发现"}],
  129 + platformTypeOptions : [],
  130 + questionTypeOptions : [],
  131 + questionClassOptions:[{"fullName":"选项一","id":"1"},{"fullName":"选项二","id":"2"}],
  132 + stageOptions:[{"fullName":"选项一","id":"1"},{"fullName":"选项二","id":"2"}],
  133 + }
  134 + },
  135 + computed: {},
  136 + created() {
  137 + this.initData()
  138 + // this.getplatformTypeOptions();
  139 + // this.getquestionTypeOptions();
  140 + },
  141 + methods: {
  142 + getplatformTypeOptions(){
  143 + getDictionaryDataSelector('576279943168656645').then(res => {
  144 + this.platformTypeOptions = res.data.list
  145 + });
  146 + },
  147 + getquestionTypeOptions(){
  148 + getDictionaryDataSelector('577006814432855301').then(res => {
  149 + this.questionTypeOptions = res.data.list
  150 + });
  151 + },
  152 + initData() {
  153 + this.listLoading = true;
  154 + let _query = {
  155 + ...this.listQuery,
  156 + ...this.query
  157 + };
  158 + let query = {}
  159 + for (let key in _query) {
  160 + if (Array.isArray(_query[key])) {
  161 + query[key] = _query[key].join()
  162 + } else {
  163 + query[key] = _query[key]
  164 + }
  165 + }
  166 + getList(query).then(res => {
  167 + this.list = res.data.list
  168 + this.total = res.data.pagination.total
  169 + this.listLoading = false
  170 + })
  171 + },
  172 + handleDel(id) {
  173 + this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
  174 + type: 'warning'
  175 + }).then(() => {
  176 + request({
  177 + url: `/Extend/BaseInspectionReport/${id}`,
  178 + method: 'DELETE'
  179 + }).then(res => {
  180 + this.$message({
  181 + type: 'success',
  182 + message: res.msg,
  183 + onClose: () => {
  184 + this.initData()
  185 + }
  186 + });
  187 + })
  188 + }).catch(() => {
  189 + });
  190 + },
  191 + addOrUpdateHandle(id, isDetail) {
  192 + this.formVisible = true
  193 + this.$nextTick(() => {
  194 + this.$refs.NCCForm.init(id, isDetail)
  195 + })
  196 + },
  197 + search() {
  198 + this.listQuery = {
  199 + currentPage: 1,
  200 + pageSize: 20,
  201 + sort: "desc",
  202 + sidx: "",
  203 + }
  204 + this.initData()
  205 + },
  206 + refresh(isrRefresh) {
  207 + this.formVisible = false
  208 + if (isrRefresh) this.reset()
  209 + },
  210 + reset() {
  211 + for (let key in this.query) {
  212 + this.query[key] = undefined
  213 + }
  214 + this.listQuery = {
  215 + currentPage: 1,
  216 + pageSize: 20,
  217 + sort: "desc",
  218 + sidx: "",
  219 + }
  220 + this.initData()
  221 + }
  222 + }
  223 + }
  224 +</script>
  225 +<style scoped lang="scss">
  226 +.common-info-box {
  227 + :deep(.el-table__body-wrapper.is-scrolling-none) {
  228 + height: calc(100% - 47px);
  229 + overflow-y: scroll;
  230 + }
  231 + .item-body {
  232 + height: calc(100% - 35px);
  233 + }
  234 +}
  235 +</style>
0 \ No newline at end of file 236 \ No newline at end of file
src/views/baseSystemInfo/index.vue
@@ -75,12 +75,12 @@ @@ -75,12 +75,12 @@
75 </el-row> 75 </el-row>
76 <div class="NCC-common-layout-main NCC-flex-main"> 76 <div class="NCC-common-layout-main NCC-flex-main">
77 <NCC-table v-loading="loading" :data="infoDataList"> 77 <NCC-table v-loading="loading" :data="infoDataList">
78 - <el-table-column prop="companyName" label="主体企业" align="center" />  
79 - <el-table-column prop="systemName" label="应用名称" align="center" />  
80 - <el-table-column prop="systemType" label="应用类型" align="center" />  
81 - <el-table-column prop="systemClass" label="应用分类" align="center" />  
82 - <el-table-column prop="contactUser" label="联系人" align="center" />  
83 - <el-table-column prop="contactPhone" label="联系电话" align="center" /> 78 + <el-table-column show-overflow-tooltip prop="companyName" label="主体企业" align="center" />
  79 + <el-table-column show-overflow-tooltip prop="systemName" label="应用名称" align="center" />
  80 + <el-table-column show-overflow-tooltip prop="systemType" label="应用类型" align="center" />
  81 + <el-table-column show-overflow-tooltip prop="systemClass" label="应用分类" align="center" />
  82 + <el-table-column show-overflow-tooltip prop="contactUser" label="联系人" align="center" />
  83 + <el-table-column show-overflow-tooltip prop="contactPhone" label="联系电话" align="center" />
84 <el-table-column prop="areaName" label="所属区域" align="center" /> 84 <el-table-column prop="areaName" label="所属区域" align="center" />
85 <el-table-column label="操作" width="200"> 85 <el-table-column label="操作" width="200">
86 <!-- 查看,修改,归属地变更,上报 --> 86 <!-- 查看,修改,归属地变更,上报 -->