can we add url inside a dynamically generated Table (TableWidget), which redirects to process a new task?

1
0
-1

Hi,

can we add url inside a dynamically generated Table (TableWidget), which redirects to process a new task?
like:

Bonita version 7.0.1

data1 | data2 | data3 | link

data4 | data5 | data6 | link

Thank you,

3 answers

1
+1
-1

You should add the fourth column as data to your data :) but format it as a link...

for example

  1. [
  2. {
  3. col1: "data1",
  4. col2: "data2",
  5. col3: "data3",
  6. col4: "<a href=\"http://www.w3schools.com/html/\">Visit our HTML tutorial</a> "
  7. }
  8. {
  9. col1: "data1",
  10. col2: "data2",
  11. col3: "data3",
  12. col4: "<a href=\"http://www.w3schools.com/html/\">Visit our HTML tutorial</a> "
  13. }
  14. ]

This is the way we do it...

regards
Seán

PS: If this reply answers your question, please mark a resolved.

Comments

Submitted by josorio_2 on Tue, 07/05/2016 - 21:15

this not work

1
0
-1

No, is the simple answer...

I thought we could....here is the official answer from Bonitasoft to the bug I raised...

Hi Sean,
Unfortunately our table widget does not support the dynamic injection of HTML.
This is a known limitation: it only supports text.
We need to update our documentation to be clear about this but we will not process this as a bug (it is a feature request).
Just to let you know, if you wish to inject dynamic HTML content in a table via a custom widget, you would need to take care to use AngularJS Strict Contextual Escaping (SCE).
Sorry about the bad news,

So the way to do this is to use a custom widget taking care of SCE...whatever that means :)

I someone does it can they upload a version to the Projects forum so everyone can do it...

regards
Seán

PS: While this reply doesn't really answer the question, it is now considered resolved. can you please mark as resolved

1
0
-1

Can you please explain this in detail? I have a similar requirement. I designed the page that has this table. Then I created a dummy JSON variable with the data as shown below. I see the data in the table when I preview but I want one of the column data to be links so that I can direct to another page in the application or to a specific task form in a case. It is showing me the whole a href tag instead of a link.

[
{
"RowHeader":"New",
"NoOfProducts":"10",
"NoOfOwners":"5",
"TotalInventory":"$100000"
},
{
"RowHeader":"Open",
"NoOfProducts":"15 ",
"NoOfOwners":"7",
"TotalInventory":"$23000"
},
{
"RowHeader":"Closed",
"NoOfProducts":"100 ",
"NoOfOwners":"33",
"TotalInventory":"$234000"
}
]

Comments

Submitted by Sean McP on Sun, 03/06/2016 - 14:53

I've created a bug as it used to work...

https://bonita.atlassian.net/browse/BBPMC-365

If you want to watch it too.

regards
Seán

Notifications