Skip to content

Conversation

Hadrien45
Copy link

Following this Issue pomm-project/pomm-bundle#53

Copy link
Member

@chanmix51 chanmix51 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice to have a comprehensive description of what this validator does since it does not just check uniqueness on primary key.

$params[] = $object->$method();

if(end($fields) !== $f){
$query_string.= $f.' = $* AND ';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It’d be better to use the Where class to handle that.

@Hadrien45
Copy link
Author

Hi,

This validator allows me to check that a record in a table does not exist (I can check one or many fields).
For example I have a Posts table with two fields ("id", "name") and I want to check with the Symfony Form that the Posts table have not a record with the same "name".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants