Always show fresh relationship status in search, better error handling.
2 unresolved threads
2 unresolved threads
This will no properly handle timeouts as well (it would just spin forever before)
Mass fetching ids did not work, i guess because the query array syntax is wrong.
Edited by lain
Merge request reports
Activity
added 25 commits
-
3fb7a7d0...277790e4 - 24 commits from branch
develop
- bd247adc - Merge remote-tracking branch 'origin/develop' into user-search-better-error-handling
-
3fb7a7d0...277790e4 - 24 commits from branch
27 34 this.$router.push({ name: 'user-search', query: { query } }) 28 35 this.$refs.userSearchInput.focus() 29 36 }, 30 search (query) { 37 async search (query) { 31 38 if (!query) { 32 this.users = [] 33 39 return 34 40 } 41 35 42 this.loading = true 36 userSearchApi.search({query, store: this.$store}) 37 .then((res) => { 38 this.loading = false 39 this.users = res 43 try { mentioned in merge request !754 (merged)
32 this.users = [] 33 39 return 34 40 } 41 35 42 this.loading = true 36 userSearchApi.search({query, store: this.$store}) 37 .then((res) => { 38 this.loading = false 39 this.users = res 43 try { 44 this.userIds = [] 45 const users = await userSearchApi.search({ query, store: this.$store }) 46 this.$store.commit('addNewUsers', users) 47 each(users, ({ id }) => { 48 this.userIds.push(id) 49 this.$store.dispatch('fetchUserRelationship', id) Solved in !754 (merged) so closing here.
@lambadalambda thank you for choosing my solution.
Please register or sign in to reply