Allow add tool categories in sakai.properties.

Description

If you want to add a new category (site type) to a tool, you have to change all the /tools/toolid.xml files. You could have all those files in sakai.home rather than distributed across webapps, but you still have to change a lot of files, and also, in the long term, you could be affected if changes are made to the original files since you are using now a modified copy of them. We think that most people just modify those files for adding new categories but those files include other things like tool title, function require...

Therefore, It would be good to have them work independently. If you'll be able to add a property like tool.categories.toolid=category1,category2,category3,.... you could manage all tool categories within the same file, avoiding the copy of the entire toolId.xml file.

Attachments

4
  • 06 Mar 2013, 09:45 AM
  • 06 Mar 2013, 07:17 AM
  • 06 Mar 2013, 07:07 AM
  • 06 Mar 2013, 07:06 AM

Activity

Show:

Hudson CI Server March 8, 2013 at 8:25 AM

Integrated in kernel-trunk #606 (See http://builds.sakaiproject.org:8080/job/kernel-trunk/606/)
Allow adding and overriding tool categories in sakai.properties.
See default sakai properties for details of how to use this. (Revision 120927)

Result = SUCCESS

Aaron Zeckoski March 8, 2013 at 7:06 AM

Applied to trunk

Earle Nietzel March 7, 2013 at 4:56 PM

Patch looks good and tested both:

tool.categories.<tool id>=<category x>
and
tool.categories.append.<tool id>=<category x>

Aaron Zeckoski March 6, 2013 at 10:00 AM
Edited

default sakai properties addition would be like this:

  1.  

    1. Override/Append Sakai Tool categories

  2. NOTE: categories are also set in the sakai tool xml files in each tool

  3. Normally, if you want to add a new category (site type) to a tool, you have to change the /tools/toolid.xml file.

  4. This config option adds 2 ways to adjust the categories. The first is to append new categories to any

  5. already defined for the tool. The second is to override any categories set for the tool with a new set.

    1. (1) Append the categories to the existing set of categories (has no effect if it is blank)

  6. Example: tool.categories.append.sakai.announcements=course

  7. Default: use the categories defined in the tool xml file

  8. tool.categories.append.{toolid}=category1,category2,category3

    1. (2) Override the current tool categories with a new set of categories (removes all categories if it is blank)

  9. Example: tool.categories.sakai.announcements=course,project

  10. Default: use the categories defined in the tool xml file

  11. tool.categories.{toolid}=category1,category2,category3

Aaron Zeckoski March 6, 2013 at 9:45 AM

Attaching the patch (KNL-1031.patch.txt) which integrates the comments I put above. Pretty much a total rewrite so should be separately reviewed.

Fixed

Details

Priority

Affects versions

Fix versions

Components

Assignee

Reporter

Property addition/change required

Yes

Created March 6, 2013 at 7:04 AM
Updated April 25, 2018 at 3:34 PM
Resolved March 8, 2013 at 7:06 AM