mirror of https://github.com/abpframework/abp.git
csharpabpc-sharpframeworkblazoraspnet-coredotnet-coreaspnetcorearchitecturesaasdomain-driven-designangularmulti-tenancy
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
1.2 KiB
38 lines
1.2 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using Scriban;
|
|
using Microsoft.Extensions.Logging;
|
|
using Microsoft.Extensions.Logging.Abstractions;
|
|
using Volo.Abp;
|
|
using Volo.Abp.ObjectMapping;
|
|
using Volo.Docs.Documents.Rendering;
|
|
using Volo.Extensions;
|
|
|
|
namespace Volo.Docs.HtmlConverting
|
|
{
|
|
public class ScribanWebDocumentSectionRenderer : ScribanDocumentSectionRenderer, IWebDocumentSectionRenderer
|
|
{
|
|
private IObjectMapper ObjectMapper { get; set; }
|
|
|
|
public Task<DocumentNavigationsDto> GetDocumentNavigationsAsync(string documentContent)
|
|
{
|
|
return GetSectionAsync<DocumentNavigationsDto>(documentContent, DocsNav);
|
|
}
|
|
|
|
public async Task<List<DocumentPartialTemplateWithValues>> GetPartialTemplatesInDocumentAsync(
|
|
string documentContent)
|
|
{
|
|
var templates = new List<DocumentPartialTemplateWithValues>();
|
|
|
|
foreach (var section in DocsJsonSections)
|
|
{
|
|
templates.AddRange(await section.GetPartialTemplatesInDocumentAsync(documentContent));
|
|
}
|
|
|
|
return templates;
|
|
}
|
|
}
|
|
}
|