The Effects of Environment on Morphological Evolution at 0 < z < 1.2 in the COSMOS Survey