Feedback von Taxman
This commit is contained in:
parent
f8c13c5b2b
commit
04acdb4ff3
6 changed files with 159 additions and 57 deletions
|
|
@ -1,25 +1,25 @@
|
|||
# Feedback zum PDF FIle
|
||||
|
||||
## 1. Podmiot 1 — Daten des Rechnungsausstellers (AGLP)
|
||||
|
||||
- `<Nazwa>` FIXED
|
||||
- `<AdresL1>` FIXED
|
||||
- `<PrefiksPodatnika>PL</PrefiksPodatnika>` FIXED
|
||||
|
||||
## 2. Podmiot 2 — Daten des Rechnungsempfängers
|
||||
|
||||
- `<NrID> <NIP>` - ALREADY IMPLEMENTED
|
||||
- EU-Rechnungsempfänger - UNCLEAR!
|
||||
- Anschrift des Rechnungsempfängers - CARGOSOFT TOPIC
|
||||
|
||||
## 3. Abschnitt <Fa> — Rechnungskopf (außer Standardfelder P_1, P_2, P_6)
|
||||
|
||||
- `<P_1M>` - FIXED
|
||||
- `<KursWalutyZ>` - FIXED
|
||||
|
||||
# 4. Rechnungspositionen <FaWiersz> — Pflichtfelder je Position
|
||||
|
||||
- `<P_7>` - FIXED
|
||||
- `<P_8B>` - IGNORED - NOT FIXED!
|
||||
|
||||
ab `<P_11A>` wird es krimminell
|
||||
| Feld / Komponente | Status |
|
||||
| :------------------------------------------------------- | :----------------------- |
|
||||
| **1. Podmiot 1 — Daten des Rechnungsausstellers (AGLP)** | |
|
||||
| `<Nazwa>` | **FIXED** |
|
||||
| `<AdresL1>` | **FIXED** |
|
||||
| `<PrefiksPodatnika>PL</PrefiksPodatnika>` | **FIXED** |
|
||||
| **2. Podmiot 2 — Daten des Rechnungsempfängers** | |
|
||||
| `<NrID> <NIP>` | **ALREADY IMPLEMENTED** |
|
||||
| EU-Rechnungsempfänger | **UNCLEAR!** |
|
||||
| Anschrift des Rechnungsempfängers | **CARGOSOFT TOPIC** |
|
||||
| **3. Abschnitt <Fa> — Rechnungskopf** | **FIXED** |
|
||||
| `<P_1M>` | **FIXED** |
|
||||
| `<KursWalutyZ>` | **FIXED** |
|
||||
| **4. Rechnungspositionen <FaWiersz> — Pflichtfelder** | |
|
||||
| `<P_7>` | **FIXED** |
|
||||
| `<P_8B>` | **IGNORED - NOT FIXED!** |
|
||||
| `<P_11A>` | **????** |
|
||||
| `<P_11Vat>` | **????** |
|
||||
| **5. Rechnungssummen — <P_13_x> / <P_14_x>** | |
|
||||
| _Noch keine Details_ | — |
|
||||
| **6. Zahlung — <Platnosc>** | |
|
||||
| `<FormaPlatnosci>` | **FIXED** |
|
||||
| `<RachunekBankowy>` | **FIXED** |
|
||||
|
|
|
|||
|
|
@ -315,7 +315,9 @@ public class KSeFAdapter implements SignalAdapter {
|
|||
// finally set the due date at the end of the XML tree
|
||||
model.setDueDateTime(workitem.getItemValueLocalDate("invoice.duedate"));
|
||||
|
||||
// finally update the template file
|
||||
/*
|
||||
* finally update the template file
|
||||
*/
|
||||
fileDataXMLTemplate.setContent(model.getContent());
|
||||
|
||||
} catch (FileNotFoundException | EInvoiceFormatException | TransformerException e) {
|
||||
|
|
@ -332,31 +334,36 @@ public class KSeFAdapter implements SignalAdapter {
|
|||
* @throws PluginException
|
||||
*/
|
||||
private void syncPerformanceDate(ItemCollection workitem) throws PluginException {
|
||||
try {
|
||||
logger.info("----Resync cargosoft performancedate....");
|
||||
DocumentBuilder documentBuilder;
|
||||
// hole die XML Datei
|
||||
FileData cargoXML = snapshotService.getWorkItemFile(workitem.getUniqueID(),
|
||||
workitem.getItemValueString("cargosoft.import.filename"));
|
||||
if (cargoXML != null) {
|
||||
InputStream inputStream = new ByteArrayInputStream(cargoXML.getContent());
|
||||
InputSource inputSource = new InputSource(inputStream);
|
||||
|
||||
documentBuilder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
|
||||
Document doc = documentBuilder.parse(inputSource);
|
||||
if (!workitem.hasItem("invoice.performancedate")) {
|
||||
try {
|
||||
logger.info("----Resync cargosoft performancedate....");
|
||||
DocumentBuilder documentBuilder;
|
||||
// hole die XML Datei
|
||||
FileData cargoXML = snapshotService.getWorkItemFile(workitem.getUniqueID(),
|
||||
workitem.getItemValueString("cargosoft.import.filename"));
|
||||
if (cargoXML != null) {
|
||||
InputStream inputStream = new ByteArrayInputStream(cargoXML.getContent());
|
||||
InputSource inputSource = new InputSource(inputStream);
|
||||
|
||||
// Performance Date
|
||||
CargosoftXMLInvoiceImportService.readXMLValue(doc, "/Invoices/Invoice/InvoiceHeader/PerformanceDate",
|
||||
workitem, "invoice.performancedate",
|
||||
Date.class);
|
||||
documentBuilder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
|
||||
Document doc = documentBuilder.parse(inputSource);
|
||||
|
||||
// falls keines gefunden wurde nehmen wir das invoice date
|
||||
if (workitem.getItemValueDate("invoice.performancedate") == null) {
|
||||
workitem.setItemValue("invoice.performancedate", workitem.getItemValueDate("invoice.date"));
|
||||
// Performance Date
|
||||
CargosoftXMLInvoiceImportService.readXMLValue(doc,
|
||||
"/Invoices/Invoice/InvoiceHeader/PerformanceDate",
|
||||
workitem, "invoice.performancedate",
|
||||
Date.class);
|
||||
|
||||
// falls keines gefunden wurde nehmen wir das invoice date
|
||||
if (workitem.getItemValueDate("invoice.performancedate") == null) {
|
||||
workitem.setItemValue("invoice.performancedate", workitem.getItemValueDate("invoice.date"));
|
||||
}
|
||||
}
|
||||
} catch (ParserConfigurationException | SAXException | IOException e) {
|
||||
throw new PluginException(CargosoftXMLInvoiceImportService.class.getName(), "XML_ERROR",
|
||||
e.getMessage());
|
||||
}
|
||||
} catch (ParserConfigurationException | SAXException | IOException e) {
|
||||
throw new PluginException(CargosoftXMLInvoiceImportService.class.getName(), "XML_ERROR", e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ import java.nio.file.Path;
|
|||
import java.nio.file.Paths;
|
||||
import java.time.LocalDate;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
|
|
@ -100,6 +101,7 @@ public class KSeFAdapterTest {
|
|||
workitem.setItemValue("invoice.CorrectionInvoiceNumber", "");
|
||||
workitem.setItemValue("partner.id", "BP-001");
|
||||
workitem.setItemValue("partner.vat", "PL1234567890");
|
||||
workitem.setItemValue("invoice.performancedate", new Date());
|
||||
|
||||
// Prepare child items (invoice line items)
|
||||
List<Object> childItems = new ArrayList<>();
|
||||
|
|
@ -159,7 +161,7 @@ public class KSeFAdapterTest {
|
|||
// simulation Korrekturrechnung
|
||||
workitem.setItemValue("invoice.correction", true);
|
||||
workitem.setItemValue("invoice.CorrectionInvoiceNumber", "6551");
|
||||
|
||||
workitem.setItemValue("invoice.performancedate", new Date());
|
||||
// Prepare child items (invoice line items)
|
||||
List<Object> childItems = new ArrayList<>();
|
||||
|
||||
|
|
|
|||
|
|
@ -13,14 +13,14 @@
|
|||
|
||||
<!-- Seller (Your Polish Company - Pre-filled) -->
|
||||
<Podmiot1>
|
||||
<PrefiksPodatnika>PL</PrefiksPodatnika>
|
||||
<DaneIdentyfikacyjne>
|
||||
<NIP>9552521552</NIP>
|
||||
<Nazwa>Alexander Global Logistics</Nazwa>
|
||||
<Nazwa>ALEXANDER GLOBAL LOGISTICS POLAND sp. z o.o.</Nazwa>
|
||||
</DaneIdentyfikacyjne>
|
||||
<Adres>
|
||||
<KodKraju>PL</KodKraju>
|
||||
<AdresL1>Gdanska 36</AdresL1>
|
||||
<AdresL2>70-660 Szczecin</AdresL2>
|
||||
<AdresL1>ul. Gdańska 36, 70-660 Szczecin</AdresL1>
|
||||
</Adres>
|
||||
<DaneKontaktowe>
|
||||
<Email>MBudas@alexander-logistics.com</Email>
|
||||
|
|
@ -57,6 +57,7 @@
|
|||
<KodWaluty>#CURRENCY#</KodWaluty>
|
||||
|
||||
<P_1></P_1> <!-- Invoice Date -->
|
||||
<P_1M>Szczecin</P_1M>
|
||||
<P_2></P_2> <!-- Invoice Number -->
|
||||
<P_6></P_6> <!-- Due Date -->
|
||||
|
||||
|
|
@ -104,5 +105,38 @@
|
|||
|
||||
<!-- Invoice Positions: FaWiersz -->
|
||||
|
||||
<Platnosc>
|
||||
|
||||
<!-- Setzen der Zahlungsart (immer 6)
|
||||
* 1 – Barzahlung
|
||||
* 2 – Karte
|
||||
* 3 – Gutschein
|
||||
* 4 – Scheck
|
||||
* 5 – Kredit
|
||||
* 6 – Überweisung
|
||||
* 7 – Mobilzahlung
|
||||
-->
|
||||
<FormaPlatnosci>6</FormaPlatnosci>
|
||||
|
||||
<!-- BANKEN-->
|
||||
<RachunekBankowy>
|
||||
<NrRB>PL79116022020000000654306674</NrRB>
|
||||
<SWIFT>BIGBPLPWXXX</SWIFT>
|
||||
<NazwaBanku>Bank Millennium S.A.</NazwaBanku>
|
||||
<OpisRachunku>Konto PLN</OpisRachunku>
|
||||
</RachunekBankowy>
|
||||
<RachunekBankowy>
|
||||
<NrRB>PL16116022020000000654910469</NrRB>
|
||||
<SWIFT>BIGBPLPWXXX</SWIFT>
|
||||
<NazwaBanku>Bank Millennium S.A.</NazwaBanku>
|
||||
<OpisRachunku>Konto EUR</OpisRachunku>
|
||||
</RachunekBankowy>
|
||||
<RachunekBankowy>
|
||||
<NrRB>PL72116022020000000654911595</NrRB>
|
||||
<SWIFT>BIGBPLPWXXX</SWIFT>
|
||||
<NazwaBanku>Bank Millennium S.A.</NazwaBanku>
|
||||
<OpisRachunku>Konto USD</OpisRachunku>
|
||||
</RachunekBankowy>
|
||||
</Platnosc>
|
||||
</Fa>
|
||||
</Faktura>
|
||||
|
|
@ -6,19 +6,19 @@
|
|||
<Naglowek>
|
||||
<KodFormularza kodSystemowy="FA (3)" wersjaSchemy="1-0E">FA</KodFormularza>
|
||||
<WariantFormularza>3</WariantFormularza>
|
||||
<DataWytworzeniaFa>2026-04-16T06:22:32.455873037Z</DataWytworzeniaFa>
|
||||
<DataWytworzeniaFa>2026-04-27T16:20:53.265515Z</DataWytworzeniaFa>
|
||||
<SystemInfo>Imixs eInvoice</SystemInfo>
|
||||
</Naglowek>
|
||||
<!-- Seller (Your Polish Company - Pre-filled) -->
|
||||
<Podmiot1>
|
||||
<PrefiksPodatnika>PL</PrefiksPodatnika>
|
||||
<DaneIdentyfikacyjne>
|
||||
<NIP>9552521552</NIP>
|
||||
<Nazwa>Alexander Global Logistics</Nazwa>
|
||||
<Nazwa>ALEXANDER GLOBAL LOGISTICS POLAND sp. z o.o.</Nazwa>
|
||||
</DaneIdentyfikacyjne>
|
||||
<Adres>
|
||||
<KodKraju>PL</KodKraju>
|
||||
<AdresL1>Gdanska 36</AdresL1>
|
||||
<AdresL2>70-660 Szczecin</AdresL2>
|
||||
<AdresL1>ul. Gdańska 36, 70-660 Szczecin</AdresL1>
|
||||
</Adres>
|
||||
<DaneKontaktowe>
|
||||
<Email>MBudas@alexander-logistics.com</Email>
|
||||
|
|
@ -56,9 +56,10 @@
|
|||
<KodWaluty>PLN</KodWaluty>
|
||||
<P_1>2025-02-10</P_1>
|
||||
<!-- Invoice Date -->
|
||||
<P_1M>Szczecin</P_1M>
|
||||
<P_2>FV/2025/001</P_2>
|
||||
<!-- Invoice Number -->
|
||||
<P_6>2025-03-10</P_6>
|
||||
<P_6>2026-04-27</P_6>
|
||||
<!-- Due Date -->
|
||||
<!-- Totals will only be computed by the EInvoiceModelKSeF Class-->
|
||||
<!--
|
||||
|
|
@ -98,21 +99,46 @@
|
|||
<!-- Invoice Positions: FaWiersz -->
|
||||
<FaWiersz>
|
||||
<NrWierszaFa>1</NrWierszaFa>
|
||||
<UU_ID>a743f373-b75c-44c5-a077-ee628295b5d3</UU_ID>
|
||||
<P_8A>szt.</P_8A>
|
||||
<P_8B>1</P_8B>
|
||||
<P_9A>6000.00</P_9A>
|
||||
<P_11>6000.00</P_11>
|
||||
<P_12>0</P_12>
|
||||
</FaWiersz>
|
||||
<FaWiersz>
|
||||
<NrWierszaFa>2</NrWierszaFa>
|
||||
<UU_ID>9eb2d946-a3cb-4adb-8ed1-069e2f48d67d</UU_ID>
|
||||
<P_8A>szt.</P_8A>
|
||||
<P_8B>1</P_8B>
|
||||
<P_9A>4000.00</P_9A>
|
||||
<P_11>4000.00</P_11>
|
||||
<P_12>0</P_12>
|
||||
</FaWiersz>
|
||||
<Platnosc>
|
||||
|
||||
<!-- Setzen der Zahlungsart (immer 6)
|
||||
* 1 – Barzahlung
|
||||
* 2 – Karte
|
||||
* 3 – Gutschein
|
||||
* 4 – Scheck
|
||||
* 5 – Kredit
|
||||
* 6 – Überweisung
|
||||
* 7 – Mobilzahlung
|
||||
-->
|
||||
<TerminPlatnosci>
|
||||
<Termin>2025-03-10</Termin>
|
||||
</TerminPlatnosci>
|
||||
<FormaPlatnosci>6</FormaPlatnosci>
|
||||
<!-- BANKEN-->
|
||||
<RachunekBankowy>
|
||||
<NrRB>PL79116022020000000654306674</NrRB>
|
||||
<SWIFT>BIGBPLPWXXX</SWIFT>
|
||||
<NazwaBanku>Bank Millennium S.A.</NazwaBanku>
|
||||
<OpisRachunku>Konto PLN</OpisRachunku>
|
||||
</RachunekBankowy>
|
||||
<RachunekBankowy>
|
||||
<NrRB>PL16116022020000000654910469</NrRB>
|
||||
<SWIFT>BIGBPLPWXXX</SWIFT>
|
||||
<NazwaBanku>Bank Millennium S.A.</NazwaBanku>
|
||||
<OpisRachunku>Konto EUR</OpisRachunku>
|
||||
</RachunekBankowy>
|
||||
</Platnosc>
|
||||
</Fa>
|
||||
</Faktura>
|
||||
|
|
|
|||
|
|
@ -105,5 +105,38 @@
|
|||
|
||||
<!-- Invoice Positions: FaWiersz -->
|
||||
|
||||
<Platnosc>
|
||||
|
||||
<!-- Setzen der Zahlungsart (immer 6)
|
||||
* 1 – Barzahlung
|
||||
* 2 – Karte
|
||||
* 3 – Gutschein
|
||||
* 4 – Scheck
|
||||
* 5 – Kredit
|
||||
* 6 – Überweisung
|
||||
* 7 – Mobilzahlung
|
||||
-->
|
||||
<FormaPlatnosci>6</FormaPlatnosci>
|
||||
|
||||
<!-- BANKEN-->
|
||||
<RachunekBankowy>
|
||||
<NrRB>PL79116022020000000654306674</NrRB>
|
||||
<SWIFT>BIGBPLPWXXX</SWIFT>
|
||||
<NazwaBanku>Bank Millennium S.A.</NazwaBanku>
|
||||
<OpisRachunku>Konto PLN</OpisRachunku>
|
||||
</RachunekBankowy>
|
||||
<RachunekBankowy>
|
||||
<NrRB>PL16116022020000000654910469</NrRB>
|
||||
<SWIFT>BIGBPLPWXXX</SWIFT>
|
||||
<NazwaBanku>Bank Millennium S.A.</NazwaBanku>
|
||||
<OpisRachunku>Konto EUR</OpisRachunku>
|
||||
</RachunekBankowy>
|
||||
<RachunekBankowy>
|
||||
<NrRB>PL72116022020000000654911595</NrRB>
|
||||
<SWIFT>BIGBPLPWXXX</SWIFT>
|
||||
<NazwaBanku>Bank Millennium S.A.</NazwaBanku>
|
||||
<OpisRachunku>Konto USD</OpisRachunku>
|
||||
</RachunekBankowy>
|
||||
</Platnosc>
|
||||
</Fa>
|
||||
</Faktura>
|
||||
Loading…
Reference in a new issue