0 Replies Latest reply on Mar 6, 2015 9:43 AM by amine8357

    rich:autocomplete not working richfaces 4.3

    amine8357

      I´m trying to implement a richfaces autocomplete component, the problem i have is that the autocompleteMethod is never called.

       

       

      MBean:

      public String getFormacode() {
        return testDto.getFormacode();
      }
      
      public void setFormacode(String formacode) {
        testDto.setFormacode(formacode);
      }
      public List<String> getToShow() {
        return testDto.getToShow();
      }
      
      public void setToShow(List<String> toShow) {
        testDto.setToShow(toShow);
      }
      
      public List<String> autocomplete(String prefix) {
        Map<String, String> map;
        List<String> listOfItems = new ArrayList<String>();
        try {
        map = testFacade.getFormacode(prefix);
      
        for (Entry<String, String> e : map.entrySet()) {
        listOfItems.add(e.getValue());
        }
        } catch (RemoteException | ServiceException e1) {
        e1.printStackTrace();
        }
        setToShow(listOfItems);
        return listOfItems;
      }
      

       

      When i debug, the getter getToShow and the function autocomplete are never called.

      I am using richfaces 4.3.3

      ps: in the log

       

      ERROR [com.liferay.faces.bridge.application.MissingResourceImpl] (http--127.0.0.1-8080-3) Resource handler=[com.liferay.faces.bridge.application.ResourceHandlerOuterImpl@73ceed1] was unable to create a resource for resourceName=[AutocompleteBase.js] libraryName=[org.richfaces.images] contentType=[null]
      WARNING [javax.enterprise.resource.webcontainer.jsf.application] (http--127.0.0.1-8080-5) JSF1064 : Impossible de localiser ou de servir une ressource, Autocomplete.js, depuis la bibliothèque org.richfaces.images