Esempio n. 1
0
        public void EditEntity(AvgWorkingDaysInWeek amount)
        {
            AvgWorkingDaysInWeek am = amount;

            if (amount == null && FocusedEntity == null)
            {
                return;
            }

            if (am == null)
            {
                am = FocusedEntity;
            }
            if (am == null)
            {
                return;            // paranoik check
            }
            using (AvgWorkingDaysInWeekForm form = new AvgWorkingDaysInWeekForm())
            {
                form.Amount = am;

                if (form.ShowDialog() == DialogResult.OK)
                {
                    ListOfAvgWDInWeek.ResetItemById(am.ID);
                }
            }
        }
Esempio n. 2
0
        void NewEntity()
        {
            AvgWorkingDaysInWeek amount = ClientEnvironment.AvgWorkingDaysInWeekService.CreateEntity();

            amount.CountryID = EntityCountry.ID;
            using (AvgWorkingDaysInWeekForm form = new AvgWorkingDaysInWeekForm())
            {
                form.Amount = amount;

                if (form.ShowDialog() == DialogResult.OK)
                {
                    ListOfAvgWDInWeek.Add(form.Amount);
                    UpdateBarButtons();
                }
            }
        }
Esempio n. 3
0
        public void EditEntity(AvgWorkingDaysInWeek amount)
        {
            AvgWorkingDaysInWeek am = amount;
            if (amount == null && FocusedEntity == null) return;

            if (am == null) am = FocusedEntity;
            if (am == null) return;// paranoik check

            using (AvgWorkingDaysInWeekForm form = new AvgWorkingDaysInWeekForm())
            {
                form.Amount = am;

                if (form.ShowDialog() == DialogResult.OK)
                {
                    ListOfAvgWDInWeek.ResetItemById(am.ID);
                }
            }
        }
Esempio n. 4
0
         void NewEntity()
        {
            AvgWorkingDaysInWeek amount = ClientEnvironment.AvgWorkingDaysInWeekService.CreateEntity();

            amount.CountryID = EntityCountry.ID;
            using (AvgWorkingDaysInWeekForm form = new AvgWorkingDaysInWeekForm())
            {
                form.Amount = amount;

                if (form.ShowDialog() == DialogResult.OK)
                {
                        ListOfAvgWDInWeek.Add(form.Amount);
                        UpdateBarButtons();   
                }
            }
        }