Skip to content

Commit

Permalink
add permission setting to loaded json doc
Browse files Browse the repository at this point in the history
  • Loading branch information
ningyifan committed Sep 21, 2016
1 parent 6264381 commit ba21c12
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions pre-annot-tool/load-ner.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ function loadNERs(nersets, sourceType, email){
subL = nersets[i];

for (j = 0; j < subL.length; j++){
//for (j = 0; j < 20; j++){
//for (j = 0; j < 10; j++){
annotation = subL[j];
if (annotation){
uriStr = "";
Expand Down Expand Up @@ -168,8 +168,9 @@ function loadAnnotation(annotation, uriStr, email){
"created": datetime,
"updated": datetime,
"annotationType": "DrugMention",
"quote": annotation.drugname,
"permissions": {},
"permissions": {
"read": ["group:__consumer__"]
},
"argues": {
"hasTarget": {
"hasSelector": {
Expand All @@ -192,7 +193,7 @@ function loadAnnotation(annotation, uriStr, email){
"consumer": "mockconsumer",
"uri": uriPost,
"rawurl": uriStr,
"user": "NER"
"user": "alice"
}
}, function (err, resp) {
if (err)
Expand Down

0 comments on commit ba21c12

Please sign in to comment.