GET | /user/{supplieruserid}/purchaseorder/{purchaseorderid}/purchaseorderversion/{purchaseorderversionid} |
---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class BrowsePurchaseOrderVersion extends PurchaseOrderVersionBase implements IGet
{
}
public static class PurchaseOrderVersionBase extends PurchaseOrderBase
{
public Integer PurchaseOrderVersionId = null;
public Integer getPurchaseOrderVersionId() { return PurchaseOrderVersionId; }
public PurchaseOrderVersionBase setPurchaseOrderVersionId(Integer value) { this.PurchaseOrderVersionId = value; return this; }
}
public static class PurchaseOrderBase
{
public Integer PurchaseOrderId = null;
public Integer SupplierUserId = null;
public Integer getPurchaseOrderId() { return PurchaseOrderId; }
public PurchaseOrderBase setPurchaseOrderId(Integer value) { this.PurchaseOrderId = value; return this; }
public Integer getSupplierUserId() { return SupplierUserId; }
public PurchaseOrderBase setSupplierUserId(Integer value) { this.SupplierUserId = value; return this; }
}
public static class BrowsePurchaseOrderVersionResponse extends ResponseBase
{
public PurchaseOrderVersionDetails PurchaseOrderVersion = null;
public PurchaseOrderVersionDetails getPurchaseOrderVersion() { return PurchaseOrderVersion; }
public BrowsePurchaseOrderVersionResponse setPurchaseOrderVersion(PurchaseOrderVersionDetails value) { this.PurchaseOrderVersion = value; return this; }
}
public static class ResponseBase
{
public ResponseStatus ResponseStatus = null;
public ResponseStatus getResponseStatus() { return ResponseStatus; }
public ResponseBase setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
}
public static class PurchaseOrderVersionDetails extends PurchaseOrderVersionSimple
{
public HashMap<String,String> Meta = null;
public Date ViewingDateTime = null;
public Date ReviewingDateTime = null;
public ArrayList<PurchaseOrderFileSimple> PurchaseOrderFiles = null;
public HashMap<String,String> getMeta() { return Meta; }
public PurchaseOrderVersionDetails setMeta(HashMap<String,String> value) { this.Meta = value; return this; }
public Date getViewingDateTime() { return ViewingDateTime; }
public PurchaseOrderVersionDetails setViewingDateTime(Date value) { this.ViewingDateTime = value; return this; }
public Date getReviewingDateTime() { return ReviewingDateTime; }
public PurchaseOrderVersionDetails setReviewingDateTime(Date value) { this.ReviewingDateTime = value; return this; }
public ArrayList<PurchaseOrderFileSimple> getPurchaseOrderFiles() { return PurchaseOrderFiles; }
public PurchaseOrderVersionDetails setPurchaseOrderFiles(ArrayList<PurchaseOrderFileSimple> value) { this.PurchaseOrderFiles = value; return this; }
}
public static class PurchaseOrderVersionSimple
{
public Integer Id = null;
public Integer PurchaseOrderId = null;
public Integer SupplierUserId = null;
public Integer Version = null;
public Boolean IsViewed = null;
public ReviewStatus Status = null;
public Integer getId() { return Id; }
public PurchaseOrderVersionSimple setId(Integer value) { this.Id = value; return this; }
public Integer getPurchaseOrderId() { return PurchaseOrderId; }
public PurchaseOrderVersionSimple setPurchaseOrderId(Integer value) { this.PurchaseOrderId = value; return this; }
public Integer getSupplierUserId() { return SupplierUserId; }
public PurchaseOrderVersionSimple setSupplierUserId(Integer value) { this.SupplierUserId = value; return this; }
public Integer getVersion() { return Version; }
public PurchaseOrderVersionSimple setVersion(Integer value) { this.Version = value; return this; }
public Boolean getIsViewed() { return IsViewed; }
public PurchaseOrderVersionSimple setIsViewed(Boolean value) { this.IsViewed = value; return this; }
public ReviewStatus getStatus() { return Status; }
public PurchaseOrderVersionSimple setStatus(ReviewStatus value) { this.Status = value; return this; }
}
public static enum ReviewStatus
{
@SerializedName("0") Draft(0),
@SerializedName("1") Commented(1),
@SerializedName("2") Accepted(2);
private final int value;
ReviewStatus(final int intValue) { value = intValue; }
public int getValue() { return value; }
}
public static class PurchaseOrderFileSimple extends BrowseFileResponseBase
{
public Integer PurchaseOrderVersionId = null;
public PurchaseOrderDocumentType DocumentType = null;
public Integer getPurchaseOrderVersionId() { return PurchaseOrderVersionId; }
public PurchaseOrderFileSimple setPurchaseOrderVersionId(Integer value) { this.PurchaseOrderVersionId = value; return this; }
public PurchaseOrderDocumentType getDocumentType() { return DocumentType; }
public PurchaseOrderFileSimple setDocumentType(PurchaseOrderDocumentType value) { this.DocumentType = value; return this; }
}
public static class BrowseFileResponseBase
{
public Integer Id = null;
public Integer FileContentId = null;
public String FileName = null;
public Long Size = null;
public Integer getId() { return Id; }
public BrowseFileResponseBase setId(Integer value) { this.Id = value; return this; }
public Integer getFileContentId() { return FileContentId; }
public BrowseFileResponseBase setFileContentId(Integer value) { this.FileContentId = value; return this; }
public String getFileName() { return FileName; }
public BrowseFileResponseBase setFileName(String value) { this.FileName = value; return this; }
public Long getSize() { return Size; }
public BrowseFileResponseBase setSize(Long value) { this.Size = value; return this; }
}
public static enum PurchaseOrderDocumentType
{
@SerializedName("0") Draft(0),
@SerializedName("1") Comment(1);
private final int value;
PurchaseOrderDocumentType(final int intValue) { value = intValue; }
public int getValue() { return value; }
}
}
Java BrowsePurchaseOrderVersion DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /user/{supplieruserid}/purchaseorder/{purchaseorderid}/purchaseorderversion/{purchaseorderversionid} HTTP/1.1 Host: szallitoiportal-be.veolia.hu Accept: text/jsv
HTTP/1.1 200 OK Content-Type: text/jsv Content-Length: length { PurchaseOrderVersion: { Meta: { String: String }, ViewingDateTime: 0001-01-01, ReviewingDateTime: 0001-01-01, PurchaseOrderFiles: [ { PurchaseOrderVersionId: 0, DocumentType: 0, Id: 0, FileContentId: 0, FileName: String, Size: 0 } ], Id: 0, PurchaseOrderId: 0, SupplierUserId: 0, Version: 0, IsViewed: False, Status: 0 }, ResponseStatus: { ErrorCode: String, Message: String, StackTrace: String, Errors: [ { ErrorCode: String, FieldName: String, Message: String, Meta: { String: String } } ], Meta: { String: String } } }