store added and button click will alert
fixed the code to use events