Fiscal balance - liberal professions

Dear,

I’m trying to make a fiscal balance that sufficient for liberal professions.

  • stock is inapplicable
  • cost of ‘60’–accounts should be added up bij the other indirect costs.

I’ve started from the existing template “beroepskosten EZ”.
In my output, the correct accounts were linked to the correct hashtack, but they does not appear.

This is my code for the moment. Which changes do I have to make so the accounts appear?

{% assign revenue_default = revenue_default | default:"70__74" %}
{% assign trade_goods_default = trade_goods_default | default:"60" %}
{% assign assigned_accounts_range_default = assigned_accounts_range_default | default:'6,7' %} 




{% t= "Detail van de kosten" fr:"Détails des frais" en:"Detail of all costs" %}
{% t= "Beroeps-<br />beperking" fr:"Limite professionnelle" en:"Occupational limitation" %}
{% t= "Fiscale beperking" fr:"Limite fiscale" en:"Fiscal limitation" %}
{% t= "Totale beperking" fr:"Limite totale" en:"Total limitation" %}
{% t= "Aftrekbaar" fr:"Déductible" en:"Deductible" %}
{% t= "aftrekbaar" fr:"déductible" en:"deductible" %}
{% t= "Niet aftrekbaar" fr:"Non déductible" en:"Not deductible" %}
{% t= "Ontvangsten/Baten/Omzet" fr:"Chiffre d'affaires" en:"Revenues" %}

{% t= "Voorraadwijziging" fr:"Variation de stock" en:"Change in stocks" %}
{% t= "Toon beginvoorraad - eindvoorraad boekjaar" fr:"Afficher le stock initial - le stock final de l'exercice" en:"Show initial - final stock for the financial year"%}
{% t= "Beginvoorraad" fr:"Stock initial" en:"Initial stock" %}
{% t= "Eindvoorraad" fr:"Stock final" en:"Final stock" %}

{% t= "Verkochte voorraad" fr:"Stock vendu" en:"Stock sold" %}
{% t= "Brutowinst" fr:"Résultat brut" en:"Gross profit" %}
{% t= "Sociale bijdragen" fr:"Cotisations sociales" en:"Social contributions" %}
{% t= "Toekenning meewerkende echtgeno(o)t(e)" fr:"Attribution au conjoint aidant" en:"Allocation helping spouse" %}
{% t= "Kosten" fr:"Frais" en:"Costs" %}
{% t= "Nettoresultaat" fr:"Résultat net" en:"Net result" %}
{% t= "Niet toegewezen bedrag" fr:"Montant non affecté" en:"Unassigned amount" %}
{% t= "Alle rekeningen zijn opgenomen" fr:"Tous des comptes sont inclus" en:"All accounts are selected" %}
{% t= "Eén of meerdere rekeningen werden meermaals toegewezen" fr:"Un ou plusieurs comptes ont été attribués plusieurs fois" en:"One or more accounts were selected more than once" %}
{% t= "Niet alle rekeningen zijn opgenomen" fr:"Tous les comptes ne sont pas inclus" en:"Not all accounts are selected" %}
{% t= "Handelsgoederen, grond en hulpstoffen" fr:"Marchandises, matières premières et matières consommables" en:"Goods for resale, raw materials and additives" %}
{% t= "Verkochte goederen" fr:"Biens vendus" en:"Sold goods" %}
{% t= "Huur en huurlasten" fr:"Location et frais de location" en:"Rent and rental expenses" %}
{% t= "Onderhoud en herstellingen" fr:"Entretien et les réparation" en:"Maintenance and repair" %}
{% t= "Leveringen en diensten" fr:"Fournitures et les services" en:"Supplies and services" %}
{% t= "Vergoeding aan derden" fr:"Frais de tiers" en:"Remuneration to third parties" %}
{% t= "Totaal" fr:"Total" en:"Total" %}
{% t= "Divers" fr:"Divers" en:"Miscellaneous" %}
{% t= "Extra toelichting" fr:"Explication supplémentaire" en:"Additional explanation" %}
{% t= "Naam" fr:"Nom" en:"Name" %}
{% t= "Nr." fr:"N°" en:"No." %}
{% t= "Bedrag" fr:"Montant" en:"Amount" %}
{% t= "Kosten werden reeds aan het beroepsmatig percentage in de boekhouding verwerkt" fr:"Les frais ont déjà été limités au pourcentage professionnel dans la comptabilité" en:"Costs have already been booked at the professional percentage in the accounting software" nl:"Kosten werden reeds aan het beroepsmatig percentage in de boekhouding verwerkt" default:"Costs have already been booked at the professional percentage in the accounting software" %}


{% if cost_categories_string == blank %}
   {% assign cost_categories_string = "Aankopen|Huur en huurlasten|Onderhoud en herstellingen|Algemene werkingskosten|Kantoorkosten|Nutsvoorzieningen|Verzekeringen|Commissies en erelonen|Verplaatsingskosten|Publiciteit en representatie|Personeelskosten|Afschrijvingen|Andere bedrijfskosten|Financiële kosten|Uitzonderlijke kosten" %}
  {% assign cost_keys_string = "aankopen|huur|onderhoud|werkingskosten|kantoorkosten|nutsvoorzieningen|verzekering|commissies|verplaatsing|representatie|personeelskosten|afschrijvingen|divers|finkosten|uitzkosten" %}
{% endif %}

{% assign cost_categories = cost_categories_string | split:"|" %}

{% if cost_keys_string != blank %}
  {% assign cost_keys = cost_keys_string | split:"|" %}
{% endif %}

{% assign toegewezen = "" %}
{% assign def_voorraadwijziging = "" %}
{% assign count = 0 %}

{% for cost_category in cost_categories %}
  {% if cost_keys_string != blank %}
    {% assign category_key = cost_keys[forloop.index0] %}
  {% else %}
    {% assign category_key = cost_category | replace:" ","_" | downcase %}
  {% endif %}
  
  {% capture range_key %}{{ category_key }}_range{% endcapture %}
  {% capture default_key %}{{ category_key }}_default{% endcapture %}

  {% if [default_key] != blank %}
    {% assign aankopen_range = aankopen_range | default:global_60_range %}
    {% assign aankopen_default = aankopen_default | default:"60" %}
    {% assign huur_range = huur_range | default:global_610_range %}
    {% assign huur_default = huur_default | default:"6100,6101,6102,610495,610496" %}
    {% assign onderhoud_range = onderhoud_range | default:global_6105_range %}
    {% assign onderhoud_default = onderhoud_default | default:"6105,6106,6107,61258" %}
    {% assign werkingskosten_range = werkingskosten_range | default:global_6114_range %}
    {% assign werkingskosten_default = werkingskosten_default | default:"61140,6112" %}
    {% assign kantoorkosten_range = kantoorkosten_range | default:global_6163_range %}
    {% assign kantoorkosten_default = kantoorkosten_default | default:"6163,6162,6128,6129,61665,61654,61653,6110,6111,6113,61145,6160,6161,6120__6124" %}
    {% assign nutsvoorzieningen_range = nutsvoorzieningen_range | default:global_611_range %}
    {% assign nutsvoorzieningen_default = nutsvoorzieningen_default | default:"6115,6116,6117,6118,6119" %}
    {% assign verzekering_range = verzekering_range | default:global_613_range %}   
    {% assign verzekering_default = verzekering_default | default:"6130,6131,6132,6135,6136,6137,6138,6139" %}
    {% assign commissies_range = commissies_range | default:615 %}
    {% assign commissies_default = commissies_default | default:"615" %}
    {% assign verplaatsing_range = verplaatsing_range | default:global_6103_range %}
    {% assign verplaatsing_default = verplaatsing_default | default:"6103,61250__61253,61080__61083,61260__61263,61265__61268,61340__61341,64020,640210__640218,64071,640703,61040,61084,61254,61264,61344,640219,64025,640705,61049,61085__61089,61255,61269,61349,6127,614,616703,616704,616705,61259,64022,6403" %}
    {% assign representatie_range = representatie_range | default:global_6166_range %}
    {% assign representatie_default = representatie_default | default:"61660__61664,61645,61640__61644,61650__61652,61666__61669,6168,6169,616700__616702,61671__61675" %}
    {% assign afschrijvingen_range = afschrijvingen_range | default:global_63_range %}
    {% assign afschrijvingen_default = afschrijvingen_default | default:"63" %}
    {% assign divers_range = divers_range | default:global_64_range %}
    {% assign divers_default = divers_default | default:"6400,6401,6404,6405,6406,640700,640701,640702,6408__6409,641__649" %}
    {% assign finkosten_range = finkosten_range | default:global_65_range %}
    {% assign finkosten_default = finkosten_default | default:"65" %}
  {% else %}
    {% assign costs_range = custom[category_key].selected | default:custom[category_key].accounts %}
  {% endif %}

  {% assign costs = period.accounts.include_zeros | range:costs_range %}
  {% for account in costs %}
    {% assign toegewezen = toegewezen | append:"$" | append:account.mapped_number | append:"$;" %}
  {% endfor %}
{% endfor %}

{% assign omzet_range = custom.detail.omzet | default:revenue_default %}
{% assign omzet = period.accounts.include_zeros| range:omzet_range %}
{% for account in omzet %}
  {% assign toegewezen = toegewezen | append:"$" | append:account.mapped_number | append:"$;" %}
{% endfor %}

{% assign goederen_range = custom.detail.goederen | default:trade_goods_default %}
{% assign goederen = period.accounts.include_zeros| range:goederen_range %}
{% for account in goederen %}
  {% assign toegewezen = toegewezen | append:"$" | append:account.mapped_number | append:"$;" %}
{% endfor %}


{% comment %}
---------------------
Configuration options
---------------------
{% endcomment %}

{% assign partner_default = partner_default | default:"" %}
{% assign social_default = social_default | default:"61330,61331" %}



{% assign sociale_bijdrage_range = custom.detail.sociale_bijdrage | default:social_default %}
{% assign sociale_bijdrage = period.accounts.include_zeros| range:sociale_bijdrage_range %}
{% for account in sociale_bijdrage %}
  {% assign toegewezen = toegewezen | append:"$" | append:account.mapped_number | append:"$;" %}
{% endfor %}

{% assign echtgenote_range = custom.detail.echtgenote | default:partner_default %}
{% assign echtgenote = period.accounts.include_zeros| range:echtgenote_range %}
{% for account in echtgenote %}
  {% assign toegewezen = toegewezen | append:"$" | append:account.mapped_number | append:"$;" %}
{% endfor %}

{% for extra_kost in custom.extra_kosten %}
  {% assign accounts = period.accounts.include_zeros | range:extra_kost.accounts %}
  {% for account in accounts %}
  {% assign toegewezen = toegewezen | append:"$" | append:account.mapped_number | append:"$;" %}
  {% endfor %}
{% endfor %}

{% for extra_account in custom.extra_accounts %}
  {% assign accounts = period.accounts.include_zeros | range:extra_account.accounts %}
  {% for account in accounts %}
  {% assign toegewezen = toegewezen | append:"$" | append:account.mapped_number | append:"$;" %}
  {% endfor %}
{% endfor %}

{% comment %}-----DETERMINE-RANGES-FOR-ACCOUNT-COLLECTIONS-----{% endcomment %}

{% assign global_6_range = "" %}
{% assign accounts = period.accounts.include_zeros | range:'6' %}

{% for account in accounts %}
{% assign numberwithdollar = account.mapped_number | prepend:"$" | append:"$" %} 
  {% unless toegewezen contains numberwithdollar %}
    {% unless global_6_range == blank %}{% assign global_6_range = global_6_range | append:"," %}{% endunless %}
    {% assign global_6_range = global_6_range | append:account.mapped_number %}
  {% endunless%}
{% endfor %}

{% assign global_7_range = "" %}
{% assign accounts = period.accounts.include_zeros | range:'7' %}

{% for account in accounts %}
{% assign numberwithdollar = account.mapped_number | prepend:"$" | append:"$" %}
  {% unless toegewezen contains numberwithdollar %}
    {% unless global_7_range == blank %}{% assign global_7_range = global_7_range | append:"," %}{% endunless %}
    {% assign global_7_range = global_7_range | append:account.mapped_number %}
  {% endunless%}
{% endfor %}

{% assign global_range = global_6_range | append:"," | append:global_7_range %}

{% comment %}
---------------------
Configuration options


---------------------
{% endcomment %}
{% assign revenue_range = revenue_range | default:global_7_range %}
{% assign revenue_default = revenue_default | default:"70__74" %}
{% assign trade_goods_range = trade_goods_range | default:global_6_range %}
{% assign trade_goods_default = trade_goods_default | default:"60" %}
{% assign social_range = social_range | default:global_6_range %}
{% assign social_default = social_default | default:"61330,61331" %}
{% assign partner_range = partner_range | default:global_6_range %}
{% assign aankopen_range = aankopen_range | default:global_60_range %}
    {% assign aankopen_default = aankopen_default | default:"60" %}
    {% assign huur_range = huur_range | default:global_610_range %}
    {% assign huur_default = huur_default | default:"6100,6101,6102,610495,610496" %}
    {% assign onderhoud_range = onderhoud_range | default:global_6105_range %}
    {% assign onderhoud_default = onderhoud_default | default:"6105,6106,6107,61258" %}
    {% assign werkingskosten_range = werkingskosten_range | default:global_6114_range %}
    {% assign werkingskosten_default = werkingskosten_default | default:"61140,6112" %}
    {% assign kantoorkosten_range = kantoorkosten_range | default:global_6163_range %}
    {% assign kantoorkosten_default = kantoorkosten_default | default:"6163,6162,6128,6129,61665,61654,61653,6110,6111,6113,61145,6160,6161,6120__6124" %}
    {% assign nutsvoorzieningen_range = nutsvoorzieningen_range | default:global_611_range %}
    {% assign nutsvoorzieningen_default = nutsvoorzieningen_default | default:"6115,6116,6117,6118,6119" %}
    {% assign verzekering_range = verzekering_range | default:global_613_range %}   
    {% assign verzekering_default = verzekering_default | default:"6130,6131,6132,6135,6136,6137,6138,6139" %}
    {% assign commissies_range = commissies_range | default:615 %}
    {% assign commissies_default = commissies_default | default:"615" %}
    {% assign verplaatsing_range = verplaatsing_range | default:global_6103_range %}
    {% assign verplaatsing_default = verplaatsing_default | default:"6103,61250__61253,61080__61083,61260__61263,61265__61268,61340__61341,64020,640210__640218,64071,640703,61040,61084,61254,61264,61344,640219,64025,640705,61049,61085__61089,61255,61269,61349,6127,614,616703,616704,616705,61259,64022,6403" %}
    {% assign representatie_range = representatie_range | default:global_6166_range %}
    {% assign representatie_default = representatie_default | default:"61660__61664,61645,61640__61644,61650__61652,61666__61669,6168,6169,616700__616702,61671__61675" %}
    {% assign afschrijvingen_range = afschrijvingen_range | default:global_63_range %}
    {% assign afschrijvingen_default = afschrijvingen_default | default:"63" %}
    {% assign divers_range = divers_range | default:global_64_range %}
    {% assign divers_default = divers_default | default:"6400,6401,6404,6405,6406,640700,640701,640702,6408__6409,641__649" %}
    {% assign finkosten_range = finkosten_range | default:global_65_range %}
    {% assign finkosten_default = finkosten_default | default:"65" %}


  
{% assign hide_beroepsbeperking_col = custom.detail.hide_beroepsbeperking_col | default:false %}


{% capture header %}|-----------10%---------------|-----------30%---------------|---------------15%-----------:|---------------15%-----------:|---------------15%-----------:|---------------15%-----------:+{% endcapture %}

{% comment %}generate cost values first, to show later on{% endcomment %}
{% capture table %}

{% ic %}{% input custom.detail.hide_beroepsbeperking_col as:boolean %}{% t "Kosten werden reeds aan het beroepsmatig percentage in de boekhouding verwerkt" %}{% endic %}

-----------------------------------------------------------------------------------------------------------

{% stripnewlines %}
{{ header }}
{% newline %}
| **{% t "Nr." %}**
| **{% t "Detail van de kosten" %}**    
| **{{ period.year_end_date | date:'%Y' }}**
|{% unless hide_beroepsbeperking_col %} **{% t "Beroeps-<br />beperking" %}**<br />**({% t "aftrekbaar" %})** {% endunless %}
| **{% t "Fiscale beperking" %}**<br />**({% t "aftrekbaar" %})**
| **{% t "Aftrekbaar" %}**                      
{% newline %}                
{% newline %}
-----------------------------------------------------------------------------------------------------------
{% newline %}                
{% newline %}
{% for cost_category in cost_categories %}
  {% assign $11 = 0 %}
  {% assign $12 = 0 %}
  {% assign $13 = 0 %}
    {% if cost_keys_string != blank %}
    {% assign category_key = cost_keys[forloop.index0] %}
  {% else %}
    {% assign category_key = cost_category | replace:" ","_" | downcase %}
  {% endif %}

{% capture range_key %}{{ category_key }}_range{% endcapture %}

{% if [range_key] != blank %}

  {% assign accounts = period.accounts.include_zeros | range:[range_key] %}
  
  {% for account in accounts %}
  {% assign numberwithdollar = account.mapped_number | prepend:"$" | append:"$" %} 
    {% unless toegewezen contains numberwithdollar %}
      {% unless [range_key] == blank %}{% assign [range_key] = [range_key] | append:"," %}{% endunless %}
      {% assign [range_key]  = [range_key]  | append:account.mapped_number %}
    {% endunless%}
  {% endfor %}
{% endif %}


  {% capture default_key %}{{ category_key }}_default{% endcapture %}

  {% if [default_key] != blank %}
    {% assign afschrijvingen_range = afschrijvingen_range | default:global_63_range %}
    {% assign afschrijvingen_default = afschrijvingen_default | default:"63" %}
    {% assign divers_range = divers_range | default:global_64_range %}
    {% assign divers_default = divers_default | default:"64" %}
    {% assign finkosten_range = finkosten_range | default:global_65_range %}
    {% assign finkosten_default = finkosten_default | default:"65" %}
  {% else %}
    {% assign costs_range = custom[category_key].selected | default:custom[category_key].accounts %}
  {% endif %}
  
    {% ifi costs_range != blank %}
{% newline %}
  {% if [range_key] == blank %}{% assign [range_key] = global_range %}{% endif %}
  || **{% t cost_category %}** {% input custom.[category_key].accounts as:account_collection range:[range_key] default:[default_key] %}
 
  {% ic %}{% assign costs = period.accounts.include_zeros | range:costs_range %}{% endic %}
  {% nic %}{% assign costs = period.accounts | range:costs_range %}{% endnic %}
  
  {% newline %}
  {{ header }}
  {% newline %}
  {% for account in costs %}
    {% capture account_id %}{{ account.id }}{% endcapture %}
    {% assign vin_old = 1-custom[account_id].vin %}
    {% assign beperking_old = 1-custom[account_id].beperking %}
    {% assign vin_new = custom[account_id].vin_new | default:vin_old %}
    {% if vin_new == blank %}
      {% assign vin = 0 %}
    {% else %}
      {% assign vin = vin_new %}
    {% endif %}
    
    {% assign beperking_new = custom[account_id].beperking_new | default:beperking_old %}
    {% if beperking_new == blank %}
      {% assign beperking = 0 %}
    {% else %}
      {% assign beperking = beperking_new %}
    {% endif %}
    
    | {{ account.number }}
    | {{ account.name }}
    | {%=$11+ -1*account.value as:currency %}
    | {% unless hide_beroepsbeperking_col %}{% input custom[account_id].vin_new as:percentage placeholder:'0.00%' default:vin_old %}{% endunless %}
    | {% input custom[account_id].beperking_new as:percentage placeholder:'0.00%' default:beperking_old %}
    | {% if hide_beroepsbeperking_col %}
        {{ -1*beperking*account.value | currency }}
        {% $13+ -1*beperking*account.value | currency: 2 %}
      {% else %}
        {{ -1*vin*beperking*account.value | currency }}
        {% $13+ -1*vin*beperking*account.value | currency: 2 %}
      {% endif %}
    {% newline %}
    {% if forloop.last %}
      |
      |     
      | **{% =$21+ $11 as:currency %}** 
      |
      |
      | **{% =$23+ $13 as:currency %}** {% $1+ $13 as:currency %}
      |
    {% newline %}
    {% endif %}
    {% endfor %}
  {% result category_key $13 %}
  {% newline %}
    {% endifi %}
{% endfor %}
{% newline %}                
{% newline %}
-----------------------------------------------------------------------------------------------------------
{% newline %}                
{% newline %}
{% endstripnewlines %}

{{ header }}
|| **{% t "Totaal" %}**                  | **{{ $21 | currency }}** {% result 'total_costs' $21 %} | | | **{{ $23 | currency }}**{% result 'total_deductible_actual_costs' $23 %}

-----------------------------------------------------------------------------------------------------------

{% endcapture %}

{% comment %}table where nett result is calculated{% endcomment %}

{% stripnewlines %}
{% newline %}
|---------------------|-------15%-------:|-------15%-------:|-------15%-------:+
{% newline %}
| {% t "Ontvangsten/Baten/Omzet" %} {% input custom.detail.omzet as:account_collection range:revenue_range default:revenue_default %}| | | {%=$10+ -1*omzet.value | currency %}
{% assign omzet = period.accounts | range:omzet_range %}
{% for account in omzet %}
  {% $31+ account.value %}
  {% newline %}
  | &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{{ account.name }}|{{ -1*account.value | currency }}
{% endfor %}
{% assign goederen = period.accounts | range:goederen_range %}
{% ifi goederen.name != blank %}

{% newline %}
| **{% t "Brutowinst" %}**        ||| **{{ $10 | currency }}**{% comment %}Result for insights queries - flat rate costs{% endcomment %}{% result 'gross_profit' $10 %}{% endifi %}{% assign flat_rate_costs = $10*0.03 | currency %}{% result 'flat_rate_costs' flat_rate_costs %}
{% ifi sociale_bijdrage.value != 0 %}
{% newline %}
| {% t "Sociale bijdragen" %} {% input custom.detail.sociale_bijdrage as:account_collection range:social_range default:social_default %} {% input custom.sociale_bijdrage.doc as:file %}| | | {%=$10+ -1*sociale_bijdrage.value | currency %}{% result 'sociale_bijdrage' -1*sociale_bijdrage.value %}{% endifi %}{% ifi echtgenote.value != 0 %}
{% newline %}
  | {% t "Toekenning meewerkende echtgeno(o)t(e)" %} {% input custom.detail.echtgenote as:account_collection range:partner_range default:partner_default %} {% input custom.echtgenoot.doc as:file %} | | | {%=$10+ -1*echtgenote.value | currency %}{% result 'echtgenote' -1*echtgenote.value %}
  {% endifi %}
  {% assign bruto_winst = $10 %}

| {% fori extra_kost in custom.extra_kosten %}
  {% newline %}
  |{% input extra_kost.name %} {% input extra_kost.accounts as:account_collection range:global_range %}{% input extra_kost.doc as:file %} | | |{% assign accounts = period.accounts.include_zeros | range:extra_kost.accounts %}{% if extra_kost.accounts != blank %}{% =$14+ accounts.value*-1 %}{% else %}{% $14+input extra_kost.value as:currency default:-1*accounts.value %}{% endif %}
{% endfori %}
{% $10+ $14 %}
{% result "extra_kosten" $14 %}
{% newline %}
  | {% t "Kosten" %}              | | |_{% =$10+ $1 %}_
{% newline %}
  | **{% t "Nettoresultaat" %}**      | | | **{{ $10 | currency }}**
  {% comment %}result tag for SF Insights{% endcomment %}
  {% result 'nettoresultaat' $10 %}
{% newline %}
  |
  | {% fori extra_account in custom.extra_accounts %}
    {% newline %}
    |{% input extra_account.name %} {% input extra_account.accounts as:account_collection range:global_range %}{% input extra_account.doc as:file %} | | |{% assign accounts = period.accounts.include_zeros | range:extra_account.accounts %}{% if extra_account.accounts != blank %}{% =$10+ accounts.value*-1 %}{% else %}{% $10+input extra_account.value as:currency default:-1*accounts.value %}{% endif %}
    {% if extra_account.accounts != blank %}{% assign extra_accounts_value = extra_accounts_value+accounts.value*-1 %}{% else %}{% assign extra_accounts_value = extra_accounts_value+extra_account.value %}{% endif %}
  {% endfori %}{% result 'extra_accounts' extra_accounts_value %}
  |
{% endstripnewlines %}

{% newpage %}

{% comment %}table where costs are shown{% endcomment %}
{{ table }}

<!----------------------------------------- check to see if all accounts have been used JUST ONCE ----------------------------------------->
{% assign accounts = period.accounts.include_zeros | range:assigned_accounts_range_default %}
{% assign count_6_7 = accounts.count %}
{% assign toegewezen = toegewezen | remove:"$" %}
{% assign count_toegewezen = toegewezen | split:";" %}
{% assign toegewezen_range = count_toegewezen | join:"," %}
{% assign count_toegewezen = count_toegewezen.size %}

{% assign toegewezen_bedrag = period.accounts | range:toegewezen_range %}

{% assign niet_toegewezen = accounts-toegewezen_bedrag.value %}

{% capture check_acc_ind %}{% unreconciled niet_toegewezen as:indicator %}{% endcapture %}

{% ic %}
*{% t "Niet toegewezen bedrag" %} {{ niet_toegewezen | currency }}* {{ check_acc_ind }}

{% if count_6_7 > count_toegewezen %}

{% stripnewlines %}
| *{% t "Nr." %}* | *{% t "Naam" %}* | *{% t "Bedrag" %}*
{% newline %}
|--7%--|----|----:#+
{% newline %}
{% for account in accounts %}
  {% unless toegewezen contains account.mapped_number %}
           | *{{ account.number }}* | *{{ account.name }}* | *{%=$30+ account.value | currency %}*
    {% newline %}
      {% if forloop.last %}
      |                      |                      | _*{{ $30 | currency }}*_ 
      {% endif %}
  {% endunless %}
{% endfor %}
{% endstripnewlines %}
{% endif %}

{% endic %}

{% comment %}additional comments{% endcomment %}
{% ifi custom.extra.bijlage.document or custom.extra.toelichting != blank %}<br>

{% stripnewlines %}
|------
|------
{% newline %}
| **{% t "Extra toelichting" %}**
| {% input custom.extra.bijlage as:file placeholder:'' %}
{% endstripnewlines %}

{% input custom.extra.toelichting as:text placeholder:'' %}
{% endifi %}

Hi @jolien.hoekman ,

Welcome to the community! Please have a read on how to post liquid code in a community post here.

We are here to help you but we do not review complete template code here. Can you please specify what section in specific is not working? What are your additions to the template “beroepskosten EZ”?

Please try to paste only relevant code.

Kind regards,

Michiel