fix bugs in links in views