-
Notifications
You must be signed in to change notification settings - Fork 4
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
Ea 3925 issue item descriptions profile #261
Conversation
…ub.com/europeana/set-api.git into EA-3925-issue-itemDescriptions-profile
@@ -10,7 +10,8 @@ | |||
*/ | |||
public enum UserSetTypes implements JsonKeyword { | |||
|
|||
COLLECTION("Collection"), DYNAMICCOLLECTION("DynamicCollection"), BOOKMARKSFOLDER("BookmarkFolder"), ENTITYBESTITEMSSET("EntityBestItemsSet"); | |||
COLLECTION("Collection"), DYNAMICCOLLECTION("DynamicCollection"), BOOKMARKSFOLDER("BookmarkFolder"), ENTITYBESTITEMSSET("EntityBestItemsSet"), | |||
GALLERY("Gallery"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Gallery must not be included here. Only the values used in the type must be included here. For the time being we can use a constant in WebUserSetModelFields
@@ -280,6 +292,11 @@ public boolean isCollection() { | |||
return UserSetTypes.COLLECTION.getJsonValue().equals(getType()); | |||
} | |||
|
|||
@Override | |||
public boolean isGallery() { | |||
return UserSetTypes.GALLERY.getJsonValue().equals(getCollectionType()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
need to use a different constant
@@ -594,7 +599,7 @@ public void validateWebUserSet(UserSet webUserSet, boolean isAlreadyPublished) t | |||
@Override | |||
public void validateCollectionSize(UserSet webUserSet, int newItems) throws ItemValidationException { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please rename to validateGallerySize
@@ -594,7 +599,7 @@ public void validateWebUserSet(UserSet webUserSet, boolean isAlreadyPublished) t | |||
@Override | |||
public void validateCollectionSize(UserSet webUserSet, int newItems) throws ItemValidationException { | |||
final int collectionMaxSize = getConfiguration().getCollectionMaxSize(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the mthod in the configuration needs to be changed to getGalleryMaxSize
No description provided.