This commit is contained in:
@@ -68,272 +68,158 @@
|
|||||||
}}<v-icon right large>$ayiTrashRestoreAlt</v-icon></v-btn
|
}}<v-icon right large>$ayiTrashRestoreAlt</v-icon></v-btn
|
||||||
>
|
>
|
||||||
|
|
||||||
-------------------------------------------------------------
|
|
||||||
|
|
||||||
<v-col
|
<v-col
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborName')"
|
v-if="form().showMe(this, 'WorkOrderItemLaborServiceStartDate')"
|
||||||
cols="12"
|
cols="12"
|
||||||
sm="6"
|
sm="6"
|
||||||
lg="4"
|
lg="4"
|
||||||
xl="3"
|
xl="3"
|
||||||
>
|
>
|
||||||
<v-text-field
|
<gz-date-time-picker
|
||||||
|
:label="$ay.t('WorkOrderItemLaborServiceStartDate')"
|
||||||
v-model="
|
v-model="
|
||||||
value.items[activeWoItemIndex].labors[activeItemIndex].name
|
value.items[activeWoItemIndex].labors[activeItemIndex]
|
||||||
|
.serviceStartDate
|
||||||
"
|
"
|
||||||
:readonly="formState.readOnly"
|
:readonly="formState.readOnly"
|
||||||
:disabled="isDeleted"
|
:disabled="isDeleted"
|
||||||
:label="$ay.t('WorkOrderItemLaborName')"
|
|
||||||
:ref="
|
:ref="
|
||||||
`Items[${activeWoItemIndex}].labors[
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceStartDate`
|
||||||
${activeItemIndex}
|
|
||||||
].name`
|
|
||||||
"
|
"
|
||||||
|
data-cy="serviceStartDate"
|
||||||
:error-messages="
|
:error-messages="
|
||||||
form().serverErrors(
|
form().serverErrors(
|
||||||
this,
|
this,
|
||||||
`Items[${activeWoItemIndex}].labors[
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceStartDate`
|
||||||
${activeItemIndex}
|
|
||||||
].name`
|
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
@input="
|
@input="
|
||||||
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
fieldValueChanged(
|
||||||
${activeItemIndex}
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceStartDate`
|
||||||
].name`)
|
)
|
||||||
"
|
"
|
||||||
></v-text-field>
|
></gz-date-time-picker>
|
||||||
</v-col>
|
</v-col>
|
||||||
|
|
||||||
<v-col
|
<v-col
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborTotalCost')"
|
v-if="form().showMe(this, 'WorkOrderItemLaborServiceStopDate')"
|
||||||
cols="12"
|
cols="12"
|
||||||
sm="6"
|
sm="6"
|
||||||
lg="4"
|
lg="4"
|
||||||
xl="3"
|
xl="3"
|
||||||
>
|
>
|
||||||
<gz-currency
|
<gz-date-time-picker
|
||||||
v-model="
|
:label="$ay.t('WorkOrderItemLaborServiceStopDate')"
|
||||||
value.items[activeWoItemIndex].labors[activeItemIndex].totalCost
|
|
||||||
"
|
|
||||||
:readonly="formState.readOnly || isDeleted"
|
|
||||||
:disabled="isDeleted"
|
|
||||||
:label="$ay.t('WorkOrderItemLaborTotalCost')"
|
|
||||||
:ref="
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].totalCost`
|
|
||||||
"
|
|
||||||
data-cy="laborTotalCost"
|
|
||||||
:error-messages="
|
|
||||||
form().serverErrors(
|
|
||||||
this,
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].totalCost`
|
|
||||||
)
|
|
||||||
"
|
|
||||||
:rules="[
|
|
||||||
form().decimalValid(
|
|
||||||
this,
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].totalCost`
|
|
||||||
),
|
|
||||||
form().required(
|
|
||||||
this,
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].totalCost`
|
|
||||||
)
|
|
||||||
]"
|
|
||||||
@input="
|
|
||||||
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
|
||||||
${activeItemIndex}
|
|
||||||
].totalCost`)
|
|
||||||
"
|
|
||||||
></gz-currency>
|
|
||||||
</v-col>
|
|
||||||
|
|
||||||
<v-col
|
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborChargeAmount')"
|
|
||||||
cols="12"
|
|
||||||
sm="6"
|
|
||||||
lg="4"
|
|
||||||
xl="3"
|
|
||||||
>
|
|
||||||
<gz-currency
|
|
||||||
v-model="
|
v-model="
|
||||||
value.items[activeWoItemIndex].labors[activeItemIndex]
|
value.items[activeWoItemIndex].labors[activeItemIndex]
|
||||||
.chargeAmount
|
.serviceStopDate
|
||||||
"
|
|
||||||
:readonly="formState.readOnly || isDeleted"
|
|
||||||
:disabled="isDeleted"
|
|
||||||
:label="$ay.t('WorkOrderItemLaborChargeAmount')"
|
|
||||||
:ref="
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeAmount`
|
|
||||||
"
|
|
||||||
data-cy="laborChargeAmount"
|
|
||||||
:error-messages="
|
|
||||||
form().serverErrors(
|
|
||||||
this,
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeAmount`
|
|
||||||
)
|
|
||||||
"
|
|
||||||
:rules="[
|
|
||||||
form().decimalValid(
|
|
||||||
this,
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeAmount`
|
|
||||||
),
|
|
||||||
form().required(
|
|
||||||
this,
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeAmount`
|
|
||||||
)
|
|
||||||
]"
|
|
||||||
@input="
|
|
||||||
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
|
||||||
${activeItemIndex}
|
|
||||||
].chargeAmount`)
|
|
||||||
"
|
|
||||||
></gz-currency>
|
|
||||||
</v-col>
|
|
||||||
|
|
||||||
<v-col
|
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborChargeToCustomer')"
|
|
||||||
cols="12"
|
|
||||||
sm="6"
|
|
||||||
lg="4"
|
|
||||||
xl="3"
|
|
||||||
>
|
|
||||||
<v-checkbox
|
|
||||||
v-model="
|
|
||||||
value.items[activeWoItemIndex].labors[activeItemIndex]
|
|
||||||
.chargeToCustomer
|
|
||||||
"
|
"
|
||||||
:readonly="formState.readOnly"
|
:readonly="formState.readOnly"
|
||||||
:disabled="isDeleted"
|
:disabled="isDeleted"
|
||||||
:label="$ay.t('WorkOrderItemLaborChargeToCustomer')"
|
|
||||||
:ref="
|
:ref="
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeToCustomer`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceStopDate`
|
||||||
"
|
"
|
||||||
data-cy="chargeToCustomer"
|
data-cy="serviceStopDate"
|
||||||
|
:rules="[
|
||||||
|
form().datePrecedence(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceStartDate`,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceStopDate`
|
||||||
|
)
|
||||||
|
]"
|
||||||
:error-messages="
|
:error-messages="
|
||||||
form().serverErrors(
|
form().serverErrors(
|
||||||
this,
|
this,
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeToCustomer`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceStopDate`
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
@change="
|
@input="
|
||||||
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
fieldValueChanged(
|
||||||
${activeItemIndex}
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceStopDate`
|
||||||
].chargeToCustomer`)
|
)
|
||||||
"
|
"
|
||||||
></v-checkbox>
|
></gz-date-time-picker>
|
||||||
</v-col>
|
</v-col>
|
||||||
|
|
||||||
<v-col
|
<v-col
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborTaxPaid')"
|
v-if="form().showMe(this, 'WorkOrderItemLaborServiceRateQuantity')"
|
||||||
cols="12"
|
cols="12"
|
||||||
sm="6"
|
sm="6"
|
||||||
lg="4"
|
lg="4"
|
||||||
xl="3"
|
xl="3"
|
||||||
>
|
>
|
||||||
<gz-currency
|
<gz-decimal
|
||||||
v-model="
|
v-model="
|
||||||
value.items[activeWoItemIndex].labors[activeItemIndex].taxPaid
|
value.items[activeWoItemIndex].labors[activeItemIndex]
|
||||||
|
.serviceRateQuantity
|
||||||
"
|
"
|
||||||
:readonly="formState.readOnly || isDeleted"
|
:readonly="formState.readOnly || isDeleted"
|
||||||
:disabled="isDeleted"
|
:disabled="isDeleted"
|
||||||
:label="$ay.t('WorkOrderItemLaborTaxPaid')"
|
:label="$ay.t('WorkOrderItemLaborServiceRateQuantity')"
|
||||||
:ref="
|
:ref="
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].taxPaid`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceRateQuantity`
|
||||||
"
|
"
|
||||||
data-cy="laborTaxPaid"
|
data-cy="laborServiceRateQuantity"
|
||||||
:error-messages="
|
:error-messages="
|
||||||
form().serverErrors(
|
form().serverErrors(
|
||||||
this,
|
this,
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].taxPaid`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceRateQuantity`
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
:rules="[
|
:rules="[
|
||||||
form().decimalValid(
|
form().decimalValid(
|
||||||
this,
|
this,
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].taxPaid`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceRateQuantity`
|
||||||
),
|
),
|
||||||
form().required(
|
form().required(
|
||||||
this,
|
this,
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].taxPaid`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceRateQuantity`
|
||||||
)
|
)
|
||||||
]"
|
]"
|
||||||
@input="
|
@input="
|
||||||
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
||||||
${activeItemIndex}
|
${activeItemIndex}
|
||||||
].taxPaid`)
|
].serviceRateQuantity`)
|
||||||
"
|
"
|
||||||
></gz-currency>
|
></gz-decimal>
|
||||||
</v-col>
|
</v-col>
|
||||||
|
|
||||||
<v-col
|
<v-col
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborChargeTaxCodeID')"
|
v-if="form().showMe(this, 'WorkOrderItemLaborServiceRateID')"
|
||||||
cols="12"
|
cols="12"
|
||||||
sm="6"
|
sm="6"
|
||||||
lg="4"
|
lg="4"
|
||||||
xl="3"
|
xl="3"
|
||||||
>
|
>
|
||||||
<gz-pick-list
|
<gz-pick-list
|
||||||
:aya-type="$ay.ayt().TaxCode"
|
:aya-type="$ay.ayt().ServiceRate"
|
||||||
:show-edit-icon="true"
|
:show-edit-icon="true"
|
||||||
v-model="
|
v-model="
|
||||||
value.items[activeWoItemIndex].labors[activeItemIndex]
|
value.items[activeWoItemIndex].labors[activeItemIndex]
|
||||||
.chargeTaxCodeId
|
.serviceRateId
|
||||||
"
|
"
|
||||||
:readonly="formState.readOnly || isDeleted"
|
:readonly="formState.readOnly || isDeleted"
|
||||||
:disabled="isDeleted"
|
:disabled="isDeleted"
|
||||||
:label="$ay.t('WorkOrderItemLaborChargeTaxCodeID')"
|
:label="$ay.t('WorkOrderItemLaborServiceRateID')"
|
||||||
:ref="
|
:ref="
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeTaxCodeId`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceRateId`
|
||||||
"
|
"
|
||||||
data-cy="laborChargeTaxCode"
|
data-cy="labors.serviceRateId"
|
||||||
:error-messages="
|
:error-messages="
|
||||||
form().serverErrors(
|
form().serverErrors(
|
||||||
this,
|
this,
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeTaxCodeId`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceRateId`
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
@input="
|
@input="
|
||||||
fieldValueChanged(
|
fieldValueChanged(
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].chargeTaxCodeId`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].serviceRateId`
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
@update:name="taxCodeChange"
|
@update:name="rateChange"
|
||||||
></gz-pick-list>
|
></gz-pick-list>
|
||||||
</v-col>
|
</v-col>
|
||||||
|
|
||||||
<v-col
|
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborReimburseUser')"
|
|
||||||
cols="12"
|
|
||||||
sm="6"
|
|
||||||
lg="4"
|
|
||||||
xl="3"
|
|
||||||
>
|
|
||||||
<v-checkbox
|
|
||||||
v-model="
|
|
||||||
value.items[activeWoItemIndex].labors[activeItemIndex]
|
|
||||||
.reimburseUser
|
|
||||||
"
|
|
||||||
:readonly="formState.readOnly"
|
|
||||||
:disabled="isDeleted"
|
|
||||||
:label="$ay.t('WorkOrderItemLaborReimburseUser')"
|
|
||||||
:ref="
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].reimburseUser`
|
|
||||||
"
|
|
||||||
data-cy="laborReimburseUser"
|
|
||||||
:error-messages="
|
|
||||||
form().serverErrors(
|
|
||||||
this,
|
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].reimburseUser`
|
|
||||||
)
|
|
||||||
"
|
|
||||||
@change="
|
|
||||||
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
|
||||||
${activeItemIndex}
|
|
||||||
].reimburseUser`)
|
|
||||||
"
|
|
||||||
></v-checkbox>
|
|
||||||
</v-col>
|
|
||||||
|
|
||||||
<v-col
|
<v-col
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborUserID')"
|
v-if="form().showMe(this, 'WorkOrderItemLaborUserID')"
|
||||||
cols="12"
|
cols="12"
|
||||||
@@ -354,7 +240,7 @@
|
|||||||
:ref="
|
:ref="
|
||||||
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].userId`
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].userId`
|
||||||
"
|
"
|
||||||
data-cy="laborUser"
|
data-cy="labors.userid"
|
||||||
:error-messages="
|
:error-messages="
|
||||||
form().serverErrors(
|
form().serverErrors(
|
||||||
this,
|
this,
|
||||||
@@ -371,34 +257,241 @@
|
|||||||
</v-col>
|
</v-col>
|
||||||
|
|
||||||
<v-col
|
<v-col
|
||||||
v-if="form().showMe(this, 'WorkOrderItemLaborDescription')"
|
v-if="form().showMe(this, 'WorkOrderItemLaborNoChargeQuantity')"
|
||||||
|
cols="12"
|
||||||
|
sm="6"
|
||||||
|
lg="4"
|
||||||
|
xl="3"
|
||||||
|
>
|
||||||
|
<gz-decimal
|
||||||
|
v-model="
|
||||||
|
value.items[activeWoItemIndex].labors[activeItemIndex]
|
||||||
|
.noChargeQuantity
|
||||||
|
"
|
||||||
|
:readonly="formState.readOnly || isDeleted"
|
||||||
|
:disabled="isDeleted"
|
||||||
|
:label="$ay.t('WorkOrderItemLaborNoChargeQuantity')"
|
||||||
|
:ref="
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].noChargeQuantity`
|
||||||
|
"
|
||||||
|
data-cy="laborNoChargeQuantity"
|
||||||
|
:error-messages="
|
||||||
|
form().serverErrors(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].noChargeQuantity`
|
||||||
|
)
|
||||||
|
"
|
||||||
|
:rules="[
|
||||||
|
form().decimalValid(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].noChargeQuantity`
|
||||||
|
),
|
||||||
|
form().required(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].noChargeQuantity`
|
||||||
|
)
|
||||||
|
]"
|
||||||
|
@input="
|
||||||
|
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
||||||
|
${activeItemIndex}
|
||||||
|
].noChargeQuantity`)
|
||||||
|
"
|
||||||
|
></gz-decimal>
|
||||||
|
</v-col>
|
||||||
|
|
||||||
|
<v-col
|
||||||
|
v-if="form().showMe(this, 'WorkOrderItemLaborTaxRateSaleID')"
|
||||||
|
cols="12"
|
||||||
|
sm="6"
|
||||||
|
lg="4"
|
||||||
|
xl="3"
|
||||||
|
>
|
||||||
|
<gz-pick-list
|
||||||
|
:aya-type="$ay.ayt().TaxCode"
|
||||||
|
:show-edit-icon="true"
|
||||||
|
v-model="
|
||||||
|
value.items[activeWoItemIndex].labors[activeItemIndex]
|
||||||
|
.taxCodeSaleId
|
||||||
|
"
|
||||||
|
:readonly="formState.readOnly || isDeleted"
|
||||||
|
:disabled="isDeleted"
|
||||||
|
:label="$ay.t('WorkOrderItemLaborTaxRateSaleID')"
|
||||||
|
:ref="
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].taxCodeSaleId`
|
||||||
|
"
|
||||||
|
data-cy="laborTaxCodeSaleId"
|
||||||
|
:error-messages="
|
||||||
|
form().serverErrors(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].taxCodeSaleId`
|
||||||
|
)
|
||||||
|
"
|
||||||
|
@input="
|
||||||
|
fieldValueChanged(
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].taxCodeSaleId`
|
||||||
|
)
|
||||||
|
"
|
||||||
|
@update:name="taxCodeChange"
|
||||||
|
></gz-pick-list>
|
||||||
|
</v-col>
|
||||||
|
|
||||||
|
<v-col
|
||||||
|
v-if="form().showMe(this, 'WorkOrderItemLaborManualDiscountPct')"
|
||||||
|
cols="12"
|
||||||
|
sm="6"
|
||||||
|
lg="4"
|
||||||
|
xl="3"
|
||||||
|
>
|
||||||
|
<gz-percent
|
||||||
|
v-model="
|
||||||
|
value.items[activeWoItemIndex].labors[activeItemIndex]
|
||||||
|
.manualDiscountPct
|
||||||
|
"
|
||||||
|
:readonly="formState.readOnly || isDeleted"
|
||||||
|
:disabled="isDeleted"
|
||||||
|
:label="$ay.t('WorkOrderItemLaborManualDiscountPct')"
|
||||||
|
:ref="
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].manualDiscountPct`
|
||||||
|
"
|
||||||
|
data-cy="laborManualDiscountPct"
|
||||||
|
:error-messages="
|
||||||
|
form().serverErrors(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].manualDiscountPct`
|
||||||
|
)
|
||||||
|
"
|
||||||
|
:rules="[
|
||||||
|
form().decimalValid(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].manualDiscountPct`
|
||||||
|
),
|
||||||
|
form().required(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].manualDiscountPct`
|
||||||
|
)
|
||||||
|
]"
|
||||||
|
@input="
|
||||||
|
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
||||||
|
${activeItemIndex}
|
||||||
|
].manualDiscountPct`)
|
||||||
|
"
|
||||||
|
></gz-percent>
|
||||||
|
</v-col>
|
||||||
|
|
||||||
|
<v-col
|
||||||
|
v-if="form().showMe(this, 'WorkOrderItemLaborBasePrice')"
|
||||||
|
cols="12"
|
||||||
|
sm="6"
|
||||||
|
lg="4"
|
||||||
|
xl="3"
|
||||||
|
>
|
||||||
|
<gz-currency
|
||||||
|
v-model="
|
||||||
|
value.items[activeWoItemIndex].labors[activeItemIndex].basePrice
|
||||||
|
"
|
||||||
|
:readonly="formState.readOnly || isDeleted"
|
||||||
|
:disabled="isDeleted"
|
||||||
|
:label="$ay.t('WorkOrderItemLaborBasePrice')"
|
||||||
|
:ref="
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].basePrice`
|
||||||
|
"
|
||||||
|
data-cy="laborbasePrice"
|
||||||
|
:error-messages="
|
||||||
|
form().serverErrors(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].basePrice`
|
||||||
|
)
|
||||||
|
"
|
||||||
|
:rules="[
|
||||||
|
form().decimalValid(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].basePrice`
|
||||||
|
),
|
||||||
|
form().required(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].basePrice`
|
||||||
|
)
|
||||||
|
]"
|
||||||
|
@input="
|
||||||
|
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
||||||
|
${activeItemIndex}
|
||||||
|
].basePrice`)
|
||||||
|
"
|
||||||
|
></gz-currency>
|
||||||
|
</v-col>
|
||||||
|
|
||||||
|
<v-col
|
||||||
|
v-if="form().showMe(this, 'WorkOrderItemLaborPrice')"
|
||||||
|
cols="12"
|
||||||
|
sm="6"
|
||||||
|
lg="4"
|
||||||
|
xl="3"
|
||||||
|
>
|
||||||
|
<gz-currency
|
||||||
|
v-model="
|
||||||
|
value.items[activeWoItemIndex].labors[activeItemIndex].price
|
||||||
|
"
|
||||||
|
:readonly="formState.readOnly || isDeleted"
|
||||||
|
:disabled="isDeleted"
|
||||||
|
:label="$ay.t('WorkOrderItemLaborPrice')"
|
||||||
|
:ref="
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].price`
|
||||||
|
"
|
||||||
|
data-cy="laborprice"
|
||||||
|
:error-messages="
|
||||||
|
form().serverErrors(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].price`
|
||||||
|
)
|
||||||
|
"
|
||||||
|
:rules="[
|
||||||
|
form().decimalValid(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].price`
|
||||||
|
),
|
||||||
|
form().required(
|
||||||
|
this,
|
||||||
|
`Items[${activeWoItemIndex}].labors[${activeItemIndex}].price`
|
||||||
|
)
|
||||||
|
]"
|
||||||
|
@input="
|
||||||
|
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
||||||
|
${activeItemIndex}
|
||||||
|
].price`)
|
||||||
|
"
|
||||||
|
></gz-currency>
|
||||||
|
</v-col>
|
||||||
|
|
||||||
|
<v-col
|
||||||
|
v-if="form().showMe(this, 'WorkOrderItemLaborServiceDetails')"
|
||||||
cols="12"
|
cols="12"
|
||||||
>
|
>
|
||||||
<v-textarea
|
<v-textarea
|
||||||
v-model="
|
v-model="
|
||||||
value.items[activeWoItemIndex].labors[activeItemIndex].description
|
value.items[activeWoItemIndex].labors[activeItemIndex]
|
||||||
|
.serviceDetails
|
||||||
"
|
"
|
||||||
:readonly="formState.readOnly"
|
:readonly="formState.readOnly"
|
||||||
:disabled="isDeleted"
|
:disabled="isDeleted"
|
||||||
:label="$ay.t('WorkOrderItemLaborDescription')"
|
:label="$ay.t('WorkOrderItemLaborServiceDetails')"
|
||||||
:error-messages="
|
:error-messages="
|
||||||
form().serverErrors(
|
form().serverErrors(
|
||||||
this,
|
this,
|
||||||
`Items[${activeWoItemIndex}].labors[
|
`Items[${activeWoItemIndex}].labors[
|
||||||
${activeItemIndex}
|
${activeItemIndex}
|
||||||
].description`
|
].serviceDetails`
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
:ref="
|
:ref="
|
||||||
`Items[${activeWoItemIndex}].labors[
|
`Items[${activeWoItemIndex}].labors[
|
||||||
${activeItemIndex}
|
${activeItemIndex}
|
||||||
].description`
|
].serviceDetails`
|
||||||
"
|
"
|
||||||
data-cy="laborDescription"
|
data-cy="laborserviceDetails"
|
||||||
@input="
|
@input="
|
||||||
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
fieldValueChanged(`Items[${activeWoItemIndex}].labors[
|
||||||
${activeItemIndex}
|
${activeItemIndex}
|
||||||
].description`)
|
].serviceDetails`)
|
||||||
"
|
"
|
||||||
auto-grow
|
auto-grow
|
||||||
></v-textarea>
|
></v-textarea>
|
||||||
@@ -510,10 +603,15 @@ export default {
|
|||||||
this.activeItemIndex
|
this.activeItemIndex
|
||||||
].userViz = newName;
|
].userViz = newName;
|
||||||
},
|
},
|
||||||
|
rateChange(newName) {
|
||||||
|
this.value.items[this.activeWoItemIndex].labors[
|
||||||
|
this.activeItemIndex
|
||||||
|
].serviceRateViz = newName;
|
||||||
|
},
|
||||||
taxCodeChange(newName) {
|
taxCodeChange(newName) {
|
||||||
this.value.items[this.activeWoItemIndex].labors[
|
this.value.items[this.activeWoItemIndex].labors[
|
||||||
this.activeItemIndex
|
this.activeItemIndex
|
||||||
].chargeTaxCodeViz = newName;
|
].taxCodeSaleViz = newName;
|
||||||
},
|
},
|
||||||
newItem() {
|
newItem() {
|
||||||
let newIndex = this.value.items[this.activeWoItemIndex].labors.length;
|
let newIndex = this.value.items[this.activeWoItemIndex].labors.length;
|
||||||
|
|||||||
Reference in New Issue
Block a user