and use that variable in your if-statement. I’ll check later on onto why that “@” is not working properly.
For the reconciled status, that’s hard to check for me, without all other code. What i would do, is add this in your code, so you know if the IF-statements are executed or not, and which one:
{% comment %}Set variables on answers to questions below{% endcomment %}
{% if custom.opdrachtbevestiging.value != "Ja" %}
Test custom.opdrachtbevestiging.value
{% assign check_opdracht = check_opdracht+1 %}{% unreconciled 1 %}
{% endif %}
{% if period.custom.admin.uren == 0 %}
Test period.custom.admin.uren
{% assign check_opdracht = check_opdracht+1 %}{% unreconciled 1 %}
{% endif %}
{% if period.custom.control.uren == 0 %}
Test period.custom.control.uren
{% assign check_opdracht = check_opdracht+1 %}{% unreconciled 1 %}
{% endif %}
{% if custom.fee.value != "Ja" and custom.fixed_fee.Verklaring == blank %}
test custom.fee.value != "Ja" and custom.fixed_fee.Verklaring
{% assign check_opdracht = check_opdracht+1 %}{% unreconciled 1 %}{% unreconciled 1 %}
{% endif %}
{% if company.custom.team.value == blank %}
test company.custom.team.value
{% assign check_opdracht = check_opdracht+1 %}{% unreconciled 1 %}
{% endif %}
{% if company.custom.relatiebeheerder.value == blank %}
test company.custom.relatiebeheerder.value
{% assign check_opdracht = check_opdracht+1 %}{% unreconciled 1 %}
{% endif %}
If nothing is seen from above code, then it’s correct that the template becomes reconciled, and something has to be tweaked in the code.
Your parts/setvars will only be executed when the if-statement is true, meaning that only in that situation your template can become unreconciled.
If the statement is not true however, your template will be automatically set on reconciled if the type of reconciliation is set on this:
When it would be set on Reconciliation necessary, and invalid without data, then the recon would stay unreconciled unless someone would enter a value somewhere.
By the way, I would recommend leaving the unreconciled out of the if-statement. Unless I’m misunderstanding the issue, I don’t think reconciling should be user-specific.
Yes, you are correct, but the issue is this. The unreconclied is now basically in a nested if statement and both if statements are true. If I take the include out of the equation it would look like this, correct?
The second if statement gives me the desired result (True, and the assign is fired), but the unreconciled is not handled. This seems unconnected to the reconciliation type, as The unreconnciled is triggered if I take it out of the first if statement.
Reconciling is actually user specific. An external user does not need to do anything with the template, so it is okay for an external user to see the template as reconciled.
As I’m typing this: could that be the actual issue? Is what I want even possible? Because the reconciliation would give the same result for all users, right? Is the template itself reconciled by a system user? That would explain the issue…
I’m having the same feeling, but I’ll need to dig deeper to be sure. I can simulate it now, where my recon is reconciled while I see an indicator in my template, so that is not what should be happening.
I’ll keep you informed.
By the way: any user should be able to see whether or not the recon is reconciled, no?
I agree on the content being hidden from certain users, but the reconciliation itself is a use-case I haven’t heard yet
Ideally I would be able to control it. So external users see the template as reconciled (as they do not have to do anything themselves), while internal users see the reconciliation based on the actual code.
I could work around the issue, but I’d just rather not…
I already have some feedback, and I’m afraid it’ll debunk the case.
Reconciliation cannot be user specific; it needs to be the same for everyone. We rely on this fact for performance as well which is why we cache the result.
If it would be user specific we couldn’t cache it plus the workflow completion calculations would be done per user and we wouldn’t be able to cache those either which would pretty much lock the platform.
So the way we do it is that we simply don’t pass user drop when calculation reconciled state for ledger. As a consequence unreconciled inside a if block that checks anything on an user will simply be false/ignored.
So I hope this helps you understand why we do this.
Is it an option for you to just hide parts of the template for specific users, and leave the reconciliation for everyone?
As you can see, I’m having a hard time to see the benefit on why hiding a reconciliation from anyone
Feel free to fill me in on this @ronald_groot_RSF
Okay, thanks. I kind off figured it would be that. Makes total sense as well. It’s not that I want to hide the reconciliation, it’s just that I thought it would be easiest to just not show it to prevent questions.
But this is totally fine. Like I said, I already have a workaround in place (by simply not including the setting of the reconciliation within the user if-statement.