Skip to content

Commit

Permalink
#254 implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
eblondel committed Sep 1, 2023
1 parent 49013a6 commit b834e56
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion R/geoflow_validator.R
Original file line number Diff line number Diff line change
Expand Up @@ -736,9 +736,9 @@ geoflow_validator_entity_Relation <- R6Class("geoflow_validator_entity_Relation"
#'@param str string to validate
initialize = function(i, j, str){
valid_keys <- list(
"ref",
"ftp", "http", "download",
"parent","thumbnail",
"ref", "grant",
"csw", "csw202", "csw30",
"wcs", "wcs100", "wcs11", "wcs110", "wcs111", "wcs201",
"wfs", "wfs100", "wfs110", "wfs200",
Expand Down
1 change: 1 addition & 0 deletions doc/Summary_metadata.csv
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ Relation,wms,,,x,,,,,,x,,
Relation,wfs,,,x,,,,,,x,,
Relation,wcs,,,x,,,,,,,,
Relation,ref,x,,,,,,,x,,,
Relation,grant,,,,,,,,x,,,
Rights,use,x,x,x,,,,,,,,
Rights,useLimitation,x,x,x,,,,,,,,
Rights,useConstraint,,,x,,,,,,x,x,
Expand Down
10 changes: 10 additions & 0 deletions inst/actions/zen4R_deposit_record.R
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,16 @@ function(action, entity, config){
}
}

#grants
if(length(entity$relations)){
grants = entity$relations[sapply(entity$relations, function(x){tolower(x$key) == "grant"})]
if(length(grants)>0){
for(grant in grants){
zenodo_metadata$addGrant(grant)
}
}
}

#communities
if(length(communities)>0){
zenodo_metadata$metadata$communities <- list()
Expand Down

0 comments on commit b834e56

Please sign in to comment.