Glass material is transparent only when object is selected
You might have probably deleted the glass material. So you have to delete your object and add another one.

You can watch the following tutorial
https://youtu.be/p5q_P8WQegQ
https://youtu.be/I685JGTCpCU

Hope it helps.