@@ -41,19 +41,19 @@ public class LabOnFhirConfig implements ApplicationContextAware {
4141
4242 public static final String GP_KEYSTORE_PATH = "labonfhir.keystorePath" ;
4343
44- public static final String GP_KEYSTORE_PASS = "labonfhir.keystorepass " ;
44+ public static final String GP_KEYSTORE_PASSWORD = "labonfhir.keystorepassword " ;
4545
4646 public static final String GP_TRUSTSTORE_PATH = "labonfhir.truststorePath" ;
4747
48- public static final String GP_TRUSTSTORE_PASS = "labonfhir.truststorepass " ;
48+ public static final String GP_TRUSTSTORE_PASSWORD = "labonfhir.truststorepassword " ;
4949
5050 public static final String GP_ACTIVATE_FHIR_PUSH = "labonfhir.activateFhirPush" ;
5151
5252 private static final String TEMP_DEFAULT_LIS_URL = "https://testapi.openelisci.org:8444/hapi-fhir-jpaserver/fhir" ;
5353
5454 public static final String GP_AUTH_TYPE = "labonfhir.authType" ;
5555
56- public static final String GP_USER_NAME = "labonfhir.userName " ;
56+ public static final String GP_USER_NAME = "labonfhir.username " ;
5757
5858 public static final String GP_PASSWORD = "labonfhir.password" ;
5959
@@ -69,6 +69,10 @@ public class LabOnFhirConfig implements ApplicationContextAware {
6969
7070 public static final String GP_FILTER_ORDER_BY_TEST_UUIDS = "labonfhir.filterOrderBytestUuids" ;
7171
72+ public static final String GP_FILTER_DEMO_DATA = "labonfhir.filterDemoData" ;
73+
74+ public static final String DEMO_PATIENT_ATTR = "demo_patient" ;
75+
7276 public enum AuthType {
7377 SSL ,
7478 BASIC
@@ -94,9 +98,9 @@ public SSLContext sslContext() throws Exception {
9498 try {
9599 if (administrationService .getGlobalProperty (GP_KEYSTORE_PATH ) != null
96100 && !administrationService .getGlobalProperty (GP_KEYSTORE_PATH ).isEmpty ()) {
97- String keyPassword = ConfigUtil .getProperty (GP_KEYSTORE_PASS );
101+ String keyPassword = ConfigUtil .getProperty (GP_KEYSTORE_PASSWORD );
98102 File truststoreFile = new File (administrationService .getGlobalProperty (GP_TRUSTSTORE_PATH ));
99- String truststorePassword = ConfigUtil .getProperty (GP_TRUSTSTORE_PASS );
103+ String truststorePassword = ConfigUtil .getProperty (GP_TRUSTSTORE_PASSWORD );
100104
101105 KeyStore keystore = loadKeystore (administrationService .getGlobalProperty (GP_KEYSTORE_PATH ));
102106
@@ -132,7 +136,7 @@ public String getLisUserUuid() {
132136 }
133137
134138 public String getLisUserName () {
135- return administrationService . getGlobalProperty (GP_USER_NAME );
139+ return ConfigUtil . getProperty (GP_USER_NAME );
136140 }
137141
138142 public String getLisPassword () {
@@ -158,7 +162,7 @@ public String getLabUpdateTriggerObject() {
158162 }
159163
160164 public Boolean filterOrderByTestUuuids () {
161- String filterOrders = administrationService .getGlobalProperty (GP_FILTER_ORDER_BY_TEST_UUIDS , "true " );
165+ String filterOrders = administrationService .getGlobalProperty (GP_FILTER_ORDER_BY_TEST_UUIDS , "false " );
162166 return Boolean .valueOf (filterOrders );
163167 }
164168
@@ -167,6 +171,11 @@ public Boolean addObsAsTaskInput() {
167171 return Boolean .valueOf (addObsAsTaskInPut );
168172 }
169173
174+ public Boolean filterDemoData () {
175+ String filterDemoData = administrationService .getGlobalProperty (GP_FILTER_DEMO_DATA , "true" );
176+ return Boolean .valueOf (filterDemoData );
177+ }
178+
170179 public AuthType getAuthType () {
171180 String authTypeGp = administrationService .getGlobalProperty (GP_AUTH_TYPE );
172181 switch (authTypeGp .toUpperCase ()) {
@@ -196,7 +205,7 @@ private KeyStore loadKeystore(String filePath) {
196205 is = new FileInputStream (file );
197206 keystore = KeyStore .getInstance (KeyStore .getDefaultType ());
198207
199- String password = ConfigUtil .getProperty (GP_KEYSTORE_PASS );
208+ String password = ConfigUtil .getProperty (GP_KEYSTORE_PASSWORD );
200209
201210 keystore .load (is , password .toCharArray ());
202211
0 commit comments