private void DeleteImpl() { var formatter = FormattersLocator.Get(SelectedItem.Guid); FormattersLocator.Remove(formatter); UpdateConverters(); }
private static void FillFieldViewModel(RuleFieldViewModel viewModel, ExcelImportRule.Column model) { if (model == null) { return; } viewModel.UpdateCompatableFormatters(); viewModel.Formatter = FormattersLocator.Get(model.Formatter.Guid); viewModel.Active = model.Active; viewModel.Required = model.Required; viewModel.Index = model.Index; }
protected override ExcelImportRule GetModel(ExcelImportRulePoco entity) { return(new ExcelImportRule() { Name = entity.Name, Description = entity.Description, Identificator = entity.Identificator, CsvMode = entity.UseCsvFile, RowOffset = entity.RowOffset, ColumnOffset = entity.ColumnOffset, WorksheetIndex = entity.WorksheetIndex, Columns = entity.Properties.Select(p => new ExcelImportRule.Column() { Index = p.RowIndex, Name = p.Property.ToString(), Formatter = FormattersLocator.Get(p.FormatterGuid), Active = p.Active, Required = p.Required }) }); }
protected override IFormatter GetModel(FixedFormatterReference entity) { return(FormattersLocator.Get(entity.Guid)); }