We have a meeting room booking system that needs one extra feature added. Meeting rooms 1 and 2 have a removable wall so people can book Room 1, Room 2 or Rooms 1 and 2. What I need is a way during booking for the option to book one or both rooms.
My plan: Offering separate booking forms for Room 1 and Room 2 and just have a field where they can check off if they need the other room booked with it. If this box is checked, it will create a duplicate booking with a new ID and the room number (Term reference list) changed.
From my reading, I think I need to use node_save() to do this? I am not sure where to call this from though. I assume I need to call it from one of the hook_node_* things (as we already do for some other custom code)?
Basically, how do I create a duplicate node when submitting a form with almost identical data but one field is changed before it saves the copy?
Thanks!