Module ordering improvements

This commit is contained in:
Shaun Walker
2019-09-10 09:56:42 -04:00
parent f60898dbc7
commit 2a691dbceb
12 changed files with 229 additions and 152 deletions

View File

@ -9,20 +9,30 @@
@inject HttpClient http
@inject SiteState sitestate
<ModuleMessage Message="@message" />
@((MarkupString)content)
<br /><ActionLink Action="Edit" /><br /><br />
@code {
string message = "";
string content;
protected override async Task OnParametersSetAsync()
{
HtmlTextService htmltextservice = new HtmlTextService(http, sitestate, UriHelper);
HtmlTextInfo htmltext = await htmltextservice.GetHtmlTextAsync(ModuleState.ModuleId);
if (htmltext != null)
try
{
content = htmltext.Content;
HtmlTextService htmltextservice = new HtmlTextService(http, sitestate, UriHelper);
HtmlTextInfo htmltext = await htmltextservice.GetHtmlTextAsync(ModuleState.ModuleId);
if (htmltext != null)
{
content = htmltext.Content;
}
}
catch (Exception ex)
{
message = ex.Message;
}
}
}