This commit is contained in:
@@ -21,6 +21,17 @@
|
||||
</v-list-item-icon>
|
||||
<v-list-item-title>{{ $ay.t("New") }}</v-list-item-title>
|
||||
</v-list-item>
|
||||
<v-list-item
|
||||
v-if="hasSelection && !formState.readOnly"
|
||||
@click="generateUnit"
|
||||
>
|
||||
<v-list-item-icon>
|
||||
<v-icon>$ayiFan</v-icon>
|
||||
</v-list-item-icon>
|
||||
<v-list-item-title>{{
|
||||
$ay.t("WorkOrderGenerateUnit")
|
||||
}}</v-list-item-title>
|
||||
</v-list-item>
|
||||
<v-list-item v-if="canAdd" @click="partAssemblyDialog = true">
|
||||
<v-list-item-icon>
|
||||
<v-icon>$ayiObjectGroup</v-icon>
|
||||
@@ -504,6 +515,23 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
generateUnit() {
|
||||
const thisPart = this.value.items[this.activeWoItemIndex].parts[
|
||||
this.activeItemIndex
|
||||
];
|
||||
this.$router.push({
|
||||
name: "svc-units",
|
||||
params: {
|
||||
recordid: 0,
|
||||
genFromPart: {
|
||||
customerId: this.value.customerId,
|
||||
partId: thisPart.partId,
|
||||
purchaseDate: this.value.serviceDate,
|
||||
serial: thisPart.serials
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
async selectSerials() {
|
||||
this.availableSerials.splice(0);
|
||||
this.selectedSerials.splice(0);
|
||||
|
||||
Reference in New Issue
Block a user