Esempio n. 1
0
        private void Add()
        {
            AddUserForm frmUser = new AddUserForm(GetRole());

            frmUser.ShowDialog();
            RefreshUserList();
        }
        public void AddUser()
        {
            AddUserForm frmUser = new AddUserForm(currentRole);

            frmUser.ShowDialog();
            LoadUser();
        }
        public void ModifyUser()
        {
            if (nTreeListView1.SelectedItems.Count == 0)
            {
                MessageBox.Show("请选择要修改行!");
                return;
            }
            AddUserForm frmUser = new AddUserForm(nTreeListView1.SelectedItems[0].Tag as User, currentRole);

            frmUser.ShowDialog();
            LoadUser();
        }
Esempio n. 4
0
        private void fpSpread1_CellDoubleClick(object sender, FarPoint.Win.Spread.CellClickEventArgs e)
        {
            if (e.Column != -1 && e.Row != -1)
            {
                User user = new Neusoft.HISFC.BizLogic.Privilege.UserLogic().Get(fpSpread1_Sheet1.Cells[fpSpread1_Sheet1.ActiveRowIndex, 0].Text.Trim());
                if (user == null)
                {
                    return;
                }

                AddUserForm frmUser = new AddUserForm(user, GetRole());
                frmUser.ShowDialog();
                RefreshUserList();
            }
        }