mirror of https://gitee.com/topiam/eiam
✨ 应用管理
parent
7adb8641c7
commit
a60d6b670c
|
@ -145,28 +145,37 @@ export default [
|
||||||
name: 'app',
|
name: 'app',
|
||||||
icon: 'AppstoreOutlined',
|
icon: 'AppstoreOutlined',
|
||||||
path: '/app',
|
path: '/app',
|
||||||
component: './app/AppList',
|
routes: [
|
||||||
},
|
{
|
||||||
//创建应用
|
path: '/app',
|
||||||
{
|
redirect: '/app/list',
|
||||||
name: 'app.create',
|
},
|
||||||
path: '/app/create',
|
//创建应用
|
||||||
hideInMenu: true,
|
{
|
||||||
component: './app/AppCreate',
|
name: 'create',
|
||||||
},
|
path: '/app/create',
|
||||||
//应用详情
|
component: './app/AppCreate',
|
||||||
{
|
},
|
||||||
name: 'app.detail',
|
//应用列表
|
||||||
path: '/app/detail',
|
{
|
||||||
hideInMenu: true,
|
name: 'list',
|
||||||
component: './app/AppDetail',
|
path: '/app/list',
|
||||||
},
|
component: './app/AppList',
|
||||||
//应用分组
|
},
|
||||||
{
|
//应用详情
|
||||||
name: 'app.group',
|
{
|
||||||
path: '/app/group',
|
name: 'detail',
|
||||||
hideInMenu: true,
|
path: '/app/list/detail',
|
||||||
component: './app/AppGroup',
|
hideInMenu: true,
|
||||||
|
component: './app/AppDetail',
|
||||||
|
},
|
||||||
|
//应用分组
|
||||||
|
{
|
||||||
|
name: 'group',
|
||||||
|
path: '/app/group',
|
||||||
|
component: './app/AppGroup',
|
||||||
|
},
|
||||||
|
],
|
||||||
},
|
},
|
||||||
//行为审计
|
//行为审计
|
||||||
{
|
{
|
||||||
|
|
|
@ -23,7 +23,7 @@ import { useRef, useState } from 'react';
|
||||||
import CreateModal from './components/CreateModal';
|
import CreateModal from './components/CreateModal';
|
||||||
import UpdateModal from './components/UpdateModal';
|
import UpdateModal from './components/UpdateModal';
|
||||||
import { createAppGroup, removeAppGroup, updateAppGroup } from './service';
|
import { createAppGroup, removeAppGroup, updateAppGroup } from './service';
|
||||||
import { history, useIntl } from '@@/exports';
|
import { useIntl } from '@@/exports';
|
||||||
import { getAppGroupList } from '@/services/app';
|
import { getAppGroupList } from '@/services/app';
|
||||||
|
|
||||||
export default () => {
|
export default () => {
|
||||||
|
@ -101,7 +101,7 @@ export default () => {
|
||||||
key: 'option',
|
key: 'option',
|
||||||
width: 100,
|
width: 100,
|
||||||
align: 'center',
|
align: 'center',
|
||||||
render: (text, record) => [
|
render: (_text, record) => [
|
||||||
<a
|
<a
|
||||||
key="editable"
|
key="editable"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
|
@ -157,12 +157,7 @@ export default () => {
|
||||||
];
|
];
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<PageContainer
|
<PageContainer content={intl.formatMessage({ id: 'pages.app_group.list.desc' })}>
|
||||||
content={intl.formatMessage({ id: 'pages.app_group.list.desc' })}
|
|
||||||
onBack={() => {
|
|
||||||
history.push('/app');
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<ProTable<AppAPI.AppGroupList>
|
<ProTable<AppAPI.AppGroupList>
|
||||||
columns={columns}
|
columns={columns}
|
||||||
actionRef={actionRef}
|
actionRef={actionRef}
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
import { getAllAppGroupList, getAppList, removeApp } from '@/services/app';
|
import { getAllAppGroupList, getAppList, removeApp } from '@/services/app';
|
||||||
import { PlusOutlined, QuestionCircleOutlined, GroupOutlined } from '@ant-design/icons';
|
import { PlusOutlined, QuestionCircleOutlined } from '@ant-design/icons';
|
||||||
import type { ActionType } from '@ant-design/pro-components';
|
import type { ActionType } from '@ant-design/pro-components';
|
||||||
import { PageContainer, ProList } from '@ant-design/pro-components';
|
import { PageContainer, ProList } from '@ant-design/pro-components';
|
||||||
import { App, Avatar, Button, Popconfirm, Space, Tag } from 'antd';
|
import { App, Avatar, Button, Popconfirm, Space, Tag } from 'antd';
|
||||||
|
@ -92,15 +92,6 @@ export default () => {
|
||||||
<PlusOutlined />
|
<PlusOutlined />
|
||||||
{intl.formatMessage({ id: 'pages.app.list.tool_bar_render.add_app' })}
|
{intl.formatMessage({ id: 'pages.app.list.tool_bar_render.add_app' })}
|
||||||
</Button>,
|
</Button>,
|
||||||
<Button
|
|
||||||
key="app-group"
|
|
||||||
icon={<GroupOutlined />}
|
|
||||||
onClick={() => {
|
|
||||||
history.push('/app/group');
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
分组管理
|
|
||||||
</Button>,
|
|
||||||
]}
|
]}
|
||||||
metas={{
|
metas={{
|
||||||
title: {
|
title: {
|
||||||
|
@ -122,17 +113,17 @@ export default () => {
|
||||||
},
|
},
|
||||||
avatar: {
|
avatar: {
|
||||||
search: false,
|
search: false,
|
||||||
render: (text, row) => {
|
render: (_text, row) => {
|
||||||
return <Avatar key={row.id} shape="square" size={45} src={row.icon} />;
|
return <Avatar key={row.id} shape="square" size={45} src={row.icon} />;
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
description: { search: false, dataIndex: 'remark' },
|
description: { search: false, dataIndex: 'remark' },
|
||||||
content: {
|
content: {
|
||||||
search: false,
|
search: false,
|
||||||
render: (text, row) => [<ListContent key="context" {...row} />],
|
render: (_text, row) => [<ListContent key="context" {...row} />],
|
||||||
},
|
},
|
||||||
actions: {
|
actions: {
|
||||||
render: (text, row) => [
|
render: (_text, row) => [
|
||||||
row.enabled ? (
|
row.enabled ? (
|
||||||
<Popconfirm
|
<Popconfirm
|
||||||
title={intl.formatMessage({
|
title={intl.formatMessage({
|
||||||
|
|
Loading…
Reference in New Issue