Update
This commit is contained in:
rodič
88878fed13
revize
5891875882
|
@ -37,6 +37,10 @@ class API {
|
||||||
description: sp.desc
|
description: sp.desc
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
const schedule = this.bundle.schedule.find(s => s.event === ev.id)
|
||||||
|
if (schedule) {
|
||||||
|
ev.scheduleId = '@' + schedule.id
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return this.bundle
|
return this.bundle
|
||||||
|
|
|
@ -106,6 +106,15 @@
|
||||||
arr = arr.filter((e) => e.track === f.key);
|
arr = arr.filter((e) => e.track === f.key);
|
||||||
}
|
}
|
||||||
if (f.type === "text") {
|
if (f.type === "text") {
|
||||||
|
if (f.key.substring(0,1) === '@') {
|
||||||
|
const schedule = bd.spec.schedule.find(e => e.id === f.key.substring(1))
|
||||||
|
if (schedule) {
|
||||||
|
const ev = bd.spec.events.find(e => e.id === schedule.event)
|
||||||
|
arr = [ev];
|
||||||
|
} else {
|
||||||
|
arr = [];
|
||||||
|
}
|
||||||
|
} else {
|
||||||
const sr = fuse.search(f.key);
|
const sr = fuse.search(f.key);
|
||||||
if (sr.length > 0) {
|
if (sr.length > 0) {
|
||||||
arr = sr
|
arr = sr
|
||||||
|
@ -116,6 +125,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
ids = arr.map((a) => a.id);
|
ids = arr.map((a) => a.id);
|
||||||
return arr;
|
return arr;
|
||||||
}
|
}
|
||||||
|
@ -126,6 +136,7 @@
|
||||||
//minMatchCharLength: 1,
|
//minMatchCharLength: 1,
|
||||||
threshold: 0.4,
|
threshold: 0.4,
|
||||||
keys: [
|
keys: [
|
||||||
|
{ name: "scheduleId", weight: 20 },
|
||||||
{ name: "name", weight: 10 },
|
{ name: "name", weight: 10 },
|
||||||
{ name: "description", weight: 7 },
|
{ name: "description", weight: 7 },
|
||||||
{ name: "speakers", weight: 5 },
|
{ name: "speakers", weight: 5 },
|
||||||
|
|
Načítá se…
Odkázat v novém úkolu