diff --git a/pom.xml b/pom.xml
index 72fd4e8..11d8d37 100644
--- a/pom.xml
+++ b/pom.xml
@@ -67,7 +67,7 @@
org.humanistika.oxygen
tei-completer
- 1.2.1-SNAPSHOT
+ 1.2.1
com.oxygenxml
diff --git a/src/main/java/org/humanistika/oxygen/tei/authorizer/TeiAuthorizer.java b/src/main/java/org/humanistika/oxygen/tei/authorizer/TeiAuthorizer.java
index 8fc664b..102ced4 100644
--- a/src/main/java/org/humanistika/oxygen/tei/authorizer/TeiAuthorizer.java
+++ b/src/main/java/org/humanistika/oxygen/tei/authorizer/TeiAuthorizer.java
@@ -97,7 +97,7 @@ public List filterAttributeValues(List list, final WhatPossibl
@SuppressWarnings("unchecked")
@Override
- protected Configuration getConfiguration() {
+ public Configuration getConfiguration() {
if(configuration == null) {
synchronized(this) {
if(configuration == null) {
diff --git a/src/main/java/org/humanistika/oxygen/tei/authorizer/configuration/beans/AutoComplete.java b/src/main/java/org/humanistika/oxygen/tei/authorizer/configuration/beans/AutoComplete.java
index 3312b12..b96a80d 100644
--- a/src/main/java/org/humanistika/oxygen/tei/authorizer/configuration/beans/AutoComplete.java
+++ b/src/main/java/org/humanistika/oxygen/tei/authorizer/configuration/beans/AutoComplete.java
@@ -22,6 +22,8 @@
import org.humanistika.oxygen.tei.completer.configuration.beans.Dependent;
import org.humanistika.oxygen.tei.completer.configuration.beans.RequestInfo;
import org.humanistika.oxygen.tei.completer.configuration.beans.ResponseAction;
+import org.humanistika.oxygen.tei.completer.configuration.beans.Selection;
+
import javax.annotation.Nullable;
import java.util.Map;
@@ -34,7 +36,7 @@ public class AutoComplete extends org.humanistika.oxygen.tei.completer.configura
@Nullable
private final UploadInfo uploadInfo;
- public AutoComplete(final Map namespaceBindings, final String context, final String attribute, final Dependent dependent, final String selection, final RequestInfo requestInfo, final ResponseAction responseAction, @Nullable final UploadInfo uploadInfo) {
+ public AutoComplete(final Map namespaceBindings, final String context, final String attribute, final Dependent dependent, final Selection selection, final RequestInfo requestInfo, final ResponseAction responseAction, @Nullable final UploadInfo uploadInfo) {
super(namespaceBindings, context, attribute, dependent, selection, requestInfo, responseAction);
this.uploadInfo = uploadInfo;
}
diff --git a/src/main/java/org/humanistika/oxygen/tei/authorizer/configuration/impl/XmlConfiguration.java b/src/main/java/org/humanistika/oxygen/tei/authorizer/configuration/impl/XmlConfiguration.java
index f5f2254..807c203 100644
--- a/src/main/java/org/humanistika/oxygen/tei/authorizer/configuration/impl/XmlConfiguration.java
+++ b/src/main/java/org/humanistika/oxygen/tei/authorizer/configuration/impl/XmlConfiguration.java
@@ -25,11 +25,14 @@
import org.humanistika.oxygen.tei.authorizer.configuration.beans.BodyInfo;
import org.humanistika.oxygen.tei.authorizer.configuration.beans.UploadInfo;
import org.humanistika.oxygen.tei.authorizer.configuration.beans.UserFieldInfo;
+
+import javax.annotation.Nullable;
+
import org.humanistika.oxygen.tei.completer.configuration.beans.Authentication;
import org.humanistika.oxygen.tei.completer.configuration.beans.Dependent;
import org.humanistika.oxygen.tei.completer.configuration.beans.RequestInfo;
import org.humanistika.oxygen.tei.completer.configuration.beans.ResponseAction;
-import javax.annotation.Nullable;
+import org.humanistika.oxygen.tei.completer.configuration.beans.Selection;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -97,8 +100,19 @@ private List expandConfig(final Config config) {
dependent = null;
} else {
dependent = new Dependent(
- autoComplete.getDependent().getDefault(),
- autoComplete.getDependent().getValue()
+ autoComplete.getDependent().getDefault(),
+ autoComplete.getDependent().getValue(),
+ autoComplete.getDependent().getLabel()
+ );
+ }
+
+ final Selection selection;
+ if(autoComplete.getSelection() == null) {
+ selection = null;
+ } else {
+ selection = new Selection(
+ autoComplete.getSelection().getValue(),
+ autoComplete.getSelection().getLabel()
);
}
@@ -167,7 +181,7 @@ private List expandConfig(final Config config) {
autoComplete.getContext(),
autoComplete.getAttribute(),
dependent,
- autoComplete.getSelection(),
+ selection,
requestInfo,
responseAction,
uploadInfo
diff --git a/src/main/resources/config.xsd b/src/main/resources/config.xsd
index e582a72..adda7ec 100644
--- a/src/main/resources/config.xsd
+++ b/src/main/resources/config.xsd
@@ -88,14 +88,30 @@
An optional default value to be used for the dependency if the attribute value is empty
+
+
+ A human-readable label for the dependent, this is used in the GUI.
+
+
-
+
The XPath (relative to the context) to use for the selection. e.g. text()
+
+
+
+
+
+ A human-readable label for the selection, this is used in the GUI.
+
+
+
+
+