Many custom fields Align in custom them

Hi
I have created 3 custom fields in our invoice. these are Detail of Event, Terms & Conditions: , Authorized Signatory. I want to align left Detail of Event, Terms & Conditions: and align right Authorized Signatory. but when in custom theme i am changing align right all custom fields align right.
please solve my problem how can align them correctly.

You need a custom theme. If you do not have the programming skills to create one, hire a local programmer. See Manager Cloud.

You will have to do something like this:

    {% for field in custom_fields %}
    <tr>
        <td colspan="99">

            {% if field.label == "Detail of Event" %}
                <div style="font-weight: bold; padding-top: 20px; align: left">{{ field.label }}</div> 
            {% endif %}

            {% if field.label == "Terms & Conditions" %}
                <div style="font-weight: bold; padding-top: 20px; align: left">{{ field.label }}</div> 
            {% endif %}

            {% if field.label == "Authorized Signatory" %}
                <div style="font-weight: bold; padding-top: 20px; align: right">{{ field.label }}</div> 
            {% endif %}
           
        </td>
    </tr>
    {% endfor %}

I didn’t check the code, but the example above should give you the right direction.

Actually there is now easier way to “inject” custom fields.

Have a look at this guide: Manager Cloud

1 Like

FANTASTIC! Great tutorial too.
One question, how do you only print the custom field if it contains information?
At the moment it prints even if there is no data

{% for field in fields %}
                            {% if field.label == 'Custom field name' %}
                                    {% if field.text != null and field.text != '' %}
                                        <div></div>
                                    {% else %}
                                        {{ field.label }}
                                        {{ field.text}}
                                    {% endif %}
                        {% endfor %}

Not understand much but I think the conditional logic is from the following lines ’ {% if field.text != null and field.text != ‘’ %}’

Supplied by @isklerius.

  1. For logic to Search within set of the following variables =
    {% for field in fields %}

  2. IF Logic to Search Targeted field label ‘custom field name’ =
    {% if field.label == ‘Custom field name’ %}

  3. The conditional logic if the content in ‘custom field’ is ‘empty’ or ‘space’ then the following line to be display. =

{ % if field.text != null and field.text != ‘’ %}
<div></div>

  1. If the conditional logic are not met display the following line = ```
    {% else %}
    {{ field.label }}
    {{ field.text }}

4. End of If logic condition = ```
 {% endif %}
  1. End of For logic condition = ```
    {% endfor %}

If anyone can help fix my mistake or comprehension please rectify it for me.