Theta Function Identities and Ramanujan's Congruences on Partition Function