Ejemplo n.º 1
0
 private void tsbCounterChange_Click(object sender, System.EventArgs e)
 {
     if ((this.m_House != AIS.SN.Model.DomainObjects.House.Null) && ((this.bsHouseAreas.get_Current() != null) && (this.bsHouseAreas.get_Current() != HouseArea.Null)))
     {
         HistoryHouseAreasAddChangeForm form = new HistoryHouseAreasAddChangeForm(this.bsHouseAreas.get_Current() as HouseArea, true);
         form.set_Text("Изменение истории площади дома");
         form.btnAddChange.set_Text("Изменить");
         if (form.ShowDialog(this) == System.Windows.Forms.DialogResult.OK)
         {
             this.bsHouseAreas.set_DataSource(HouseArea.FindAllByHouseId(this.m_House.Id));
         }
     }
 }
Ejemplo n.º 2
0
 private void tsbCounterAdd_Click(object sender, System.EventArgs e)
 {
     HistoryHouseAreasAddChangeForm form = new HistoryHouseAreasAddChangeForm(this.m_House.Id);
     form.set_Text("Добавление записи в историю площади дома");
     form.ShowDialog(this);
     if (form.DialogResult == System.Windows.Forms.DialogResult.OK)
     {
         form.HouseArea.SaveChanges();
         this.bsHouseAreas.Add(form.HouseArea);
     }
 }