ExamEdit&Check
This commit is contained in:
@@ -1,18 +1,25 @@
|
||||
@using Entities.DTO
|
||||
|
||||
<MudPaper Width="@Width" Height="@Height" @onclick="ExamClick">
|
||||
<MudCard>
|
||||
<MudCardHeader>
|
||||
<MudText> @examDto.AssignmentTitle </MudText>
|
||||
</MudCardHeader>
|
||||
<MudPaper Class="overflow-hidden " Style="background-color:pink" Width="@Width" Height="@Height" MaxHeight="@MaxHeight" MaxWidth="@MaxWidth">
|
||||
<MudPaper Class="d-flex flex-column flex-grow-1 justify-content-between" Height="100%" Style="background-color:green">
|
||||
|
||||
<MudCardContent>
|
||||
<MudText> @examDto.Description </MudText>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
<MudText Typo="Typo.body2"> @examDto.AssignmentTitle </MudText>
|
||||
|
||||
|
||||
<MudPaper>
|
||||
|
||||
<MudButtonGroup Size="Size.Small" Color="Color.Primary" Variant="Variant.Filled">
|
||||
|
||||
<MudButton OnClick="ExamClick"> 详情 </MudButton>
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Delete" aria-label="delete" />
|
||||
<MudIconButton Icon="@Icons.Custom.Brands.GitHub" OnClick="CheckExam" Color="Color.Primary" aria-label="github" />
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Favorite" Color="Color.Secondary" aria-label="add to favorite" />
|
||||
</MudButtonGroup>
|
||||
</MudPaper>
|
||||
|
||||
</MudPaper>
|
||||
</MudPaper>
|
||||
|
||||
|
||||
@code {
|
||||
|
||||
[Inject]
|
||||
@@ -23,15 +30,28 @@
|
||||
|
||||
|
||||
[Parameter]
|
||||
public string? Width { get; set; } = "200";
|
||||
public string? Width { get; set; } = "256";
|
||||
|
||||
|
||||
[Parameter]
|
||||
public string? Height { get; set; } = "400";
|
||||
public string? Height { get; set; } = "64";
|
||||
|
||||
|
||||
[Parameter]
|
||||
public string? MaxWidth { get; set; } = "256";
|
||||
|
||||
|
||||
[Parameter]
|
||||
public string? MaxHeight { get; set; } = "64";
|
||||
|
||||
|
||||
private void ExamClick()
|
||||
{
|
||||
navigationManager.NavigateTo($"exam/Edit/{examDto.AssignmentId}");
|
||||
navigationManager.NavigateTo($"exam/edit/{examDto.AssignmentId}");
|
||||
}
|
||||
|
||||
private void CheckExam()
|
||||
{
|
||||
navigationManager.NavigateTo($"exam/check/{examDto.AssignmentId}");
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user