Example #1
0
        private void bbi_New_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            if (!MspTool.PermissionControl(AppMain.User.username, SecRightType.Insert, (int)DocumentType.Company, AppMain.CompanyRecId))
            {
                return;
            }

            FrmCompanyEdit _Form = new FrmCompanyEdit();

            _Form._FormOpenType = Infrastructure.FormOpenType.New;
            _Form.Show(0);
        }
Example #2
0
        private void do_edit()
        {
            if (!MspTool.PermissionControl(AppMain.User.username, SecRightType.Update, (int)DocumentType.Company, AppMain.CompanyRecId))
            {
                return;
            }

            CompanyDTO oRow = (CompanyDTO)gcv_company.GetFocusedRow();

            if (oRow != null)
            {
                FrmCompanyEdit _Form = new FrmCompanyEdit();
                _Form._FormOpenType = Infrastructure.FormOpenType.Edit;
                _Form.Show(oRow.RecId);
            }
        }