Hello,
I am trying to hide the Primary Contact Field in the Account Form if the Business Unit of the User viewing this Account form is different from this Account Record's Owning Business Unit.
If the User's Business Unit is the same as the Account record's Owning Business Unit, or if the User's Business Unit is a parent BU of the Account Record's owning BU, the Primary Contact Field should be visible.
Ex: If Account Record named 'X' belongs to a business unit called 'BU 1', any user in Business Unit 'BU 1' should be able to see this account's primary contact. And any user in a parent Business Unit of 'BU 1' should also be able to see the primary contact.
Can someone help regarding accomplishing this using Javascript please?