This commit is contained in:
2021-07-15 15:28:42 +00:00
parent 85fb87bdb5
commit 72e9a68ccc

View File

@@ -251,7 +251,7 @@
>
<v-textarea
v-model="value.items[activeItemIndex].notes"
:readonly="formState.readOnly"
:readonly="formState.readOnly || value.userIsRestrictedType"
:disabled="isDeleted"
:label="$ay.t('WorkOrderItemSummary')"
:error-messages="
@@ -266,7 +266,10 @@
</v-col>
<v-col
v-if="form().showMe(this, 'WorkOrderItemSequence')"
v-if="
form().showMe(this, 'WorkOrderItemSequence') &&
!value.userIsRestrictedType
"
cols="12"
sm="6"
lg="4"
@@ -274,7 +277,7 @@
>
<v-text-field
v-model="value.items[activeItemIndex].sequence"
:readonly="formState.readOnly"
:readonly="formState.readOnly || value.userIsRestrictedType"
:disabled="isDeleted"
:label="$ay.t('Sequence')"
:ref="`items[${activeItemIndex}].sequence`"
@@ -292,7 +295,7 @@
<v-col v-if="form().showMe(this, 'WorkOrderItemTechNotes')" cols="12">
<v-textarea
v-model="value.items[activeItemIndex].techNotes"
:readonly="formState.readOnly"
:readonly="formState.readOnly || value.userIsRestrictedType"
:disabled="isDeleted"
:label="$ay.t('WorkOrderItemTechNotes')"
:error-messages="
@@ -306,7 +309,10 @@
</v-col>
<v-col
v-if="form().showMe(this, 'WorkOrderItemRequestDate')"
v-if="
form().showMe(this, 'WorkOrderItemRequestDate') &&
!value.userIsRestrictedType
"
cols="12"
sm="6"
lg="4"
@@ -327,7 +333,10 @@
</v-col>
<v-col
v-if="form().showMe(this, 'WorkOrderItemWorkOrderStatusID')"
v-if="
form().showMe(this, 'WorkOrderItemWorkOrderStatusID') &&
!value.userIsRestrictedType
"
cols="12"
sm="6"
lg="4"
@@ -380,7 +389,10 @@
</v-col>
<v-col
v-if="form().showMe(this, 'WorkOrderItemPriorityID')"
v-if="
form().showMe(this, 'WorkOrderItemPriorityID') &&
!value.userIsRestrictedType
"
cols="12"
sm="6"
lg="4"
@@ -432,7 +444,10 @@
</v-col>
<v-col
v-if="form().showMe(this, 'WorkOrderItemWarrantyService')"
v-if="
form().showMe(this, 'WorkOrderItemWarrantyService') &&
!value.userIsRestrictedType
"
cols="12"
sm="6"
lg="4"
@@ -455,7 +470,13 @@
></v-checkbox>
</v-col>
<v-col v-if="form().showMe(this, 'WorkOrderItemTags')" cols="12">
<v-col
v-if="
form().showMe(this, 'WorkOrderItemTags') &&
!value.userIsRestrictedType
"
cols="12"
>
<gz-tag-picker
v-model="value.items[activeItemIndex].tags"
:readonly="formState.readOnly"
@@ -468,7 +489,7 @@
></gz-tag-picker>
</v-col>
<v-col cols="12">
<v-col v-if="!value.userIsRestrictedType" cols="12">
<gz-custom-fields
v-model="value.items[activeItemIndex].customFields"
:form-key="formCustomTemplateKey"
@@ -487,7 +508,13 @@
></gz-custom-fields>
</v-col>
<v-col v-if="form().showMe(this, 'WorkOrderItemWiki')" cols="12">
<v-col
v-if="
form().showMe(this, 'WorkOrderItemWiki') &&
!value.userIsRestrictedType
"
cols="12"
>
<gz-wiki
:aya-type="$ay.ayt().WorkOrderItem"
:aya-id="value.id"
@@ -499,7 +526,11 @@
></v-col>
<v-col
v-if="form().showMe(this, 'WorkOrderItemAttachments') && value.id"
v-if="
form().showMe(this, 'WorkOrderItemAttachments') &&
value.id &&
!value.userIsRestrictedType
"
cols="12"
>
<gz-attachments
@@ -1122,7 +1153,10 @@ and it's probably not a big list to fill anyway
value: "notes"
});
if (this.form().showMe(this, "WorkOrderItemWorkOrderStatusID")) {
if (
this.form().showMe(this, "WorkOrderItemWorkOrderStatusID") &&
!this.value.userIsRestrictedType
) {
headers.push({
text: this.$ay.t("WorkOrderItemWorkOrderStatusID"),
align: "left",
@@ -1130,7 +1164,10 @@ and it's probably not a big list to fill anyway
});
}
if (this.form().showMe(this, "WorkOrderItemRequestDate")) {
if (
this.form().showMe(this, "WorkOrderItemRequestDate") &&
!this.value.userIsRestrictedType
) {
headers.push({
text: this.$ay.t("WorkOrderItemRequestDate"),
align: "right",
@@ -1138,7 +1175,10 @@ and it's probably not a big list to fill anyway
});
}
if (this.form().showMe(this, "WorkOrderItemPriorityID")) {
if (
this.form().showMe(this, "WorkOrderItemPriorityID") &&
!this.value.userIsRestrictedType
) {
headers.push({
text: this.$ay.t("WorkOrderItemPriorityID"),
align: "left",
@@ -1146,7 +1186,10 @@ and it's probably not a big list to fill anyway
});
}
if (this.form().showMe(this, "WorkOrderItemWarrantyService")) {
if (
this.form().showMe(this, "WorkOrderItemWarrantyService") &&
!this.value.userIsRestrictedType
) {
headers.push({
text: this.$ay.t("WorkOrderItemWarrantyService"),
align: "center",
@@ -1154,7 +1197,10 @@ and it's probably not a big list to fill anyway
});
}
if (this.form().showMe(this, "WorkOrderItemTags")) {
if (
this.form().showMe(this, "WorkOrderItemTags") &&
!this.value.userIsRestrictedType
) {
headers.push({
text: this.$ay.t("Tags"),
align: "left",