Margot Robbie's standalone Harley Quinn movie had a longer journey to the big screen than you might think.