/// <summary>
        /// 出入库单编辑或复制
        /// </summary>
        /// <param name="HandleType"></param>
        /// <param name="state"></param>
        private void EditOrCopyMethod(string HandleType, WindowStatus state)
        {
            try
            {
                string        InoutBillID     = string.Empty;
                List <string> InoutBillIDList = GetSelectedRecord();//获取要编辑的出入库单记录行

                if (InoutBillIDList.Count == 0 && gvAllocBillList.SelectedRows.Count == 0)
                {
                    MessageBoxEx.Show("请选择要" + HandleType + "的数据!");
                    return;
                }
                else if (InoutBillIDList.Count > 1 && gvAllocBillList.SelectedRows.Count > 1)
                {
                    MessageBoxEx.Show("一次只能" + HandleType + "一条数据!");
                    return;
                }
                else
                {
                    if (InoutBillIDList.Count == 1)
                    {
                        InoutBillID = InoutBillIDList[0].ToString();
                    }
                    else if (gvAllocBillList.SelectedRows.Count == 1)
                    {
                        InoutBillID = gvAllocBillList.CurrentRow.Cells["Inout_Id"].Value.ToString();
                    }
                    UCAllocationBillAddOrEdit UCAllocBillHandle = new UCAllocationBillAddOrEdit(state, InoutBillID, this);
                    base.addUserControl(UCAllocBillHandle, "出入库单-" + HandleType, "UCAllocBillHandle", this.Tag.ToString(), this.Name);
                }
            }
            catch (Exception ex)
            {
                MessageBoxEx.Show(ex.Message, "异常提示", MessageBoxButtons.OK, MessageBoxIcon.Question);
            }
        }
        /// <summary>
        /// 出入库单编辑或复制
        /// </summary>
        /// <param name="HandleType"></param>
        /// <param name="state"></param>
        private void EditOrCopyMethod(string HandleType, WindowStatus state)
        {
            try
            {
                string InoutBillID = string.Empty;
                List<string> InoutBillIDList = GetSelectedRecord();//获取要编辑的出入库单记录行

                if (InoutBillIDList.Count == 0 && gvAllocBillList.SelectedRows.Count == 0)
                {
                    MessageBoxEx.Show("请选择要" + HandleType + "的数据!");
                    return;
                }
                else if (InoutBillIDList.Count > 1 && gvAllocBillList.SelectedRows.Count > 1)
                {
                    MessageBoxEx.Show("一次只能" + HandleType + "一条数据!");
                    return;
                }
                else
                {
                    if (InoutBillIDList.Count == 1)
                    {
                        InoutBillID = InoutBillIDList[0].ToString();
                    }
                    else if (gvAllocBillList.SelectedRows.Count == 1)
                    {
                        InoutBillID = gvAllocBillList.CurrentRow.Cells["Inout_Id"].Value.ToString();
                    }
                    UCAllocationBillAddOrEdit UCAllocBillHandle = new UCAllocationBillAddOrEdit(state, InoutBillID, this);
                    base.addUserControl(UCAllocBillHandle, "出入库单-" + HandleType, "UCAllocBillHandle", this.Tag.ToString(), this.Name);
                }
            }
            catch (Exception ex)
            {
                MessageBoxEx.Show(ex.Message, "异常提示", MessageBoxButtons.OK, MessageBoxIcon.Question);
            }
        }
 /// <summary>
 /// 添加出入库单
 /// </summary>
 /// <param name="send"></param>
 /// <param name="e"></param>
 private void UCAllocationBillManager_AddEvent(object send, EventArgs e)
 {
     UCAllocationBillAddOrEdit UCAllocBillAdd = new UCAllocationBillAddOrEdit(WindowStatus.Add, null, this);
     base.addUserControl(UCAllocBillAdd, "出入库单-添加", "UCAllocBillAdd", this.Tag.ToString(), this.Name);
 }
        /// <summary>
        /// 添加出入库单
        /// </summary>
        /// <param name="send"></param>
        /// <param name="e"></param>
        private void UCAllocationBillManager_AddEvent(object send, EventArgs e)
        {
            UCAllocationBillAddOrEdit UCAllocBillAdd = new UCAllocationBillAddOrEdit(WindowStatus.Add, null, this);

            base.addUserControl(UCAllocBillAdd, "出入库单-添加", "UCAllocBillAdd", this.Tag.ToString(), this.Name);
        }