public HouseApartmentCounterDistributionSharesManualCalculationForm(ApartmentCounterShare apartmentCounterShare) : this() { if ((apartmentCounterShare != ApartmentCounterShare.Null) && (apartmentCounterShare != null)) { this.m_apartmentCounterShare = apartmentCounterShare; this.bsApartmentCounterHistoryShares.set_DataSource(ApartmentCounterShare.FindByApartmentCounterId(this.m_apartmentCounterShare.ApartmentCounterId)); this.set_Text(string.Concat((string[]) new string[] { "Ручной расчет: ", this.m_apartmentCounterShare.AddressName, ", ", this.m_apartmentCounterShare.CounterTypeName, ", ", this.m_apartmentCounterShare.CounterName })); } }
public HouseApartmentCounterDistributionSharesAddChangeForm(long apartmentCounterId) : this() { if (apartmentCounterId != 0L) { this.m_ApartmentCounterId = apartmentCounterId; this.btnAddChangeShare.set_Text("Добавить"); this.m_ApartmentCounterShare = ApartmentCounterShare.Null; } }
public HouseApartmentCounterDistributionSharesAddChangeForm(ApartmentCounterShare apartmentCounterShare) : this() { if ((apartmentCounterShare != ApartmentCounterShare.Null) && (apartmentCounterShare != null)) { this.m_ApartmentCounterShare = apartmentCounterShare; this.nudShare.set_Value(this.m_ApartmentCounterShare.Share); this.dbFromDate.Value = this.m_ApartmentCounterShare.FromDate; this.btnAddChangeShare.set_Text("Изменить"); } }
private void btnAddChangeShare_Click(object sender, System.EventArgs e) { if (this.dbFromDate.IsNull) { new BalloonWindow("Не введене дата установки доли оплаты").Show(this.btnAddChangeShare); } else { if ((this.m_ApartmentCounterShare == null) || (this.m_ApartmentCounterShare == ApartmentCounterShare.Null)) { this.m_ApartmentCounterShare = new ApartmentCounterShare(); this.m_ApartmentCounterShare.ApartmentCounterId = this.m_ApartmentCounterId; } if (!this.dbFromDate.IsNull) { this.m_ApartmentCounterShare.FromDate = this.dbFromDate.Value; } this.m_ApartmentCounterShare.Share = this.nudShare.Value; this.m_ApartmentCounterShare.SaveChanges(); base.set_DialogResult(System.Windows.Forms.DialogResult.OK); base.Close(); } }
private void tsbManualCalculation_Click(object sender, System.EventArgs e) { if ((this.m_houseCounter != HouseCounter.Null) && (this.m_houseCounter != null)) { this.m_apartmentCounterShare = this.bsApartmentCounterShares.get_Current() as ApartmentCounterShare; if ((this.m_apartmentCounterShare != null) && (this.m_apartmentCounterShare != ApartmentCounterShare.Null)) { HouseApartmentCounterDistributionSharesManualCalculationForm form = new HouseApartmentCounterDistributionSharesManualCalculationForm(this.m_apartmentCounterShare); form.ShowDialog(this); if (form.DialogResult == System.Windows.Forms.DialogResult.OK) { this.UpdateBindingSourceApartmentCountersShareDates(); this.IncorrectlySumShare(); } } } }
public HouseApartmentCounterDistributionSharesManualCalculationForm() { this.m_apartmentCounterShare = ApartmentCounterShare.Null; this.InitializeComponent(); this.set_Font(Manager.WindowFont); }
private void tsbDeleteShare_Click(object sender, System.EventArgs e) { if ((this.bsApartmentCounterHistoryShares.get_Current() != null) && (Messages.QuestionYesNo(this, "Вы действительно хотите удалить?") != System.Windows.Forms.DialogResult.No)) { this.m_apartmentCounterShare = this.bsApartmentCounterHistoryShares.get_Current() as ApartmentCounterShare; if ((this.m_apartmentCounterShare != null) && (this.m_apartmentCounterShare != ApartmentCounterShare.Null)) { this.m_apartmentCounterShare.Delete(); this.bsApartmentCounterHistoryShares.set_DataSource(ApartmentCounterShare.FindByApartmentCounterId(this.m_apartmentCounterShare.ApartmentCounterId)); this.update = true; } } }
private void tsbChangeShare_Click(object sender, System.EventArgs e) { this.m_apartmentCounterShare = this.bsApartmentCounterHistoryShares.get_Current() as ApartmentCounterShare; if ((this.m_apartmentCounterShare != null) && (this.m_apartmentCounterShare != ApartmentCounterShare.Null)) { HouseApartmentCounterDistributionSharesAddChangeForm form = new HouseApartmentCounterDistributionSharesAddChangeForm(this.m_apartmentCounterShare); form.set_Text("Изменение доли оплаты"); if (form.ShowDialog(this) == System.Windows.Forms.DialogResult.OK) { this.bsApartmentCounterHistoryShares.set_DataSource(ApartmentCounterShare.FindByApartmentCounterId(this.m_apartmentCounterShare.ApartmentCounterId)); this.update = true; } } }
public HouseApartmentCounterDistributionSharesAddChangeForm() { this.m_ApartmentCounterShare = ApartmentCounterShare.Null; this.InitializeComponent(); this.set_Font(Manager.WindowFont); }