BasicLayout.razor
3.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
@namespace DataAcquisition
@inherits LayoutComponentBase
<AntDesign.ProLayout.BasicLayout Logo="@("/favicon.ico")"
MenuData="_menuData">
<RightContentRender>
</RightContentRender>
<ChildContent>
@Body
</ChildContent>
<FooterRender>
<FooterView Copyright="2024 长沙华恒机器人系统有限公司" Links="Links"></FooterView>
</FooterRender>
</AntDesign.ProLayout.BasicLayout>
<SettingDrawer />
@code
{
private readonly MenuDataItem[] _menuData =
{
new MenuDataItem
{
Path = "/",
Name = "日志",
Key = "logPage",
Icon = "bell",
},
new MenuDataItem
{
Path = "/Basic",
Name = "基础数据",
Key = "basic",
Icon = "database",
Children = new MenuDataItem[]
{
new MenuDataItem
{
Path = "/Basic/Communication",
Name = "通讯配置",
Key = "Communication",
Icon = "api",
},
new MenuDataItem
{
Path = "/Basic/Equipment",
Name = "设备信息",
Key = "Equipment",
Icon = "mac-command",
},
// new MenuDataItem
// {
// Path = "/Basic/WorkpieceModel",
// Name = "工件型号配置",
// Key = "WorkpieceModel",
// Icon = "mac-command",
// },
}
},
new MenuDataItem
{
Path = "/DataAnalysis",
Name = "数据统计",
Key = "dataAnalysis",
Icon = "mac-command",
Children = new MenuDataItem[]
{
new MenuDataItem
{
Path = "/DataAnalysis/WorkpieceProduction",
Name = "加工记录",
Key = "WorkpieceProduction",
Icon = "mac-command"
},
new MenuDataItem
{
Path = "DataAnalysis/Report",
Name = "报表",
Key = "Report",
Icon = "schedule"
},
new MenuDataItem
{
Path = "DataAnalysis/EquipmentPropertyRecord",
Name = "状态日志",
Key = "equipmentPropertyRecord",
Icon = "schedule"
},
}
},
new MenuDataItem
{
Path = "/EquipmentDataQueuePage",
Name = "待推送数据",
Key = "EquipmentDataQueuePage",
Icon = "mac-command",
},
};
public LinkItem[] Links { get; set; } =
{
// new LinkItem
// {
// Key = "Ant Design Blazor",
// Title = "Ant Design Blazor",
// Href = "https://antblazor.com",
// BlankTarget = true,
// },
// new LinkItem
// {
// Key = "github",
// Title = (RenderFragment)(@<Icon Type="github" />),
// Href = "https://github.com/ant-design-blazor/ant-design-pro-blazor",
// BlankTarget = true,
// },
// new LinkItem
// {
// Key = "Blazor",
// Title = "Blazor",
// Href = "https://dotnet.microsoft.com/apps/aspnet/web-apps/blazor?WT.mc_id=DT-MVP-5003987",
// BlankTarget = true,
// }
};
}