More work in progress for competition creation
Updated some js and some api to save a load phases