예제 #1
0
        private StoreHouseProper GetHousePro(EnumStoreHouse enumHouseName)
        {
            StoreHouseProper housePro = null;

            for (int i = 0; i < houseProList.Count(); i++)
            {
                if (houseProList[i].HouseName == enumHouseName)
                {
                    housePro = houseProList[i];
                }
            }
            return(housePro);
        }
예제 #2
0
 private void tscb_Layerth_TextChanged(object sender, EventArgs e)
 {
     if (IsIntNum(this.tscb_Layerth.Text) == false)
     {
         this.tscb_Layerth.Text = "1";
         MessageBox.Show("您输入层数不合法!", "信息提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
     else
     {
         StoreHouseProper housePro = GetHousePro((EnumStoreHouse)Enum.Parse(typeof(EnumStoreHouse), this.tscb_StoreHouseName.Text));
         if (int.Parse(this.tscb_Layerth.Text) <= 0 || int.Parse(this.tscb_Layerth.Text) > housePro.Layers)
         {
             this.tscb_Layerth.Text = "1";
             MessageBox.Show("您输入层数超出范围!", "信息提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
         }
     }
 }
예제 #3
0
        private void QueryStorage()
        {
            if (this.tscb_StoreHouseName.SelectedItem != null &&
                this.tscb_StoreHouseName.SelectedItem.ToString() == EnumStoreHouse.A1库房.ToString())
            {
                StoreHouseProper housePro = GetHousePro(EnumStoreHouse.A1库房);
                if (housePro == null)
                {
                    return;
                }

                if (this.tscb_Rowth.SelectedItem != null)
                {
                    this.storageControl1.Columns    = housePro.Columns;
                    this.storageControl1.Layers     = housePro.Layers;
                    this.storageControl1.QueryRowth = int.Parse(this.tscb_Rowth.Text);
                    OnLoadStorageData(EnumStoreHouse.A1库房, int.Parse(this.tscb_Rowth.Text.Trim()));
                }
            }
            else if (this.tscb_StoreHouseName.SelectedItem != null &&
                     this.tscb_StoreHouseName.SelectedItem.ToString() == EnumStoreHouse.B1库房.ToString())
            {
                StoreHouseProper housePro = GetHousePro(EnumStoreHouse.B1库房);

                if (housePro == null)
                {
                    return;
                }

                if (this.tscb_Rowth.SelectedItem != null)
                {
                    this.storageControl1.Columns    = housePro.Columns;
                    this.storageControl1.Layers     = housePro.Layers;
                    this.storageControl1.QueryRowth = int.Parse(this.tscb_Rowth.Text);

                    this.storageControl1.Columns    = housePro.Columns;
                    this.storageControl1.Layers     = housePro.Layers;
                    this.storageControl1.QueryRowth = int.Parse(this.tscb_Rowth.Text);
                    OnLoadStorageData(EnumStoreHouse.B1库房, int.Parse(this.tscb_Rowth.Text.Trim()));
                }
            }
        }
예제 #4
0
        private void tscb_StoreHouse_SelectedIndexChanged(object sender, EventArgs e)
        {
            this.tscb_ProductStatus.Items.Clear();
            if (tscb_StoreHouse.SelectedItem.ToString() == EnumStoreHouse.A1库房.ToString())//不同库房流程不同
            {
                this.tscb_ProductStatus.Items.Add(EnumProductStatus.A1库静置10小时.ToString());
                this.tscb_ProductStatus.Items.Add(EnumProductStatus.A1库老化3天.ToString());
                this.tscb_ProductStatus.Items.Add("所有");
                this.tscb_ProductStatus.SelectedIndex = 2;

                this.tscb_GoodsSiteStatus.Items.Clear();
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.空货位.ToString());
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.货.ToString());
            }
            else if (tscb_StoreHouse.SelectedItem.ToString() == EnumStoreHouse.B1库房.ToString())
            {
                this.tscb_ProductStatus.Items.Add(EnumProductStatus.B1库静置10天.ToString());
                this.tscb_ProductStatus.Items.Add(EnumProductStatus.空料框.ToString());
                this.tscb_ProductStatus.Items.Add("所有");
                this.tscb_ProductStatus.SelectedIndex = 2;

                this.tscb_GoodsSiteStatus.Items.Clear();
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.空货位.ToString());
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.空料框.ToString());
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.货.ToString());
            }
            else
            {
                this.tscb_ProductStatus.Items.Add(EnumProductStatus.A1库静置10小时.ToString());
                this.tscb_ProductStatus.Items.Add(EnumProductStatus.B1库静置10天.ToString());
                this.tscb_ProductStatus.Items.Add(EnumProductStatus.A1库老化3天.ToString());
                this.tscb_ProductStatus.Items.Add(EnumProductStatus.空料框.ToString());
                this.tscb_ProductStatus.Items.Add("所有");
                this.tscb_ProductStatus.SelectedIndex = 4;
            }


            this.tscb_StockRow.Items.Clear();
            StoreHouseProper housePro = GetHousePro((EnumStoreHouse)Enum.Parse(typeof(EnumStoreHouse), this.tscb_StoreHouse.Text));

            for (int i = 0; i < housePro.Rows; i++)
            {
                if (i == 0)
                {
                    this.tscb_StockRow.Items.Add("所有");
                }
                this.tscb_StockRow.Items.Add(i + 1);
            }
            this.tscb_StockRow.Text = "所有";
            this.tscb_StockColumn.Items.Clear();
            for (int i = 0; i < housePro.Columns; i++)
            {
                if (i == 0)
                {
                    this.tscb_StockColumn.Items.Add("所有");
                }
                this.tscb_StockColumn.Items.Add(i + 1);
            }
            this.tscb_StockColumn.Text = "所有";
            this.tscb_StockLayer.Items.Clear();
            for (int i = 0; i < housePro.Layers; i++)
            {
                if (i == 0)
                {
                    this.tscb_StockLayer.Items.Add("所有");
                }
                this.tscb_StockLayer.Items.Add(i + 1);
            }
            this.tscb_StockLayer.Text = "所有";

            this.cb_QueryGSTaskStatus.SelectedIndex = 0;
            this.cb_QueryGSStoreType.SelectedIndex  = 0;
            this.cb_QueryGSTaskType.SelectedIndex   = 0;

            this.cb_OutStorageBatchNum.Text = "所有";
        }
예제 #5
0
        private void cb_StoreHouse_SelectedIndexChanged(object sender, EventArgs e)
        {
            this.tscb_Rowth.Items.Clear();
            if (this.tscb_StoreHouseName.Text == EnumStoreHouse.A1库房.ToString())
            {
                this.tscb_GoodsSiteStatus.Items.Clear();
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.空货位.ToString());
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.货.ToString());
                #region 初始化右键菜单
                this.cms_Storage.Items.Clear();
                ToolStripMenuItem tsmi_FRCK = new ToolStripMenuItem();
                tsmi_FRCK.Text = EnumTaskName.分容出库_A1.ToString();

                ToolStripMenuItem tsmi_DXCK = new ToolStripMenuItem();
                tsmi_DXCK.Text = EnumTaskName.电芯出库_A1.ToString();

                tsmi_FRCK.Click += MenuItemClickEventHandler;
                tsmi_DXCK.Click += MenuItemClickEventHandler;

                this.cms_Storage.Items.Add(tsmi_FRCK);
                this.cms_Storage.Items.Add(tsmi_DXCK);
                #endregion
            }
            else
            {
                this.cms_Storage.Items.Clear();
                ToolStripMenuItem tsmi_KLKCK = new ToolStripMenuItem();
                tsmi_KLKCK.Text = EnumTaskName.空料框出库.ToString();
                ToolStripMenuItem tsmi_JCCK = new ToolStripMenuItem();
                tsmi_JCCK.Text = EnumTaskName.电芯出库_B1.ToString();

                tsmi_KLKCK.Click += MenuItemClickEventHandler;
                tsmi_JCCK.Click  += MenuItemClickEventHandler;

                this.cms_Storage.Items.Add(tsmi_KLKCK);
                this.cms_Storage.Items.Add(tsmi_JCCK);

                this.tscb_GoodsSiteStatus.Items.Clear();
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.空货位.ToString());
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.空料框.ToString());
                this.tscb_GoodsSiteStatus.Items.Add(EnumGSStoreStatus.货.ToString());
            }
            StoreHouseProper housePro = GetHousePro((EnumStoreHouse)Enum.Parse(typeof(EnumStoreHouse), this.tscb_StoreHouseName.Text));
            for (int i = 0; i < housePro.Rows; i++)
            {
                this.tscb_Rowth.Items.Add(i + 1);
            }
            if (housePro.Rows > 0)
            {
                this.tscb_Rowth.SelectedIndex = 0;
            }

            this.tscb_Columnth.Text = "1";
            this.tscb_Columnth.Items.Clear();
            for (int i = 0; i < housePro.Columns; i++)
            {
                this.tscb_Columnth.Items.Add(i + 1);
            }
            this.tscb_Layerth.Text = "1";
            this.tscb_Layerth.Items.Clear();
            for (int i = 0; i < housePro.Layers; i++)
            {
                this.tscb_Layerth.Items.Add(i + 1);
            }
        }