private void CancelExecute(object parameter)
        {
            SellOrder = null;
            AddSellOrderWindow AddSellOrderWindow = parameter as AddSellOrderWindow;

            CallBack(SellOrder);
            AddSellOrderWindow.Close();
        }
        private void ConfirmExecute(object parameter)
        {
            bool   IsValid       = true;
            string message       = "存在非法输入";
            string detailMessage = "";

            if (SellOrder.UnitSellPrize <= 0)
            {
                detailMessage += "单位售价不允许小于等于零\n";
                IsValid        = false;
            }
            if (SellOrder.Amount <= 0)
            {
                detailMessage += "数量不允许小于等于零\n";
                IsValid        = false;
            }
            if (IsValid)
            {
                if (CargoCollection.Amount < SellOrder.Amount)
                {
                    string        message2       = "货物数量不足";
                    string        detailMessage2 = string.Format("仓库:{0},楼层:{1},区域:{2}中的商品:{3},库存数量:{4},订单要求卖出数量:{5}。数量不足!", CargoCollection.WarehouseName, CargoCollection.PlaneName, CargoCollection.BlockName, CargoCollection.Cargo.CargoName, CargoCollection.Amount, SellOrder.Amount);
                    WarningWindow warn           = new WarningWindow(message2, detailMessage2);
                    warn.ShowDialog();
                }
                else
                {
                    CallBack(SellOrder);
                    AddSellOrderWindow AddSellOrderWindow = parameter as AddSellOrderWindow;
                    AddSellOrderWindow.Close();
                }
            }
            else
            {
                WarningWindow warn = new WarningWindow(message, detailMessage);
                warn.ShowDialog();
            }
        }