重构作业结构:优化实体模型、DTO映射和前端界面
Some checks failed
TechAct / explore-gitea-actions (push) Failing after 13s
Some checks failed
TechAct / explore-gitea-actions (push) Failing after 13s
- 重构AppMainStruct、AssignmentQuestion、Question等实体模型 - 更新相关DTO以匹配新的数据结构 - 优化前端页面布局和组件 - 添加全局信息和笔记功能相关代码 - 更新数据库迁移和程序配置
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
@inherits ErrorBoundary
|
||||
@inject ISnackbar Snackbar
|
||||
|
||||
@if (CurrentException is null)
|
||||
{
|
||||
@ChildContent
|
||||
}
|
||||
else if (ErrorContent is not null)
|
||||
{
|
||||
@ErrorContent(CurrentException)
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="custom-error-ui">
|
||||
<MudAlert Severity="Severity.Error" Icon="@Icons.Material.Filled.Error">
|
||||
<MudText>组件加载或执行时出现了问题。</MudText>
|
||||
<MudButton Variant="Variant.Filled"
|
||||
Color="Color.Primary"
|
||||
Class="mt-3">
|
||||
重试
|
||||
</MudButton>
|
||||
</MudAlert>
|
||||
</div>
|
||||
}
|
||||
|
||||
|
||||
@code {
|
||||
protected override async Task OnErrorAsync(Exception exception)
|
||||
{
|
||||
Snackbar.Add("操作失败,请重试或联系管理员。", Severity.Error);
|
||||
|
||||
await base.OnErrorAsync(exception);
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user