public void OrderServiceRelayConfirm()
        {
            OrderServiceReference.ConfirmationCollectionDataContract request = new OrderServiceReference.ConfirmationCollectionDataContract()
            {
                new OrderServiceReference.ConfirmationDataContract()
                {
                    Code = "NCP90R-AHMRK",
                    Plant = 1110,
                    Units = 3,
                    Produced = new DateTime(2014, 01, 05),
                    Suffix = "U1",
                    Color = new OrderServiceReference.ColorDataContract()
                    {
                        External = "040",
                        Internal = "12"
                    },
                    Category = "TOYOTA",
                    Purchaser = new OrderServiceReference.PurchaserDataContract()
                    {
                        Group = "TU",
                        Organization = 1100
                    },
                    Vendor = "TTAFVEHJPY",
                    Delivery = new DateTime(2014, 05, 31),
                    Order = "3KN201405"
                }
            };

            OrderServiceReference.OrderServiceClient client = new OrderServiceReference.OrderServiceClient("OrderService.basicHttpRelay");

            client.Confirm(request);
        }
Ejemplo n.º 2
0
        public ActionResult CancelOrder(int orderId, int orderStatusId)
        {
            var            serviceReference = new OrderServiceReference.OrderServiceClient();
            OrderStatusDTO os = new OrderStatusDTO()
            {
                OrderId       = orderId,
                OrderStatusId = 3
            };
            var response = serviceReference.UpdateOrderStatus(os);

            return(Json(response));
        }
        public ActionResult MyOrder()
        {
            if (Session["User"] == null)
            {
                TempData["Login"] = "******";
                return(Redirect("/Account/Login"));
            }

            UserDTO u = (UserDTO)Session["User"];
            var     serviceReference = new OrderServiceReference.OrderServiceClient();
            var     list             = serviceReference.GetOrdersByClient(u.UserId);

            ViewBag.ListOrder = list;

            return(View());
        }