mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2026-09-09 18:02:54 +00:00
[MNT-25681] Search refactoring and unification (#5257)
* [MNT-25681] Search refactoring and unification * [MNT-25681] CR fixes * [MNT-25681] ADF version bump * [MNT-25681] Two way binding on search input * MNT-25681] search e2es fixes * [MNT-25681] search e2es stabilization pt 2 * [MNT-25149] Add unit tests for multivalued select parameter default value (#5262) * [MNT-25149] Add unit tests for multivalued select parameter default value * address comment on pr * [MNT-25681] Fix content node selector panel issues * [PRODSEC-13253] Upgraded angular version to fix vulnerability and to have the same versions like ADF * [MNT-25681] Unit test fix * [MNT-25681] Search input fix --------- Co-authored-by: Adam Świderski <adam.tomasz.swiderski@gmail.com> Co-authored-by: Akash Rathod <41251473+akashrathod28@users.noreply.github.com> Co-authored-by: Aleksander Sklorz <Aleksander.Sklorz@hyland.com>
This commit is contained in:
co-authored by
Adam Świderski
Akash Rathod
Aleksander Sklorz
parent
e2df1e352c
commit
1695f17b7c
+2
@@ -31,6 +31,8 @@ export class SearchInputComponent extends BaseComponent {
|
||||
public searchButton = this.page.locator('.aca-search-input--search-button');
|
||||
public searchCloseButton = this.page.locator('.aca-search-input--close-button');
|
||||
public searchInButton = this.getChild('aca-search-in-menu button');
|
||||
public formulaSearchButton = this.getChild('[value="formula"]');
|
||||
public regularSearchButton = this.getChild('[value="regular"]');
|
||||
|
||||
/**
|
||||
* Method used in cases where user have possibility to navigate "inside" the element (it's clickable and has link attribute).
|
||||
|
||||
@@ -46,6 +46,7 @@ import { AdfConfirmDialogComponent, AdfFolderDialogComponent, ManageVersionsDial
|
||||
import { SearchInDialogComponent } from '../components/search/search-in-dialog.components';
|
||||
|
||||
export type SearchType = 'files' | 'folders' | 'filesAndFolders' | 'libraries';
|
||||
export type SearchMode = 'regular' | 'formula';
|
||||
|
||||
export class SearchPage extends BasePage {
|
||||
private static readonly pageUrl = 'search';
|
||||
@@ -76,11 +77,17 @@ export class SearchPage extends BasePage {
|
||||
public folderInformationDialog = new FolderInformationDialogComponent(this.page);
|
||||
public searchMenuCard = new SearchMenuCard(this.page);
|
||||
|
||||
async searchWithin(searchText: string, searchType?: SearchType): Promise<void> {
|
||||
async searchWithin(searchText: string, searchType?: SearchType, searchMode?: SearchMode): Promise<void> {
|
||||
if (!(await this.searchInputComponent.searchInput.isVisible())) {
|
||||
await this.acaHeader.searchButton.click();
|
||||
}
|
||||
await this.searchInputComponent.searchFor(searchText);
|
||||
await this.dataTable.spinnerWaitForReload();
|
||||
if (searchMode === 'formula') {
|
||||
await this.searchInputComponent.formulaSearchButton.click();
|
||||
} else {
|
||||
await this.searchInputComponent.regularSearchButton.click();
|
||||
}
|
||||
await this.searchInputComponent.searchInButton.click();
|
||||
switch (searchType) {
|
||||
case 'files':
|
||||
|
||||
Reference in New Issue
Block a user