   @property 'resultListElement'
   @property 'searchRemotelyAt'
   
-  @method 'allowCreateWithAttributes', (attributes, prefill=null) ->
+  @method 'allowCreateWithLabel', (label) ->
     @_canCreate = true
-    @_createAttributes = attributes
-    @_createPrefill = prefill
+    @_createLabel = label
   
   @method 'render', ->
     @super()

  
  @method 'chooseResult', (result) ->
    if result == 'new'
      self = this
      form = ST.FormView.createWithModelAttributes @_model, @_createAttributes
      if @_createPrefill
        defaults = @_createPrefill @_inputValue
        delete defaults.label
        form.defaults defaults
      form.bind 'saved', (form, item) ->
        self.value item
        self.trigger 'valueChosen', item, true
      ST.DialogView.createWithTitleView "Create new #{@_model._name.toLowerCase()}", form
      form.release()
    else if result && result[0]
      @value result[0]
      @trigger 'valueChosen', result[0], false
  
  @method 'chooseByText', (text) ->
    if @_results

    @_searchValue = ''
    @_results = null
    @_canCreate = false
    @_createLabel = null
    @_focused = false
    @_searchRemotelyAt = null
  
