Commit 5308c419 authored by Jörg Richter's avatar Jörg Richter

Remove "Geomaps" API

See dmx-platform/dmx-platform#260
parent 10aa6ed5
Pipeline #8888 passed with stage
in 3 seconds
This diff is collapsed.
import {
DMXObject, Topic, Assoc, Player, RelatedTopic, Type, TopicType, AssocType, Topicmap, ViewTopic, ViewAssoc, Geomap
DMXObject, Topic, Assoc, Player, RelatedTopic, Type, TopicType, AssocType, Topicmap, ViewTopic, ViewAssoc
} from './model'
import restClient from './rest-client'
import typeCache from './type-cache'
import permCache from './permission-cache'
import utils from './utils'
console.log('[DMX] Client API 2019/11/21')
console.log('[DMX] Client Library 2020/01/27')
export default {
DMXObject, Topic, Assoc, Player, RelatedTopic, Type, TopicType, AssocType, Topicmap, ViewTopic, ViewAssoc, Geomap,
DMXObject, Topic, Assoc, Player, RelatedTopic, Type, TopicType, AssocType, Topicmap, ViewTopic, ViewAssoc,
restClient,
typeCache,
......
......@@ -991,23 +991,6 @@ class ViewAssoc extends viewPropsMixin(Assoc) {
}
}
class Geomap extends Topic {
constructor (geomap) {
super(geomap.topic)
this.viewProps = geomap.viewProps
this.geoCoordTopics = geomap.geoCoordTopics // instantiating dm5.Topic objects not required at the moment
}
removeTopic (id) {
// TODO; skeleton needed by dm5-topicmap-panel contract
}
removeAssoc (id) {
// TODO; skeleton needed by dm5-topicmap-panel contract
}
}
export {
DMXObject,
Topic,
......@@ -1019,6 +1002,5 @@ export {
AssocType,
Topicmap,
ViewTopic,
ViewAssoc,
Geomap
ViewAssoc
}
import http from 'axios'
import permCache from './permission-cache'
import utils from './utils'
import { Topic, Assoc, RelatedTopic, TopicType, AssocType, Topicmap, Geomap } from './model'
import { Topic, Assoc, RelatedTopic, TopicType, AssocType, Topicmap } from './model'
// Vanilla instance without error interceptor.
// In contrast the default http instance allows the caller to set an error handler (see setErrorHandler()).
......@@ -305,28 +305,6 @@ export default {
http.put(`/topicmap/${topicmapId}/pan/${pan.x}/${pan.y}/zoom/${zoom}`)
}, 3000),
// === Geomaps ===
getGeomap (geomapId) {
return http.get(`/geomap/${geomapId}`).then(response =>
new Geomap(response.data)
)
},
getDomainTopics (geoCoordId, includeChildren, includeAssocChildren) {
return http.get(`/geomap/coord/${geoCoordId}`, {params: {
children: includeChildren,
assoc_children: includeAssocChildren
}}).then(response =>
utils.instantiateMany(response.data, Topic)
)
},
setGeomapState: utils.debounce((geomapId, lon, lat, zoom) => {
console.log('setGeomapState', lon, lat, zoom)
http.put(`/geomap/${geomapId}/center/${lon}/${lat}/zoom/${zoom}`)
}, 3000),
// === Workspaces ===
/**
......
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