Add passing current group to template

Adds passing current group to template and makes it react properly.