Closed mcmihai closed 9 months ago
What is the specificity of the Romanian invoice? The template for EN16931 should cover all EU countries.
Thanks for all the contributions @mcmihai !
I guess now it's just the CustomizationID. It is also required to have provinces for buyer and seller and a payment means method. Also in the template invoice.xml the cbc:PriceAmount currencyID is hardcoded to euros but that can be easily fixed.
So in my program I used to have a different template which I loaded like this:
invoice._templates = templates.get_template('ro_invoice.xml')
and I was looking for a way to have a different template somehow:
'invoice = Invoice(currency="RON", template_name="ro_invoice.xml")`.
Now that all the other stuff is merged I guess it would make more sense to add a way to supply a different CustomizationID and make all the currencies variable.
Thanks for all the contributions @mcmihai !
no problem! :)
I guess now it's just the CustomizationID. It is also required to have provinces for buyer and seller and a payment means method. Also in the template invoice.xml the cbc:PriceAmount currencyID is hardcoded to euros but that can be easily fixed.
So in my program I used to have a different template which I loaded like this:
invoice._templates = templates.get_template('ro_invoice.xml')
and I was looking for a way to have a different template somehow: 'invoice = Invoice(currency="RON", template_name="ro_invoice.xml")`.Now that all the other stuff is merged I guess it would make more sense to add a way to supply a different CustomizationID and make all the currencies variable.
That sounds like a plan! I'd prefer this solution.
Superseded by #9
I was thinking you could have multiple templates and you could select one when you initialize an invoice object. I've added a template for a Romanian invoice.