I'm trying to create an object like this:
var DadosUtente = true;
var DevolucaoModelo = {
get UtNome() { return (DadosUtente) ? $("#UT_Nome") : $("#Equipamento_Nome")}
};
If i change the DadosUtente the selector returned changes too.
This works properly in Chrome, but when i've tested it with Internet Explorer i get an error because the browsers is excepting :
In the rest of code i'm accessing the selectors like DevolucaoModelo.UtNome.val();
Can someone help me?
By the way, i've search a lot in google and tried others solutions but without success in IE.