Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix SpecifiedLegalOrganization profile #221

Merged
merged 3 commits into from
Nov 18, 2023

Conversation

danvy
Copy link
Contributor

@danvy danvy commented Nov 8, 2023

SpecifiedLegalOrganization was missing in some profiles

@stephanstapel
Copy link
Owner

Good morning,

thanks for the pull request. I'm not sure if this is correct either.
From the docs (ZUGFeRD 2.2, i.e. excluding XRechnung specification):

TradingBusinessName:
grafik

SpecifiedLegalOrganization:
grafik

@danvy
Copy link
Contributor Author

danvy commented Nov 10, 2023

In the lastest Factur-X doc, SpecifiedLegalOrganization is introduced in the BASCI WL profile.
I let you decide for XRechnung.
This is a severe issue for us as documents are being rejected.

@stephanstapel
Copy link
Owner

ok, thanks. For me to remember later - according to version 1.0.6, SpecifiedLegalOrganization is handled like:

ShipToTradeParty, ShipFromTradeParty, SalesAgentTradeParty, UltimateShipToTradeParty, BuyerTaxRepresentativeTradeParty, ProductEndUserTradeParty, BuyerAgentTradeParty, InvoicerTradeParty, InvoiceeTradeParty, PayerTradeParty:

grafik

SellerTradeParty, BuyerTradeParty, PayeeTradeParty:

grafik

@stephanstapel
Copy link
Owner

TradingBusinessName:

BuyerTradeParty

ShipToTradeParty, SalesAgentTradeParty, BuyerTaxRepresentativeTradeParty, SellerTaxRepresentativeTradeParty, ProductEndUserTradeParty, ...:

grafik

SellerTradeParty, PayeeTradeParty:

grafik

BuyerTradeParty:

grafik

I have no idea why it has been designed like this though...

@danvy
Copy link
Contributor Author

danvy commented Nov 17, 2023

@stephanstapel Are you ok if I add includeLegalOrganization parameter to _writeOptionalParty and set its value on each call accordingly ?

@stephanstapel
Copy link
Owner

Imho the change is quite big. As written in my notes above, the necessity to write SpecifiedLegalOrganization differs from party to party. Probably, _WriteOptionalParty() needs to be rewritten to allow this. Do you have ideas for this?

@stephanstapel stephanstapel merged commit a715ac7 into stephanstapel:master Nov 18, 2023
2 checks passed
@stephanstapel
Copy link
Owner

can you please add test cases?

@stephanstapel
Copy link
Owner

@danvy : besides the test cases (added one here:

public void TestMinimumInvoice()
btw), can you please verify that this modification of your code:

695c92d

works as expected?

@danvy
Copy link
Contributor Author

danvy commented Nov 21, 2023

Could you push a new release so I can test IRL ?

@stephanstapel
Copy link
Owner

done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants