From f4d41a1090c2a346cac7dabcbb681636041d1f05 Mon Sep 17 00:00:00 2001 From: Berkan Sasmaz Date: Tue, 18 May 2021 16:50:11 +0300 Subject: [PATCH] Set the name of the GetTitle method in the CoverImageHelper class to GetContentOfImage --- src/EventHub.Web/Helpers/CoverImageHelper.cs | 7 ++++--- .../Events/Components/EventsArea/_eventListSection.cshtml | 2 +- src/EventHub.Web/Pages/Index.cshtml | 4 ++-- .../OrganizationsArea/_organizationListSection.cshtml | 2 +- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/EventHub.Web/Helpers/CoverImageHelper.cs b/src/EventHub.Web/Helpers/CoverImageHelper.cs index 3de86c7..b600439 100644 --- a/src/EventHub.Web/Helpers/CoverImageHelper.cs +++ b/src/EventHub.Web/Helpers/CoverImageHelper.cs @@ -1,5 +1,6 @@ using System; using System.Linq; +using System.Text; using Volo.Abp; namespace EventHub.Web.Helpers @@ -20,11 +21,11 @@ namespace EventHub.Web.Helpers return ImageColors[total % ImageColors.Length]; } - public static string GetTitle(string title) + public static string GetContentOfImage(string content) { - title = Check.NotNullOrWhiteSpace(title, nameof(title)); + content = Check.NotNullOrWhiteSpace(content, nameof(content)); - return title.ToUpper(); + return content.ToUpper(); } } } \ No newline at end of file diff --git a/src/EventHub.Web/Pages/Events/Components/EventsArea/_eventListSection.cshtml b/src/EventHub.Web/Pages/Events/Components/EventsArea/_eventListSection.cshtml index 1307ed5..3c4d801 100644 --- a/src/EventHub.Web/Pages/Events/Components/EventsArea/_eventListSection.cshtml +++ b/src/EventHub.Web/Pages/Events/Components/EventsArea/_eventListSection.cshtml @@ -10,7 +10,7 @@ @if (eventDto.CoverImageContent is null) {
- @CoverImageHelper.GetTitle(eventDto.Title).TruncateWithPostfix(40) + @CoverImageHelper.GetContentOfImage(eventDto.Title).TruncateWithPostfix(30)
} else diff --git a/src/EventHub.Web/Pages/Index.cshtml b/src/EventHub.Web/Pages/Index.cshtml index a2a6c63..833c110 100644 --- a/src/EventHub.Web/Pages/Index.cshtml +++ b/src/EventHub.Web/Pages/Index.cshtml @@ -122,7 +122,7 @@ @if (Model.OnlineEvents[i].CoverImageContent is null) { } else @@ -152,7 +152,7 @@ @if (Model.OnlineEvents[i + 1].CoverImageContent is null) { } else diff --git a/src/EventHub.Web/Pages/Organizations/Components/OrganizationsArea/_organizationListSection.cshtml b/src/EventHub.Web/Pages/Organizations/Components/OrganizationsArea/_organizationListSection.cshtml index e8d4bbf..0e85386 100644 --- a/src/EventHub.Web/Pages/Organizations/Components/OrganizationsArea/_organizationListSection.cshtml +++ b/src/EventHub.Web/Pages/Organizations/Components/OrganizationsArea/_organizationListSection.cshtml @@ -8,7 +8,7 @@ @if (organization.ProfilePictureContent == null) {
- @CoverImageHelper.GetTitle(organization.Name).TruncateWithPostfix(40) + @CoverImageHelper.GetContentOfImage(organization.Name).TruncateWithPostfix(40)
} else