11 lines
576 B
Plaintext
11 lines
576 B
Plaintext
@model HN.Application.LinkDto
|
|
|
|
<a asp-action="Show" asp-controller="Links" asp-route-id="@Model.Id">@Model.Url - created at @Model.CreatedAt.ToLocalTime() by @Model.CreatedByName (👍: @Model.UpVotes / 👎: @Model.DownVotes)</a>
|
|
|
|
@if(User.Identity.IsAuthenticated) {
|
|
<form asp-controller="Links" asp-action="Vote" asp-route-id="@Model.Id" asp-route-url="@Model.Url" method="post">
|
|
<input type="hidden" name="redirectTo" value="@Context.Request.Path" />
|
|
<input type="submit" name="type" value="up" />
|
|
<input type="submit" name="type" value="down" />
|
|
</form>
|
|
} |