Revision 58113
Added by Konstantinos Triantafyllou about 4 years ago
searchFields.ts | ||
---|---|---|
4 | 4 |
//RESULTS |
5 | 5 |
//Used for datasets and publications and software and orp |
6 | 6 |
//In case Datasets or Software should display different fields, use seperate tables for fields |
7 |
// "resultacceptanceyear", |
|
8 |
public RESULT_RANGE_FIELDS = [ |
|
9 |
["resultacceptanceyear", "resultacceptanceyear"] |
|
10 |
]; |
|
7 | 11 |
public RESULT_REFINE_FIELDS = [ |
8 | 12 |
"relfunder", |
9 | 13 |
"relfundinglevel0_id","relfundinglevel1_id","relfundinglevel2_id", |
10 |
"relproject","resultacceptanceyear",
|
|
14 |
"relproject", |
|
11 | 15 |
"resultbestaccessright", "instancetypename", "resultlanguagename", "community","resulthostingdatasource","collectedfrom" ]; |
12 | 16 |
|
13 | 17 |
public RESULT_ADVANCED_FIELDS:string[] = ["q","resulttitle","resultauthor", "authorid","resultdescription","resultsubject","resultpublisher", |
... | ... | |
16 | 20 |
"relfundinglevel0_id","relfundinglevel1_id","relfundinglevel2_id", |
17 | 21 |
"resultlanguagename", "relorganizationid", "pid","relprojectid", "instancetypename"]; |
18 | 22 |
public RESULT_FIELDS: { [key:string]:FieldDetails}={ |
19 |
["q"]:{name:"All fields", type:"keyword", param:"q", operator: "op", equalityOperator: "=", uniqueValue: false}, |
|
20 |
["resulttitle"]:{name:"Title", type:"keyword", param:"title", operator: "tt", equalityOperator: "=", uniqueValue: false}, |
|
21 |
["resultauthor"]:{name:"Author", type:"keyword", param:"author", operator: "at", equalityOperator: "=", uniqueValue: false}, |
|
22 |
["authorid"]:{name:"Author ORCID", type:"keyword", param:"orcid", operator: "oc", equalityOperator: " exact ", uniqueValue: false}, |
|
23 |
["resultsubject"]:{name:"Subject", type:"keyword", param:"subject", operator: "sb", equalityOperator: "=", uniqueValue: false}, |
|
24 |
["resultdescription"]:{name:"Description", type:"keyword", param:"description", operator: "ds", equalityOperator: "=", uniqueValue: false}, |
|
25 |
["resultpublisher"]:{name:"Publisher", type:"keyword", param:"publisher", operator: "pb", equalityOperator: "=", uniqueValue: false}, |
|
26 |
["pid"]:{name:"PID", type:"keyword", param:"pid", operator: "pd", equalityOperator: " = ", uniqueValue: false}, |
|
27 |
["resulthostingdatasourceid"]:{name:"Hosting Content Provider", type:"entity", param:"hostedBy", operator: "hs", equalityOperator: " exact ", uniqueValue: false}, |
|
28 |
["resulthostingdatasource"]:{name:"Content Provider", type:"refine", param:"hostedBy", operator: "hs", equalityOperator: " exact ", uniqueValue: false}, |
|
29 |
["instancetypename"]:{name:"Type", type:"vocabulary", param:"type", operator: "tp", equalityOperator: " exact ", uniqueValue: false}, |
|
30 |
["resultlanguagename"]:{name:"Language", type:"vocabulary", param:"lang", operator: "ln", equalityOperator: " exact ", uniqueValue: false}, |
|
31 |
["community"]:{name:"Community", type:"refine", param:"community", operator: "cm", equalityOperator: " exact ", uniqueValue: false}, |
|
32 |
["relproject"]:{name:"Project", type:"refine", param:"project", operator: "po", equalityOperator: " exact ", uniqueValue: false}, |
|
33 |
["relprojectid"]:{name:"Project", type:"entity", param:"project", operator: "po", equalityOperator: " exact ", uniqueValue: false}, |
|
34 |
["relfunder"]:{name:"Funder", type:"refine", param:"funder", operator: "fn", equalityOperator: " exact ", uniqueValue: false}, |
|
35 |
["relfundinglevel0_id"]:{name:"Funding Stream", type:"refine", param:"funderlv0", operator: "fn0", equalityOperator: " exact ", uniqueValue: false}, |
|
36 |
["relfundinglevel1_id"]:{name:"Funding Substream level 1", type:"refine", param:"funderlv1", operator: "fn1", equalityOperator: " exact ", uniqueValue: false}, |
|
37 |
["relfundinglevel2_id"]:{name:"Funding Substream level 2", type:"refine", param:"funderlv2", operator: "fn0", equalityOperator: " exact ", uniqueValue: false}, |
|
38 |
["resultacceptanceyear"]:{name:"Publication Date", type:"keyword", param:"year", operator: "ya", equalityOperator: " exact ", uniqueValue: false}, |
|
39 |
["resultdateofacceptance"]:{name:"Publication Date", type:"date", param:"date", operator: "dt", equalityOperator: " within ", uniqueValue: false}, |
|
40 |
["resultbestaccessright"]:{name:"Access Mode", type:"vocabulary", param:"access", operator: "ac", equalityOperator: " exact ", uniqueValue: false}, |
|
41 |
["collectedfrom"]:{name:"Collected From", type:"refine", param:"datasource", operator: "cl", equalityOperator: " exact ", uniqueValue: false}, |
|
42 |
["relorganizationid"]:{name:"Organization", type:"entity", param:"organization", operator: "og", equalityOperator: " exact ", uniqueValue: false}, |
|
43 |
["collectedfromdatasourceid"]:{name:"Collected from Content Provider", type:"entity", param:"collectedFrom", operator: "cl", equalityOperator: " exact ", uniqueValue: false} |
|
23 |
["q"]:{name:"All fields", type:"keyword", param:"q", operator: "op", equalityOperator: "=", filterType: null}, |
|
24 |
["resulttitle"]:{name:"Title", type:"keyword", param:"title", operator: "tt", equalityOperator: "=", filterType: null}, |
|
25 |
["resultauthor"]:{name:"Author", type:"keyword", param:"author", operator: "at", equalityOperator: "=", filterType: null}, |
|
26 |
["authorid"]:{name:"Author ORCID", type:"keyword", param:"orcid", operator: "oc", equalityOperator: " exact ", filterType: null}, |
|
27 |
["resultsubject"]:{name:"Subject", type:"keyword", param:"subject", operator: "sb", equalityOperator: "=", filterType: null}, |
|
28 |
["resultdescription"]:{name:"Description", type:"keyword", param:"description", operator: "ds", equalityOperator: "=", filterType: null}, |
|
29 |
["resultpublisher"]:{name:"Publisher", type:"keyword", param:"publisher", operator: "pb", equalityOperator: "=", filterType: null}, |
|
30 |
["pid"]:{name:"PID", type:"keyword", param:"pid", operator: "pd", equalityOperator: " = ", filterType: null}, |
|
31 |
["resulthostingdatasourceid"]:{name:"Hosting Content Provider", type:"entity", param:"hostedBy", operator: "hs", equalityOperator: " exact ", filterType: null}, |
|
32 |
["resulthostingdatasource"]:{name:"Content Provider", type:"refine", param:"hostedBy", operator: "hs", equalityOperator: " exact ", filterType: "checkbox"}, |
|
33 |
["instancetypename"]:{name:"Type", type:"vocabulary", param:"type", operator: "tp", equalityOperator: " exact ", filterType: "checkbox"}, |
|
34 |
["resultlanguagename"]:{name:"Language", type:"vocabulary", param:"lang", operator: "ln", equalityOperator: " exact ", filterType: "checkbox"}, |
|
35 |
["community"]:{name:"Community", type:"refine", param:"community", operator: "cm", equalityOperator: " exact ", filterType: "checkbox"}, |
|
36 |
["relproject"]:{name:"Project", type:"refine", param:"project", operator: "po", equalityOperator: " exact ", filterType: "checkbox"}, |
|
37 |
["relprojectid"]:{name:"Project", type:"entity", param:"project", operator: "po", equalityOperator: " exact ", filterType: null}, |
|
38 |
["relfunder"]:{name:"Funder", type:"refine", param:"funder", operator: "fn", equalityOperator: " exact ", filterType: "checkbox"}, |
|
39 |
["relfundinglevel0_id"]:{name:"Funding Stream", type:"refine", param:"funderlv0", operator: "fn0", equalityOperator: " exact ", filterType: "checkbox"}, |
|
40 |
["relfundinglevel1_id"]:{name:"Funding Substream level 1", type:"refine", param:"funderlv1", operator: "fn1", equalityOperator: " exact ", filterType: "checkbox"}, |
|
41 |
["relfundinglevel2_id"]:{name:"Funding Substream level 2", type:"refine", param:"funderlv2", operator: "fn0", equalityOperator: " exact ", filterType: "checkbox"}, |
|
42 |
["resultacceptanceyear"]:{name:"Publication Date", type:"keyword", param:"year", operator: "ya", equalityOperator: " = ", filterType: null}, |
|
43 |
["resultdateofacceptance"]:{name:"Publication Date", type:"date", param:"date", operator: "dt", equalityOperator: " exact ", filterType: null}, |
|
44 |
["resultacceptanceyear-range-resultacceptanceyear"]:{name:"Published between", type:"keyword", param:"year", operator: "ya", equalityOperator: " within ", filterType: "range"}, |
|
45 |
["resultbestaccessright"]:{name:"Access Mode", type:"vocabulary", param:"access", operator: "ac", equalityOperator: " exact ", filterType: "radio"}, |
|
46 |
["collectedfrom"]:{name:"Collected From", type:"refine", param:"datasource", operator: "cl", equalityOperator: " exact ", filterType: "checkbox"}, |
|
47 |
["relorganizationid"]:{name:"Organization", type:"entity", param:"organization", operator: "og", equalityOperator: " exact ", filterType: null}, |
|
48 |
["collectedfromdatasourceid"]:{name:"Collected from Content Provider", type:"entity", param:"collectedFrom", operator: "cl", equalityOperator: " exact ", filterType: null} |
|
44 | 49 |
}; |
45 | 50 |
|
46 | 51 |
//PROJECT |
47 |
|
|
52 |
public PROJECT_RANGE_FIELDS = [ |
|
53 |
["projectendyear", "projectstartyear"] |
|
54 |
]; |
|
48 | 55 |
public PROJECT_REFINE_FIELDS:string[] = ["funder","fundinglevel0_id","fundinglevel1_id", |
49 | 56 |
"fundinglevel2_id","projectstartyear","projectendyear","projectecsc39"]; |
50 | 57 |
public PROJECT_ADVANCED_FIELDS:string[] = ["q","projectacronym","projecttitle","projectkeywords", |
... | ... | |
52 | 59 |
"projectstartdate","projectenddate","projectecsc39", |
53 | 60 |
"projectcode_nt","relorganizationid", "collectedfromdatasourceid"]; |
54 | 61 |
public PROJECT_FIELDS: { [key:string]:FieldDetails}={ |
55 |
["q"]:{name:"All fields", type:"keyword", param:"q", operator: "op", equalityOperator: "=", uniqueValue: false},
|
|
56 |
["projectacronym"]:{name:"Acronym", type:"keyword", param:"acronym", operator: "ar", equalityOperator: "=", uniqueValue: false},
|
|
57 |
["projecttitle"]:{name:"Title", type:"keyword", param:"title", operator: "tt", equalityOperator: "=", uniqueValue: false},
|
|
58 |
["projectkeywords"]:{name:"Keywords", type:"keyword", param:"keywords", operator: "ky", equalityOperator: "=", uniqueValue: false},
|
|
62 |
["q"]:{name:"All fields", type:"keyword", param:"q", operator: "op", equalityOperator: "=", filterType: null},
|
|
63 |
["projectacronym"]:{name:"Acronym", type:"keyword", param:"acronym", operator: "ar", equalityOperator: "=", filterType: null},
|
|
64 |
["projecttitle"]:{name:"Title", type:"keyword", param:"title", operator: "tt", equalityOperator: "=", filterType: null},
|
|
65 |
["projectkeywords"]:{name:"Keywords", type:"keyword", param:"keywords", operator: "ky", equalityOperator: "=", filterType: null},
|
|
59 | 66 |
|
60 |
["funder"]:{name:"Funder", type:"refine", param:"funder", operator: "fn", equalityOperator: " exact ", uniqueValue: false}, |
|
61 |
["fundinglevel0_id"]:{name:"Funding Stream", type:"refine", param:"funderlv0", operator: "fn0", equalityOperator: " exact ", uniqueValue: false}, |
|
62 |
["fundinglevel1_id"]:{name:"Funding Substream level 1", type:"refine", param:"funderlv1", operator: "fn1", equalityOperator: " exact ", uniqueValue: false}, |
|
63 |
["fundinglevel2_id"]:{name:"Funding Substream level 2", type:"refine", param:"funderlv2", operator: "fn2", equalityOperator: " exact ", uniqueValue: false}, |
|
64 |
["projectstartyear"]:{name:"Start Year", type:"year", param:"startyear", operator: "sy", equalityOperator: " exact ", uniqueValue: false}, |
|
65 |
["projectendyear"]:{name:"End Year", type:"year", param:"endyear", operator: "ey", equalityOperator: " exact ", uniqueValue: false}, |
|
66 |
["projectstartdate"]:{name:"Start Date", type:"date", param:"startdate", operator: "sd", equalityOperator: " within ", uniqueValue: false}, |
|
67 |
["projectenddate"]:{name:"End Date", type:"date", param:"enddate", operator: "ed", equalityOperator: " within ", uniqueValue: false}, |
|
68 |
["projectecsc39"]:{name:"Special Clause 39", type:"boolean", param:"sc39", operator: "sc", equalityOperator: " exact ", uniqueValue: false}, |
|
69 |
["projectcode_nt"]:{name:"Project Code", type:"keyword", param:"code", operator: "cd", equalityOperator: " exact ", uniqueValue: false}, |
|
70 |
["relorganizationid"]:{name:"Organization", type:"entity", param:"organization", operator: "og", equalityOperator: " exact ", uniqueValue: false}, |
|
71 |
["collectedfromdatasourceid"]:{name:"Collected from Content Provider", type:"entity", param:"collectedFrom", operator: "cl", equalityOperator: " exact ", uniqueValue: false} |
|
67 |
["funder"]:{name:"Funder", type:"refine", param:"funder", operator: "fn", equalityOperator: " exact ", filterType: "checkbox"}, |
|
68 |
["fundinglevel0_id"]:{name:"Funding Stream", type:"refine", param:"funderlv0", operator: "fn0", equalityOperator: " exact ", filterType: "checkbox"}, |
|
69 |
["fundinglevel1_id"]:{name:"Funding Substream level 1", type:"refine", param:"funderlv1", operator: "fn1", equalityOperator: " exact ", filterType: "checkbox"}, |
|
70 |
["fundinglevel2_id"]:{name:"Funding Substream level 2", type:"refine", param:"funderlv2", operator: "fn2", equalityOperator: " exact ", filterType: "checkbox"}, |
|
71 |
["projectstartyear"]:{name:"Start Year", type:"year", param:"startyear", operator: "sy", equalityOperator: " <= ", filterType: "checkbox"}, |
|
72 |
["projectendyear"]:{name:"End Year", type:"year", param:"endyear", operator: "ey", equalityOperator: " >= ", filterType: "checkbox"}, |
|
73 |
["projectendyear-range-projectstartyear"]:{name:"Active years", type:"year", param:"year", operator: "ya", equalityOperator: " = ", filterType: "range"}, |
|
74 |
["projectstartdate"]:{name:"Start Date", type:"date", param:"startdate", operator: "sd", equalityOperator: " within ", filterType: null}, |
|
75 |
["projectenddate"]:{name:"End Date", type:"date", param:"enddate", operator: "ed", equalityOperator: " within ", filterType: null}, |
|
76 |
["projectecsc39"]:{name:"Special Clause 39", type:"boolean", param:"sc39", operator: "sc", equalityOperator: " exact ", filterType: "radio"}, |
|
77 |
["projectcode_nt"]:{name:"Project Code", type:"keyword", param:"code", operator: "cd", equalityOperator: " exact ", filterType: null}, |
|
78 |
["relorganizationid"]:{name:"Organization", type:"entity", param:"organization", operator: "og", equalityOperator: " exact ", filterType: null}, |
|
79 |
["collectedfromdatasourceid"]:{name:"Collected from Content Provider", type:"entity", param:"collectedFrom", operator: "cl", equalityOperator: " exact ", filterType: null} |
|
72 | 80 |
|
73 | 81 |
}; |
74 | 82 |
|
... | ... | |
81 | 89 |
"datasourceodcontenttypes", "datasourcecompatibilityname","relorganizationid", "collectedfromdatasourceid"]; |
82 | 90 |
|
83 | 91 |
public DATASOURCE_FIELDS: { [key:string]:FieldDetails}={ |
84 |
["q"]:{name:"All fields", type:"keyword", param:"q", operator: "op", equalityOperator: "=", uniqueValue: false},
|
|
85 |
["datasourceofficialname"]:{name:"English name", type:"keyword", param:"officialname", operator: "of", equalityOperator: "=", uniqueValue: false},
|
|
86 |
["datasourceenglishname"]:{name:"Title", type:"keyword", param:"engname", operator: "eg", equalityOperator: "=", uniqueValue: false},
|
|
87 |
["datasourceodsubjects"]:{name:"Subject", type:"keyword", param:"subjects", operator: "sb", equalityOperator: "=", uniqueValue: false},
|
|
88 |
["datasourcetypeuiid"]:{name:"Type", type:"refine", param:"type", operator: "tp", equalityOperator: " exact ", uniqueValue: false},
|
|
89 |
["datasourcetypeuiname"]:{name:"Type", type:"refine", param:"type", operator: "tp", equalityOperator: " exact ", uniqueValue: false},
|
|
90 |
["datasourcetypename"]:{name:"Type", type:"vocabulary", param:"type", operator: "tp", equalityOperator: " exact ", uniqueValue: false},
|
|
91 |
["datasourceodlanguages"]:{name:"Language", type:"vocabulary", param:"lang", operator: "ln", equalityOperator: " exact ", uniqueValue: false},
|
|
92 |
["datasourceodcontenttypes"]:{name:"Content", type:"refine", param:"content", operator: "cn", equalityOperator: " exact ", uniqueValue: false},
|
|
93 |
["datasourcecompatibilityid"]:{name:"Compatibility Level", type:"refine", param:"compatibility", operator: "cm", equalityOperator: " exact ", uniqueValue: false},
|
|
94 |
["datasourcecompatibilityname"]:{name:"Compatibility Level", type:"vocabulary", param:"compatibility", operator: "cm", equalityOperator: " exact ", uniqueValue: false},
|
|
95 |
["relorganizationid"]:{name:"Organization", type:"entity", param:"organization", operator: "og", equalityOperator: " exact ", uniqueValue: false},
|
|
96 |
["collectedfromdatasourceid"]:{name:"Collected from Content Provider", type:"entity", param:"collectedFrom", operator: "cl", equalityOperator: " exact ", uniqueValue: false},
|
|
97 |
["country"]:{name:"Country", type:"vocabulary", param:"country", operator: "cu", equalityOperator: "=", uniqueValue: false}
|
|
92 |
["q"]:{name:"All fields", type:"keyword", param:"q", operator: "op", equalityOperator: "=", filterType: null},
|
|
93 |
["datasourceofficialname"]:{name:"English name", type:"keyword", param:"officialname", operator: "of", equalityOperator: "=", filterType: null},
|
|
94 |
["datasourceenglishname"]:{name:"Title", type:"keyword", param:"engname", operator: "eg", equalityOperator: "=", filterType: null},
|
|
95 |
["datasourceodsubjects"]:{name:"Subject", type:"keyword", param:"subjects", operator: "sb", equalityOperator: "=", filterType: null},
|
|
96 |
["datasourcetypeuiid"]:{name:"Type", type:"refine", param:"type", operator: "tp", equalityOperator: " exact ", filterType: null},
|
|
97 |
["datasourcetypeuiname"]:{name:"Type", type:"refine", param:"type", operator: "tp", equalityOperator: " exact ", filterType: "checkbox"},
|
|
98 |
["datasourcetypename"]:{name:"Type", type:"vocabulary", param:"type", operator: "tp", equalityOperator: " exact ", filterType: null},
|
|
99 |
["datasourceodlanguages"]:{name:"Language", type:"vocabulary", param:"lang", operator: "ln", equalityOperator: " exact ", filterType: "checkbox"},
|
|
100 |
["datasourceodcontenttypes"]:{name:"Content", type:"refine", param:"content", operator: "cn", equalityOperator: " exact ", filterType: "checkbox"},
|
|
101 |
["datasourcecompatibilityid"]:{name:"Compatibility Level", type:"refine", param:"compatibility", operator: "cm", equalityOperator: " exact ", filterType: null},
|
|
102 |
["datasourcecompatibilityname"]:{name:"Compatibility Level", type:"vocabulary", param:"compatibility", operator: "cm", equalityOperator: " exact ", filterType: "checkbox"},
|
|
103 |
["relorganizationid"]:{name:"Organization", type:"entity", param:"organization", operator: "og", equalityOperator: " exact ", filterType: null},
|
|
104 |
["collectedfromdatasourceid"]:{name:"Collected from Content Provider", type:"entity", param:"collectedFrom", operator: "cl", equalityOperator: " exact ", filterType: null},
|
|
105 |
["country"]:{name:"Country", type:"vocabulary", param:"country", operator: "cu", equalityOperator: "=", filterType: "checkbox"}
|
|
98 | 106 |
}; |
99 | 107 |
|
100 | 108 |
public DEPOSIT_DATASOURCE_KEYWORD_FIELDS: { "name": string, "equalityOperator": string} []= [ |
... | ... | |
109 | 117 |
public DEPOSIT_DATASOURCE_REFINE_FIELDS:string[] = ["datasourcetypeuiname", "country", "datasourceodsubjects", "datasourceodcontenttypes", "datasourcecompatibilityname"]; |
110 | 118 |
|
111 | 119 |
public DEPOSIT_DATASOURCE_FIELDS: { [key:string]:FieldDetails}={ |
112 |
["datasourcetypeuiname"]:{name:"Repository type", type:"refine", param:"type", operator: "tp", equalityOperator: " exact ", uniqueValue: true},
|
|
113 |
["country"]:{name:"Countries", type:"vocabulary", param:"country", operator: "cu", equalityOperator: "=", uniqueValue: false},
|
|
114 |
["datasourceodsubjects"]:{name:"Subjects", type:"keyword", param:"subjects", operator: "sb", equalityOperator: "=", uniqueValue: false},
|
|
115 |
["datasourceodcontenttypes"]:{name:"Content type", type:"refine", param:"content", operator: "cn", equalityOperator: " exact ", uniqueValue: false},
|
|
116 |
["datasourcecompatibilityname"]:{name:"Compatibility Level", type:"vocabulary", param:"compatibility", operator: "cm", equalityOperator: " exact ", uniqueValue: true},
|
|
120 |
["datasourcetypeuiname"]:{name:"Repository type", type:"refine", param:"type", operator: "tp", equalityOperator: " exact ", filterType: "radio"},
|
|
121 |
["country"]:{name:"Countries", type:"vocabulary", param:"country", operator: "cu", equalityOperator: "=", filterType: "checkbox"},
|
|
122 |
["datasourceodsubjects"]:{name:"Subjects", type:"keyword", param:"subjects", operator: "sb", equalityOperator: "=", filterType: "checkbox"},
|
|
123 |
["datasourceodcontenttypes"]:{name:"Content type", type:"refine", param:"content", operator: "cn", equalityOperator: " exact ", filterType: "checkbox"},
|
|
124 |
["datasourcecompatibilityname"]:{name:"Compatibility Level", type:"vocabulary", param:"compatibility", operator: "cm", equalityOperator: " exact ", filterType: "checkbox"},
|
|
117 | 125 |
}; |
118 | 126 |
|
119 | 127 |
public COMPATIBLE_DATAPROVIDER_FIELDS:string[] = ["datasourcetypeuiid","datasourcecompatibilityname"]; |
... | ... | |
126 | 134 |
public ORGANIZATION_ADVANCED_FIELDS:string[] = ["q", "organizationlegalname","organizationlegalshortname","country"]; |
127 | 135 |
|
128 | 136 |
public ORGANIZATION_FIELDS: { [key:string]:FieldDetails}={ |
129 |
["q"]:{name:"All fields", type:"keyword", param:"q", operator:"op", equalityOperator: "=", uniqueValue: false},
|
|
130 |
["organizationlegalname"]:{name:"Legal Name", type:"keyword", param:"name", operator: "nm", equalityOperator: "=", uniqueValue: false},
|
|
131 |
["organizationlegalshortname"]:{name:"Legal Short Name", type:"keyword", param:"shortname", operator: "so", equalityOperator: "=", uniqueValue: false},
|
|
132 |
["country"]:{name:"Country", type:"vocabulary", param:"country", operator: "cu", equalityOperator: "=", uniqueValue: false},
|
|
137 |
["q"]:{name:"All fields", type:"keyword", param:"q", operator:"op", equalityOperator: "=", filterType: null},
|
|
138 |
["organizationlegalname"]:{name:"Legal Name", type:"keyword", param:"name", operator: "nm", equalityOperator: "=", filterType: null},
|
|
139 |
["organizationlegalshortname"]:{name:"Legal Short Name", type:"keyword", param:"shortname", operator: "so", equalityOperator: "=", filterType: null},
|
|
140 |
["country"]:{name:"Country", type:"vocabulary", param:"country", operator: "cu", equalityOperator: "=", filterType: "checkbox"},
|
|
133 | 141 |
}; |
134 | 142 |
// public ORGANIZATION_INDEX:string[] = ["organizationcountryname"]//,"organizationeclegalbody"]; |
135 | 143 |
// public ADVANCED_SEARCH_ORGANIZATION_PARAM:string[] = ["q","contenttype","compatibility","country","type"]; |
... | ... | |
173 | 181 |
} |
174 | 182 |
} |
175 | 183 |
|
176 |
fieldHasUniqueValue(fieldId:string,fieldType:string,usedBy:string="search"):boolean{
|
|
184 |
getFieldFilterType(fieldId:string, fieldType:string, usedBy:string="search"):string{
|
|
177 | 185 |
if(fieldType == "publication" || fieldType == "dataset" || fieldType == "software" || fieldType == "other"|| fieldType == "result"){ |
178 |
return this.RESULT_FIELDS[fieldId].uniqueValue;
|
|
186 |
return this.RESULT_FIELDS[fieldId].filterType;
|
|
179 | 187 |
}else if(fieldType == "project"){ |
180 |
return this.PROJECT_FIELDS[fieldId].uniqueValue;
|
|
188 |
return this.PROJECT_FIELDS[fieldId].filterType;
|
|
181 | 189 |
}else if(fieldType == "organization"){ |
182 |
return this.ORGANIZATION_FIELDS[fieldId].uniqueValue;
|
|
190 |
return this.ORGANIZATION_FIELDS[fieldId].filterType;
|
|
183 | 191 |
}else if(fieldType == "datasource" || fieldType == "dataprovider"){ |
184 | 192 |
if(usedBy == "search") { |
185 |
return this.DATASOURCE_FIELDS[fieldId].uniqueValue;
|
|
193 |
return this.DATASOURCE_FIELDS[fieldId].filterType;
|
|
186 | 194 |
} else if(usedBy == "deposit") { |
187 |
return this.DEPOSIT_DATASOURCE_FIELDS[fieldId].uniqueValue;
|
|
195 |
return this.DEPOSIT_DATASOURCE_FIELDS[fieldId].filterType;
|
|
188 | 196 |
} |
189 | 197 |
}else{ |
190 |
return false;
|
|
198 |
return "checkbox";
|
|
191 | 199 |
} |
192 | 200 |
} |
193 | 201 |
|
202 |
getFieldParam(fieldId:string,fieldType:string):string{ |
|
203 |
if(fieldType == "publication" || fieldType == "dataset" || fieldType == "software" || fieldType == "other" || fieldType == "result"){ |
|
204 |
return this.RESULT_FIELDS[fieldId].param; |
|
205 |
}else if(fieldType == "project"){ |
|
206 |
return this.PROJECT_FIELDS[fieldId].param; |
|
207 |
}else if(fieldType == "organization"){ |
|
208 |
return this.ORGANIZATION_FIELDS[fieldId].param; |
|
209 |
}else if(fieldType == "datasource" || fieldType == "dataprovider"){ |
|
210 |
return this.DATASOURCE_FIELDS[fieldId].param; |
|
211 |
}else{ |
|
212 |
return "UNDEFINED"; |
|
213 |
} |
|
214 |
} |
|
215 |
|
|
194 | 216 |
/* |
195 | 217 |
AND |
196 | 218 |
Funder: relfunder, relfundinglevel0_id, relfundinglevel1_id, relfundinglevel2_id |
... | ... | |
220 | 242 |
|
221 | 243 |
getFieldOperator(fieldId:string):string{ |
222 | 244 |
if(fieldId == "relfunder" || fieldId == "relfundinglevel0_id" || fieldId == "relfundinglevel1_id" || fieldId == "relfundinglevel2_id" |
223 |
|| fieldId == "relproject" || fieldId == "community") { |
|
245 |
|| fieldId == "relproject" || fieldId == "community" || fieldId == "projectendyear-range-projectstartyear") {
|
|
224 | 246 |
return "and"; |
225 | 247 |
} else if(fieldId == "instancetypename" || fieldId == "datasourcetypeuiname" |
226 | 248 |
|| fieldId == "resultlanguagename" || fieldId == "datasourceodlanguages" |
... | ... | |
237 | 259 |
param:string; |
238 | 260 |
equalityOperator:string; |
239 | 261 |
operator:string; |
240 |
uniqueValue: boolean = false;
|
|
262 |
filterType: string = "checkbox";
|
|
241 | 263 |
} |
Also available in: Unified diff
[Library | Landing redesign]: Merge from trunk