Remove Queries from Assigment List Web Part

Topics: Developer Forum
Oct 12, 2012 at 10:36 PM

Hi, I was hoping someone can help me with removing some queries from the Assigment List Webpart.  We don't have due dates for our assignments, so queries such as "Over Due", "Due Next Week", etc. are irrelevent.  I'd like to get those out of the webpart.

I've been able to successfully change the query titles by editing the SLKSetting.xml file, but removing the entire block <Query> to </Query> gives me an error.  Is there a way to make it not visible or remove the unwanted queries from the web part?

Thanks,

 

Oct 17, 2012 at 8:40 AM

While I don't know how to modify the web part, I solved a similar problem by extracting the data from SLK to Sharepoint lists instead. Full guide available here: http://fragged.nu/2012/06/custom-slk-reporting-on-sharepoint/

 

/Simon

Coordinator
Nov 29, 2012 at 10:33 AM

You're almost correct is modifying slksetting.xml. In addition to deleting the Query you also need to delete the reference to it in the QuerySet. In fact that's all you need to do to stop it appearing.

    <QuerySet Name="LearnerQuerySet" Title="Learner Query Set" DefaultQueryName="ToDoLearner">
    <IncludeQuery QueryName="ToDoLearner" />
    <IncludeQuery QueryName="OverdueLearner" />
    <IncludeQuery QueryName="DueTodayLearner" />
    <IncludeQuery QueryName="DueThisWeekLearner" />
    <IncludeQuery QueryName="DueNextWeekLearner" />
    <IncludeQuery QueryName="ReturnedLearner" />
    <IncludeQuery QueryName="AllAssignmentsLearner" />
  </QuerySet>

Each query set is a collection of queries. Just remove the IncludeQuery element containing those that you don't want to show.

Richard

SLK Coordinator

http://blog.salamandersoft.co.uk