Skip to content

Commit

Permalink
update ena2ont
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaoranzhou committed Jul 3, 2024
1 parent 34f5922 commit 10556e8
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -219,10 +219,10 @@
if (checklistNr == checklistNo){
number +=1;
let Term1 =`
[Term]
id: ENACL:0`+checklistNo.slice(2)+`
name: `+checklistNo+`
def: " `+list1.querySelector("DESCRIPTOR").querySelector("LABEL").innerHTML+`"
[Term]
id: ENACL:0`+checklistNo.slice(2)+`
name: `+checklistNo+`
def: " `+list1.querySelector("DESCRIPTOR").querySelector("LABEL").innerHTML+`"
`
const list2 = Array.prototype.slice.call(list1.querySelectorAll("FIELD"));
var text = header + Term1;
Expand All @@ -245,12 +245,12 @@
//console.log("csv will be: "+ label+", "+ mandatory+", "+ units+", "+fieldType+", "+fieldValidate );
let ontid = "ENACL:" + (100+parseInt(number)).toString()+ (1000+parseInt(index)).toString();
text += `
[Term]
id: `+ontid+`
name: `+label+`
def: " `+description+`"
subset: samples
comment: `+ "\t mandatory: "+ mandatory+".\t unit:"+ units+".\t field type: "+fieldType+".\t validation: "+fieldValidate.replace(/(?:\r\n|\r|\n)/g, "").replace(/(?:\r\n|\r|\n)/g, "")+"\n"
[Term]
id: `+ontid+`
name: `+label+`
def: " `+description.replaceAll('"','\\"')+`"
subset: samples
comment: `+ "\t mandatory: "+ mandatory+".\t unit:"+ units+".\t field type: "+fieldType+".\t validation: "+fieldValidate.replaceAll(/(?:\r\n|\r|\n)/g, "").replace(/(?:\r\n|\r|\n)/g, "").replaceAll("{","\\{").replaceAll("}","\\}")+"\n"

// label+"\t"+ mandatory+"\t"+ units+"\t"+fieldType+"\t"+fieldValidate.replace(/(?:\r\n|\r|\n)/g, "").replace(/(?:\r\n|\r|\n)/g, "")+"\n"

Expand Down

0 comments on commit 10556e8

Please sign in to comment.