Закрито

Parse an xml file using fast-xml-parser

I need to parse an xml file that is inside another xml file. Please modify the follow code to parse it correctly. Thank you.

You should use the package [login to view URL]

The second xml is on the route ["AttachedDocument"]["cac:Attachment"]["cac:ExternalReference"]["cbc:Description"]

When you parse it you should be able to get an json object. To check if is working you should be able to get the route ["Invoice"]["cbc:ID"] on the second xml.

//Parse xml file Intermediate obj

const tObj = [login to view URL](xmlData,options); //[login to view URL](data, 'base64').toString()

const jsonObj = [login to view URL](tObj,options);

const prueba = jsonObj["Invoice"];

if(prueba != undefined){

numFactura = jsonObj["Invoice"]["cbc:ID"];

saveInvoice(jsonObj,numFactura);

} else {

//Get Invoice text

const invoice = jsonObj["AttachedDocument"]["cac:Attachment"]["cac:ExternalReference"]["cbc:Description"].toString();

const tObj1 = [login to view URL](invoice,options);

const jsonObj1 = [login to view URL](tObj1, options).toString();

numFactura = 'Prueba2'; //jsonObj1["Invoice"]["cbc:ID"];

saveInvoice(jsonObj1,numFactura);

Навички: XML, Javascript, node.js, JSON

Деталі: saving grid data xml file using extjs, mysql xml file using php, read xml file using net insert sql server, parsing xml file using vbnet, using excel parse file, create xml file using mysql, edit xml file using flash, read xml file using extjs, multiuser xml file using php, extract data xml file using 2008, parse xml file using vbnet, parse xml file using dom, i need an android app i already have a design for it i just need it to be built gps service for taxi, as i rosina need help to write avidavite, i have drawn the logo i just need someone to design it, i need someone to check my analytics and webmaster tools is set correctly, i need you to write a report for something.system Engineer for Banks Report 30 pages with a special format please apply with you, I need my website re-configured.I already have a design, I just need you to build my personal website., \ m looking to hire someone to work 3 to 4 hrs a day 7 days. I will need you to follow a training video and post on my account a

Про роботодавця:
( 10 відгуки(-ів) ) Bogota, Colombia

ID Проекту: #24508844

4 фрілансерів(-и) у середньому готові виконати цю роботу за $22

VileGnosis

I can make this mult-level parser for you in node.js My average project completion time is within 3-5 hours on the same day. The skills I have include PHP, HTML5, CSS3, JavaScript, jQuery, WordPress Themes & Plugins, W Більше

$30 USD за 1 день
(117 відгуків(и))
6.3
satyajeetkeshari

Hello Dear Employer, I have read the requirement and instructions written in the project. I am expert in XML related task. I can parse the code correctly by modifying the code. Більше

$20 USD за 1 день
(11 відгуків(и))
3.3
abdullahahmeda

Greetings I have read that you want to parse an XML file to json file. I am a fullstack developer with knowledge in Javscript and nodeJS. I can complete this task for you and I can start now. Thanks

$19 USD за 1 день
(4 відгуків(и))
2.2
(0 відгуків(и))
0.0