示例#1
0
        /// <summary>
        /// 新增
        /// </summary>
        private void DoCreateUnit()
        {
            FrmVehicleEdit frmEdit = new FrmVehicleEdit();

            frmEdit.DataSourceChanged += OnCreateChanage;
            frmEdit.ShowDialog();
        }
示例#2
0
        /// <summary>
        /// 编辑
        /// </summary>
        private void ShowEditUnit()
        {
            VehicleEntity editEntity = SelectedUnitRow;

            if (editEntity == null)
            {
                MsgBox.Warn("没有要修改的数据。");
                return;
            }

            FrmVehicleEdit frmEdit = new FrmVehicleEdit(editEntity);

            frmEdit.DataSourceChanged += OnEditChanage;
            frmEdit.ShowDialog();
        }