Forum Discussion

ChrisTurner's avatar
ChrisTurner
Data Storage
08-01-2022

Links in Pivot Table

Hello,

I am trying to create a column that links to our gift pages on our crm. The problem is when it goes to the url, it has the donor data at the top from the last viewed donor, instead of the donor data of the gift. Our solution is first to open to the donor page and then go to the gift page.

This is the code I came up with:

'<a onclick="openWin()" target="_blank" style="color:black">' + tostring([giftid]) + '</a>

<script>

function openWin() {

  const myWindow = window.open(https://portfolio.usawest.org/Donors/DonorSPTC.aspx?dxid=' + tostring([donorid]) + ', "", "width=1000, height=1000");

  setTimeout(function() {myWindow.location.replace(' + [link] + ')}, 1000);

}

</script>'

 

I have tested it in w3schools and it works perfectly, but when I try to put it into the pivot table on sisense, it does not work. I have the widget code that is given for implementing html into pivot tables, and it works for other links, but this one just won’t work. It shows as a link with the donorid, but clicking on it does absolutely nothing.

Do you have any suggestions of what I am doing wrong?

Thanks!

2 Replies

Replies have been turned off for this discussion
    • ChrisTurner's avatar
      ChrisTurner
      Data Storage

      Hello, 

      I ended up figuring out why it would not open, but now it opens up to the last one in the list. I tried making it so that it names each function uniquely, because I assumed that it was changing the function each time until the last one. Now it just doesn't work again.

      It is running on windows.

      Thanks!