nitrogen: How to implement Autocompletion for in-place text box

47 views Asked by At

I have a page with in-place texbox, so user could easy modify some data, is it possible to add auto-completion functionality? I would like it behaves as #textbox_autocomplete{}.

1

There are 1 answers

0
Anton Prokofiev On

Looks like:

      F = fun(RowId,Value,AutocompleteTag, InPlaceTag) ->
            ControlId = wf:temp_id(),
            Control   =  #textbox_autocomplete { 
                        id = ControlId,
                        tag = AutocompleteTag},
            ControlId2 = wf:temp_id(),
            #inplace { id=ControlId2, text=Value, tag = {InPlaceTag,RowId}, view = #p{text=Value}, edit=Control }
      end.