完成页面的基础配置
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
"use client";
|
||||
|
||||
import { GitHubBanner, Refine, type AuthProvider } from "@refinedev/core";
|
||||
import { Refine, type AuthProvider } from "@refinedev/core";
|
||||
import { RefineKbar, RefineKbarProvider } from "@refinedev/kbar";
|
||||
import {
|
||||
RefineSnackbarProvider,
|
||||
@@ -15,6 +15,13 @@ import routerProvider from "@refinedev/nextjs-router";
|
||||
import { ColorModeContextProvider } from "@contexts/color-mode";
|
||||
import { dataProvider } from "@providers/data-provider";
|
||||
|
||||
import { LiaNetworkWiredSolid } from "react-icons/lia";
|
||||
import { TbDatabaseEdit } from "react-icons/tb";
|
||||
import { LuReplace } from "react-icons/lu";
|
||||
import { PiAsteriskDuotone } from "react-icons/pi";
|
||||
import { TbLocationPin } from "react-icons/tb";
|
||||
import { AiOutlinePartition } from "react-icons/ai";
|
||||
|
||||
type RefineContextProps = {
|
||||
defaultMode?: string;
|
||||
};
|
||||
@@ -105,7 +112,6 @@ const App = (props: React.PropsWithChildren<AppProps>) => {
|
||||
|
||||
return (
|
||||
<>
|
||||
<GitHubBanner />
|
||||
<RefineKbarProvider>
|
||||
<ColorModeContextProvider defaultMode={defaultMode}>
|
||||
<RefineSnackbarProvider>
|
||||
@@ -116,23 +122,51 @@ const App = (props: React.PropsWithChildren<AppProps>) => {
|
||||
authProvider={authProvider}
|
||||
resources={[
|
||||
{
|
||||
name: "blog_posts",
|
||||
list: "/blog-posts",
|
||||
create: "/blog-posts/create",
|
||||
edit: "/blog-posts/edit/:id",
|
||||
show: "/blog-posts/show/:id",
|
||||
name: "管网在线模拟",
|
||||
list: "/network-simulation",
|
||||
meta: {
|
||||
canDelete: true,
|
||||
icon: <LiaNetworkWiredSolid className="w-6 h-6" />,
|
||||
label: "管网在线模拟",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "categories",
|
||||
list: "/categories",
|
||||
create: "/categories/create",
|
||||
edit: "/categories/edit/:id",
|
||||
show: "/categories/show/:id",
|
||||
name: "SCADA 数据清洗",
|
||||
list: "/scada-data-cleaning",
|
||||
meta: {
|
||||
canDelete: true,
|
||||
icon: <TbDatabaseEdit className="w-6 h-6" />,
|
||||
label: "SCADA 数据清洗",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "监测点优化布置",
|
||||
list: "/monitoring-place-optimization",
|
||||
meta: {
|
||||
icon: <LuReplace className="w-6 h-6" />,
|
||||
label: "监测点优化布置",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "健康风险分析",
|
||||
list: "/health-risk-analysis",
|
||||
meta: {
|
||||
icon: <PiAsteriskDuotone className="w-6 h-6" />,
|
||||
label: "健康风险分析",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "爆管分析定位",
|
||||
list: "/burst-pipe-analysis",
|
||||
meta: {
|
||||
icon: <TbLocationPin className="w-6 h-6" />,
|
||||
label: "爆管分析定位",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "管网优化分区",
|
||||
list: "/network-partition-optimization",
|
||||
meta: {
|
||||
icon: <AiOutlinePartition className="w-6 h-6" />,
|
||||
label: "管网优化分区",
|
||||
},
|
||||
},
|
||||
]}
|
||||
|
||||
Reference in New Issue
Block a user