Ejemplo n.º 1
0
        protected override int Add( )
        {
            Operation.ProgramControlEdit form = new  Operation.ProgramControlEdit("新增", _model, "add");
            form.StartPosition = FormStartPosition.CenterScreen;
            DialogResult result = form.ShowDialog( );

            if (result == System.Windows.Forms.DialogResult.OK)
            {
                Query( );
            }

            return(0);
        }
Ejemplo n.º 2
0
        protected override int Edit( )
        {
            if (_model.idx < 1)
            {
                XtraMessageBox.Show("请选择需要编辑的内容");
                return(0);
            }

            Operation.ProgramControlEdit form = new Operation.ProgramControlEdit("编辑", _model, "edit");
            form.StartPosition = FormStartPosition.CenterScreen;
            DialogResult result = form.ShowDialog( );

            if (result == System.Windows.Forms.DialogResult.OK)
            {
                Query( );
            }

            return(0);
        }