Esempio n. 1
0
        public ManageStockClearControls(ManageItem manageStock)
        {
            foreach (Control item in manageStock.groupBox1.Controls)
            {
                if (item is TextBox)
                {
                    ((TextBox)item).Text = string.Empty;
                }
            }

            manageStock.pictureBoxItem.Image = Properties.Resources.DefaultItem;
        }
 internal static bool CheckIfBarCodeIsUnique(ManageItem manageItem)
 {
     _manageItem = manageItem;
     if (CreateDataReader().HasRows)
     {
         MessageBox.Show("BarCode is already taken", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
         return(true);
     }
     else
     {
         return(false);
     }
 }
Esempio n. 3
0
 public AddProduct(ManageItem manageStock)
 {
     ManageStock = manageStock;
     ExecuteCommand(CreateCommand());
     System.Windows.Forms.MessageBox.Show("Item Saved Succesfully", "Message", System.Windows.Forms.MessageBoxButtons.OK, System.Windows.Forms.MessageBoxIcon.Information);
 }
Esempio n. 4
0
 public AddToOrderDetails(ManageItem manageItem, int index)
 {
     this.manageItem = manageItem;
     this.index      = index;
     ExecuteCommand(CreateCommand());
 }