moved js code to js file from html
fixed for selected manager option