From: atz Date: Wed, 15 Sep 2010 05:24:57 +0000 (+0000) Subject: Tons of EDI test files X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=a86bb792a4ea857cec44a9f8bde1d8ee4e987c56;p=evergreen%2Fbjwebb.git Tons of EDI test files git-svn-id: svn://svn.open-ils.org/ILS/trunk@17679 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/edi_scratch/0BzIfl53u8.ORDRSP.jedi b/edi_scratch/0BzIfl53u8.ORDRSP.jedi new file mode 100644 index 000000000..daa76b36a --- /dev/null +++ b/edi_scratch/0BzIfl53u8.ORDRSP.jedi @@ -0,0 +1 @@ +my $o = '{"trailer":["UNZ",{"0020":"02","0036":1}],"recipient_qual":"31B","body":[{"ORDRSP":[["UNH",{"S009":{"0052":"D","0054":"96A","0065":"ORDRSP","0051":"UN"},"0062":"02"}],["BGM",{"1225":"4","C002":{"1001":"231"},"1004":"000000","4343":"AC"}],["DTM",{"C507":{"2379":"102","2380":"20100611","2005":"137"}}],["SG1",[["RFF",{"C506":{"1153":"ON","1154":"8"}}]]],["SG3",[["NAD",{"3035":"SU","C082":{"3039":"1692100","3055":"9"}}]]],["SG8",[["CUX",{"C504":[{"6345":"USD","6347":"2","6343":"9"}]}]]],["SG26",[["LIN",{"1082":1,"1229":"2"}],["IMD",{"C273":{"7008":[" "]},"7077":"F","7081":"BST"}],["QTY",{"C186":{"6060":10,"6063":"21"}}],["QTY",{"C186":{"6060":0,"6063":"12"}}],["QTY",{"C186":{"6060":10,"6063":"85"}}],["FTX",{"C107":{"1131":"8B","3055":"28","4441":"27"},"4451":"LIN"}],["SG30",[["PRI",{"C509":{"5125":"AAB","5118":0,"5387":"SRP"}}]]],["SG31",[["RFF",{"C506":{"1153":"LI","1154":"8/1"}}]]]]],["SG26",[["LIN",{"1082":2,"1229":"2"}],["IMD",{"C273":{"7008":[" "]},"7077":"F","7081":"BST"}],["QTY",{"C186":{"6060":8,"6063":"21"}}],["QTY",{"C186":{"6060":0,"6063":"12"}}],["QTY",{"C186":{"6060":8,"6063":"85"}}],["FTX",{"C107":{"1131":"8B","3055":"28","4441":"27"},"4451":"LIN"}],["SG30",[["PRI",{"C509":{"5125":"AAB","5118":0,"5387":"SRP"}}]]],["SG31",[["RFF",{"C506":{"1153":"LI","1154":"8/2"}}]]]]],["SG26",[["LIN",{"1082":3,"1229":"2"}],["IMD",{"C273":{"7008":[" "]},"7077":"F","7081":"BST"}],["QTY",{"C186":{"6060":5,"6063":"21"}}],["QTY",{"C186":{"6060":0,"6063":"12"}}],["QTY",{"C186":{"6060":5,"6063":"85"}}],["FTX",{"C107":{"1131":"8B","3055":"28","4441":"27"},"4451":"LIN"}],["SG30",[["PRI",{"C509":{"5125":"AAB","5118":0,"5387":"SRP"}}]]],["SG31",[["RFF",{"C506":{"1153":"LI","1154":"8/3"}}]]]]],["UNS",{"0081":"S"}],["CNT",{"C270":{"6069":"2","6066":3}}],["UNT",{"0074":33,"0062":"02"}]]}],"sender":"1556150","header":["UNB",{"S003":{"0007":"31B","0010":"123EVER"},"0020":"02","S004":{"0019":1155,"0017":100611},"S001":{"0001":"UNOC","0002":3},"S002":{"0007":"31B","0004":"1556150"}}],"recipient":"123EVER","sender_qual":"31B","UNA":{"seg_term":"\'","decimal_sign":".","esc_char":"?","de_sep":"+","ce_sep":":","rep_sep":" "}}'; diff --git a/edi_scratch/0LGQQtTxuv.orders.edi b/edi_scratch/0LGQQtTxuv.orders.edi new file mode 100644 index 000000000..b3656bb30 --- /dev/null +++ b/edi_scratch/0LGQQtTxuv.orders.edi @@ -0,0 +1 @@ +UNA:+.? 'UNB+UNOB:3+123EVER:31B+1556150:31B+100804:1504+1'UNH+1+ORDERS:D:96A:UN'BGM+220+12+9'DTM+137:20100804:102'NAD+BY+123EVER 0001::91'NAD+SU+1556150::31B'NAD+SU+8::92'CUX+2:USD:9'LIN+67++9780754809654:EN'PIA+5+9780754809654:EN+075480965X:IB+67:SA'IMD+F+BTI+:::The arthritis cookbook ?:'IMD+F+BPU+:::Lorenz,'IMD+F+BPD+:::2002.'IMD+F+BPH+:::96 p. ?:'QTY+21:5'PRI+AAB:15'RFF+LI:12/67'LIN+66++9780596526856:EN'PIA+5+9780596526856:EN+0596526857:IB+66:SA'IMD+F+BTI+:::Illustrated guide to astronomical w:onders'IMD+F+BPU+:::Make?:Books,'IMD+F+BPD+:::cop. 2007.'IMD+F+BPH+:::519 p. ?:'QTY+21:13'PRI+AAB:24'RFF+LI:12/66'LIN+69++9789990545371:EN'PIA+5+9789990545371:EN+69:SA'IMD+F+BTI+:::Ancient Text'QTY+21:5'PRI+AAB:35'RFF+LI:12/69'LIN+68++9780446360012:EN'PIA+5+9780446360012:EN+0446360015:IB+68:SA'IMD+F+BTI+:::On leaving Charleston /'IMD+F+BPU+:::Warner Books,'IMD+F+BPD+:::1984.'IMD+F+BPH+:::574 p.'QTY+21:12'PRI+AAB:12'RFF+LI:12/68'UNS+S'CNT+2:4'UNT+43+1'UNZ+1+1' diff --git a/edi_scratch/4PkcdYeZtT.edi b/edi_scratch/4PkcdYeZtT.edi new file mode 100644 index 000000000..a039dc26b --- /dev/null +++ b/edi_scratch/4PkcdYeZtT.edi @@ -0,0 +1 @@ +UNA:+.? 'UNB+UNOB:3+123EVER:31B+1556150:31B+100622:0212+1'UNH+1+ORDERS:D:96A:UN'BGM+220+8+9'DTM+137:20100621:102'NAD+BY+123EVER 0001::91'NAD+SU+1556150::31B'NAD+SU+8::92'CUX+2:USD:9'LIN+1++9780446360272:EN'PIA+5+9780446360272:EN+0446360279:IB+57:SA'IMD+F+BTI+:::Webster?'s new world thesaurus ?:'IMD+F+BPU+:::Warner Books, Inc.,'IMD+F+BPD+:::1990.'IMD+F+BPH+:::xv, 494 p. ;'QTY+21:10'PRI+AAB:4.5'RFF+LI:8/1'LIN+2++9780446357197:EN'PIA+5+9780446357197:EN+0446357197:IB+0446831832:IB+9780446831833:EN+59:SA'IMD+F+BTI+:::The world is full of divorced women: /'IMD+F+BPU+:::Warner Books,'IMD+F+BPD+:::c1980.'IMD+F+BPH+:::413 p. ;'QTY+21:8'PRI+AAB:7.99'RFF+LI:8/2'LIN+3++9780446350105:EN'PIA+5+9780446350105:EN+0446350109:IB+60:SA'IMD+F+BTI+:::Windmills of the gods /'IMD+F+BPU+:::Warner Books,'IMD+F+BPD+:::1988, c1987.'IMD+F+BPH+:::xiii, 434 p. ;'QTY+21:5'PRI+AAB:8.75'RFF+LI:8/3'UNS+S'CNT+2:3'UNT+37+1'UNZ+1+1' diff --git a/edi_scratch/5pGP3O5rgS b/edi_scratch/5pGP3O5rgS new file mode 100644 index 000000000..ad28cc648 --- /dev/null +++ b/edi_scratch/5pGP3O5rgS @@ -0,0 +1 @@ +UNA:+.? 'UNB+UNOB:3+123EVER:31B+1556150:31B+100727:1833+1'UNH+1+ORDERS:D:96A:UN'BGM+220+8+9'DTM+137:20100621:102'NAD+BY+123EVER 0001::91'NAD+SU+1556150::31B'NAD+SU+8::92'CUX+2:USD:9'LIN+1++9780446360272:EN'PIA+5+9780446360272:EN+0446360279:IB+57:SA'IMD+F+BTI+:::Webster?'s new world thesaurus ?:'IMD+F+BPU+:::Warner Books, Inc.,'IMD+F+BPD+:::1990.'IMD+F+BPH+:::xv, 494 p. ;'QTY+21:10'PRI+AAB:4.5'RFF+LI:8/1'LIN+2++9780446357197:EN'PIA+5+9780446357197:EN+0446357197:IB+0446831832:IB+9780446831833:EN+59:SA'IMD+F+BTI+:::The world is full of divorced women: /'IMD+F+BPU+:::Warner Books,'IMD+F+BPD+:::c1980.'IMD+F+BPH+:::413 p. ;'QTY+21:8'PRI+AAB:7.99'RFF+LI:8/2'LIN+3++9780446350105:EN'PIA+5+9780446350105:EN+0446350109:IB+60:SA'IMD+F+BTI+:::Windmills of the gods /'IMD+F+BPU+:::Warner Books,'IMD+F+BPD+:::1988, c1987.'IMD+F+BPH+:::xiii, 434 p. ;'QTY+21:5'PRI+AAB:8.75'RFF+LI:8/3'UNS+S'CNT+2:3'UNT+37+1'UNZ+1+1' diff --git a/edi_scratch/acq.bugs b/edi_scratch/acq.bugs new file mode 100644 index 000000000..19c0ca9c1 --- /dev/null +++ b/edi_scratch/acq.bugs @@ -0,0 +1,24 @@ + +Every LID needs a Fund. Interface doesn't enforce this. + +When the interface intends to make you cancel rather than "X" a LID (because the PO is active) +you can still delete LIDs by changing the Item Count and clicking "Go". + +LID Save Changes: when it works quickly, you have no idea that it succeeded. Especially if you +are conditioned to eternally hung progress bars. + +Upload MARC file for acq: hangs. + +No chrome package registered for chrome://open_ils_staff_client/js/dojo/dojo/dojo.js +No chrome package registered for chrome://extensiondev/content/rdfhistory.js +No chrome package registered for chrome://extensiondev/content/chromeShellExtras.js + +Error: buildGrid is not defined +Source File: http://dev-vm7.lan.hq.esilibrary.com/js/ui/default/vandelay/vandelay.js +Line: 1325 + +Error: list[i].toHash is not a function +Source File: http://dev-vm7.lan.hq.esilibrary.com/js/dojo/dojo/dojo.js +Line: 71 + +Title of tab for /eg/vandelay/vandelay is "Server Settings" (not "MARC Import/Export") as in FF. diff --git a/edi_scratch/baker_taylor.ordrsp.edi b/edi_scratch/baker_taylor.ordrsp.edi new file mode 100644 index 000000000..c1c3e456c --- /dev/null +++ b/edi_scratch/baker_taylor.ordrsp.edi @@ -0,0 +1 @@ +UNA:+.? 'UNB+UNOC:3+1556150:31B+123EVER:31B+100622:1004+03'UNG+ORDRSP+1556150:31B+123EVER:31B+100622:1004+38+UN+D 'UNH+03+ORDRSP:D:96A:UN'BGM+231+071678+29+AC'DTM+137:20100622:102'RFF+ON:8'NAD+BY+123EVER::9'NAD+BY+123EVER 0001::91'CUX+2:USD:9'LIN+1+5+9780446360272:EN'IMD+F+BST+:::NOT APPLIC WEBSTERS NEW WORLD THESA'QTY+21:10'QTY+12:10'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:4.5::SRP'RFF+LI:8/1'LIN+2+5+9780446357197:EN'IMD+F+BST+:::COLLINS, J WORLD IS FULL OF DIVORCE'QTY+21:8'QTY+12:8'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.5::SRP'RFF+LI:8/2'LIN+3+5+9780446350105:EN'IMD+F+BST+:::SHELDON, S WINDMILLS OF THE GODS'QTY+21:5'QTY+12:5'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.99::SRP'RFF+LI:8/3'UNS+S'CNT+2:3'UNT+34+03'UNE+1+38'UNZ+1+03' \ No newline at end of file diff --git a/edi_scratch/baker_taylor.ordrsp.edi.split b/edi_scratch/baker_taylor.ordrsp.edi.split new file mode 100644 index 000000000..91eb8b730 --- /dev/null +++ b/edi_scratch/baker_taylor.ordrsp.edi.split @@ -0,0 +1,41 @@ +UNA:+.? ' +UNB+UNOC:3+1556150:31B+123EVER:31B+100622:1004+03' +UNG+ORDRSP+1556150:31B+123EVER:31B+100622:1004+38+UN+D ' +UNH+03+ORDRSP:D:96A:UN' +BGM+231+071678+29+AC' +DTM+137:20100622:102' +RFF+ON:8' +NAD+BY+123EVER::9' +NAD+BY+123EVER 0001::91' +CUX+2:USD:9' +LIN+1+5+9780446360272:EN' +IMD+F+BST+:::NOT APPLIC WEBSTERS NEW WORLD THESA' +QTY+21:10' +QTY+12:10' +QTY+85:0' +FTX+LIN++01:8B:28' +PRI+AAB:4.5::SRP' +RFF+LI:8/1' +LIN+2+5+9780446357197:EN' +IMD+F+BST+:::COLLINS, J WORLD IS FULL OF DIVORCE' +QTY+21:8' +QTY+12:8' +QTY+85:0' +FTX+LIN++01:8B:28' +PRI+AAB:6.5::SRP' +RFF+LI:8/2' +LIN+3+5+9780446350105:EN' +IMD+F+BST+:::SHELDON, S WINDMILLS OF THE GODS' +QTY+21:5' +QTY+12:5' +QTY+85:0' +FTX+LIN++01:8B:28' +PRI+AAB:6.99::SRP' +RFF+LI:8/3' +UNS+S' +CNT+2:3' +UNT+34+03' +UNE+1+38' +UNZ+1+03' +====================================================================== + diff --git a/edi_scratch/baker_taylor.ordrsp.edi2 b/edi_scratch/baker_taylor.ordrsp.edi2 new file mode 100644 index 000000000..f47b935dd --- /dev/null +++ b/edi_scratch/baker_taylor.ordrsp.edi2 @@ -0,0 +1 @@ +UNA:+.? 'UNB+UNOC:3+1556150:31B+123EVER:31B+100707:0941+05'UNG+ORDRSP+1556150:31B+123EVER:31B+100707:0941+40+UN+D:96A:UN'UNH+05+ORDRSP:D:96A:UN'BGM+231+071681+29+AC'DTM+137:20100622:102'RFF+ON:8'NAD+BY+123EVER::9'NAD+SU+1556150::9'NAD+BY+123EVER 0001::91'CUX+2:USD:9'LIN+1+5+9780446360272:EN'IMD+F+BST+:::NOT APPLIC WEBSTERS NEW WORLD THESA'QTY+21:10'QTY+12:10'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:4.5::SRP'RFF+LI:8/1'LIN+2+5+9780446357197:EN'IMD+F+BST+:::COLLINS, J WORLD IS FULL OF DIVORCE'QTY+21:8'QTY+12:8'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.5::SRP'RFF+LI:8/2'LIN+3+5+9780446350105:EN'IMD+F+BST+:::SHELDON, S WINDMILLS OF THE GODS'QTY+21:5'QTY+12:5'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.99::SRP'RFF+LI:8/3'UNS+S'CNT+2:3'UNT+35+05'UNE+1+40'UNZ+1+05' \ No newline at end of file diff --git a/edi_scratch/baker_taylor.ordrsp.jedi b/edi_scratch/baker_taylor.ordrsp.jedi new file mode 100644 index 000000000..5abb95100 --- /dev/null +++ b/edi_scratch/baker_taylor.ordrsp.jedi @@ -0,0 +1,453 @@ +UNA:+.? 'UNB+UNOC:3+1556150:31B+123EVER:31B+100622:1004+03'UNG+ORDRSP+1556150:31B+123EVER:31B+100622:1004+38+UN+D 'UNH+03+ORDRSP:D:96A:UN'BGM+231+071678+29+AC'DTM+137:20100622:102'RFF+ON:8'NAD+BY+123EVER::9'NAD+BY+123EVER 0001::91'CUX+2:USD:9'LIN+1+5+9780446360272:EN'IMD+F+BST+:::NOT APPLIC WEBSTERS NEW WORLD THESA'QTY+21:10'QTY+12:10'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:4.5::SRP'RFF+LI:8/1'LIN+2+5+9780446357197:EN'IMD+F+BST+:::COLLINS, J WORLD IS FULL OF DIVORCE'QTY+21:8'QTY+12:8'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.5::SRP'RFF+LI:8/2'LIN+3+5+9780446350105:EN'IMD+F+BST+:::SHELDON, S WINDMILLS OF THE GODS'QTY+21:5'QTY+12:5'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.99::SRP'RFF+LI:8/3'UNS+S'CNT+2:3'UNT+34+03'UNE+1+38'UNZ+1+03' + +# edi2json Response: +$VAR1 = { + 'body' => [ + { + 'ORDRSP' => [ + [ + 'UNH', + { + '0062' => '03', + 'S009' => { + '0051' => 'UN', + '0052' => 'D', + '0065' => 'ORDRSP', + '0054' => '96A' + } + } + ], + [ + 'BGM', + { + '1004' => '071678', + '4343' => 'AC', + '1225' => '29', + 'C002' => { + '1001' => '231' + } + } + ], + [ + 'DTM', + { + 'C507' => { + '2005' => '137', + '2379' => '102', + '2380' => '20100622' + } + } + ], + [ + 'SG1', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8', + '1153' => 'ON' + } + } + ] + ] + ], + [ + 'SG3', + [ + [ + 'NAD', + { + 'C082' => { + '3039' => '123EVER', + '3055' => '9' + }, + '3035' => 'BY' + } + ] + ] + ], + [ + 'SG3', + [ + [ + 'NAD', + { + 'C082' => { + '3039' => '123EVER 0001', + '3055' => '91' + }, + '3035' => 'BY' + } + ] + ] + ], + [ + 'SG8', + [ + [ + 'CUX', + { + 'C504' => [ + { + '6345' => 'USD', + '6343' => '9', + '6347' => '2' + } + ] + } + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 1, + 'C212' => { + '7140' => '9780446360272', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'NOT APPLIC WEBSTERS NEW WORLD THESA' + ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 10 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 10 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '4.5', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/1', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 2, + 'C212' => { + '7140' => '9780446357197', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'COLLINS, J WORLD IS FULL OF DIVORCE' + ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 8 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 8 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '6.5', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/2', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 3, + 'C212' => { + '7140' => '9780446350105', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'SHELDON, S WINDMILLS OF THE GODS' + ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 5 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 5 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '6.99', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/3', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ + 'UNS', + { + '0081' => 'S' + } + ], + [ + 'CNT', + { + 'C270' => { + '6066' => 3, + '6069' => '2' + } + } + ], + [ + 'UNT', + { + '0062' => '03', + '0074' => 34 + } + ] + ] + } + ], + 'trailer' => [ + 'UNZ', + { + '0036' => 1, + '0020' => '03' + } + ], + 'recipient' => '123EVER', + 'sender' => '1556150', + 'recipient_qual' => '31B', + 'sender_qual' => '31B', + 'UNA' => { + 'ce_sep' => ':', + 'decimal_sign' => '.', + 'de_sep' => '+', + 'seg_term' => '\'', + 'rep_sep' => ' ', + 'esc_char' => '?' + }, + 'header' => [ + 'UNB', + { + 'S003' => { + '0007' => '31B', + '0010' => '123EVER' + }, + 'S004' => { + '0017' => 100622, + '0019' => 1004 + }, + 'S001' => { + '0002' => 3, + '0001' => 'UNOC' + }, + 'S002' => { + '0004' => '1556150', + '0007' => '31B' + }, + '0020' => '03' + } + ] +}; diff --git a/edi_scratch/baker_taylor.ordrsp.jedi.pl b/edi_scratch/baker_taylor.ordrsp.jedi.pl new file mode 100644 index 000000000..6e2c62e87 --- /dev/null +++ b/edi_scratch/baker_taylor.ordrsp.jedi.pl @@ -0,0 +1,457 @@ +=doc + +UNA:+.? 'UNB+UNOC:3+1556150:31B+123EVER:31B+100622:1004+03'UNG+ORDRSP+1556150:31B+123EVER:31B+100622:1004+38+UN+D 'UNH+03+ORDRSP:D:96A:UN'BGM+231+071678+29+AC'DTM+137:20100622:102'RFF+ON:8'NAD+BY+123EVER::9'NAD+BY+123EVER 0001::91'CUX+2:USD:9'LIN+1+5+9780446360272:EN'IMD+F+BST+:::NOT APPLIC WEBSTERS NEW WORLD THESA'QTY+21:10'QTY+12:10'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:4.5::SRP'RFF+LI:8/1'LIN+2+5+9780446357197:EN'IMD+F+BST+:::COLLINS, J WORLD IS FULL OF DIVORCE'QTY+21:8'QTY+12:8'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.5::SRP'RFF+LI:8/2'LIN+3+5+9780446350105:EN'IMD+F+BST+:::SHELDON, S WINDMILLS OF THE GODS'QTY+21:5'QTY+12:5'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.99::SRP'RFF+LI:8/3'UNS+S'CNT+2:3'UNT+34+03'UNE+1+38'UNZ+1+03' + +=cut + +# edi2json Response: +$VAR1 = { + 'body' => [ + { + 'ORDRSP' => [ + [ + 'UNH', + { + '0062' => '03', + 'S009' => { + '0051' => 'UN', + '0052' => 'D', + '0065' => 'ORDRSP', + '0054' => '96A' + } + } + ], + [ + 'BGM', + { + '1004' => '071678', + '4343' => 'AC', + '1225' => '29', + 'C002' => { + '1001' => '231' + } + } + ], + [ + 'DTM', + { + 'C507' => { + '2005' => '137', + '2379' => '102', + '2380' => '20100622' + } + } + ], + [ + 'SG1', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8', + '1153' => 'ON' + } + } + ] + ] + ], + [ + 'SG3', + [ + [ + 'NAD', + { + 'C082' => { + '3039' => '123EVER', + '3055' => '9' + }, + '3035' => 'BY' + } + ] + ] + ], + [ + 'SG3', + [ + [ + 'NAD', + { + 'C082' => { + '3039' => '123EVER 0001', + '3055' => '91' + }, + '3035' => 'BY' + } + ] + ] + ], + [ + 'SG8', + [ + [ + 'CUX', + { + 'C504' => [ + { + '6345' => 'USD', + '6343' => '9', + '6347' => '2' + } + ] + } + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 1, + 'C212' => { + '7140' => '9780446360272', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'NOT APPLIC WEBSTERS NEW WORLD THESA' + ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 10 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 10 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '4.5', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/1', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 2, + 'C212' => { + '7140' => '9780446357197', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'COLLINS, J WORLD IS FULL OF DIVORCE' + ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 8 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 8 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '6.5', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/2', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 3, + 'C212' => { + '7140' => '9780446350105', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'SHELDON, S WINDMILLS OF THE GODS' + ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 5 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 5 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '6.99', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/3', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ + 'UNS', + { + '0081' => 'S' + } + ], + [ + 'CNT', + { + 'C270' => { + '6066' => 3, + '6069' => '2' + } + } + ], + [ + 'UNT', + { + '0062' => '03', + '0074' => 34 + } + ] + ] + } + ], + 'trailer' => [ + 'UNZ', + { + '0036' => 1, + '0020' => '03' + } + ], + 'recipient' => '123EVER', + 'sender' => '1556150', + 'recipient_qual' => '31B', + 'sender_qual' => '31B', + 'UNA' => { + 'ce_sep' => ':', + 'decimal_sign' => '.', + 'de_sep' => '+', + 'seg_term' => '\'', + 'rep_sep' => ' ', + 'esc_char' => '?' + }, + 'header' => [ + 'UNB', + { + 'S003' => { + '0007' => '31B', + '0010' => '123EVER' + }, + 'S004' => { + '0017' => 100622, + '0019' => 1004 + }, + 'S001' => { + '0002' => 3, + '0001' => 'UNOC' + }, + 'S002' => { + '0004' => '1556150', + '0007' => '31B' + }, + '0020' => '03' + } + ] +}; diff --git a/edi_scratch/baker_taylor.ordrsp.jedi.tidy.pl b/edi_scratch/baker_taylor.ordrsp.jedi.tidy.pl new file mode 100644 index 000000000..f3b2fd9b2 --- /dev/null +++ b/edi_scratch/baker_taylor.ordrsp.jedi.tidy.pl @@ -0,0 +1,448 @@ + +=doc + +UNA:+.? 'UNB+UNOC:3+1556150:31B+123EVER:31B+100622:1004+03'UNG+ORDRSP+1556150:31B+123EVER:31B+100622:1004+38+UN+D 'UNH+03+ORDRSP:D:96A:UN'BGM+231+071678+29+AC'DTM+137:20100622:102'RFF+ON:8'NAD+BY+123EVER::9'NAD+BY+123EVER 0001::91'CUX+2:USD:9'LIN+1+5+9780446360272:EN'IMD+F+BST+:::NOT APPLIC WEBSTERS NEW WORLD THESA'QTY+21:10'QTY+12:10'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:4.5::SRP'RFF+LI:8/1'LIN+2+5+9780446357197:EN'IMD+F+BST+:::COLLINS, J WORLD IS FULL OF DIVORCE'QTY+21:8'QTY+12:8'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.5::SRP'RFF+LI:8/2'LIN+3+5+9780446350105:EN'IMD+F+BST+:::SHELDON, S WINDMILLS OF THE GODS'QTY+21:5'QTY+12:5'QTY+85:0'FTX+LIN++01:8B:28'PRI+AAB:6.99::SRP'RFF+LI:8/3'UNS+S'CNT+2:3'UNT+34+03'UNE+1+38'UNZ+1+03' + +=cut + +# edi2json Response: +$VAR1 = { + 'body' => [ + { + 'ORDRSP' => [ + [ + 'UNH', + { + '0062' => '03', + 'S009' => { + '0051' => 'UN', + '0052' => 'D', + '0065' => 'ORDRSP', + '0054' => '96A' + } + } + ], + [ + 'BGM', + { + '1004' => '071678', + '4343' => 'AC', + '1225' => '29', + 'C002' => { '1001' => '231' } + } + ], + [ + 'DTM', + { + 'C507' => { + '2005' => '137', + '2379' => '102', + '2380' => '20100622' + } + } + ], + [ + 'SG1', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8', + '1153' => 'ON' + } + } + ] + ] + ], + [ + 'SG3', + [ + [ + 'NAD', + { + 'C082' => { + '3039' => '123EVER', + '3055' => '9' + }, + '3035' => 'BY' + } + ] + ] + ], + [ + 'SG3', + [ + [ + 'NAD', + { + 'C082' => { + '3039' => '123EVER 0001', + '3055' => '91' + }, + '3035' => 'BY' + } + ] + ] + ], + [ + 'SG8', + [ + [ + 'CUX', + { + 'C504' => [ + { + '6345' => 'USD', + '6343' => '9', + '6347' => '2' + } + ] + } + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 1, + 'C212' => { + '7140' => '9780446360272', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => + [ 'NOT APPLIC WEBSTERS NEW WORLD THESA' ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 10 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 10 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '4.5', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/1', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 2, + 'C212' => { + '7140' => '9780446357197', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => + [ 'COLLINS, J WORLD IS FULL OF DIVORCE' ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 8 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 8 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '6.5', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/2', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ + 'SG26', + [ + [ + 'LIN', + { + '1229' => '5', + '1082' => 3, + 'C212' => { + '7140' => '9780446350105', + '7143' => 'EN' + } + } + ], + [ + 'IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => + [ 'SHELDON, S WINDMILLS OF THE GODS' ] + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 5 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 5 + } + } + ], + [ + 'QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + [ + 'FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + [ + 'SG30', + [ + [ + 'PRI', + { + 'C509' => { + '5118' => '6.99', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + [ + 'SG31', + [ + [ + 'RFF', + { + 'C506' => { + '1154' => '8/3', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + [ 'UNS', { '0081' => 'S' } ], + [ + 'CNT', + { + 'C270' => { + '6066' => 3, + '6069' => '2' + } + } + ], + [ + 'UNT', + { + '0062' => '03', + '0074' => 34 + } + ] + ] + } + ], + 'trailer' => [ + 'UNZ', + { + '0036' => 1, + '0020' => '03' + } + ], + 'recipient' => '123EVER', + 'sender' => '1556150', + 'recipient_qual' => '31B', + 'sender_qual' => '31B', + 'UNA' => { + 'ce_sep' => ':', + 'decimal_sign' => '.', + 'de_sep' => '+', + 'seg_term' => '\'', + 'rep_sep' => ' ', + 'esc_char' => '?' + }, + 'header' => [ + 'UNB', + { + 'S003' => { + '0007' => '31B', + '0010' => '123EVER' + }, + 'S004' => { + '0017' => 100622, + '0019' => 1004 + }, + 'S001' => { + '0002' => 3, + '0001' => 'UNOC' + }, + 'S002' => { + '0004' => '1556150', + '0007' => '31B' + }, + '0020' => '03' + } + ] +}; diff --git a/edi_scratch/baker_taylor.ordrsp.jedi2 b/edi_scratch/baker_taylor.ordrsp.jedi2 new file mode 100644 index 000000000..ddf0fe310 --- /dev/null +++ b/edi_scratch/baker_taylor.ordrsp.jedi2 @@ -0,0 +1,406 @@ +// ID: 338 + +done +$VAR1 = { + 'body' => [ + { + 'ORDRSP' => [ + ['UNH', + { + '0062' => '05', + 'S009' => { + '0051' => 'UN', + '0052' => 'D', + '0065' => 'ORDRSP', + '0054' => '96A' + } + } + ], + ['BGM', + { + '1004' => '071681', + '4343' => 'AC', + '1225' => '29', + 'C002' => { + '1001' => '231' + } + } + ], + ['DTM', + { + 'C507' => { + '2005' => '137', + '2379' => '102', + '2380' => '20100622' + } + } + ], + ['SG1', + [['RFF', + { + 'C506' => { + '1154' => '8', + '1153' => 'ON' + } + } + ] + ] + ], + ['SG3', + [['NAD', + { + 'C082' => { + '3039' => '123EVER', + '3055' => '9' + }, + '3035' => 'BY' + } + ] + ] + ], + ['SG3', + [['NAD', + { + 'C082' => { + '3039' => '1556150', + '3055' => '9' + }, + '3035' => 'SU' + } + ] + ] + ], + ['SG3', + [['NAD', + { + 'C082' => { + '3039' => '123EVER 0001', + '3055' => '91' + }, + '3035' => 'BY' + } + ] + ] + ], + ['SG8', + [['CUX', + { + 'C504' => [ + { + '6345' => 'USD', + '6343' => '9', + '6347' => '2' + } + ] + } + ] + ] + ], + ['SG26', + [['LIN', + { + '1229' => '5', + '1082' => 1, + 'C212' => { + '7140' => '9780446360272', + '7143' => 'EN' + } + } + ], + ['IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'NOT APPLIC WEBSTERS NEW WORLD THESA' + ] + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 10 + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 10 + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + ['FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + ['SG30', + [['PRI', + { + 'C509' => { + '5118' => '4.5', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + ['SG31', + [['RFF', + { + 'C506' => { + '1154' => '8/1', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + ['SG26', + [['LIN', + { + '1229' => '5', + '1082' => 2, + 'C212' => { + '7140' => '9780446357197', + '7143' => 'EN' + } + } + ], + ['IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'COLLINS, J WORLD IS FULL OF DIVORCE' + ] + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 8 + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 8 + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + ['FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + ['SG30', + [['PRI', + { + 'C509' => { + '5118' => '6.5', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + ['SG31', + [['RFF', + { + 'C506' => { + '1154' => '8/2', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + ['SG26', + [['LIN', + { + '1229' => '5', + '1082' => 3, + 'C212' => { + '7140' => '9780446350105', + '7143' => 'EN' + } + } + ], + ['IMD', + { + '7081' => 'BST', + '7077' => 'F', + 'C273' => { + '7008' => [ + 'SHELDON, S WINDMILLS OF THE GODS' + ] + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '21', + '6060' => 5 + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '12', + '6060' => 5 + } + } + ], + ['QTY', + { + 'C186' => { + '6063' => '85', + '6060' => 0 + } + } + ], + ['FTX', + { + '4451' => 'LIN', + 'C107' => { + '4441' => '01', + '3055' => '28', + '1131' => '8B' + } + } + ], + ['SG30', + [['PRI', + { + 'C509' => { + '5118' => '6.99', + '5387' => 'SRP', + '5125' => 'AAB' + } + } + ] + ] + ], + ['SG31', + [['RFF', + { + 'C506' => { + '1154' => '8/3', + '1153' => 'LI' + } + } + ] + ] + ] + ] + ], + ['UNS', + { + '0081' => 'S' + } + ], + ['CNT', + { + 'C270' => { + '6066' => 3, + '6069' => '2' + } + } + ], + ['UNT', + { + '0062' => '05', + '0074' => 35 + } + ] + ] + } + ], + 'trailer' => [ + 'UNZ', + { + '0036' => 1, + '0020' => '05' + } + ], + 'recipient' => '123EVER', + 'sender' => '1556150', + 'recipient_qual' => '31B', + 'sender_qual' => '31B', + 'UNA' => { + 'ce_sep' => ':', + 'decimal_sign' => '.', + 'de_sep' => '+', + 'seg_term' => '\'', + 'rep_sep' => ' ', + 'esc_char' => '?' + }, + 'header' => [ + 'UNB', + { + 'S003' => { + '0007' => '31B', + '0010' => '123EVER' + }, + 'S004' => { + '0017' => 100707, + '0019' => 941 + }, + 'S001' => { + '0002' => 3, + '0001' => 'UNOC' + }, + 'S002' => { + '0004' => '1556150', + '0007' => '31B' + }, + '0020' => '05' + } + ] +}; + diff --git a/edi_scratch/brodart_001_edi.tst b/edi_scratch/brodart_001_edi.tst new file mode 100644 index 000000000..62f5ebdc0 --- /dev/null +++ b/edi_scratch/brodart_001_edi.tst @@ -0,0 +1 @@ +UNA:+.? 'UNB+UNOB:3+9999867:31B+1697684:31B+100811:1927+1'UNH+1+ORDERS:D:96A:UN'BGM+220+15+9'DTM+137:20100811:102'NAD+BY+9999867 0001::91'NAD+SU+1697684::31B'NAD+SU+7::92'CUX+2:USD:9'LIN+81++0743294394:IB'PIA+5+0743294394:IB+81:SA'IMD+F+BTI+:::206 BONES'IMD+F+BPU+:::Scribner'IMD+F+BPD+:::2009-08-01'QTY+21:4'PRI+AAB:0'RFF+LI:15/81'LIN+80++1598883275:IB'PIA+5+1598883275:IB+80:SA'IMD+F+BTI+:::COUNTY AND CITY EXTRA'IMD+F+BPU+:::Bernan Press'IMD+F+BPD+:::2009-07-01'QTY+21:4'PRI+AAB:0'RFF+LI:15/80'LIN+79++1590203097:IB'PIA+5+1590203097:IB+79:SA'IMD+F+BTI+:::2017'IMD+F+BPU+:::Overlook Pr'IMD+F+BPD+:::2010-03-01'QTY+21:4'PRI+AAB:0'RFF+LI:15/79'LIN+78++1598884093:IB'PIA+5+1598884093:IB+78:SA'IMD+F+BTI+:::COUNTY AND CITY EXTRA'IMD+F+BPU+:::Bernan Press'IMD+F+BPD+:::2010-07-01'QTY+21:4'PRI+AAB:0'RFF+LI:15/78'UNS+S'CNT+2:4'UNT+42+1'UNZ+1+1' diff --git a/edi_scratch/edi_splitter.pl b/edi_scratch/edi_splitter.pl new file mode 100755 index 000000000..354bd6bb6 --- /dev/null +++ b/edi_scratch/edi_splitter.pl @@ -0,0 +1,26 @@ +#!/usr/bin/perl +# +# +# Purpose here is to break up EDI messages to make them more readable +# (i.e., not all on one line). +# + +use warnings; +use strict; + + +my @unindented = qw( LIN BGM ); + +my $delim = "'"; +while (my $line = <>) { + foreach (split $delim, $line) { + '+' eq substr($_,3,1) or warn "Line $. missing '+' delimiter as 4th character: $_"; + my $tag = substr($_,0,3) or warn "Line $. Unexpectedly short: $_"; + unless ($tag =~ /^UN\S/ or grep {$_ eq $tag} @unindented) { + print "\t"; + } + print "$_$delim\n"; + } + print '=' x 70, "\n\n"; +} + diff --git a/edi_scratch/ftx_test.jedi b/edi_scratch/ftx_test.jedi new file mode 100644 index 000000000..5eeac4106 --- /dev/null +++ b/edi_scratch/ftx_test.jedi @@ -0,0 +1,69 @@ + + { + "recipient":"1556150", + "sender":"6666666", + "body": [{ + "ORDERS":[ "order", { + "po_number":8, + "date":"20100610", + "buyer":[{ "id":"6666666" }], + "vendor":[ "1556150", + {"id-qualifier": 92, "id":"8"} + ], + "currency":"USD", + "items":[ + + { + "identifiers":[ + {"id-qualifier":"EN","id":"9780446360272"}, + {"id-qualifier":"SA","id":"57"}, + {"id-qualifier":"IB","id":"0446360279"} + ], + "price":4.50, + "desc":[ + {"BTI":"Webster's new world thesaurus :"}, + {"BPU":"Warner Books, Inc.,"}, + {"BPD":"1990."}, + {"BPH":"xv, 494 p. ;"} + ], + "quantity":8, + // "FTX":[ { "4451": "LIN", "C108": {"4440": "This is a TEST! zzz!"} } ] + "FTX": { "4451": "LIN", "C108": {"4440": "This is a TEST! zzz!"} } + }, + { + "identifiers":[ + {"id-qualifier":"SA","id":"59"}, + {"id-qualifier":"IB","id":"0446831832"}, + {"id-qualifier":"EN","id":"9780446357197"} + ], + "price":7.99, + "desc":[ + {"BTI":"The world is full of divorced women /"}, + {"BPU":"Warner Books,"}, + {"BPD":"c1980."}, + {"BPH":"413 p. ;"} + ], + "quantity":10 + }, + { + "identifiers":[ + {"id-qualifier":"SA","id":"60"}, + {"id-qualifier":"IB","id":"0446350109"}, + {"id-qualifier":"EN","id":"9780446350105"} + ], + "price":8.75, + "desc":[ + {"BTI":"Windmills of the gods /"}, + {"BPU":"Warner Books,"}, + {"BPD":"1988, c1987."}, + {"BPH":"xiii, 434 p. ;"} + ], + "quantity":5 + } + ], + "line_items":3 + }] + }] + } + + diff --git a/edi_scratch/ftx_test.output b/edi_scratch/ftx_test.output new file mode 100644 index 000000000..eb260fe00 --- /dev/null +++ b/edi_scratch/ftx_test.output @@ -0,0 +1,70 @@ + { + "recipient":"1556150", + "sender":"6666666", + "body": [{ + "ORDERS":[ "order", { + "po_number":8, + "date":"20100610", + "buyer":[{ "id":"6666666" }], + "vendor":[ "1556150", + {"id-qualifier": 92, "id":"8"} + ], + "currency":"USD", + "items":[ + + { + "identifiers":[ + {"id-qualifier":"EN","id":"9780446360272"}, + {"id-qualifier":"SA","id":"57"}, + {"id-qualifier":"IB","id":"0446360279"} + ], + "price":4.50, + "desc":[ + {"BTI":"Webster's new world thesaurus :"}, + {"BPU":"Warner Books, Inc.,"}, + {"BPD":"1990."}, + {"BPH":"xv, 494 p. ;"} + ], + "quantity":8, + "FTX": { "4451": "LIN", "C108": {"4440": "This is a TEST! zzz!"} } + }, + { + "identifiers":[ + {"id-qualifier":"SA","id":"59"}, + {"id-qualifier":"IB","id":"0446831832"}, + {"id-qualifier":"EN","id":"9780446357197"} + ], + "price":7.99, + "desc":[ + {"BTI":"The world is full of divorced women /"}, + {"BPU":"Warner Books,"}, + {"BPD":"c1980."}, + {"BPH":"413 p. ;"} + ], + "quantity":10 + }, + { + "identifiers":[ + {"id-qualifier":"SA","id":"60"}, + {"id-qualifier":"IB","id":"0446350109"}, + {"id-qualifier":"EN","id":"9780446350105"} + ], + "price":8.75, + "desc":[ + {"BTI":"Windmills of the gods /"}, + {"BPU":"Warner Books,"}, + {"BPD":"1988, c1987."}, + {"BPH":"xiii, 434 p. ;"} + ], + "quantity":5 + } + ], + "line_items":3 + }] + }] + } + + + +# json2edi Response: +$VAR1 = bless( do{\(my $o = 'UNA:+.? \'UNB+UNOB:3+6666666:31B+1556150:31B+100812:2026+1\'UNH+1+ORDERS:D:96A:UN\'BGM+220+8+9\'DTM+137:20100610:102\'NAD+BY+6666666::31B\'NAD+SU+1556150::31B\'NAD+SU+8::92\'CUX+2:USD:9\'LIN+1++9780446360272:EN\'PIA+5+9780446360272:EN+57:SA+0446360279:IB\'IMD+F+BTI+:::Webster?\'s new world thesaurus ?:\'IMD+F+BPU+:::Warner Books, Inc.,\'IMD+F+BPD+:::1990.\'IMD+F+BPH+:::xv, 494 p. ;\'QTY+21:8\'PRI+AAB:4.5\'RFF+LI:8/1\'LIN+2++59:SA\'PIA+5+59:SA+0446831832:IB+9780446357197:EN\'IMD+F+BTI+:::The world is full of divorced women: /\'IMD+F+BPU+:::Warner Books,\'IMD+F+BPD+:::c1980.\'IMD+F+BPH+:::413 p. ;\'QTY+21:10\'PRI+AAB:7.99\'RFF+LI:8/2\'LIN+3++60:SA\'PIA+5+60:SA+0446350109:IB+9780446350105:EN\'IMD+F+BTI+:::Windmills of the gods /\'IMD+F+BPU+:::Warner Books,\'IMD+F+BPD+:::1988, c1987.\'IMD+F+BPH+:::xiii, 434 p. ;\'QTY+21:5\'PRI+AAB:8.75\'RFF+LI:8/3\'UNS+S\'CNT+2:3\'UNT+37+1\'UNZ+1+1\'')}, 'RPC::XML::string' ); diff --git a/edi_scratch/ruby_json2edi.orders b/edi_scratch/ruby_json2edi.orders new file mode 100644 index 000000000..c8fd174da --- /dev/null +++ b/edi_scratch/ruby_json2edi.orders @@ -0,0 +1,75 @@ + +{ + "recipient":"1556150", + "sender":"6666666", + "body": [{ + "ORDERS":[ "order", { + "po_number":8, + "date":"20100621", + "buyer":[{ "id":"6666666 0001", + "id-qualifier": 91 }], + "vendor":[ "1556150", + {"id-qualifier": 92, "id":"8"} + ], + "currency":"USD", + "items":[ + + { + "identifiers":[ + {"id-qualifier":"EN","id":"9780446360272"}, + + {"id-qualifier":"IB","id":"0446360279"}, + + {"id-qualifier":"SA","id":"57"} + ], + "price":4.50, + "desc":[ + {"BTI":"Webster's new world thesaurus :"}, + {"BPU":"Warner Books, Inc.,"}, + {"BPD":"1990."}, + {"BPH":"xv, 494 p. ;"} + ], + "quantity":10 + }, + { + "identifiers":[ + {"id-qualifier":"EN","id":"9780446357197"}, + + {"id-qualifier":"IB","id":"0446357197"}, + {"id-qualifier":"IB","id":"0446831832"}, + {"id-qualifier":"EN","id":"9780446831833"}, + + + {"id-qualifier":"SA","id":"59"} + ], + "price":7.99, + "desc":[ + {"BTI":"The world is full of divorced women /"}, + {"BPU":"Warner Books,"}, + {"BPD":"c1980."}, + {"BPH":"413 p. ;"} + ], + "quantity":8 + }, + { + "identifiers":[ + {"id-qualifier":"EN","id":"9780446350105"}, + + {"id-qualifier":"IB","id":"0446350109"}, + + {"id-qualifier":"SA","id":"60"} + ], + "price":8.75, + "desc":[ + {"BTI":"Windmills of the gods /"}, + {"BPU":"Warner Books,"}, + {"BPD":"1988, c1987."}, + {"BPH":"xiii, 434 p. ;"} + ], + "quantity":5 + } + ], + "line_items":3 + }] + }] +} diff --git a/edi_scratch/zBFqgVwJ7l.orders.edi b/edi_scratch/zBFqgVwJ7l.orders.edi new file mode 100644 index 000000000..db1d954fa --- /dev/null +++ b/edi_scratch/zBFqgVwJ7l.orders.edi @@ -0,0 +1 @@ +UNA:+.? 'UNB+UNOB:3+123EVER:31B+1556150:31B+100804:1504+1'UNH+1+ORDERS:D:96A:UN'BGM+220+9+9'DTM+137:20100804:102'NAD+BY+123EVER 0001::91'NAD+SU+1556150::31B'NAD+SU+8::92'CUX+2:USD:9'LIN+61++9787777777777:EN'PIA+5+9787777777777:EN+61:SA'IMD+F+BTI+:::Fake Book'QTY+21:3'PRI+AAB:5'RFF+LI:9/61'LIN+63++9781591430476:EN'PIA+5+9781591430476:EN+159143047X:IB+63:SA'IMD+F+BTI+:::Merlin and the discovery of Avalon :in the New World /'IMD+F+BPU+:::Bear & Co.,'IMD+F+BPD+:::c2005.'IMD+F+BPH+:::vi, 231, [14] p. of plates ?:'QTY+21:5'PRI+AAB:7'RFF+LI:9/63'LIN+62++9780446310062:EN'PIA+5+9780446310062:EN+0446310069:IB+0446313033:IB+9780446313032:EN+0446314129:IB'PIA+5+9780446314121:EN+62:SA'IMD+F+BTI+:::Shroud for a nightingale /'IMD+F+BPU+:::Warner Books,'IMD+F+BPD+:::1982, c1971.'IMD+F+BPH+:::287 p. ;'QTY+21:10'PRI+AAB:8'RFF+LI:9/62'UNS+S'CNT+2:3'UNT+35+1'UNZ+1+1'