]> git.aero2k.de Git - tmp/jakarta-migration.git/commitdiff
CSPACE-2670. Added support for address and accessnote in location schema.
authorPatrick Schmitz <pschmitz@berkeley.edu>
Tue, 24 Aug 2010 05:39:10 +0000 (05:39 +0000)
committerPatrick Schmitz <pschmitz@berkeley.edu>
Tue, 24 Aug 2010 05:39:10 +0000 (05:39 +0000)
services/location/3rdparty/nuxeo-platform-cs-location/src/main/resources/schemas/locations_common.xsd
services/location/client/src/main/java/org/collectionspace/services/client/LocationAuthorityClientUtils.java
services/location/client/src/test/java/org/collectionspace/services/client/test/LocationAuthorityServiceTest.java
services/location/jaxb/src/main/java/org/collectionspace/services/LocationJAXBSchema.java
services/location/jaxb/src/main/resources/location_common.xsd

index 54e76a1c913b8df36d13cfd272689fb1e8e89d60..ed0ffa7e83697dc516ca21527188b523ea4c3e73 100644 (file)
@@ -32,6 +32,8 @@
     <xs:element name="conditionNote" type="xs:string"/>
     <xs:element name="conditionNoteDate" type="xs:string"/>
     <xs:element name="securityNote" type="xs:string"/>
+    <xs:element name="accessNote" type="xs:string"/>
+    <xs:element name="address" type="xs:string"/>
     <xs:element name="locationType" type="xs:string"/>
 
 </xs:schema>
index ae878daa891520c17417270efe3ae2946be1a40d..fac62e1d517597bae7b09c90fff42fa608e9ba01 100644 (file)
@@ -81,8 +81,12 @@ public class LocationAuthorityClientUtils {
                location.setConditionNoteDate(value);\r
         if((value = (String)locationInfo.get(LocationJAXBSchema.SECURITY_NOTE))!=null)\r
                location.setSecurityNote(value);\r
+        if((value = (String)locationInfo.get(LocationJAXBSchema.ACCESS_NOTE))!=null)\r
+               location.setAccessNote(value);\r
         if((value = (String)locationInfo.get(LocationJAXBSchema.LOCATION_TYPE))!=null)\r
                location.setLocationType(value);\r
+        if((value = (String)locationInfo.get(LocationJAXBSchema.ADDRESS))!=null)\r
+               location.setAddress(value);\r
         if((value = (String)locationInfo.get(LocationJAXBSchema.TERM_STATUS))!=null)\r
                location.setTermStatus(value);\r
         MultipartOutput multipart = new MultipartOutput();\r
index c9aefb2dba316be2c45c633ff0cacc5300115fef..1d941d32bdf60ddd8de89edc7e719990154901b9 100644 (file)
@@ -81,6 +81,8 @@ public class LocationAuthorityServiceTest extends AbstractServiceTestImpl {
     final String TEST_CONDITION_NOTE = "Basically clean";
     final String TEST_CONDITION_NOTE_DATE = "June 11, 1979";
     final String TEST_SECURITY_NOTE = "Kind of safe";
+    final String TEST_ACCESS_NOTE = "Only right-thinkers may see";
+    final String TEST_ADDRESS = "123 Main Street, Anytown USA";
     // TODO Make loc type be a controlled vocab term.
     final String TEST_LOCATION_TYPE = "Shelf";
     // TODO Make status type be a controlled vocab term.
@@ -235,6 +237,8 @@ public class LocationAuthorityServiceTest extends AbstractServiceTestImpl {
         shelf1Map.put(LocationJAXBSchema.CONDITION_NOTE, TEST_CONDITION_NOTE);
         shelf1Map.put(LocationJAXBSchema.CONDITION_NOTE_DATE, TEST_CONDITION_NOTE_DATE);
         shelf1Map.put(LocationJAXBSchema.SECURITY_NOTE, TEST_SECURITY_NOTE);
+        shelf1Map.put(LocationJAXBSchema.ACCESS_NOTE, TEST_ACCESS_NOTE);
+        shelf1Map.put(LocationJAXBSchema.ADDRESS, TEST_ADDRESS);
         shelf1Map.put(LocationJAXBSchema.LOCATION_TYPE, TEST_LOCATION_TYPE);
         shelf1Map.put(LocationJAXBSchema.TERM_STATUS, TEST_STATUS);
         
index dbbe74acb56d25a931cd29d160873da967083b0e..cc073fd62840947bb8a134df1f73662172f17064 100644 (file)
@@ -15,6 +15,8 @@ public interface LocationJAXBSchema extends AuthorityJAXBSchema {
        final static String CONDITION_NOTE = "conditionNote";\r
        final static String CONDITION_NOTE_DATE = "conditionNoteDate";\r
        final static String SECURITY_NOTE = "securityNote";\r
+       final static String ACCESS_NOTE = "accessNote";\r
+       final static String ADDRESS = "address";\r
        final static String LOCATION_TYPE = "locationType";\r
 }\r
 \r
index 9b02b2acfa89396cce22efdeb54d5a0e985b5416..d66668eff54559df6a74fd7801bc3aeb67cc083c 100644 (file)
@@ -31,6 +31,8 @@
                                                                <xs:element name="conditionNote" type="xs:string"/>
                                                                <xs:element name="conditionNoteDate" type="xs:string"/>
                                                                <xs:element name="securityNote" type="xs:string"/>
+                                                               <xs:element name="accessNote" type="xs:string"/>
+                                                               <xs:element name="address" type="xs:string"/>
                                                                <xs:element name="locationType" type="xs:string"/>
             </xs:sequence>
         </xs:complexType>