Skip to content

Commit d87a649

Browse files
committed
changes per review
1 parent 91192a3 commit d87a649

6 files changed

Lines changed: 27 additions & 27 deletions

File tree

src/main/java/edu/harvard/iq/dataverse/DatasetPage.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6284,16 +6284,16 @@ public void setCurationStatus(String status) {
62846284
dataset = commandEngine.submit(new SetCurationStatusCommand(dvRequestService.getDataverseRequest(), dataset, status));
62856285
workingVersion=dataset.getLatestVersion();
62866286
if (Strings.isBlank(status)) {
6287-
JsfHelper.addInfoMessage(BundleUtil.getStringFromBundle("dataset.status.removed"));
6287+
JsfHelper.addInfoMessage(BundleUtil.getStringFromBundle("dataset.curationstatus.removed"));
62886288
} else {
6289-
JH.addMessage(FacesMessage.SEVERITY_INFO, BundleUtil.getStringFromBundle("dataset.status.header"),
6290-
BundleUtil.getStringFromBundle("dataset.status.info",
6289+
JH.addMessage(FacesMessage.SEVERITY_INFO, BundleUtil.getStringFromBundle("dataset.curationstatus.header"),
6290+
BundleUtil.getStringFromBundle("dataset.curationstatus.info",
62916291
Arrays.asList(DatasetUtil.getLocaleCurationStatusLabelFromString(status))
62926292
));
62936293
}
62946294

62956295
} catch (CommandException ex) {
6296-
String msg = BundleUtil.getStringFromBundle("dataset.status.cantchange");
6296+
String msg = BundleUtil.getStringFromBundle("dataset.curationstatus.cantchange");
62976297
logger.warning("Unable to change external status to " + status + " for dataset id " + dataset.getId() + ". Message to user: " + msg + " Exception: " + ex);
62986298
JsfHelper.addErrorMessage(msg);
62996299
}

src/main/java/edu/harvard/iq/dataverse/MailServiceBean.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -572,7 +572,7 @@ public String getMessageTextBasedOnNotification(UserNotification userNotificatio
572572
CurationStatus status = version.getCurationStatusAsOfDate(userNotification.getSendDateTimestamp());
573573
String curationLabel = DatasetUtil.getLocaleCurationStatusLabel(status);
574574
if(curationLabel == null) {
575-
curationLabel = BundleUtil.getStringFromBundle("dataset.status.none");
575+
curationLabel = BundleUtil.getStringFromBundle("dataset.curationstatus.none");
576576
}
577577
String[] paramArrayStatus = {
578578
version.getDataset().getDisplayName(),

src/main/java/edu/harvard/iq/dataverse/api/Datasets.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4873,8 +4873,8 @@ public Response getCurationStates(@Context ContainerRequestContext crc,
48734873
BundleUtil.getStringFromBundle("datasets.api.creationdate"),
48744874
BundleUtil.getStringFromBundle("datasets.api.modificationdate"),
48754875
BundleUtil.getStringFromBundle("datasets.api.curationstatus"),
4876-
BundleUtil.getStringFromBundle("datasets.api.statuscreatetime"),
4877-
BundleUtil.getStringFromBundle("datasets.api.statussetter"),
4876+
BundleUtil.getStringFromBundle("datasets.api.curationstatuscreatetime"),
4877+
BundleUtil.getStringFromBundle("datasets.api.curationstatussetter"),
48784878
String.join(",", assignees.keySet())));
48794879
for (Dataset dataset : datasetSvc.findAllWithDraftVersion()) {
48804880
List<RoleAssignment> ras = permissionService.assignmentsOn(dataset);
@@ -4892,9 +4892,9 @@ public Response getCurationStates(@Context ContainerRequestContext crc,
48924892
List<CurationStatus> statuses = includeHistory ? dsv.getCurationStatuses() : Collections.singletonList(dsv.getCurrentCurationStatus());
48934893

48944894
for (CurationStatus status : statuses) {
4895-
String label = BundleUtil.getStringFromBundle("dataset.status.none");
4896-
String statusCreator = BundleUtil.getStringFromBundle("dataset.status.none");
4897-
String createTime = BundleUtil.getStringFromBundle("dataset.status.none");
4895+
String label = BundleUtil.getStringFromBundle("dataset.curationstatus.none");
4896+
String statusCreator = BundleUtil.getStringFromBundle("dataset.curationstatus.none");
4897+
String createTime = BundleUtil.getStringFromBundle("dataset.curationstatus.none");
48984898

48994899
if (status != null) {
49004900
if (Strings.isNotBlank(status.getLabel())) {

src/main/java/edu/harvard/iq/dataverse/engine/command/impl/SetCurationStatusCommand.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,19 +51,19 @@ public SetCurationStatusCommand(DataverseRequest aRequest, Dataset dataset, Stri
5151
public Dataset execute(CommandContext ctxt) throws CommandException {
5252
DatasetVersion version = getDataset().getLatestVersion();
5353
if (version.isReleased()) {
54-
throw new IllegalCommandException(BundleUtil.getStringFromBundle("dataset.status.failure.isReleased"), this);
54+
throw new IllegalCommandException(BundleUtil.getStringFromBundle("dataset.curationstatus.failure.isReleased"), this);
5555
}
5656
CurationStatus currentStatus = version.getCurrentCurationStatus();
5757

5858
CurationStatus status = null;
5959
if (((currentStatus == null || Strings.isBlank(currentStatus.getLabel())) && Strings.isNotBlank(label)) ||
6060
(currentStatus != null && !currentStatus.getLabel().equals(label))) {
61-
status = new CurationStatus(label, getDataset().getLatestVersion(), getRequest().getAuthenticatedUser());
61+
status = new CurationStatus(label, version, getRequest().getAuthenticatedUser());
6262
}
6363

6464
String setName = getDataset().getEffectiveCurationLabelSetName();
6565
if (setName.equals(SystemConfig.CURATIONLABELSDISABLED)) {
66-
throw new IllegalCommandException(BundleUtil.getStringFromBundle("dataset.status.failure.disabled"), this);
66+
throw new IllegalCommandException(BundleUtil.getStringFromBundle("dataset.curationstatus.failure.disabled"), this);
6767
}
6868
if (status != null) {
6969
boolean found = false;
@@ -83,11 +83,11 @@ public Dataset execute(CommandContext ctxt) throws CommandException {
8383
}
8484
if (!found) {
8585
logger.fine("Label not found: " + label + " in set " + setName);
86-
throw new IllegalCommandException(BundleUtil.getStringFromBundle("dataset.status.failure.notallowed"), this);
86+
throw new IllegalCommandException(BundleUtil.getStringFromBundle("dataset.curationstatus.failure.notallowed"), this);
8787
}
8888
} else {
8989
logger.fine("Attempt to reset with the same label : " + label);
90-
throw new IllegalCommandException(BundleUtil.getStringFromBundle("dataset.status.failure.noChange"), this);
90+
throw new IllegalCommandException(BundleUtil.getStringFromBundle("dataset.curationstatus.failure.noChange"), this);
9191
}
9292
Dataset updatedDataset = save(ctxt);
9393
return updatedDataset;

src/main/java/propertyFiles/Bundle.properties

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1569,15 +1569,15 @@ dataset.submit.failure=Dataset Submission Failed - {0}
15691569
dataset.submit.failure.null=Can't submit for review. Dataset is null.
15701570
dataset.submit.failure.isReleased=Latest version of dataset is already released. Only draft versions can be submitted for review.
15711571
dataset.submit.failure.inReview=You cannot submit this dataset for review because it is already in review.
1572-
dataset.status.failure.notallowed=Status update failed - label not allowed
1573-
dataset.status.failure.noChange=Status update failed - the dataset already has this status
1574-
dataset.status.failure.disabled=Status labeling disabled for this dataset
1575-
dataset.status.failure.isReleased=Latest version of dataset is already released. Status can only be set on draft versions
1576-
dataset.status.header=Curation Status Changed
1577-
dataset.status.removed=Curation Status Removed
1578-
dataset.status.info=Curation Status is now "{0}"
1579-
dataset.status.none=<none>
1580-
dataset.status.cantchange=Unable to change Curation Status. Please contact the administrator.
1572+
dataset.curationstatus.failure.notallowed=Status update failed - label not allowed
1573+
dataset.curationstatus.failure.noChange=Status update failed - the dataset already has this status
1574+
dataset.curationstatus.failure.disabled=Status labeling disabled for this dataset
1575+
dataset.curationstatus.failure.isReleased=Latest version of dataset is already released. Status can only be set on draft versions
1576+
dataset.curationstatus.header=Curation Status Changed
1577+
dataset.curationstatus.removed=Curation Status Removed
1578+
dataset.curationstatus.info=Curation Status is now "{0}"
1579+
dataset.curationstatus.none=<none>
1580+
dataset.curationstatus.cantchange=Unable to change Curation Status. Please contact the administrator.
15811581
dataset.rejectMessage=Return this dataset to contributor for modification.
15821582
dataset.rejectMessageReason=The reason for return entered below will be sent by email to the author.
15831583
dataset.rejectMessage.label=Return to Author Reason
@@ -2826,8 +2826,8 @@ datasets.api.privateurl.anonymized.error.released=Can't create a URL for anonymi
28262826
datasets.api.creationdate=Date Created
28272827
datasets.api.modificationdate=Last Modified Date
28282828
datasets.api.curationstatus=Curation Status
2829-
datasets.api.statuscreatetime=Status Set Time
2830-
datasets.api.statussetter=Status Set By
2829+
datasets.api.curationstatuscreatetime=Status Set Time
2830+
datasets.api.curationstatussetter=Status Set By
28312831
datasets.api.version.files.invalid.order.criteria=Invalid order criteria: {0}
28322832
datasets.api.version.files.invalid.access.status=Invalid access status: {0}
28332833
datasets.api.deaccessionDataset.invalid.version.identifier.error=Only {0} or a specific version can be deaccessioned

src/main/java/propertyFiles/astrophysics.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ datasetfieldtype.astroFacility.description=The observatory or facility where the
3232
datasetfieldtype.astroInstrument.description=The instrument used to collect the data.
3333
datasetfieldtype.astroObject.description=Astronomical Objects represented in the data (Given as SIMBAD recognizable names preferred).
3434
datasetfieldtype.resolution.Spatial.description=The spatial (angular) resolution that is typical of the observations, in decimal degrees.
35-
datasetfieldtype.resolution.Spectral.description=The spectral resolution that is typical of the observations, given as the ratio \u03bb/\u0394\u03bb.
35+
datasetfieldtype.resolution.Spectral.description=The spectral resolution that is typical of the observations, given as the ratio λ/Δλ.
3636
datasetfieldtype.resolution.Temporal.description=The temporal resolution that is typical of the observations, given in seconds.
3737
datasetfieldtype.coverage.Spectral.Bandpass.description=Conventional bandpass name
3838
datasetfieldtype.coverage.Spectral.CentralWavelength.description=The central wavelength of the spectral bandpass, in meters.

0 commit comments

Comments
 (0)