|
|
@ -37,8 +37,14 @@ Use parse-edi within your code base as a library
|
|
|
|
import edi.parser
|
|
|
|
import edi.parser
|
|
|
|
import json
|
|
|
|
import json
|
|
|
|
import os
|
|
|
|
import os
|
|
|
|
ROOT = '/mnt/data/837'
|
|
|
|
|
|
|
|
files = os.listdir(ROOT)
|
|
|
|
|
|
|
|
file = os.sep.join([ROOT,files[0]])
|
|
|
|
ROOT = 'data'
|
|
|
|
conf = json.loads(open('/mnt/data/config/837.json').read())
|
|
|
|
CLAIMS_FOLDER = os.sep.join([ROOT,'837'])
|
|
|
|
info = edi.parser.get_content(file,conf)
|
|
|
|
CONFIG_FOLDER = os.sep.join([ROOT,'config'])
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
files = os.listdir(CLAIMS_FOLDER)
|
|
|
|
|
|
|
|
filename = os.sep.join([ROOT,files[0]]) #-- selecting the first file in the folder (it's an example)
|
|
|
|
|
|
|
|
conf = json.loads(open( os.sep.join([CONFIG_FOLDER,'837.json']) ).read())
|
|
|
|
|
|
|
|
info = edi.parser.get_content(file,conf) #-- array of objects claims/remits
|
|
|
|