You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
952 B
38 lines
952 B
using HeartTrack.Models;
|
|
using HeartTrack.Services;
|
|
using Microsoft.AspNetCore.Components;
|
|
|
|
namespace HeartTrack.Pages
|
|
{
|
|
public partial class ViewTicket
|
|
{
|
|
[Parameter]
|
|
public int Id { get; set; }
|
|
|
|
private Ticket ticket { get; set; } = new();
|
|
|
|
[Inject]
|
|
public IDataService DataService { get; set; }
|
|
|
|
[Inject]
|
|
public NavigationManager NavigationManager { get; set; }
|
|
|
|
[Inject]
|
|
public IWebHostEnvironment WebHostEnvironment { get; set; }
|
|
|
|
protected async Task OnInitializedAsync()
|
|
{
|
|
var item = await DataService.GetByID(Id);
|
|
|
|
ticket = new Ticket
|
|
{
|
|
Id = item.Id,
|
|
Username = item.Username,
|
|
Contexte = item.Contexte,
|
|
Description = item.Description,
|
|
Urgence = item.Urgence,
|
|
isCheck = item.isCheck
|
|
};
|
|
}
|
|
}
|
|
} |