﻿<?xml version="1.0" encoding="UTF-8" ?> 
<?xml-stylesheet type="text/xsl" href="..\Stylesheet.xsl"?>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -   -->
<!--  För test och illustration av Svefaktura  -  Användning av attribut     -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -   -->
<Invoice xmlns="urn:sfti:documents:BasicInvoice:1:0"
   xmlns:cac="urn:sfti:CommonAggregateComponents:1:0"
   xmlns:cbc="urn:oasis:names:tc:ubl:CommonBasicComponents:1:0"
   xmlns:ccts="urn:oasis:names:tc:ubl:CoreComponentParameters:1:0"
   xmlns:cur="urn:oasis:names:tc:ubl:codelist:CurrencyCode:1:0"
   xmlns:sdt="urn:oasis:names:tc:ubl:SpecializedDatatypes:1:0"
   xmlns:udt="urn:oasis:names:tc:ubl:UnspecializedDatatypes:1:0"
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <ID>08/0032</ID>
   <cbc:IssueDate>2007-01-29</cbc:IssueDate>
   <InvoiceTypeCode>380</InvoiceTypeCode>
   <cbc:Note>Illustration av och kommentar till användning av attribut i Svefaktura
   A) Attribut som ingår i Svefaktura Bas
   1. För elementet AdditionalDocumentReference: identificationSchemeAgencyName="SFTI" med identificationSchemeID="CT", "ACD", "DQ" eller "ATS"
   2. För element ReasonCode="ZZZ" vid rabatt/påslag i fakturahuvudet: name med beskrivande text
   3. För element PayeeFinancialAccount/ID: identificationSchemeName utelämnat eller ="IBAN", "BBAN", eller "Domestic account". Ifall kontonumret följer IBAN nummerplan är attributet obligatoriskt.
   4. För beloppselementen (obligatoriskt attribut): amountCurrencyID med kodvärde enligt ISO 4217
   5. För elementet InvociedQuantity (obligatoriskt attribut) med leverantörsdefinierat innehåll: quantityUnitCode med valfri textförkortning

   B) I Svefaktura utökad ingår dessutom följande rekommenderade uppsättning attribut:
   1. För elementet PartyIdentification: identificationSchemeAgencyID="9"
   2. För elementen Address och DeliveryAddress: identificationSchemeAgencyID="9"
   3. För elementet InvociedQuantity (obligatoriskt attribut) med standardiserat innehåll: quantityUnitCodeListAgencyID="6", quantityUnitCodeListID="UNECE-REC20" och quantityUnitCode eligt kodlista
   4. För elementen BuyersItemIdentification, SellersItemIdentification, och StandardItemIdentification: identificationSchemeAgencyID="9"

   Vi avråder från användning av andra/ytterligare attribut och kodvärden. Är mottagarens stilmall inte förberedd för dessa finns risk för informationsförlust, och bilaterala avtal är ingen bra lösning då de bromsar masspridning.
   </cbc:Note>
   <LineItemCountNumeric>4</LineItemCountNumeric>
   <AdditionalDocumentReference>
      <cac:ID identificationSchemeAgencyName="SFTI" identificationSchemeID="CT">1234 ("CT"-referens)</cac:ID>
   </AdditionalDocumentReference>
   <AdditionalDocumentReference>
      <cac:ID identificationSchemeAgencyName="SFTI" identificationSchemeID="ACD">12345678 ("ACD"-referens)</cac:ID>
   </AdditionalDocumentReference>
   <AdditionalDocumentReference>
      <cac:ID identificationSchemeAgencyName="SFTI" identificationSchemeID="DQ">0987654 ("DQ"-referens)</cac:ID>
   </AdditionalDocumentReference>
   <AdditionalDocumentReference>
      <cac:ID identificationSchemeAgencyName="SFTI" identificationSchemeID="ATS">AB124578 ("ATS"-referens, URN till externt objekt)</cac:ID>
   </AdditionalDocumentReference>
   <AdditionalDocumentReference>
      <cac:ID>XYZ (Ospecifiserad dok.referens)</cac:ID>
   </AdditionalDocumentReference>
   <cac:BuyerParty>
      <cac:Party>
         <cac:PartyIdentification>
            <cac:ID>123</cac:ID>
         </cac:PartyIdentification>
         <cac:PartyIdentification>
            <cac:ID identificationSchemeAgencyID="9">7300010000001</cac:ID>
         </cac:PartyIdentification>
         <cac:PartyName>
            <cbc:Name>QVK Catering</cbc:Name>
         </cac:PartyName>
         <cac:Address>
            <cac:ID identificationSchemeAgencyID="9">7600001000004</cac:ID>
            <cbc:StreetName>Stora gatan 5</cbc:StreetName>
            <cbc:CityName>Hägersten</cbc:CityName>
            <cbc:PostalZone>12652</cbc:PostalZone>
         </cac:Address>
      </cac:Party>
   </cac:BuyerParty>
   <cac:SellerParty>
      <cac:Party>
         <cac:PartyIdentification>
            <cac:ID identificationSchemeAgencyID="9">7300010001015</cac:ID>
         </cac:PartyIdentification>
         <cac:PartyIdentification>
            <cac:ID>01313</cac:ID>
         </cac:PartyIdentification>
         <cac:PartyName>
            <cbc:Name>Komponentlagret AB</cbc:Name>
         </cac:PartyName>
         <cac:Address>
            <cac:ID>123-4</cac:ID>
            <cbc:Postbox>Box 54321</cbc:Postbox>
            <cbc:CityName>Göteborg</cbc:CityName>
            <cbc:PostalZone>40123</cbc:PostalZone>
            <cac:Country>
               <cac:IdentificationCode>SE</cac:IdentificationCode>
            </cac:Country>
         </cac:Address>
         <cac:PartyTaxScheme>
            <cac:CompanyID>5566778899</cac:CompanyID>
            <cbc:ExemptionReason>F-skattebevis finns</cbc:ExemptionReason>
            <cac:RegistrationAddress>
            <cbc:CityName>Göteborg</cbc:CityName>
               <cac:Country>
                  <cac:IdentificationCode>SE</cac:IdentificationCode>
               </cac:Country>
            </cac:RegistrationAddress>
            <cac:TaxScheme>
               <cac:ID>SWT</cac:ID>
            </cac:TaxScheme>
         </cac:PartyTaxScheme>
         <cac:PartyTaxScheme>
            <cac:CompanyID>SE556677889901</cac:CompanyID>
            <cac:TaxScheme>
               <cac:ID>VAT</cac:ID>
            </cac:TaxScheme>
         </cac:PartyTaxScheme>
      </cac:Party>
   </cac:SellerParty>
   <cac:Delivery>
      <cac:DeliveryAddress>
         <cac:ID identificationSchemeAgencyID="9">7600001000004</cac:ID>
      </cac:DeliveryAddress>
   </cac:Delivery>
   <cac:PaymentMeans>
      <cac:PaymentMeansTypeCode>1</cac:PaymentMeansTypeCode>
      <cac:PayeeFinancialAccount>
         <cac:ID identificationSchemeName="IBAN">SE7530000000031000054321</cac:ID>
         <cac:FinancialInstitutionBranch>
            <cac:FinancialInstitution>
               <cac:ID>NDEASESS</cac:ID>
            </cac:FinancialInstitution>
         </cac:FinancialInstitutionBranch>
      </cac:PayeeFinancialAccount>
   </cac:PaymentMeans>
   <AllowanceCharge>
      <cbc:ChargeIndicator>true</cbc:ChargeIndicator>
      <cac:ReasonCode name="Fraktavgift">ZZZ</cac:ReasonCode>
      <cbc:Amount amountCurrencyID="SEK">40</cbc:Amount>
      <cac:TaxCategory>
         <cac:ID>S</cac:ID>
         <cbc:Percent>25</cbc:Percent>
         <cac:TaxScheme>
            <cac:ID>VAT</cac:ID>
         </cac:TaxScheme>
      </cac:TaxCategory>
   </AllowanceCharge>
   <cac:TaxTotal>
      <cbc:TotalTaxAmount amountCurrencyID="SEK">35</cbc:TotalTaxAmount>
      <cac:TaxSubTotal>
         <cbc:TaxableAmount amountCurrencyID="SEK">140</cbc:TaxableAmount>
         <cbc:TaxAmount amountCurrencyID="SEK">35</cbc:TaxAmount>
         <cac:TaxCategory>
            <cac:ID>S</cac:ID>
            <cbc:Percent>25</cbc:Percent>
            <cac:TaxScheme>
               <cac:ID>VAT</cac:ID>
            </cac:TaxScheme>
         </cac:TaxCategory>
      </cac:TaxSubTotal>
   </cac:TaxTotal>
   <cac:LegalTotal>
      <cbc:LineExtensionTotalAmount amountCurrencyID="SEK">100</cbc:LineExtensionTotalAmount>
      <cbc:TaxExclusiveTotalAmount amountCurrencyID="SEK">140</cbc:TaxExclusiveTotalAmount>
      <cbc:TaxInclusiveTotalAmount  amountCurrencyID="SEK">175</cbc:TaxInclusiveTotalAmount>
   </cac:LegalTotal>
   <cac:InvoiceLine>
      <cac:ID>1</cac:ID>
      <cbc:InvoicedQuantity quantityUnitCode="">100</cbc:InvoicedQuantity>
      <cbc:LineExtensionAmount amountCurrencyID="SEK">18</cbc:LineExtensionAmount>
      <cbc:Note>Kvantitet med tomt attribut;
      artikelnr utan attribut</cbc:Note>
      <cac:Item>
         <cbc:Description>Dekal 1</cbc:Description>
         <cac:BuyersItemIdentification>
            <cac:ID>QVK-1</cac:ID>
         </cac:BuyersItemIdentification>
         <cac:SellersItemIdentification>
            <cac:ID>DEK-1-v2.01</cac:ID>
         </cac:SellersItemIdentification>
         <cac:StandardItemIdentification>
            <cac:ID>Std01.002.01</cac:ID>
         </cac:StandardItemIdentification>
      </cac:Item>
   </cac:InvoiceLine>
   <cac:InvoiceLine>
      <cac:ID>2</cac:ID>
      <cbc:InvoicedQuantity quantityUnitCode="styck">5</cbc:InvoicedQuantity>
      <cbc:LineExtensionAmount amountCurrencyID="SEK">5</cbc:LineExtensionAmount>
      <cbc:Note>Kvantitet med text i attribut</cbc:Note>
      <cac:Item>
         <cbc:Description>Dekal 2</cbc:Description>
      </cac:Item>
   </cac:InvoiceLine>
   <cac:InvoiceLine>
      <cac:ID>3</cac:ID>
      <cbc:InvoicedQuantity quantityUnitCode="St">25</cbc:InvoicedQuantity>
      <cbc:LineExtensionAmount amountCurrencyID="SEK">2</cbc:LineExtensionAmount>
      <cbc:Note>Kvantitet med förkortning i attribut</cbc:Note>
      <cac:Item>
         <cbc:Description>Dekal 3</cbc:Description>
      </cac:Item>
   </cac:InvoiceLine>
   <cac:InvoiceLine>
      <cac:ID>4</cac:ID>
      <cbc:InvoicedQuantity quantityUnitCodeListAgencyID="6" quantityUnitCodeListID="UNECE-REC20" quantityUnitCode="LTR">75</cbc:InvoicedQuantity>
      <cbc:LineExtensionAmount amountCurrencyID="SEK">75</cbc:LineExtensionAmount>
      <cbc:Note>Kvantitet med attribut för UN/ECE-kod;
      artikelnummer som GTIN</cbc:Note>
      <cac:Item>
         <cbc:Description>Plastmassa</cbc:Description>
         <cac:BuyersItemIdentification>
            <cac:ID identificationSchemeAgencyID="9">7300060000006</cac:ID>
         </cac:BuyersItemIdentification>
         <cac:SellersItemIdentification>
            <cac:ID identificationSchemeAgencyID="9">7300070010019</cac:ID>
         </cac:SellersItemIdentification>
         <cac:StandardItemIdentification>
            <cac:ID identificationSchemeAgencyID="9">7300070011115</cac:ID>
         </cac:StandardItemIdentification>
         <cac:BasePrice>
            <cbc:PriceAmount amountCurrencyID="SEK">1</cbc:PriceAmount>
         </cac:BasePrice>
      </cac:Item>
   </cac:InvoiceLine>
   <RequisitionistDocumentReference>
      <cac:ID>HaGre</cac:ID>
   </RequisitionistDocumentReference>
</Invoice>