| GET,PUT,POST | /{Workspace}/InventoryItemType | ||
|---|---|---|---|
| GET,PUT,POST | /{Workspace}/InventoryItemType/{ObjectId} |
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class InventoryItemType extends InventoryTreeNode
{
public String Type = null;
public String ObjectId = null;
public String Workspace = null;
public String ExternalId = null;
public String Created = null;
public String LastUpdated = null;
public String ItemType = null;
public String Desc = null;
public String VendorNum = null;
public String PurchasingUOM = null;
public String SalesUOM = null;
public Integer ReorderLevel = null;
public Integer ReorderQty = null;
public Double DefaultUnitCost = null;
public Double DefaultUnitPrice = null;
public String Barcode = null;
public Boolean UseSerialNumbers = null;
public String Template = null;
public HashMap<String,String> Data = null;
public Boolean Enabled = null;
public String ParentCategoryId = null;
public Boolean IncludeInactive = null;
public String getType() { return Type; }
public InventoryItemType setType(String value) { this.Type = value; return this; }
public String getObjectId() { return ObjectId; }
public InventoryItemType setObjectId(String value) { this.ObjectId = value; return this; }
public String getWorkspace() { return Workspace; }
public InventoryItemType setWorkspace(String value) { this.Workspace = value; return this; }
public String getExternalId() { return ExternalId; }
public InventoryItemType setExternalId(String value) { this.ExternalId = value; return this; }
public String getCreated() { return Created; }
public InventoryItemType setCreated(String value) { this.Created = value; return this; }
public String getLastUpdated() { return LastUpdated; }
public InventoryItemType setLastUpdated(String value) { this.LastUpdated = value; return this; }
public String getItemType() { return ItemType; }
public InventoryItemType setItemType(String value) { this.ItemType = value; return this; }
public String getDesc() { return Desc; }
public InventoryItemType setDesc(String value) { this.Desc = value; return this; }
public String getVendorNum() { return VendorNum; }
public InventoryItemType setVendorNum(String value) { this.VendorNum = value; return this; }
public String getPurchasingUOM() { return PurchasingUOM; }
public InventoryItemType setPurchasingUOM(String value) { this.PurchasingUOM = value; return this; }
public String getSalesUOM() { return SalesUOM; }
public InventoryItemType setSalesUOM(String value) { this.SalesUOM = value; return this; }
public Integer getReorderLevel() { return ReorderLevel; }
public InventoryItemType setReorderLevel(Integer value) { this.ReorderLevel = value; return this; }
public Integer getReorderQty() { return ReorderQty; }
public InventoryItemType setReorderQty(Integer value) { this.ReorderQty = value; return this; }
public Double getDefaultUnitCost() { return DefaultUnitCost; }
public InventoryItemType setDefaultUnitCost(Double value) { this.DefaultUnitCost = value; return this; }
public Double getDefaultUnitPrice() { return DefaultUnitPrice; }
public InventoryItemType setDefaultUnitPrice(Double value) { this.DefaultUnitPrice = value; return this; }
public String getBarcode() { return Barcode; }
public InventoryItemType setBarcode(String value) { this.Barcode = value; return this; }
public Boolean isUseSerialNumbers() { return UseSerialNumbers; }
public InventoryItemType setUseSerialNumbers(Boolean value) { this.UseSerialNumbers = value; return this; }
public String getTemplate() { return Template; }
public InventoryItemType setTemplate(String value) { this.Template = value; return this; }
public HashMap<String,String> getData() { return Data; }
public InventoryItemType setData(HashMap<String,String> value) { this.Data = value; return this; }
public Boolean isEnabled() { return Enabled; }
public InventoryItemType setEnabled(Boolean value) { this.Enabled = value; return this; }
public String getParentCategoryId() { return ParentCategoryId; }
public InventoryItemType setParentCategoryId(String value) { this.ParentCategoryId = value; return this; }
public Boolean isIncludeInactive() { return IncludeInactive; }
public InventoryItemType setIncludeInactive(Boolean value) { this.IncludeInactive = value; return this; }
}
public static class InventoryTreeNode
{
public String Type = null;
public Integer DescendantCount = null;
public String getType() { return Type; }
public InventoryTreeNode setType(String value) { this.Type = value; return this; }
public Integer getDescendantCount() { return DescendantCount; }
public InventoryTreeNode setDescendantCount(Integer value) { this.DescendantCount = value; return this; }
}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /{Workspace}/InventoryItemType HTTP/1.1
Host: dev.fieldsquared.com
Accept: application/json
Content-Type: application/json
Content-Length: length
{"Type":"ItemType","ObjectId":"String","Workspace":"String","ExternalId":"String","Created":"String","LastUpdated":"String","ItemType":"String","Desc":"String","VendorNum":"String","PurchasingUOM":"String","SalesUOM":"String","ReorderLevel":0,"ReorderQty":0,"DefaultUnitCost":0,"DefaultUnitPrice":0,"Barcode":"String","UseSerialNumbers":false,"Template":"String","Data":{"String":"String"},"Enabled":false,"ParentCategoryId":"String","IncludeInactive":false,"DescendantCount":0}