| Methods / Methods for Manual Work Items (Tasks) | |
REST
POST
Creates a manual work item that is linked to another manual work item. The work item you create does not depend on the completion of the work item to which it is linked. In other words, the original (source) work item can be marked as completed before new work item is completed.
https://[domain]:[port]/AgilePointServer/Workflow/CreateLinkedWorkItem
https://[domain]:[port]/AgilePointService/Workflow/CreateLinkedWorkItem
| Name | Description |
|---|---|
| None | Not Applicable |
| Name | Description |
|---|---|
bDependent |
|
BusinessTime |
|
ClientData |
|
Length |
|
SourceWorkItemID |
|
Unit |
|
UserID |
|
WorkToPerform |
|
These properties are based on the class CreateLinkedWorkItemHelper
$("#btnCreateLinkedWorkItem").click(function () {
var JSONObject = {
SourceWorkItemID: "0E11FFE63E594128B662CD27A259E4B3",
WorkToPerform: "Test123",
UserID: "demo3\\susan.miller",
Length: "2",
Unit: "DAY",
BusinessTime:true,
bDependent: true,
ClientData: null
};
$.ajax({
url: "https://mydomain:9011/AgilePointServer/Workflow/CreateLinkedWorkItem",
data: JSON.stringify(JSONObject)
});
});
public String CreateLinkedWorkItem() {
String URI = "https://mydomain:9011/AgilePointServer/Workflow/CreateLinkedWorkItem";
HTTPOperations ops = new HTTPOperations(domain, userName,
password, appID, locale);
JSONObject postData = new JSONObject();
postData.put("SourceWorkItemID", "0E11FFE63E594128B662CD27A259E4B3");
postData.put("WorkToPerform", "New WorkItem");
postData.put("UserID", "demo3\\susan.miller");
postData.put("Length", "2");
postData.put("Unit", "DAY");
postData.put("BusinessTime", "true");
postData.put("bDependent", "true");
postData.put("ClientData", "");
return ops.POSTMethod(URI, postData.toString());
return "";
}
public string CreateLinkedWorkItem()
{
string jsonRequestData = "{
\"SourceWorkItemID\":\"0E11FFE63E594128B662CD27A259E4B3\",
\"WorkToPerform\":\"CreateLinkedWorkItem\",
\"UserID\":\"demo3\\\\brian.lucas\",
\"Length\":\"2\",
\"Unit\":\"DAY\",
\"BusinessTime\":\"true\",
\"bDependent\":\"true\",
\"ClientData\":\"" + null + "\"}";
string URI = "https://mydomain:9011/AgilePointServer/Workflow/CreateLinkedWorkItem";
HTTPOperations ops = new HTTPOperations(domain, this.userName,
password, appID, locale);
return ops.POSTMethod(URI, jsonRequestData);
}
WFEvent object that provides the status of the transaction. The possible statuses are:
{
"ActivityInstID": "0DB05C1A1BAB445895CCF46E096AECDD",
"AutoStart": true,
"CustomAttributes": null,
"Diagnostic": true,
"EndDate": “\/Date(928149600000+0000)\/”,
"Entries": 1,
"Error": null,
"EventID": "572215CBEA884B7890259879C21FAC42",
"EventName": "CreateWorkItem",
"HighPriority": true,
"ParamsXml": "<?xml version=\"1.0\" encoding=\"utf-8\"?>
<WFEvent>
<param name=\"ExpectedTime\" value=\"2 Day(s)(business time)\" \/>
<param name=\"workPerformer\" value=\"Revise\" \/>
<param name=\"SourceWorkItemID\"
value=\"2AA1E203047B41F29E3E29F62D00903B\" \/>
<param name=\"ProcInstID\"
value=\"B7F0ACFA610349B4BF10A4DAB8E93458\" \/>
<param name=\"UserID\" value=\"demo3\\administrator\" \/>
<param name=\"ActivityInstID\"
value=\"0DB05C1A1BAB445895CCF46E096AECDD\" \/>
<param name=\"waitWorkPerformed\" value=\"True\" \/>
<param name=\"HighPriority\" value=\"True\" \/>
<param name=\"Carbon\" value=\"False\" \/>
<param name=\"WorkItemID\"
value=\"CE4265BC8CA944F885446962D0463974\" \/>
<\/WFEvent>",
"ParentProcInstID": "",
"ProcDefID": "",
"ProcInstID": "B7F0ACFA610349B4BF10A4DAB8E93458",
"ProcInstName": "",
"Sender": "demo3\\administrator",
"SentDate": "\/Date(1394148475011+0000)\/",
"SourceWorkItemID": "2AA1E203047B41F29E3E29F62D00903B",
"Status": "Sent",
"UserID": "demo3\\administrator",
"WorkItemID": "CE4265BC8CA944F885446962D0463974",
"WorkObjectID": "",
"WorkObjectInfo": ""
}
AgilePoint BPMS v5.0 R2 and higher