Skip to content

Commit

Permalink
SAK-29118 add copyrightAlert to Content entity broker feed
Browse files Browse the repository at this point in the history
  • Loading branch information
bethkirschner committed Mar 2, 2015
1 parent 69d5009 commit 1aa024d
Showing 1 changed file with 23 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -297,23 +297,26 @@ private List<ContentItem> getSiteListItems(String siteId) {
* @param item
* @param props
*/
private void setContentItemValues(ContentEntity entity,
ContentItem item, ResourceProperties props) {
item.setTitle(props.getProperty(ResourceProperties.PROP_DISPLAY_NAME));
item.setDescription(props.getProperty(ResourceProperties.PROP_DESCRIPTION));
item.setUrl(entity.getUrl());
item.setAuthor(getDisplayName(props.getProperty(ResourceProperties.PROP_CREATOR)));
item.setModifiedDate(props.getProperty(ResourceProperties.PROP_MODIFIED_DATE));
item.setContainer(entity.getContainingCollection().getReference());
item.isVisible = !entity.isHidden() && entity.isAvailable();
item.isHidden = entity.isHidden();
if(entity.getReleaseDate() != null) {
item.setFromDate(entity.getReleaseDate().toStringGmtFull());
}
if(entity.getRetractDate()!=null) {
item.setEndDate(entity.getRetractDate().toStringGmtFull());
}
}
private void setContentItemValues(ContentEntity entity,
ContentItem item, ResourceProperties props) {
item.setTitle(props.getProperty(ResourceProperties.PROP_DISPLAY_NAME));
item.setDescription(props.getProperty(ResourceProperties.PROP_DESCRIPTION));
item.setUrl(entity.getUrl());
item.setAuthor(getDisplayName(props.getProperty(ResourceProperties.PROP_CREATOR)));
item.setModifiedDate(props.getProperty(ResourceProperties.PROP_MODIFIED_DATE));
item.setContainer(entity.getContainingCollection().getReference());
item.isVisible = !entity.isHidden() && entity.isAvailable();
item.isHidden = entity.isHidden();
if(entity.getReleaseDate() != null) {
item.setFromDate(entity.getReleaseDate().toStringGmtFull());
}
if(entity.getRetractDate()!=null) {
item.setEndDate(entity.getRetractDate().toStringGmtFull());
item.setEndDate(entity.getRetractDate().toStringGmtFull());
}
item.copyrightAlert = props.getProperty(props.getNamePropCopyrightAlert());

}

/**
*
Expand Down Expand Up @@ -511,6 +514,9 @@ public static class ContentItem {

@Getter @Setter
private String endDate;

@Getter @Setter
private String copyrightAlert;
}

/**
Expand Down

0 comments on commit 1aa024d

Please sign in to comment.