Skip to content

Commit

Permalink
Ajuste e novos erros de callback
Browse files Browse the repository at this point in the history
Aumentado o tamanho do campo `parentId` de modo a visualizar todo o
conteúdo do id da venue principal. Incluídos novos erros de rede
(callbacks) retornados pela API. Opção de importar CSV temporariamente
desabilitada.
  • Loading branch information
gavlinski committed Sep 6, 2014
1 parent c871890 commit 387a1d6
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion edit.php
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@
}

if ($editParentId) {
echo '<input type="text" dojoType="dijit.form.TextBox" name="parentId" maxlength="24" value=" " placeHolder="Dentro" style="width: 7em; margin-left: 5px;" onchange="verificarAlteracao(this, ', $i - 1, ')">', chr(10);
echo '<input type="text" dojoType="dijit.form.TextBox" name="parentId" maxlength="24" value=" " placeHolder="Dentro" style="width: 14em; margin-left: 5px;" onchange="verificarAlteracao(this, ', $i - 1, ')">', chr(10);
}

if ($editPhone) {
Expand Down
10 changes: 9 additions & 1 deletion js/4sq.js
Original file line number Diff line number Diff line change
Expand Up @@ -271,6 +271,14 @@ function xmlhttpRequest(metodo, endpoint, acao, dados, i) {
imagem = "<img src='img/erro.png' alt='Erro 500: Internal Server Error'>";
dica = "<span style=\"font-size: 12px\">Erro 500: Internal Server Error</span>";
break;
case 503:
imagem = "<img src='img/erro.png' alt='Erro 503: backend read error'>";
dica = "<span style=\"font-size: 12px\">Erro 503: backend read error</span>";
break;
case 504:
imagem = "<img src='img/erro.png' alt='Erro 504: Gateway Time-out'>";
dica = "<span style=\"font-size: 12px\">Erro 504: Gateway Time-out</span>";
break;
default:
imagem = "<img src='img/erro.png' alt='Erro desconhecido: " + xmlhttp.status + "'>";
dica = "<span style=\"font-size: 12px\">Erro desconhecido: " + xmlhttp.status + "</span>";
Expand Down Expand Up @@ -1447,7 +1455,7 @@ function showDialogComment(caller, comment) {
function verificarAlteracao(textbox, i) {
var index = csv[0].indexOf(textbox.name)
if (csv[i + 1][index].slice(1, -1) != textbox.value) {
//console.info("changed: " + textbox.name + ", old value: " + csv[i + 1][index].slice(1, -1) + ", new value: " + textbox.value);
console.info("changed: " + textbox.name + ", old value: " + csv[i + 1][index].slice(1, -1) + ", new value: " + textbox.value);
csv[i + 1][index] = '"' + textbox.value + '"';
dojo.byId("result" + i).innerHTML = "";
if (linhasEditadas.indexOf(i) == -1)
Expand Down
2 changes: 1 addition & 1 deletion main.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ function removeLocalCache($key) {
</button>
-->
<div>
<button dojoType="dijit.form.Button" type="submit" class="continue">
<button dojoType="dijit.form.Button" type="submit" class="continue" disabled=disabled>
Continuar
</button>
</div>
Expand Down

0 comments on commit 387a1d6

Please sign in to comment.