IF, OR statements in HTML mode in Org Chart

Hello,
in OrgChart in the Box template compartment, HTML mode, I want to display a field only if the condition that this field has certain values is met. I used the #IF, #OR statements in various combinations, but without success.

{{#if AgileOrchestra=="RBLO" #or AgileOrchestra=="BBLO"}} Orchestra: {{AgileOrchestra}} {{/if}}

Please help me write the correct syntax.
Thank you

Hello Alexandru! The #if helper does not allow you to compare values but rather checks wether the provided values does not return false. For your case, I would advise you just to assign a custom class to the required block:


Then, use this custom JS code to add another custom class to the block if its value meets the condition:

renderer.onBoxRendered(function(event, box, itemData){
  //Box rendered event
  if (itemData["Department"] == "Financial Department" || itemData["Deparment"] == "Production Department") {
    box.$elem.find(".department").addClass("displayed");
  }
});

And with custom CSS, hide the class set in the box template and display one added in the JS code:

Thus, it hides the "Department" field if it is not "Financial Department" or "Production Department":