jeudi 10 avril 2014

[2.3.1] DomQuery's not equal (!=) attribute selector not working as expected

I'm using ComponentQuery.query() to find all elements of a certain type that have an attribute not equal to the one indicated.




Code:



console.log(Ext.ComponentQuery.query('tarefas_decorrer togglebutton[name=telefone]'));

console.log(Ext.ComponentQuery.query('tarefas_decorrer togglebutton[name!=telefone]'));



Even though the expect result is that the first log prints the toggle button with the indicated name and the second log should print all the others.



What is actually happening is that BOTH queries return the same togglebutton, with name=telefone. I've tried the same query with different attributes and the result is the same. The not-equal query always returns the same as the equal one.




Aucun commentaire:

Enregistrer un commentaire