--- /dev/null
+<?php
+
+namespace Epnadmin\CoreBundle\Validator\Constraints;
+
+use Symfony\Component\Validator\Constraint;
+
+/**
+ * @Annotation
+ */
+class ValidParent extends Constraint
+{
+ public $all = false;
+ public $message_parent_inactive = 'Le parent "%name%" n\'est pas activé';
+
+ /**
+ * {@inheritDoc}
+ */
+ public function getTargets()
+ {
+ return self::CLASS_CONSTRAINT;
+ }
+
+ public function validatedBy()
+ {
+ return 'resource_valid_parent_validator';
+ }
+}