This commit is contained in:
@@ -871,6 +871,9 @@ BUILD CHANGES OF NOTE
|
||||
|
||||
BUILD 120
|
||||
|
||||
|
||||
- v8 migrate
|
||||
PM implemented
|
||||
Quote implemented
|
||||
- Fixed bug where workorderitem priority and workorderItemStatus were not being saved properly for quotes and PM's
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
export default {
|
||||
version: "8.0.0-alpha.120",
|
||||
version: "8.0.0-alpha.121",
|
||||
copyright: "© 1999-2021, Ground Zero Tech-Works Inc."
|
||||
};
|
||||
|
||||
@@ -567,8 +567,8 @@ Example workorder
|
||||
tags: [],
|
||||
pmId: 10,
|
||||
techNotes: "technotes",
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: "2021-05-29T21:25:31.421011Z",
|
||||
warrantyService: false,
|
||||
isDirty: false,
|
||||
@@ -615,8 +615,8 @@ Example workorder
|
||||
tags: [],
|
||||
pmId: 10,
|
||||
techNotes: "technotes",
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: "2021-05-29T21:25:31.421011Z",
|
||||
warrantyService: false,
|
||||
isDirty: false,
|
||||
|
||||
@@ -313,10 +313,10 @@
|
||||
xl="3"
|
||||
>
|
||||
<v-autocomplete
|
||||
v-model="value.items[activeItemIndex].workorderItemStatusId"
|
||||
v-model="value.items[activeItemIndex].workOrderItemStatusId"
|
||||
:readonly="formState.readOnly"
|
||||
:disabled="isDeleted"
|
||||
@input="fieldValueChanged('workorderItemStatusId')"
|
||||
@input="fieldValueChanged('workOrderItemStatusId')"
|
||||
:items="selectableStatusList"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
@@ -324,11 +324,11 @@
|
||||
:error-messages="
|
||||
form().serverErrors(
|
||||
this,
|
||||
`items[${activeItemIndex}].workorderItemStatusId`
|
||||
`items[${activeItemIndex}].workOrderItemStatusId`
|
||||
)
|
||||
"
|
||||
:ref="`items[${activeItemIndex}].workorderItemStatusId`"
|
||||
data-cy="workorderItemStatusId"
|
||||
:ref="`items[${activeItemIndex}].workOrderItemStatusId`"
|
||||
data-cy="workOrderItemStatusId"
|
||||
prepend-icon="$ayiEdit"
|
||||
@click:prepend="handleEditItemStatusClick()"
|
||||
>
|
||||
@@ -369,10 +369,10 @@
|
||||
xl="3"
|
||||
>
|
||||
<v-autocomplete
|
||||
v-model="value.items[activeItemIndex].workorderItemPriorityId"
|
||||
v-model="value.items[activeItemIndex].workOrderItemPriorityId"
|
||||
:readonly="formState.readOnly"
|
||||
:disabled="isDeleted"
|
||||
@input="fieldValueChanged('workorderItemPriorityId')"
|
||||
@input="fieldValueChanged('workOrderItemPriorityId')"
|
||||
:items="selectablePriorityList"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
@@ -380,11 +380,11 @@
|
||||
:error-messages="
|
||||
form().serverErrors(
|
||||
this,
|
||||
`items[${activeItemIndex}].workorderItemPriorityId`
|
||||
`items[${activeItemIndex}].workOrderItemPriorityId`
|
||||
)
|
||||
"
|
||||
:ref="`items[${activeItemIndex}].workorderItemPriorityId`"
|
||||
data-cy="workorderItemPriorityId"
|
||||
:ref="`items[${activeItemIndex}].workOrderItemPriorityId`"
|
||||
data-cy="workOrderItemPriorityId"
|
||||
prepend-icon="$ayiEdit"
|
||||
@click:prepend="handleEditItemPriorityClick()"
|
||||
>
|
||||
@@ -833,8 +833,8 @@ export default {
|
||||
tags: [],
|
||||
pmId: this.value.id,
|
||||
techNotes: null,
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: null,
|
||||
warrantyService: false,
|
||||
sequence: newIndex + 1, //indexes are zero based but sequences are visible to user so 1 based
|
||||
@@ -923,13 +923,13 @@ export default {
|
||||
handleEditItemStatusClick: function() {
|
||||
window.$gz.eventBus.$emit("openobject", {
|
||||
type: window.$gz.type.WorkOrderItemStatus,
|
||||
id: this.value.items[this.activeItemIndex].workorderItemStatusId
|
||||
id: this.value.items[this.activeItemIndex].workOrderItemStatusId
|
||||
});
|
||||
},
|
||||
handleEditItemPriorityClick: function() {
|
||||
window.$gz.eventBus.$emit("openobject", {
|
||||
type: window.$gz.type.WorkOrderItemPriority,
|
||||
id: this.value.items[this.activeItemIndex].workorderItemPriorityId
|
||||
id: this.value.items[this.activeItemIndex].workOrderItemPriorityId
|
||||
});
|
||||
},
|
||||
form() {
|
||||
@@ -1043,8 +1043,8 @@ export default {
|
||||
itemList: function() {
|
||||
return this.value.items
|
||||
.map((x, i) => {
|
||||
const stat = statusViz(x.workorderItemStatusId, this);
|
||||
const prior = priorityViz(x.workorderItemPriorityId, this);
|
||||
const stat = statusViz(x.workOrderItemStatusId, this);
|
||||
const prior = priorityViz(x.workOrderItemPriorityId, this);
|
||||
return {
|
||||
index: i,
|
||||
id: x.id,
|
||||
@@ -1066,14 +1066,14 @@ export default {
|
||||
},
|
||||
selectableStatusList: function() {
|
||||
const selectedId = this.value.items[this.activeItemIndex]
|
||||
.workorderItemStatusId;
|
||||
.workOrderItemStatusId;
|
||||
return this.pvm.selectLists.woItemStatus.filter(s => {
|
||||
return s.active == true || s.id == selectedId;
|
||||
});
|
||||
},
|
||||
selectablePriorityList: function() {
|
||||
const selectedId = this.value.items[this.activeItemIndex]
|
||||
.workorderItemPriorityId;
|
||||
.workOrderItemPriorityId;
|
||||
return this.pvm.selectLists.woItemPriorities.filter(s => {
|
||||
return s.active == true || s.id == selectedId;
|
||||
});
|
||||
|
||||
@@ -578,8 +578,8 @@ Example workorder
|
||||
tags: [],
|
||||
quoteId: 10,
|
||||
techNotes: "technotes",
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: "2021-05-29T21:25:31.421011Z",
|
||||
warrantyService: false,
|
||||
isDirty: false,
|
||||
@@ -626,8 +626,8 @@ Example workorder
|
||||
tags: [],
|
||||
quoteId: 10,
|
||||
techNotes: "technotes",
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: "2021-05-29T21:25:31.421011Z",
|
||||
warrantyService: false,
|
||||
isDirty: false,
|
||||
|
||||
@@ -313,10 +313,10 @@
|
||||
xl="3"
|
||||
>
|
||||
<v-autocomplete
|
||||
v-model="value.items[activeItemIndex].workorderItemStatusId"
|
||||
v-model="value.items[activeItemIndex].workOrderItemStatusId"
|
||||
:readonly="formState.readOnly"
|
||||
:disabled="isDeleted"
|
||||
@input="fieldValueChanged('workorderItemStatusId')"
|
||||
@input="fieldValueChanged('workOrderItemStatusId')"
|
||||
:items="selectableStatusList"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
@@ -324,11 +324,11 @@
|
||||
:error-messages="
|
||||
form().serverErrors(
|
||||
this,
|
||||
`items[${activeItemIndex}].workorderItemStatusId`
|
||||
`items[${activeItemIndex}].workOrderItemStatusId`
|
||||
)
|
||||
"
|
||||
:ref="`items[${activeItemIndex}].workorderItemStatusId`"
|
||||
data-cy="workorderItemStatusId"
|
||||
:ref="`items[${activeItemIndex}].workOrderItemStatusId`"
|
||||
data-cy="workOrderItemStatusId"
|
||||
prepend-icon="$ayiEdit"
|
||||
@click:prepend="handleEditItemStatusClick()"
|
||||
>
|
||||
@@ -369,10 +369,10 @@
|
||||
xl="3"
|
||||
>
|
||||
<v-autocomplete
|
||||
v-model="value.items[activeItemIndex].workorderItemPriorityId"
|
||||
v-model="value.items[activeItemIndex].workOrderItemPriorityId"
|
||||
:readonly="formState.readOnly"
|
||||
:disabled="isDeleted"
|
||||
@input="fieldValueChanged('workorderItemPriorityId')"
|
||||
@input="fieldValueChanged('workOrderItemPriorityId')"
|
||||
:items="selectablePriorityList"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
@@ -380,11 +380,11 @@
|
||||
:error-messages="
|
||||
form().serverErrors(
|
||||
this,
|
||||
`items[${activeItemIndex}].workorderItemPriorityId`
|
||||
`items[${activeItemIndex}].workOrderItemPriorityId`
|
||||
)
|
||||
"
|
||||
:ref="`items[${activeItemIndex}].workorderItemPriorityId`"
|
||||
data-cy="workorderItemPriorityId"
|
||||
:ref="`items[${activeItemIndex}].workOrderItemPriorityId`"
|
||||
data-cy="workOrderItemPriorityId"
|
||||
prepend-icon="$ayiEdit"
|
||||
@click:prepend="handleEditItemPriorityClick()"
|
||||
>
|
||||
@@ -833,8 +833,8 @@ export default {
|
||||
tags: [],
|
||||
quoteId: this.value.id,
|
||||
techNotes: null,
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: null,
|
||||
warrantyService: false,
|
||||
sequence: newIndex + 1, //indexes are zero based but sequences are visible to user so 1 based
|
||||
@@ -923,13 +923,13 @@ export default {
|
||||
handleEditItemStatusClick: function() {
|
||||
window.$gz.eventBus.$emit("openobject", {
|
||||
type: window.$gz.type.WorkOrderItemStatus,
|
||||
id: this.value.items[this.activeItemIndex].workorderItemStatusId
|
||||
id: this.value.items[this.activeItemIndex].workOrderItemStatusId
|
||||
});
|
||||
},
|
||||
handleEditItemPriorityClick: function() {
|
||||
window.$gz.eventBus.$emit("openobject", {
|
||||
type: window.$gz.type.WorkOrderItemPriority,
|
||||
id: this.value.items[this.activeItemIndex].workorderItemPriorityId
|
||||
id: this.value.items[this.activeItemIndex].workOrderItemPriorityId
|
||||
});
|
||||
},
|
||||
form() {
|
||||
@@ -1043,8 +1043,8 @@ export default {
|
||||
itemList: function() {
|
||||
return this.value.items
|
||||
.map((x, i) => {
|
||||
const stat = statusViz(x.workorderItemStatusId, this);
|
||||
const prior = priorityViz(x.workorderItemPriorityId, this);
|
||||
const stat = statusViz(x.workOrderItemStatusId, this);
|
||||
const prior = priorityViz(x.workOrderItemPriorityId, this);
|
||||
return {
|
||||
index: i,
|
||||
id: x.id,
|
||||
@@ -1066,14 +1066,14 @@ export default {
|
||||
},
|
||||
selectableStatusList: function() {
|
||||
const selectedId = this.value.items[this.activeItemIndex]
|
||||
.workorderItemStatusId;
|
||||
.workOrderItemStatusId;
|
||||
return this.pvm.selectLists.woItemStatus.filter(s => {
|
||||
return s.active == true || s.id == selectedId;
|
||||
});
|
||||
},
|
||||
selectablePriorityList: function() {
|
||||
const selectedId = this.value.items[this.activeItemIndex]
|
||||
.workorderItemPriorityId;
|
||||
.workOrderItemPriorityId;
|
||||
return this.pvm.selectLists.woItemPriorities.filter(s => {
|
||||
return s.active == true || s.id == selectedId;
|
||||
});
|
||||
|
||||
@@ -545,8 +545,8 @@ Example workorder
|
||||
tags: [],
|
||||
workOrderId: 10,
|
||||
techNotes: "technotes",
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: "2021-05-29T21:25:31.421011Z",
|
||||
warrantyService: false,
|
||||
isDirty: false,
|
||||
@@ -593,8 +593,8 @@ Example workorder
|
||||
tags: [],
|
||||
workOrderId: 10,
|
||||
techNotes: "technotes",
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: "2021-05-29T21:25:31.421011Z",
|
||||
warrantyService: false,
|
||||
isDirty: false,
|
||||
|
||||
@@ -343,10 +343,10 @@
|
||||
xl="3"
|
||||
>
|
||||
<v-autocomplete
|
||||
v-model="value.items[activeItemIndex].workorderItemStatusId"
|
||||
v-model="value.items[activeItemIndex].workOrderItemStatusId"
|
||||
:readonly="formState.readOnly"
|
||||
:disabled="isDeleted"
|
||||
@input="fieldValueChanged('workorderItemStatusId')"
|
||||
@input="fieldValueChanged('workOrderItemStatusId')"
|
||||
:items="selectableStatusList"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
@@ -354,11 +354,11 @@
|
||||
:error-messages="
|
||||
form().serverErrors(
|
||||
this,
|
||||
`items[${activeItemIndex}].workorderItemStatusId`
|
||||
`items[${activeItemIndex}].workOrderItemStatusId`
|
||||
)
|
||||
"
|
||||
:ref="`items[${activeItemIndex}].workorderItemStatusId`"
|
||||
data-cy="workorderItemStatusId"
|
||||
:ref="`items[${activeItemIndex}].workOrderItemStatusId`"
|
||||
data-cy="workOrderItemStatusId"
|
||||
prepend-icon="$ayiEdit"
|
||||
@click:prepend="handleEditItemStatusClick()"
|
||||
>
|
||||
@@ -399,10 +399,10 @@
|
||||
xl="3"
|
||||
>
|
||||
<v-autocomplete
|
||||
v-model="value.items[activeItemIndex].workorderItemPriorityId"
|
||||
v-model="value.items[activeItemIndex].workOrderItemPriorityId"
|
||||
:readonly="formState.readOnly"
|
||||
:disabled="isDeleted"
|
||||
@input="fieldValueChanged('workorderItemPriorityId')"
|
||||
@input="fieldValueChanged('workOrderItemPriorityId')"
|
||||
:items="selectablePriorityList"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
@@ -410,11 +410,11 @@
|
||||
:error-messages="
|
||||
form().serverErrors(
|
||||
this,
|
||||
`items[${activeItemIndex}].workorderItemPriorityId`
|
||||
`items[${activeItemIndex}].workOrderItemPriorityId`
|
||||
)
|
||||
"
|
||||
:ref="`items[${activeItemIndex}].workorderItemPriorityId`"
|
||||
data-cy="workorderItemPriorityId"
|
||||
:ref="`items[${activeItemIndex}].workOrderItemPriorityId`"
|
||||
data-cy="workOrderItemPriorityId"
|
||||
prepend-icon="$ayiEdit"
|
||||
@click:prepend="handleEditItemPriorityClick()"
|
||||
>
|
||||
@@ -976,8 +976,8 @@ export default {
|
||||
tags: [],
|
||||
workOrderId: this.value.id,
|
||||
techNotes: null,
|
||||
workorderItemStatusId: null,
|
||||
workorderItemPriorityId: null,
|
||||
workOrderItemStatusId: null,
|
||||
workOrderItemPriorityId: null,
|
||||
requestDate: null,
|
||||
warrantyService: false,
|
||||
sequence: newIndex + 1, //indexes are zero based but sequences are visible to user so 1 based
|
||||
@@ -1067,13 +1067,13 @@ export default {
|
||||
handleEditItemStatusClick: function() {
|
||||
window.$gz.eventBus.$emit("openobject", {
|
||||
type: window.$gz.type.WorkOrderItemStatus,
|
||||
id: this.value.items[this.activeItemIndex].workorderItemStatusId
|
||||
id: this.value.items[this.activeItemIndex].workOrderItemStatusId
|
||||
});
|
||||
},
|
||||
handleEditItemPriorityClick: function() {
|
||||
window.$gz.eventBus.$emit("openobject", {
|
||||
type: window.$gz.type.WorkOrderItemPriority,
|
||||
id: this.value.items[this.activeItemIndex].workorderItemPriorityId
|
||||
id: this.value.items[this.activeItemIndex].workOrderItemPriorityId
|
||||
});
|
||||
},
|
||||
form() {
|
||||
@@ -1215,8 +1215,8 @@ and it's probably not a big list to fill anyway
|
||||
itemList: function() {
|
||||
return this.value.items
|
||||
.map((x, i) => {
|
||||
const stat = statusViz(x.workorderItemStatusId, this);
|
||||
const prior = priorityViz(x.workorderItemPriorityId, this);
|
||||
const stat = statusViz(x.workOrderItemStatusId, this);
|
||||
const prior = priorityViz(x.workOrderItemPriorityId, this);
|
||||
return {
|
||||
index: i,
|
||||
id: x.id,
|
||||
@@ -1238,14 +1238,14 @@ and it's probably not a big list to fill anyway
|
||||
},
|
||||
selectableStatusList: function() {
|
||||
const selectedId = this.value.items[this.activeItemIndex]
|
||||
.workorderItemStatusId;
|
||||
.workOrderItemStatusId;
|
||||
return this.pvm.selectLists.woItemStatus.filter(s => {
|
||||
return s.active == true || s.id == selectedId;
|
||||
});
|
||||
},
|
||||
selectablePriorityList: function() {
|
||||
const selectedId = this.value.items[this.activeItemIndex]
|
||||
.workorderItemPriorityId;
|
||||
.workOrderItemPriorityId;
|
||||
return this.pvm.selectLists.woItemPriorities.filter(s => {
|
||||
return s.active == true || s.id == selectedId;
|
||||
});
|
||||
|
||||
@@ -346,7 +346,7 @@ export default {
|
||||
"dateRequested": "2020-01-10T18:20:31.294229Z",
|
||||
"customerId": 28,
|
||||
"unitId": null,
|
||||
"workorderItemId": null,
|
||||
"workOrderItemId": null,
|
||||
"requestedByUserId": 48,
|
||||
"customerReferenceNumber": "65560804",
|
||||
"status": 0,
|
||||
@@ -365,7 +365,7 @@ export default {
|
||||
dateRequested: window.$gz.locale.nowUTC8601String(),
|
||||
customerId: null,
|
||||
unitId: null,
|
||||
workorderItemId: null,
|
||||
workOrderItemId: null,
|
||||
requestedByUserId: null, //window.$gz.store.state.userId, for outside version of this form
|
||||
customerReferenceNumber: null,
|
||||
status: 0,
|
||||
|
||||
@@ -344,7 +344,7 @@ export default {
|
||||
"dateRequested": "2020-01-10T18:20:31.294229Z",
|
||||
"customerId": 28,
|
||||
"unitId": null,
|
||||
"workorderItemId": null,
|
||||
"workOrderItemId": null,
|
||||
"requestedByUserId": 48,
|
||||
"customerReferenceNumber": "65560804",
|
||||
"status": 0,
|
||||
@@ -363,7 +363,7 @@ export default {
|
||||
dateRequested: window.$gz.locale.nowUTC8601String(),
|
||||
customerId: null,
|
||||
unitId: null,
|
||||
workorderItemId: null,
|
||||
workOrderItemId: null,
|
||||
requestedByUserId: null, //window.$gz.store.state.userId, for outside version of this form
|
||||
customerReferenceNumber: null,
|
||||
status: 0,
|
||||
|
||||
@@ -975,46 +975,46 @@ async function saveItems(vm) {
|
||||
//fields to update if post
|
||||
if (isPost) {
|
||||
vm.obj.items[i].id = res.data.id;
|
||||
vm.obj.items[i].workorderId = res.data.workorderId;
|
||||
vm.obj.items[i].workOrderId = res.data.workOrderId;
|
||||
|
||||
//walk all unsaved children and set the workorder item id so they can save
|
||||
vm.obj.items[i].units.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
|
||||
vm.obj.items[i].scheduledUsers.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
|
||||
vm.obj.items[i].tasks.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
|
||||
vm.obj.items[i].parts.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
|
||||
vm.obj.items[i].partRequests.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
|
||||
vm.obj.items[i].labors.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
|
||||
vm.obj.items[i].travels.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
|
||||
vm.obj.items[i].expenses.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
|
||||
vm.obj.items[i].loans.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
vm.obj.items[i].outsideServices.forEach(
|
||||
z => (z.workorderItemId = vm.obj.items[i].id)
|
||||
z => (z.workOrderItemId = vm.obj.items[i].id)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user