From feb8dcddb9b60ff6ddc17224cd0bf0e7dc8a75db Mon Sep 17 00:00:00 2001 From: XieYongHong <18010623010@163.com> Date: Thu, 23 Nov 2023 14:09:54 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=96=B0=E5=A2=9E=E5=AD=97=E5=85=B8?= =?UTF-8?q?=E7=AE=A1=E7=90=86=EF=BC=9B=E6=96=B0=E5=A2=9Es7=EF=BC=9B?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=E9=BB=98=E8=AE=A4=E6=B5=81=E7=A8=8B=E5=BC=95?= =?UTF-8?q?=E6=93=8E=E8=8F=9C=E5=8D=95=E6=9D=83=E9=99=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix: 优化初始化流程引擎菜单数据权限 * feat: 新增S7 * feat(s7): 数据采集增加S7协议 * fix: s7点位死区校验 * fix: bug#19996 * fix: bug#20211 * fix: bug#20211 * fix: s7点位配置 * fix: s7点位死区校验 * fix: s7点位配置 * fix: 优化流程引擎字段权限 * fix: 优化流程引擎字段权限 * fix: s7按钮权限 * fix: 修复s7点位bug * fix: 修复s7点位bug * fix: s7点位bug修复 * fix: s7点位bug修复 * fix: bug#20382 * fix: bug#19996 * fix: bug#19649 * feat: 导入通道校验 * feat(s7): 数据采集增加S7协议 * fix: s7点位死区校验 * fix: s7点位配置 * fix: 修复s7点位bug * fix: s7点位bug修复 * feat: 新增点位导入功能 * feat: 新增导入功能 * feat: 导入通道校验 * fix: 优化内部应用页面集成 * * fix: 修改导入图标 * fix: 修改导入图标 * bug#20101 * fix: bug#20449 * fix: bug#20488 * fix: bug#20495 * fix: bug#20101 * feat: 集成菜单新增菜单功能 * feat: api新增菜单 * feat: 集成菜单新增菜单功能 * feat: 集成菜单应用新增菜单 * fix: bug#20293 * fix: bug#20430 * fix: s7修改导入图标 * fix: 修改导入图标 * fix: 优化集成页面路径 --- .env.develop | 3 +- .env.production | 3 +- package.json | 2 +- public/images/DataCollect/gateway.png | Bin 0 -> 4141 bytes public/images/DataCollect/s7.png | Bin 0 -> 5986 bytes src/api/account/notificationRecord.ts | 3 +- src/api/comm.ts | 4 +- src/api/data-collect/collector.ts | 11 +- src/api/initHome.ts | 3 +- src/api/system/dictionary.ts | 56 + src/api/system/menu.ts | 4 +- src/api/system/region.ts | 22 + src/api/system/role.ts | 9 +- src/api/system/user.ts | 9 +- src/components/AMapComponent/index.vue | 5 +- src/components/Layout/SinglePage.vue | 129 ++ src/components/Layout/components/Notice.vue | 17 +- .../Layout/components/NoticeInfo.vue | 3 +- src/components/Layout/index.ts | 3 +- src/router/index.ts | 2 +- src/router/menu.ts | 4 +- src/store/menu.ts | 41 +- src/utils/consts.ts | 1 + src/utils/menu.ts | 53 +- src/utils/request.ts | 8 +- src/views/DataCollect/Channel/Save/index.vue | 14 +- src/views/DataCollect/Channel/data.ts | 1 + src/views/DataCollect/Channel/index.vue | 13 +- src/views/DataCollect/Channel/type.d.ts | 1 + .../Collector/Point/Save/DeathArea.vue | 260 +++ .../Collector/Point/Save/SaveS7.vue | 377 ++++ .../Point/components/Import/index.vue | 206 ++ .../Point/components/WritePoint/index.vue | 55 + .../DataCollect/Collector/Point/index.vue | 88 +- .../DataCollect/Collector/Tree/Save/index.vue | 49 +- src/views/DataCollect/Collector/data.ts | 104 +- .../components/ViewDialog.vue | 83 +- .../components/NotificationRecord/index.vue | 13 +- .../components/StationMessage/index.vue | 5 +- .../Center/components/Subscribe/index.vue | 17 +- src/views/account/Center/components/data.ts | 41 +- src/views/account/Center/index.vue | 4 +- .../device/Instance/Detail/Info/index.vue | 2 +- .../components/BindParentDevice/index.vue | 2 +- src/views/iframe/index.vue | 66 +- src/views/init-home/Menu/index.vue | 16 +- src/views/init-home/Role/index.vue | 246 ++- src/views/init-home/data/RoleData.ts | 3 + src/views/init-home/data/baseMenu.ts | 1757 ++++++++++++++++- src/views/init-home/index.vue | 7 +- .../Save/action/ListItem/FilterCondition.vue | 13 +- .../system/Apply/componenets/MenuDialog.vue | 11 +- src/views/system/Apply/index.vue | 1 + src/views/system/Basis/index.vue | 1 - .../components/Left/Export/index.vue | 98 + .../Dictionary/components/Left/index.vue | 218 ++ .../Dictionary/components/Left/save/index.vue | 125 ++ .../components/Right/Save/index.vue | 143 ++ .../Dictionary/components/Right/index.vue | 229 +++ src/views/system/Dictionary/index.vue | 45 + src/views/system/Menu/Detail/BasicInfo.vue | 374 ++-- src/views/system/Menu/Setting/index.vue | 87 +- src/views/system/Menu/Setting/utils.ts | 19 +- src/views/system/Menu/components/fields.ts | 1 + src/views/system/Menu/index.vue | 50 +- src/views/system/NoticeRule/index.vue | 48 +- .../Platforms/Api/components/ApiTest.vue | 22 +- src/views/system/Region/LeftTree/index.vue | 240 +++ src/views/system/Region/MapTool/index.ts | 0 src/views/system/Region/MapTool/map.vue | 304 +++ src/views/system/Region/Save/BuildIn.vue | 124 ++ src/views/system/Region/Save/TracePoint.vue | 45 + src/views/system/Region/Save/index.vue | 234 +++ src/views/system/Region/index.vue | 65 + .../Relationship/components/EditDialog.vue | 66 +- src/views/system/Relationship/index.vue | 50 +- .../system/Role/Detail/Permiss/index.vue | 42 +- src/views/system/Role/RoleLeft/index.vue | 175 ++ .../Role/RoleRight/components/AddDialog.vue | 139 ++ src/views/system/Role/RoleRight/index.vue | 193 ++ .../system/Role/components/AddDialog.vue | 79 - src/views/system/Role/index.vue | 176 +- .../system/User/components/EditUserDialog.vue | 273 +-- src/views/system/User/index.vue | 42 +- vite.config.ts | 5 +- yarn.lock | 8 +- 86 files changed, 6655 insertions(+), 915 deletions(-) create mode 100644 public/images/DataCollect/gateway.png create mode 100644 public/images/DataCollect/s7.png create mode 100644 src/api/system/dictionary.ts create mode 100644 src/api/system/region.ts create mode 100644 src/components/Layout/SinglePage.vue create mode 100644 src/views/DataCollect/Collector/Point/Save/DeathArea.vue create mode 100644 src/views/DataCollect/Collector/Point/Save/SaveS7.vue create mode 100644 src/views/DataCollect/Collector/Point/components/Import/index.vue create mode 100644 src/views/system/Dictionary/components/Left/Export/index.vue create mode 100644 src/views/system/Dictionary/components/Left/index.vue create mode 100644 src/views/system/Dictionary/components/Left/save/index.vue create mode 100644 src/views/system/Dictionary/components/Right/Save/index.vue create mode 100644 src/views/system/Dictionary/components/Right/index.vue create mode 100644 src/views/system/Dictionary/index.vue create mode 100644 src/views/system/Region/LeftTree/index.vue create mode 100644 src/views/system/Region/MapTool/index.ts create mode 100644 src/views/system/Region/MapTool/map.vue create mode 100644 src/views/system/Region/Save/BuildIn.vue create mode 100644 src/views/system/Region/Save/TracePoint.vue create mode 100644 src/views/system/Region/Save/index.vue create mode 100644 src/views/system/Region/index.vue create mode 100644 src/views/system/Role/RoleLeft/index.vue create mode 100644 src/views/system/Role/RoleRight/components/AddDialog.vue create mode 100644 src/views/system/Role/RoleRight/index.vue delete mode 100644 src/views/system/Role/components/AddDialog.vue diff --git a/.env.develop b/.env.develop index c8349cd4..8ace0858 100644 --- a/.env.develop +++ b/.env.develop @@ -1,2 +1,3 @@ ENV=develop -VITE_APP_BASE_API=/api \ No newline at end of file +VITE_APP_BASE_API=/api +VITE_TOKEN_KEY = X-Access-Token diff --git a/.env.production b/.env.production index 990e0635..73450e9f 100644 --- a/.env.production +++ b/.env.production @@ -1,2 +1,3 @@ ENV=production -VITE_APP_BASE_API=/api \ No newline at end of file +VITE_APP_BASE_API=/api +VITE_TOKEN_KEY = X-Access-Token diff --git a/package.json b/package.json index 6976a7c2..c8700605 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "event-source-polyfill": "^1.0.31", "global": "^4.4.0", "jetlinks-store": "^0.0.3", - "jetlinks-ui-components": "^1.0.34-4", + "jetlinks-ui-components": "^1.0.34-7", "js-cookie": "^3.0.1", "jsencrypt": "^3.3.2", "less": "^4.1.3", diff --git a/public/images/DataCollect/gateway.png b/public/images/DataCollect/gateway.png new file mode 100644 index 0000000000000000000000000000000000000000..50fc4f636872f23a7f3540f03ba97722632c8f14 GIT binary patch literal 4141 zcmV+|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 HcmV?d00001 diff --git a/public/images/DataCollect/s7.png b/public/images/DataCollect/s7.png new file mode 100644 index 0000000000000000000000000000000000000000..5707d4ec135f8acaff00068e9368c7d1b2dfa0c2 GIT binary patch literal 5986 zcmV-o7oF&dP)Awk&IxMzg$m+r78n8+qihE!!GtBrA~b935M4 z-n;L;-}~AaM<8Al7FI5=FMqr%U=YJ?;M5G^(lsq5>zg3BZxBciYl7?|+ z;|`$baq0Jrg`CLg6v!MYJwzKp<@9V?Kd4lpYaOe~O07(}?c&m<7VvVr)>po0WMn?^G}jvBy`2t=`LEQF@$0Pp-C z85GI%@{tNev23)3rf2|97KqV`bHlaK5}FYM%n5{`w2?4q9&g}IwtS%xCT#lY*8|Nk z0vi#)oInstZ7Iz^jDn4qZw?E!J>EwNs!48yI@Jj+8 z3C0_MgU(d851)hypD>eB#K2`UfpA*_J7AN*DGOYK0wi1>M)HqHa9X{f%58oLPWGdp z6p%S^9F!Q9yaiLWR~f(#!ntwszRH;fIyQB8U{Kwk11Ul5S2VTd;|S6N=elw_0kzBn zM=2aQTb`l}VcZiy5)Y&!&zF+7eq2E2z^TA0(9=3`3T_^1hCC#IIXe#0#>DeDND0cJ zKgRS1GYp??IrDSiTnSq#E$luD0+_RtLE^)@5G8-Vr&{nwU>-PW@o5f-S|V8&63c?4 z!zgTr1u$p%AiWqVIIYJCF>XQTg9Ax$2^F>#>TxIAhydnnyn}RIqA0|j%3WC}B#A>2 zz~!tc0CScP((AbiPR=RF95@QJ&gIMl_lIJE%UMwY=Ij{A_fcSC=#33y4KfE#0ksZ* z#WA$)yayg!c8&V%t3x^dXRVk1{--5Bec11hI4-uH&b04{0oGO6l~>MEFRKW#c?1MY zTe7u1A=dw7v$K^5UoTTUkPJb(qYg3$4kW`|PKgW0-l_Q&9%8QIX4sIwCbxZG*NQFO zKfdSBR(|Pe+a&_KPtui~4Awdr7C_fFNYJmS-&q;DzdG!Hgi&%zO?}Y}d)Je1ci*wI zO=}a>p9Lwn%ogVYSW!Xdg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K?5S zy6VYz19RB|tmG48`sWT~1ke)=@X;U^=~FS&?!%OR{Ywv4rp|gC6lh}(a+Cpj;Bbm! zp(JXtkzr8{nx6mSiCyP29uLDXFFsNhK#;OgFlfV;`Jqt*IZ6O=N!8`qu7Rla{(4<% zWL+WPayFvBSkD(4?mErbV>$%Iwju+}cFr+P#(KC0+h^sRK+_8khIhg+ttc;@7*)kC z62N?A#g@xNu8^IlQ`SPPsINWw?0+?vYF5Shn6;M_4de&`o{*Aw%1U8JF~H?)R9?K3 z6B@5bS2T6|h~nc20OEpS2Af=AM<_F>BU>FMvuP;GT8NG6tDlOZ*uwyrO-Tr0lF?aS zN>Zq@7IZEc16%crHZY8 zdq(!nZ3=IC;r{5DyaI2`U%*(fVxIw^my)0rNNO3y_$gX0!VAhSSf2EHtqm= zmTgu*u#tlNE4;+pfyg@rbKe~+Wi7a&N Q2LJ#707*qoM6N<$f<%RFRR910 literal 0 HcmV?d00001 diff --git a/src/api/account/notificationRecord.ts b/src/api/account/notificationRecord.ts index 4d69c13f..7279b831 100644 --- a/src/api/account/notificationRecord.ts +++ b/src/api/account/notificationRecord.ts @@ -8,7 +8,8 @@ export const getList_api = (data: any): any => server.post(`/notifications/_quer export const changeStatus_api = (type: '_read' | '_unread', data: string[]): any => server.post(`/notifications/${type}`, data) export const changeAllStatus = (type: '_read' | '_unread', data: string[]): any => server.post(`/notifications/${type}/provider`, data) - +//查看工作流通知详情 +export const getWorkflowNotice = (data:any) => server.post('/process/runtime/processes/_query/no-paging',data) // 查询告警记录详情 export const getDetail = (id: string): any => server.get(`/alarm/record/${id}`) diff --git a/src/api/comm.ts b/src/api/comm.ts index 42384c5e..312d52ce 100644 --- a/src/api/comm.ts +++ b/src/api/comm.ts @@ -36,4 +36,6 @@ export const systemVersion = () => server.get<{edition?: string}>('/system/versi */ export const queryDashboard = (data: Record) => server.post(`/dashboard/_multi`, data) -export const fileUpload = (data: any) => server.post('/file/static', data) \ No newline at end of file +export const fileUpload = (data: any) => server.post('/file/static', data) + +export const lowCodeUrl = () => server.get('/system/config/low-code') \ No newline at end of file diff --git a/src/api/data-collect/collector.ts b/src/api/data-collect/collector.ts index 8ab956f5..b90fe629 100644 --- a/src/api/data-collect/collector.ts +++ b/src/api/data-collect/collector.ts @@ -54,8 +54,7 @@ export const queryPointNoPaging = (data: any) => export const scanOpcUAList = (data: any) => server.get( - `/data-collect/opc/channel/${data.id}/nodes?nodeId=${ - data?.nodeId || '' + `/data-collect/opc/channel/${data.id}/nodes?nodeId=${data?.nodeId || '' }`, ); @@ -63,4 +62,10 @@ export const queryTypeList = () => server.get(`/data-collect/opc/data-types`); export const getProviders = () => server.get('/data-collect/channel/gateway/codec/providers') -export const getStates = () => server.get('/dictionary/running-state/items') \ No newline at end of file +export const getStates = () => server.get('/dictionary/running-state/items') + +export const getSnapTypes = () => server.get('/s7/client/s7codecs/list') + +export const getArea = () => server.get('/s7/client/s7area/list') + +export const exportTemplate = (provider: string, format: string) =>server.get(`/data-collect/point/${provider}/template.${format}`, {}, {responseType: 'blob'}) \ No newline at end of file diff --git a/src/api/initHome.ts b/src/api/initHome.ts index 3b339a74..9359b8d2 100644 --- a/src/api/initHome.ts +++ b/src/api/initHome.ts @@ -4,7 +4,8 @@ import server from '@/utils/request'; export const updateMenus = (data: any) => server.patch(`/menu/iot/_all`, data) // 添加角色 export const addRole = (data: any) => server.post(`/role`, data) - +//添加角色分组 +export const addRoleGroup = (data:any) => server.patch('/role/group',data) //更新权限菜单 export const getRoleMenu = (id: string) => server.get(`/menu/role/${id}/_grant/tree`) diff --git a/src/api/system/dictionary.ts b/src/api/system/dictionary.ts new file mode 100644 index 00000000..1cf9ab26 --- /dev/null +++ b/src/api/system/dictionary.ts @@ -0,0 +1,56 @@ +import server, { request } from '@/utils/request'; + +/** + * 查询字典列表 + */ +export const getDicList = (data:any) => request.post('/dictionary/_query/no-paging',data) + +/** + * 查询字典分页 + */ +export const getDic_page = (data:any) => request.post('/dictionary/_query',data) +/** + * 查询字典ID是否重复 + */ +export const verifyId = (id:string) => request.post(`/dictionary/_exists`,{where:`id is ${id}`}) + +/** + * 保存字典 + */ +export const addDictionary = (data:any) => request.patch('/dictionary',data) + +/** + * 删除字典 + */ +export const deleteDictionary =(id:string) => request.delete(`/dictionary/${id}`) + +/** + * 查询字典项 + */ +export const queryDicItem = (data:any)=>request.post('/dictionary-item/_query',data) + +/** + * 查询字典项不分页 + */ +export const queryDicItemNoPage = (data:any) => request.post('/dictionary-item/_query/no-paging',data) + + +/** + * 保存字典项 + */ +export const saveDicItem = (data:any) => request.patch('/dictionary-item',data) + +/** + * 删除字典项 + */ +export const deleteDicItem = (id:string) => request.delete(`/dictionary-item/${id}`) + +/** + * 校验字典项value唯一 + */ +export const verifyValue = (data:any) => request.post('/dictionary-item/_exists',data) + +/** + * 下载字典 + */ +export const downDic = (data:any) => request.post('/dictionary/detail/_query',data) \ No newline at end of file diff --git a/src/api/system/menu.ts b/src/api/system/menu.ts index 93be944c..30165eb7 100644 --- a/src/api/system/menu.ts +++ b/src/api/system/menu.ts @@ -20,4 +20,6 @@ export const saveMenuInfo_api = (data: object) => server.patch(`/menu`, data); // 新增菜单信息 export const addMenuInfo_api = (data: object) => server.post(`/menu`, data); // 删除菜单信息 -export const delMenuInfo_api = (id: string) => server.remove(`/menu/${id}`); \ No newline at end of file +export const delMenuInfo_api = (id: string) => server.remove(`/menu/${id}`); +//查询集成菜单 +export const queryApp = (data:any) => server.post('/application/_query/no-paging',data) \ No newline at end of file diff --git a/src/api/system/region.ts b/src/api/system/region.ts new file mode 100644 index 00000000..80f5d217 --- /dev/null +++ b/src/api/system/region.ts @@ -0,0 +1,22 @@ +import server from '@/utils/request'; + +// 获取全部地区(树结构) +export const getRegionTree = (): Promise => server.post(`/area/_all/tree`); + +// 校验名称是否存在 +export const validateName = (name: string, id?: string): Promise => server.get(`/area/name/_validate?name=${name}${id ? `&id=${id}` : ''}`); + +//校验行政区划代码是否存在 +export const validateCode = (code: string, id?: string): Promise => server.get(`/area/code/_validate?code=${code}${id ? `&id=${id}` : ''}`); + +// 删除 +export const delRegion = (id: string): Promise => server.remove(`/area/${id}`); + +// 保存 +export const saveRegion = (data: any): Promise => server.post(`/area`, data); + +// 更新 +export const updateRegion = (data: any): Promise => server.patch(`/area`, data); + +// 获取全部内置地区(树结构) +export const getBuiltinRegionTree = (data: any): Promise => server.post(`/area/builtin/_all/tree`, data); diff --git a/src/api/system/role.ts b/src/api/system/role.ts index 9198a5e3..bb9a2670 100644 --- a/src/api/system/role.ts +++ b/src/api/system/role.ts @@ -1,3 +1,4 @@ +import request from '@/utils/request'; import server from '@/utils/request'; // 获取角色列表 @@ -25,4 +26,10 @@ export const getUserByRole_api = (data: any): Promise => server.post(`/user // 将用户与角色绑定 export const bindUser_api = (roleId:string, data: string[]): Promise => server.post(`/role/${roleId}/users/_bind`, data); // 将用户与角色解绑 -export const unbindUser_api = (roleId:string, data: string[]): Promise => server.post(`/role/${roleId}/users/_unbind`, data); \ No newline at end of file +export const unbindUser_api = (roleId:string, data: string[]): Promise => server.post(`/role/${roleId}/users/_unbind`, data); +//查询分组 +export const queryRoleGroup = (data:any) => request.post('/role/group/_query/no-paging',data) +//保存分组 +export const saveRoleGroup = (data:any) => request.patch('/role/group',data) +//删除分组 +export const deleteRoleGroup = (id:string) => request.remove(`/role/group/${id}`) \ No newline at end of file diff --git a/src/api/system/user.ts b/src/api/system/user.ts index 9b6a01c3..4a36c5d3 100644 --- a/src/api/system/user.ts +++ b/src/api/system/user.ts @@ -15,8 +15,11 @@ export const validateField_api = (type: 'username' | 'password', name: string) = // 获取角色列表 export const getRoleList_api = () => server.get(`/role/_query/no-paging?paging=false`); + +//获取角色列表 +export const getRoleList = (data:any) => server.post('/role/group/detail/_query/tree',data) // 获取组织列表 -export const getDepartmentList_api = () => server.get(`/organization/_all/tree?paging=false`); +export const getDepartmentList_api = (data:any) => server.post(`/organization/_all/tree`,data); // 获取用户信息 export const getUser_api = (id: string) => server.get(`/user/detail/${id}`); @@ -33,4 +36,6 @@ export const updatePassword_api = (data: { id: string, password: string }) => se // 修改用户状态 export const changeUserStatus_api = (data: object) => server.patch(`/user`,data); // 删除用户 -export const deleteUser_api = (id: string) => server.remove(`/user/${id}`); \ No newline at end of file +export const deleteUser_api = (id: string) => server.remove(`/user/${id}`); +// 查询角色不分页 +export const queryRole_api = (data: any): Promise => server.post(`/role/_query/no-paging`, data) \ No newline at end of file diff --git a/src/components/AMapComponent/index.vue b/src/components/AMapComponent/index.vue index 6dec0ed4..8de55a2e 100644 --- a/src/components/AMapComponent/index.vue +++ b/src/components/AMapComponent/index.vue @@ -22,6 +22,8 @@ import '@vuemap/vue-amap/dist/style.css'; import { getAMapUiPromise } from './utils'; import { useSystem } from '@/store/system'; +const emit = defineEmits('init') + const system = useSystem(); interface AMapProps { style?: CSSProperties; @@ -65,8 +67,9 @@ const initMap = (e: any) => { if (isOpenUi.value) { getAMapUI(); } + emit('init', e) }; \ No newline at end of file + diff --git a/src/components/Layout/SinglePage.vue b/src/components/Layout/SinglePage.vue new file mode 100644 index 00000000..c2f0fd49 --- /dev/null +++ b/src/components/Layout/SinglePage.vue @@ -0,0 +1,129 @@ + - diff --git a/src/views/init-home/Menu/index.vue b/src/views/init-home/Menu/index.vue index d4270dde..6ce235ff 100644 --- a/src/views/init-home/Menu/index.vue +++ b/src/views/init-home/Menu/index.vue @@ -96,12 +96,26 @@ const menuCount = (menus: any[]) => { return pre + _count; }, 0); }; +/** + * 添加options show用于控制菜单是否显示函数 + */ +const dealMenu = (data:any) =>{ + data.forEach((item:any)=>{ + item.options = Object.assign({ + show: true + }, item?.options || {}) + if(item.children){ + dealMenu(item.children) + } + }) +} /** * 初始化菜单 */ const initMenu = async () => { return new Promise(async (resolve) => { // 用户中心 + dealMenu(menuDatas.current) console.log([...menuDatas.current!, USER_CENTER_MENU_DATA]); const res = await updateMenus([...menuDatas.current!, USER_CENTER_MENU_DATA]); if (res.status === 200) { @@ -125,4 +139,4 @@ defineExpose({ margin-right: 16px; } } - \ No newline at end of file + diff --git a/src/views/init-home/Role/index.vue b/src/views/init-home/Role/index.vue index de2505b8..a1701027 100644 --- a/src/views/init-home/Role/index.vue +++ b/src/views/init-home/Role/index.vue @@ -1,15 +1,31 @@ \ No newline at end of file +} \ No newline at end of file diff --git a/src/views/init-home/data/RoleData.ts b/src/views/init-home/data/RoleData.ts index 098e5a41..ae6f81f8 100644 --- a/src/views/init-home/data/RoleData.ts +++ b/src/views/init-home/data/RoleData.ts @@ -13,15 +13,18 @@ export const RoleData = { [ROLEKEYS.device]: { name: '设备接入岗', description: '该角色负责设备接入模块的维护管理', + groupId:'default_group', state: { text: '正常', value: 'enabled' }, }, [ROLEKEYS.link]: { name: '运维管理岗', + groupId:'default_group', description: '该角色负责系统运维模块的维护管理', state: { text: '正常', value: 'enabled' }, }, [ROLEKEYS.complex]: { name: '综合管理岗', + groupId:'default_group', description: '该角色负责系统运维和设备接入模块的维护管理', state: { text: '正常', value: 'enabled' }, }, diff --git a/src/views/init-home/data/baseMenu.ts b/src/views/init-home/data/baseMenu.ts index a8211b1b..0547d948 100644 --- a/src/views/init-home/data/baseMenu.ts +++ b/src/views/init-home/data/baseMenu.ts @@ -13,6 +13,9 @@ export const USER_CENTER_MENU_DATA = { sortIndex: 9999, granted: true, owner: 'iot', + options: { + isShow: false, + }, permissions: [ { permission: 'system_config', @@ -1413,7 +1416,7 @@ export default [ }, ], }, - + ], accessSupport: { text: "间接支持", value: "indirect" }, supportDataAccess: false, @@ -1672,119 +1675,199 @@ export default [ permissions: [], buttons: [ { - id: 'view', - name: '查看', - permissions: [ + "id": "view", + "name": "查看", + "permissions": [ { - permission: 'data-collect-channel', - actions: ['query'], + "permission": "data-collect-channel", + "actions": [ + "query" + ] }, { - permission: 'data-collector', - actions: ['query'], + "permission": "data-collector", + "actions": [ + "query" + ] }, { - permission: 'data-collect-opc', - actions: ['query'], + "permission": "data-collect-opc", + "actions": [ + "query" + ] }, { - permission: 'things-collector', - actions: ['query'], + "permission": "things-collector", + "actions": [ + "query" + ] }, - ], + { + "permission": "s7-client", + "actions": [ + "query" + ] + } + ] }, { - id: 'add', - name: '新增', - permissions: [ + "id": "add", + "name": "新增", + "permissions": [ { - permission: 'data-collect-channel', - actions: ['save', 'query'], + "permission": "data-collect-channel", + "actions": [ + "query", + "save" + ] }, { - permission: 'data-collector', - actions: ['save', 'query'], + "permission": "data-collector", + "actions": [ + "query", + "save" + ] }, { - permission: 'data-collect-opc', - actions: ['save', 'query'], + "permission": "data-collect-opc", + "actions": [ + "query", + "save" + ] }, { - permission: 'things-collector', - actions: ['save', 'query'], + "permission": "things-collector", + "actions": [ + "query", + "save" + ] }, - ], + { + "permission": "s7-client", + "actions": [ + "query" + ] + } + ] }, { - id: 'update', - name: '编辑', - permissions: [ + "id": "update", + "name": "编辑", + "permissions": [ { - permission: 'data-collect-channel', - actions: ['save', 'query'], + "permission": "data-collect-channel", + "actions": [ + "query", + "save" + ] }, { - permission: 'data-collector', - actions: ['save', 'query'], + "permission": "data-collector", + "actions": [ + "query", + "save" + ] }, { - permission: 'data-collect-opc', - actions: ['save', 'query'], + "permission": "data-collect-opc", + "actions": [ + "query", + "save" + ] }, { - permission: 'things-collector', - actions: ['save', 'query'], + "permission": "things-collector", + "actions": [ + "query", + "save" + ] }, { - permission: 'certificate', - actions: ['query'], + "permission": "certificate", + "actions": [ + "query" + ] }, - ], + { + "permission": "s7-client", + "actions": [ + "query" + ] + } + ] }, { - id: 'action', - name: '禁用/启用', - permissions: [ + "id": "action", + "name": "禁用/启用", + "permissions": [ { - permission: 'data-collect-channel', - actions: ['save', 'query'], + "permission": "data-collect-channel", + "actions": [ + "query", + "save" + ] }, { - permission: 'data-collector', - actions: ['save', 'query'], + "permission": "data-collector", + "actions": [ + "query", + "save" + ] }, { - permission: 'data-collect-opc', - actions: ['save', 'query'], + "permission": "data-collect-opc", + "actions": [ + "query", + "save" + ] }, { - permission: 'things-collector', - actions: ['save', 'query'], + "permission": "things-collector", + "actions": [ + "query", + "save" + ] }, - ], + { + "permission": "s7-client", + "actions": [] + } + ] }, { - id: 'delete', - name: '删除', - permissions: [ + "id": "delete", + "name": "删除", + "permissions": [ { - permission: 'data-collect-channel', - actions: ['delete', 'query'], + "permission": "data-collect-channel", + "actions": [ + "query", + "delete" + ] }, { - permission: 'data-collector', - actions: ['delete', 'query'], + "permission": "data-collector", + "actions": [ + "query", + "delete" + ] }, { - permission: 'data-collect-opc', - actions: ['delete', 'query'], + "permission": "data-collect-opc", + "actions": [ + "query", + "delete" + ] }, { - permission: 'things-collector', - actions: ['delete', 'query'], - }, - ], - }, + "permission": "things-collector", + "actions": [ + "query", + "delete" + ] + } + ] + } ], accessSupport: { text: "支持", value: "support" }, supportDataAccess: true, @@ -3445,6 +3528,30 @@ export default [ permission: 'role', actions: ['query'], }, + { + permission: 'role-group', + actions: ['query'] + } + ], + }, + { + id: 'groupUpdate', + name: '角色组编辑', + permissions: [ + { + permission: 'role-group', + actions: ['query','save'] + } + ], + }, + { + id: 'groupDelete', + name: '角色组删除', + permissions: [ + { + permission: 'role-group', + actions: ['query','delete'] + } ], }, ], @@ -4013,6 +4120,144 @@ export default [ accessSupport: { text: "不支持", value: "unsupported" }, supportDataAccess: false }, + { + code: 'system/Dictionary', + name: '数据字典', + owner: 'iot', + id: 'b69782873cc24be8165c6ad292359092', + sortIndex: 12, + url: '/system/Dictionary', + icon: 'FormOutlined', + showPage: ['dictionary'], + permissions: [], + buttons: [ + { + id: "add", + name: "新增", + permissions: [ + { + permission: "dictionary", + actions: [ + "save" + ] + } + ] + }, + { + id: "delete", + name: "删除", + permissions: [ + { + permission: "dictionary", + actions: [ + "delete" + ] + } + ] + }, + { + id: "update", + name: "编辑", + permissions: [ + { + permission: "dictionary", + actions: [ + "save" + ] + } + ] + }, + { + id: "import", + name: "导入", + permissions: [ + { + permission: "dictionary", + actions: [ + "save" + ] + } + ] + }, + { + id: "down", + name: "下载", + permissions: [ + { + permission: "dictionary", + actions: [ + "query" + ] + } + ] + }, + { + id: "action", + name: "启用/禁用", + permissions: [ + { + permission: "dictionary", + actions: [ + "save" + ] + } + ] + } + ], + accessSupport: { text: "不支持", value: "unsupported" }, + supportDataAccess: false + }, + { + code: 'system/Region', + name: '地区管理', + owner: 'iot', + id: 'b69782873cc24be8165c6ad29233333', + sortIndex: 12, + url: '/system/region', + icon: 'FormOutlined', + showPage: ['area'], + permissions: [], + buttons: [ + { + id: "add", + name: "新增", + permissions: [ + { + permission: "area", + actions: [ + "save" + ] + } + ] + }, + { + id: "delete", + name: "删除", + permissions: [ + { + permission: "area", + actions: [ + "delete" + ] + } + ] + }, + { + id: "update", + name: "编辑", + permissions: [ + { + permission: "area", + actions: [ + "save" + ] + } + ] + }, + ], + accessSupport: { text: "不支持", value: "unsupported" }, + supportDataAccess: false + }, // { // code: 'system/License', // name: 'License管理', @@ -4426,5 +4671,1387 @@ export default [ supportDataAccess: false }, ], + }, + { + "path": "3n23", + "sortIndex": 5, + "level": 1, + "owner": "iot", + "name": "WEB IDE", + "code": "web_ide", + "url": "/web_ide", + "icon": "MenuUnfoldOutlined", + showPage: ["low-code-info", "low-code-editor"], + "options": { + isShow: false, + }, + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + permissions: [ + { + "permission": "low-code-info", + "actions": [ + "add", "query", "save", "delete" + ] + }, + { + "permission": "low-code-editor", + "actions": [ + "query", "deploy" + ] + } + ], + "creatorId": "1199596756811550720", + "createTime": 1698735482730, + "supportDataAccess": false + }, + { + "path": "3nkE", + "sortIndex": 6, + "level": 1, + "owner": "iot", + "name": "流程引擎", + "code": "process", + "url": "/workflow", + "icon": "MenuUnfoldOutlined", + showPage: ["process-form","process-deployment", "process-runtime"], + "options": { + "show": true, + "isShow": false + }, + "permissions": [ + { + "permission": "low-code-info", + "actions": [ + "query" + ] + }, + { + "permission": "process-runtime", + "actions": [ + "transfer", + "reject", + "query", + "start", + "save", + "self", + "claim", + "delete-ready", + "complete", + "createAndStart", + "repeal" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "children": [ + // { + // "path": "3nkE-n7lJ", + // "sortIndex": 1, + // "level": 2, + // "name": "工作流", + // "code": "process/home", + // "describe": "", + // "url": "/workflow/home", + // "icon": "UpCircleOutlined", + // showPage: ["process-form"], + // "permissions": [ + // { + // "permission": "process-form", + // "actions": [ + // "query" + // ] + // }, + // { + // "permission": "low-code-info", + // "actions": [ + // "query" + // ] + // }, + // ], + // "accessSupport": { + // "text": "不支持", + // "value": "unsupported" + // }, + // "indirectMenus": [], + // "buttons": [], + // "options": { + // "show": true + // }, + // "creatorId": "1199596756811550720", + // "createTime": 1699263818795, + // "supportDataAccess": false + // }, + { + "path": "3nkE-n7lJ", + "sortIndex": 2, + "level": 2, + "name": "表单", + "code": "process/form", + "describe": "", + "owner": "iot", + "url": "/workflow/form", + "icon": "UpCircleOutlined", + showPage: ["process-form"], + "permissions": [ + { + "permission": "process-form", + "actions": [ + "query" + ] + }, + { + "permission": "role", + "actions": [ + "query" + ] + }, + { + "permission": "role-group", + "actions": [ + "query" + ] + }, + { + "permission": "user", + "actions": [ + "query" + ] + }, + { + "permission": "user-third-party-manager", + "actions": [ + "query" + ] + }, + { + "permission": "user-token", + "actions": [ + "query" + ] + }, + { + "permission": "device-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-category", + "actions": [ + "query" + ] + }, + { + "permission": "edge-product", + "actions": [ + "query" + ] + }, + { + "permission": "dueros-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-gateway", + "actions": [ + "query" + ] + }, + { + "permission": "device-msg-task", + "actions": [ + "query" + ] + }, + { + "permission": "device-group", + "actions": [ + "query" + ] + }, + { + "permission": "opc-point", + "actions": [ + "query" + ] + }, + { + "permission": "device-mapping", + "actions": [ + "query" + ] + }, + { + "permission": "dictionary", + "actions": [ + "query" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "buttons": [ + { + "id": "add", + "name": "新增", + "permissions": [ + { + "permission": "process-form", + "actions": [ + "save" + ] + } + ] + }, + { + "id": "save", + "name": "保存", + "permissions": [ + { + "permission": "process-form", + "actions": [ + "save" + ] + } + ] + }, + { + "id": "update", + "name": "编辑", + "permissions": [ + { + "permission": "process-form", + "actions": [ + "save" + ] + } + ] + }, + { + "id": "delete", + "name": "删除", + "permissions": [ + { + "permission": "process-form", + "actions": [ + "delete" + ] + } + ] + } + ], + "options": { + "show": true + }, + "creatorId": "1199596756811550720", + "createTime": 1699263818795, + "supportDataAccess": false + }, + { + "path": "3nkE-ysKb", + "sortIndex": 3, + "level": 2, + "name": "流程模型", + "code": "process/model", + "describe": "", + "owner": "iot", + "url": "/workflow/model", + "icon": "UpCircleOutlined", + showPage: ["process-definition"], + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "query" + ] + }, + { + "permission": "role", + "actions": [ + "query" + ] + }, + { + "permission": "role-group", + "actions": [ + "query" + ] + }, + { + "permission": "user", + "actions": [ + "query" + ] + }, + { + "permission": "user-third-party-manager", + "actions": [ + "query" + ] + }, + { + "permission": "user-token", + "actions": [ + "query" + ] + }, + { + "permission": "device-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-category", + "actions": [ + "query" + ] + }, + { + "permission": "edge-product", + "actions": [ + "query" + ] + }, + { + "permission": "dueros-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-gateway", + "actions": [ + "query" + ] + }, + { + "permission": "device-msg-task", + "actions": [ + "query" + ] + }, + { + "permission": "device-group", + "actions": [ + "query" + ] + }, + { + "permission": "opc-point", + "actions": [ + "query" + ] + }, + { + "permission": "device-mapping", + "actions": [ + "query" + ] + }, + { + "permission": "dictionary", + "actions": [ + "query" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "buttons": [ + { + "id": "add", + "name": "新增", + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "save" + ] + } + ] + }, + { + "id": "delete", + "name": "删除", + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "delete" + ] + } + ] + }, + { + "id": "update", + "name": "编辑", + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "save" + ] + } + ] + }, + { + "id": "save", + "name": "保存", + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "save" + ] + } + ] + }, + { + "id": "deploy", + "name": "部署", + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "save" + ] + } + ] + } + ], + "options": { + "show": true + }, + "creatorId": "1199596756811550720", + "createTime": 1699264341009, + "supportDataAccess": false + }, + { + "path": "3nkE-fJkR", + "sortIndex": 4, + "level": 2, + "name": "流程实例", + "code": "process/instance", + "describe": "", + "owner": "iot", + showPage: ["process-deployment"], + "url": "/workflow/instance", + "icon": "UpCircleOutlined", + "status": 1, + "permissions": [ + { + "permission": "process-deployment", + "actions": [ + "query" + ] + }, + { + "permission": "role", + "actions": [ + "query" + ] + }, + { + "permission": "role-group", + "actions": [ + "query" + ] + }, + { + "permission": "user", + "actions": [ + "query" + ] + }, + { + "permission": "user-third-party-manager", + "actions": [ + "query" + ] + }, + { + "permission": "user-token", + "actions": [ + "query" + ] + }, + { + "permission": "device-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-category", + "actions": [ + "query" + ] + }, + { + "permission": "edge-product", + "actions": [ + "query" + ] + }, + { + "permission": "dueros-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-gateway", + "actions": [ + "query" + ] + }, + { + "permission": "device-msg-task", + "actions": [ + "query" + ] + }, + { + "permission": "device-group", + "actions": [ + "query" + ] + }, + { + "permission": "opc-point", + "actions": [ + "query" + ] + }, + { + "permission": "device-mapping", + "actions": [ + "query" + ] + }, + { + "permission": "dictionary", + "actions": [ + "query" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "buttons": [ + { + "id": "action", + "name": "启/禁用", + "permissions": [ + { + "permission": "process-deployment", + "actions": [ + "save" + ] + } + ] + }, + { + "id": "auth", + "name": "权限控制", + "permissions": [ + { + "permission": "process-deployment", + "actions": [ + "save" + ] + } + ] + }, + { + "id": "delete", + "name": "删除", + "permissions": [ + { + "permission": "process-deployment", + "actions": [ + "delete" + ] + } + ] + } + ], + "options": { + "show": true + }, + "creatorId": "1199596756811550720", + "createTime": 1699264485954, + "supportDataAccess": false + }, + { + "path": "3nkE-i2nG", + "sortIndex": 5, + "level": 2, + "name": "发起流程", + "code": "process/initiate", + "describe": "", + "owner": "iot", + "url": "/workflow/initiate", + "icon": "UpOutlined", + showPage: ["process-runtime"], + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "query" + ] + }, + { + "permission": "process-deployment", + "actions": [ + "query" + ] + }, + { + "permission": "process-form", + "actions": [ + "query" + ] + }, + { + "permission": "process-runtime", + "actions": [ + "transfer", + "reject", + "query", + "start", + "save", + "self", + "claim", + "delete-ready", + "complete", + "createAndStart", + "repeal" + ] + }, + { + "permission": "role", + "actions": [ + "query" + ] + }, + { + "permission": "role-group", + "actions": [ + "query" + ] + }, + { + "permission": "user", + "actions": [ + "query" + ] + }, + { + "permission": "user-third-party-manager", + "actions": [ + "query" + ] + }, + { + "permission": "user-token", + "actions": [ + "query" + ] + }, + { + "permission": "device-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-category", + "actions": [ + "query" + ] + }, + { + "permission": "edge-product", + "actions": [ + "query" + ] + }, + { + "permission": "dueros-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-gateway", + "actions": [ + "query" + ] + }, + { + "permission": "device-msg-task", + "actions": [ + "query" + ] + }, + { + "permission": "device-group", + "actions": [ + "query" + ] + }, + { + "permission": "opc-point", + "actions": [ + "query" + ] + }, + { + "permission": "device-mapping", + "actions": [ + "query" + ] + }, + { + "permission": "dictionary", + "actions": [ + "query" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "options": { + "show": true + }, + "creatorId": "1199596756811550720", + "createTime": 1699269393605, + "supportDataAccess": false + }, + { + "path": "3nkE-4T1D", + "sortIndex": 6, + "level": 2, + "name": "待办事项", + "code": "process/me/todo", + "describe": "", + "owner": "iot", + "url": "/workflow/me/todo", + "icon": "UpCircleOutlined", + showPage: ["process-runtime"], + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "query" + ] + }, + { + "permission": "process-deployment", + "actions": [ + "query" + ] + }, + { + "permission": "process-form", + "actions": [ + "query" + ] + }, + { + "permission": "process-runtime", + "actions": [ + "transfer", + "reject", + "query", + "start", + "save", + "self", + "claim", + "delete-ready", + "complete", + "createAndStart", + "repeal" + ] + }, + { + "permission": "role", + "actions": [ + "query" + ] + }, + { + "permission": "role-group", + "actions": [ + "query" + ] + }, + { + "permission": "user", + "actions": [ + "query" + ] + }, + { + "permission": "user-third-party-manager", + "actions": [ + "query" + ] + }, + { + "permission": "user-token", + "actions": [ + "query" + ] + }, + { + "permission": "device-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-category", + "actions": [ + "query" + ] + }, + { + "permission": "edge-product", + "actions": [ + "query" + ] + }, + { + "permission": "dueros-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-gateway", + "actions": [ + "query" + ] + }, + { + "permission": "device-msg-task", + "actions": [ + "query" + ] + }, + { + "permission": "device-group", + "actions": [ + "query" + ] + }, + { + "permission": "opc-point", + "actions": [ + "query" + ] + }, + { + "permission": "device-mapping", + "actions": [ + "query" + ] + }, + { + "permission": "dictionary", + "actions": [ + "query" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "options": { + "show": true + }, + "creatorId": "1199596756811550720", + "createTime": 1699269425041, + "supportDataAccess": false + }, + { + "path": "3nkE-RXP3", + "sortIndex": 7, + "level": 2, + "name": "已办事项", + "code": "process/me/finished", + "describe": "", + "owner": "iot", + "url": "/workflow/me/finished", + "icon": "UpCircleOutlined", + showPage: ["process-runtime"], + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "query" + ] + }, + { + "permission": "process-deployment", + "actions": [ + "query" + ] + }, + { + "permission": "process-form", + "actions": [ + "query" + ] + }, + { + "permission": "process-runtime", + "actions": [ + "transfer", + "reject", + "query", + "start", + "save", + "self", + "claim", + "delete-ready", + "complete", + "createAndStart", + "repeal" + ] + }, + { + "permission": "role", + "actions": [ + "query" + ] + }, + { + "permission": "role-group", + "actions": [ + "query" + ] + }, + { + "permission": "user", + "actions": [ + "query" + ] + }, + { + "permission": "user-third-party-manager", + "actions": [ + "query" + ] + }, + { + "permission": "user-token", + "actions": [ + "query" + ] + }, + { + "permission": "device-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-category", + "actions": [ + "query" + ] + }, + { + "permission": "edge-product", + "actions": [ + "query" + ] + }, + { + "permission": "dueros-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-gateway", + "actions": [ + "query" + ] + }, + { + "permission": "device-msg-task", + "actions": [ + "query" + ] + }, + { + "permission": "device-group", + "actions": [ + "query" + ] + }, + { + "permission": "opc-point", + "actions": [ + "query" + ] + }, + { + "permission": "device-mapping", + "actions": [ + "query" + ] + }, + { + "permission": "dictionary", + "actions": [ + "query" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "options": { + "show": true + }, + "creatorId": "1199596756811550720", + "createTime": 1699269455412, + "supportDataAccess": false + }, + { + "path": "3nkE-ibau", + "sortIndex": 8, + "level": 2, + "name": "我发起的", + "code": "process/me/initiate", + "describe": "", + "owner": "iot", + "url": "/workflow/me/initiate", + "icon": "UpCircleOutlined", + showPage: ["process-runtime"], + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "query" + ] + }, + { + "permission": "process-deployment", + "actions": [ + "query" + ] + }, + { + "permission": "process-form", + "actions": [ + "query" + ] + }, + { + "permission": "process-runtime", + "actions": [ + "transfer", + "reject", + "query", + "start", + "save", + "self", + "claim", + "delete-ready", + "complete", + "createAndStart", + "repeal" + ] + }, + { + "permission": "role", + "actions": [ + "query" + ] + }, + { + "permission": "role-group", + "actions": [ + "query" + ] + }, + { + "permission": "user", + "actions": [ + "query" + ] + }, + { + "permission": "user-third-party-manager", + "actions": [ + "query" + ] + }, + { + "permission": "user-token", + "actions": [ + "query" + ] + }, + { + "permission": "device-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-category", + "actions": [ + "query" + ] + }, + { + "permission": "edge-product", + "actions": [ + "query" + ] + }, + { + "permission": "dueros-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-gateway", + "actions": [ + "query" + ] + }, + { + "permission": "device-msg-task", + "actions": [ + "query" + ] + }, + { + "permission": "device-group", + "actions": [ + "query" + ] + }, + { + "permission": "opc-point", + "actions": [ + "query" + ] + }, + { + "permission": "device-mapping", + "actions": [ + "query" + ] + }, + { + "permission": "dictionary", + "actions": [ + "query" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "options": { + "show": true + }, + "creatorId": "1199596756811550720", + "createTime": 1699269488928, + "supportDataAccess": false + }, + { + "path": "3nkE-vCQb", + "sortIndex": 9, + "level": 2, + "name": "抄送给我", + "code": "process/me/cc", + "describe": "", + "owner": "iot", + "url": "/workflow/me/cc", + "icon": "BorderInnerOutlined", + "status": 1, + showPage: ["process-runtime"], + "permissions": [ + { + "permission": "process-definition", + "actions": [ + "query" + ] + }, + { + "permission": "process-runtime", + "actions": [ + "transfer", + "reject", + "query", + "start", + "save", + "self", + "claim", + "delete-ready", + "complete", + "createAndStart", + "repeal" + ] + }, + { + "permission": "process-deployment", + "actions": [ + "query" + ] + }, + { + "permission": "process-form", + "actions": [ + "query" + ] + }, + { + "permission": "role", + "actions": [ + "query" + ] + }, + { + "permission": "role-group", + "actions": [ + "query" + ] + }, + { + "permission": "user", + "actions": [ + "query" + ] + }, + { + "permission": "user-third-party-manager", + "actions": [ + "query" + ] + }, + { + "permission": "user-token", + "actions": [ + "query" + ] + }, + { + "permission": "device-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-category", + "actions": [ + "query" + ] + }, + { + "permission": "edge-product", + "actions": [ + "query" + ] + }, + { + "permission": "dueros-product", + "actions": [ + "query" + ] + }, + { + "permission": "device-gateway", + "actions": [ + "query" + ] + }, + { + "permission": "device-msg-task", + "actions": [ + "query" + ] + }, + { + "permission": "device-group", + "actions": [ + "query" + ] + }, + { + "permission": "opc-point", + "actions": [ + "query" + ] + }, + { + "permission": "device-mapping", + "actions": [ + "query" + ] + }, + { + "permission": "dictionary", + "actions": [ + "query" + ] + } + ], + "accessSupport": { + "text": "不支持", + "value": "unsupported" + }, + "indirectMenus": [], + "options": { + "show": true + }, + "creatorId": "1199596756811550720", + "createTime": 1699348851779, + "supportDataAccess": false + } + ], + "creatorId": "8004214f8141f29cb951befdca3615f0", + "createTime": 1699262480040, + "supportDataAccess": false } ]; diff --git a/src/views/init-home/index.vue b/src/views/init-home/index.vue index f8becc64..3e48d85c 100644 --- a/src/views/init-home/index.vue +++ b/src/views/init-home/index.vue @@ -112,6 +112,11 @@ const submitData = async () => { loading.value = false; return; } + const roleGroupRes = await roleRef.value.submitRoleGroup(); + if (!roleGroupRes) { + loading.value = false; + return; + } const initDataRes = await initDataRef.value.save(); if (!initDataRes) { loading.value = false; @@ -119,7 +124,7 @@ const submitData = async () => { } loading.value = false; // 当前数据是否成功提交 - if (basicRes && menuRes && roleRes && initDataRes) { + if (basicRes && menuRes && roleRes && roleGroupRes && initDataRes) { onlyMessage('保存成功'); // // 记录初始化数据,跳转首页 const res = await saveInit(); diff --git a/src/views/rule-engine/Scene/Save/action/ListItem/FilterCondition.vue b/src/views/rule-engine/Scene/Save/action/ListItem/FilterCondition.vue index 5469d1d2..08a81d47 100644 --- a/src/views/rule-engine/Scene/Save/action/ListItem/FilterCondition.vue +++ b/src/views/rule-engine/Scene/Save/action/ListItem/FilterCondition.vue @@ -203,6 +203,17 @@ const handOptionByColumn = (option: any) => { valueOptions.value = [] valueColumnOptions.value = [] } + if(paramsValue.termType){ + if (columnType.value ==='date') { + if (timeTypeKeys.includes(paramsValue.termType)) { + if (tabsOptions.value[0].component !== 'int') { + } + tabsOptions.value[0].component = 'int' + } else if (!timeTypeKeys.includes(paramsValue.termType) && tabsOptions.value[0].component == 'int') { + tabsOptions.value[0].component = 'date' + } + } + } } watch(() => [columnOptions.value, paramsValue.column], () => { @@ -367,4 +378,4 @@ nextTick(() => { \ No newline at end of file + diff --git a/src/views/system/Apply/componenets/MenuDialog.vue b/src/views/system/Apply/componenets/MenuDialog.vue index c5f13f13..ce351e2c 100644 --- a/src/views/system/Apply/componenets/MenuDialog.vue +++ b/src/views/system/Apply/componenets/MenuDialog.vue @@ -127,7 +127,16 @@ function getMenus(id: string) { { column: 'appId', value: id, - }, + }, + { + terms:[ + { + value:"%show\":true%", + termType:"like", + column:"options" + } + ] + } ], }; getMenuTree_api(params).then((resp: any) => { diff --git a/src/views/system/Apply/index.vue b/src/views/system/Apply/index.vue index 486a395c..10589b6a 100644 --- a/src/views/system/Apply/index.vue +++ b/src/views/system/Apply/index.vue @@ -221,6 +221,7 @@ const permission = 'system/Apply'; const typeOptions = ref([]) const visible = ref(false) +const addMenuVisible = ref(false) onMounted(() => { queryType().then((resp: any) => { diff --git a/src/views/system/Basis/index.vue b/src/views/system/Basis/index.vue index 8fddcbb4..7424577b 100644 --- a/src/views/system/Basis/index.vue +++ b/src/views/system/Basis/index.vue @@ -332,7 +332,6 @@ import { save_api } from '@/api/system/basis'; import { usePermissionStore } from '@/store/permission'; import { useSystem } from '@/store/system'; import { settingDetail } from '@/api/login'; - const action = `${BASE_API_PATH}/file/static`; const headers = { [TOKEN_KEY]: LocalStore.get(TOKEN_KEY) }; const formRef = ref(); diff --git a/src/views/system/Dictionary/components/Left/Export/index.vue b/src/views/system/Dictionary/components/Left/Export/index.vue new file mode 100644 index 00000000..ebf5f3ec --- /dev/null +++ b/src/views/system/Dictionary/components/Left/Export/index.vue @@ -0,0 +1,98 @@ + + + + \ No newline at end of file diff --git a/src/views/system/Dictionary/components/Left/index.vue b/src/views/system/Dictionary/components/Left/index.vue new file mode 100644 index 00000000..f6ad60f6 --- /dev/null +++ b/src/views/system/Dictionary/components/Left/index.vue @@ -0,0 +1,218 @@ + + + + \ No newline at end of file diff --git a/src/views/system/Dictionary/components/Left/save/index.vue b/src/views/system/Dictionary/components/Left/save/index.vue new file mode 100644 index 00000000..17306c29 --- /dev/null +++ b/src/views/system/Dictionary/components/Left/save/index.vue @@ -0,0 +1,125 @@ + + + + \ No newline at end of file diff --git a/src/views/system/Dictionary/components/Right/Save/index.vue b/src/views/system/Dictionary/components/Right/Save/index.vue new file mode 100644 index 00000000..66cf6bb7 --- /dev/null +++ b/src/views/system/Dictionary/components/Right/Save/index.vue @@ -0,0 +1,143 @@ + + + + \ No newline at end of file diff --git a/src/views/system/Dictionary/components/Right/index.vue b/src/views/system/Dictionary/components/Right/index.vue new file mode 100644 index 00000000..49723fce --- /dev/null +++ b/src/views/system/Dictionary/components/Right/index.vue @@ -0,0 +1,229 @@ + + + + \ No newline at end of file diff --git a/src/views/system/Dictionary/index.vue b/src/views/system/Dictionary/index.vue new file mode 100644 index 00000000..f7a5cf78 --- /dev/null +++ b/src/views/system/Dictionary/index.vue @@ -0,0 +1,45 @@ + + + + \ No newline at end of file diff --git a/src/views/system/Menu/Detail/BasicInfo.vue b/src/views/system/Menu/Detail/BasicInfo.vue index 656295cf..74797a06 100644 --- a/src/views/system/Menu/Detail/BasicInfo.vue +++ b/src/views/system/Menu/Detail/BasicInfo.vue @@ -4,209 +4,125 @@

基本信息

- +
- - 点击修改 + + 点击修改
-
+
- +

点击选择图标

- - + + - - + + - - + + - - + + + + + + + - - - - -
- +
-
+

权限配置

- + - + 不支持 支持 间接控制 - - + + - - + + - +
@@ -285,10 +172,12 @@ import { saveMenuInfo_api, addMenuInfo_api, validCode_api, + queryApp } from '@/api/system/menu'; import { Rule } from 'ant-design-vue/lib/form'; import { isNoCommunity } from '@/utils/utils'; import { onlyMessage } from '@/utils/comm'; +import { applicationInfo } from '@/api/bind'; const permission = 'system/Menu'; // 路由 @@ -300,11 +189,13 @@ const routeParams = { url: route.query.basePath, parentId: route.query.pid, }; - +const isChildren = route.query?.isChildren // 表单 const basicFormRef = ref(); const permissFormRef = ref(); const uploadIcon = ref(); +//菜单应用选项 +const appOptions = ref([]) const form = reactive({ data: { name: '', @@ -316,6 +207,8 @@ const form = reactive({ accessSupport: 'unsupported', assetType: undefined, indirectMenus: [], + appId: '', + application:'', ...routeParams, } as formType, treeData: [], // 关联菜单 @@ -329,6 +222,7 @@ const form = reactive({ getMenuInfo_api(routeParams.id).then((resp: any) => { form.data = { ...(resp.result as formType), + permissions: resp.result?.permissions ? resp.result.permissions : [], accessSupport: resp.result?.accessSupport?.value || 'unsupported', }; @@ -337,7 +231,15 @@ const form = reactive({ if (isNoCommunity) { // 获取关联菜单 - getMenuTree_api({ paging: false }).then((resp: any) => { + getMenuTree_api({ paging: false,terms:[{terms:[{ + terms:[ + { + value:"%show\":true%", + termType:"like", + column:"options" + } + ] + }]}]}).then((resp: any) => { form.treeData = resp.result; }); // 获取资产类型 @@ -374,9 +276,9 @@ const form = reactive({ const api = routeParams.id ? saveMenuInfo_api : addMenuInfo_api; form.saveLoading = true; const accessSupportValue = form.data.accessSupport; - const params = { + const params:any = { ...form.data, - owner: form.data?.owner ?? null, + owner: 'iot', options: { show: true }, accessSupport: { value: accessSupportValue, @@ -384,10 +286,13 @@ const form = reactive({ accessSupportValue === 'unsupported' ? '不支持' : accessSupportValue === 'support' - ? '支持' - : '间接控制', + ? '支持' + : '间接控制', }, }; + if(params?.isChildren){ + delete params.isChildren + } api(params) .then((resp: any) => { if (resp.status === 200) { @@ -406,18 +311,41 @@ const form = reactive({ }) .finally(() => (form.saveLoading = false)); }) - .catch((err) => {}); + .catch((err) => { }); }, }); form.init(); -const choseIcon = (typeStr:string) =>{ +const choseIcon = (typeStr: string) => { form.data.icon = typeStr; uploadIcon.value?.clearValidate(); } + +const selectApp = (value:string,options:any) =>{ + form.data.application = options?.label +} // 弹窗 const dialogVisible = ref(false); +onMounted(() => { + queryApp({ + terms: [ + { + "column": "integrationModes", + "termType": "in$any", + "value": "page" + } + ], + paging: false + }).then((res:any)=>{ + appOptions.value = res.result?.map((i:any)=>{ + return { + label:i.name, + value:i.id + } + }) + }) +}) type formType = { id?: string; name: string; @@ -431,6 +359,8 @@ type formType = { assetType: string | undefined; indirectMenus: any[]; parentId?: string; + appId:string, + application:string }; type assetType = { @@ -441,11 +371,11 @@ type assetType = { + + \ No newline at end of file diff --git a/src/views/system/Region/MapTool/index.ts b/src/views/system/Region/MapTool/index.ts new file mode 100644 index 00000000..e69de29b diff --git a/src/views/system/Region/MapTool/map.vue b/src/views/system/Region/MapTool/map.vue new file mode 100644 index 00000000..86f53450 --- /dev/null +++ b/src/views/system/Region/MapTool/map.vue @@ -0,0 +1,304 @@ + + + + + diff --git a/src/views/system/Region/Save/BuildIn.vue b/src/views/system/Region/Save/BuildIn.vue new file mode 100644 index 00000000..b822a9bd --- /dev/null +++ b/src/views/system/Region/Save/BuildIn.vue @@ -0,0 +1,124 @@ + + + \ No newline at end of file diff --git a/src/views/system/Region/Save/TracePoint.vue b/src/views/system/Region/Save/TracePoint.vue new file mode 100644 index 00000000..7281fc21 --- /dev/null +++ b/src/views/system/Region/Save/TracePoint.vue @@ -0,0 +1,45 @@ + + + \ No newline at end of file diff --git a/src/views/system/Region/Save/index.vue b/src/views/system/Region/Save/index.vue new file mode 100644 index 00000000..af122b86 --- /dev/null +++ b/src/views/system/Region/Save/index.vue @@ -0,0 +1,234 @@ + + + \ No newline at end of file diff --git a/src/views/system/Region/index.vue b/src/views/system/Region/index.vue new file mode 100644 index 00000000..80eeafdd --- /dev/null +++ b/src/views/system/Region/index.vue @@ -0,0 +1,65 @@ + + + + + diff --git a/src/views/system/Relationship/components/EditDialog.vue b/src/views/system/Relationship/components/EditDialog.vue index 76a59000..8d733421 100644 --- a/src/views/system/Relationship/components/EditDialog.vue +++ b/src/views/system/Relationship/components/EditDialog.vue @@ -10,22 +10,9 @@ class="edit-dialog-container" > - - - + + 正向关系示例:用户张三是001号视频设备的管理员 + + + + + 反向关系示例:001号视频设备是用户张三的管辖设备 + (); // 弹窗相关 const loading = ref(false); +const targetList = ref([]) const dialogTitle = computed(() => (props.data.id ? '编辑' : '新增')); const confirm = () => { loading.value = true; @@ -180,6 +199,7 @@ const form = reactive({ getObjectList: () => { getObjectList_api().then((resp: any) => { form.objectList = resp.result; + targetList.value = resp.result }); }, submit: () => { @@ -187,7 +207,7 @@ const form = reactive({ ...form.data, objectTypeName: form.objectList.find( (item) => item.id === form.data.objectType, - ).name, + )?.name, targetTypeName: targetList.value.find( (item: dictItemType) => item.id === form.data.targetType, )?.name, @@ -196,13 +216,17 @@ const form = reactive({ return api(params); }, }); -const targetList = computed(() => - form.data.objectType === 'device' ? [{ id: 'user', name: '用户' }] : [], -); +const validateName = async(_:any,value:any)=>{ + if(!value){ + return Promise.resolve() + } + return form.data.reverseName === form.data.name ? Promise.reject('不能使用相同的关系名称') : Promise.resolve() +} form.getObjectList(); type formType = { name: string; + reverseName: string; relation: string; objectType: string | undefined; targetType: string | undefined; @@ -210,3 +234,9 @@ type formType = { id?: string; }; + diff --git a/src/views/system/Relationship/index.vue b/src/views/system/Relationship/index.vue index 4dbbf215..78d5de64 100644 --- a/src/views/system/Relationship/index.vue +++ b/src/views/system/Relationship/index.vue @@ -72,6 +72,7 @@ import PermissionButton from '@/components/PermissionButton/index.vue'; import { getRelationshipList_api, delRelation_api, + getObjectList_api } from '@/api/system/relationship'; import EditDialog from './components/EditDialog.vue'; import { onlyMessage } from '@/utils/comm'; @@ -80,7 +81,7 @@ const permission = 'system/Relationship'; const columns = [ { - title: '名称', + title: '正向关系名称', dataIndex: 'name', key: 'name', ellipsis: true, @@ -89,6 +90,16 @@ const columns = [ type: 'string', }, }, + { + title: '反向关系名称', + dataIndex: 'reverseName', + key: 'reverseName', + ellipsis: true, + fixed: 'left', + search: { + type: 'string', + }, + }, { title: '关联方', dataIndex: 'objectTypeName', @@ -97,17 +108,16 @@ const columns = [ fixed: 'left', search: { type: 'select', - options: [ - { - label: '用户', - value: '用户', - }, - { - label: '设备', - value: '设备', - }, - ], - }, + options: async () =>{ + const res:any = await getObjectList_api() + return res.result?.map((i:any)=>{ + return { + label:i.name, + value:i.id + } + }) + } + } }, { title: '被关联方', @@ -118,12 +128,15 @@ const columns = [ search: { rename: 'targetType', type: 'select', - options: [ - { - label: '用户', - value: 'user', - }, - ], + options: async () =>{ + const res:any = await getObjectList_api() + return res.result?.map((i:any)=>{ + return { + label:i.name, + value:i.id + } + }) + } }, }, { @@ -174,6 +187,7 @@ const dialog = reactive({ selectRow: {} as any, visible: false, }); + \ No newline at end of file diff --git a/src/views/system/Role/RoleRight/components/AddDialog.vue b/src/views/system/Role/RoleRight/components/AddDialog.vue new file mode 100644 index 00000000..9cfcadfc --- /dev/null +++ b/src/views/system/Role/RoleRight/components/AddDialog.vue @@ -0,0 +1,139 @@ + + + + + diff --git a/src/views/system/Role/RoleRight/index.vue b/src/views/system/Role/RoleRight/index.vue new file mode 100644 index 00000000..857a0b18 --- /dev/null +++ b/src/views/system/Role/RoleRight/index.vue @@ -0,0 +1,193 @@ + + + + + diff --git a/src/views/system/Role/components/AddDialog.vue b/src/views/system/Role/components/AddDialog.vue deleted file mode 100644 index 0154f3e9..00000000 --- a/src/views/system/Role/components/AddDialog.vue +++ /dev/null @@ -1,79 +0,0 @@ - - - - - diff --git a/src/views/system/Role/index.vue b/src/views/system/Role/index.vue index d104a40b..c435d41c 100644 --- a/src/views/system/Role/index.vue +++ b/src/views/system/Role/index.vue @@ -1,142 +1,40 @@ - - - - + + + + \ No newline at end of file diff --git a/src/views/system/User/components/EditUserDialog.vue b/src/views/system/User/components/EditUserDialog.vue index be2119eb..2154f31e 100644 --- a/src/views/system/User/components/EditUserDialog.vue +++ b/src/views/system/User/components/EditUserDialog.vue @@ -12,8 +12,9 @@ okText="确定" > +
基础信息
- + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
账号信息
+ + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@@ -200,6 +214,7 @@ import { updateUser_api, updatePassword_api, getUser_api, + getRoleList } from '@/api/system/user'; import { Rule } from 'ant-design-vue/es/form'; import { DefaultOptionType } from 'ant-design-vue/es/vc-tree-select/TreeSelect'; @@ -207,10 +222,7 @@ import { AxiosResponse } from 'axios'; import { passwordRegEx } from '@/utils/validate'; import { filterSelectNode, onlyMessage } from '@/utils/comm'; import { uniqBy } from 'lodash-es'; - -const admin = computed(() => { - return userInfos.value?.username === 'admin'; -}) +import { storeToRefs } from 'pinia'; const deptPermission = 'system/Department'; const rolePermission = 'system/Role'; @@ -282,10 +294,9 @@ const form = reactive({ }, }, - roleOptions: [] as optionType[], + roleOptions: [], departmentOptions: [] as DefaultOptionType[], - _roleOptions: [] as optionType[], _departmentOptions: [] as DefaultOptionType[], init: () => { @@ -309,8 +320,8 @@ const form = reactive({ (item: dictType) => item.id, ), }; - form._roleOptions = resp.result?.roleList?.map((i: any) => { - return {label: i.name, value: i.id} + form.data.roleIdList = resp.result?.roleList?.map((i: any) => { + return i.id }); form._departmentOptions = resp.result?.orgList nextTick(() => { @@ -348,16 +359,22 @@ const form = reactive({ return api(params); }, getRoleList: () => { - getRoleList_api().then((resp: any) => { - form.roleOptions = resp.result.map((item: dictType) => ({ - label: item.name, - value: item.id, - })); + getRoleList({ sorts: [{ name: 'createTime', order: 'desc' }] }).then((resp: any) => { + if(resp.status === 200){ + form.roleOptions = dealRoleList(resp.result) + } }); }, getDepartmentList: () => { - getDepartmentList_api().then((resp: any) => { - form.departmentOptions = resp.result; + getDepartmentList_api({ + paging: false, + sorts: [{ name: 'sortIndex', order: 'asc' }], + }).then((resp: any) => { + form.departmentOptions = resp.result.sort((a: any, b: any) => + a.sortIndex === b.sortIndex + ? b.createTime - a.createTime + : a.sortIndex - b.sortIndex, + ); // 报存源数据; }); }, IsShow: (...typeList: modalType[]) => typeList.includes(props.type), @@ -371,13 +388,25 @@ const form = reactive({ }, }); -const _roleOptions = computed(() => { - return uniqBy([...form.roleOptions, ...form._roleOptions], 'value') -}) - -const _departmentOptions = computed(() => { - return uniqBy([...form.departmentOptions, ...form._departmentOptions], 'id') -}) +const dealRoleList = (data:any) =>{ + return data.map((item:any)=>{ + return { + name: item.groupName, + id: item.groupId, + disabled: true, + children: item?.roles ? item.roles.map((i:any)=>{ + return { + name:i.name, + id:i.id + } + }) : [] + } + }) +} +// 组织已删除在仍显示在列表中 +// const _departmentOptions = computed(() => { +// return uniqBy([...form.departmentOptions, ...form._departmentOptions], 'id') +// }) form.init(); @@ -442,4 +471,16 @@ type optionType = { } } } +.formName{ + margin-bottom: 10px; + font-size: 16px; + &::before{ + width: 2px; + background-color: rgb(184, 184, 184); + display: inline-block; + height: 13px; + margin-right: 3px; + content:'' + } +} diff --git a/src/views/system/User/index.vue b/src/views/system/User/index.vue index 71c6b654..28542da6 100644 --- a/src/views/system/User/index.vue +++ b/src/views/system/User/index.vue @@ -29,6 +29,13 @@ +