Helps you work with Workflow Manager jobs. A job is a single unit of work that is carried out within an organization. Various methods are available in the class to work with the following:
- Manage jobs - Manage jobs by creating jobs, deleteing jobs, assigning jobs, updating jobs, closing jobs, creating job version, getting job and job ids, getting job notes, logging an activity, unassigning jobs, updating notes.
- Manage job attachments - Files or urls can be added to jobs as attachments to provide additional information on the job. Manage job attachments by adding embedded and linked attachments to the job, deleting attachments from a job, getting attachment content url and getting job attachments.
- Manage job dependency and holds - Job dependencies build relationships between jobs. The execution of one job's certain step can be dependent on the status or step or stage of another job. A dependency is automatically released once the dependent job reaches the status or stage or step defined in the dependency. A hold will suspend all job activity until the hold is released. Manage dependencies and holds on the job by creating a dependency, creating a hold, deleting a dependency, getting dependencies for a job, getting holds, releasing holds.
- Manage extended properties - Extended properties are custom properties that enable you to store business-specific properties as required. These properties are configured by job type. Manage extended properties for a job by adding linked records, deleting linked records, getting extended properties, list field values from geodatabase domain or table list extended property field, list display values for specified fields that comprise a multi-level table list extended property, query current display values for each display field in a multi-level table list extended property, update extended or linked property records.
- Query and search jobs - Query jobs using a job query Id, query jobs based on an adhoc query definition, search jobs using freeform search.
Constructors
new JobTask(properties)
properties Object See the properties for a list of all the properties that may be passed into the constructor. |
Property Overview
Name | Type | Summary | |
---|---|---|---|
String | The name of the class. more details | more details | |
Object | The options to be used for data requests. more details | more details | |
String | URL to the ArcGIS Workflow Manager REST service. more details | more details |
Property Details
declaredClassStringreadonly
The name of the class. The declared class name is formatted as
esri.folder.className
.requestOptionsObject
The options to be used for data requests. These options can also be controlled through the
requestOptions
method parameter.urlString
URL to the ArcGIS Workflow Manager REST service.
Method Overview
Name | Return Type | Summary | |
---|---|---|---|
Promise | Uploads a file and attaches it to the job as an embedded attachment. more details | more details | |
Promise | Adds a linked attachment to a job (url or file). more details | more details | |
Promise | Adds a linked property record to a job's linked properties table. more details | more details | |
Promise | Assigns one or more jobs to a user or group. more details | more details | |
Promise | Closes one or more jobs. more details | more details | |
Promise | Creates a job dependency. more details | more details | |
Promise | Creates a job hold. more details | more details | |
Promise | Creates new jobs based on the provided parameters. more details | more details | |
Promise | Creates a version specific to the job. more details | more details | |
Promise | Deletes an attachment from a job. more details | more details | |
Promise | Deletes a job dependency. more details | more details | |
Promise | Delete one or more jobs. more details | more details | |
Promise | Deletes a record from a job's linked properties table. more details | more details | |
Promise | Gets the activity log for a job. more details | more details | |
String | Gets the URL to access the file content of an embedded job attachment. more details | more details | |
Promise | Gets all the attachments associated with the job. more details | more details | |
Promise | Gets an array of dependencies configured for a job. more details | more details | |
Promise | Gets an array of extended properties for a job. more details | more details | |
Promise | Gets an array of holds on a job. more details | more details | |
Promise | Gets the job object based on the given id. more details | more details | |
Promise | Gets all the job ids in the system. more details | more details | |
Promise | Gets the notes for a job. more details | more details | |
Promise | Gets an array of values and descriptions for a geodatabase domain or table list extended property field. more details | more details | |
Promise | Gets an array of display values for a given fields that comprise a multi-level table list extended property. more details | more details | |
Promise | Logs an action in a job's activity log. more details | more details | |
Promise | Queries the jobs using the queryId of an existing query. more details | more details | |
Promise | Queries the jobs using an ad-hoc query definition and gets the query result. more details | more details | |
Promise | Gets an array of string values representing the current display values for each display field in a multi-level table list extended property. more details | more details | |
Promise | Releases a job hold. more details | more details | |
Promise | Reopens one or more closed jobs. more details | more details | |
Promise | Performs a freeform text search and returns a set of matching job records. more details | more details | |
Promise | Unassigns one or more jobs. more details | more details | |
Promise | Update a job's properties. more details | more details | |
Promise | Updates the notes for a job. more details | more details | |
Promise | Updates the values of an extended or linked properties record. more details | more details |
Method Details
addEmbeddedAttachment(params, requestOptions){Promise}
Uploads a file and attaches it to the job as an embedded attachment.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
form ObjectThe form element that contains the file input control. The form parameter can be an instance of FormData. Using FormData you can send a "multipart/form-data" request to the server without having to create an HTML form element in markup. Note that the FormData api is not available in all browsers.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns the id of the embedded attachment added to the job. addLinkedAttachment(params, requestOptions){Promise}
Adds a linked attachment to a job (url or file).
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
attachmentType NumberThe type of attachment to be added.
Possible Values: linked-file | url
path StringThe file path to the attachment.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns the id of the linked attachment added to the job. Example:var params = { jobId: 804, attachmentType: "linked-file", path: "c:\\temp\\test.txt", user: "cjones" }; jobTask.addLinkedAttachment(params).then(function(attachmentId){ console.log("attachmentId: " + attachmentId); }, function() { * console.log("Failed to add attachment.") });
addLinkedRecord(params, requestOptions){Promise}
Adds a linked property record to a job's linked properties table.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
tableName StringThe name of the table to which the record will be added.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns the id of the added record. assignJobs(params, requestOptions){Promise}
Assigns one or more jobs to a user or group.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobIds Number[]An array of unique job Ids.
assignedType StringIndicates whether the job is assigned to a user, group or unassigned.
Possible Values: unassigned | user | group
assignedTo StringThe name of the user or group to whom the job will be assigned.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. Example:var params = { jobIds: [12,14], assignedTo: "Technicians", assignedType: "group", user: "cjones" }; jobTask.assignJobs(params).then(function(){ console.log("Jobs assigned successfully.") }, function() { console.log("Failed to assign jobs.") });
closeJobs(params, requestOptions){Promise}
Closes one or more jobs.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobIds Number[]An array of unique job Ids.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. createDependency(params, requestOptions){Promise}
Creates a job dependency.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
heldOnType StringIndicates whether the current job (to which the dependency is being added) will be held at a step, stage or status.
Possible Values: step | stage | status
heldOnValue NumberThe value of the step, stage or status at which the current job will be held.
depJobId NumberThe unique id of the job on which the current job will depend.
depOnType StringIndicates whether the current job (to which the dependency is being added) will be dependent on a step, stage or status of the other job.
Possible Values: step | stage | status
depOnValue NumberThe value of the step or status of the other job on which the current job will be dependent.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns the id of the dependency created. Example:var params = { jobId: 403, heldOnType: "status", heldOnValue: 4, depJobId: 405, depOnType: "step", depOnValue: 1093, user: "cjones" }; jobTask.createDependency(params).then(function(dependencyId){ console.log("dependencyId = " + dependencyId); }, function() { console.log("Failed to create job dependency.") });
createHold(params, requestOptions){Promise}
Creates a job hold.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
holdTypeId NumberThe unique id representing the hold type to be placed on the job.
comments StringReason or more detailed information regarding why the hold is being added.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns the id of the hold added. Example:var params = { jobId: 403, holdTypeId: 2, comments: "Require department approval", user: "cjones" }; jobTask.createHold(params).then(function(holdId){ console.log("holdId = " + holdId); }, function() { console.log("Failed to create job hold.") });
createJobs(params, requestOptions){Promise}
Creates new jobs based on the provided parameters.
Parameters:params JobCreationParametersThe parameters to be used for job creation, parameters defined in the job type can be overritten. The jobTypeId and user are required parameters when creating a job.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of ids of the jobs created. Example:// job location of interest (loi) can be a polygon, point, or multipoint // polygon // var polygon = new Polygon(new SpatialReference({ wkid: 102100 })); // polygon.addRing([[-108.92, 44.73], [-108.92, 36.01], [-126.46, 36.01], [-126.46, 44.73], [-108.92, 44.73]]); // points var multipoint = new esri.geometry.Multipoint(new esri.SpatialReference({ wkid: 102100 })); multipoint.addPoint(new esri.geometry.Point(-108.92, 44.73)); multipoint.addPoint(new esri.geometry.Point(-108.92, 36.01)); multipoint.addPoint(new esri.geometry.Point(-126.46, 36.01)); multipoint.addPoint(new esri.geometry.Point(-126.46, 44.73)); multipoint.addPoint(new esri.geometry.Point(-108.92, 44.73)); // specify fields to override job type default values var params = { jobTypeId: 12, assignedTo: "demo", assignedType: "user", loi: multipoint, numJobs: 2 user: "cjones", . . . }; jobTask.createJobs(params).then(function(data){ var jobIds = data; jobTask.getJob(jobIds[0]).then(function(job){ var createdDate = job.createdDate; var priority = job.priority; var status = job.status; }); });
createJobVersion(params, requestOptions){Promise}
Creates a version specific to the job.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
name StringThe name of the version to be created.
parent StringThe name of the job's assigned geodatabase (data workspace) version, based on which the new version will be created.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns the name of the version created as a string. deleteAttachment(params, requestOptions){Promise}
Deletes an attachment from a job.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
attachmentId NumberThe unique id of the attachment to be deleted.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. deleteDependency(params, requestOptions){Promise}
Deletes a job dependency.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
dependencyId NumberThe unique id of the dependency to be deleted.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. deleteJobs(params, requestOptions){Promise}
Delete one or more jobs.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobIds Number[]An array of unique job Ids.
optionaldeleteHistory BooleanIndicates whether or not to delete the associated job history, the default is to delete job history.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. deleteLinkedRecord(params, requestOptions){Promise}
Deletes a record from a job's linked properties table.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
tableName StringThe name of the table from which linked record will be deleted.
recordId NumberThe unique id of the record in the table.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. getActivityLog(jobId, requestOptions){Promise}
Gets the activity log for a job.
Parameters:jobId NumberThe unique id of the job.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of objects, each object with the following properties: Name Type Description date Date The date that the activity happened. message String The activity message logged in the history table. type Number The type of activity that is been logged in the application. user String The user making the request. getAttachmentContentUrl(params){String}
Gets the URL to access the file content of an embedded job attachment.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
attachmentId NumberThe Id of the attachment to be retrieved.
Returns:Type Description String Returns the URL to access the file content of an embedded job attachment. getAttachments(jobId, requestOptions){Promise}
Gets all the attachments associated with the job.
Parameters:jobId NumberThe unique id of the job.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of job attachment objects. getDependencies(jobId, requestOptions){Promise}
Gets an array of dependencies configured for a job. A job with a dependency is held at a step, stage or status of the other job, and cannot progress until the other job reaches the step, stage or status defined in the dependency. Once the other job reaches step, stage or status as defined in the dependency criteria the dependency is released and the dependent job can progress.
Parameters:jobId NumberThe unique id of the job.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of job dependency objects. getExtendedProperties(jobId, requestOptions){Promise}
Gets an array of extended properties for a job.
Parameters:jobId NumberThe unique id of the job.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of extended properties[] for a job. getHolds(jobId, requestOptions){Promise}
Gets an array of holds on a job.
Parameters:jobId NumberThe unique id of the job.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of objects, each object with the following properties: Name Type Summary heldBy String The user name of the person that created the hold. holdComments String The comment added to indicate the reason for the hold. holdDate date The date the hold was added. id Number A unique identifier for the hold. releaseComment String The comment added to support releasing of the hold. releasedBy String The user name of the person that released the hold. releasedDate date The date the hold was released. type Number A numeric identifier that represents the type of hold. getJob(jobId, requestOptions){Promise}
Gets the job object based on the given id.
Parameters:jobId NumberThe unique id of the job to be retrieved.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns a job object. getJobIds(requestOptions){Promise}
Gets all the job ids in the system.
Parameter:optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of job ids in the system. getNotes(jobId, requestOptions){Promise}
Gets the notes for a job.
Parameters:jobId NumberThe unique id of the job.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns the job note as string. listFieldValues(params, requestOptions){Promise}
Gets an array of values and descriptions for a geodatabase domain or table list extended property field.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
tableName StringThe name of the extended property table.
field StringThe field name of the extended property for which to retrieve values.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of values and descriptions for a geodatabase domain or table list extended property field. Example:require(["dojo/_base/array", "esri/tasks/workflow/JobTask"], function(array, JobTask){ var params = { jobId: 1801, tableName: "wmdb.DBO.jtx_extra_properties", field: "TEXTNAME", user: "demo" }; var jobTask = new JobTask(serverUrl); jobTask.listFieldValues(params).then(function(fieldValues){ array.forEach(fieldValues, function(fieldValue){ console.log("value: " + fieldValue.value); console.log("description: " + fieldValue.description); . . . }); });
listMultiLevelFieldValues(params, requestOptions){Promise}
Gets an array of display values for a given fields that comprise a multi-level table list extended property. As each display field is selected, for example using a dropdown UI control, this method can be called to obtain a list of values to display in the subsequent dropdown control.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:field StringThe name of the field.
previousSelectedValues String[]The array of previous values, on which the current value is dependent on. For example, when selecting a city based on the state and county. The value for the state and county would be the previous values.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns an array of display values for a given fields that comprise a multi-level table list extended property. Example:require(["dojo/_base/array", "esri/tasks/workflow/JobTask"], function(array, JobTask){ var params = { jobId: 1801, field: auxRecordValue, previousSelectedValues: ["California", "Alameda"], user: "demo" }; var jobTask = new JobTask(serverUrl); jobTask.listMultiLevelFieldValues(params).then(function(fieldValues){ array.forEach(fieldValues, function(fieldValue){ console.log("value: " + fieldValue.value); console.log("description: " + fieldValue.description); . . . }); });
logAction(params, requestOptions){Promise}
Logs an action in a job's activity log.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
activityTypeId NumberThe unique id representing the activity type of the action associated with this log record.
comments StringThe comment that is added to the history.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. queryJobs(params, requestOptions){Promise}
Queries the jobs using the queryId of an existing query.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:queryId NumberThe unique id of a query, used to query jobs in the database.
user StringThe username of the user who is requesting query.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns a query result. queryJobsAdHoc(params, requestOptions){Promise}
Queries the jobs using an ad-hoc query definition and gets the query result.
Parameters:params JobQueryParametersThe parameters to query jobs.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns a query result. Example:var params = { fields: "JTX_JOBS.JOB_ID,JTX_JOBS.JOB_NAME", tables: "JTX_JOBS", where: "JTX_JOBS.JOB_ID < 1000", user: "cjones" }; jobTask.queryJobsAdHoc(params).then(function(data){ var queryResult = data; var fields = queryResult.fields; var rows = queryResult.rows; . . . });
queryMultiLevelSelectedValues(params, requestOptions){Promise}
Gets an array of string values representing the current display values for each display field in a multi-level table list extended property. The values from this method should be used to pre-select items in dropdown lists when initially displaying the extended properties of a job.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:field StringThe name of the field.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns a string array of the extended property values. releaseHold(params, requestOptions){Promise}
Releases a job hold.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
holdId NumberThe unique id of the hold.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, retuns a boolean to indicate if the request succeeded or not. Example:var params = { jobId: 403, holdId: 212, comments: "Department approval granted", user: "cjones" }; jobTask.releaseHold(params).then(function(){ console.log("Successfully released job hold."); }, function() { console.log("Failed to release job hold.") });
reopenClosedJobs(params, requestOptions){Promise}
Reopens one or more closed jobs. Supported from 10.3 onwards
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobIds Number[]An array of unique job Ids.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. searchJobs(params, requestOptions){Promise}
Performs a freeform text search and returns a set of matching job records.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:text StringThe text which will be used to perform the search.
user StringThe username of the user who is requesting search.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns a query result. unassignJobs(params, requestOptions){Promise}
Unassigns one or more jobs.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobIds Number[]An array of unique job Ids.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. updateJob(params, requestOptions){Promise}
Update a job's properties.
Parameters:params JobUpdateParametersThe parameters to be used for job properties update, the jobId and the user are required when updating jobs.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. Example:// specify the fields that need updating var params = { jobId: 12, assignedTo: "demo", assignedType: "user", startDate: new Date(2017, 4, 13), dueDate: new Date(2017, 4, 20), priority: 10, user: "cjones", . . . }; jobTask.updateJob(params).then(function(){ console.log("Job updated successfully.") }, function() { console.log("Failed to update jobs.") });
updateNotes(params, requestOptions){Promise}
Updates the notes for a job.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
notes StringThe new notes for the job. Set to an empty (zero-length) string to clear the job notes.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not. updateRecord(params, requestOptions){Promise}
Updates the values of an extended or linked properties record.
Parameters:params ObjectSee the object specifications in table below for the structure of the
params
object.Specification:jobId NumberThe unique id of the job.
record AuxRecordDescriptionThe record to be updated.
user StringThe user name of the user who is requesting the change.
optionalrequestOptions ObjectAdditional options to be used for the data request (will override requestOptions defined during construction).
Returns:Type Description Promise When resolved, returns boolean that indicates if the request succeeded or not.
Type Definitions
ActivityTypeObject
ActivityType represents an activity type template that gets logged on a job when a certain event is fired in the application.
AuxRecordObject
AuxRecord represents the extended/linked properties record information associated with a job so that you can fetch or update the information for a specified record.
Properties:displayProperty ObjectThe display value of the record.
id NumberThe unique id of the record.
recordvalues AuxRecordValueThe array of the values in the records.
AuxRecordContainerObject
AuxRecordContainer represents the extended/linked properties table characteristics.
AuxRecordDescriptionObject
AuxRecordDescription represents the type of value that is captured in a specific AuxRecord field. There are multiple data types supported in Workflow Manager like - file, folder, text, date, etc.
AuxRecordValueObject
AuxRecordValue represents the values of extended/linked properties associated with a job.
Properties:alias StringThe alias for the field in the table.
canUpdate BooleanIndicates whether the extended property value can be updated.
data ObjectThe data contained in the field.
dataType StringThe type of data expected in the field.
Possible Values: small-integer | integer | single | double | string | date | oid | geometry | blob | raster | guid | global-id | xml
displayOrder NumberThe order each field is displayed.
displayType StringThe type of extended property item.
Possible Values: default | text | date | domain | file | geo-file | folder | list | table-list | multi-level-table-list
domain StringThe domain value configured for the field.
filter StringThe filter to restrict the types of records supported.
length NumberThe length of the property string.
name StringThe name property associated with the record.
required BooleanIndicates whether the property is a required or optional field.
tableListClass StringThe lookup table that contains the list of values which will be selected.
tableListDisplayField StringThe field that will be displayed for the extended property.
tableListStoreField StringThe field that contains the value that gets stored as the extended property value.
userVisible BooleanIndicates whether the value will be visible to the user or not.
FieldValueObject
FieldValue represents a single entry of a geodatabase domain or table list, applicable to constraining the values of an extended or linked property.
JobAttachmentObject
JobAttachment represents an attachments associated with a job.
JobCreationParametersObject
JobCreationParameters provides information about the properties used for creating a job.
Properties:assignedTo StringThe name of the user or group to whom the job will be assigned.
assignedType StringIndicates whether the job is assigned to a user, group or unassigned.
Possible Values: unassigned | user | group
autoCommitWorkflow BooleanIndicates whether the workflow will be automatically committed upon creation of the job. The workflow cannot be edited after being committed to the system.
autoExecute BooleanIndicates whether the job workflow will start execution automatically upon creation of the job.
dataWorkspaceId StringThe unique id of the data workspace of the job.
description StringThe description of the job.
dueDate DateThe date on which the job is expected to be complete.
jobTypeId NumberThe unique id of the job type from which to create the new job from.
loi GeometryThe geometry of the job's location of interest (LOI). Supported geometry types include point, multipoint and polygon.
name StringThe name of the new job.
numJobs StringThe number of jobs to be created.
ownedBy StringThe name of the user that will own the job. Job ownership allows modification of job properties and not workflow execution.
parentJobId NumberThe unique id of the job that will be designated as the parent job of the new job.
parentVersion StringThe name of the geodatabase version that will be the parent version of the new job's version. By default it'll be the parent version of the data workspace.
priority NumberThe numeric value to denote priority of the job.
startDate DateThe date on which the job is scheduled to begin.
user StringThe username of the user creating the job.
JobDependencyObject
JobDependency represents a dependency associated with a job.
Properties:depJobId NumberThe unique id of the job on which the current job depends.
depOnType StringIndicates whether the job is dependent on a step, stage or status of the other job.
Possible Values: step | stage | status
depOnValue StringThe value of the step, stage or status of the other job on which the current job is dependent.
heldOnValue NumberThe value of the step, stage or status at which the current job will be held.
holdOnType StringIndicates whether the job is held at a step, stage or status.
Possible Values: step | stage | status
id NumberThe unique id of the dependency.
jobID StringThe unique id of the job on which the dependency exists.
JobInfoObject
JobInfo represents a collection of job properties
Properties:assignedTo StringThe name of the user or group to whom the job is assigned.
assignedType StringIndicates whether the job is assigned to a user, group or unassigned.
Possible Values: unassigned | user | group
childJobIds Number[]An array of unique job ids designated as child jobs for the current job.
createdBy StringThe user name of the person that created the job.
createdDate DateThe date the job was created.
dataWorkspaceId StringThe unique id of the data workspace of the job.
description StringThe description of the job.
dueDate DateThe date on which the job is expected to be complete.
endDate DateThe actual date the job's workflow was completed.
id NumberThe unique id to identify the job.
jobTypeId NumberThe unique id of the job type whose instance is the current job.
loi GeometryThe geometry of the job's location of interest (LOI). Supported geometry types include point, multipoint and polygon.
name StringThe name of the job.
ownedBy StringThe name of the user that will own the job. Job ownership allows modification of job properties and not workflow execution.
parentJobId NumberThe unique id of the job that will be designated as the parent job of the new job.
parentVersion StringThe name of the geodatabase version that is the parent version of the job's version. By default it'll be the parent version of the data workspace.
pendingDays NumberThe number of days that the job has been active.
percentageComplete NumberThe percentage of work completed on the job.
priority NumberThe numeric value to denote priority of the job.
stage StringThe internal stage of the job which corresponds to the status of the job.
Possible Values: created | ready | working | done | closed
startDate DateThe date on which the job is scheduled to begin.
status NumberThe numeric value to represent the current status of the job.
versionExists BooleanIndicates whether a version exists for the job.
versionInfo JobVersionInfoThe information about job's geodatabase version.
versionName StringThe name of the job's geodatabase version.
JobQueryParametersObject
JobQueryParameters is a full query definition of the selected query.
Properties:aliases StringAn alias of fields included in the select statement.
fields StringAn array of fields included in the select statement.
orderBy StringThe field that will be used to order the results returned by the query.
tables StringThe tables that will be used in the where clause for selection.
where StringThe where clause used as a filter for selecting job information.
user StringThe username of the user who is requesting query.
JobUpdateParametersObject
JobUpdateParameters is a collection of properties that can be updated for jobs.
Properties:assignedTo StringThe name of the user or group to whom the job will be assigned.
assignedType StringIndicates whether the job is assigned to a user, group or unassigned.
Possible Values: unassigned | user | group
dataWorkspaceId StringThe unique id of the data workspace of the job.
description StringThe description of the job.
dueDate DateThe date on which the job is expected to be complete.
loi GeometryThe geometry of the job's location of interest (LOI). Supported geometry types include point, multipoint and polygon.
jobId NumberThe unique id of the job.
name StringThe name of the job.
ownedBy StringThe name of the user that will own the job. Job ownership allows modification of job properties and not workflow execution.
parentJobId NumberThe unique id of the job that will be designated as the parent job of the new job.
parentVersion StringThe name of the geodatabase version that will be the parent version of the new job's version. By default it'll be the parent version of the data workspace.
percent NumberThe percentage of work completed on the job's current step.
priority NumberThe numeric value to denote priority of the job.
startDate DateThe date on which the job is scheduled to begin.
status NumberThe unique id of the job's new status.
versionName StringThe name of the geodatabase version to be used for the job.
user StringThe user name of the user who is requesting the change.
JobVersionInfoObject
JobVersionInfo represents a collection of properties for a job's version.
QueryFieldInfoObject
QueryFieldInfo represents a collection of field properties that are returned as part of a query.
Properties:alias StringThe alias name of the field.
length StringThe field length.
name StringThe name of the data workspace.
type StringThe type of data expected in the field.
Possible Values: small-integer | integer | single | double | string | date | oid | geometry | blob | raster | guid | global-id | xml
QueryResultObject
QueryResult contains the result of a query after it has been executed.
Properties:fields QueryFieldInfo[]An array of fields and field properties in the query.
rows String[]The rows of results.