Can you add a Visual Task Board to a homepage?

sconjardi
Kilo Explorer

Is there a way to add a VTB to a homapage, similar to a gauge? I do not see any way to convert a board to a gauge or custom widget.

Let me know if anyone has any ideas.

Thanks,

4 REPLIES 4

Bhupinder1
Giga Expert

There isn't any direct way to do it so you need to build UI page which calls the taskboard in iFrame and then you need to create Widget and call the UI page from there. This should work well.


samfindlay1
Giga Expert

Hi Sam,



Don't know if you are still having this issue but I have been able to implement a solution based on instructions from Bhupinder Rajput above. For anyone interested here is the process:



1. Go to System UI > UI Page > New


Name: vtb_page


XML:


<?xml version="1.0" encoding="utf-8" ?>


<j:jelly trim="false" xmlns:j="jelly:core" xmlns:g="glide" xmlns:j2="null" xmlns:g2="null">


<iframe src="$vtb.do" style="width: 100%; height: 700px;"/>


</j:jelly>



2. Go to System UI > Widgets > New


Name: Visual task Board Widget


Script:


function sections() {


      return {


              'Visual Task Boards': {


                      'type': 'vtb_page'


              }


      };


}




function render() {


      var scope = gs.getCurrentScopeName();


      scope = (scope == 'rhino.global' ? '' : scope + '_');


      var page = renderer.getPreference('type');


      return renderer.getRenderedPage(scope + page);


}




function getEditLink() {


      var scope = gs.getCurrentScopeName();


      scope = (scope == 'rhino.global' ? '' : scope + '_');


      var page = renderer.getPreference('type');


      return "sys_ui_page.do?sysparm_query=name=" + scope + page;


}



3. Go to any homepage > Add content


4. Search for 'Visual Task boards' then add it to homepage.



Useful documentation for creating and configuring widget script:


Create a widget that displays a ServiceNow UI page



Hope that helps.


This worked Perfectly,



Thank you


Hello Sam,



this basically works fine. But I will only be directed to the visual task boards page and I have to choose every time I open the dashboard the visual taskboard I want to open. Can I direct it to a specific one?



br