Показать сообщение отдельно
Старый 17.08.2015, 17:28   #3  
syl is offline
syl
Участник
Аватар для syl
 
236 / 21 (1) +++
Регистрация: 10.06.2015
Адрес: Киев
Это все делаю, там пишется только "Недопустимый XML-документ". Уже определил что ошибка из за поля AgreementClassification в SalesAgreementHeader (по ссылке расписано более детально). Судя по маппингу туда надо писать Name из AgreementClasification, что я в принципе и делаю, но получаю ошибку. Если же опустить заполнение SalesAgreementHeader, то запись проходит нормально

UPD: XML из журнала
X++:
  <?xml version="1.0" encoding="UTF-8" ?> 
- <CustImportServiceCreateRequest xmlns="http://tempuri.org">
- <CustImport xmlns="http://schemas.microsoft.com/dynamics/2008/01/documents/CustImport">
  <SenderId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
- <CustTableT class="entity">
  <_DocumentHash xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <AccountNum>20957066</AccountNum> 
  <AgencyLocationCode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <AuthorityOffice_IT xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <BankAccount xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <BankCentralBankPurposeCode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <BankCentralBankPurposeText xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <BankCustPaymIdTable xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <BirthCountyCode_IT xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <BirthPlace_IT xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Blocked>No</Blocked> 
  <CashDisc xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CCMNum_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <ClearingPeriod xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CNAE_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CNPJCPFNum_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CommercialRegister xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CommercialRegisterInsetNumber xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CommercialRegisterSection xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CommissionGroup xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CompanyChainId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CompanyIdSiret xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CompanyNAFCode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <ContactPersonId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CreditRating xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Curp_MX xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Currency>USD</Currency> 
  <CustClassificationId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CustGroup>B2C</CustGroup> 
  <CustItemGroupId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CustTradingPartnerCode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DAXIntegrationId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
- <DefaultDimension>
- <Values xmlns="http://schemas.microsoft.com/dynamics/2008/01/sharedtypes">
- <Value>
  <Name>BusinessUnit</Name> 
  <Value>B2C</Value> 
  </Value>
  </Values>
  </DefaultDimension>
  <DefaultDirectDebitMandate xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DefaultInventStatusId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DestinationCodeId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DlvMode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DlvReason xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DlvTerm xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <EinvoiceEANNum xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <EndDisc xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <EnterpriseCode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <EnterpriseNumber xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <FactoringAccount xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <FederalComments xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <FineCode_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <FiscalCode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <ForeignerId_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <FreightZone xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <IdentificationNumber xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <IENum_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <INSSCEI_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <IntBank_LV xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <InterestCode_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <InventLocation xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <InventProfileId_RU xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <InventSiteId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <InvoiceAccount xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <IssuerCountry_HU xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <LineDisc xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <LineOfBusinessId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <LvPaymTransCodes xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <MainContactPersonnelNumber xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <MainContactWorker xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <MarkupGroup xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <MCRMergedParent xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <MCRMergedRoot xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Memo xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <MultiLineDisc xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Name xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <NIT_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <numberSequenceGroup xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <OrderEntryDeadlineGroupId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <OrgId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <OurAccountNum xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PackMaterialFeeLicenseNum xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Party xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PartyCountry xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PartyState xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PassportNo_HU xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PaymDayId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PaymentReference_EE xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PaymMode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PaymSched xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PaymSpec xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PaymTermId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PBACustGroupId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PdsCustRebateGroupId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PdsRebateTMAGroup xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PriceGroup xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <RegNum_W xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <ResidenceForeignCountryRegionId_IT xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Rfc_MX xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SalesCalendarId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SalesDistrictId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SalesGroup xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SalesPoolId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SegmentId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <ShipCarrierAccount xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <ShipCarrierAccountCode xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <ShipCarrierId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <StateInscription_MX xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <StatisticsGroup xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SubsegmentId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SuframaNumber_BR xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SuppItemGroupId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SyncEntityId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <TaxBorderNumber_FI xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <TaxGroup xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <TaxGSTReliefGroupHeading_MY xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <TaxLicenseNum xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <TaxPeriodPaymentCode_PL xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <TaxWithholdGroup_TH xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <VATNum xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <VendAccount xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
- <DirPartyTableT class="entity">
  <KnownAs xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <LanguageId>RU</LanguageId> 
  <Name> </Name> 
  <NameAlias></NameAlias> 
  <PartyNumber xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PrimaryAddressLocation xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  </DirPartyTableT>
- <SalesAgreementHeaderT class="entity">
- <AgreementClassification>
  <Name xmlns="http://schemas.microsoft.com/dynamics/2008/01/sharedtypes">B2B</Name> 
  </AgreementClassification>
  <AgreementState>Effective</AgreementState> 
  <Currency>USD</Currency> 
  <DefaultAgreementLineEffectiveDate>2015-08-17</DefaultAgreementLineEffectiveDate> 
  <DefaultDimension xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DocumentExternalReference xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DocumentTitle xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Language>RU</Language> 
  <Originator xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CustAccount>20957066</CustAccount> 
  <CustomerDataAreaId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <SalesNumberSequence>20957066</SalesNumberSequence> 
  <SellingLegalEntity xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
- <SalesAgreementHeaderExt_RUT class="entity">
  <AgreementDate>2015-08-17</AgreementDate> 
  <AgreementId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <AgreementSubject xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CellularPhone xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <DefaultDimension xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Email xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <InventProfileId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <LineOfBusinessId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PaymDayId xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Phone xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <PhoneLocal xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <TeleFax xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Telex xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <Url xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CustPostingProfile xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  <CustPrepaymentPostingProfile xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> 
  </SalesAgreementHeaderExt_RUT>
  </SalesAgreementHeaderT>
  </CustTableT>
  </CustImport>
  </CustImportServiceCreateRequest>
Не вижу в нем никаких проблем

Последний раз редактировалось syl; 17.08.2015 в 17:56.