How To Custom Report Body?
Hello there,
I'm working as engineer at a company who is your customer.
We are using your product to make our report.
We are imbedded Izenda into our Angular application (v9).
We would like to customize report body.
As you know, we can create several reports as a table. And we would like to replace some text by hyperlink.
Ex: We have a table like this [Id-Created Date-Name]. The "Name" should be a hyperlink which redirect user to a new page.
Is there any way to replace text by a hyperlink? It took me a week for finding.
And can I catch a "loaded or rendered" event when every report is rendered? then I can manually modify something by JS.
Thanks,
Tuan Pham
-
Official comment
Hello Tuan,
Sorry for the delay.
There are two option to use hyperlink on the report field, 1st is to use a Subreport on that field where you want the column with hyperlink. Second is that if the customer is using form report then we can edit the html using anchor tag and use that field inside this tag Or we can use the Subreport feature inside the form report as well. To confirm, if you are using form or simple grid report, you can use the Subreport in both type of report.
Please check out this doc for more details: Subreports — Izenda BI 4.0.0 documentation
Thanks,
-
Here is some more information:
1. Set custom URL.
2. Click the icon.
3. Enter the url into the text box.
4. Choose an option to open the url in a new window, a new tab or the current window.
5. Click OK to save the setting.System variables
Some system variables are available for use in Custom URL pop-up.
-pXvalue=a_value
setsa_value
as the value for filter number X.
-{column_name}
will be replaced by the value in the column specified.
-{0}
will be replaced by the value in current column.For example:
-http://www.google.com/?q={0}
when clicked on will open Google and search for the value in this column.
-http://www.google.com/?q={[OrderDay]}
when clicked on will open Google and search for the value in column OrderDay.
-http://127.0.0.1/new/e8d89dc0-5933-4946-816c-c0ee4e30f2b2?p1value={[OrderDay]}
when clicked on will take the value in column OrderDay, open the report with id=e8d89dc0-5933-4946-816c-c0ee4e30f2b2 and pass the value to the first filter of that report.0 -
Hi Tuan,
Apologies for the delay and multiple responses. I wanted to summarized the previous comments and add some additional information.
Custom URL
The easiest and most common way to do this is using the Custom URL setting in the Report Designer. This works well when you are trying to navigate to URL that is not another Izenda report. (ex. Google, a page in your application, etc)
To set the Custom URL setting, you can follow the steps below.
- In the Report Designer, navigate to the Design tab
- Navigate to configuration mode (right-click the blue bar) on your Grid report part and select the field you want to make a hyperlink (ex. "Name" field)
- In the Field Properties on the right side of the page, scroll down to the Custom URL setting
- Click the Custom URL icon
- In the popup, you will be able to construct your custom URL, the behavior of the hyperlink, and how the hyperlink appears in your report
- Click OK to confirm your choice and Save the report
When constructing your custom URL, we allow you to use a few system variables in the URL that will be used to pass values to your URL. Below are the system variables that are available and examples.
-
pXvalue = a_value
setsa_value
as the value for filter number X. -
{column_name}
will be replaced by the value in the column specified. -
{0}
will be replaced by the value in current column.
For example:
-
http://www.google.com/?q={0}
when clicked on will open Google and search for the value in this column. -
http://www.google.com/?q={[OrderDay]}
when clicked on will open Google and search for the value in column OrderDay. -
http://127.0.0.1/new/e8d89dc0-5933-4946-816c-c0ee4e30f2b2?p1value={[OrderDay]}
when clicked on will take the value in column OrderDay, open the report with id=e8d89dc0-5933-4946-816c-c0ee4e30f2b2 and pass the value to the first filter of that report.
More information about the Custom URL can be found here: https://www.izenda.com/docs/ui/doc_report_designer_fields.html#configure-field-properties-in-data-formatting-section
Subreport
If you are trying to navigate to another Izenda report, we would recommend setting up a subreport. When setting up a subreport, you will need to create the subreport separately before connecting it to the parent report. Similar to the Custom URL, you will navigate to the field in the Report Designer and navigate to the Subreport setting at the bottom of the Field Properties.
More information about subreports can be found here: https://www.izenda.com/docs/ui/doc_subreports.html
Form Report Parts
One last note is for if you are using a form report part instead of a grid report part. With form report parts, you can use the CustomURL setting or the subreport setting outlined above or you can use the HTML <a> tag to create static hyperlink.
0
Please sign in to leave a comment.
Comments
3 comments