X-Git-Url: http://lists.indexdata.dk/cgi-bin?a=blobdiff_plain;f=src%2Fmkws-widget.js;h=566f60404c5a44ecf2781c8cb5397b98a944f565;hb=HEAD;hp=4cace293c2025351d227161f2968715517153d08;hpb=bfb0e43c8973ed41c33eed56bad6534771a1a3ae;p=mkws-moved-to-github.git diff --git a/src/mkws-widget.js b/src/mkws-widget.js index 4cace29..566f604 100644 --- a/src/mkws-widget.js +++ b/src/mkws-widget.js @@ -109,29 +109,12 @@ mkws.makeWidget = function($, team, type, node) { if (widget) { widget.node.val(query); } this.team.queue("ready").subscribe(function() { - // Postpone testing for the configuration items: these are not - // yet set for Record subclass widgets that fill them in in the - // subclass, as widget.autosearch is called in the superclass, - // before the subclass fiddles with the configuration. - var sortOrder = that.config.sort; - var maxrecs = that.config.maxrecs; - var perpage = that.config.perpage; - var limit = that.config.limit; - var targets = that.config.targets; - var targetfilter = that.config.targetfilter; - var target = that.config.target; - if (target) targetfilter = 'udb=="' + target + '"'; - - var s = "running auto search: '" + query + "'"; - if (sortOrder) s += " sorted by '" + sortOrder + "'"; - if (maxrecs) s += " restricted to " + maxrecs + " records"; - if (perpage) s += " with " + perpage + " per page"; - if (limit) s += " limited by '" + limit + "'"; - if (targets) s += " in targets '" + targets + "'"; - if (targetfilter) s += " constrained by targetfilter '" + targetfilter + "'"; - that.info(s); - - that.team.newSearch(query, sortOrder, maxrecs, perpage, limit, targets, targetfilter); + // Postpone search until the team is ready: configuration + // items are not yet set for Record subclass widgets that fill + // them in in the subclass, as widget.autosearch is called in + // the superclass, before the subclass fiddles with the + // configuration. + that.team.newSearch(that, query); }); } };