-
Notifications
You must be signed in to change notification settings - Fork 174
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[API] Added features for dicoms : PatientName and images: isPhantom #6899
[API] Added features for dicoms : PatientName and images: isPhantom #6899
Conversation
fa61255
to
79cff9a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These changes do not correspond to the API spec.
@driusan do you mean that the spec should be adjusted in this PR? Or do you object to this change because it does not correspond to the API spec? |
0.0.3 was released, any changes need to go into a new version which incorporates the changes both in the code and the spec for that version |
@driusan Additions do not compromise the specs for existing users. Managing a new version for every modification is a lot of overhead. |
New additions without a new version absolutely compromises the spec. It's an API intended for third party usage. Values can't sometimes exist and sometimes not exist with the same version of the API and no way for the caller to know what it's going to get. |
The feature added in this endpoint is not in the specs for v0.0.3, so the changes suggested in this PR need to be added to the API v0.0.4 initiated in PR #6944, which is in progress. |
79cff9a
to
245b8dd
Compare
@spell00 is this PR still valid and ready for re-review? If so please re-request review from driusan (click the cycling arrows in the Reviewers list) |
@christinerogers It is still blocked by PR #6944 |
ce5b2f1
to
0acacb8
Compare
LGTM except it is failing travis. |
@driusan the modifications are now added to the specs of v0.0.4-dev |
c8f08ee
to
bc711e6
Compare
@@ -553,6 +553,7 @@ the form: | |||
"OutputType" : "native", | |||
"Filename" : "abc.mnc", | |||
"AcquisitionType" : "t1w/t2w/etc", | |||
"IsPhantom" : true/false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was going to say this isn't valid js so it's going to be rendered as an error since it's in a JS block, but then I decided to check if it's valid js in my JS console..
>> $x = true / false
Infinity
....
'Tarname' => $dicom->getTarname(), | ||
'SeriesInfo' => array_map( | ||
'Tarname' => $dicom->getTarname(), | ||
'Patientname' => $dicom->getPatientname(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is changing the result for both 0.0.3 and 0.0.4-dev, it needs a version check.
@@ -58,6 +58,7 @@ class Images | |||
'OutputType' => $image->getOutputType(), | |||
'Filename' => $image->getFilename(), | |||
'AcquisitionType' => $image->getAcquisitionprotocol(), | |||
'IsPhantom' => $image->isPhantom(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine to me, @xlecours does it still look good to you after the latest changes?
yes.
Once -dev is removed, replace the file by the -dev content then delete -dev. |
I don't think we're committed to that just because it's done that way in 1 place. We can always update the coding style to something more robust later, but since it works for this and the author of the PR is leaving I think we should merge it. |
…ces#6899) Patientname is added to dicoms endpoint view and IsPhantom is added to images endpoint view.
Brief summary of changes
Patientname
is added to dicoms endpoint view andIsPhantom
is added to images endpoint viewTesting instructions
Go to
<hostname>/api/v0.0.3/candidates/400162/V6/dicoms/
. Under the attributeTarname
, a new attribute should be there:Patientname : "ROM162_400162_V6"
Go to
<hostname>/api/v0.0.3/candidates/400162/V6/images/
. Each file should have 4 attributes, the last one being the new attribute,IsPhantom: false