public ApartmentPersonBenefitForm(ApartmentResident apartmentResident, PersonBenefitDocument personBenefitDocument)
     : this()
 {
     this.apr = apartmentResident;
     this.pbd = personBenefitDocument;
     this.btnSave.set_Text("Изменить");
 }
 public void Fill(ApartmentResident apartmentResident)
 {
     if (this.m_ApartmentResident.Id != apartmentResident.Id)
     {
         this.m_ApartmentResident = apartmentResident;
         this.UpdateBindingSourcePersonBenefitDocuments();
     }
 }
 public void Fill(ApartmentResident apartmentResident)
 {
     if (this.m_ApartmentResident.Id != apartmentResident.Id)
     {
         this.m_ApartmentResident = apartmentResident;
         this.UpdateBindingSourceResidentBenefitProperty();
     }
 }
 public void Fill(ApartmentResident apartmentResident)
 {
     if (this.m_ApartmentResident.Id != apartmentResident.Id)
     {
         this.m_ApartmentResident = apartmentResident;
         this.UpdateBindingSourceResidentVacations();
     }
 }
Example #5
0
 public ApartmentResidentForm()
 {
     this.apr = AIS.SN.Model.DomainObjects.ApartmentResident.Null;
     this.ap = Apartment.Null;
     this.m_Save = true;
     this.InitializeComponent();
     this.set_Font(Manager.WindowFont);
 }
 public ApartmentPersonBenefitView()
 {
     this.m_ApartmentResident = ApartmentResident.Null;
     this.m_viewPersonBenefitDocument = true;
     this.InitializeComponent();
     if (!Manager.DesignMode)
     {
         this.tsPersonBenefits.set_Enabled(User.IsMemberOf(RightsEnum.АРМБухгалтерЛСПроживающиеПолныйДоступ));
     }
 }
 public ApartmentPersonBenefitForm(ApartmentResident apartmentResident)
     : this()
 {
     this.apr = apartmentResident;
     this.pbd = new PersonBenefitDocument();
     this.pbd.Id = -1L;
     this.pbd.PersonId = apartmentResident.PersonId;
     this.pbd.PersonName = apartmentResident.PersonName;
     this.personBenefitDocumentIsNew = true;
     this.btnSave.set_Text("Добавить");
 }
 public ApartmentResidentBenefitDebtsView()
 {
     this.m_ApartmentResident = ApartmentResident.Null;
     this.dtp = new System.Windows.Forms.DateTimePicker();
     this.InitializeComponent();
     this.dtp.set_Format(System.Windows.Forms.DateTimePickerFormat.Short);
     this.dtp.set_Width(100);
     this.dtp.add_CloseUp(new System.EventHandler(this.dtp_CloseUp));
     this.tsBenefitDebts.Items.Add(new System.Windows.Forms.ToolStripControlHost(this.dtp));
     if (!Manager.DesignMode)
     {
         this.currentCalcPeriod = CalcPeriod.GetCurrent().FromDate;
         this.dtp.set_Value(CalcPeriod.GetCurrent().FromDate);
     }
 }
 public PersonBenefitOutAddChangeForm(ApartmentResident ar)
 {
     this.InitializeComponent();
     this.bOk.set_Text("Добавить");
     this.set_Text("Добавление");
     this.m_PersonBenefitOut = new PersonBenefitOut();
     this.m_PersonBenefitOut.PersonId = ar.PersonId;
     this.m_PersonBenefitOut.PersonName = ar.PersonName;
     this.cbIsDelete.set_Enabled(false);
     this.dbCreated.Value = System.DateTime.Today;
     this.dbCreated.set_Enabled(false);
     this.bsBenefits.set_DataSource(Benefit.FindBy(ar.PersonId));
     this.tbBenefitName.set_Text(((Benefit) this.bsBenefits.get_Current()).ShortName);
     this.tbBenefitName.set_Enabled(false);
     this.cbBenefitCode.set_Visible(true);
     this.dbPeriod.set_Enabled(true);
     this.dbByPeriod.set_Enabled(true);
     this.bsAccounts.set_DataSource(Account.FindActiveByApartmentId(ar.ApartmentId));
     this.cbAccount.set_Visible(true);
 }
 public ApartmentResidentBenefitDebtsForm(ApartmentResident apartmentResident, BenefitDebt benefitDebt)
     : this()
 {
     this.m_ApartmentResident = apartmentResident;
     this.m_ApartmentResidentBenefitDebt = benefitDebt;
 }
Example #11
0
 public ApartmentResidentForm(Apartment apartment, AIS.SN.Model.DomainObjects.ApartmentResident apartmentResident, bool save)
     : this(apartment, save)
 {
     this.apr = apartmentResident;
 }
Example #12
0
 public ApartmentResidentForm(Apartment apartment, AIS.SN.Model.DomainObjects.ApartmentResident apartmentResident)
     : this()
 {
     this.ap = apartment;
     this.apr = apartmentResident;
 }
 public ApartmentResidentVacationView()
 {
     this.m_ApartmentResident = ApartmentResident.Null;
     this.m_viewVacation = true;
     this.InitializeComponent();
 }
Example #14
0
 public static ObjectList<PersonBenefitOut> FindByPerson(ApartmentResident apartmentResident)
 {
     return Mappers.PersonBenefitOutMapper.FindByPerson(apartmentResident);
 }
 public ApartmentResidentVacationView(ApartmentResident apartmentResident)
     : this()
 {
     this.m_ApartmentResident = apartmentResident;
 }
 public static ObjectList<ApartmentResidentBenefit> GetApartmentResidentBenefitsByResident(ApartmentResident resident)
 {
     return Mappers.ApartmentResidentBenefitMapper.GetApartmentResidentBenefitsByResident(resident);
 }
 public ApartmentResidentVacationForm(ApartmentResident apartmentResident, ApartmentResidentVacation apartmentResidentVacation)
     : this()
 {
     this.apr = apartmentResident;
     this.aprv = apartmentResidentVacation;
 }
 public ApartmentResidentChangeForm(ApartmentResident apartmentResident)
     : this()
 {
     this.apr = apartmentResident;
 }
 public ApartmentResidentChangeForm()
 {
     this.apr = ApartmentResident.Null;
     this.InitializeComponent();
     this.set_Font(Manager.WindowFont);
 }
 public ApartmentResidentBenefitDebtsView(ApartmentResident apartmentResident)
     : this()
 {
     this.m_ApartmentResident = apartmentResident;
 }
 public static ObjectList<ApartmentResidentBenefit> FindByApartmentResident(ApartmentResident resident, bool toDateIsNull)
 {
     return Mappers.ApartmentResidentBenefitMapper.FindByApartmentResident(resident, toDateIsNull);
 }
 public ApartmentPersonBenefitView(ApartmentResident apartmentResident)
     : this()
 {
     this.m_ApartmentResident = apartmentResident;
 }
 public ApartmentResidentBenefitPropertiesView()
 {
     this.m_ApartmentResident = ApartmentResident.Null;
     this.m_viewBenefitProperties = true;
     this.InitializeComponent();
 }
 private void tsbAddApartmentOwners_Click(object sender, System.EventArgs e)
 {
     if (this.testValidation())
     {
         AIS.SN.Model.DomainObjects.Person selectedPerson = this.selectPerson.SelectedPerson;
         ApartmentResident resident = new ApartmentResident {
             ApartmentId = this.m_Apartment.Id,
             PersonId = selectedPerson.Id,
             TypeResidents = this.selectTypeResident.SelectedFasetItem.Id,
             Relative = this.seletcRelative.SelectedFasetItem.Id,
             FromDate = this.dbxBegin.Value,
             Comment = this.tbComment.get_Text(),
             PersonName = this.selectPerson.SelectedPerson.FullName,
             RelativeName = this.seletcRelative.SelectedFasetItem.Name,
             TypeResidentName = this.selectTypeResident.SelectedFasetItem.Name
         };
         this.base_colResident.Add(resident);
         this.UpdateBindingSourceApartmentResidents();
         this.selectPerson.SelectedPerson = AIS.SN.Model.DomainObjects.Person.Null;
         this.tsbAddApartmentResident.set_Enabled(false);
     }
 }
 public ApartmentResidentBenefitForm(ApartmentResident ap)
     : this()
 {
     this.ap = ap;
 }
 public ApartmentResidentBenefitPropertiesForm(ApartmentResident apartmentResident, ApartmentResidentBenefitProperty apartmentResidentBenefitProperty)
     : this()
 {
     this.m_ApartmentResident = apartmentResident;
     this.m_ApartmentResidentBenefitProperty = (apartmentResidentBenefitProperty != null) ? apartmentResidentBenefitProperty : null;
 }
 public ApartmentResidentBenefitPropertiesView(ApartmentResident apartmentResident)
     : this()
 {
     this.m_ApartmentResident = apartmentResident;
 }
Example #28
0
 private void btnSave_Click(object sender, System.EventArgs e)
 {
     if (((this.selectTypeResident.SelectedFasetItem == FasetItem.Null) || this.dbxBegin.IsNull) || (this.selectPerson.SelectedPerson == null))
     {
         new BalloonWindow("Не все поля заполнены").Show(this.btnSave);
     }
     else
     {
         if (this.apr == AIS.SN.Model.DomainObjects.ApartmentResident.Null)
         {
             Person selectedPerson = this.selectPerson.SelectedPerson;
             this.apr = new AIS.SN.Model.DomainObjects.ApartmentResident();
             this.apr.ApartmentId = this.ap.Id;
             this.apr.PersonId = selectedPerson.Id;
         }
         this.apr.TypeResidents = this.selectTypeResident.SelectedFasetItem.Id;
         this.apr.Relative = this.seletcRelative.SelectedFasetItem.Id;
         this.apr.FromDate = this.dbxBegin.Value;
         this.apr.ToDate = this.dbxEnd.IsNull ? System.DateTime.MinValue : this.dbxEnd.Value;
         this.apr.Comment = this.tbComment.get_Text();
         if (this.m_Save)
         {
             this.apr.SaveChanges();
         }
         base.set_DialogResult(System.Windows.Forms.DialogResult.OK);
         base.Close();
     }
 }
Example #29
0
 public AddBenefitResident(ApartmentResident apartment)
     : this()
 {
     this.apr = apartment;
 }
 private void dg_spun_reg_CellContentClick(object sender, System.Windows.Forms.DataGridViewCellEventArgs e)
 {
     if ((e.get_RowIndex() != -1) && (this.dg_spun_reg.Columns.get_Item(e.get_ColumnIndex()) == this.spun_fl_reg_copy_Column))
     {
         SidPerson sidPerson = (SidPerson) this.bsSidPerson.get_Current();
         ResidentPack residentPack = (ResidentPack) this.bsSnPerson.get_Current();
         if ((sidPerson == null) || (residentPack == null))
         {
             AIS.SN.UI.Messages.ShowWarning("Необходимо выделить связанного человека, которому копировать регистрацию");
         }
         else if (((EqualityPerson.FindBySidPersonAndResidentPack(this.equalityPersons, sidPerson, residentPack) == null) && (sidPerson.equalityed > 0)) && (residentPack.equalityed > 0))
         {
             AIS.SN.UI.Messages.ShowWarning("Регистрацию можно перенести только на сопоставленного человека");
         }
         else
         {
             SidPersonRegistration registration = (SidPersonRegistration) this.bsSidRegistration.get_Current();
             ApartmentResident resident = new ApartmentResident {
                 ApartmentId = this.apartment.Id,
                 FromDate = registration.FromDate,
                 ToDate = registration.ToDate,
                 Relative = registration.Relative,
                 TypeResidents = registration.TypeResidents
             };
             this.bsSnApartmentResident.set_DataSource(null);
             residentPack.apartmentResidents.Add(resident);
             this.bsSnApartmentResident.set_DataSource(residentPack.apartmentResidents);
         }
     }
 }