changed createEvent function to use built in collection function create instead of ajax call