added json, xml and txt invoice renderer (#1576)

This commit is contained in:
Kevin Papst
2020-03-21 01:01:47 +01:00
committed by GitHub
parent c89750fe94
commit 1ca1b00d11
19 changed files with 560 additions and 53 deletions

View File

@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<kimai version="{{ constant('App\\Constants::VERSION') }}">
{% for key, value in model.toArray %}
<{{ key }}{% if value is empty %}/>{% else %}>{{ value|escape }}</{{ key }}>{% endif %}
{% endfor %}
<items>
{%- for entry in model.calculator.entries %}
<item>
{% for key, value in model.itemToArray(entry) %}
<{{ key }}{% if value is empty %}/>{% else %}>{{ value|escape }}</{{ key }}>{% endif %}
{% endfor %}
</item>
{%- endfor %}
</items>
</kimai>