Skip to Content

Create new UI5 control for autoComplete

Hi,

I found this example and I need to use something with similar logic but I need to create New Ui5 control

which encapsulate all the logic inside

JS Bin - Collaborative JavaScript Debugging

I need to add the following functionality to the new control plus what is defined in the JS bin,I wasnt able to sucessed with it since we have to provide additional logic

1.Add value functionality like following:

value: {
                path: "/path",
                mode: sap.ui.model.BindingMode.OneWay,
                formatter: function(path) {

                        var event = this;
                        doc.getProject().then(function(oProject) {
....
          
                }
            },


2. Add the suggest and change method

suggest: function(oEvent) {
                this.destroyItems();
                var sValue = oEvent.getParameter("suggestValue");
                for (var i = 0; i < aData.length; i++) {
...
                    }
                }
            },
            change: $.proxy(oController.onChange, oController),

3. add the following
oAuto1.setFilterFunction(function(sValue, oItem) {
            var ignVal = sVae.trCase();
            return (oItem.getText() !== -1) ||
         .....
        });

Is this possible in UI5 ?

Regards,

Joerg

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    Posted on Sep 21, 2015 at 07:11 PM

    HI Again,

    I know that this is not trivial and can be complicated but can I get some help in this?

    Thanks!

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.