name property WIP

This commit is contained in:
Joel McKinnon 2020-01-10 15:58:16 -08:00
parent d0e8f650be
commit d79402c568
2 changed files with 15 additions and 7 deletions

View File

@ -35,6 +35,7 @@
>
<div v-if="isEditing">
<ConditionEdit :is-default="condition.isDefault"
:condition="condition"
@persist="persist"
/>
</div>
@ -85,7 +86,7 @@ export default {
let conditionObjId = uuid();
let conditionObj = {
"composition": [],
"name": "condition" + this.conditionCollection.length,
"name": "Unnamed Condition",
"type": "condition",
"id": conditionObjId,
"location": this.parentKeyString,

View File

@ -20,7 +20,7 @@
</span>
<span v-else
class="condition-name"
>[condition name]
>{{ name }}
</span>
<span v-if="isDefault"
class="condition-description"
@ -28,7 +28,7 @@
</span>
<span v-else
class="condition-description"
>[condition description]
>{{ description }}
</span>
</div>
<span v-if="!isDefault"
@ -52,7 +52,8 @@
<li>
<label>Condition Name</label>
<span class="controls">
<input class="t-rule-name-input"
<input v-model="name"
class="t-rule-name-input"
type="text"
>
</span>
@ -80,12 +81,18 @@ export default {
props: {
isEditing: Boolean,
isCurrent: Boolean,
isDefault: Boolean
isDefault: Boolean,
condition: {
type: Object,
required: true
}
},
data() {
// console.log(`domainObject: ${domainObject}`);
console.log(`this.condition.name: ${this.condition.name}`);
return {
expanded: true
expanded: true,
name: this.condition.name,
description: this.condition.description
};
},
mounted() {