Hello
Is there a way to conditionally exclude a row from being displayed in the (portfolio) push table? I can't see anything in the API that would support this.
You could assign a "display:none" style to the row that should disappear:
[syntax="JS"]yourDMPTable.onChangingValues = function(domNode,itemUpdate) {
if (itemUpdate.getFormattedValue("key") == "toDisappear") {
domNode.style.display = "none";
}
}
[/syntax]
We have a 'total amounts' row sent in an item with a 'key' of -1 and we want to always display that on the top.
You could sort your table in a way that that row is always on top.
If not possible you could clone the node on each update making the original one transparent
[syntax="JS"]var cloned;
yourDMPTable.onChangingValues = function(domNode,itemUpdate) {
if (itemUpdate.getFormattedValue("key") == "toBeOnTop") {
if (cloned) {
cloned.parentNode.removeChild(cloned);
}
cloned = domNode.cloneNode(true);
cloned.style.display = "";
document.getElementById("herepls").appendChild(cloned);
domNode.style.display = "none";
}
}
[/syntax]
HTH