Deleting activities
Use administrative commands to move one or more activities to the Trash view.
Before you begin
To run administrative commands, you must use the wsadmin client. See Starting the wsadmin client for details.
Procedure
- Start the Activities Jython
script interpreter.
- Use
the following command to access the Activities configuration file:
execfile("activitiesAdmin.py")
If prompted to specify a service to connect to, type 1 to pick the first node in the list. Most commands can run on any node. If the command writes or reads information to or from a file using a local file path, you must pick the node where the file is stored.
- Use
the following command to access the Activities configuration file:
- If you have not
yet created a variable that contains the
activities you want to delete, create one. You can get a list of activities
in hash table format by using one of the fetchActivities commands.
See Activities administrative commands for a full list.
For example, if a person leaves the organization and you want to delete
all of the activities that he owns, you can perform the following
steps to narrow down the activities to delete:
-
Get a hash table of information related to a specific
user:
For example:variable=ActivitiesMemberService.fetchMemberByName(java.lang.String member)
joe=ActivitiesMemberService.fetchMemberByName("Joe Jacobs")
- Retrieve the activities that a specific person
owns:
For example:variable=ActivityService.fetchActivitiesByOwner(java.util.Hashtable member)
joesactivities=ActivityService.fetchActivitiesByOwner(joe)
-
Get a hash table of information related to a specific
user:
- Enter the following command
to delete the activity or activities:
where you specify the activity or activities that you want to delete as the activities parameter. For example:ActivityService.deleteActivities(java.util.Vector activities)
ActivityService.deleteActivities(joesactivities)