tidy up event handler declarations to use .on consistently

also more consistent alignment and quoting style for readability
fix logic around sync_id following initial save of a new activity
copying an activity should not copy its id or its sync_id