You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First of all, thanks for your work and support of the library!
I saw #105 and #121 , which were the basis for the mapping. That being said, I still seem to be missing something.
We're working with X12 850 Purchase Order message, and here's the relevant excerpt
N1*ST*Customer ABC~
N2*Suite 1123~
N3*11111 S. Main Ave.~
N4*New York*NY*10001*USA~
PER*OC*Customer ABC*TE*1234123412*EM*a_customer@example.com~
The focus here is the PER segment, where we have the code, name, then the qualifier and the 'number'.
Now, apart from the TE (telephone) number, we also have an EM email, so that's potentially a repeated element.
Let's try mapping it appropriately
// Majority of this definition is taken from the test sample data mapping for X12 850[EdiSegment][EdiSegmentGroup("N1",SequenceEnd="PO1")]publicclassAddress{[EdiValue(Path="N1/0",Description="N101 - Address Code")]publicstring?AddressCode{get;set;}[EdiValue(Path="N1/1",Description="N102 - Address Name")]publicstring?AddressName{get;set;}[EdiValue(Path="N3/0",Description="N301 - Address Information")]publicstring?AddressInformation{get;set;}[EdiValue(Path="N4/0",Description="N401 - City Name")]publicstring?CityName{get;set;}[EdiValue(Path="N4/3",Description="N404 - Country Code")]publicstring?CountryCode{get;set;}// ------------- up to here// Here's a new propertypublicAdministrativeCommunicationsContactContact{get;set;}}[EdiSegment][EdiPath("PER")]publicclassAdministrativeCommunicationsContact{[EdiValue("X(2)",Path="PER/0")]publicstringContactFunctionCode{get;set;}[EdiValue(Path="PER/1")]publicstring?Name{get;set;}[EdiValue(Path="PER/2..*")]publicList<CommunicationData>CommunicationData{get;set;}}[EdiElement]publicclassCommunicationData{[EdiValue("X(2)",Path="*/*/0")]publicstringQualifier{get;set;}[EdiValue(Path="*/*/1")]publicstringValue{get;set;}}
This is the closest I got to having it work, but it's still not right:
I didn't have the chance to spend more time on it though. Ultimately I ended up post-processing the 'incorrectly' tokenized data into a more suitable shape.
First of all, thanks for your work and support of the library!
I saw #105 and #121 , which were the basis for the mapping. That being said, I still seem to be missing something.
We're working with X12 850 Purchase Order message, and here's the relevant excerpt
The focus here is the
PER
segment, where we have the code, name, then the qualifier and the 'number'.Now, apart from the
TE
(telephone) number, we also have anEM
email, so that's potentially a repeated element.Let's try mapping it appropriately
This is the closest I got to having it work, but it's still not right:
while I'd like to get
Is there anything obvious I'm missing here?
Library version:
1.11.0
The text was updated successfully, but these errors were encountered: