-3
I’m trying to verify a Json feedback for a decision-making, but I’m not getting it, I have it:
if (sender.getFieldName() == 'IdUsuarioIntranet') { var MatriculaPessoa = sender.getValue(); console.log("MATRÍCULA: " + MatriculaPessoa); $.getJSON( location.href, { IdPessoa: MatriculaPessoa }, function(data) { if (data.CelularCorporativo == 'null') { console.log("VAZIO"); data.CelularCorporativo = 'SEM CELULAR'; } editors['CelularCorporativo'].setValue(data.CelularCorporativo); editors['EmailCorporativo'].setValue(data.EmailCorporativo); } ) }
To help the question, when I return to search for my user I have email, but I do not have mobile phone, the email is rescued correctly, but as I do not have Cellular registered the field Cellular Corportativo needs to be filled with a text.
But it’s not working, some hint?
What exactly isn’t working?
– Luiz Felipe
Hello @Luizfelipe, the console doesn’t even show "EMPTY".
– adventistapr
Is the AJAX request being made at least? What was the HTTP response obtained?
– Woss