コード例 #1
0
        private void Add(EventModel model)
        {
            var window = new AddEditEventView {
                ViewModel = this
            };

            window.Render(model);
            window.ShowDialog();
        }
コード例 #2
0
        public void Edit(int id)
        {
            var model  = EventService.Edit(id);
            var window = new AddEditEventView {
                ViewModel = this
            };

            window.Render(model);
            window.ShowDialog();
        }
コード例 #3
0
        public static void Show(Event update)
        {
            var vm = new AddEditEventViewModel(update);
            var v  = new AddEditEventView();

            vm.CloseWindow = v.Close;
            v.DataContext  = vm;

            v.ShowDialog();
        }