Skip to content
This bundle performs duplicate check against your entities.
PHP HTML
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Adapter
Async
Command
Controller
Datagrid
DependencyInjection
Entity
EventListener
Exception
Factory
Migrations/Schema
Model
Placeholder
Provider
Repository
Resources
Tests
.gitignore
.php_cs
.travis.yml
DMKDuplicateCheckBundle.php
Facade.php
Finder.php
FinderInterface.php
LICENSE
Readme.md
composer.json
phpstan.neon
phpunit.xml.dist

Readme.md

What does this bundle do?

This bundle provides a functionality to perform duplicate checks against your entities. Especially in the CRM context you will encounter in the issue where you database is full of duplicates.

Usage

To enable the duplicate check for a given entity just, enable the check via the entity config:

<?php
/**
 * @ORM\Entity
 * @Config(
 *  defaultValues={
 *      "duplicate"={
 *          "enabled"=true
 *      }
 *  }
 * )
 */
class MyEntity
{
    /**
     * @Config(defaultValues={"duplicate"={"enabled"=true}})
     */
    protected $name:
}

The bundle will perform a entity check, if an entity is created or updated automatically.

Trigger manually

If you want to perform a check manually, you can use the Facade class. This class performs a check and save the result immediately.

Please beware, that this check will might consume multiple megabyte of ram, depending of you database.

Create your own adapter

Creating your own adapter is really simple. This bundle follows the Adapter Pattern. So just create a class which implements the AdapterInterface and tag this service with the tag "dmk_duplicate_check.adapter".

You can’t perform that action at this time.