diff --git a/template/pages/#cms/pages.ejs b/template/pages/#cms/pages.ejs index eb57ce18..cc903647 100644 --- a/template/pages/#cms/pages.ejs +++ b/template/pages/#cms/pages.ejs @@ -1,5 +1,6 @@ <% const { slug, content } = await _.resolveRoute() +const isNotFound = !Object.keys(content).length _.breadcrumbs = [{ name: content.title, link: `/pages/${slug}` @@ -15,4 +16,35 @@ if (!content.sections || !content.sections.length) { } %> -<%- await include('@/view') %> +<% if (!isNotFound) { %> + <%- await include('@/view') %> +<% } else { %> + + + + <%- await include('@/head') %> + + + <%- await include('@/layout/menu') %> +
+ <%- await include('@/layout/header') %> +
+ +
+ <%- await include('@/layout/footer') %> +
+ <%- await include('@/json') %> + <%- await include('@/scripts') %> + + +<% } %> diff --git a/template/pages/#cms/posts.ejs b/template/pages/#cms/posts.ejs index 200f2020..6f3be6d5 100644 --- a/template/pages/#cms/posts.ejs +++ b/template/pages/#cms/posts.ejs @@ -1,6 +1,7 @@ <% const blogPage = _.cms('blog') const { slug, content } = await _.resolveRoute() +const isNotFound = !Object.keys(content).length _.breadcrumbs = [{ name: blogPage.title, link: `/blog` @@ -19,4 +20,35 @@ if (!content.sections || !content.sections.length) { } %> -<%- await include('@/view') %> +<% if (!isNotFound) { %> + <%- await include('@/view') %> +<% } else { %> + + + + <%- await include('@/head') %> + + + <%- await include('@/layout/menu') %> +
+ <%- await include('@/layout/header') %> +
+ +
+ <%- await include('@/layout/footer') %> +
+ <%- await include('@/json') %> + <%- await include('@/scripts') %> + + +<% } %>