summary update javascript