diff --git a/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.html b/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.html index fd4a63759777a12bdb84b02a46ffc149e4e153f8..c5400e93a852b299b6455783f2d6554394e7d1e0 100755 --- a/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.html +++ b/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.html @@ -1,6 +1,6 @@ <form (ngSubmit)="getCurrentCriteriaValues()" #criteriaFormUp="ngForm"> <mat-form-field *ngIf="!adminMode" floatLabel="never" class="basket-search"> - <input class="metaSearch" type="text" matInput + <input class="metaSearch" type="text" matInput [formControl]="searchTermControl" [placeholder]="'lang.quickSearch' |Â translate"> <button mat-icon-button matPrefix> <mat-icon class="fas fa-search"></mat-icon> @@ -15,8 +15,8 @@ <button type="button" mat-icon-button [matMenuTriggerFor]="menu" (menuOpened)="focusFilter()" (click)="$event.stopPropagation()" [title]="'lang.displayCriteria' | translate"> <mat-icon class="fa fa-plus"></mat-icon> </button> - <mat-menu #menu="matMenu"> - <div class="menuTitle" style="position: sticky;top: 0px;background: white;z-index: 1;"> + <mat-menu #menu="matMenu" class="searchTemplateMenu"> + <div class="menuTitle" style="position: sticky;top: 0px;background: white;z-index: 1;display: flex;justify-content: center;"> <mat-form-field floatLabel="never" appearance="outline" class="smallInput" (click)="$event.stopPropagation();" style="width: 220px !important; padding-top: 10px;"> <input matInput id="searchTerm" #searchCriteriaInput [formControl]="getFilterControl()" placeholder="{{'lang.filterBy' | translate}}" #listFilter autocomplete="off" (click)="$event.stopPropagation();" diff --git a/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.scss b/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.scss index 6c9b86f0697829265e7c73c38f5167142fd4ac94..fa0dce3274f23bf4684d4ce743ab17be11cbe950 100644 --- a/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.scss +++ b/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.scss @@ -129,8 +129,6 @@ } } -.hide {} - .myCriterias { flex-grow: 0; margin-right: 0px; @@ -138,6 +136,8 @@ ::ng-deep.searchTemplateMenu.mat-menu-panel { max-width: 400px !important; + width: 400px !important; + max-height: 400px !important; } .menuTitle { diff --git a/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.ts b/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.ts index 02bc1f5a251d60532dfb2c0fb80cc16ff5d31512..d841d8b7243971eecef0e23aedf04516491e7c59 100644 --- a/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.ts +++ b/src/frontend/app/adv-search/criteria-tool/criteria-tool.component.ts @@ -155,7 +155,6 @@ export class CriteriaToolComponent implements OnInit { } this.initField(criteria); this.currentCriteria.push(criteria); - this.searchTermControl.setValue(this.searchTerm); if (this.adminMode) { criteria.control.disable(); } @@ -657,7 +656,6 @@ export class CriteriaToolComponent implements OnInit { if (index > -1) { element.control = new FormControl({ value: searchTemplate.query[index].values, disabled: false }); element.control.value = searchTemplate.query[index].values; - console.log(element.control); this.addCriteria(element, openPanel);