コード例 #1
0
        public bool CreateOrder(VOOrder order)
        {
            var resultMessage = new { result = false };

            Utility.CheckAuthentication(() => DAL.CreateOrder(user.Token, order.IdClient, order.ProductList,
                                                              order.Address.Latitude, order.Address.Longitude,
                                                              order.Date, order.Status)
                                        , (res) =>
            {
                resultMessage = JsonConvert.DeserializeAnonymousType(res.Content.ReadAsStringAsync().Result, resultMessage);
            }, this);

            return(resultMessage.result);
        }
コード例 #2
0
        public VOOrder GetOrder(string id)
        {
            VOOrder order = null;

            Utility.CheckAuthentication(() => DAL.GetOrder(user.Token, id), (res) =>
            {
                order = JsonConvert.DeserializeObject <VOOrder>(res.Content.ToString());
                if (order != null)
                {
                    order.Id = id;
                }
            }, this);

            return(order);
        }
コード例 #3
0
 public bool CreateOrder(VOOrder order)
 {
     throw new NotImplementedException();
 }