# HG changeset patch # User Ingo Weinzierl # Date 1300988625 0 # Node ID ecfc33a4ba3d36460bd001d9b46ab1631184b783 # Parent cabe4c02ab6429a67d6710ce61944178d09321ce Bugfix: Creating new ArtifactCollection will create artifact collections with empty - but not null - attributes. artifacts/trunk@1563 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r cabe4c02ab64 -r ecfc33a4ba3d ChangeLog --- a/ChangeLog Thu Mar 24 16:16:51 2011 +0000 +++ b/ChangeLog Thu Mar 24 17:43:45 2011 +0000 @@ -1,3 +1,11 @@ +2011-03-24 Ingo Weinzierl + + * artifacts-common/src/main/java/de/intevation/artifacts/common/utils/ClientProtocolUtils.java: + The CREATE document for used for creating new ArtifactCollections will + build an ArtifactCollection with an empty attribute - but it is no + longer null (which broke the XML parser while fetching the + ArtifactCollection from backend). + 2011-03-24 Ingo Weinzierl * artifact-database/src/main/java/de/intevation/artifactdatabase/ArtifactDatabaseImpl.java: diff -r cabe4c02ab64 -r ecfc33a4ba3d artifacts-common/src/main/java/de/intevation/artifacts/common/utils/ClientProtocolUtils.java --- a/artifacts-common/src/main/java/de/intevation/artifacts/common/utils/ClientProtocolUtils.java Thu Mar 24 16:16:51 2011 +0000 +++ b/artifacts-common/src/main/java/de/intevation/artifacts/common/utils/ClientProtocolUtils.java Thu Mar 24 17:43:45 2011 +0000 @@ -211,12 +211,14 @@ Element action = cr.create("action"); Element type = cr.create("type"); Element collection = cr.create("collection"); + Element attribute = cr.create("attribute"); cr.addAttr(type, "name", "create"); cr.addAttr(collection, "name", name != null ? name : ""); action.appendChild(type); type.appendChild(collection); + collection.appendChild(attribute); doc.appendChild(action);