Browse Source

Update Default.cshtml

pull/4961/head
Yunus Emre Kalkan 6 years ago
parent
commit
769ce3d82c
  1. 9
      modules/cms-kit/src/Volo.CmsKit.Public.Web/Pages/CmsKit/Shared/Components/Commenting/Default.cshtml

9
modules/cms-kit/src/Volo.CmsKit.Public.Web/Pages/CmsKit/Shared/Components/Commenting/Default.cshtml

@ -8,11 +8,12 @@
@model Volo.CmsKit.Web.Pages.CmsKit.Shared.Components.Commenting.CommentingViewComponent.CommentingViewModel @model Volo.CmsKit.Web.Pages.CmsKit.Shared.Components.Commenting.CommentingViewComponent.CommentingViewModel
@{ @{
Func<dynamic, IHtmlContent> GetCommentAuthorName(CmsUserDto author) => Func<dynamic, IHtmlContent> GetCommentTitle(CmsUserDto author, DateTime creationTime) =>
@<span> @<span>
@((string.IsNullOrWhiteSpace(author.Name) @((string.IsNullOrWhiteSpace(author.Name)
? author.UserName ? author.UserName
: author.Name + " " + author.Surname).Trim()) : author.Name + " " + author.Surname).Trim())
<small>@creationTime.ToString()</small>
</span>; </span>;
} }
@{ @{
@ -93,8 +94,7 @@
<div class="border-bottom"> <div class="border-bottom">
<h5> <h5>
<i class="fa fa-comment-o"></i> <i class="fa fa-comment-o"></i>
@GetCommentAuthorName(comment.Author).Invoke(null) @GetCommentTitle(comment.Author, comment.CreationTime).Invoke(null)
<small>@comment.CreationTime.ToString()</small>
</h5> </h5>
@GetCommentContentArea(comment.Id, comment.Author.Id, false, comment.Text).Invoke(null) @GetCommentContentArea(comment.Id, comment.Author.Id, false, comment.Text).Invoke(null)
@ -114,8 +114,7 @@
<h6> <h6>
<i class="fa fa-comment-o"></i> <i class="fa fa-comment-o"></i>
@GetCommentAuthorName(reply.Author).Invoke(null) @GetCommentTitle(reply.Author, reply.CreationTime).Invoke(null)
<small>@comment.CreationTime.ToString()</small>
</h6> </h6>
@GetCommentContentArea(reply.Id, reply.Author.Id, true, reply.Text).Invoke(null) @GetCommentContentArea(reply.Id, reply.Author.Id, true, reply.Text).Invoke(null)

Loading…
Cancel
Save