Implementing feature

This commit is contained in:
Luca Frosini 2021-05-11 11:43:24 +02:00
parent bf637e439f
commit e00b2010d1
1 changed files with 25 additions and 0 deletions

View File

@ -337,6 +337,11 @@ public class CKANPackage extends CKAN {
parameters.put(GCatConstants.Q_KEY, filter);
}
if(ckanInstance.isModerationEnabled()) {
// TODO
}
return list(parameters);
}
@ -526,6 +531,10 @@ public class CKANPackage extends CKAN {
@Override
public String read() {
try {
if(ckanInstance.isModerationEnabled()) {
// TODO
}
String ret = super.read();
result = mapper.readTree(ret);
result = cleanResult(result);
@ -544,6 +553,11 @@ public class CKANPackage extends CKAN {
try {
logger.debug("Going to create Item {}", json);
if(ckanInstance.isModerationEnabled()) {
// TODO
}
JsonNode jsonNode = validateJson(json);
ArrayNode resourcesToBeCreated = mapper.createArrayNode();
@ -589,6 +603,10 @@ public class CKANPackage extends CKAN {
@Override
public String update(String json) {
try {
if(ckanInstance.isModerationEnabled()) {
// TODO
}
JsonNode jsonNode = validateJson(json);
read();
@ -662,6 +680,10 @@ public class CKANPackage extends CKAN {
@Override
public String patch(String json) {
try {
if(ckanInstance.isModerationEnabled()) {
// TODO
}
JsonNode jsonNode = checkBaseInformation(json, true);
read();
@ -736,6 +758,9 @@ public class CKANPackage extends CKAN {
@Override
protected void delete() {
if(ckanInstance.isModerationEnabled()) {
// TODO
}
super.delete();
}