Skip to content
Snippets Groups Projects
Verified Commit d829a342 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

feat(datatable): new tag-list callback

parent ae366778
No related branches found
No related tags found
No related merge requests found
...@@ -52,11 +52,11 @@ ...@@ -52,11 +52,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1738271129, "lastModified": 1738272818,
"narHash": "sha256-cktd+pC9HKAgXIeB5kA9cuVvbAFEifvWOqQtRRGcV1A=", "narHash": "sha256-KuaKPkPBHq6ljlqXSAYwc1i1RvZ6tDOmRHytfYtY6jc=",
"ref": "refs/heads/master", "ref": "refs/heads/master",
"rev": "c24bd8c557d043ae096fcd7fb2db7bf6614652cd", "rev": "c89890f1c4dfbc0e2909651d99cd11cc6f735255",
"revCount": 3, "revCount": 4,
"type": "git", "type": "git",
"url": "https://gitlab.schukai.com/schukai/entwicklung/nix-flake-common" "url": "https://gitlab.schukai.com/schukai/entwicklung/nix-flake-common"
}, },
...@@ -166,11 +166,11 @@ ...@@ -166,11 +166,11 @@
}, },
"nixpkgs_3": { "nixpkgs_3": {
"locked": { "locked": {
"lastModified": 1738163270, "lastModified": 1738435198,
"narHash": "sha256-B/7Y1v4y+msFFBW1JAdFjNvVthvNdJKiN6EGRPnqfno=", "narHash": "sha256-5+Hmo4nbqw8FrW85FlNm4IIrRnZ7bn0cmXlScNsNRLo=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "59e618d90c065f55ae48446f307e8c09565d5ab0", "rev": "f6687779bf4c396250831aa5a32cbfeb85bb07a3",
"type": "github" "type": "github"
}, },
"original": { "original": {
......
This diff is collapsed.
...@@ -32,7 +32,7 @@ import { Settings } from "./filter/settings.mjs"; ...@@ -32,7 +32,7 @@ import { Settings } from "./filter/settings.mjs";
import { FilterStyleSheet } from "./stylesheet/filter.mjs"; import { FilterStyleSheet } from "./stylesheet/filter.mjs";
import { getDocument, getWindow } from "../../dom/util.mjs"; import { getDocument, getWindow } from "../../dom/util.mjs";
import { getGlobal } from "../../types/global.mjs"; import { getGlobal } from "../../types/global.mjs";
import { isInstance, isFunction, isObject, isArray } from "../../types/is.mjs"; import {isInstance, isFunction, isObject, isArray, isString} from "../../types/is.mjs";
import { Host } from "../host/host.mjs"; import { Host } from "../host/host.mjs";
import { addAttributeToken } from "../../dom/attributes.mjs"; import { addAttributeToken } from "../../dom/attributes.mjs";
import { ATTRIBUTE_ERRORMESSAGE } from "../../dom/constants.mjs"; import { ATTRIBUTE_ERRORMESSAGE } from "../../dom/constants.mjs";
...@@ -1204,6 +1204,22 @@ function collectSearchQueries() { ...@@ -1204,6 +1204,22 @@ function collectSearchQueries() {
ltOp: "<", ltOp: "<",
}); });
}, },
"tag-list": (value, key) => {
if(isString(value)) {
value = value.split(",");
}
if (!isArray(value)) {
return "";
}
return key+" IN "+value
.map((v) => {
return `"${encodeURIComponent(v)}"`;
})
.join(",");
},
"date-range": (value, key) => { "date-range": (value, key) => {
const query = parseDateInput(value, key); const query = parseDateInput(value, key);
if (!query || query === "false") { if (!query || query === "false") {
......
...@@ -45,9 +45,9 @@ class FilterSelect extends Select { ...@@ -45,9 +45,9 @@ class FilterSelect extends Select {
get defaults() { get defaults() {
return Object.assign({}, super.defaults, { return Object.assign({}, super.defaults, {
type: "checkbox", type: "checkbox",
templateMapping: { // templateMapping: {
selected: getSummaryTemplate(), // selected: getSummaryTemplate(),
}, // },
}); });
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment