-
When using the SDK these fields are generated in the physical model as follows And they should be generated as follows: When validating the generated XML with the SDK, it gives the following error: See below the full error:\n[{"line":51,"column":45,"message":"cvc-complex-type.2.4.a: Invalid content was found starting with element '{\"urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2\":NoticeTypeCode}'. One of '{\"urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2\":NoticeLanguageCode, \"urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2\":AdditionalNoticeLanguage, \"urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2\":DocumentReference, \"urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2\":Signature, \"urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2\":ContractingParty}' is expected."}, Thanks in advance |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Although it has code list with id "notice-type" and "form-type" (i believe this is how you get those elements at the end) and i agreee with you, well it is what it is. Lets take a look in to it. "id" : "BT-02-notice", "id" : "BT-03-notice", Another example but different (little bit) Anyway watch out its not so unique. this behaviour is also for example for but look at this for example. They are same but different in definition. Unfortunately there are many of those inconstinaces. There are multiple, i call it patterns, to recognize what to do with field itself. If its value, if its value of attribute if its value but subchild has this or that attribute, and so on. Good is, its not so difficult how it looks like on first sight and its manageable with not so complex logic even there are many inconstances (so far they are manageable) |
Beta Was this translation helpful? Give feedback.
Although it has code list with id "notice-type" and "form-type" (i believe this is how you get those elements at the end) and i agreee with you, well it is what it is. Lets take a look in to it.
"id" : "BT-02-notice",
"xpathRelative" : "cbc:NoticeTypeCode",
-> Value of Field represent value of element
"id" : "BT-03-notice",
"xpathRelative" : "cbc:NoticeTypeCode/@listname",
-> value of field represent value of attribute.
/@listname represent information about that this field is pure attribute value of element NoticeTypeCode.
Another example but different (little bit)
[cbc:ID/@schemeName='Lot']
Value of Field represent value of element but it has defined attribute schemeName with value Lot.
A…