コード例 #1
0
        public HttpResponseMessage getOrderDatabyKey(string orderkey)
        {
            InvoiceBO invoiceBO = new InvoiceBO();
            var       orderdata = bl.getOrderDatabyKey(orderkey);

            invoiceBO.order = orderdata;

            var containerdata = dl.GetContainers(orderkey);

            if (containerdata != null)
            {
                invoiceBO.containers = containerdata;
            }

            if (invoiceBO != null)
            {
                return(Request.CreateResponse(HttpStatusCode.OK, invoiceBO, Configuration.Formatters.JsonFormatter));
            }
            else
            {
                return(Request.CreateResponse(HttpStatusCode.InternalServerError));
            }
        }