This commit is contained in:
@@ -36,6 +36,26 @@
|
||||
></v-checkbox>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'Customer')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<gz-pick-list
|
||||
:ayaType="ayaTypes().Customer"
|
||||
:showEditIcon="true"
|
||||
v-model="obj.customerId"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('Customer')"
|
||||
ref="customerId"
|
||||
data-cy="customerId"
|
||||
:error-messages="form().serverErrors(this, 'customerId')"
|
||||
@input="fieldValueChanged('customerId')"
|
||||
></gz-pick-list>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'UnitDescription')"
|
||||
cols="12"
|
||||
@@ -229,150 +249,191 @@
|
||||
@input="fieldValueChanged('purchasedFromVendorId')"
|
||||
></gz-pick-list>
|
||||
</v-col>
|
||||
<!-- -------------------------------------------- -->
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'WebAddress')"
|
||||
v-if="form().showMe(this, 'UnitPurchasedDate')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<gz-url
|
||||
v-model="obj.webAddress"
|
||||
<gz-date-time-picker
|
||||
:label="$ay.t('UnitPurchasedDate')"
|
||||
v-model="obj.purchasedDate"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('WebAddress')"
|
||||
ref="webAddress"
|
||||
data-cy="webAddress"
|
||||
:error-messages="form().serverErrors(this, 'webAddress')"
|
||||
@input="fieldValueChanged('webAddress')"
|
||||
></gz-url>
|
||||
ref="purchasedDate"
|
||||
testId="purchasedDate"
|
||||
:error-messages="form().serverErrors(this, 'purchasedDate')"
|
||||
@input="fieldValueChanged('purchasedDate')"
|
||||
></gz-date-time-picker>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'Contact')"
|
||||
v-if="form().showMe(this, 'UnitReceipt')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<v-text-field
|
||||
v-model="obj.contact"
|
||||
v-model="obj.receipt"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitContact')"
|
||||
ref="contact"
|
||||
data-cy="contact"
|
||||
:error-messages="form().serverErrors(this, 'contact')"
|
||||
@input="fieldValueChanged('contact')"
|
||||
:label="$ay.t('UnitReceipt')"
|
||||
ref="receipt"
|
||||
data-cy="receipt"
|
||||
:error-messages="form().serverErrors(this, 'receipt')"
|
||||
@input="fieldValueChanged('receipt')"
|
||||
></v-text-field>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'EmailAddress')"
|
||||
v-if="form().showMe(this, 'UnitOverrideWarranty')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<gz-email
|
||||
v-model="obj.emailAddress"
|
||||
<v-checkbox
|
||||
v-model="obj.overrideModelWarranty"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitEmail')"
|
||||
ref="emailAddress"
|
||||
data-cy="emailAddress"
|
||||
:error-messages="form().serverErrors(this, 'emailAddress')"
|
||||
@input="fieldValueChanged('emailAddress')"
|
||||
></gz-email>
|
||||
:label="$ay.t('UnitOverrideWarranty')"
|
||||
ref="overrideModelWarranty"
|
||||
data-cy="overrideModelWarranty"
|
||||
:error-messages="
|
||||
form().serverErrors(this, 'overrideModelWarranty')
|
||||
"
|
||||
@change="fieldValueChanged('overrideModelWarranty')"
|
||||
></v-checkbox>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'Phone1')"
|
||||
v-if="form().showMe(this, 'UnitOverrideLifeTime')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<gz-phone
|
||||
v-model="obj.phone1"
|
||||
<v-checkbox
|
||||
v-model="obj.lifeTimeWarranty"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitPhone1')"
|
||||
ref="phone1"
|
||||
data-cy="phone1"
|
||||
:error-messages="form().serverErrors(this, 'phone1')"
|
||||
@input="fieldValueChanged('phone1')"
|
||||
></gz-phone>
|
||||
:label="$ay.t('UnitOverrideLifeTime')"
|
||||
ref="lifeTimeWarranty"
|
||||
data-cy="lifeTimeWarranty"
|
||||
:error-messages="
|
||||
form().serverErrors(this, 'lifeTimeWarranty')
|
||||
"
|
||||
@change="fieldValueChanged('lifeTimeWarranty')"
|
||||
></v-checkbox>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'Phone2')"
|
||||
v-if="form().showMe(this, 'UnitOverrideLength')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<gz-phone
|
||||
v-model="obj.phone2"
|
||||
<v-text-field
|
||||
v-model="obj.warrantyLength"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitPhone2')"
|
||||
ref="phone2"
|
||||
data-cy="phone2"
|
||||
:error-messages="form().serverErrors(this, 'phone2')"
|
||||
@input="fieldValueChanged('phone2')"
|
||||
></gz-phone>
|
||||
:label="$ay.t('UnitOverrideLength')"
|
||||
ref="warrantyLength"
|
||||
data-cy="warrantyLength"
|
||||
:rules="[form().integerValid(this, 'warrantyLength')]"
|
||||
:error-messages="
|
||||
form().serverErrors(this, 'warrantyLength')
|
||||
"
|
||||
@input="fieldValueChanged('warrantyLength')"
|
||||
type="number"
|
||||
></v-text-field>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'Phone3')"
|
||||
v-if="form().showMe(this, 'UnitOverrideWarrantyTerms')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<gz-phone
|
||||
v-model="obj.phone3"
|
||||
<v-textarea
|
||||
v-model="obj.warrantyTerms"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitPhone3')"
|
||||
ref="phone3"
|
||||
data-cy="phone3"
|
||||
:error-messages="form().serverErrors(this, 'phone3')"
|
||||
@input="fieldValueChanged('phone3')"
|
||||
></gz-phone>
|
||||
:label="$ay.t('UnitOverrideWarrantyTerms')"
|
||||
:error-messages="form().serverErrors(this, 'warrantyTerms')"
|
||||
ref="warrantyTerms"
|
||||
data-cy="warrantyTerms"
|
||||
@input="fieldValueChanged('warrantyTerms')"
|
||||
auto-grow
|
||||
></v-textarea>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'Phone4')"
|
||||
v-if="form().showMe(this, 'UnitText1')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<gz-phone
|
||||
v-model="obj.phone4"
|
||||
<v-text-field
|
||||
v-model="obj.text1"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitPhone4')"
|
||||
ref="phone4"
|
||||
data-cy="phone4"
|
||||
:error-messages="form().serverErrors(this, 'phone4')"
|
||||
@input="fieldValueChanged('phone4')"
|
||||
></gz-phone>
|
||||
:label="$ay.t('UnitText1')"
|
||||
:error-messages="form().serverErrors(this, 'text1')"
|
||||
ref="text1"
|
||||
data-cy="text1"
|
||||
@input="fieldValueChanged('text1')"
|
||||
></v-text-field>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'Phone5')"
|
||||
v-if="form().showMe(this, 'UnitText2')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<gz-phone
|
||||
v-model="obj.phone5"
|
||||
<v-text-field
|
||||
v-model="obj.text2"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitPhone5')"
|
||||
ref="phone5"
|
||||
data-cy="phone5"
|
||||
:error-messages="form().serverErrors(this, 'phone5')"
|
||||
@input="fieldValueChanged('phone5')"
|
||||
></gz-phone>
|
||||
:label="$ay.t('UnitText2')"
|
||||
:error-messages="form().serverErrors(this, 'text2')"
|
||||
ref="text2"
|
||||
data-cy="text2"
|
||||
@input="fieldValueChanged('text2')"
|
||||
></v-text-field>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'UnitText3')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<v-text-field
|
||||
v-model="obj.text3"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitText3')"
|
||||
:error-messages="form().serverErrors(this, 'text3')"
|
||||
ref="text3"
|
||||
data-cy="text3"
|
||||
@input="fieldValueChanged('text3')"
|
||||
></v-text-field>
|
||||
</v-col>
|
||||
|
||||
<v-col
|
||||
v-if="form().showMe(this, 'UnitText4')"
|
||||
cols="12"
|
||||
sm="6"
|
||||
lg="4"
|
||||
xl="3"
|
||||
>
|
||||
<v-text-field
|
||||
v-model="obj.text4"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitText4')"
|
||||
:error-messages="form().serverErrors(this, 'text4')"
|
||||
ref="text4"
|
||||
data-cy="text4"
|
||||
@input="fieldValueChanged('text4')"
|
||||
></v-text-field>
|
||||
</v-col>
|
||||
|
||||
<!-- --------------------------------- -->
|
||||
@@ -389,35 +450,6 @@
|
||||
></v-textarea>
|
||||
</v-col>
|
||||
|
||||
<v-col v-if="form().showMe(this, 'ContactNotes')" cols="12">
|
||||
<v-textarea
|
||||
v-model="obj.contactNotes"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitContactNotes')"
|
||||
:error-messages="form().serverErrors(this, 'contactNotes')"
|
||||
ref="contactNotes"
|
||||
data-cy="contactNotes"
|
||||
@input="fieldValueChanged('contactNotes')"
|
||||
auto-grow
|
||||
prepend-icon="$ayiUser"
|
||||
></v-textarea>
|
||||
</v-col>
|
||||
|
||||
<v-col v-if="form().showMe(this, 'PopUpNotes')" cols="12">
|
||||
<v-textarea
|
||||
v-model="obj.popUpNotes"
|
||||
:readonly="formState.readOnly"
|
||||
:label="$ay.t('UnitPopUpNotes')"
|
||||
:error-messages="form().serverErrors(this, 'popUpNotes')"
|
||||
ref="popUpNotes"
|
||||
data-cy="popUpNotes"
|
||||
@input="fieldValueChanged('popUpNotes')"
|
||||
auto-grow
|
||||
prepend-icon="$ayiExclamationCircle"
|
||||
color="accent"
|
||||
></v-textarea>
|
||||
</v-col>
|
||||
|
||||
<v-col v-if="form().showMe(this, 'Tags')" cols="12">
|
||||
<gz-tag-picker
|
||||
v-model="obj.tags"
|
||||
@@ -844,7 +876,7 @@ export default {
|
||||
}
|
||||
},
|
||||
canOpenMeter: function() {
|
||||
return this.obj.usesBanking == true && this.$route.params.recordid != 0;
|
||||
return this.obj.metered == true && this.$route.params.recordid != 0;
|
||||
},
|
||||
openMeter: function() {
|
||||
if (this.canOpenMeter()) {
|
||||
@@ -1296,6 +1328,30 @@ function generateMenu(vm) {
|
||||
|
||||
menuOptions.menuItems.push({ divider: true, inset: false });
|
||||
|
||||
//---- SHOW ALL ---
|
||||
//MIGRATE_OUTSTANDING show all: workorderlist, unitlist, quotelist, pmlist
|
||||
menuOptions.menuItems.push({
|
||||
title: "WorkOrderList",
|
||||
icon: "$ayiTools",
|
||||
key: FORM_KEY + ":WorkOrderList",
|
||||
vm: vm
|
||||
});
|
||||
|
||||
menuOptions.menuItems.push({
|
||||
title: "QuoteList",
|
||||
icon: "$ayiPencilAlt",
|
||||
key: FORM_KEY + ":QuoteList",
|
||||
vm: vm
|
||||
});
|
||||
|
||||
menuOptions.menuItems.push({
|
||||
title: "PMList",
|
||||
icon: "$ayiBusinessTime",
|
||||
key: FORM_KEY + ":PMList",
|
||||
vm: vm
|
||||
});
|
||||
//--- /show all ---
|
||||
|
||||
menuOptions.menuItems.push({
|
||||
title: "GeoView",
|
||||
icon: "$ayiMapMarked",
|
||||
|
||||
Reference in New Issue
Block a user