Example #1
0
        private void MenuItem_AddGroup_Click(object sender, RoutedEventArgs e)
        {
            var win = new AddGroup();

            win.OnAddComplete += (券商 o) =>
            {
                //this.dgMain.ItemsSource = Adapter.GroupsDict.Values.ToList();
            };
            var isAdd = win.ShowDialog();

            if (isAdd == true)
            {
                this.dgState.ItemsSource = Adapter.GroupLogonList;
                //this.dgMain.ItemsSource = Adapter.GroupsDict.Values.ToList();
            }
        }
Example #2
0
        private void Button_Edit_Click(object sender, RoutedEventArgs e)
        {
            if ((sender as Button).DataContext is 券商)
            {
                var o = (sender as Button).DataContext as 券商;
                if (o.IsIMSAccount)
                {
                    var win = new AddImsGroup(o);
                    win.ShowDialog();
                }
                else
                {
                    var win = new AddGroup();
                    win.Init(o);
                    win.ShowDialog();
                }

                this.dgMain.ItemsSource = Adapter.GroupsDict.Values.ToList();
            }
        }