- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-03-2020 03:49 AM
Hi ,
I have a requirement to hide all the categories Except "Project task" under Tasks - > All Tasks in Time Sheet Portal.
It got fixed my making the changes to the Server Script in 'Time Card Portal Main Container' widget , please find the 2 nd screenshot attached.In line 33 , i have commented all the table names .In line 36 i have put only pm_project_task table.
I don't see other tasks -> under Tasks - > All Tasks
But when i click on "Generate Time Cards" , i see all the categories are again visible under Tasks - > All Tasks.
My Requirement is to completely restrict the below categories except "Project task" .
1. Incidents
2. problems
3. Change requests
4. Stories
5. Scrum tasks
6. Test plans
7. Project task
8. Projects
9. Defects
10. Enhancements
11. sn_customerservice_case
12. wm_order
13. wm_task
How can i restrict the categories from "Generate Time Cards" ?
Thanks
NR
Solved! Go to Solution.
- Labels:
-
Project Portfolio Management
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-03-2020 07:23 AM
Hi NR,
"Add unassigned tasks to timesheet" has a select2 dropdown, which query to task table with ServiceNow standard table query api. Incident, Case, Project, Demand and many more tables are extended from task table, so you are able to see all type of tasks in this dropdown.
To restrict this, you need to
1. navigate Service portal -> Widget -> tc-grid (Time Card Grid).
2. Open 'link function'.
3. Search for '/api/now/table/task'.
4. Instead of 'task', you need to replace with 'pm_project_task'.
This will only get records from Project Task table.
Hope this will help you with your requirement.
Thank you,
Jayarnab
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-04-2020 03:30 AM
Hi NR,
I think Generate Time Cards, directly create time cards from backend. there is no option to select what type of time cards.
Where exactly are you seeing Defects?
As per previous workaround, that will work for "Add unassigned tasks to timesheet" and '/api/now/table/pm_project_task' will only return records from Project Tasks.
Please check once.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-14-2020 01:21 AM
Hello,
Nikhil i have the similar requirement i want only project task when we click on "Generate time card" . Where you able to achieve so ? if so can you share what configuration or changes you have made to achieve this ?