Skip to content

Commit

Permalink
Deetv
Browse files Browse the repository at this point in the history
  • Loading branch information
gerMdz committed Apr 24, 2021
1 parent a210e09 commit 0505ef9
Show file tree
Hide file tree
Showing 2 changed files with 134 additions and 110 deletions.
80 changes: 40 additions & 40 deletions assets/js/nota_mensaje.js
Original file line number Diff line number Diff line change
@@ -1,26 +1,26 @@
import $ from 'jquery';
$(function () {
const puno = localStorage.getItem("Desp6Puno");
const pdos = localStorage.getItem("Desp6Pdos");
const ptres = localStorage.getItem("Desp6Ptres");
const pcuatro = localStorage.getItem("Desp6Pcuatro");
const pcinco = localStorage.getItem("Desp6Pcinco");
const pseis = localStorage.getItem("Desp6Pseis");
const psiete = localStorage.getItem("Desp6Psiete");
const pocho = localStorage.getItem("Desp6Pocho");
const pnueve = localStorage.getItem("Desp6Pnueve");
const pdiez = localStorage.getItem("Desp6Pdiez");
const puno = localStorage.getItem("DEETV1Puno");
const pdos = localStorage.getItem("DEETV1Pdos");
const ptres = localStorage.getItem("DEETV1Ptres");
const pcuatro = localStorage.getItem("DEETV1Pcuatro");
const pcinco = localStorage.getItem("DEETV1Pcinco");
const pseis = localStorage.getItem("DEETV1Pseis");
const psiete = localStorage.getItem("DEETV1Psiete");
const pocho = localStorage.getItem("DEETV1Pocho");
const pnueve = localStorage.getItem("DEETV1Pnueve");
const pdiez = localStorage.getItem("DEETV1Pdiez");

if (pcinco != null) {
$('#pcinco').val(JSON.parse(localStorage.Desp6Pcinco))
$('#pcinco').val(JSON.parse(localStorage.DEETV1Pcinco))
muestra1('#lpcinco', '#sinpcinco')
aceptado('cinco');
} else {
oculta1('#lpcinco', '#sinpcinco')
}

if (puno != null) {
$('#puno').val(JSON.parse(localStorage.Desp6Puno))
$('#puno').val(JSON.parse(localStorage.DEETV1Puno))
muestra1('#lpuno', '#sinpuno')
aceptado('uno');
console.log('19')
Expand All @@ -30,62 +30,62 @@ $(function () {
}

if (pdos != null) {
$('#pdos').val(JSON.parse(localStorage.Desp6Pdos))
$('#pdos').val(JSON.parse(localStorage.DEETV1Pdos))
muestra1('#lpdos', '#sinpdos')
aceptado('dos');
} else {
oculta1('#lpdos', '#sinpdos')
}

if (ptres != null) {
$('#ptres').val(JSON.parse(localStorage.Desp6Ptres))
$('#ptres').val(JSON.parse(localStorage.DEETV1Ptres))
muestra1('#lptres', '#sinptres')
aceptado('tres');
} else {
oculta1('#lptres', '#sinptres')
}

if (pcuatro != null) {
$('#pcuatro').val(JSON.parse(localStorage.Desp6Pcuatro))
$('#pcuatro').val(JSON.parse(localStorage.DEETV1Pcuatro))
muestra1('#lpcuatro', '#sinpcuatro')
aceptado('cuatro');
} else {
oculta1('#lpcuatro', '#sinpcuatro')
}

if (pseis != null) {
$('#pseis').val(JSON.parse(localStorage.Desp6Pseis))
$('#pseis').val(JSON.parse(localStorage.DEETV1Pseis))
muestra1('#lpseis', '#sinpseis')
aceptado('seis');
} else {
oculta1('#lpseis', '#sinpseis')
}
if (psiete != null) {
$('#psiete').val(JSON.parse(localStorage.Desp6Psiete))
$('#psiete').val(JSON.parse(localStorage.DEETV1Psiete))
muestra1('#lpsiete', '#sinpsiete')
aceptado('siete');
} else {
oculta1('#lpsiete', '#sinpsiete')
}

if (pocho != null) {
$('#pocho').val(JSON.parse(localStorage.Desp6Pocho))
$('#pocho').val(JSON.parse(localStorage.DEETV1Pocho))
muestra1('#lpocho', '#sinpocho')
aceptado('ocho');
} else {
oculta1('#lpocho', '#sinpocho')
}

if (pnueve != null) {
$('#pnueve').val(JSON.parse(localStorage.Desp6Pnueve))
$('#pnueve').val(JSON.parse(localStorage.DEETV1Pnueve))
muestra1('#lpnueve', '#sinpnueve')
aceptado('nueve');
} else {
oculta1('#lpnueve', '#sinpnueve')
}

if (pdiez != null) {
$('#pdiez').val(JSON.parse(localStorage.Desp6Pdiez))
$('#pdiez').val(JSON.parse(localStorage.DEETV1Pdiez))
muestra1('#lpdiez', '#sinpdiez')
aceptado('diez');
} else {
Expand Down Expand Up @@ -276,52 +276,52 @@ function procesa(p) {
console.log('p = ' + p)
if (p === 'diez') {
const pdiez = $('#pdiez').val();
localStorage.Desp6Pdiez = JSON.stringify(pdiez);
localStorage.DEETV1Pdiez = JSON.stringify(pdiez);
}

if (p === 'nueve') {
const pnueve = $('#pnueve').val();
localStorage.Desp6Pnueve = JSON.stringify(pnueve);
localStorage.DEETV1Pnueve = JSON.stringify(pnueve);
}

if (p === 'ocho') {
const pocho = $('#pocho').val();
localStorage.Desp6Pocho = JSON.stringify(pocho);
localStorage.DEETV1Pocho = JSON.stringify(pocho);
}

if (p === 'siete') {
const psiete = $('#psiete').val();
localStorage.Desp6Psiete = JSON.stringify(psiete);
localStorage.DEETV1Psiete = JSON.stringify(psiete);
}

if (p === 'seis') {
const pseis = $('#pseis').val();
localStorage.Desp6Pseis = JSON.stringify(pseis);
localStorage.DEETV1Pseis = JSON.stringify(pseis);
}

if (p === 'cinco') {
const pcinco = $('#pcinco').val();
localStorage.Desp6Pcinco = JSON.stringify(pcinco);
localStorage.DEETV1Pcinco = JSON.stringify(pcinco);
}

if (p === 'uno') {
const puno = $('#puno').val();
localStorage.Desp6Puno = JSON.stringify(puno);
localStorage.DEETV1Puno = JSON.stringify(puno);
}

if (p === 'dos') {
const pdos = $('#pdos').val();
localStorage.Desp6Pdos = JSON.stringify(pdos);
localStorage.DEETV1Pdos = JSON.stringify(pdos);
}

if (p === 'tres') {
const ptres = $('#ptres').val();
localStorage.Desp6Ptres = JSON.stringify(ptres);
localStorage.DEETV1Ptres = JSON.stringify(ptres);
}

if (p === 'cuatro') {
const pcuatro = $('#pcuatro').val();
localStorage.Desp6Pcuatro = JSON.stringify(pcuatro);
localStorage.DEETV1Pcuatro = JSON.stringify(pcuatro);
}

}
Expand All @@ -331,76 +331,76 @@ function aceptado(p) {
console.log('aceptado' + p);

if (p === 'diez') {
const pdiez = JSON.parse(localStorage.Desp6Pdiez);
const pdiez = JSON.parse(localStorage.DEETV1Pdiez);

$('#lpdiez').addClass('fontTahu fa-2x text-info');
$('#lpdiez').html(pdiez);
$('#sinpdiez').hide();
}

if (p === 'nueve') {
const pnueve = JSON.parse(localStorage.Desp6Pnueve);
const pnueve = JSON.parse(localStorage.DEETV1Pnueve);

$('#lpnueve').addClass('fontTahu fa-2x text-info');
$('#lpnueve').html(pnueve);
$('#sinpnueve').hide();
}

if (p === 'ocho') {
const pocho = JSON.parse(localStorage.Desp6Pocho);
const pocho = JSON.parse(localStorage.DEETV1Pocho);

$('#lpocho').addClass('fontTahu fa-2x text-info');
$('#lpocho').html(pocho);
$('#sinpocho').hide();
}

if (p === 'seis') {
const pseis = JSON.parse(localStorage.Desp6Pseis);
const pseis = JSON.parse(localStorage.DEETV1Pseis);

$('#lpseis').addClass('fontTahu fa-2x text-info');
$('#lpseis').html(pseis);
$('#sinpseis').hide();
}

if (p === 'siete') {
const psiete = JSON.parse(localStorage.Desp6Psiete);
const psiete = JSON.parse(localStorage.DEETV1Psiete);

$('#lpsiete').addClass('fontTahu fa-2x text-info');
$('#lpsiete').html(psiete);
$('#sinpsiete').hide();
}

if (p === 'uno') {
const puno = JSON.parse(localStorage.Desp6Puno);
const puno = JSON.parse(localStorage.DEETV1Puno);

$('#lpuno').addClass('fontTahu fa-2x text-info');
$('#lpuno').html(puno);
$('#sinpuno').hide();
}
if (p === 'cinco') {
console.log('aceptado = ' + p)
const pcinco = JSON.parse(localStorage.Desp6Pcinco);
const pcinco = JSON.parse(localStorage.DEETV1Pcinco);
$('#lpcinco').addClass('fontTahu fa-2x text-info');
$('#lpcinco').html(pcinco);
$('#lpcinco').show();
$('#sinpcinco').hide();
}
if (p === 'dos') {
const pdos = JSON.parse(localStorage.Desp6Pdos);
const pdos = JSON.parse(localStorage.DEETV1Pdos);

$('#lpdos').addClass('fontTahu fa-2x text-info');
$('#lpdos').html(pdos);
$('#sinpdos').hide();
}
if (p === 'tres') {
const ptres = JSON.parse(localStorage.Desp6Ptres);
const ptres = JSON.parse(localStorage.DEETV1Ptres);

$('#lptres').addClass('fontTahu fa-2x text-info');
$('#lptres').html(ptres);
$('#sinptres').hide();
}
if (p === 'cuatro') {
const pcuatro = JSON.parse(localStorage.Desp6Pcuatro);
const pcuatro = JSON.parse(localStorage.DEETV1Pcuatro);

$('#lpcuatro').addClass('fontTahu fa-2x text-info');
$('#lpcuatro').html(pcuatro);
Expand Down
Loading

0 comments on commit 0505ef9

Please sign in to comment.