| POST | /WorkflowStep/update |
|---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class CreateWorkflowStepRequest extends WorkflowStep
{
}
public static class WorkflowStep
{
public Integer id = null;
@References(Document.class)
public Integer workflowId = null;
public Integer stepOrder = null;
public Integer statusId = null;
@Required()
@StringLength(255)
public String stepName = null;
@Required()
public Boolean isRequired = null;
public Integer slaLegalValue = null;
public Boolean slaLegalIsByDay = null;
public Integer slaInternalValue = null;
public Boolean slaInternalIsByDay = null;
public Boolean requireAttachment = null;
public Boolean isUsingForm = null;
@Required()
public String description = null;
public Integer createdBy = null;
@Ignore()
public ArrayList<Integer> departmentIds = null;
@Ignore()
public ArrayList<Integer> mainAssigneeIds = null;
@Ignore()
public ArrayList<Integer> coDepartmentIds = null;
@Ignore()
public ArrayList<Integer> supportingAssigneeIds = null;
@Ignore()
public ArrayList<Integer> stepBasisDocumentIds = null;
@Ignore()
public ArrayList<StepAttached> attachedDocuments = null;
public Integer getId() { return id; }
public WorkflowStep setId(Integer value) { this.id = value; return this; }
public Integer getWorkflowId() { return workflowId; }
public WorkflowStep setWorkflowId(Integer value) { this.workflowId = value; return this; }
public Integer getStepOrder() { return stepOrder; }
public WorkflowStep setStepOrder(Integer value) { this.stepOrder = value; return this; }
public Integer getStatusId() { return statusId; }
public WorkflowStep setStatusId(Integer value) { this.statusId = value; return this; }
public String getStepName() { return stepName; }
public WorkflowStep setStepName(String value) { this.stepName = value; return this; }
public Boolean getIsRequired() { return isRequired; }
public WorkflowStep setIsRequired(Boolean value) { this.isRequired = value; return this; }
public Integer getSlaLegalValue() { return slaLegalValue; }
public WorkflowStep setSlaLegalValue(Integer value) { this.slaLegalValue = value; return this; }
public Boolean isSlaLegalIsByDay() { return slaLegalIsByDay; }
public WorkflowStep setSlaLegalIsByDay(Boolean value) { this.slaLegalIsByDay = value; return this; }
public Integer getSlaInternalValue() { return slaInternalValue; }
public WorkflowStep setSlaInternalValue(Integer value) { this.slaInternalValue = value; return this; }
public Boolean isSlaInternalIsByDay() { return slaInternalIsByDay; }
public WorkflowStep setSlaInternalIsByDay(Boolean value) { this.slaInternalIsByDay = value; return this; }
public Boolean isRequireAttachment() { return requireAttachment; }
public WorkflowStep setRequireAttachment(Boolean value) { this.requireAttachment = value; return this; }
public Boolean getIsUsingForm() { return isUsingForm; }
public WorkflowStep setIsUsingForm(Boolean value) { this.isUsingForm = value; return this; }
public String getDescription() { return description; }
public WorkflowStep setDescription(String value) { this.description = value; return this; }
public Integer getCreatedBy() { return createdBy; }
public WorkflowStep setCreatedBy(Integer value) { this.createdBy = value; return this; }
public ArrayList<Integer> getDepartmentIds() { return departmentIds; }
public WorkflowStep setDepartmentIds(ArrayList<Integer> value) { this.departmentIds = value; return this; }
public ArrayList<Integer> getMainAssigneeIds() { return mainAssigneeIds; }
public WorkflowStep setMainAssigneeIds(ArrayList<Integer> value) { this.mainAssigneeIds = value; return this; }
public ArrayList<Integer> getCoDepartmentIds() { return coDepartmentIds; }
public WorkflowStep setCoDepartmentIds(ArrayList<Integer> value) { this.coDepartmentIds = value; return this; }
public ArrayList<Integer> getSupportingAssigneeIds() { return supportingAssigneeIds; }
public WorkflowStep setSupportingAssigneeIds(ArrayList<Integer> value) { this.supportingAssigneeIds = value; return this; }
public ArrayList<Integer> getStepBasisDocumentIds() { return stepBasisDocumentIds; }
public WorkflowStep setStepBasisDocumentIds(ArrayList<Integer> value) { this.stepBasisDocumentIds = value; return this; }
public ArrayList<StepAttached> getAttachedDocuments() { return attachedDocuments; }
public WorkflowStep setAttachedDocuments(ArrayList<StepAttached> value) { this.attachedDocuments = value; return this; }
}
public static class StepAttached
{
public Integer id = null;
public String documentCode = null;
public String title = null;
public Boolean isSequentialSigning = null;
public UploadedFiles pendingSignFile = null;
public UploadedFiles originalFile = null;
public ArrayList<SignerConfigDetail> signerConfigs = null;
public Integer getId() { return id; }
public StepAttached setId(Integer value) { this.id = value; return this; }
public String getDocumentCode() { return documentCode; }
public StepAttached setDocumentCode(String value) { this.documentCode = value; return this; }
public String getTitle() { return title; }
public StepAttached setTitle(String value) { this.title = value; return this; }
public Boolean getIsSequentialSigning() { return isSequentialSigning; }
public StepAttached setIsSequentialSigning(Boolean value) { this.isSequentialSigning = value; return this; }
public UploadedFiles getPendingSignFile() { return pendingSignFile; }
public StepAttached setPendingSignFile(UploadedFiles value) { this.pendingSignFile = value; return this; }
public UploadedFiles getOriginalFile() { return originalFile; }
public StepAttached setOriginalFile(UploadedFiles value) { this.originalFile = value; return this; }
public ArrayList<SignerConfigDetail> getSignerConfigs() { return signerConfigs; }
public StepAttached setSignerConfigs(ArrayList<SignerConfigDetail> value) { this.signerConfigs = value; return this; }
}
public static class UploadedFiles extends BasicUploadedFile
{
public Long id = null;
public String uploadedFile = null;
public Integer subDocumentId = null;
public Integer stepId = null;
public Integer code = null;
public Long getId() { return id; }
public UploadedFiles setId(Long value) { this.id = value; return this; }
public String getUploadedFile() { return uploadedFile; }
public UploadedFiles setUploadedFile(String value) { this.uploadedFile = value; return this; }
public Integer getSubDocumentId() { return subDocumentId; }
public UploadedFiles setSubDocumentId(Integer value) { this.subDocumentId = value; return this; }
public Integer getStepId() { return stepId; }
public UploadedFiles setStepId(Integer value) { this.stepId = value; return this; }
public Integer getCode() { return code; }
public UploadedFiles setCode(Integer value) { this.code = value; return this; }
}
public static class BasicUploadedFile
{
public String fileName = null;
public String filekey = null;
public String fileUrl = null;
public String checksum = null;
public String eTag = null;
public Long fileSize = null;
public String getFileName() { return fileName; }
public BasicUploadedFile setFileName(String value) { this.fileName = value; return this; }
public String getFilekey() { return filekey; }
public BasicUploadedFile setFilekey(String value) { this.filekey = value; return this; }
public String getFileUrl() { return fileUrl; }
public BasicUploadedFile setFileUrl(String value) { this.fileUrl = value; return this; }
public String getChecksum() { return checksum; }
public BasicUploadedFile setChecksum(String value) { this.checksum = value; return this; }
public String getETag() { return eTag; }
public BasicUploadedFile setETag(String value) { this.eTag = value; return this; }
public Long getFileSize() { return fileSize; }
public BasicUploadedFile setFileSize(Long value) { this.fileSize = value; return this; }
}
public static class SignerConfigDetail extends SignerConfig
{
public WorkFlowProfile profile = null;
public Roles role = null;
public WorkFlowProfile getProfile() { return profile; }
public SignerConfigDetail setProfile(WorkFlowProfile value) { this.profile = value; return this; }
public Roles getRole() { return role; }
public SignerConfigDetail setRole(Roles value) { this.role = value; return this; }
}
public static class SignerConfig extends BasicSignerConfig
{
public Integer id = null;
public Integer documentId = null;
public Integer stepId = null;
public Integer getId() { return id; }
public SignerConfig setId(Integer value) { this.id = value; return this; }
public Integer getDocumentId() { return documentId; }
public SignerConfig setDocumentId(Integer value) { this.documentId = value; return this; }
public Integer getStepId() { return stepId; }
public SignerConfig setStepId(Integer value) { this.stepId = value; return this; }
}
public static class BasicSignerConfig
{
public Integer subDocumentId = null;
public Integer departmentId = null;
public Short signerType = null;
public Integer signerRefId = null;
@Ignore()
public String signerRefText = null;
public Short actionType = null;
public Integer orderIndex = null;
public Integer getSubDocumentId() { return subDocumentId; }
public BasicSignerConfig setSubDocumentId(Integer value) { this.subDocumentId = value; return this; }
public Integer getDepartmentId() { return departmentId; }
public BasicSignerConfig setDepartmentId(Integer value) { this.departmentId = value; return this; }
public Short getSignerType() { return signerType; }
public BasicSignerConfig setSignerType(Short value) { this.signerType = value; return this; }
public Integer getSignerRefId() { return signerRefId; }
public BasicSignerConfig setSignerRefId(Integer value) { this.signerRefId = value; return this; }
public String getSignerRefText() { return signerRefText; }
public BasicSignerConfig setSignerRefText(String value) { this.signerRefText = value; return this; }
public Short getActionType() { return actionType; }
public BasicSignerConfig setActionType(Short value) { this.actionType = value; return this; }
public Integer getOrderIndex() { return orderIndex; }
public BasicSignerConfig setOrderIndex(Integer value) { this.orderIndex = value; return this; }
}
public static class WorkFlowProfile
{
public Integer id = null;
public String name = null;
public String fullName = null;
public String email = null;
public Integer departmentId = null;
public String avatar = null;
public String telephone = null;
public Date birthday = null;
public Integer confirmStatus = null;
public String confirmStatusText = null;
public Date signAt = null;
public Long signedFileId = null;
public Integer originalFileId = null;
public String signedFileName = null;
public Boolean isSigned = null;
public String signStatusText = null;
public Integer getId() { return id; }
public WorkFlowProfile setId(Integer value) { this.id = value; return this; }
public String getName() { return name; }
public WorkFlowProfile setName(String value) { this.name = value; return this; }
public String getFullName() { return fullName; }
public WorkFlowProfile setFullName(String value) { this.fullName = value; return this; }
public String getEmail() { return email; }
public WorkFlowProfile setEmail(String value) { this.email = value; return this; }
public Integer getDepartmentId() { return departmentId; }
public WorkFlowProfile setDepartmentId(Integer value) { this.departmentId = value; return this; }
public String getAvatar() { return avatar; }
public WorkFlowProfile setAvatar(String value) { this.avatar = value; return this; }
public String getTelephone() { return telephone; }
public WorkFlowProfile setTelephone(String value) { this.telephone = value; return this; }
public Date getBirthday() { return birthday; }
public WorkFlowProfile setBirthday(Date value) { this.birthday = value; return this; }
public Integer getConfirmStatus() { return confirmStatus; }
public WorkFlowProfile setConfirmStatus(Integer value) { this.confirmStatus = value; return this; }
public String getConfirmStatusText() { return confirmStatusText; }
public WorkFlowProfile setConfirmStatusText(String value) { this.confirmStatusText = value; return this; }
public Date getSignAt() { return signAt; }
public WorkFlowProfile setSignAt(Date value) { this.signAt = value; return this; }
public Long getSignedFileId() { return signedFileId; }
public WorkFlowProfile setSignedFileId(Long value) { this.signedFileId = value; return this; }
public Integer getOriginalFileId() { return originalFileId; }
public WorkFlowProfile setOriginalFileId(Integer value) { this.originalFileId = value; return this; }
public String getSignedFileName() { return signedFileName; }
public WorkFlowProfile setSignedFileName(String value) { this.signedFileName = value; return this; }
public Boolean getIsSigned() { return isSigned; }
public WorkFlowProfile setIsSigned(Boolean value) { this.isSigned = value; return this; }
public String getSignStatusText() { return signStatusText; }
public WorkFlowProfile setSignStatusText(String value) { this.signStatusText = value; return this; }
}
public static class Roles
{
public Integer id = null;
@StringLength(50)
public String name = null;
public Date createdAt = null;
public Date deletedAt = null;
public Date updatedAt = null;
public Integer updatedBy = null;
public Integer deletedBy = null;
public Integer createdBy = null;
@Ignore()
public ArrayList<String> permission = null;
public Integer getId() { return id; }
public Roles setId(Integer value) { this.id = value; return this; }
public String getName() { return name; }
public Roles setName(String value) { this.name = value; return this; }
public Date getCreatedAt() { return createdAt; }
public Roles setCreatedAt(Date value) { this.createdAt = value; return this; }
public Date getDeletedAt() { return deletedAt; }
public Roles setDeletedAt(Date value) { this.deletedAt = value; return this; }
public Date getUpdatedAt() { return updatedAt; }
public Roles setUpdatedAt(Date value) { this.updatedAt = value; return this; }
public Integer getUpdatedBy() { return updatedBy; }
public Roles setUpdatedBy(Integer value) { this.updatedBy = value; return this; }
public Integer getDeletedBy() { return deletedBy; }
public Roles setDeletedBy(Integer value) { this.deletedBy = value; return this; }
public Integer getCreatedBy() { return createdBy; }
public Roles setCreatedBy(Integer value) { this.createdBy = value; return this; }
public ArrayList<String> getPermission() { return permission; }
public Roles setPermission(ArrayList<String> value) { this.permission = value; return this; }
}
public static class WorkflowStepResponse implements IResponseRequest
{
public Integer code = null;
public String message = null;
public Integer insertedId = null;
public Integer getCode() { return code; }
public WorkflowStepResponse setCode(Integer value) { this.code = value; return this; }
public String getMessage() { return message; }
public WorkflowStepResponse setMessage(String value) { this.message = value; return this; }
public Integer getInsertedId() { return insertedId; }
public WorkflowStepResponse setInsertedId(Integer value) { this.insertedId = value; return this; }
}
}
Java CreateWorkflowStepRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /WorkflowStep/update HTTP/1.1
Host: etc-api.vsmlab.vn
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<CreateWorkflowStepRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/tvpl.api.ServiceModel">
<AttachedDocuments xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">
<StepAttached>
<DocumentCode>String</DocumentCode>
<Id>0</Id>
<IsSequentialSigning>false</IsSequentialSigning>
<OriginalFile>
<Checksum>String</Checksum>
<ETag>String</ETag>
<FileName>String</FileName>
<FileSize>0</FileSize>
<FileUrl>String</FileUrl>
<Filekey>String</Filekey>
<Code>0</Code>
<Id>0</Id>
<StepId>0</StepId>
<SubDocumentId>0</SubDocumentId>
<UploadedFile>String</UploadedFile>
</OriginalFile>
<PendingSignFile>
<Checksum>String</Checksum>
<ETag>String</ETag>
<FileName>String</FileName>
<FileSize>0</FileSize>
<FileUrl>String</FileUrl>
<Filekey>String</Filekey>
<Code>0</Code>
<Id>0</Id>
<StepId>0</StepId>
<SubDocumentId>0</SubDocumentId>
<UploadedFile>String</UploadedFile>
</PendingSignFile>
<SignerConfigs>
<SignerConfigDetail>
<ActionType>0</ActionType>
<DepartmentId>0</DepartmentId>
<OrderIndex>0</OrderIndex>
<SignerRefId>0</SignerRefId>
<SignerRefText>String</SignerRefText>
<SignerType>0</SignerType>
<SubDocumentId>0</SubDocumentId>
<CreateAt>0001-01-01T00:00:00</CreateAt>
<CreateBy>0</CreateBy>
<DocumentId>0</DocumentId>
<Id>0</Id>
<StepId>0</StepId>
<Profile>
<Avatar>String</Avatar>
<Birthday>0001-01-01T00:00:00</Birthday>
<ConfirmStatus>0</ConfirmStatus>
<ConfirmStatusText>String</ConfirmStatusText>
<DepartmentId>0</DepartmentId>
<Email>String</Email>
<FullName>String</FullName>
<Id>0</Id>
<IsSigned>false</IsSigned>
<Name>String</Name>
<OriginalFileId>0</OriginalFileId>
<SignAt>0001-01-01T00:00:00</SignAt>
<SignStatusText>String</SignStatusText>
<SignedFileId>0</SignedFileId>
<SignedFileName>String</SignedFileName>
<Telephone>String</Telephone>
</Profile>
<Role>
<CreatedAt>0001-01-01T00:00:00</CreatedAt>
<CreatedBy>0</CreatedBy>
<DeletedAt>0001-01-01T00:00:00</DeletedAt>
<DeletedBy>0</DeletedBy>
<Id>0</Id>
<Name>String</Name>
<Permission xmlns:d7p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d7p1:string>String</d7p1:string>
</Permission>
<UpdatedAt>0001-01-01T00:00:00</UpdatedAt>
<UpdatedBy>0</UpdatedBy>
</Role>
</SignerConfigDetail>
</SignerConfigs>
<Title>String</Title>
</StepAttached>
</AttachedDocuments>
<CoDepartmentIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">
<d2p1:int>0</d2p1:int>
</CoDepartmentIds>
<CreatedAt xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0001-01-01T00:00:00</CreatedAt>
<CreatedBy xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</CreatedBy>
<DeletedAt xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0001-01-01T00:00:00</DeletedAt>
<DeletedBy xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</DeletedBy>
<DepartmentIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">
<d2p1:int>0</d2p1:int>
</DepartmentIds>
<Description xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">String</Description>
<Id xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</Id>
<IsRequired xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">false</IsRequired>
<IsUsingForm xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">false</IsUsingForm>
<MainAssigneeIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">
<d2p1:int>0</d2p1:int>
</MainAssigneeIds>
<RequireAttachment xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">false</RequireAttachment>
<SLAInternalIsByDay xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">false</SLAInternalIsByDay>
<SLAInternalValue xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</SLAInternalValue>
<SLALegalIsByDay xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">false</SLALegalIsByDay>
<SLALegalValue xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</SLALegalValue>
<SLAWarningSentAt xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0001-01-01T00:00:00</SLAWarningSentAt>
<SLAWarningSentCount xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</SLAWarningSentCount>
<StatusId xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</StatusId>
<StepBasisDocumentIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">
<d2p1:int>0</d2p1:int>
</StepBasisDocumentIds>
<StepName xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">String</StepName>
<StepOrder xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</StepOrder>
<SupportingAssigneeIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">
<d2p1:int>0</d2p1:int>
</SupportingAssigneeIds>
<UpdatedAt xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0001-01-01T00:00:00</UpdatedAt>
<UpdatedBy xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</UpdatedBy>
<WorkflowId xmlns="http://schemas.datacontract.org/2004/07/tvpl.data.Models">0</WorkflowId>
</CreateWorkflowStepRequest>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <WorkflowStepResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/tvpl.api.ServiceModel"> <Code>0</Code> <InsertedId>0</InsertedId> <Message>String</Message> </WorkflowStepResponse>