Commit 40cda8ff authored by Jörg Richter's avatar Jörg Richter

REST client: adapt `queryTopicsFulltext()` to server API

See dmx-platform/dmx-platform#273
parent 39458530
Pipeline #7738 passed with stage
in 4 seconds
This diff is collapsed.
......@@ -6,7 +6,7 @@ import typeCache from './type-cache'
import permCache from './permission-cache'
import utils from './utils'
console.log('[DMX] Client API 2019/07/30')
console.log('[DMX] Client API 2019/08/01')
export default {
......
......@@ -47,11 +47,11 @@ export default {
)
},
queryTopicsFulltext (searchTerm, typeUri) {
const config = {params: {search: searchTerm, field: typeUri}}
return http.get('/core/topic', config).then(response =>
utils.instantiateMany(response.data, Topic)
)
queryTopicsFulltext (query, typeUri) {
return http.get('/core/topic', {params: {query, type_uri: typeUri}}).then(response => ({
query: response.data.query,
topics: utils.instantiateMany(response.data.topics, Topic)
}))
},
createTopic (topicModel) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment