Exemple #1
0
        internal override async Task AddRecord()
        {
            try
            {
                _options   = new EditingOptionForm();
                _presenter = new OptionPresenter(_options);
                _options.ShowDialog();

                await Update();
            }
            catch (Exception ex)
            {
                ShowError(ex.Message);
            }
        }
Exemple #2
0
        internal override async Task EditRecord()
        {
            try
            {
                if (ExistsRecord)
                {
                    _options   = new EditingOptionForm();
                    _presenter = new OptionPresenter(_options, Item.ID);
                    _options.ShowDialog();

                    await Update();
                }
            }
            catch (Exception ex)
            {
                ShowError(ex.Message);
            }
        }