浏览代码

Updated preview_mode.rst

Updated doc with `base_edit_form_macro` import (from issue #2421) and class name `sonata-preview-form-container`.
plehatron 10 年之前
父节点
当前提交
b6a29acf6a
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      Resources/doc/reference/preview_mode.rst

+ 3 - 1
Resources/doc/reference/preview_mode.rst

@@ -90,12 +90,14 @@ a different object you can just set your own variables prior to calling parent()
 
     {% use 'SonataAdminBundle:CRUD:base_edit_form.html.twig' with form as parentForm %}
 
+    {% import 'SonataAdminBundle:CRUD:base_edit_form_macro.html.twig' as form_helper %}
+
     {% block templateContent %}     {# a block in 'AcmeDemoBundle::layout.html.twig' expecting article #}
         {% set article = object %}
 
         {{ parent() }}
 
-        <div class="sonata-preview-form">
+        <div class="sonata-preview-form-container">
             {{ block('parentForm') }}
         </div>