Skip to content

Commit

Permalink
archivemanagement plugin update
Browse files Browse the repository at this point in the history
  • Loading branch information
rsehr committed Nov 5, 2024
1 parent 8d4e3a8 commit d2e2962
Showing 1 changed file with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public EadManager(ImportSet importSet, String processName, String CatalogIDDigit
} else {
// prepare ArchivePlugin
this.archivePlugin.getPossibleDatabases();
this.archivePlugin.setSelectedDatabase(importSet.getEadFile());
this.archivePlugin.setDatabaseName(importSet.getEadFile());
this.archivePlugin.loadSelectedDatabase();
this.dbStatusOk = checkDB();
}
Expand All @@ -67,8 +67,8 @@ public EadManager(ImportSet importSet, String processName, String CatalogIDDigit

private boolean checkDB() {
List<String> possibleDBs = this.archivePlugin.getPossibleDatabases();
return !possibleDBs.isEmpty() && StringUtils.isNotBlank(this.archivePlugin.getSelectedDatabase())
&& this.archivePlugin.getSelectedDatabase().equals(this.importSet.getEadFile());
return !possibleDBs.isEmpty() && StringUtils.isNotBlank(this.archivePlugin.getDatabaseName())
&& this.archivePlugin.getDatabaseName().equals(this.importSet.getEadFile());
}

private IEadEntry findNode(String eadNode) throws NullPointerException {
Expand Down Expand Up @@ -103,12 +103,11 @@ public String addDocumentNodeWithMetadata(Row row, List<MappingField> mappingFie
addMetadata(entry, row, mappingFields);
entry.setGoobiProcessTitle(entry.getId());

this.archivePlugin.createEadDocument();
this.archivePlugin.updateSingleNode();
return entry.getId();
}

public void saveArchiveAndLeave() {
this.archivePlugin.createEadDocument();
this.archivePlugin.saveArchiveAndLeave();
}

Expand Down

0 comments on commit d2e2962

Please sign in to comment.