From 786ba2480dceb046a8e765ea952baf5d5b73d855 Mon Sep 17 00:00:00 2001 From: gftrader Date: Wed, 15 Nov 2017 15:30:46 -0600 Subject: [PATCH] Added a new specification for 850 document for ANSI X12 version 5010. The only real difference between the 4010 version is the addition of an MTX element allowed in an N9 Loop. --- src/OopFactory.X12/OopFactory.X12.csproj | 3 + .../Parsing/SpecificationFinder.cs | 5 + .../Ansi-850-5010Specification.xml | 299 ++++++++++++++++++ 3 files changed, 307 insertions(+) create mode 100644 src/OopFactory.X12/Specifications/Ansi-850-5010Specification.xml diff --git a/src/OopFactory.X12/OopFactory.X12.csproj b/src/OopFactory.X12/OopFactory.X12.csproj index c910f728..a24c3b48 100644 --- a/src/OopFactory.X12/OopFactory.X12.csproj +++ b/src/OopFactory.X12/OopFactory.X12.csproj @@ -676,6 +676,9 @@ + + + diff --git a/src/OopFactory.X12/Parsing/SpecificationFinder.cs b/src/OopFactory.X12/Parsing/SpecificationFinder.cs index e7c3bce3..9d3ae304 100644 --- a/src/OopFactory.X12/Parsing/SpecificationFinder.cs +++ b/src/OopFactory.X12/Parsing/SpecificationFinder.cs @@ -55,6 +55,11 @@ public virtual TransactionSpecification FindTransactionSpec(string functionalCod return GetSpecification("837-5010"); else return GetSpecification("837-4010"); + case "850": + if (versionCode.Contains("5010")) + return GetSpecification("850-5010"); + else + return GetSpecification("850-4010"); case "875": return GetSpecification("875-5010"); case "880": diff --git a/src/OopFactory.X12/Specifications/Ansi-850-5010Specification.xml b/src/OopFactory.X12/Specifications/Ansi-850-5010Specification.xml new file mode 100644 index 00000000..a9202bae --- /dev/null +++ b/src/OopFactory.X12/Specifications/Ansi-850-5010Specification.xml @@ -0,0 +1,299 @@ + + + + + + + + + + + + + + + Service, Promotion, Allowance, or Charg + + + + + + + + + + + + + + + + + + + + + + + + + Service, Promotion, Allowance, or Charge Information + + + + Monetary Amount + + + + + + Type of Financial Accounting Data + + + + + + Reference Identification + + + + + + + Name + + + + + + + + + + + + + + + + + Code Source Information + + + + + Specification Identifier + + + + + + Name + + + + + + + + + + Contract and Cost Accounting Standards + + + + + + + + + + Advertising Demographic Information + + + + + + Baseline Item Data + + + + + + + + Pricing Information + + + + + + + Product/Item Description + + + + + + + + + + Service, Promotion, Allowance, or Charg + + + + + + + + + + + + + + + + + + + + + + + + + + + Quantity + + + + + Line Item Schedule + + + + + + + + + Marking, Packaging, Loading + + + + + Loop Header + + + + Lead Time + + + + + + Code Source Information + + + + + + + Reference Identification + + + + + + + Name + + + + + + + + + + + + + + + + + + + Lead Time + + + + + + + + + Subline Item Detail + + + + + + + + + + + + + + Reference Identification + + + + + + Service, Promotion, Allowance, or Charg + + + + + + Quantity + + + + + Name + + + + + + + + + + + + Monetary Amount + + + + + + Code Source Information + + + + + + Transaction Totals + + + + \ No newline at end of file