UniqueFieldConstraint.php in Unique field 8
File
src/Plugin/Validation/Constraint/UniqueFieldConstraint.php
View source
<?php
namespace Drupal\unique_field\Plugin\Validation\Constraint;
use Symfony\Component\Validator\Constraint;
use Symfony\Component\Validator\Exception\MissingOptionsException;
class UniqueFieldConstraint extends Constraint {
public $bundle;
public $scope;
public $match;
public $comb;
public $fields;
public $matches = 'Matches are found in the following content: !node';
public $UniqueMessage = 'Field %label should be unique. %value is already used';
public function __construct($options = null) {
parent::__construct($options);
}
}