Add documentation of template system.
[mkws-moved-to-github.git] / tools / htdocs / mkws.js
index 67bedc6..281f5b2 100644 (file)
@@ -470,7 +470,12 @@ function triggerSearch (query, sort, targets)
        if (filter.id) {
            if (pp2filter)
                pp2filter += ",";
-           pp2filter += 'pz:id=' + filter.id;
+           if (filter.id.match(/^[a-z:]+[=~]/)) {
+               debug("filter '" + filter.id + "' already begins with SETTING OP");
+           } else {
+               filter.id = 'pz:id=' + filter.id;
+           }
+           pp2filter += filter.id;
        } else {
            if (pp2limit)
                pp2limit += ",";