Hi Team,
The requirement is to implement the Opportunity metrics container, like (Manager Mood, Probability) in the lead section based on some condition as (Lookup value - changes to "Opportunity") to the instance of version 8 and above.
Reference image is added below,
In the latest version we don't have this similar UI rather its updated to latest one in opportunity Section as below,
I have identified the code for the above metrics from base file "Base Opportunity edit page" as shown below,
{
"operation": "merge",
"parentName": "ProfileContainer",
"propertyName": "items",
"name": "MetricsContainer",
"values": {
"layout": {"column": 0, "row": 0, "colSpan": 24},
"itemType": Terrasoft.ViewItemType.CONTAINER,
"classes": {"wrapClassName": ["ts-metrics-container"]},
"items": [],
"visible": true//{"bindTo": "isMetricsContainerVisible"}
}
},
{
"operation": "merge",
"parentName": "MetricsContainer",
"propertyName": "items",
"name": "MoodContainer",
"values": {
"items": [],
"itemType": this.Terrasoft.ViewItemType.CONTAINER,
"classes": {"wrapClassName": ["ts-metric-item", "ts-mood-container"]}
}
},
{
"operation": "merge",
"parentName": "MoodContainer",
"propertyName": "items",
"name": "OpportunityMood",
"values": {
"generator": "ImageListGenerator.generateImageList",
"bindTo": "Mood",
"id": "MoodImageList",
"schemaName": "OpportunityMood",
"schemaColumn": "Image",
"caption": {"bindTo": "Resources.Strings.MoodListCaption"},
"controlConfig": {
"wrapClasses": ["opportunity-mood-image-list image-list"],
"modalBoxClasses": ["opportunity-mood-image-list"]
},
"markerValue": "OpportunityMood",
"tips": []
},
"alias": {
"name": "Mood",
"excludeProperties": ["layout"],
"excludeOperations": ["remove", "move"]
}
},
{
"operation": "merge",
"parentName": "OpportunityMood",
"propertyName": "tips",
"name": "MoodTip",
"values": {
"content": {"bindTo": "Resources.Strings.MoodTip"}
}
},
{
"operation": "merge",
"parentName": "MoodContainer",
"propertyName": "items",
"name": "MoodCaption",
"values": {
"itemType": Terrasoft.ViewItemType.LABEL,
"caption": {"bindTo": "Resources.Strings.MoodCaption"},
"classes": {"labelClass": ["ts-metric-item-caption"]}
}
},
When I tried to implement in the current package with the file "OpportunitypageV2", I am facing the below error.
Kindly help me in figuring out the code that has to be included, so as to implement the metrics in Lead section.
Regards,
Adharsh S