           delegate: @
         ,snippet
 
-  showForm: (type = "Group", data = @getData(), actionType = "Insert") ->
+  showForm: (type = "Group", data = @getData(), actionType = "Insert", addingToAGroup = no) ->
     @buttonsContainer.hide()
     @container.hide()
     @addSubView @form = new IntroductionAdminForm {
       type
       actionType
+      addingToAGroup
       delegate: @
     }
     , data


    super options, data

    {type, actionType} = @getOptions()
    @utils.defer => @setAceEditor() if (type is "Group" and actionType is "Insert") or type is "Item"

    @setVisibilityOfOverlayWarning @parentData.overlay is "no" # wtf "no"

  save: ->
    {actionType} = @getOptions()

    if @getOptions().type is "Group"
      return @insertParent() if actionType is "Insert"
      @updateParent()
    else


  createPostData: ->
    {inputs}     = @

    if @getOptions().type is "Group"
      groupData =
        title      : inputs.Title.getValue()
        expiryDate : inputs.ExpiryDate.getValue()
        visibility : inputs.Visibility.getValue()
        overlay    : inputs.Overlay.getValue()
        snippets   : []
      return groupData

    else
      editorValue = @aceEditor?.getValue()
      snippet     = """new KDView({partial: "#{editorValue}"});""" if @snippetType is "Text"

      itemData    =
        introId    : inputs.IntroId.getValue()
        introTitle : inputs.IntroTitle.getValue()
        snippet    : snippet or editorValue

      return itemData

  setVisibilityOfOverlayWarning: (isShowing) ->
    @warningView = @warningView or @fields?.warning.getSubViews()[1].getSubViews()[0]
