Split into groups and get template working