md-autocomplete does not show options

0

Personal I have the following code:

            <md-autocomplete md-items="cliente in vm.listaClientes"
                         md-item-text="cliente.nome"
                         md-search-text="vm.busca"
                         md-search-text-change="vm.querySearch(vm.busca)"
                         md-no-cache="true">

            <md-item-template>
                <span md-highlight-text="vm.busca" md-highlight-flags="^i">{{cliente.nome}}</span>
            </md-item-template>
            <md-not-found>
                Nenhum cliente encontrado
            </md-not-found>
        </md-autocomplete>

Function on Controller:

        function querySearch(termo) {
        var clienteViewModel = {
            filtroBusca: termo
        };

        ClientesDataService.searchCliente(clienteViewModel)
            .then(function (response) {
                vm.listaClientes = response.data;
                console.log(response);
            }).catch(function (response) {

            });
    }

The whole process happens normally (reaches the backend and brings results), but no option is displayed in autocomplete. If someone helps me I appreciate it.

    
asked by anonymous 26.04.2018 / 16:56

0 answers