Prefix for Invoice Number

<td style="border-right-width: 1px; padding-right: 20px; text-align: right">
                    {% for field in fields %}                            
                        {% if field.label != 'Invoice number' %}
                            <div style="font-weight: bold">{{ field.label }}</div>
                            <div style="margin-bottom: 10px">{{ field.text }}</div>
                        {% endif %}
                        
                        {% if field.label == 'Invoice number' %}
                            <div style="font-weight: bold">{{ field.label }}</div>
                            <div>{% for field in fields %}{% if field.label == 'Invoice date' %}{{ field.text | date:'20%y'}}{% endif %}{% endfor %}{{ field.text }}{{ recipient.code }}</div>                                                                 
                        {% endif %}
                    {% endfor %}                       
                </td>

You can use this code, it works for me. When you are using an other language than English change the field labels accordingly. The output is 2016+invoice nr.+client reference and you can change the order if you like.

3 Likes