Added click event and saves the state
Calculates total price