This commit is contained in:
2021-07-02 18:14:28 +00:00
parent a03a75132c
commit cd02d61bc7
3 changed files with 44 additions and 9 deletions

View File

@@ -422,6 +422,19 @@ todo: many biz objects are not using new PUT methodology
CURRENTLY DOING: serials on wo
issue: serials probably shouldn't be a free-form text box or stored or handled that way but instead as a list like tags are at the back end
and in a list control at the front end
UI:
entry mode
table below a single entry box
click on a row to edit in the entry box
click on a delete button to remove an entry
display mode
shows as a table
maybe don't need modes, can just use the same ui to view and edit and just remove the edit bits if readonly
todo: make sure serials are de-duped at the server anywhere it accepts raw serial data from client
todo: picking from existing serial numbers for parts on workorder
see work order item parts for notes and what to do
close 3839 when done

View File

@@ -419,10 +419,18 @@
serial picker / entry
</v-card-text>
<v-card-actions>
<v-spacer />
<v-btn text @click="serialDialog = false" color="primary">{{
$ay.t("Close")
$ay.t("Cancel")
}}</v-btn>
<v-spacer></v-spacer>
<!-- :disabled="selectedPartAssembly == null" -->
<v-btn
color="primary"
text
@click="addSelectedSerials()"
class="ml-4"
>{{ $ay.t("Add") }}</v-btn
>
</v-card-actions>
</v-card>
</v-dialog>
@@ -515,13 +523,17 @@ export default {
return;
}
let res = await window.$gz.api.get(`part/serials/${partId}`);
if(res.error){
//display info box error here, see recent code where did that forget at the moment because .... you know why :)
}else{
console.log(res);
this.serialDialog = true;
if (res.error) {
window.$gz.eventBus.$emit(
"notify-warning",
window.$gz.errorHandler.errorToString(res, this)
);
} else {
this.serialDialog = true;
}
},
addSelectedSerials() {
},
async addPartAssembly() {
let res = await window.$gz.api.get(

View File

@@ -1,7 +1,13 @@
<template>
<div>
<v-row justify="center">
<v-dialog v-model="openDialog" persistent max-width="600px">
<v-dialog
@keydown.esc="openDialog = false"
@keydown.enter="openWo()"
v-model="openDialog"
persistent
max-width="600px"
>
<v-card>
<v-card-title>
<span class="text-h5">{{ $ay.t("Open") }}</span>
@@ -10,6 +16,7 @@
<v-text-field
v-model="openWoNumber"
:label="$ay.t('WorkOrder')"
autofocus
required
type="number"
></v-text-field>
@@ -79,6 +86,9 @@ export default {
},
async openWo() {
if (!this.openWoNumber) {
return;
}
//get id from number then push open
let res = await window.$gz.api.get(
"workorder/id-from-number/" + this.openWoNumber