public void LoadControl() { if ((purchaseOrder.PurchaseStatus == OrderStatus.WaitBuyerPay) || (purchaseOrder.PurchaseStatus == OrderStatus.BuyerAlreadyPaid)) { lkBtnEditshipingMode.Visible = true; } if ((purchaseOrder.PurchaseStatus == OrderStatus.Finished) || (purchaseOrder.PurchaseStatus == OrderStatus.SellerAlreadySent)) { lblModeName.Text = purchaseOrder.RealModeName; } else { lblModeName.Text = purchaseOrder.ModeName; } litFreight.Text = Globals.FormatMoney(purchaseOrder.AdjustedFreight); litOptionPrice.Text = Globals.FormatMoney(purchaseOrder.GetOptionPrice()); litDiscount.Text = Globals.FormatMoney(purchaseOrder.AdjustedDiscount); litTotalPrice.Text = Globals.FormatMoney(purchaseOrder.GetPurchaseTotal()); string str = string.Empty; if (purchaseOrder.PurchaseOrderOptions.Count > 0) { foreach (PurchaseOrderOptionInfo info in purchaseOrder.PurchaseOrderOptions) { string str2 = str; str = str2 + info.ListDescription + ":" + info.ItemDescription + ";" + info.CustomerTitle + ":" + info.CustomerDescription; } } if (!string.IsNullOrEmpty(str)) { litOderItem.Text = "(" + str + ")"; } }
private void BindOrderInfo(PurchaseOrderInfo order) { litAddress.Text = order.ShippingRegion + order.Address; litCellPhone.Text = order.CellPhone; litTelPhone.Text = order.TelPhone; litZipCode.Text = order.ZipCode; litOrderId.Text = order.OrderId; litOrderDate.Text = order.PurchaseDate.ToString(); litRemark.Text = order.Remark; litShipperMode.Text = order.RealModeName; litShippNo.Text = order.ShipOrderNumber; litSkipTo.Text = order.ShipTo; string str = string.Empty; if (order.PurchaseOrderOptions.Count > 0) { IList <PurchaseOrderOptionInfo> purchaseOrderOptions = order.PurchaseOrderOptions; str = str + "("; foreach (PurchaseOrderOptionInfo info in purchaseOrderOptions) { string str2 = str; str = str2 + info.ListDescription + ":" + info.ItemDescription + ";" + info.CustomerTitle + ":" + info.CustomerDescription; } str = str + ")"; litOptionDes.Text = str; } switch (order.PurchaseStatus) { case OrderStatus.WaitBuyerPay: litOrderStatus.Text = "等待付款"; break; case OrderStatus.BuyerAlreadyPaid: litOrderStatus.Text = "已付款等待发货"; break; case OrderStatus.SellerAlreadySent: litOrderStatus.Text = "已发货"; break; case OrderStatus.Closed: litOrderStatus.Text = "已关闭"; break; case OrderStatus.Finished: litOrderStatus.Text = "已完成"; break; } litOptionMoney.Money = order.GetOptionPrice(); litShippMoney.Money = order.AdjustedFreight; litTotalMoney.Money = order.OrderTotal; litDiscountMoney.Money = order.AdjustedDiscount; decimal num = 0M; foreach (PurchaseOrderItemInfo info2 in order.PurchaseOrderItems) { num += info2.ItemListPrice * info2.Quantity; } litItemsMoney.Money = num; }
private void BindCharges(PurchaseOrderInfo purchaseOrder) { lblModeName.Text = purchaseOrder.ModeName; litFreight.Text = Globals.FormatMoney(purchaseOrder.AdjustedFreight); litOptionPrice.Text = Globals.FormatMoney(purchaseOrder.GetOptionPrice()); litDiscount.Text = Globals.FormatMoney(purchaseOrder.AdjustedDiscount); litTotalPrice.Text = Globals.FormatMoney(purchaseOrder.GetPurchaseTotal()); string str = string.Empty; if (purchaseOrder.PurchaseOrderOptions.Count > 0) { foreach (PurchaseOrderOptionInfo info in purchaseOrder.PurchaseOrderOptions) { string str2 = str; str = str2 + info.ListDescription + ":" + info.ItemDescription + ";" + info.CustomerTitle + ":" + info.CustomerDescription; } } if (!string.IsNullOrEmpty(str)) { litOderItem.Text = "(" + str + ")"; } }