Ibexa DXP の便利な各種バンドルの紹介

## Netgen Tags Bundle
https://github.com/netgen/TagsBundle/
Ibexa Open Source では Taxonomy が利用できないため、Netgen 社によるサードパーティーのバンドルをインストールすることで対応できる。

### インストール
```shell
composer require netgen/tagsbundle
```
```yaml:config/routes/netgen_tags.yaml
netgen_tags:
    resource: "@NetgenTagsBundle/Resources/config/routing.yaml"
```
```shell
mysql -u<user> -p <db_name> < vendor/netgen/tagsbundle/bundle/Resources/sql/mysql/schema.sql
```

## Codein IbexaColorPicker
https://github.com/Codein-Labs/ibexa-color-picker

### インストール
```shell
composer require codein/ibexa-color-picker
```

## Ibexa RichText Validation Errors
https://gitlab.com/contextualcode/ibexa-richtext-validation-errors
このバンドルは、 RichText の検証エラーに関する詳細情報を提供します。
eZ Platform AlloyEditor Source (contextualcode/ezplatform-alloyeditor-source) バンドルを併せて利用することが推奨されます。

![](https://gitlab.com/contextualcode/ibexa-richtext-validation-errors/raw/master/doc/images/old-common-error.png)
![](https://gitlab.com/contextualcode/ibexa-richtext-validation-errors/raw/master/doc/images/new-detailed-error.png)

### インストール
```shell
composer require contextualcode/ibexa-richtext-validation-errors
```


## eZ Platform AlloyEditor Source
https://gitlab.com/contextualcode/ezplatform-alloyeditor-source

### インストール
```shell
composer require contextualcode/ezplatform-alloyeditor-source
```


## Codein SEO Toolkit
https://github.com/Codein-Labs/ibexa-seo-toolkit

### インストール
```shell
composer require codein/ibexa-seo-toolkit --no-scripts
```
```php:config/bundles.php
return [
    //...
    Codein\IbexaSeoToolkit\IbexaSeoToolkitBundle::class => ['all' => true],
];
```
```yaml:config/routes.yaml
api_codein_ibexa_seo:
    resource: .
    type: api_codein_ibexa_seo
```
```yaml:config/packages/codein_ibexa_seo_toolkit.yaml
codein_ibexa_seo_toolkit:
    system:
        default:
            metas:
                default_metas:
```
```shell
composer composer run-script post-install-cmd
php bin/console doctrine:schema:update --force
php bin/console bazinga:js-translation:dump public/assets --merge-domains
yarn encore dev
```


## Novactive eZ SEO Bundle
https://github.com/Novactive/NovaeZSEOBundle

### インストール
```shell
composer require novactive/ezseobundle
```
```php:config/bundles.php
return [
    // ...
    Novactive\Bundle\eZSEOBundle\NovaeZSEOBundle::class => [ 'all'=> true ],
];
```
```yaml:config/routes.yaml
_novaezseo_routes:
    resource: '@NovaeZSEOBundle/Resources/config/routing/main.yaml'
```
```shell
php bin/console ibexa:graphql:generate-schema
```


## Elbformat Field Helper Bundle for ibexa DXP
https://github.com/elbformat/field-helper-bundle

### インストール
```shell
composer require elbformat/field-helper-bundle
```
```php:config/bundles.php
return [
    // ...
    Elbformat\FieldHelperBundle\ElbformatFieldHelperBundle::class => ['all' => true],
];
```
### 使用方法
```php
public function getFields(RegistryInterface $fieldHelperRegistry, Content $content) {
    $myText = $fieldHelperRegistry->getTextFieldHelper()->getString($content, 'text_field');
    $linkObject = $fieldHelperRegistry->getLinkFieldHelper()->getLink($content, 'my_url');
    $linkUrl = $linkObj->getUrl();
    $linkText = $linkObj->getText();
}
```


## Novactive eZ Slack Bundle
Ibexa DXP と Slack の統合を提供するバンドルです。
Ibexa の管理画面の操作を Slack に通知したり、逆に Slack から Ibexa のコンテンツを操作したりすることができるようになります。
https://github.com/Novactive/NovaeZSlackBundle

### 説明動画
<iframe width="560" height="400" src="https://www.youtube-nocookie.com/embed/3DTe6pDCx1w" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

### インストール
https://github.com/Novactive/NovaeZSlackBundle/blob/master/bundle/Resources/doc/INSTALL.md
```shell
composer require novactive/ezslackbundle
```
```php:config/bundles.php
return [
    // ...
    JMS\SerializerBundle\JMSSerializerBundle::class => [ 'all'=> true ],
    KnpU\OAuth2ClientBundle\KnpUOAuth2ClientBundle::class => [ 'all'=> true ],
    Novactive\Bundle\eZSlackBundle\NovaeZSlackBundle::class => [ 'all'=> true ],
];
```
```yaml:config/packages/routing.yaml
_novaezslack_routes:
    resource: "@NovaeZSlackBundle/Controller"
    type:     annotation
    prefix:   /_novaezslack

_novaezslack_slack_oauth_check:
    path: /_novaezslack/auth/check
```
```yaml:config/packages/nova_ezslack.yml
nova_ezslack:
    system:
        default:
            slack_client_id: "SLACK_APP_CLIENT ID"
            slack_client_secret: "SLACK_APP_CLIENT_SECRET"
            slack_verification_token: "SLACK_APP_VERIFICATION_TOKEN"
            site_name: "novactive.us"
            favicon: "https://assets.novactive.us/images/icos/favicon.ico"
            asset_prefix: "https://assets.novactive.us"
            notifications:
                channels:
                    - "https://hooks.slack.com/services/XXXX"

knpu_oauth2_client:
    clients:
        slack:
            type: slack
            redirect_route: _novaezslack_slack_oauth_check
            client_id: "#" # will be overridden by ConfigResolver - this value does not matter
            client_secret: "#" # will be overridden by ConfigResolver - this value does not matter
```
```yaml:config/packages/security.yml
        ibexa_front:
            guard:
                authenticators:
                    - Novactive\Bundle\eZSlackBundle\Security\SlackAuthenticator
```
```shell
composer install
```


## CJW's Config-Processor Bundle
https://github.com/cjw-network/CjwConfigProcessorBundle

### インストール
```shell
composer require cjw-network/cjw-config-processor
```
```php:config/bundles.php
return [
    // ...
    // <vendor>\<bundle-name>\<bundle-long-name>::class => ['all' => true],
    CJW\CJWConfigProcessorBundle\CJWConfigProcessorBundle::class => ['all' => true],
];
```
```yaml:config/routes/cjw_config_processing.yaml
cjw_config_processor_bundle:
    resource: "@CJWConfigProcessorBundle/Resources/config/routing.yaml"
```
```yaml:config/packages/cjw_config_processor.yaml
# example settings
cjw_config_processor:
  custom_site_access_parameters:
    allow: false
    scan_parameters: false
    parameters:
      - "user.defined.parameters"

  favourite_parameters:
    allow: true
    scan_parameters: true
    parameters:
      - "user.defined.parameters"

  env_variables:
    allow: true
```
```shell
php bin/console assets:install
```


## Ibexa DXP Maintenance Mode Bundle
https://github.com/kmadejski/ezplatform-maintenance-mode

### インストール
```shell
composer require kmadejski/ezplatform-maintenance-mode
```
```php:config/bundles.php
    EzSystems\EzPlatformMaintenanceModeBundle\EzSystemsEzPlatformMaintenanceModeBundle::class => ['all' => true]
```
```shell
php bin/console cache:clear --env=prod
```

### 設定
```yaml:ezplatform.yml
ezplatform:
    system:
        default:
            maintenance_mode:
                enabled: true
```
```yaml
ezplatformgs:
    system:
        default:
            maintenance_mode:
                enabled: true
                allowed_ips: ['::1', '10.0.0.1', '192.168.0.0/16']
                response_code: 404
                template: '@Acme/custom_maintenance.html.twig'
```

## IbexaHoneypot
https://github.com/sleguevaques/IbexaHoneypot

### インストール
```shell
composer require inforca/ibexa-honeypot-bundle
```
```php:config/bundles.php
<?php
return [
    // ...
    Inforca\IbexaHoneypotBundle\IbexaHoneypotBundle::class => ['all' => true],
];
```

### 使用方法
Use Ibexa Form Builder to put a Honeypot field in your form.

The default label is `Honeypot` witch is automatically convert to `Email`.
You can change label Name.

You should customize the display of the field to hide it.

## Netgen Ibexa Forms Bundle
https://github.com/netgen/ibexa-forms-bundle

### インストール
ルートフォルダから以下を実行し、 Netgen Ibexa Forms Bundle をインストールします。
```shell
composer require netgen/ibexa-forms-bundle
```
Ibexa Platform のキャッシュを次のコマンドでクリアします。
```shell
php bin/console cache:clear
```
https://netgen.io/blog/creating-and-updating-ez-publish-content-via-symfony-s-form-component

## Netgen Layouts & Ibexa Platform integration
https://github.com/netgen-layouts/layouts-ibexa

### インストール
```shell
composer require netgen/layouts-ibexa
```

## Nova Ibexa (and eZ Platform) Bundles
https://github.com/Novactive/Nova-eZPlatform-Bundles

### インストール
```shell
git clone
make installibexa
```