# Beroepskosten 2.0 - default accounts with categories

**URL:** <https://community.silverfin.com/t/beroepskosten-2-0-default-accounts-with-categories/543>\
**Category:** Templates\
**Tags:** ifi, attribute\_default, iterations, for\_loop\
**Created:** [December 15, 2017, 2:45pm UTC](https://community.silverfin.com/t/beroepskosten-2-0-default-accounts-with-categories/543 "2017-12-15T14:45:03Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![sven](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.silverfin.com/sven/32/1495_2.png) [@sven](https://community.silverfin.com/u/sven)\
**Post date:** [December 18, 2017, 12:17pm UTC](https://community.silverfin.com/t/beroepskosten-2-0-default-accounts-with-categories/543/6 "2017-12-18T12:17:07Z")

</div>

> [@Cedric](#):
>
> {% ifi custom.anderebo.accounts != blank %}  
> {{ detailanderebo }}  
> \<br\>{% endifi %}

@Cedric,

It’s this statement that decides whether or not the export will display the accounts.

Your ifi-statement is looking at the object `custom.anderebo.accounts` but that object will be empty by default, even if you use a default-account range!  
That object will not be empty or blank, when you actually press the button # and drag some accounts in it.

It’s a very wierd thing to work with an input-tag and a default-value to it. You can clearly see the behaviour, if you do this :

```auto
{{ custom.anderebo.accounts }}

```

It won’t show anything.  
However, if you press the # and drag an account in it, you’ll see what happens: the object now does have a value.

Why? An input-object will only have actual data in the object, only if you actualle put in data in there.  
The default-value added to it, is only some sort of a layer over the object (to show in input and export mode), but it doesn’t actually input the value in the object.

I’ll admit, strange in the beginning but I have explicitly documented this in the slides of the workshops.

To get back to a solution:

You have a collection that stores all the accounts, so why not do a check on the collection `anderebo`?

For instance :

```auto
{% ifi anderebo != empty %}
{{ detailanderebo }}
<br>{% endifi %}

```

or

```auto
{% ifi anderebo.value != 0 %}
{{ detailanderebo }}
<br>{% endifi %}

```

Could you give it a go ?

Nice looking template by the way 👍

---

_[View the full topic](https://community.silverfin.com/t/beroepskosten-2-0-default-accounts-with-categories/543)._
