Exemplo n.º 1
0
        private void RightBtn_Click(object sender, EventArgs e)
        {
            RightSetForm right = new RightSetForm("ÿÿÿÿÿÿÿÿÿÿùw");

            if (right.ShowDialog(this) == DialogResult.OK)
            {
                string bitRight = right.BitArrayStr;
                rightStr = OMWorkBench.BitStrToStr(bitRight);
            }
        }
Exemplo n.º 2
0
        private void managerDGV_CellContentClick(object sender, DataGridViewCellEventArgs e)
        {
            int     managerID  = Convert.ToInt32(managerDGV.CurrentRow.Cells["id"].Value);
            DataRow currentRow = _managerTable.Select("id=" + managerID)[0];

            switch (managerDGV.CurrentCell.OwningColumn.Name)
            {
            case "name":
            {
                SelfManagerForm managerForm = new SelfManagerForm(managerID);
                OMWorkBench.CreateForm(managerForm);
                break;
            }

            case "log": break;

            case "rights":
            {
                if (canModifyOthers)
                {
                    string       rights    = currentRow["rights"].ToString();
                    RightSetForm rightForm = new RightSetForm(rights);
                    if (rightForm.ShowDialog() == DialogResult.OK)
                    {
                        currentRow["rights"] = OMWorkBench.BitStrToStr(rightForm.BitArrayStr);
                        int I = OMWorkBench.DataAgent.UpdateManager(_managerTable.GetChanges());
                        _managerTable.AcceptChanges();
                    }
                }
                break;
            }

            case "remind":
            {
                OMWorkBench.CreateForm(new ManagerMindForm(managerID));
                break;
            }

            default: break;
            }
        }