Beispiel #1
0
 public static List<StockItem> GetStockItemsByKey(Search_Stock_ByKey stockIdentifier, String ApiToken, String ApiServer)
 {
     return Newtonsoft.Json.JsonConvert.DeserializeObject<List<StockItem>>(Factory.GetResponse("Stock/GetStockItemsByKey", "stockIdentifier=" + Newtonsoft.Json.JsonConvert.SerializeObject(stockIdentifier) + "", ApiToken, ApiServer), new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore });
 }
Beispiel #2
0
        /// <summary>
        /// Returns a list of Stock Items for the provided key and location
        /// </summary>
        /// <param name="stockIdentifier">Made up of a string key, used to search Item Number, Barcode Number, Supplier Code and Supplier Basrcode Fields as well as Stock Location.</param>
        /// <returns>A list of Stock Items</returns>
        public List <StockItem> GetStockItemsByKey(Search_Stock_ByKey stockIdentifier)
        {
            var response = GetResponse("Stock/GetStockItemsByKey", "stockIdentifier=" + JsonFormatter.ConvertToJson(stockIdentifier) + "");

            return(JsonFormatter.ConvertFromJson <List <StockItem> >(response));
        }
Beispiel #3
0
 public static List <StockItem> GetStockItemsByKey(Search_Stock_ByKey stockIdentifier, Guid ApiToken, String ApiServer)
 {
     return(Newtonsoft.Json.JsonConvert.DeserializeObject <List <StockItem> >(Factory.GetResponse("Stock/GetStockItemsByKey", "stockIdentifier=" + Newtonsoft.Json.JsonConvert.SerializeObject(stockIdentifier, serializerSettings) + "", ApiToken, ApiServer), new JsonSerializerSettings {
         NullValueHandling = NullValueHandling.Ignore
     }));
 }
Beispiel #4
0
        /// <summary>
        /// Returns a list of Stock Items for the provided key and location
        /// </summary>
        /// <param name="stockIdentifier">Made up of a string key, used to search Item Number, Barcode Number, Supplier Code and Supplier Basrcode Fields as well as Stock Location.</param>
        /// <returns>A list of Stock Items</returns>
        public List <StockItem> GetStockItemsByKey(Search_Stock_ByKey stockIdentifier)
        {
            var response = GetResponse("Stock/GetStockItemsByKey", "stockIdentifier=" + System.Net.WebUtility.UrlEncode(JsonFormatter.ConvertToJson(stockIdentifier)) + "", "POST");

            return(JsonFormatter.ConvertFromJson <List <StockItem> >(response));
        }