cms icon indicating copy to clipboard operation
cms copied to clipboard

BUG:PreviewController.cs的fileContentBuilder 和contentBuilder错误导致单页模板的标签未解析

Open nhren opened this issue 8 years ago • 2 comments

var contentBuilder = new StringBuilder(TemplateManager.GetTemplateContent(siteInfo, templateInfo));

        if (templateInfo.TemplateType == TemplateType.FileTemplate)           //单页
        {
            var fileContentBuilder = new StringBuilder(TemplateManager.GetTemplateContent(siteInfo, templateInfo));
            Parser.Parse(pageInfo, contextInfo, contentBuilder, visualInfo.FilePath, true);
            return Response(fileContentBuilder.ToString(), siteInfo);
        }

第一句读到ContentBuilder 里了。单页判断又读了一次到fileContentBuilder 里。 Parser.Parse的是contentBuilder,却返回了未做Parse的fileContentBuilder 。。

望修正~~~

nhren avatar Jun 09 '18 13:06 nhren

好的,我们查一下代码

starlying avatar Jun 11 '18 05:06 starlying

已修改,感谢反馈

starlying avatar Jun 11 '18 06:06 starlying