shinoka7 6 лет назад
Родитель
Сommit
eba839c46e
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/server/views/modal/create_page.html

+ 1 - 1
src/server/views/modal/create_page.html

@@ -72,7 +72,7 @@
             // modify href
             const value = $(this).val();
             const pageName = (value === 'children') ? '_template' : '__template';
-            const truePath = "{{ page.path || path | addTrailingSlash }}";
+            const truePath = "{% if page.path || path %}{{ page.path || path | addTrailingSlash }}{% else %}{{ page.path || path }}{% endif %}"
             const link = truePath + pageName + '#edit-form';
             $('#link-to-template').attr('href', link);
           });