Camera settings exposed in UI defined by server.
This commit is contained in:
parent
3651013440
commit
e7e3a08210
7 changed files with 159 additions and 80 deletions
|
|
@ -98,9 +98,14 @@ export default {
|
|||
type: String,
|
||||
required: true
|
||||
},
|
||||
readBack: {
|
||||
type: Boolean,
|
||||
required: false,
|
||||
default: false
|
||||
},
|
||||
readBackDelay: {
|
||||
type: Number,
|
||||
default: undefined,
|
||||
default: 1000,
|
||||
required: false
|
||||
}
|
||||
},
|
||||
|
|
@ -124,9 +129,6 @@ export default {
|
|||
return 1;
|
||||
}
|
||||
},
|
||||
readBack: function() {
|
||||
return this.readBackDelay !== undefined;
|
||||
},
|
||||
propertyDescription: function() {
|
||||
try {
|
||||
return this.thingDescription(this.thingName).properties[
|
||||
|
|
@ -202,7 +204,6 @@ export default {
|
|||
writeProperty: async function() {
|
||||
try {
|
||||
let requestedValue = this.value;
|
||||
console.log("writing", requestedValue);
|
||||
await this.writeThingProperty(
|
||||
this.thingName,
|
||||
this.propertyName,
|
||||
|
|
|
|||
|
|
@ -0,0 +1,31 @@
|
|||
<template>
|
||||
<property-control
|
||||
:thing="propertyData.thing"
|
||||
:property-name="propertyData.property_name"
|
||||
:thing-name="propertyData.thing"
|
||||
:read-back="propertyData.read_back"
|
||||
:read-back-delay="propertyData.read_back_delay"
|
||||
/>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import PropertyControl from "./propertyControl.vue";
|
||||
|
||||
// Export main app
|
||||
export default {
|
||||
name: "ServerSpecifiedPropertyControl",
|
||||
|
||||
components: {
|
||||
PropertyControl
|
||||
},
|
||||
|
||||
props: {
|
||||
propertyData: {
|
||||
type: Object,
|
||||
required: true,
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="less"></style>
|
||||
Loading…
Add table
Add a link
Reference in a new issue