Update metodos.js
This commit is contained in:
parent
d7694e4b70
commit
334dd5f73f
38
metodos.js
38
metodos.js
@ -656,46 +656,12 @@ async function Fun_ConsultarClavesCatastrales(agent, req, res, _cedula = null, n
|
|||||||
const regex = /^[0-9]*$/;
|
const regex = /^[0-9]*$/;
|
||||||
_cedula = _cedula.replace(/-/g, "");
|
_cedula = _cedula.replace(/-/g, "");
|
||||||
if (regex.test(_cedula)) {
|
if (regex.test(_cedula)) {
|
||||||
console.log("legion model antes 12385");
|
|
||||||
let legion = await funcion.ConsultaClaves(_cedula, nuevo);
|
let legion = await funcion.ConsultaClaves(_cedula, nuevo);
|
||||||
console.log("legion model antes");
|
|
||||||
console.log(legion)
|
|
||||||
if (legion['ok'] == true) {
|
if (legion['ok'] == true) {
|
||||||
console.log("legion model");
|
|
||||||
console.log(legion);
|
|
||||||
let printzeus = '';
|
let printzeus = '';
|
||||||
legion['data']['data'].forEach((elem_ares, index) => {
|
legion['data']['data'].forEach((elem_ares, index) => {
|
||||||
printzeus += '\n*' + elem_ares.name + ': **$' + elem_ares.value + '**';
|
printzeus += '\n*' + elem_ares.name + (elem_ares.value != null ? ': $' + elem_ares.value : '');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
// let mensjae_predios = '';
|
|
||||||
// legion['data'].forEach((element, index) => {
|
|
||||||
// var rec = element['valor']['boot']['anteriores'];
|
|
||||||
|
|
||||||
// if (element['valor']['boot']['total'] != null) {
|
|
||||||
// if (element['valor']['boot']['anteriores'] == 'Recaudación al día') {
|
|
||||||
// rec = element['valor']['boot']['actual'] + '\n' + element['valor']['boot']['total'];
|
|
||||||
// }else{
|
|
||||||
// rec += '\n' + element['valor']['boot']['actual'] + '\n' + element['valor']['boot']['total'];
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// if (mensjae_predios.length > 0) {
|
|
||||||
// mensjae_predios += '\n\n';
|
|
||||||
// }
|
|
||||||
// mensjae_predios += element['text'] + '\n' + element['direccion'] + '\n' + rec;
|
|
||||||
// // if (index == (coun - 1)) {
|
|
||||||
// // mensjae_predios += element['text'] + '\n' + element['direccion'] + '\n' + rec;
|
|
||||||
// // // agent.add(element['text'] + '\n' + element['direccion'] + '\n' + rec);
|
|
||||||
// // // return Fun_RetornarAlinicio(agent, req, res, funcion.conver_name(data_context.name));
|
|
||||||
// // } else {
|
|
||||||
// // mensjae_predios += element['text'] + '\n' + element['direccion'] + '\n' + rec;
|
|
||||||
// // // agent.add(element['text'] + '\n' + funcion.conver_capitalice(element['direccion']) + '\n' + rec);
|
|
||||||
// // }
|
|
||||||
// });
|
|
||||||
// if (mensjae_predios.length > 0) {
|
|
||||||
// agent.add(mensjae_predios);
|
|
||||||
// }
|
|
||||||
agent.add(printzeus);
|
agent.add(printzeus);
|
||||||
return Fun_RetornarAlinicio(agent, req, res, funcion.conver_name(data_context.name));
|
return Fun_RetornarAlinicio(agent, req, res, funcion.conver_name(data_context.name));
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user