Add optional filtering on groups

pull/941/head
M 2025-05-26 15:09:49 +02:00
parent 6bf4ed0592
commit 0f168f87c2
1 changed files with 5 additions and 0 deletions

View File

@ -42,6 +42,11 @@ export default {
this.api = await this.fetch("/api/v1/endpoints/statuses", { method: "GET", cache: "no-cache" }).catch((e) => {
console.error(e);
});
if (this.item.groups) {
this.api = this.api?.filter((job) => {
return this.item.groups.includes(job.group) === true;
})
}
},
countUp: function() {
if (!this.api) {