Object level script are not working because lookup is overriding it.
you can use below steps to achieve the requirement:
- Create a table domain
object: COMMTEMPLATE
list where clause: templateid LIKE 'TR-%
validation where clause: templateid LIKE 'TR-%
2. Create attribute launch point to attached the domain id dynamically (i am not checking person cgdivision in below script please add it)
Object: COMMLOG
Attribute: TEMPLATEID
event: retrieve list
code:
current_app = mbo.getThisMboSet().getParentApp()
if current_app == "WOTRACK":
domainid="MJN_TR_ONLY_DOMAIN"
I hope this will work for you.