Skip to content

Commit

Permalink
ACP-3661 Added the ACL entity synchronization command to the IG.
Browse files Browse the repository at this point in the history
  • Loading branch information
abitskil committed Sep 10, 2024
1 parent 15fce7d commit 5cb69ae
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ use Spryker\Zed\Kernel\Container;
use Spryker\Zed\Console\ConsoleDependencyProvider as SprykerConsoleDependencyProvider;
use Spryker\Zed\DataImport\Communication\Console\DataImportConsole;
use Spryker\Zed\AclDataImport\AclDataImportConfig;
use Spryker\Zed\AclMerchantPortal\Communication\Console\AclEntitySynchronizeConsole;

class ConsoleDependencyProvider extends SprykerConsoleDependencyProvider
{
Expand All @@ -213,6 +214,7 @@ class ConsoleDependencyProvider extends SprykerConsoleDependencyProvider
new DataImportConsole(DataImportConsole::DEFAULT_NAME . static::COMMAND_SEPARATOR . AclDataImportConfig::IMPORT_TYPE_ACL_GROUP),
new DataImportConsole(DataImportConsole::DEFAULT_NAME . static::COMMAND_SEPARATOR . AclDataImportConfig::IMPORT_TYPE_ACL_ROLE),
new DataImportConsole(DataImportConsole::DEFAULT_NAME . static::COMMAND_SEPARATOR . AclDataImportConfig::IMPORT_TYPE_ACL_GROUP_ROLE),
new AclEntitySynchronizeConsole(),
];

return $commands;
Expand All @@ -237,6 +239,28 @@ Make sure the configured data has been added to the following database tables:

{% endinfo_block %}

5. Synchronize the ACL entities for the merchants and their users by running the following command:

```bash
console acl:entity:synchronize
```

{% info_block warningBox "Verification" %}

Make sure that synchronized data has been added to the following database tables:
* `spy_acl_entity_rule`
* `spy_acl_entity_segment`
* `spy_acl_entity_segment_merchant`
* `spy_acl_entity_segment_merchant_user`
* `spy_acl_group`
* `spy_acl_groups_has_roles`
* `spy_acl_role`
* `spy_acl_rule`

In case you have a multi-merchant environment, ensure that the ACL entities are synchronized for each merchant.
If the ACL entities have already been synchronized, the synchronization process will not create duplicate entries.

{% endinfo_block %}

## 5) Set up behavior

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: Install the ACL feature
last_updated: Jub 24, 2024
last_updated: Sep 10, 2024
description: This integration guide provides steps on how to integrate the ACL feature into a Spryker project.
template: feature-integration-guide-template
redirect_from:
Expand Down

0 comments on commit 5cb69ae

Please sign in to comment.