Beroepskosten - reconciliation

@sven
Question…

In one of our reports we are using following formula - see below…

Knipsel

This gives the total of the ‘rubriek huur’ we are using in other reconciliation. If we want the total of the sum of ‘totale beperking’ in the ‘rubriek huur’ that is shown in the reconciliation of beroepskosten. How do we code that in our report ?

Thx in advance!

Hello @Andrew,

Is that a custom template you use (so not a standard one from the Silverfin template shop)?

Hello @sven,

we are rebuilding a bit the report of ‘Resultatenrekening (EZ)’ - from the template shop …

One thing we want to add in this report, is the sum van ‘totale beperking’ out of the reconcilliation beroepskosten 2.0. With using formula above, we are getting the sum of ‘aftrekbaar’ in our report. But we the sum of totale beperking. Can you help us out ? What do we have tot add to this formula ?

Thx!

Hello @Andrew,

You’ll need to take the variable or object (that has the amount you wish to link to in another template), in a result-tag.

For instance:

if the register $23 has the amount you wish to link to, you can add it in a result tag like this :

{% result 'total_beperking' $23 %}

So the amount $23 holds, will be saved in the result-tag total_beperking; this can be used in

  • another template other than report, by using this code :

{{ period.reconciliations.handle_beroepskosten.results.total_beperking | currency }}

So we search for any recon-template by the handle named “handle_beroepskosten” and which results there are in there with the result-tag “total_beperking” .

  • report templates, by using this code :

You can use the same code BUT a report is already period-dependant so we’ll use need to use this code (without the period-part) :


{{ reconciliations.handle_beroepskosten.results.total_beperking | currency }}

More info can be found here as well :

@sven

Thx for the help !!

Th result-tag you gave to me, gives the sum of all total_beperking. Using the register $23.

Is it possible to create a result tag per categorie ?

For example - if i want the total_beperking of just the categorie ‘nutsvoorzieningen’.

@Andrew,

That is already present in our standard template :


    {% newline %}
    {% if forloop.last %}
      |     
      | **{% =$21+ $11 as:currency %}** 
      | **{% =$22+ $11-$12 as:currency %}** 
      | **{% =$25+ $11-$15 as:currency %}** 
      | **{% =$23+ $11-$13 as:currency %}** 
      | **{% =$1+ $14 as:currency %}**
      {% result category_key $14 %}| 

So this part : {% result category_key $14 %}will be done in each loop. Each loop has a unique key named the category_key, so you can link to it perfectly in a report (explained here as well).

If you wish to link another result (f.i. the total of the column ‘Fiscal limitation’ for each category), you could do almost the same thing but of course you can’t have twice the same result-tag.
So, in each loop you can do this in the last loop that goes over the selection of accounts :


    {% if forloop.last %}
      |     
      | **{% =$21+ $11 as:currency %}** 
      | **{% =$22+ $11-$12 as:currency %}** 
      | **{% =$25+ $11-$15 as:currency %}** 
      | **{% =$23+ $11-$13 as:currency %}** 
      | **{% =$1+ $14 as:currency %}**
      
      {% capture fiscal_key %}{{ category_key }}_fisc{% endcapture %}
      {% result fiscal_key $11-$15 %}
      
      {% result category_key $14 %}

The amount of fiscal limitation of each category ( category_key ! ) is $11-$15 .
Each loop has a unique category_key (fi ‘huur’) but that’s already used for another result-tag, so we need to create another one.

Hence the capture :

{% capture fiscal_key %}{{ category_key }}_fisc{% endcapture %}

So each catogory key (fi ‘huur’) will be put an extra string after it: ‘_fisc’ so we have this key to go on (unique for each category) :

{{ fiscal_key }} 

This variable can be used now to link to in a report, like this :


reconciliations.community.results.huur_fisc 

Care to take a try @Andrew ?

@sven
Forgot to give you an answer to this. It works! Thx!

Another question concerning the ‘beroepskosten’.

Is their a way to define the % of fiscale beperking of beroepsbeperking, that this is filled in automatically based on a code.

For example restaurantkosten - which is deductable for 69%, that in ‘fiscale beperking’ their automatically is filled in 31%.

Or that you can fill in somewhere your ‘beroepspercentages’ of certain costs and based on this the % percentage of ‘beroepsberperking’ is automatically filled in.

Thx in advance !

Hey @Andrew,

There is.

You could create a new “array” for this for each costs category like this :

{% assign cost_perc_string = "0.50|0.70|0.25|0.40|0.65" %} 

So you’ll have this for instance:

{% if cost_categories_string == blank or cost_keys_string == blank %}
  {% assign cost_categories_string = "Huur en huurlasten|Onderhoud en herstellingen|Leveringen en diensten|Vergoeding aan derden|Divers" %}
  {% assign cost_keys_string = "huur|onderhoud|leveringen|vergoeding|divers" %}
  {% assign cost_perc_string = "0.50|0.70|0.25|0.40|0.65" %}
{% endif %} 

Then, you split on that array and create a new variable :

{% assign cost_perc = cost_perc_string | split:"|" %} 

Now, when you forloop through the cost_categories {% for cost_category in cost_categories %} you’ll need to create a new variable for each loop ( = cost category basically) :

{% assign perc_key = cost_perc[forloop.index0] %} 

So the variable perc_key gives its value for each loop (that’s what the [forloop.index0] does; it goes through the splitted array together with each loop of the cost categories.

In the calculation of each account number, you can create something now like this :

{% $7+input custom[account.number].beperking_2 default:perc_key %}

I use the default for obvious reason, but you can change it. The default-value of the percentage is saved not into the object custom[account.number].beperking_2 but in the register $7.
If you change the percentage, that value will be saved into that object. But that is either way saved as well into the register $7!

For each account number now, you will need to calculate with that register! After the calculation, it’s important to assign it back to zero so you can calculate with it further (if you don’t do that, for each accountnumber the value of the register gets added up) :

{% assign $7 = 0 %} 

Hope this works out for you :slightly_smiling_face:

@sven
This was a bit to difficult for me :wink:

Problem I had is that all the accounts in the cost categories were taken with cost_perc i gave in, what isn’t the intention …

We’re putting our ‘beroeps en fiscale’ berperking in manually.

Thx for the help.

Are you sure @Andrew? Perhaps I can take a look at your code and see where the mistake is? I’ll be glad to help!

I know, but it work good for the moment.

Another question concerning this…

We created a code that links the sum of our fiscal limitation for each category in the reconcillation beroepskosten to the report ‘resultatenrekening EZ’.

Problem i’m seeing now - if you split up your report ‘resultatenrekening EZ’ in PTD’s and at the end you add your YTD totals, is that their is a problem with the sum of our ‘privé en/of fiscale’ beperking.

You see in the end the total is correct, but in he isn’t splitting up the totals in the correct quarters - see example in below…

He just looks at the the quarter of the reconcilliation and puts in the sum of that quarter in the report. The sum at the end of the year is correct, but in the PTD’s he doesn’t correct.

@Andrew,

The numbers for each PTD is caclulated by doing YTD of that period minus YTD of the previous period.
So important to know that, to display the value of each period correctly, the YTD number of each period has to be known.

More info on this here

So if you link to results from a recon template into a report, and want to display each result in PTD as well, be sure to create the result number for each period (meaning you’ll have to create the recon template and fill it in for each period).

@sven

See image below

@Andrew,

I suggest using our first line helpdesk for this, because it’s related in the report and not the Liquid code I think. Also, that way we can see for ourselves :slight_smile:

The helpdesk is through our chat or through support@getsilverfin.com

Thanks for mentionning this

You’re welcome !

’ Another question :slight_smile: I’m to create a template for ‘meerwaarden bij eenmanszaken’, where you fill the inputfield soort as selection, and then he automatically generates the code in de aangifte PB.

I’ve tried below, but the outcome isn’t showing. Do you see what i’m doing wrong ?
Thx !

{% fori detail in current_account.details %}{% assign $1 = 0 %}{% if forloop.first %}

{% ic %}*{% input custom.meerwaarde.soort as:select options:'vrijwllig|gedwongen' %}*{% endic %} {% ic %} *Om welke meerwaarde gaat het ?* {% endic %}

{% if custom.meerwaarde.soort == 'vrijwillig' %}
Meerwaarde afzonderlijk belastbaar tegen 16,5% en op te nemen in code 1603/2603 van de aangifte PB.
{% endif}

|---------|----15%---:|---15%----:|----15%---:|----15%---:+{% endif %}
|
| **{% input detail.custom.description placeholder:'omschr. + fac.nr. + datum' %}** {% input detail.custom.doc as:file %}
|
| {% t "Aankoopdatum" %}               | {% input detail.custom.aankoopdatum as:date %}
| {% t "Verkoopdatum" %}               | {% input detail.custom.verkoopdatum as:date %}
|
| {% t "Aanschaffingswaarde" %}        | {%$1+input detail.custom.aanschaffingswaarde as:currency %}{% ic %}{% if detail.custom.verkoopdatum-detail.custom.aankoopdatum > 5*365 %}
| *{% t "meer dan 5 jaar actief, komt in aanmerking voor gespreide taxatie" %}*{% endif %}{% endic %}
| {% t "Geboekte afschrijvingen" %} {% ic %}*({% t "negatief bedrag" %})*{% endic %} |_{%$1+input detail.custom.afschrijvingen as:currency %}_
| {% t "Boekwaarde" %}                 |                         | {{ $1 | currency }}                       
| {% t "Verkoopprijs" %}               |                         |_{% input detail.custom.verkoopprijs as:currency placeholder_default:0 %}_
| **{% if detail.custom.verkoopprijs-$1 < 0 %}{% t "Boekhoudkundige minderwaarde" %}{% else %}{% t "Boekhoudkundige meerwaarde" %}{% endif %}** | | | **{%=$0+ detail.custom.verkoopprijs-$1 %}**
|| | | |{% if forloop.last %}_{% endif %}{% endfori %}{% unexplained current_account.value+$0 %}
|                           |                         |                               | | **{{$0|currency}}**
|

@Andrew,

May I ask for new questions related to something else other than the original topic, to make a new topic for this in the future? :wink:

Your code has a little mistake:

{% if custom.meerwaarde.soort == 'vrijwillig' %}
Meerwaarde afzonderlijk belastbaar tegen 16,5% en op te nemen in code 1603/2603 van de aangifte PB.
{% endif} 

should be :

{% if custom.meerwaarde.soort == 'vrijwillig' %}
Meerwaarde afzonderlijk belastbaar tegen 16,5% en op te nemen in code 1603/2603 van de aangifte PB.
{% endif %} 

Your {% endif %} was written down wrong.

Major TIP :bulb:

If you create code, you can always type if and then immediately TAB; you’ll see that the editor in Silverfin automatically creates your code (so no chances on writing down wrong code :ok_hand: )

I’ll do that :slight_smile:

I’ve adjusted the code but rests the same. Only the question is shown and if i chose ‘vrijwillig’, no result is shown :thinking:

You made a type again in your as:select; should be vrijwillig instead of vrijwllig @Andrew

This should work now :+1:

Thx!

Another question - i’m having problems with the export of my beroepskosten.

My beroepskosten is working fine, but if I export my beroepskosten to PDF - the export just shows me the accounts that are assigned in my cost_default_string.

Others who are sometime not yet assigned when we are preparing, he doesn’t take in my export.

Any suggestions how to fix ?

Hi @Andrew,

In this case there are a couple of suggestions to fix this:

If it doesn’t help, let us know.