Table of Contents |
---|
...
Show/Hide custom field – Using Regex Matching
Show the 'Lived Name' custom field only when the PPID starts with 'J'.
...
Code Block |
---|
{
"name": "cpr.participant.extensionDetail.attrsMap.lived_name",
"caption": "Lived Name",
"type": "text",
"optional": "true",
"showIf": {
"op": "AND",
"rules": [
{
"field": "cpr.ppid",
"op": ".search('^J') !=", // Modify the regex in single quote as per requirement.
"value": "-1"
}
]
}
}
|
Show/Hide Custom field based on CP site
Expand | ||
---|---|---|
#1. When CP SiteName is an Amol site, then only it will show the custom field 'Live Nucleated Count (MCells)'. Code: Code Block |
} Screenshot: #2. When CP SiteName is not Amol site, then not show the custom field 'Live Nucleated Count (MCells)'. Code: Code Block |
{
"op": "NOT",
"rules": [
{
"field": "cp.siteName",
"op": "==",
"value": "'Amol site'"
}
]
},
"showInOverviewIf": "useShowIf"
}Screenshot: |