This commit is contained in:
@@ -248,7 +248,7 @@
|
||||
:rules="[
|
||||
form().required(
|
||||
this,
|
||||
`Items[${activeWoItemIndex}].tasks[${activeItemIndex}].tasks`
|
||||
`Items[${activeWoItemIndex}].tasks[${activeItemIndex}].task`
|
||||
)
|
||||
]"
|
||||
:ref="`Items[${activeWoItemIndex}].tasks[${activeItemIndex}].task`"
|
||||
@@ -418,7 +418,7 @@ export default {
|
||||
id: 0,
|
||||
concurrency: 0,
|
||||
sequence: newIndex + 1, //indexes are zero based but sequences are visible to user so 1 based
|
||||
task: null,
|
||||
task: undefined, //to trigger validation on new
|
||||
status: 1, //incomplete==1
|
||||
completedByUserId: null,
|
||||
completedDate: null,
|
||||
@@ -429,6 +429,15 @@ export default {
|
||||
this.$emit("change");
|
||||
this.selectedRow = [{ index: newIndex }];
|
||||
this.activeItemIndex = newIndex;
|
||||
//trigger rule breaking / validation
|
||||
this.$nextTick(() => {
|
||||
this.value.items[this.activeWoItemIndex].tasks[
|
||||
this.activeItemIndex
|
||||
].task = null;
|
||||
this.fieldValueChanged(
|
||||
`Items[${this.activeWoItemIndex}].tasks[${this.activeItemIndex}].task`
|
||||
);
|
||||
});
|
||||
},
|
||||
unDeleteItem() {
|
||||
this.value.items[this.activeWoItemIndex].tasks[
|
||||
|
||||
@@ -762,7 +762,7 @@ export default {
|
||||
this.value.items.push({
|
||||
id: 0,
|
||||
concurrency: 0,
|
||||
notes: null,
|
||||
notes: undefined, //to trigger validation on new
|
||||
wiki: null,
|
||||
customFields: "{}",
|
||||
tags: [],
|
||||
@@ -790,7 +790,10 @@ export default {
|
||||
this.selectedRow = [{ index: newIndex }];
|
||||
this.activeItemIndex = newIndex;
|
||||
//trigger rule breaking / validation
|
||||
this.fieldValueChanged(`items[${this.activeItemIndex}].notes`);
|
||||
this.$nextTick(() => {
|
||||
this.value.items[this.activeItemIndex].notes = null;
|
||||
this.fieldValueChanged(`items[${this.activeItemIndex}].notes`);
|
||||
});
|
||||
},
|
||||
unDeleteItem() {
|
||||
this.value.items[this.activeItemIndex].deleted = false;
|
||||
|
||||
Reference in New Issue
Block a user