Social Post is disabled if not explicitly enabled by the client #19295
This commit is contained in:
parent
5a382ce556
commit
a51c7f9312
|
@ -0,0 +1,116 @@
|
||||||
|
# Changelog
|
||||||
|
|
||||||
|
All notable changes to this project will be documented in this file.
|
||||||
|
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||||
|
|
||||||
|
|
||||||
|
## [1-4-3] [r4.23.0] - 2020-05-22
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- [#19295] Social Post is disabled if not explicitly enabled by the client
|
||||||
|
|
||||||
|
## [v1-4-2] [r4.20.0]- 2020-02-14
|
||||||
|
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
**Features**
|
||||||
|
|
||||||
|
- Added method to retrieve a persisted file
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
**Fixes**
|
||||||
|
|
||||||
|
- Considering that a file could not be persisted because it could be published via portlet
|
||||||
|
|
||||||
|
|
||||||
|
## [1-4-1] - 2019-12-20
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
**Fixes**
|
||||||
|
|
||||||
|
- Fixed distro files and pom according to new release procedure
|
||||||
|
|
||||||
|
- Fixed metadata checks
|
||||||
|
|
||||||
|
## [1-4-0] - 2019-11-06
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
**Features**
|
||||||
|
|
||||||
|
- [#17635] Items listing API when invoked at VO level allow to get all the catalogue items or filtering them by organization
|
||||||
|
|
||||||
|
- [#17645] Enabled the possibility of filtering the result of items listing API
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
**Fixes**
|
||||||
|
|
||||||
|
- [#16360] User information are checked/updated on CKAN using portal information
|
||||||
|
|
||||||
|
## [1-3-0] - 2019-06-12
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
**Fixes**
|
||||||
|
|
||||||
|
- [#16740] Removed the requirement of providing the id of an item in update
|
||||||
|
|
||||||
|
## [1-2-0] - 2019-06-12
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
**Fixes**
|
||||||
|
|
||||||
|
- Separated REST class for Profile management from the logic which effectively manage profile on IS
|
||||||
|
|
||||||
|
- [#16182] Tags are now properly created/added according to profile definition
|
||||||
|
|
||||||
|
- [#16183] Groups are now properly created/added according to profile definition
|
||||||
|
|
||||||
|
- [#16330] Fixed bug on getting responses from social service
|
||||||
|
|
||||||
|
- [#16347] Setting format in resources
|
||||||
|
|
||||||
|
- [#16354] Validated provided LicenseId for Item
|
||||||
|
|
||||||
|
- [#16410] Capacity field is removed from the provided item content if any
|
||||||
|
|
||||||
|
- [#16322] Fixed bug on social post creation
|
||||||
|
|
||||||
|
- [#16322] Added the possibility to disable social post on item creation
|
||||||
|
|
||||||
|
- [#16322] Improved social post message
|
||||||
|
|
||||||
|
- [#16635] Added support to publish in specific organizations when the request is not performed at VRE level
|
||||||
|
|
||||||
|
## [1-1-0] - 2019-02-26
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
**Fixes**
|
||||||
|
|
||||||
|
- [#13309] Added Item URL via URI Resolver in extras field
|
||||||
|
|
||||||
|
- [#13303] The final URL is retrieved only URI resolver pointing to Storage Hub
|
||||||
|
|
||||||
|
- [#13306] Enforched items to be searchable in 'extras' field
|
||||||
|
|
||||||
|
- [#13307] Switched item listing to use package_search in place of package_list
|
||||||
|
|
||||||
|
- [#13076] Refactored to use storage-hub-persistence library
|
||||||
|
|
||||||
|
- [#13079] Added Create/Update/Delete in Profile Collection
|
||||||
|
|
||||||
|
- Fixed issues in Resource collection
|
||||||
|
|
||||||
|
- Refactored to use gcat-api library
|
||||||
|
|
||||||
|
|
||||||
|
## [1-0-0] - 2018-12-07
|
||||||
|
|
||||||
|
First Release
|
|
@ -1,7 +1,10 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<!DOCTYPE xml>
|
<!DOCTYPE xml>
|
||||||
<ReleaseNotes>
|
<ReleaseNotes>
|
||||||
<Changeset component="org.gcube.data-publishing.gcat.1-4-2" date="${buildDate}">
|
<Changeset component="org.gcube.data-publishing.gcat.1-4-3" date="${buildDate}">
|
||||||
|
<Change>Social Post is disabled if not explitly enabled by the client #19295</Change>
|
||||||
|
</Changeset>
|
||||||
|
<Changeset component="org.gcube.data-publishing.gcat.1-4-2" date="2020-02-14">
|
||||||
<Change>Considering that a file could not be persisted because it could be published via portlet</Change>
|
<Change>Considering that a file could not be persisted because it could be published via portlet</Change>
|
||||||
<Change>Added method to retrieve a persisted file</Change>
|
<Change>Added method to retrieve a persisted file</Change>
|
||||||
</Changeset>
|
</Changeset>
|
||||||
|
|
2
pom.xml
2
pom.xml
|
@ -12,7 +12,7 @@
|
||||||
<groupId>org.gcube.data-publishing</groupId>
|
<groupId>org.gcube.data-publishing</groupId>
|
||||||
<artifactId>gcat</artifactId>
|
<artifactId>gcat</artifactId>
|
||||||
<packaging>war</packaging>
|
<packaging>war</packaging>
|
||||||
<version>1.4.2</version>
|
<version>1.4.3-SNAPHOT</version>
|
||||||
<name>gCube Catalogue (gCat) Service</name>
|
<name>gCube Catalogue (gCat) Service</name>
|
||||||
<description>
|
<description>
|
||||||
This service allows any client to publish on the gCube Catalogue.
|
This service allows any client to publish on the gCube Catalogue.
|
||||||
|
|
|
@ -432,14 +432,14 @@ public class CKANPackage extends CKAN {
|
||||||
|
|
||||||
protected void sendSocialPost(String title, String catalogueItemURL) {
|
protected void sendSocialPost(String title, String catalogueItemURL) {
|
||||||
try {
|
try {
|
||||||
boolean socialPost = true;
|
boolean socialPost = false;
|
||||||
try {
|
try {
|
||||||
MultivaluedMap<String,String> queryParameters = uriInfo.getQueryParameters();
|
MultivaluedMap<String,String> queryParameters = uriInfo.getQueryParameters();
|
||||||
if(queryParameters.containsKey(GCatConstants.SOCIAL_POST_PARAMETER)) {
|
if(queryParameters.containsKey(GCatConstants.SOCIAL_POST_PARAMETER)) {
|
||||||
socialPost = Boolean.parseBoolean(queryParameters.getFirst(GCatConstants.SOCIAL_POST_PARAMETER));
|
socialPost = Boolean.parseBoolean(queryParameters.getFirst(GCatConstants.SOCIAL_POST_PARAMETER));
|
||||||
}
|
}
|
||||||
} catch(Exception e) {
|
} catch(Exception e) {
|
||||||
socialPost = true;
|
socialPost = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(socialPost) {
|
if(socialPost) {
|
||||||
|
|
Loading…
Reference in New Issue