[ARVADOS-WORKBENCH2] updated: 1.2.0-755-ge7af5ee

Git user git at public.curoverse.com
Tue Oct 30 08:48:14 EDT 2018


Summary of changes:
 src/store/search-bar/search-bar-actions.ts | 2 +-
 src/store/search-bar/search-bar-reducer.ts | 4 +---
 2 files changed, 2 insertions(+), 4 deletions(-)

       via  e7af5ee5ca402f7c637586831d611e5648cbc5b9 (commit)
      from  dc5cd08bad19c302d34b75b34795d5745da2eae2 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit e7af5ee5ca402f7c637586831d611e5648cbc5b9
Author: Daniel Kos <daniel.kos at contractors.roche.com>
Date:   Tue Oct 30 13:48:11 2018 +0100

    Fix setting autocomplete view first item
    
    Feature #14364
    
    Arvados-DCO-1.1-Signed-off-by: Daniel Kos <daniel.kos at contractors.roche.com>

diff --git a/src/store/search-bar/search-bar-actions.ts b/src/store/search-bar/search-bar-actions.ts
index eb4239d..165392c 100644
--- a/src/store/search-bar/search-bar-actions.ts
+++ b/src/store/search-bar/search-bar-actions.ts
@@ -32,7 +32,7 @@ export const searchBarActions = unionize({
     MOVE_UP: ofType<{}>(),
     MOVE_DOWN: ofType<{}>(),
     SELECT_FIRST_ITEM: ofType<{}>()
-}); 
+});
 
 export type SearchBarActions = UnionOf<typeof searchBarActions>;
 
diff --git a/src/store/search-bar/search-bar-reducer.ts b/src/store/search-bar/search-bar-reducer.ts
index 32b01f7..8508c05 100644
--- a/src/store/search-bar/search-bar-reducer.ts
+++ b/src/store/search-bar/search-bar-reducer.ts
@@ -127,9 +127,7 @@ export const searchBarReducer = (state = initialState, action: SearchBarActions)
         SELECT_FIRST_ITEM: () => {
             let selectedItem = state.selectedItem;
             if (state.currentView === SearchView.AUTOCOMPLETE) {
-                if (state.searchResults.length > 0) {
-                    selectedItem = makeSelectedItem(state.searchResults[0].uuid);
-                }
+                selectedItem = makeSelectedItem(state.searchValue);
             } else if (state.currentView === SearchView.BASIC) {
                 const items = makeQueryList(state.recentQueries, state.savedQueries);
                 if (items.length > 0) {

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list