Expand my Community achievements bar.

Join us LIVE in San Francisco on November 14th for Experience Makers The Skill Exchange. Don't miss out on this free learning event!

Filtering a report with parameters via its URL

Avatar

Level 10
Hi, We have a use case as follows: We have a Workfront report which lists documents from varous projects. The report has a prompt for the customer number (of the project that the document is located in). We have another system outside Workfront where a set of users (salespeople) operate to look up customer information. We would like to be able to present them a link to the Workfront report, and include a customer number in the URL which the report effectively uses as a filter parameter instead of the prompt needing to be used via the Workfront UI. We would like them to be able to click on this link and see a pre-filtered list of documents for that given customer number. Is this possible in Workfront? It is indeed possible in other systems (Power BI for example). Cheers David Cornwell
Topics

Topics help categorize Community content and increase your ability to discover relevant content.

11 Replies

Avatar

Level 10
In case anyone is also interested in this, please vote for my idea on the Idea Exchange: "https://support.workfront.com/hc/en-us/community/posts/360022226373-Report-parameters-via-URL">https://support.workfront.com/hc/en-us/community/posts/360022226373-Report-parameters-via-URL David Cornwell

Avatar

Community Advisor
Hi David, old post of yours that I'm replying to here, but I did some work this weekend around this same subject matter. My original aim was to figure out if I can append a standard report URL to force a specific view/filter/grouping when it's opened. (You can do this, which I can cover in a separate post.) Once I was able to do that, I got to thinking that it would be a lot more useful if I could append a prompted report URL to open with the prompts pre-selected for the user. Happy to report that I was able to figure it out! But, there are some limitations that perhaps you or someone else here can help to overcome. First limitation is: the content only displays as a tile - the global nav bar and report header do not get rendered in the report. This is actually a feature if you are embedding the content in a frame - it looks really clean. But, displayed by itself in a browser window might look odd to users. Second limitation is: the syntax includes a number of special characters, including double quotes ". This makes it impossible to use a calculated field to automatically create a URL, unless someone knows how to escape the double quotes when building the expression. I half-heartedly tried /" but it didn't work. This is the biggest disappointment for me because I was hoping to use calculated columns or fields to build a hyperlink that would open a prompted report, where the filter criteria of the prompt equaled the ID of the record from which it was linked. For example, in a user report, have a column that displays a hyperlink "Open Requests" which opens a prompted report where the prompted value equals the user that was selected from the report. There's all kinds of permutations similar to this example. If you're building these URLs in an environment outside of Workfront, you can probably work around the syntax. So, here it is: https://yourinstance.my.workfront.com/tile?content=content-reporting-report-data&tileID=content-repo... 5cabba11023848040004be7c63d1bed6 &reportID= 5cabba11023848040004be7c63d1bed6 &activeTab=tab-reporting-report-details&promptsMapJSON={"promptsMap":[{"enteredByID":" 5c4b92cb01233933b34c1eeff19890c0 ","enteredByID_Mod":"in"}]} https://yourinstance.my.workfront.com /tile?content=content-reporting-report-data &tileID=content-reporting-report-data &ID= 5cabba11023848040004be7c63d1bed6 &reportID= 5cabba11023848040004be7c63d1bed6 &activeTab=tab-reporting-report-details &promptsMapJSON={"promptsMap":[{" enteredByID ":" 5c4b92cb01233933b34c1eeff19890c0 "," enteredByID_Mod ":" in "}]} Replace with the GUID of your prompted report Replace with your filter criteria Replace with your filter modifier Line breaks added for readability - remove them I'm excited to put this out there and see if anyone is able to build off this to enable my use case. William English T-Mobile
If you like my content, please take a moment to view and vote on my Idea Requests: https://tinyurl.com/4rbpr7hf

Avatar

Level 2

@William English‚

You mentioned above it is possible to force a view or a filter from url.

If you posted on that , can you share a link?

Otherwise, I would appreciate pointers on how to get that done.

Thank you,

John

Avatar

Community Advisor
Very nice William! Thanks for sharing, and congrats on noodling it all out! I've made a note of your technique, and (although untested) suggest that you try using the " character's "https://www.urlencoder.org/" urlencode %22 equivalent in your calculated parameter. Regards, Doug Doug Den Hoed - AtAppStore Got Skills? Lend a hand! https://community.workfront.com/participate/unanswered-threads

Avatar

Level 10
Nice work indeed, William. I haven't had a chance to test generating the URL in Workfront, but it could be very handy for us regardless from external systems. Thanks David Cornwell

Avatar

Level 10
Hi @William English , Can you confirm if this is still working for you? I can't get this to work (and I'm not enrolled in the New Experience right now as that could be different due to the new URL structure)..... I'm pretty sure I tested it before and it worked though. Regards, David David Cornwell

Avatar

Community Advisor
Hi David, It's working for me in Classic (prod) and New Experience (preview). I haven't yet tried Doug's urlencode suggestion, but that is something I may get to this week. William English T-Mobile
If you like my content, please take a moment to view and vote on my Idea Requests: https://tinyurl.com/4rbpr7hf

Avatar

Level 8
This is working great for me, William! Which part of the code do I need to remove so I see the Workfront banners/navigation? I'm using this as an external link coming to WF, and I only see the table of data. Adina Pierce

Avatar

Community Advisor

Adina, it only took me two years to figure out how to render banners and navigation when using this approach to to pre-fill prompt values in a prompted report. I know you've probably moved on from this challenge, but I'm sharing it for anyone who comes looking for answers later on..

The solution is (as described before) to create a link using the report URL appended with

&activeTab=tab-reporting-report-details&promptsMapJSON={"promptsMap":[{"enteredByID":" 5c4b92cb01233933b34c1eeff19890c0 ","enteredByID_Mod":"in"}]}

Then, in a dashboard, add the above URL as an external page. You can then link to that dashboard instead of the report.

What makes this really cool is that you can link to the dashboard and get the navigational elements rendered, or you can display that same dashboard as a custom tab, and pass the ID of the object being viewed as a wildcard into your promptsMap.

This will display only the external links (prompted reports) in the custom tab, and submit the ID of the record being viewed as your prompt value. Now when viewing any user profile, we have custom tabs that display all a user's submitted requests, all the projects owned by the user, and all the user's assignments. It's one-stop shopping for seeing all of user's records, right there in their profile.

That example is only applicable to Classic WF since NWE won't support custom tabs on the user object, but this can be used in other areas that do work in NWE. We're now able to show pending document approvals as a tab in the project. This works around any previous error where you would normally get a yellow exclamation mark/warning that the report can't be filtered in an object's custom tab.

0694X00000FQzQkQAL.png 0694X00000FQzREQA1.png0694X00000FQzSbQAL.png

If you like my content, please take a moment to view and vote on my Idea Requests: https://tinyurl.com/4rbpr7hf

Avatar

Level 10
Excellent - thanks. I had another try and got it working....my issue (I think) was encoding-related and due to the custom field name I was trying to use. Cheers David Cornwell

Avatar

Community Advisor
Hi Adina, I was only able to get the results by displaying the tile in a browser window. I experimented at the time trying to get the nav bar to appear but couldn't figure it out and haven't really revisited it until now. Will update if that changes! William English T-Mobile
If you like my content, please take a moment to view and vote on my Idea Requests: https://tinyurl.com/4rbpr7hf