Disable members addition for muted households

Hi
How can we hide “Create Household Member” for muted households
Its possible to achieve this for App forms using the properties.json file. But the solution don’t apply on contact formss.
We have created a household_member-create.properties.json file but it doesn’t help here

{
“context”: {
“expression”: “!contact.muted && !contact.date_of_death”
}
}

we also tried adding contact type as below - but this is hiding the button for Muted and Unmuted

{
“context”: {
“expression”: “!contact.muted && !contact.date_of_death && contact.contact_type === ‘household’”
}
}

Unfortunately, I am not sure your desired behavior is possible at this time.

The expression value for contact forms actually does not have access to the contact (or summary) data, which is why you are experiencing the described behavior. I have opened a docs PR to clarify this on the docs sight. Also, there is an open cht-core issue for adding this functionality:

1 Like

Thank you @jkuester
For your feedback

1 Like