Added the ajax  function to create group