Spaces:
Runtime error
Runtime error
Download TaskTrackingSystem.WebApp/Components/Pages/Features/Common/Error.razor from Yuruyuruu/task-tracking-system: direct link, hf CLI and curl.
- Browser
- Download file 1.5 kB
-
https://huggingface.co/spaces/Yuruyuruu/task-tracking-system/resolve/main/TaskTrackingSystem.WebApp/Components/Pages/Features/Common/Error.razor
- Command line
-
hf download hf://spaces/Yuruyuruu/task-tracking-system/TaskTrackingSystem.WebApp/Components/Pages/Features/Common/Error.razor
-
curl -L -o Error.razor https://huggingface.co/spaces/Yuruyuruu/task-tracking-system/resolve/main/TaskTrackingSystem.WebApp/Components/Pages/Features/Common/Error.razor
1.5 kB
| @page "/Error" | |
| @using System.Diagnostics | |
| <PageTitle>@AppLocalization.Text("error.title", "Error")</PageTitle> | |
| <h1 class="text-danger">@AppLocalization.Text("error.heading", "Error")</h1> | |
| <h2 class="text-danger">@AppLocalization.Text("error.processingRequest", "An error occurred while processing your request.")</h2> | |
| @if (ShowRequestId) | |
| { | |
| <p> | |
| <strong>@AppLocalization.Text("error.requestId", "Request ID"):</strong> <code>@RequestId</code> | |
| </p> | |
| } | |
| <h3>@AppLocalization.Text("error.developmentMode", "Development Mode")</h3> | |
| <p> | |
| @AppLocalization.Text("error.developmentDetails", "Switching to the Development environment will display more detailed information about the error that occurred.") | |
| </p> | |
| <p> | |
| <strong>@AppLocalization.Text("error.developmentWarning", "The Development environment should not be enabled for deployed applications.")</strong> | |
| @AppLocalization.Text("error.developmentSensitive", "It can expose sensitive exception details to end users.") | |
| @AppLocalization.Text("error.developmentInstructions", "For local debugging, set the ASPNETCORE_ENVIRONMENT environment variable to Development and restart the application.") | |
| </p> | |
| @code{ | |
| [CascadingParameter] | |
| private HttpContext? HttpContext { get; set; } | |
| private string? RequestId { get; set; } | |
| private bool ShowRequestId => !string.IsNullOrEmpty(RequestId); | |
| protected override void OnInitialized() => | |
| RequestId = Activity.Current?.Id ?? HttpContext?.TraceIdentifier; | |
| } | |