Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for setting Aeon Transaction's DocumentType based on an enumeration #34

Open
AustinTSchaffer opened this issue Sep 30, 2019 · 0 comments
Labels
enhancement New feature or request

Comments

@AustinTSchaffer
Copy link
Contributor

Currently, the plugin only supports a single Document Type per ArchivesSpace repository. All requests sent from a single repository will all be sent to Aeon and will all use the same web request form, since Aeon's Open URL system does not support populating the request's DocumentType based on the value of a specific non-DocumentType field. This means that it is currently not possible to change the web request form based on the value of a field that is tied to an enumeration, such as instance_instance_type. V1 for this enhancement should be able to support setting DocumentType from instance_instance_type, but this operation can be generalized to apply to any field.

The plugin should support per-instance and per-repository configurations that allow values from any source field to be translated to any destination field. This new configuration option should allow users to specify:

  1. a source field
  2. a value that could exist in the source field
  3. a destination field that will be modified in the event the source field matches the value
  4. a static value that should be stored in the destination field. This should also support copying the value of the source field into the destination field
  5. Optional enhancement: A setting that indicates whether the comparison between 1 and 2 uses an explicit match, a case insensitive match, a "string contains" operation, a regular expression, or some other kind of standard match between arbitrary data.

The structure of this setting, which will be some combination of hashmaps and arrays, should make an effort to prevent users from being able to configure an ambiguous field remapping that behaves differently, due to rules being evaluated in a different order each time. It may not be possible to prevent cascading remappings as part of this feature, but the feature should (at least) prevent a destination field from being specified more than once.

Something to note, fields such as instance_instance_type are suffixed with the instance number that it applies to before being sent to Aeon. This is because the plugin supports creating multiple requests for each instance of a record. Fields such as that are also contained within mappings['requests'] before being written to the HTML form. The new configuration setting should be able to support fields that come from this location in the mapping, and should also be persisted back into the mappings['requests'] so that fields such as DocumentType can vary between instances of the same record.

@AustinTSchaffer AustinTSchaffer added the enhancement New feature or request label Sep 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant