feat: user manage
Some checks are pending
sync2gitee / repo-sync (push) Waiting to run

This commit is contained in:
wangdan-fit2cloud 2025-05-29 19:25:21 +08:00
parent 1dadc06220
commit 54e3804ca8
10 changed files with 89 additions and 1 deletions

View File

@ -0,0 +1,57 @@
import { h } from 'vue'
export default {
'app-resource-authorization': {
iconReader: () => {
return h('i', [
h(
'svg',
{
style: { height: '100%', width: '100%' },
viewBox: '0 0 20 20',
version: '1.1',
xmlns: 'http://www.w3.org/2000/svg',
},
[
h('path', {
d: 'M10.354 0.484228C10.1252 0.417397 9.88209 0.417366 9.6533 0.484138L2.56643 2.55237C2.0332 2.70799 1.66663 3.19683 1.66663 3.75232V7.92864C1.66663 12.9588 4.8543 17.43 9.59603 19.076C9.85818 19.167 10.144 19.167 10.4061 19.076C15.1466 17.4299 18.3333 12.9597 18.3333 7.93073V3.75223C18.3333 3.19687 17.9669 2.7081 17.4338 2.55238L10.354 0.484228ZM3.33329 4.06476L10.0034 2.11815L16.6666 4.0646V7.93073C16.6666 12.199 13.9934 15.9986 10.001 17.4512C6.00742 15.9986 3.33329 12.1981 3.33329 7.92864V4.06476Z',
fill: 'currentColor',
}),
h('path', {
d: 'M10 10C8.61917 10 7.5 8.87917 7.5 7.5C7.5 6.12083 8.61917 5 10 5C11.3808 5 12.5 6.12083 12.5 7.5C12.5 8.87917 11.3808 10 10 10ZM10 8.33333C10.4604 8.33333 10.8333 7.95833 10.8333 7.5C10.8333 7.04167 10.4604 6.66667 10 6.66667C9.53958 6.66667 9.16667 7.04167 9.16667 7.5C9.16667 7.95833 9.53958 8.33333 10 8.33333Z',
fill: 'currentColor',
}),
h('path', {
d: 'M10.8333 14.5918C10.8333 14.8173 10.6467 15 10.4166 15H9.58329C9.35317 15 9.16663 14.8173 9.16663 14.5918L9.16663 8.7415C9.16663 8.51607 9.35317 8.33333 9.58329 8.33333H10.4166C10.6467 8.33333 10.8333 8.51607 10.8333 8.7415V14.5918Z',
fill: 'currentColor',
}),
h('path', {
d: 'M10.3571 12.5C10.1599 12.5 10 12.3135 10 12.0834V11.25C10 11.0199 10.1599 10.8334 10.3571 10.8334H12.1429C12.3401 10.8334 12.5 11.0199 12.5 11.25V12.0834C12.5 12.3135 12.3401 12.5 12.1429 12.5H10.3571Z',
fill: 'currentColor',
}),
],
),
])
},
},
'app-resource-authorization-active': {
iconReader: () => {
return h('i', [
h(
'svg',
{
style: { height: '100%', width: '100%' },
viewBox: '0 0 20 20',
version: '1.1',
xmlns: 'http://www.w3.org/2000/svg',
},
[
h('path', {
d: 'M9.65332 0.483805C9.88209 0.417057 10.1257 0.416982 10.3545 0.483805L17.4336 2.55216C17.9667 2.70789 18.333 3.197 18.333 3.75236V7.93107C18.3329 12.9599 15.1465 17.4295 10.4062 19.0756C10.1441 19.1666 9.85786 19.1666 9.5957 19.0756C4.85437 17.4295 1.66718 12.959 1.66699 7.92912V3.75236C1.66699 3.19688 2.03317 2.70779 2.56641 2.55216L9.65332 0.483805ZM10 5.00041C8.61917 5.00041 7.5 6.12124 7.5 7.50041C7.50016 8.58756 8.19605 9.51433 9.16699 9.85783V14.5922C9.16717 14.8174 9.35315 15.0002 9.58301 15.0004H10.417C10.6469 15.0002 10.8328 14.8174 10.833 14.5922V12.5004H12.1426C12.3398 12.5004 12.5 12.3135 12.5 12.0834V11.2504C12.5 11.0203 12.3398 10.8334 12.1426 10.8334H10.833V9.85783C11.8039 9.51433 12.4998 8.58756 12.5 7.50041C12.5 6.12124 11.3808 5.00041 10 5.00041ZM10 6.66642C10.4604 6.66642 10.833 7.04207 10.833 7.50041C10.8328 7.95825 10.4608 8.33289 10.001 8.33341H9.99902C9.53918 8.33288 9.16719 7.95825 9.16699 7.50041C9.16699 7.04207 9.53958 6.66642 10 6.66642Z',
fill: 'currentColor',
}),
],
),
])
},
},
}

View File

@ -14,8 +14,11 @@ import { useRoute } from 'vue-router'
const route = useRoute()
const cachedViews: any = ref([])
onBeforeUpdate(() => {
const { name, meta } = route
if (name && !cachedViews.value.includes(name)) {
cachedViews.value.push(name)

View File

@ -5,6 +5,7 @@ import dataset from './dataset'
import system from './system'
import tool from './tool'
import userManage from './user-manage'
import resourceAuthorization from './resource-authorization'
import team from './team'
import model from './model'
import document from './document'
@ -21,6 +22,7 @@ export default {
system,
tool,
userManage,
resourceAuthorization,
team,
model,
dataset,

View File

@ -0,0 +1,3 @@
export default {
title: 'Resource Authorization',
}

View File

@ -5,6 +5,7 @@ import tool from './tool'
import document from './document'
import system from './system'
import userManage from './user-manage'
import resourceAuthorization from './resource-authorization'
// import notFound from './404'
// import application from './application'
// import applicationOverview from './application-overview'
@ -26,6 +27,7 @@ export default {
document,
system,
userManage,
resourceAuthorization
// notFound,
// application,
// applicationOverview,

View File

@ -0,0 +1,3 @@
export default {
title: '资源授权',
}

View File

@ -5,6 +5,7 @@ import dataset from './dataset'
import system from './system'
import tool from './tool'
import userManage from './user-manage'
import resourceAuthorization from './resource-authorization'
import team from './team'
import model from './model'
import document from './document'
@ -21,6 +22,7 @@ export default {
system,
tool,
userManage,
resourceAuthorization,
team,
model,
dataset,

View File

@ -0,0 +1,3 @@
export default {
title: '资源授权',
}

View File

@ -19,6 +19,19 @@ const systemRouter = {
},
component: () => import('@/views/user-manage/index.vue'),
},
{
path: '/system/authorization',
name: 'authorization',
meta: {
icon: 'app-resource-authorization',
iconActive: 'app-resource-authorization-active',
title: 'views.resourceAuthorization.title',
activeMenu: '/system',
parentPath: '/system',
parentName: 'system',
},
component: () => import('@/views/resource-authorization/index.vue'),
},
],
}

View File

@ -1,4 +1,4 @@
<template>111</template>
<template><span>22222</span></template>
<script lang="ts" setup>
import { onMounted, ref, reactive, watch } from 'vue'