Skip to content

Commit

Permalink
Version 1.3
Browse files Browse the repository at this point in the history
Added support for importing citation data for Resources, Digital Objects, and Accessions. Added ability to import specific instance information for Archival Objects. The fields can be customized in the DataMapping.lua file.
  • Loading branch information
dylan-isaac authored Jan 19, 2018
1 parent f746a47 commit 21105e8
Show file tree
Hide file tree
Showing 10 changed files with 1,709 additions and 0 deletions.
852 changes: 852 additions & 0 deletions Aeon-ArchivesSpace-Addon/Aeon-ArchivesSpace.lua

Large diffs are not rendered by default.

35 changes: 35 additions & 0 deletions Aeon-ArchivesSpace-Addon/Config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<?xml version="1.0" encoding="utf-8"?>
<Configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Name>ArchivesSpace Interface</Name>
<Author>Atlas Systems, Inc.</Author>
<Version>1.3.0</Version>
<Active>True</Active>
<Type>Addon</Type>
<Description>This addon performs searches in ArchivesSpace using the staff interface. This addon supports ArchivesSpace versions v2.0.0 and later.</Description>
<Forms>
<Form>FormRequest</Form>
</Forms>
<Settings>
<Setting name="AutoSearch" value="true" type="boolean">
<Description>Defines whether the search should be automatically performed when the form opens.</Description>
</Setting>
<Setting name="ArchivesSpaceStaffURL" value="" type="string">
<Description>The URL of the ArchivesSpace Frontend Staff UI. An example would be http://127.0.0.1:8080/</Description>
</Setting>
<Setting name="ArchivesSpaceBackendURL" value="" type="string">
<Description>The URL of the ArchviesSpace Backend API service. An example would be http://127.0.0.1:8089/</Description>
</Setting>
<Setting name="AS_Username" value="" type="string">
<Description>The staff username to use when logging in to the web interface. It is recommended to use an account that has read-only permissions on the relevant repositories.</Description>
</Setting>
<Setting name="AS_Password" value="" type="string">
<Description>The staff password to use when logging in to the web interface. It is recommended to use an account that has read-only permissions on the relevant repositories.</Description>
</Setting>
<Setting name="AutoSearchPriority" value="Title, Author, CallNumber" type="string">
<Description>A comma-separated list of searches to be performed in order.</Description>
</Setting>
</Settings>
<Files>
<File>Aeon-ArchivesSpace.lua</File>
</Files>
</Configuration>
123 changes: 123 additions & 0 deletions Aeon-ArchivesSpace-Addon/DataMapping.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
HostAppInfo = {}
ASpaceSearchCode = {};
HostAppInfo.Icons = {};
HostAppInfo.SearchMapping = {};
HostAppInfo.PageUri = {};

-- Icons
HostAppInfo.Icons["Search"] = "srch_32x32";
HostAppInfo.Icons["Home"] = "home_32x32";
HostAppInfo.Icons["Web"] = "web_32x32";
HostAppInfo.Icons["Import"] = "impt_32x32";

-- ArchivesSpace Search Types
ASpaceSearchCode["Creator"] = "creators"
ASpaceSearchCode["Identifier"] = "identifier"
ASpaceSearchCode["Keyword"] = "keyword"
ASpaceSearchCode["Notes"] = "notes"
ASpaceSearchCode["Subject"] = "subjects"
ASpaceSearchCode["Title"] = "title"

--Search Mapping
HostAppInfo.SearchMapping["Title"] =
{
AeonSourceField = "ItemTitle",
ASpaceSearchType = ASpaceSearchCode["Title"]
}

HostAppInfo.SearchMapping["Author"] =
{
AeonSourceField = "ItemAuthor",
ASpaceSearchType = ASpaceSearchCode["Creator"]
}

HostAppInfo.SearchMapping["CallNumber"] =
{
AeonSourceField = "CallNumber",
ASpaceSearchType = ASpaceSearchCode["Identifier"]
}

-- Object Instance Mapping
HostAppInfo.InstanceDataImport = {};

HostAppInfo.InstanceDataImport["Title"] =
{
AeonField = "ItemTitle", AspaceData = "ResourceTitle", FieldLength = 255, ItemGridColumn = "Title"
}

HostAppInfo.InstanceDataImport["CallNumber"] =
{
AeonField = "CallNumber", AspaceData = "EadId", FieldLength = 255, ItemGridColumn = "CallNumber"
}

HostAppInfo.InstanceDataImport["SubTitle"] =
{
AeonField = "ItemSubtitle", AspaceData = "ArchivalObjectTitle", FieldLength = 255, ItemGridColumn = "SubTitle"
}

HostAppInfo.InstanceDataImport["Author"] =
{
AeonField = "ItemAuthor", AspaceData = "Creators", FieldLength = 255, ItemGridColumn = "Author"
}

HostAppInfo.InstanceDataImport["Volume"] =
{
AeonField = "ItemVolume", AspaceData = "ArchivalObjectContainer", FieldLength = 255, ItemGridColumn = "Volume"
}


-- Resource Citation Import Mapping
HostAppInfo.CitationDataImport = {}

HostAppInfo.CitationDataImport["Resource"] = {
{
AeonField = "ItemTitle", AspaceData = "Title", FieldLength = 255
},
{
AeonField = "ItemAuthor", AspaceData = "Creators", FieldLength = 255
},
{
AeonField = "ItemSubtitle", AspaceData = "FindingAidTitle", FieldLength = 255
},
{
AeonField = "ItemDate", AspaceData = "DateExpression", FieldLength = 50
}
}

HostAppInfo.CitationDataImport["Accession"] = {
{
AeonField = "ItemTitle", AspaceData = "Title", FieldLength = 255
},
{
AeonField = "ItemAuthor", AspaceData = "CreatedBy", FieldLength = 255
},
{
AeonField = "ItemDate", AspaceData = "DateExpression", FieldLength = 50
}
}

HostAppInfo.CitationDataImport["DigitalObject"] = {
{
AeonField = "ItemTitle", AspaceData = "Title", FieldLength = 255
},
{
AeonField = "ItemAuthor", AspaceData = "Creators", FieldLength = 255
},
{
AeonField = "ItemSubtitle", AspaceData = "FindingAidTitle", FieldLength = 255
},
{
AeonField = "ItemDate", AspaceData = "DateExpression", FieldLength = 50
},
{
AeonField = "Location", AspaceData = "FileUri", FieldLength = 255
}
}

-- Page URIs
HostAppInfo.PageUri["ArchivalObject"] = "repositories/%d+/archival_objects/%d+";
HostAppInfo.PageUri["Resource"] = "repositories/%d+/resources/%d+";
HostAppInfo.PageUri["Accession"] = "repositories/%d+/accessions/%d+";
HostAppInfo.PageUri["DigitalObject"] = "repositories/%d+/digital_objects/%d+";

return HostAppInfo;
Loading

0 comments on commit 21105e8

Please sign in to comment.