Skip to content
This repository was archived by the owner on Sep 16, 2021. It is now read-only.

1.3 to master #774

Merged
merged 2 commits into from
Aug 20, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 19 additions & 3 deletions bundles/seo/seo_aware.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ the ``SeoMetadata``::
{
return $this->seoMetadata;
}

public function setSeoMetadata($metadata)
{
$this->seoMetadata = $metadata;
Expand Down Expand Up @@ -240,14 +240,30 @@ the ``SeoMetadata`` entity.
Form Type
---------

The bundle also provides a special form type called ``seo_metadata``. This
form type can be used in forms to edit the ``SeoMetadata`` object.
The bundle also provides a special form type called ``Symfony\Cmf\Bundle\SeoBundle\Form\Type\SeoMetadataType``
(use ``seo_metadata`` for Symfony versions older than 2.8). This form type can be
used in forms to edit the ``SeoMetadata`` object::

use Sonata\AdminBundle\Form\FormMapper;
use Symfony\Cmf\Bundle\SeoBundle\Form\Type\SeoMetadataType;

/** @var FormMapper $formMapper */
$formMapper
->add('seoMetadata', SeoMetadataType::class)
;

.. caution::

The form type requires the `BurgovKeyValueFormBundle`_ to be installed and
registered.

.. note::

If you use Doctrine ORM, you need the form option ``by_reference`` set to
``false``. If you enabled the ORM backend but not the PHPCR backend, this
option is set by default, otherwise you need to explicitly specify it in
your ORM forms.

Sonata Admin Integration
------------------------

Expand Down