Ejemplo n.º 1
0
 protected override void ShowForm()
 {
     this.FillCombo();
     HPS.BLL.GoodBLL.BLLGood_TFactory GoodFactory = new HPS.BLL.GoodBLL.BLLGood_TFactory();
     HPS.BLL.GoodBLL.BLLGood_T        GoodEntity  = GoodFactory.GetBy((HPS.BLL.GoodBLL.BLLGood_TKeys)Key);
     if (GoodEntity == null)
     {
         throw new HPS.Exceptions.GoodNotFound();
     }
     GoodCode_nvcTextBox.Text   = Hepsa.Core.Common.PersentationController.GetEntityValue(GoodEntity.GoodCode_nvc, TypeCode.String).ToString();
     Good_nvcTextBox.Text       = Hepsa.Core.Common.PersentationController.GetEntityValue(GoodEntity.Good_nvc, TypeCode.String).ToString();
     Avtive_bitCheckBox.Checked = (Boolean)Hepsa.Core.Common.PersentationController.GetEntityValue(GoodEntity.Avtive_bit, TypeCode.Boolean);
 }
Ejemplo n.º 2
0
        private void SearchButton_Click(object sender, EventArgs e)
        {
            if (GoodGridView.CurrentRow != null)
            {
                HPS.BLL.GoodBLL.BLLGood_TFactory GoodFactory = new HPS.BLL.GoodBLL.BLLGood_TFactory();
                HPS.BLL.GoodBLL.BLLGood_TKeys    GoodKey     = new HPS.BLL.GoodBLL.BLLGood_TKeys();
                GoodKey.GoodID_int = (Int32)GoodGridView.CurrentRow.Cells[colGoodID_int.Name].Value;
                GoodEntity         = GoodFactory.GetBy(GoodKey);

                if (string.IsNullOrEmpty(Hepsa.Core.Common.PersentationController.GetEntityValue(GoodGridView.CurrentRow.Cells[colGoodID_int.Name].Value, TypeCode.String).ToString()) == false)
                {
                    GoodEntity.Good_nvc     = Hepsa.Core.Common.PersentationController.GetEntityValue(GoodGridView.CurrentRow.Cells[colGood_nvc.Name].Value, TypeCode.String).ToString();
                    GoodEntity.GoodCode_nvc = Hepsa.Core.Common.PersentationController.GetEntityValue(GoodGridView.CurrentRow.Cells[colGoodCode_nvc.Name].Value, TypeCode.String).ToString();
                }
            }
            this.Close();
        }