add reloadWindow function to the modal