The first opium war exposed the military weakness of China despite her enormous economy and advanced society. This created a huge opportunity for the British to exploit China by forcing more trading ports - more opium penetration into the inland regions.
The second opium war basically cracked open the whole China for other European powers to exploit. The consequences include burn-down of the Summer Palace, numerous unequal treaties and forced lease of strategic places like Shanghai.
The Opium Wars are still a strong focus of history education in China. It still serves a reminder to all Chinese students that - if you are weak, you are deemed to be exploited. There's no friend in politics. If there's a chance, other countries will beat you up when you are weak.
This mentality explains a lot of current Chinese policy - death sentence for illegal drug dealer, rapid military expansion, rapid economic growth, non-interference policy and assertive foreign policy.
Most of the west don't understand why China behaves like what it is today because they don't understand what's like being forced to take drug. They don't understand what's like being carved to pieces. The Opium trade made some individual Indians and Chinese fabulously wealthy, but on the whole it was a negative for India and China.