1
0
mirror of https://git.teknik.io/Teknikode/Teknik.git synced 2023-08-02 14:16:22 +02:00

Fixed comments showing the user as the blog post author.

This commit is contained in:
Uncled1023 2016-02-12 11:58:28 -08:00
parent 29635234e6
commit 6d33a4258b

View File

@ -7,8 +7,8 @@
<div class="col-sm-8 col-sm-offset-2">
<div class="post-comment">
<p class="post-comment-meta text-muted">
<a href="@Url.SubRouteUrl("profile", "Profile.Index", new { username = Model.Post.Blog.User.Username })">@Model.Post.Blog.User.Username</a> replied at <time datetime="@Model.DatePosted.ToString("o")">@Model.DatePosted.ToString("hh:mm:ss tt") on @Model.DatePosted.ToString("MMMM dd, yyyy")</time>
@if (Model.Post.Blog.User.Username == User.Identity.Name || User.IsInRole("Admin"))
<a href="@Url.SubRouteUrl("profile", "Profile.Index", new { username = Model.User.Username })">@Model.User.Username</a> replied at <time datetime="@Model.DatePosted.ToString("o")">@Model.DatePosted.ToString("hh:mm:ss tt") on @Model.DatePosted.ToString("MMMM dd, yyyy")</time>
@if (Model.User.Username == User.Identity.Name || User.IsInRole("Admin"))
{
<br />
<button type="button" class="btn btn-info edit_comment" id="@Model.CommentId" data-toggle="modal" data-target="#editComment">Edit</button>