added camera settings send and general settings send

This commit is contained in:
ori agranat
2019-10-12 18:09:05 +03:00
parent 276e425183
commit 0aaff35e42
2 changed files with 11 additions and 5 deletions

View File

@@ -22,6 +22,11 @@ import CVnumberinput from '../../components/cv-number-input'
}
},
methods:{
sendCameraSettings(){
this.handleInput('cameraSettings',this.cameraSettings);
}
},
computed:{
currentCameraIndex:{
get(){

View File

@@ -8,7 +8,7 @@
<CVinput name="Gateway" v-model="settings.gateway" :disabled="isDisabled"></CVinput>
<v-divider color="white"></v-divider>
<CVinput name="Hostname" v-model="settings.hostname"></CVinput>
<v-btn style="margin-top:10px" small color="#4baf62">Save General Settings</v-btn>
<v-btn style="margin-top:10px" small color="#4baf62" @click="sendGeneralSettings">Save General Settings</v-btn>
</div>
</template>
@@ -27,6 +27,11 @@ import CVinput from '../../components/cv-input'
return {
}
},
methods:{
sendGeneralSettings(){
this.handleInput('generalSettings',this.settings);
}
},
computed:{
isDisabled(){
if(this.settings.connectionType === 0){
@@ -37,12 +42,8 @@ import CVinput from '../../components/cv-input'
settings:{
get(){
return this.$store.state.settings;
},
set(value){
this.$store.commit('settings',value);
}
}
}
}
</script>