I am developing a Booking System and I am having a issue i.e. How can I prevent duplicate events to be registered ?

Right now I am using: Calendar and Date for the event management and Entity Form for the booking system.

Users book a date and a time (for example: 09 / 10 / 2014, 14:30 and this is done with the Date field)

The problem I am facing that I don't want to let the users book a date and hour that is already selected. How can I prevent that?

For example: If an user books 09 / 10 / 2014, 14:30, no other user can book for the same date and time. How can i achieve this? Entity Forms has the option to set rules (via the rules module) but my knowledge on rules is not that good. Hope someone could give me a hint. Thanks in advance.


1 Answer 1


You could do this with Entity Rules, VBO, and Entityform if you are using 2.x(if not should upgrade).

It actually would an advanced Rule but here are the general steps.

  1. Make a VBO View that has date time contextual filter. You would want to return any Entityform Submission that matched.
  2. Make an Entity Rules Validation Rules.
  3. Within Rule check the Number of results of the View from step #1 when you send it the date value of the current Entityform Submission.
  4. If any results are returned then you have found a Entityform Submission that is for the existing date.

You would have to learn how to use Rules, Entity Rules, and VBO.

  • Great I am glad it worked out for you!
    – tedbow
    Oct 15, 2014 at 11:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.