clean up template; add missing links; update missing links; check enabled or disabled for apps