mirror of
https://github.com/LCPQ/QUESTDB_website.git
synced 2024-12-25 05:43:46 +01:00
Delete SI from select
This commit is contained in:
parent
0131432b07
commit
7987fb11df
@ -66,8 +66,8 @@ draft: false
|
||||
}
|
||||
async function loadFiles() {
|
||||
processingIndicator.isActive = true
|
||||
var chks=[]
|
||||
var chks = $("#form_datFiles > ul > ul > li >input[type=checkbox]:checked")
|
||||
var chks = []
|
||||
var chks = $("#form_datFiles > ul > ul > li >input[type=checkbox]:checked")
|
||||
var proms = Array.from(chks).flatMap((c) => {
|
||||
switch (c.value) {
|
||||
case "abs":
|
||||
@ -121,6 +121,8 @@ draft: false
|
||||
break;
|
||||
case "basis":
|
||||
return d.method.basis
|
||||
case "DOI":
|
||||
return d.DOI.string
|
||||
default:
|
||||
return d[$(this).attr("name")]
|
||||
break;
|
||||
@ -129,25 +131,9 @@ draft: false
|
||||
var sets = await getSets()
|
||||
for (const val of vals) {
|
||||
if (val !== null) {
|
||||
var op = $("<option/>", {
|
||||
$("<option/>", {
|
||||
value: JSON.stringify(val)
|
||||
})
|
||||
if ($(this).attr("name") == "DOI") {
|
||||
if (sets.has(val.string)) {
|
||||
str = sets.get(val.string)
|
||||
if (val.IsSupporting) {
|
||||
str += " (SI)"
|
||||
}
|
||||
}
|
||||
else {
|
||||
str = val.toString()
|
||||
}
|
||||
$(op).text(str)
|
||||
}
|
||||
else {
|
||||
$(op).text(val.toString())
|
||||
}
|
||||
op.appendTo(this)
|
||||
}).text(($(this).attr("name")==="DOI" && sets.has(val)) ? sets.get(val) : val.toString()).appendTo(this)
|
||||
}
|
||||
}
|
||||
})
|
||||
@ -282,6 +268,9 @@ draft: false
|
||||
case "basis":
|
||||
val = d.method.basis
|
||||
break;
|
||||
case "DOI":
|
||||
val = d.DOI.string
|
||||
break;
|
||||
default:
|
||||
val = d[prop]
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user