public AddDataEntityCommand() { ExcuteHandler = () => { using (DataEntityEditView view = new DataEntityEditView()) { view.ShowDialog(); } }; }
public EditDataEntityCommand() { ExcuteHandler = () => { DataEntityDev entity = GetArgument(); if (entity == null) { return; } if (entity.Sys) { MessageBox.Show(CommonLanguage.Current.SystemItemNoEditAllowed, CommonLanguage.Current.MessageCaption_Notice, MessageBoxButtons.OK, MessageBoxIcon.Information); return; } using (DataEntityEditView view = new DataEntityEditView()) { view.DataEntity = entity; view.ShowDialog(); } }; }