diff --git a/src/App.vue b/src/App.vue index 7986c17c84148c4a662a0f90945883caa7ee81ec..f50b6ee8a213a2b394c76d253a552210848d27cb 100644 --- a/src/App.vue +++ b/src/App.vue @@ -258,7 +258,7 @@ export default { emptyForm: {}, members: [], fullmembers: [], - pid: "o:589601", + pid: "o:589444", piddoc: {}, collection: "", sampleCollection: "", @@ -723,7 +723,7 @@ export default { this.form.sections[1].fields.push(fields.getField("file")); - //push to biassay + //push to bioassay this.form.sections[2].categories[2].fields.push( fields.getField("0-Assay-title") @@ -775,23 +775,29 @@ export default { var uniprot_assayTarget = fields.getField("1-Uniprot"); uniprot_assayTarget.label = "Assay Target Uniprot record"; - uniprot_assayTarget.type = "pharmaWien:uniprot_protein_assayTarget"; + uniprot_assayTarget.type = "pharmaWien:assayTarget_uniprot"; uniprot_assayTarget.category = ["assayTarget"]; + uniprot_assayTarget.subcategory = ["assay target protein"]; var isoform_assayTarget = fields.getField("1-Isoform"); isoform_assayTarget.label = "Assay Target Isoform"; - isoform_assayTarget.type = "pharmaWien:assayTarget_isoform_protein"; + isoform_assayTarget.type = "pharmaWien:assayTarget__proteinIsoform"; isoform_assayTarget.category = ["assayTarget"]; + isoform_assayTarget.subcategory = ["assay target protein isoform"]; var seqAlt_assayTarget = fields.getField("1-Protein-sequence-alteration"); seqAlt_assayTarget.label = "Assay Target Protein sequence alteration"; - seqAlt_assayTarget.type = "pharmaWien:assayTarget_seqAlt_protein"; + seqAlt_assayTarget.type = "pharmaWien:assayTarget_proteinSeqAlt"; seqAlt_assayTarget.category = ["assayTarget"]; + seqAlt_assayTarget.subcategory = [ + "assay target Protein sequence alteration" + ]; var protMod_assayTarget = fields.getField("1-Protein-modification"); protMod_assayTarget.label = "Assay Target Protein Modification"; - protMod_assayTarget.type = "pharmaWien:assayTarget_protMod_protein"; + protMod_assayTarget.type = "pharmaWien:assayTarget_proteinProtMod"; protMod_assayTarget.category = ["assayTarget"]; + protMod_assayTarget.subcategory = ["assay target Protein Modification"]; this.form.sections[2].categories[2].fields.push(uniprot_assayTarget); this.form.sections[2].categories[2].fields.push(isoform_assayTarget); this.form.sections[2].categories[2].fields.push(seqAlt_assayTarget); @@ -802,26 +808,30 @@ export default { gene_assayTarget.type = "pharmaWien:assayTarget_geneId"; gene_assayTarget.category = ["assayTarget"]; + gene_assayTarget.subcategory = ["assay Target gene ID"]; var geneMod_assayTarget = fields.getField("1-Gene-modification"); geneMod_assayTarget.label = "Assay Target Gene Modification"; - geneMod_assayTarget.type = "pharmaWien:assayTarget_geneMod"; geneMod_assayTarget.category = ["assayTarget"]; + geneMod_assayTarget.subcategory = ["assay target gene modification"]; this.form.sections[2].categories[2].fields.push(gene_assayTarget); this.form.sections[2].categories[2].fields.push(geneMod_assayTarget); var nacid_assayTarget = fields.getField("1-Nucleic-acid-type"); nacid_assayTarget.label = "Assay Target Nucleic Acid Type"; - nacid_assayTarget.type = "pharmaWien:assayTarget_type_nucleicAcid"; + nacid_assayTarget.type = "pharmaWien:assayTarget_nucleicAcidType"; nacid_assayTarget.category = ["assayTarget"]; nacid_assayTarget.description = "Nucleic Acid"; + nacid_assayTarget.subcategory = ["assay target Nucleic Acid Type"]; var refSeq_assayTarget = fields.getField("1-RefSeq-accession"); refSeq_assayTarget.label = "Assay Target RefSeq accession:"; - refSeq_assayTarget.type = "pharmaWien:assayTarget_refSeq_nucleicAcid"; + refSeq_assayTarget.type = + "pharmaWien:assayTarget_nucleicAcidRefSeqAccession"; refSeq_assayTarget.category = ["assayTarget"]; refSeq_assayTarget.description = "Nucleic Acid"; + refSeq_assayTarget.subcategory = ["assay target RefSeq accession"]; this.form.sections[2].categories[2].fields.push(nacid_assayTarget); this.form.sections[2].categories[2].fields.push(refSeq_assayTarget); var PFAM_assayTarget = fields.getField("1-PFAM-accession"); @@ -829,34 +839,45 @@ export default { PFAM_assayTarget.type = "pharmaWien:assayTarget_PFAM"; PFAM_assayTarget.category = ["assayTarget"]; + PFAM_assayTarget.subcategory = ["assay target PFAM"]; this.form.sections[2].categories[2].fields.push(PFAM_assayTarget); var uniprotsub_assayTarget = fields.getField("1-Uniprot"); uniprotsub_assayTarget.label = "Assay Target Protein Subunit Uniprot record"; - uniprotsub_assayTarget.type = "pharmaWien:assayTarget_uniprot_protSub"; + uniprotsub_assayTarget.type = "pharmaWien:assayTarget_protSub"; uniprotsub_assayTarget.category = ["assayTarget"]; uniprotsub_assayTarget.description = "Protein Subunit"; + uniprotsub_assayTarget.subcategory = ["assay target protein subunit"]; var isoformsub_assayTarget = fields.getField("1-Isoform"); isoformsub_assayTarget.label = "Assay Target Protein Subunit Isoform"; - isoformsub_assayTarget.type = "pharmaWien:assayTarget_isoform_protSub"; + isoformsub_assayTarget.type = "pharmaWien:assayTarget_protSubIsoform"; isoformsub_assayTarget.category = ["assayTarget"]; isoformsub_assayTarget.description = "Protein Subunit"; + isoformsub_assayTarget.subcategory = [ + "assay Target protein subunit isoform" + ]; var seqAltsub_assayTarget = fields.getField( "1-Protein-sequence-alteration" ); seqAltsub_assayTarget.label = "Assay Target Protein Subunit sequence alteration"; - seqAltsub_assayTarget.type = "pharmaWien:assayTarget_seqAlt_protSub"; + seqAltsub_assayTarget.type = "pharmaWien:assayTarget_protSubSeqAlt"; seqAltsub_assayTarget.category = ["assayTarget"]; + seqAltsub_assayTarget.subcategory = [ + "assay Target Protein Subunit sequence alteration" + ]; seqAltsub_assayTarget.description = "Protein Subunit"; var protModsub_assayTarget = fields.getField("1-Protein-modification"); protModsub_assayTarget.label = "Assay Target Protein Subunit modification"; - protModsub_assayTarget.type = "pharmaWien:assayTarget_protMod_protSub"; + protModsub_assayTarget.type = "pharmaWien:assayTarget_protSubMod"; protModsub_assayTarget.category = ["assayTarget"]; + protModsub_assayTarget.subcategory = [ + "Assay Target Protein Subunit modification" + ]; protModsub_assayTarget.description = "Protein Subunit"; this.form.sections[2].categories[2].fields.push(uniprotsub_assayTarget); this.form.sections[2].categories[2].fields.push(isoformsub_assayTarget); @@ -868,8 +889,11 @@ export default { protcomplex_assayTarget.label = "Assay Target Protein Complex-Portal Accession"; protcomplex_assayTarget.type = - "pharmaWien:assayTarget_portalAcc_protComplex"; + "pharmaWien:assayTarget_protComplexPortalAcc"; protcomplex_assayTarget.category = ["assayTarget"]; + protcomplex_assayTarget.subcategory = [ + "ssay Target Protein Complex-Portal Accession" + ]; this.form.sections[2].categories[2].fields.push(protcomplex_assayTarget); this.form.sections[2].categories[2].fields.push( fields.getField("0-carbohydrate") @@ -924,11 +948,14 @@ export default { viroids_organism_assayTarget ); var cell_line_assayTarget = fields.getField("0-cell-line"); - cell_line_assayTarget.label = "Assay Target Cell line (cellosaurus)"; + cell_line_assayTarget.label = "Assay Target Cell line"; cell_line_assayTarget.type = "pharmaWien:assayTarget_cellosaurus"; cell_line_assayTarget.visible = false; cell_line_assayTarget.category = ["assayTarget"]; + cell_line_assayTarget.subcategory = [ + "Assay Target Cell line (cellosaurus)" + ]; this.form.sections[2].categories[2].fields.push(cell_line_assayTarget); this.form.sections[2].categories[2].fields.push( diff --git a/src/components/display/pharma_display/PhDJsonld.vue b/src/components/display/pharma_display/PhDJsonld.vue index 9907e2d14be72071063fb89476f5177aff188919..fd8c09d28f905f5bb2f0087f9dca8b9c7646abe6 100644 --- a/src/components/display/pharma_display/PhDJsonld.vue +++ b/src/components/display/pharma_display/PhDJsonld.vue @@ -413,27 +413,31 @@ <v-toolbar-title class="font-weight-light">{{categ.label}}</v-toolbar-title> </v-layout> </v-toolbar> - <template v-if="categ.fields.length>0"> - <v-card v-for="(l,index) in categ.fields" :key="l['@type']+'field'+index"> + + <v-card v-for="l in categ.fields" :key="l.category+'field'"> <v-layout v-if="l"> - + <v-flex xs11> - - <p-d-skos-preflabel - v-if="getSkosexactMatch(l)==undefined" - :o="l" - :key="l+index+'pharmafreesubject'" - ></p-d-skos-preflabel> + <v-card v-for="(inputf,index) in l.fields" :key="index+'subjectField'"> + + <p-d-skos-preflabel + v-if="getSkosexactMatch(inputf)==undefined" + :p="getLabel(inputf['@type'])" + :o="inputf" + :key="inputf+index+'pharmafreesubject'" + ></p-d-skos-preflabel> - <ph-d-metadata - v-if="getSkosexactMatch(l)" - :o="l" - :p="p" - :key="l+index+'pharmasubject'" - ></ph-d-metadata> - <v-divider></v-divider> + <ph-d-metadata + v-if="getSkosexactMatch(inputf)" + :o="inputf" + :p="p" + :key="index+'pharmasubject'" + ></ph-d-metadata> + <v-divider></v-divider> + </v-card> </v-flex> + </v-layout> </v-card> </template> @@ -446,8 +450,7 @@ </v-toolbar> <template v-if="categ.subcategory.length>0"> - - <v-card v-for="l in categ.subcategory" :key="l.category+'field'"> + <v-card v-for="l in categ.subcategory" :key="l.category+'field'"> <v-layout v-if="l"> <v-flex xs1 class="subheading"> <div class="text-xs-center"> @@ -457,7 +460,7 @@ <v-flex xs11> <v-card v-for="(inputf,index) in l.fields" :key="index+'subjectField'"> - + <p-d-skos-preflabel v-if="getSkosexactMatch(inputf)==undefined" :p="getLabel(inputf['@type'])" @@ -477,6 +480,8 @@ </v-layout> </v-card> + + </template> </v-card> </template> @@ -665,9 +670,6 @@ export default { }); if (jsonTypeArray.length > 0) { - //for (var k = 0; k < jsonTypeArray.length; k++) { - // console.log("jsonTypeArray", jsonTypeArray[k]); - //} //find first whether there is a subcategory if (formFieldsFiltered[j].subcategory) { //the category is formFieldsFiltered[j].category @@ -701,16 +703,76 @@ export default { } else { jsonStructured[result].subcategory = [ { - category: formFieldsFiltered[j].subcategory[0], + category: n_subcat, id: formFieldsFiltered[j].infoRef, fields: jsonTypeArray } ]; } + } else { + //a quick fix but it's not pretty!!! + //check if those are any of the bioassay categories - the way i structured this code is not adapted yet to those subfields + if ( + n_categ === "assayOrganism" || + n_categ === "assayTarget" || + n_categ === "assayDetection" + ) { + var findAssay = jsonStructured.findIndex( + obj => obj.category === "assay" + ); + if (jsonStructured[findAssay].subcategory) { + var r = jsonStructured[findAssay].subcategory.findIndex( + obj => obj.category === n_subcat + ); + + if (r >= 0) { + for (var n = 0; n < jsonTypeArray.length; n++) { + jsonStructured[findAssay].subcategory[r].fields.push( + jsonTypeArray[n] + ); + } + } else { + jsonStructured[findAssay].subcategory.push({ + category: n_subcat, + id: formFieldsFiltered[j].infoRef, + fields: jsonTypeArray + }); + } + } else { + if (n_categ === "assayOrganism") { + jsonStructured[findAssay].subcategory = [ + { + category: "Assay organism", + id: formFieldsFiltered[j].infoRef, + fields: jsonTypeArray + } + ]; + } + if (n_categ === "assayTarget") { + jsonStructured[findAssay].subcategory = [ + { + category: "Assay Target", + id: formFieldsFiltered[j].infoRef, + fields: jsonTypeArray + } + ]; + } + if (n_categ === "assayDetection") { + jsonStructured[findAssay].subcategory = [ + { + category: "Detection", + id: formFieldsFiltered[j].infoRef, + fields: jsonTypeArray + } + ]; + } + } + } } } else { //the category is formFieldsFiltered[j].category // if it exists, push to it, otherwise create it + var n_categ = formFieldsFiltered[j].category[0]; //check if it exists already @@ -719,39 +781,26 @@ export default { ); if (result >= 0) { - /* if (jsonStructured[result].subcategory) { - var r = jsonStructured[result].subcategory.findIndex( - obj => obj.category === n_subcat - ); - console.log( - "n_sub r", - r, - "formFieldsFiltered[j].infoRef", - formFieldsFiltered[j].infoRef - ); - if (r >= 0) { - jsonStructured[result].subcategory[r].fields.push( - jsonTypeArray[0] - ); - } else { - jsonStructured[result].subcategory.push({ - category: n_subcat, - id: formFieldsFiltered[j].infoRef, - fields: jsonTypeArray - }); + jsonStructured[result].fields.push({ + category: formFieldsFiltered[j].label, + id: formFieldsFiltered[j].infoRef, + fields: jsonTypeArray + }); + } else { + jsonStructured[result].fields = [ + { + category: "my cat", + id: formFieldsFiltered[j].infoRef, + fields: jsonTypeArray } - } else {*/ - jsonStructured[result].fields = jsonTypeArray; - // category: n_categ, - // id: formFieldsFiltered[j].infoRef, - // fields: jsonTypeArray - //}; + ]; } } } } } this.pharma = jsonStructured; + return jsonStructured; }, diff --git a/src/components/display/pharma_display/PhDMetadata.vue b/src/components/display/pharma_display/PhDMetadata.vue index 58824f4213ae78d2c088341154b1f68f42176c54..6dbc8aeccce5756a623f443685071437abf23d43 100644 --- a/src/components/display/pharma_display/PhDMetadata.vue +++ b/src/components/display/pharma_display/PhDMetadata.vue @@ -229,6 +229,8 @@ export default { }) .catch(function(error) { + self.data = self.o; + console.error(error); }); } diff --git a/src/components/input/PhSubmit.vue b/src/components/input/PhSubmit.vue index bd4869b2c5f8e29c13f27b6a1de505f50b75d352..8cfce64843eb0c90fa135a7447771795c18bba31 100644 --- a/src/components/input/PhSubmit.vue +++ b/src/components/input/PhSubmit.vue @@ -10,7 +10,7 @@ </template> </v-tab> <v-tab ripple @click="updatePrettyPrint()">Metadata preview</v-tab> - <v-tab v-if="templating" ripple @click="loadTemplates()">Templates</v-tab> + <!-- <v-tab v-if="templating" ripple @click="loadTemplates()">Templates</v-tab>--> </v-tabs> <v-tabs-items v-model="activetab"> diff --git a/src/components/input/pharma-input-fields/PhInputForm.vue b/src/components/input/pharma-input-fields/PhInputForm.vue index ff4dd46172baa212f87ca8ff1e3fcd3aef652828..33477fcec067c71405b39e99911d35c3e8c7584a 100644 --- a/src/components/input/pharma-input-fields/PhInputForm.vue +++ b/src/components/input/pharma-input-fields/PhInputForm.vue @@ -190,7 +190,7 @@ :freeText="{'@type': [f.type],'skos:prefLabel': [{'@value':''}]}" ></ph-selection> </v-flex> - + <v-layout row wrap @@ -595,6 +595,10 @@ export default { var sub = []; if (el.subcategory) { + for (var catt in arr) { + if (arr[catt].category[0] === el.subcategory[0]) { + } + } sub = arr.filter(function(a) { if (a.category) { return a.category[0] === el.subcategory[0]; @@ -635,6 +639,7 @@ export default { } } } else { + //WHAT"S UP HERE??? } } // } else { @@ -666,7 +671,7 @@ export default { this.$emit("form-input-" + f.component, f); }, warning: function(section) { - console.log("in warning", section); + //console.log("in warning", section); if (typeof section === "undefined") { //console.log("undefined"); } else { @@ -690,7 +695,7 @@ export default { for (var f in fields) { if (fields[f].warning === true) { w = true; - console.log("field", fields[f].label, "is missing"); + //console.log("field", fields[f].label, "is missing"); } } } diff --git a/src/utils/fields.js b/src/utils/fields.js index 66186c072b3457813f4bb185d7741837011e7297..001f2996e8266bad6b574cb19c069a948738b4d2 100644 --- a/src/utils/fields.js +++ b/src/utils/fields.js @@ -530,7 +530,6 @@ const fields = [ multiplicable: false, visible: true, category: ["life"], - vocabulary: "life", info: "Life NCIT:C142142 Thee biochemical phenomenon that distinguishes organisms from inorganic matter. It is characterized by growth, metabolism, and reproduction. [ NCI ]", @@ -751,14 +750,14 @@ const fields = [ { id: "4-Anatomical-category", predicate: "dcterms:subject", - type: "skos:Concept", + type: "pharmaWien:anatomicalCat", //subjectType: "Anatomical Category:", label: "Anatomical Category:", value: "", component: "selection", - commit: true, visible: true, + category: ["anatomicalCategory"], vocabulary: "anatomical_category", stateVoc: "anatomical_category", info: "OMIT:0001001", @@ -1134,6 +1133,7 @@ const fields = [ required: false, removable: false, category: ["assay"], + label: "Assay title:", value: "", component: "text-field", @@ -1156,6 +1156,7 @@ const fields = [ component: "text-field", multiline: true, category: ["assay"], + info: "This includes the methodology used to perform a particular bioassay and is found on the PubChem website associated with each assay ID (AID). It includes the assay components and the order in which they were added, the incubation times, detection method and the kit used, etc.", infoRef: "http://www.bioassayontology.org/bao#BAO_0000523", @@ -1174,6 +1175,7 @@ const fields = [ commit: true, visible: true, category: ["assay"], + subcategory: ["Assay type"], vocabulary: "bioassay_type", stateVoc: "bioassay_type", info: "", @@ -1194,6 +1196,7 @@ const fields = [ ontology: "bao", ontClass: "BAO_0000015", category: ["assay"], + subcategory: ["Bioassay category:"], topId: "BAO_0000015", description: "Bioassay category:", info: @@ -1216,6 +1219,7 @@ const fields = [ topId: "BAO_0000019", description: "Assay format:", category: ["assay"], + subcategory: ["Bioassay format:"], info: "Assay format is a conceptualization of assays based on the biological and / or chemical features of the experimental system. For example assay formats include biochemical assays - referring to assays with purified protein, cell-based - referring to assays in whole cells, or organism-based - referring to assays performed in an organism.", infoRef: "http://www.bioassayontology.org/bao#BAO_0000019", @@ -1237,6 +1241,8 @@ const fields = [ //category: ["assay"], topId: "BAO_0002202", description: "Assay design method:", + category: ["assay"], + subcategory: ["Bioassay design method:"], info: "The assay design method describes how a biological or physical process screened / investigated in the model system is translated into a detectable signal. This relates to the technology / technologies used to make the assay system work, i.e. enable that the screened process can be detected. It typically involves some manipulation of the (biological) model system to detect the process of interest.", infoRef: "http://www.bioassayontology.org/bao#BAO_0002202", @@ -1254,6 +1260,7 @@ const fields = [ freefield: true, component: "ext-service", category: ["assay"], + subcategory: ["Computational method:"], ontology: "bao", //baseurl: "http://www.bioassayontology.org/bao#", ontClass: "BAO_0002094", @@ -1278,6 +1285,7 @@ const fields = [ ontClass: "BAO_0000029", topId: "BAO_0000029", category: ["assay"], + subcategory: ["Assay screening campaign stage:"], // baseurl: "http://www.bioassayontology.org/bao#", description: "Assay screening campaign stage:", info: @@ -1287,7 +1295,7 @@ const fields = [ { id: "0-Organism", predicate: "dcterms:subject", - type: "pharmaWien:assayOrg", + type: "pharmaWien:assayOrganism", //subjectType: "AssayOrganism:", label: "Bioassay organism", //description: "selection", @@ -1298,41 +1306,19 @@ const fields = [ visible: true, vocabulary: "assay_organism", stateVoc: "assay_organism", - category: ["assay"], + category: ["assayOrganism"], subcategory: ["assayOrganism"], multiplicable: true, info: "The organism related to the target / meta-target of the bioassay. It includes both bacterium and eukaryote.", infoRef: "http://www.bioassayontology.org/bao#BAO:0000551", - description: "Bioassay organism:", - }, - { - id: "0-Organism-assayTarget", - predicate: "dcterms:subject", - type: "pharmaWien:assayTarget_organism", - //subjectType: "AssayOrganism:", - label: "Assay Target Organism", - description: "Bioassay Target organism", - value: "", - component: "selection", - freefield: false, - commit: true, - visible: false, - vocabulary: "assayTarget_organism", - stateVoc: "organism_assay_target", - category: ["assayTarget"], - subcategory: ["organismAssayTarget"], - multiplicable: true, - info: - "The organism related to the target / meta-target of the bioassay. It includes both bacterium and eukaryote.", - infoRef: "BAO:0000551", + description: "selection", }, { id: "0-Cellular-organism", predicate: "dcterms:subject", - type: "pharmaWien:assayOrganism_CellularOrganism", - //subjectType: "AssayCellularOrganism", - label: "Cellular organism", + type: "pharmaWien:assayOrgCellular", + label: "Bioassay Cellular organism", value: "", required: false, visible: false, @@ -1341,17 +1327,16 @@ const fields = [ ontClass: "NCBITaxon_131567", topId: "NCBITaxon_131567", component: "ext-service", - category: ["assay"], - subcategory: ["assayOrganism"], - description: "Bioassay organism:", + category: ["assayOrganism"], + subcategory: ["Cellular organism"], + description: "Cellular organism", info: "", }, { id: "0-Viruses", predicate: "dcterms:subject", - type: "pharmaWien:assayOrganism_Viruses", - //subjectType: "AssayViruses", - label: "Viruses", + type: "pharmaWien:assayOrgViruses", + label: "Bioassay Viruses", value: "", required: false, visible: false, @@ -1360,17 +1345,16 @@ const fields = [ ontClass: "NCBITaxon_10239", topId: "NCBITaxon_10239", component: "ext-service", - category: ["assay"], - subcategory: ["assayOrganism"], + category: ["assayOrganism"], + subcategory: ["Viruses"], description: "Viruses", info: "", }, { id: "0-Viroids", predicate: "dcterms:subject", - type: "pharmaWien:assayOrganism_Viroids", - //subjectType: "AssayViroids", - label: "Viroids", + type: "pharmaWien:assayOrgViroids", + label: "Bioassay Viroids", value: "", freefield: true, required: false, @@ -1379,11 +1363,35 @@ const fields = [ ontClass: "NCBITaxon_12884", topId: "NCBITaxon_12884", component: "ext-service", - category: ["assay"], - subcategory: ["assayOrganism"], + category: ["assayOrganism"], + subcategory: ["Viroids"], description: "Viroids", + infoRef: "NCBITaxon_12884", info: "", }, + { + id: "0-Organism-assayTarget", + predicate: "dcterms:subject", + type: "pharmaWien:assayTargetOrganism", + //subjectType: "AssayOrganism:", + label: "Assay Target Organism", + description: "Bioassay Target organism", + value: "", + component: "selection", + freefield: false, + commit: true, + visible: false, + vocabulary: "assayTarget_organism", + stateVoc: "organism_assay_target", + category: ["assayTarget"], + subcategory: ["organismAssayTarget"], + multiplicable: true, + info: + "The organism related to the target / meta-target of the bioassay. It includes both bacterium and eukaryote.", + infoRef: "BAO:0000551", + }, + + { id: "0-cell-line", predicate: "dcterms:subject", @@ -1397,6 +1405,8 @@ const fields = [ ontology: "cellosaurus", ontClass: "", treeview: false, + category: ["assay"], + subcategory: ["Cultured Cell"], description: "Cultured Cell (cellosaurus)", info: "A cell in vitro that is or has been maintained or propagated as part of a cell culture. [ ReO:mhb ]", @@ -1417,6 +1427,7 @@ const fields = [ visible: true, vocabulary: "assay_target", category: ["assayTarget"], + subcategory: ["assayTarget"], stateVoc: "assay_target", info: "", //baseurl: "http://www.bioassayontology.org/bao#", @@ -1438,6 +1449,7 @@ const fields = [ freetext: true, component: "ext-service", category: ["assayTarget"], + subcategory: ["Assay target Small Molecule"], description: "Small Molecule", info: "NCIT:C48809", }, @@ -1455,6 +1467,7 @@ const fields = [ topId: "GO_0110165", component: "ext-service", category: ["assayTarget"], + subcategory: ["Assay target cellular anatomical entity"], freefield: true, multiple: true, description: "Cellular anatomical entity", @@ -1477,6 +1490,7 @@ const fields = [ topId: "NCIT_C12801", component: "ext-service", category: ["assayTarget"], + subcategory: ["assay target Tissue"], description: "Tissue", info: "An anatomical structure consisting of similarly specialized cells and intercellular matrix, aggregated according to genetically determined spatial relationships, performing a specific function. [ NCI ]", @@ -1498,6 +1512,7 @@ const fields = [ topId: "CHEBI_16646", component: "ext-service", category: ["assayTarget"], + subcategory: ["Assay Target Carbohydrate"], description: "Carbohydrate", info: "An anatomical structure consisting of similarly specialized cells and intercellular matrix, aggregated according to genetically determined spatial relationships, performing a specific function. [ NCI ]", @@ -1506,20 +1521,20 @@ const fields = [ { id: "0-detection", predicate: "dcterms:subject", - type: "pharmaWien:assay_detection", + type: "pharmaWien:assayDetection", //subjectType: "assay_detection", label: "Detection method:", description: "selection", value: "", required: false, visible: true, - freefield: false, commit: true, visible: true, vocabulary: "assay_detection", stateVoc: "assay_detection", category: ["assayDetection"], + subcategory: ["Detection"], multiplicable: true, component: "selection", info: @@ -1529,7 +1544,7 @@ const fields = [ { id: "0-detection_method", predicate: "dcterms:subject", - type: "pharmaWien:assay_physicalDetectionMethod", + type: "pharmaWien:assayPhysicalDetectionMethod", //subjectType: "physical_detection_method", label: "Physical detection method:", value: "", @@ -1542,6 +1557,7 @@ const fields = [ topId: "BAO_0000035", component: "ext-service", category: ["assayDetection"], + subcategory: ["Detection Method"], description: "Physical detection method", info: "", infoRef: "http://www.bioassayontology.org/bao#BAO_0000035", @@ -1562,6 +1578,7 @@ const fields = [ topId: "BAO_0000697", component: "ext-service", category: ["assayDetection"], + subcategory: ["Detection Instrument"], description: "Detection instrument", info: "", infoRef: "http://www.bioassayontology.org/bao#BAO_0000697", @@ -1641,11 +1658,11 @@ const predicateOrder = [ ]; export default { - getFields: function() { + getFields: function () { return fields; }, - getEditableFields: function() { + getEditableFields: function () { var editable = fields.filter((item) => !item.readonly); // hack: some bug in vuetify autocomplete can't handle the value property var newarr = []; @@ -1656,7 +1673,7 @@ export default { } return newarr; }, - getField: function(id, ordergroup) { + getField: function (id, ordergroup) { for (var i = 0; i < fields.length; i++) { if (fields[i]["id"] === id) { var field = JSON.parse(JSON.stringify(fields[i])); @@ -1666,7 +1683,7 @@ export default { } } }, - getFieldbySubject: function(subject) { + getFieldbySubject: function (subject) { for (var i = 0; i < fields.length; i++) { if (fields[i]["type"] === subject) { var field = JSON.parse(JSON.stringify(fields[i])); @@ -1675,7 +1692,7 @@ export default { } } }, - getFieldsLabelsbyCateg: function(categ) { + getFieldsLabelsbyCateg: function (categ) { var ar = []; for (var i = 0; i < fields.length; i++) { @@ -1690,7 +1707,7 @@ export default { } return ar; }, - getPredicateOrder: function() { + getPredicateOrder: function () { return predicateOrder; }, };