mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-31 17:38:28 +00:00
search fixes
This commit is contained in:
@@ -11,7 +11,6 @@
|
|||||||
<div class="inner-layout__content">
|
<div class="inner-layout__content">
|
||||||
<adf-search
|
<adf-search
|
||||||
#search
|
#search
|
||||||
[searchTerm]="searchedWord"
|
|
||||||
[maxResults]="maxItems"
|
[maxResults]="maxItems"
|
||||||
[skipResults]="skipCount"
|
[skipResults]="skipCount"
|
||||||
(resultLoaded)="onSearchResultLoaded($event)">
|
(resultLoaded)="onSearchResultLoaded($event)">
|
||||||
|
@@ -41,7 +41,6 @@ export class SearchComponent implements OnInit {
|
|||||||
search: AdfSearchComponent;
|
search: AdfSearchComponent;
|
||||||
|
|
||||||
queryParamName = 'q';
|
queryParamName = 'q';
|
||||||
searchedWord = '';
|
|
||||||
data: NodePaging;
|
data: NodePaging;
|
||||||
totalResults = 0;
|
totalResults = 0;
|
||||||
maxItems = 5;
|
maxItems = 5;
|
||||||
@@ -68,9 +67,9 @@ export class SearchComponent implements OnInit {
|
|||||||
|
|
||||||
if (this.route) {
|
if (this.route) {
|
||||||
this.route.params.forEach((params: Params) => {
|
this.route.params.forEach((params: Params) => {
|
||||||
this.searchedWord = params.hasOwnProperty(this.queryParamName) ? params[this.queryParamName] : null;
|
const searchedWord = params.hasOwnProperty(this.queryParamName) ? params[this.queryParamName] : null;
|
||||||
if (this.searchedWord) {
|
if (searchedWord) {
|
||||||
const queryBody = this.searchConfiguration.generateQueryBody(this.searchedWord, 0, 100);
|
const queryBody = this.searchConfiguration.generateQueryBody(searchedWord, 0, 100);
|
||||||
|
|
||||||
this.queryBuilder.userQuery = queryBody.query.query;
|
this.queryBuilder.userQuery = queryBody.query.query;
|
||||||
this.queryBuilder.update();
|
this.queryBuilder.update();
|
||||||
|
Reference in New Issue
Block a user