Oro\Bundle\EmailBundle\Entity\EmailTemplate:
    constraints:
        - Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity:
              fields:     [ name, entityName ]
              ignoreNull: false
        - Oro\Bundle\EmailBundle\Validator\Constraints\EmailTemplateSyntax: ~
    properties:
        name:
            - NotBlank:     ~
            - Length:
                min:        3
                max:        255
        type:
            - NotBlank:     ~
        organization:
            - NotBlank: ~

Oro\Bundle\EmailBundle\Form\Model\Email:
    properties:
        from:
            - NotBlank:     ~
        to:
            - NotBlank:     ~
        subject:
            - NotBlank:     ~
