Skip to content
This repository has been archived by the owner on May 1, 2019. It is now read-only.

Commit

Permalink
minor modifications
Browse files Browse the repository at this point in the history
  • Loading branch information
didimitrie committed Aug 25, 2017
1 parent 974f0a1 commit 082219d
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 16 deletions.
1 change: 0 additions & 1 deletion src/components/SpeckleReceiver.vue
Expand Up @@ -82,7 +82,6 @@ export default {
})
},
receiverReady( name, layers, objects, history, layerMaterials ) {
console.info( 'ready event for ' )
this.getComments()
this.showProgressBar = false
Expand Down
2 changes: 1 addition & 1 deletion src/components/SpeckleStreamList.vue
Expand Up @@ -6,7 +6,7 @@
</md-button>
<md-button class="md-icon-button md-primary" @click.native='toggleStreamList'>
<md-icon>{{ showStreamList ? 'keyboard_arrow_left':'keyboard_arrow_right' }}</md-icon>
<md-tooltip> {{ showStreamList ? 'Hide' : 'Show' }} the stream list.capti</md-tooltip>
<md-tooltip> {{ showStreamList ? 'Hide' : 'Show' }} the stream list.</md-tooltip>
</md-button>
</div>
<div id='stream-list' class='' ref='thestreamlist'>
Expand Down
25 changes: 13 additions & 12 deletions src/receiver/SpeckleReceiver.js
Expand Up @@ -163,19 +163,20 @@ export default class SpeckleReceiver extends EventEmitter {
throw new Error('no obj provided')
return
}
if( ! obj.hash )
return callback( obj )

axios.get( this.restEndpoint + '/geometry/' + obj.hash )
.then( response => {
let myObject = response.data.data
// reattach props
myObject.properties = obj.properties
return callback( myObject )
} )
.catch( err => {
throw new Error( err )
})
if( obj.type === 'Curve' || obj.type ==='Polyline' || obj.type === 'Mesh' || obj.type === 'Brep' )
axios.get( this.restEndpoint + '/geometry/' + obj.hash )
.then( response => {
let myObject = response.data.data
// reattach props
myObject.properties = obj.properties
return callback( myObject )
} )
.catch( err => {
throw new Error( err )
})
else
return callback( obj )
}

broadcast( message ) {
Expand Down
3 changes: 1 addition & 2 deletions src/store/Store.js
Expand Up @@ -62,17 +62,16 @@ export default new Vuex.Store( {
},

ADD_COMMENT( state, { payload } ) {
console.log( payload )
state.comments.push( payload )
},

ADD_COMMENTS( state, { payload } ) {
console.log()
state.comments.push( ...payload.comments )
},

INIT_RECEIVER_DATA( state, { payload } ) {
let target = state.receivers.find( rec => rec.streamId === payload.streamId )
console.log( target )
target.name = payload.name
target.layers = payload.layers

Expand Down

0 comments on commit 082219d

Please sign in to comment.