Loading public/javascript/app/designs/base/_ServiceOGC.js +9 −3 Original line number Diff line number Diff line Loading @@ -30,13 +30,15 @@ define([ _setMainConfigurations: function() { var atlasSearchFields = ['title.suggest', 'alias.suggest', 'keywords.suggest'], var atlasHighlightFields = ['title.suggest', 'alias.suggest'], atlasSearchFields = ['title.suggest', 'alias.suggest', 'keywords.suggest'], atlasSuggestFields = ['title', 'alias', 'keywords']; this.textSearchConfig = this._merge([{ highlightField: atlasSearchFields, highlightField: atlasHighlightFields, suggestFields: atlasSuggestFields, searchFields: atlasSearchFields searchFields: atlasSearchFields, legacyMode: false }, this.textSearchConfig || {}]); this.filterConfig = this._merge([{ Loading Loading @@ -73,6 +75,10 @@ define([ _handleFilterParams: function(filterParams) { if (filterParams.suggest) { return; } this._requestAtlasData({ target: this.target, queryParams: filterParams Loading public/javascript/redmic/modules/search/TextImpl.js +26 −15 Original line number Diff line number Diff line Loading @@ -41,10 +41,12 @@ define([ SERIALIZED: "serialized" }, methodSuggest: "POST", action: "_suggest", suggestAction: "_suggest", searchAction: "_search", itemLabel: null, textValue: '', ownChannel: "textSearch" ownChannel: "textSearch", legacyMode: true }; lang.mixin(this, this.config, args); Loading Loading @@ -125,22 +127,11 @@ define([ }); this._once(this._buildChannel(this.queryChannel, this.actions.SERIALIZED), lang.hitch(this, this._subSerialized, evt)); lang.hitch(this, this._subSerialized, evt, this.suggestAction)); this._publish(this._buildChannel(this.queryChannel, this.actions.SERIALIZE)); }, _subSerialized: function(evt, req) { this._emitEvt('REQUEST', { target: this._getTarget(), action: this.action, requesterId: this.getOwnChannel(), method: this.methodSuggest, query: req.data }); }, _subRequested: function(req) { var query = req.query, Loading Loading @@ -188,7 +179,27 @@ define([ this._emitEvt('SEARCH', { text: this._createQuery(evt), from: 0 from: 0, omitRefresh: true }); //Por retrocompatibilidad se debe llamar a _subSerialized if (this.legacyMode) { this._once(this._buildChannel(this.queryChannel, this.actions.SERIALIZED), lang.hitch(this, this._subSerialized, evt, this.searchAction)); } this._publish(this._buildChannel(this.queryChannel, this.actions.SERIALIZE)); }, _subSerialized: function(evt, action, req) { this._emitEvt('REQUEST', { target: this._getTarget(), action: action, requesterId: this.getOwnChannel(), method: this.methodSuggest, query: req.data }); }, Loading Loading
public/javascript/app/designs/base/_ServiceOGC.js +9 −3 Original line number Diff line number Diff line Loading @@ -30,13 +30,15 @@ define([ _setMainConfigurations: function() { var atlasSearchFields = ['title.suggest', 'alias.suggest', 'keywords.suggest'], var atlasHighlightFields = ['title.suggest', 'alias.suggest'], atlasSearchFields = ['title.suggest', 'alias.suggest', 'keywords.suggest'], atlasSuggestFields = ['title', 'alias', 'keywords']; this.textSearchConfig = this._merge([{ highlightField: atlasSearchFields, highlightField: atlasHighlightFields, suggestFields: atlasSuggestFields, searchFields: atlasSearchFields searchFields: atlasSearchFields, legacyMode: false }, this.textSearchConfig || {}]); this.filterConfig = this._merge([{ Loading Loading @@ -73,6 +75,10 @@ define([ _handleFilterParams: function(filterParams) { if (filterParams.suggest) { return; } this._requestAtlasData({ target: this.target, queryParams: filterParams Loading
public/javascript/redmic/modules/search/TextImpl.js +26 −15 Original line number Diff line number Diff line Loading @@ -41,10 +41,12 @@ define([ SERIALIZED: "serialized" }, methodSuggest: "POST", action: "_suggest", suggestAction: "_suggest", searchAction: "_search", itemLabel: null, textValue: '', ownChannel: "textSearch" ownChannel: "textSearch", legacyMode: true }; lang.mixin(this, this.config, args); Loading Loading @@ -125,22 +127,11 @@ define([ }); this._once(this._buildChannel(this.queryChannel, this.actions.SERIALIZED), lang.hitch(this, this._subSerialized, evt)); lang.hitch(this, this._subSerialized, evt, this.suggestAction)); this._publish(this._buildChannel(this.queryChannel, this.actions.SERIALIZE)); }, _subSerialized: function(evt, req) { this._emitEvt('REQUEST', { target: this._getTarget(), action: this.action, requesterId: this.getOwnChannel(), method: this.methodSuggest, query: req.data }); }, _subRequested: function(req) { var query = req.query, Loading Loading @@ -188,7 +179,27 @@ define([ this._emitEvt('SEARCH', { text: this._createQuery(evt), from: 0 from: 0, omitRefresh: true }); //Por retrocompatibilidad se debe llamar a _subSerialized if (this.legacyMode) { this._once(this._buildChannel(this.queryChannel, this.actions.SERIALIZED), lang.hitch(this, this._subSerialized, evt, this.searchAction)); } this._publish(this._buildChannel(this.queryChannel, this.actions.SERIALIZE)); }, _subSerialized: function(evt, action, req) { this._emitEvt('REQUEST', { target: this._getTarget(), action: action, requesterId: this.getOwnChannel(), method: this.methodSuggest, query: req.data }); }, Loading