converted Hostgroup form to AngularJS
collapse works