bug fixes in modify page and other code improvements
This commit is contained in:
parent
106e0abd41
commit
8065c4aa53
@ -10,6 +10,8 @@
|
||||
|
||||
<p>@Html.Raw(Model.LastMessage)</p>
|
||||
|
||||
@if(Model.PageInformation != null)
|
||||
{
|
||||
<form method="post">
|
||||
<table style="width:100%" class="noborder">
|
||||
<tr>
|
||||
@ -173,3 +175,4 @@
|
||||
<td><a role="button" href="/Admin/PageDel/?url=@Model.PageInformation.FullUrl" class="actionlink">حذف صفحه</a></td>
|
||||
</tr>
|
||||
</table>
|
||||
}
|
||||
@ -122,8 +122,15 @@ namespace GanjooRazor.Areas.Admin.Pages
|
||||
if (await GanjoorSessionChecker.PrepareClient(secureClient, Request, Response))
|
||||
{
|
||||
var putResponse = await secureClient.PutAsync($"{APIRoot.Url}/api/ganjoor/page/{Request.Query["id"]}", new StringContent(JsonConvert.SerializeObject(ModifyModel), Encoding.UTF8, "application/json"));
|
||||
putResponse.EnsureSuccessStatusCode();
|
||||
return Redirect($"/Admin/ModifyPage?id={Request.Query["id"]}&edit=true");
|
||||
if(!putResponse.IsSuccessStatusCode)
|
||||
{
|
||||
LastMessage = JsonConvert.DeserializeObject<string>(await putResponse.Content.ReadAsStringAsync());
|
||||
}
|
||||
else
|
||||
{
|
||||
putResponse.EnsureSuccessStatusCode();
|
||||
return Redirect($"/Admin/ModifyPage?id={Request.Query["id"]}&edit=true");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -821,6 +821,7 @@ namespace RMuseum.Services.Implementation
|
||||
{
|
||||
int idxbn1 = poemtext.IndexOf(" id=\"bn");
|
||||
int idxbn2 = poemtext.IndexOf("\"", idxbn1 + " id=\"bn".Length);
|
||||
|
||||
poemtext = poemtext.Substring(0, idxbn1) + poemtext.Substring(idxbn2+1);
|
||||
}
|
||||
|
||||
@ -828,7 +829,7 @@ namespace RMuseum.Services.Implementation
|
||||
poemtext = poemtext.Replace("Adaptation du milieu", "یییییییییییییییییییی");
|
||||
poemtext = poemtext.Replace("Empirique", "ببببببببب");
|
||||
|
||||
|
||||
poemtext = poemtext.Replace(" >", ">");
|
||||
poemtext = poemtext.Replace("<div class=\"b\" style=\"width:750px\">", "<div class=\"b\">").Replace("<div class=\"b\" style=\"width:660px\">", "<div class=\"b\">").Replace("<div class=\"b\" style=\"width:680px\">", "<div class=\"b\">").Replace("<div class=\"b\" style=\"width:650px\">", "<div class=\"b\">").Replace("<div class=\"b\" style=\"width:690px\">", "<div class=\"b\">").Replace("<p style=\"color:#911\">", "<p>").Replace("<p style=\"color:#191\">", "<p>").Replace("<div class=\"spacer\">", "").Replace(" ", "").Replace("<div class=\"spacer\" />", "").Replace("<div class=\"b\" style=\"width:700px\">", "<div class=\"b\">");
|
||||
poemtext = poemtext.Replace("<em>", "").Replace("</em>", "");
|
||||
poemtext = poemtext.Replace("<em>", "").Replace("</em>", "").Replace("<small>", "").Replace("</small>", "");
|
||||
|
||||
@ -853,7 +853,7 @@ namespace RMuseum.Services.Implementation
|
||||
coupletIndex++;
|
||||
if (((vIndex + 1) < verses.Count) && (verses[vIndex + 1].VersePosition == VersePosition.CenteredVerse2))
|
||||
{
|
||||
htmlText += $"<div class=\"b2\" id=\"bn{coupletIndex}\" ><p>{v.Text}</p>{Environment.NewLine}";
|
||||
htmlText += $"<div class=\"b2\" id=\"bn{coupletIndex}\"><p>{v.Text}</p>{Environment.NewLine}";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -2758,242 +2758,240 @@ namespace RMuseum.Services.Implementation
|
||||
/// <returns></returns>
|
||||
public async Task<RServiceResult<GanjoorPageCompleteViewModel>> UpdatePageAsync(int id, Guid editingUserId, GanjoorModifyPageViewModel pageData)
|
||||
{
|
||||
var dbPage = await _context.GanjoorPages.Where(p => p.Id == id).SingleOrDefaultAsync();
|
||||
if (dbPage == null)
|
||||
return new RServiceResult<GanjoorPageCompleteViewModel>(null);//not found
|
||||
|
||||
|
||||
|
||||
GanjoorPageSnapshot snapshot = new GanjoorPageSnapshot()
|
||||
{
|
||||
GanjoorPageId = id,
|
||||
MadeObsoleteByUserId = editingUserId,
|
||||
RecordDate = DateTime.Now,
|
||||
Note = pageData.Note,
|
||||
Title = dbPage.Title,
|
||||
UrlSlug = dbPage.UrlSlug,
|
||||
HtmlText = dbPage.HtmlText,
|
||||
};
|
||||
|
||||
GanjoorPoem dbPoem = null;
|
||||
|
||||
if (dbPage.GanjoorPageType == GanjoorPageType.PoemPage)
|
||||
{
|
||||
dbPoem = await _context.GanjoorPoems.Include(p => p.GanjoorMetre).Where(p => p.Id == id).SingleOrDefaultAsync();
|
||||
|
||||
snapshot.SourceName = dbPoem.SourceName;
|
||||
snapshot.SourceUrlSlug = dbPoem.SourceUrlSlug;
|
||||
snapshot.Rhythm = dbPoem.GanjoorMetre == null ? null : dbPoem.GanjoorMetre.Rhythm;
|
||||
snapshot.RhymeLetters = dbPoem.RhymeLetters;
|
||||
snapshot.OldTag = dbPoem.OldTag;
|
||||
snapshot.OldTagPageUrl = dbPoem.OldTagPageUrl;
|
||||
}
|
||||
|
||||
_context.GanjoorPageSnapshots.Add(snapshot);
|
||||
await _context.SaveChangesAsync();
|
||||
|
||||
dbPage.HtmlText = pageData.HtmlText;
|
||||
bool messWithTitles = dbPage.Title != pageData.Title;
|
||||
bool messWithUrls = dbPage.UrlSlug != pageData.UrlSlug;
|
||||
|
||||
if (messWithTitles || messWithUrls)
|
||||
{
|
||||
|
||||
dbPage.Title = pageData.Title;
|
||||
dbPage.UrlSlug = pageData.UrlSlug;
|
||||
|
||||
if (dbPage.ParentId != null)
|
||||
{
|
||||
GanjoorPage parent = await _context.GanjoorPages.AsNoTracking().Where(p => p.Id == dbPage.ParentId).SingleAsync();
|
||||
if (messWithUrls)
|
||||
{
|
||||
dbPage.FullUrl = parent.FullUrl + "/" + pageData.UrlSlug;
|
||||
}
|
||||
if (messWithTitles)
|
||||
{
|
||||
dbPage.FullTitle = parent.FullTitle + " » " + pageData.Title;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (messWithUrls)
|
||||
{
|
||||
dbPage.FullUrl = "/" + pageData.UrlSlug;
|
||||
}
|
||||
|
||||
if (messWithTitles)
|
||||
{
|
||||
dbPage.FullTitle = pageData.Title;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
switch (dbPage.GanjoorPageType)
|
||||
{
|
||||
case GanjoorPageType.CatPage:
|
||||
{
|
||||
GanjoorCat cat = await _context.GanjoorCategories.Where(c => c.Id == dbPage.CatId).SingleAsync();
|
||||
if (messWithTitles)
|
||||
cat.Title = dbPage.Title;
|
||||
if (messWithUrls)
|
||||
{
|
||||
cat.UrlSlug = dbPage.UrlSlug;
|
||||
cat.FullUrl = dbPage.FullUrl;
|
||||
}
|
||||
|
||||
_context.GanjoorCategories.Update(cat);
|
||||
await _context.SaveChangesAsync();
|
||||
}
|
||||
break;
|
||||
}
|
||||
_backgroundTaskQueue.QueueBackgroundWorkItem
|
||||
(
|
||||
async token =>
|
||||
{
|
||||
using (RMuseumDbContext context = new RMuseumDbContext(new DbContextOptions<RMuseumDbContext>())) //this is long running job, so _context might be already been freed/collected by GC
|
||||
{
|
||||
LongRunningJobProgressServiceEF jobProgressServiceEF = new LongRunningJobProgressServiceEF(context);
|
||||
var job = (await jobProgressServiceEF.NewJob($"Updating PageChildren for {dbPage.Id}", "Updating")).Result;
|
||||
try
|
||||
{
|
||||
|
||||
|
||||
await _UpdatePageChildrenTitleAndUrl(context, dbPage, messWithTitles, messWithUrls);
|
||||
|
||||
await jobProgressServiceEF.UpdateJob(job.Id, 100, "", true);
|
||||
}
|
||||
catch (Exception expUpdateBatch)
|
||||
{
|
||||
await jobProgressServiceEF.UpdateJob(job.Id, 100, "", false, expUpdateBatch.ToString());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
if (dbPage.GanjoorPageType == GanjoorPageType.PoetPage && (messWithTitles || messWithUrls))
|
||||
{
|
||||
if (messWithTitles)
|
||||
{
|
||||
GanjoorPoet poet = await _context.GanjoorPoets.Where(p => p.Id == dbPage.PoetId).SingleAsync();
|
||||
poet.Nickname = dbPage.Title;
|
||||
//poet.Description = dbPage.HtmlText; -- description might become html free
|
||||
_context.GanjoorPoets.Update(poet);
|
||||
}
|
||||
|
||||
|
||||
GanjoorCat cat = await _context.GanjoorCategories.Where(c => c.Id == dbPage.CatId).SingleAsync();
|
||||
if (messWithTitles)
|
||||
{
|
||||
cat.Title = dbPage.Title;
|
||||
}
|
||||
if (messWithUrls)
|
||||
{
|
||||
cat.UrlSlug = dbPage.UrlSlug;
|
||||
cat.FullUrl = dbPage.FullUrl;
|
||||
}
|
||||
|
||||
|
||||
_context.GanjoorCategories.Update(cat);
|
||||
|
||||
await _context.SaveChangesAsync();
|
||||
|
||||
CleanPoetCache((int)dbPage.PoetId);
|
||||
}
|
||||
|
||||
_context.GanjoorPages.Update(dbPage);
|
||||
|
||||
if (dbPoem != null)
|
||||
{
|
||||
dbPoem.SourceName = pageData.SourceName;
|
||||
dbPoem.SourceUrlSlug = pageData.SourceUrlSlug;
|
||||
if (string.IsNullOrEmpty(pageData.Rhythm))
|
||||
{
|
||||
dbPoem.GanjoorMetreId = null;
|
||||
}
|
||||
else
|
||||
{
|
||||
var metre = await _context.GanjoorMetres.Where(m => m.Rhythm == pageData.Rhythm).SingleOrDefaultAsync();
|
||||
if (metre == null)
|
||||
{
|
||||
metre = new GanjoorMetre()
|
||||
{
|
||||
Rhythm = pageData.Rhythm,
|
||||
VerseCount = 0
|
||||
};
|
||||
_context.GanjoorMetres.Add(metre);
|
||||
await _context.SaveChangesAsync();
|
||||
}
|
||||
dbPoem.GanjoorMetreId = metre.Id;
|
||||
}
|
||||
dbPoem.RhymeLetters = pageData.RhymeLetters;
|
||||
dbPoem.OldTag = pageData.OldTag;
|
||||
dbPoem.OldTagPageUrl = pageData.OldTagPageUrl;
|
||||
|
||||
dbPoem.HtmlText = pageData.HtmlText;
|
||||
dbPoem.Title = pageData.Title;
|
||||
dbPoem.UrlSlug = pageData.UrlSlug;
|
||||
dbPoem.FullUrl = dbPage.FullUrl;
|
||||
dbPoem.FullTitle = dbPoem.FullTitle;
|
||||
|
||||
List<GanjoorVerse> verses = _extractVersesFromPoemHtmlText(id, pageData.HtmlText);
|
||||
|
||||
dbPoem.PlainText = PreparePlainText(verses);
|
||||
|
||||
_context.GanjoorPoems.Update(dbPoem);
|
||||
|
||||
|
||||
var oldVerses = await _context.GanjoorVerses.Where(v => v.PoemId == id).ToListAsync();
|
||||
|
||||
if (oldVerses.Count <= verses.Count)
|
||||
{
|
||||
for (int v = 0; v < oldVerses.Count; v++)
|
||||
{
|
||||
oldVerses[v].Text = verses[v].Text;
|
||||
oldVerses[v].VersePosition = verses[v].VersePosition;
|
||||
oldVerses[v].VOrder = verses[v].VOrder;
|
||||
_context.GanjoorVerses.Update(oldVerses[v]);
|
||||
}
|
||||
|
||||
for (int v = oldVerses.Count; v < verses.Count; v++)
|
||||
{
|
||||
_context.GanjoorVerses.Add(verses[v]);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int v = 0; v < verses.Count; v++)
|
||||
{
|
||||
oldVerses[v].Text = verses[v].Text;
|
||||
oldVerses[v].VersePosition = verses[v].VersePosition;
|
||||
oldVerses[v].VOrder = verses[v].VOrder;
|
||||
_context.GanjoorVerses.Update(oldVerses[v]);
|
||||
}
|
||||
|
||||
for (int v = verses.Count; v < oldVerses.Count; v++)
|
||||
{
|
||||
_context.GanjoorVerses.Remove(oldVerses[v]);
|
||||
}
|
||||
}
|
||||
|
||||
await _FillPoemCoupletIndices(_context, id);
|
||||
}
|
||||
try
|
||||
{
|
||||
var dbPage = await _context.GanjoorPages.Where(p => p.Id == id).SingleOrDefaultAsync();
|
||||
if (dbPage == null)
|
||||
return new RServiceResult<GanjoorPageCompleteViewModel>(null);//not found
|
||||
|
||||
|
||||
|
||||
GanjoorPageSnapshot snapshot = new GanjoorPageSnapshot()
|
||||
{
|
||||
GanjoorPageId = id,
|
||||
MadeObsoleteByUserId = editingUserId,
|
||||
RecordDate = DateTime.Now,
|
||||
Note = pageData.Note,
|
||||
Title = dbPage.Title,
|
||||
UrlSlug = dbPage.UrlSlug,
|
||||
HtmlText = dbPage.HtmlText,
|
||||
};
|
||||
|
||||
GanjoorPoem dbPoem = null;
|
||||
|
||||
if (dbPage.GanjoorPageType == GanjoorPageType.PoemPage)
|
||||
{
|
||||
dbPoem = await _context.GanjoorPoems.Include(p => p.GanjoorMetre).Where(p => p.Id == id).SingleOrDefaultAsync();
|
||||
|
||||
snapshot.SourceName = dbPoem.SourceName;
|
||||
snapshot.SourceUrlSlug = dbPoem.SourceUrlSlug;
|
||||
snapshot.Rhythm = dbPoem.GanjoorMetre == null ? null : dbPoem.GanjoorMetre.Rhythm;
|
||||
snapshot.RhymeLetters = dbPoem.RhymeLetters;
|
||||
snapshot.OldTag = dbPoem.OldTag;
|
||||
snapshot.OldTagPageUrl = dbPoem.OldTagPageUrl;
|
||||
}
|
||||
|
||||
_context.GanjoorPageSnapshots.Add(snapshot);
|
||||
await _context.SaveChangesAsync();
|
||||
|
||||
dbPage.HtmlText = pageData.HtmlText;
|
||||
bool messWithTitles = dbPage.Title != pageData.Title;
|
||||
bool messWithUrls = dbPage.UrlSlug != pageData.UrlSlug;
|
||||
|
||||
if (messWithTitles || messWithUrls)
|
||||
{
|
||||
|
||||
dbPage.Title = pageData.Title;
|
||||
dbPage.UrlSlug = pageData.UrlSlug;
|
||||
|
||||
if (dbPage.ParentId != null)
|
||||
{
|
||||
GanjoorPage parent = await _context.GanjoorPages.AsNoTracking().Where(p => p.Id == dbPage.ParentId).SingleAsync();
|
||||
if (messWithUrls)
|
||||
{
|
||||
dbPage.FullUrl = parent.FullUrl + "/" + pageData.UrlSlug;
|
||||
}
|
||||
if (messWithTitles)
|
||||
{
|
||||
dbPage.FullTitle = parent.FullTitle + " » " + pageData.Title;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (messWithUrls)
|
||||
{
|
||||
dbPage.FullUrl = "/" + pageData.UrlSlug;
|
||||
}
|
||||
|
||||
if (messWithTitles)
|
||||
{
|
||||
dbPage.FullTitle = pageData.Title;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
switch (dbPage.GanjoorPageType)
|
||||
{
|
||||
case GanjoorPageType.CatPage:
|
||||
{
|
||||
GanjoorCat cat = await _context.GanjoorCategories.Where(c => c.Id == dbPage.CatId).SingleAsync();
|
||||
if (messWithTitles)
|
||||
cat.Title = dbPage.Title;
|
||||
if (messWithUrls)
|
||||
{
|
||||
cat.UrlSlug = dbPage.UrlSlug;
|
||||
cat.FullUrl = dbPage.FullUrl;
|
||||
}
|
||||
|
||||
_context.GanjoorCategories.Update(cat);
|
||||
await _context.SaveChangesAsync();
|
||||
}
|
||||
break;
|
||||
}
|
||||
_backgroundTaskQueue.QueueBackgroundWorkItem
|
||||
(
|
||||
async token =>
|
||||
{
|
||||
using (RMuseumDbContext context = new RMuseumDbContext(new DbContextOptions<RMuseumDbContext>())) //this is long running job, so _context might be already been freed/collected by GC
|
||||
{
|
||||
LongRunningJobProgressServiceEF jobProgressServiceEF = new LongRunningJobProgressServiceEF(context);
|
||||
var job = (await jobProgressServiceEF.NewJob($"Updating PageChildren for {dbPage.Id}", "Updating")).Result;
|
||||
try
|
||||
{
|
||||
|
||||
|
||||
await _UpdatePageChildrenTitleAndUrl(context, dbPage, messWithTitles, messWithUrls);
|
||||
|
||||
await jobProgressServiceEF.UpdateJob(job.Id, 100, "", true);
|
||||
}
|
||||
catch (Exception expUpdateBatch)
|
||||
{
|
||||
await jobProgressServiceEF.UpdateJob(job.Id, 100, "", false, expUpdateBatch.ToString());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
if (dbPage.GanjoorPageType == GanjoorPageType.PoetPage && (messWithTitles || messWithUrls))
|
||||
{
|
||||
if (messWithTitles)
|
||||
{
|
||||
GanjoorPoet poet = await _context.GanjoorPoets.Where(p => p.Id == dbPage.PoetId).SingleAsync();
|
||||
poet.Nickname = dbPage.Title;
|
||||
//poet.Description = dbPage.HtmlText; -- description might become html free
|
||||
_context.GanjoorPoets.Update(poet);
|
||||
}
|
||||
|
||||
|
||||
GanjoorCat cat = await _context.GanjoorCategories.Where(c => c.Id == dbPage.CatId).SingleAsync();
|
||||
if (messWithTitles)
|
||||
{
|
||||
cat.Title = dbPage.Title;
|
||||
}
|
||||
if (messWithUrls)
|
||||
{
|
||||
cat.UrlSlug = dbPage.UrlSlug;
|
||||
cat.FullUrl = dbPage.FullUrl;
|
||||
}
|
||||
|
||||
|
||||
_context.GanjoorCategories.Update(cat);
|
||||
|
||||
await _context.SaveChangesAsync();
|
||||
|
||||
CleanPoetCache((int)dbPage.PoetId);
|
||||
}
|
||||
|
||||
_context.GanjoorPages.Update(dbPage);
|
||||
|
||||
if (dbPoem != null)
|
||||
{
|
||||
dbPoem.SourceName = pageData.SourceName;
|
||||
dbPoem.SourceUrlSlug = pageData.SourceUrlSlug;
|
||||
if (string.IsNullOrEmpty(pageData.Rhythm))
|
||||
{
|
||||
dbPoem.GanjoorMetreId = null;
|
||||
}
|
||||
else
|
||||
{
|
||||
var metre = await _context.GanjoorMetres.Where(m => m.Rhythm == pageData.Rhythm).SingleOrDefaultAsync();
|
||||
if (metre == null)
|
||||
{
|
||||
metre = new GanjoorMetre()
|
||||
{
|
||||
Rhythm = pageData.Rhythm,
|
||||
VerseCount = 0
|
||||
};
|
||||
_context.GanjoorMetres.Add(metre);
|
||||
await _context.SaveChangesAsync();
|
||||
}
|
||||
dbPoem.GanjoorMetreId = metre.Id;
|
||||
}
|
||||
dbPoem.RhymeLetters = pageData.RhymeLetters;
|
||||
dbPoem.OldTag = pageData.OldTag;
|
||||
dbPoem.OldTagPageUrl = pageData.OldTagPageUrl;
|
||||
|
||||
dbPoem.HtmlText = pageData.HtmlText;
|
||||
dbPoem.Title = pageData.Title;
|
||||
dbPoem.UrlSlug = pageData.UrlSlug;
|
||||
dbPoem.FullUrl = dbPage.FullUrl;
|
||||
dbPoem.FullTitle = dbPoem.FullTitle;
|
||||
|
||||
List<GanjoorVerse> verses = _extractVersesFromPoemHtmlText(id, pageData.HtmlText);
|
||||
|
||||
dbPoem.PlainText = PreparePlainText(verses);
|
||||
|
||||
_context.GanjoorPoems.Update(dbPoem);
|
||||
|
||||
|
||||
var oldVerses = await _context.GanjoorVerses.Where(v => v.PoemId == id).ToListAsync();
|
||||
|
||||
if (oldVerses.Count <= verses.Count)
|
||||
{
|
||||
for (int v = 0; v < oldVerses.Count; v++)
|
||||
{
|
||||
oldVerses[v].Text = verses[v].Text;
|
||||
oldVerses[v].VersePosition = verses[v].VersePosition;
|
||||
oldVerses[v].VOrder = verses[v].VOrder;
|
||||
_context.GanjoorVerses.Update(oldVerses[v]);
|
||||
}
|
||||
|
||||
for (int v = oldVerses.Count; v < verses.Count; v++)
|
||||
{
|
||||
_context.GanjoorVerses.Add(verses[v]);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int v = 0; v < verses.Count; v++)
|
||||
{
|
||||
oldVerses[v].Text = verses[v].Text;
|
||||
oldVerses[v].VersePosition = verses[v].VersePosition;
|
||||
oldVerses[v].VOrder = verses[v].VOrder;
|
||||
_context.GanjoorVerses.Update(oldVerses[v]);
|
||||
}
|
||||
|
||||
for (int v = verses.Count; v < oldVerses.Count; v++)
|
||||
{
|
||||
_context.GanjoorVerses.Remove(oldVerses[v]);
|
||||
}
|
||||
}
|
||||
|
||||
await _FillPoemCoupletIndices(_context, id);
|
||||
}
|
||||
await _context.SaveChangesAsync();
|
||||
CacheCleanForPageByUrl(dbPage.FullUrl);
|
||||
|
||||
|
||||
return await GetPageByUrl(dbPage.FullUrl);
|
||||
}
|
||||
catch (Exception exp)
|
||||
{
|
||||
return new RServiceResult<GanjoorPageCompleteViewModel>(null, exp.ToString());
|
||||
}
|
||||
|
||||
|
||||
CacheCleanForPageByUrl(dbPage.FullUrl);
|
||||
|
||||
|
||||
return await GetPageByUrl(dbPage.FullUrl);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@ -75,7 +75,7 @@ namespace RMuseum.Services.Implementation
|
||||
;
|
||||
}
|
||||
|
||||
public static string PrepareTextForFindingRhyme(string text)
|
||||
private static string PrepareTextForFindingRhyme(string text)
|
||||
{
|
||||
return MakeTextSearchable(text)
|
||||
.Replace("لله", "للاه")
|
||||
@ -84,9 +84,7 @@ namespace RMuseum.Services.Implementation
|
||||
.Replace("", "")
|
||||
.Replace("", "")
|
||||
.Replace(" ", "")
|
||||
.Trim()
|
||||
;
|
||||
;
|
||||
.Trim();
|
||||
}
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user