rev:托盘拣选出库流程
This commit is contained in:
@@ -95,16 +95,15 @@
|
||||
</el-table-column>
|
||||
<el-table-column prop="parent_id" width="200" label="父流程" />
|
||||
<el-table-column prop="def_name" width="200" label="部署名称" />
|
||||
<el-table-column prop="def_model_key" width="200" label="模型KEY" />
|
||||
<!-- <el-table-column prop="def_description" width="200" label="部署描述" />-->
|
||||
<!-- <el-table-column prop="def_description" width="200" label="部署描述" />-->
|
||||
<el-table-column v-if="false" prop="deployment_id" label="流程部署ID" />
|
||||
<!-- <el-table-column-->
|
||||
<!-- prop="deployment_name"-->
|
||||
<!-- show-overflow-tooltip-->
|
||||
<!-- show-tooltip-when-overflow-->
|
||||
<!-- width="130"-->
|
||||
<!-- label="流程模型"-->
|
||||
<!-- />-->
|
||||
<!-- <el-table-column-->
|
||||
<!-- prop="deployment_name"-->
|
||||
<!-- show-overflow-tooltip-->
|
||||
<!-- show-tooltip-when-overflow-->
|
||||
<!-- width="130"-->
|
||||
<!-- label="流程模型"-->
|
||||
<!-- />-->
|
||||
<el-table-column v-if="false" prop="activity_id" label="当前节点ID" />
|
||||
<el-table-column
|
||||
prop="activity_name"
|
||||
@@ -113,23 +112,24 @@
|
||||
width="130"
|
||||
label="当前节点"
|
||||
/>
|
||||
<el-table-column prop="is_active" label="启用">
|
||||
<template slot-scope="scope">
|
||||
<el-switch
|
||||
v-model="scope.row.is_active"
|
||||
active-color="#13ce66"
|
||||
:active-value="true"
|
||||
:inactive-value="false"
|
||||
inactive-color="#ff4949"
|
||||
@change="changeActive(scope.row)"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column prop="is_active" label="启用">-->
|
||||
<!-- <template slot-scope="scope">-->
|
||||
<!-- <el-switch-->
|
||||
<!-- v-model="scope.row.is_active"-->
|
||||
<!-- active-color="#13ce66"-->
|
||||
<!-- :active-value="true"-->
|
||||
<!-- :inactive-value="false"-->
|
||||
<!-- inactive-color="#ff4949"-->
|
||||
<!-- @change="changeActive(scope.row)"-->
|
||||
<!-- />-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<el-table-column prop="status" label="实例状态">
|
||||
<template slot-scope="scope">
|
||||
{{ statusEnum.label.FLOW_STATUS[scope.row.status] }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="def_model_key" width="200" label="模型KEY" />
|
||||
<el-table-column prop="remark" show-overflow-tooltip show-tooltip-when-overflow label="备注" />
|
||||
<el-table-column prop="form_type" show-overflow-tooltip show-tooltip-when-overflow width="130" label="表单类型" />
|
||||
<el-table-column prop="form_id" show-overflow-tooltip show-tooltip-when-overflow width="130" label="表单id" />
|
||||
@@ -306,12 +306,12 @@ export default {
|
||||
})
|
||||
},
|
||||
flowConfirm(proc_inst_id) {
|
||||
curdExecution.flowConfirm(proc_inst_id).then(res => {
|
||||
curdExecution.flowConfirm(proc_inst_id).then(res => {
|
||||
crud.notify('操作成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
this.crud.toQuery()
|
||||
},
|
||||
async load(tree, treeNode, resolve) {
|
||||
async load(tree, treeNode, resolve) {
|
||||
curdExecution.queryByParentId(tree.proc_inst_id).then(res => {
|
||||
resolve(res)
|
||||
})
|
||||
|
||||
@@ -44,25 +44,26 @@
|
||||
<el-input v-model="form.status" disabled placeholder="生成" clearable style="width: 150px" />
|
||||
</el-form-item>
|
||||
<el-form-item label="源单类型" prop="source_form_type">
|
||||
<el-input v-model="form.source_form_type" clearable style="width: 150px" />
|
||||
<el-input v-model="form.source_form_type" clearable style="width: 150px" />
|
||||
</el-form-item>
|
||||
<el-form-item label="源单id" prop="source_form_id">
|
||||
<el-input v-model="form.source_form_id" clearable style="width: 150px" />
|
||||
<el-input v-model="form.source_form_id" clearable style="width: 150px" />
|
||||
</el-form-item>
|
||||
<el-form-item label="源单时间" prop="source_form_date">
|
||||
<el-input v-model="form.source_form_date" clearable style="width: 150px" />
|
||||
<el-input v-model="form.source_form_date" clearable style="width: 150px" />
|
||||
</el-form-item>
|
||||
<template v-for="(col,index) in cols">
|
||||
<el-form-item label="col.lable" prop="bill_code">
|
||||
<label slot="label">{{col.lable}}:</label>
|
||||
<el-select v-if="col.value == 'product_area'"
|
||||
v-model="form.form_data[col.value]"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="车间"
|
||||
class="filter-item"
|
||||
style="width: 120px"
|
||||
@change="areaChange"
|
||||
<label slot="label">{{ col.lable }}:</label>
|
||||
<el-select
|
||||
v-if="col.value == 'product_area'"
|
||||
v-model="form.form_data[col.value]"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="车间"
|
||||
class="filter-item"
|
||||
style="width: 120px"
|
||||
@change="areaChange"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in statusEnum.PRODUCT_AREA"
|
||||
@@ -76,7 +77,7 @@
|
||||
</template>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<label slot="label">备 注:</label>
|
||||
<el-input v-model="form.remark" style="width: 380px;" rows="2" type="textarea" />
|
||||
<el-input v-model="form.remark" style="width: 380px;" rows="2" type="textarea" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
@@ -84,14 +85,14 @@
|
||||
<span class="crud-opts-right2">
|
||||
<!--左侧插槽-->
|
||||
<slot name="left" />
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="insertEvent()"
|
||||
>
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="insertEvent()"
|
||||
>
|
||||
添加物料
|
||||
</el-button>
|
||||
<el-button
|
||||
@@ -120,15 +121,20 @@
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" />
|
||||
<el-table-column show-overflow-tooltip prop="material_spec" label="物料规格" />
|
||||
<el-table-column show-overflow-tooltip prop="pcsn" label="物料批次" width="160" align="center">
|
||||
<template scope="scope"><el-input v-model="tableData[scope.$index].pcsn" class="input-with-select" /></template>
|
||||
<template scope="scope"><el-input v-model="tableData[scope.$index].pcsn" class="input-with-select" /></template>
|
||||
</el-table-column>
|
||||
<el-table-column show-overflow-tooltip prop="qty" label="计划数量" width="160" align="center">
|
||||
<template scope="scope"><el-input-number v-model="tableData[scope.$index].qty" class="input-with-select" /></template>
|
||||
<template scope="scope"><el-input-number v-model="tableData[scope.$index].qty" class="input-with-select" /></template>
|
||||
</el-table-column>
|
||||
<el-table-column show-overflow-tooltip prop="unit_id" label="单位" width="160">
|
||||
<template slot-scope="scope">
|
||||
<el-select v-model="tableData[scope.$index].unit_id"
|
||||
class="filter-item" placeholder="单位" size="small" style="width: 90px">
|
||||
<el-select
|
||||
v-model="tableData[scope.$index].unit_id"
|
||||
class="filter-item"
|
||||
placeholder="单位"
|
||||
size="small"
|
||||
style="width: 90px"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in unitDict"
|
||||
:key="item.value"
|
||||
@@ -159,23 +165,24 @@
|
||||
</el-table-column>
|
||||
<el-table-column show-overflow-tooltip prop="source_form_type" label="源单类型" width="190" align="center">
|
||||
<template scope="scope">
|
||||
<el-input v-model="tableData[scope.$index].source_form_type" class="input-with-select" />
|
||||
<el-input v-model="tableData[scope.$index].source_form_type" class="input-with-select" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column show-overflow-tooltip prop="source_form_type" label="源单id" width="190" align="center">
|
||||
<template scope="scope">
|
||||
<el-input v-model="tableData[scope.$index].source_form_id" class="input-with-select" />
|
||||
<el-input v-model="tableData[scope.$index].source_form_id" class="input-with-select" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column v-for="(item, index) in dtlCols" :key="item.value" :label="item.lable" width="160">
|
||||
<el-table-column v-for="(item, index) in dtlCols" :key="item.value" :label="item.lable" width="160">
|
||||
<template scope="scope">
|
||||
<el-select v-if="item.value == 'product_area'"
|
||||
v-model="tableData[scope.$index].form_data[item.value]"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="车间"
|
||||
class="filter-item"
|
||||
style="width: 120px"
|
||||
<el-select
|
||||
v-if="item.value == 'product_area'"
|
||||
v-model="tableData[scope.$index].form_data[item.value]"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="车间"
|
||||
class="filter-item"
|
||||
style="width: 120px"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in statusEnum.PRODUCT_AREA"
|
||||
@@ -184,14 +191,14 @@
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
<el-input v-if="item.value != 'product_area'" disabled v-model="tableData[scope.$index].form_data[item.value]" class="input-with-select" />
|
||||
<el-input v-if="item.value != 'product_area'" v-model="tableData[scope.$index].form_data[item.value]" disabled class="input-with-select" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<label slot="label">备 注:</label>
|
||||
<template scope="scope">
|
||||
<el-input v-model="tableData[scope.$index].remark" rows="2" type="textarea"/>
|
||||
<el-input v-model="tableData[scope.$index].remark" rows="2" type="textarea" />
|
||||
</template>
|
||||
</el-form-item>
|
||||
<el-table-column v-if="crud.status.cu > 0" align="center" label="操作" width="170" fixed="right">
|
||||
@@ -230,7 +237,6 @@ import formstruc from '@/views/wms/config_manage/formStruc/formstruc'
|
||||
import measureunit from '@/views/wms/base_manage/measure/measureunit'
|
||||
import crudProductIn from '@/views/wms/stor_manage/out/storinvout'
|
||||
|
||||
|
||||
const defaultForm = {
|
||||
id: '',
|
||||
code: '',
|
||||
@@ -249,10 +255,10 @@ const defaultForm = {
|
||||
|
||||
export default {
|
||||
name: 'AddDialog',
|
||||
components: { formstruc, MaterDialog,measureunit, FormDialog },
|
||||
components: { formstruc, MaterDialog, measureunit, FormDialog },
|
||||
mixins: [crud(), form(defaultForm)],
|
||||
statusEnums: [ 'FORM_STATUS', 'IOBILL_TYPE_OUT', 'PRODUCT_AREA' ],
|
||||
tableEnums: [ 'st_ivt_bsrealstorattr#stor_name#stor_code' ],
|
||||
statusEnums: ['FORM_STATUS', 'IOBILL_TYPE_OUT', 'PRODUCT_AREA'],
|
||||
tableEnums: ['st_ivt_bsrealstorattr#stor_name#stor_code'],
|
||||
props: {
|
||||
dialogShow: {
|
||||
type: Boolean,
|
||||
@@ -264,9 +270,9 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
cols:[],
|
||||
dtlCols:[],
|
||||
tableData:[],
|
||||
cols: [],
|
||||
dtlCols: [],
|
||||
tableData: [],
|
||||
dialogVisible: false,
|
||||
materShow: false,
|
||||
id: '',
|
||||
@@ -279,7 +285,7 @@ export default {
|
||||
rules: {
|
||||
bill_type: [
|
||||
{ required: true, message: '单据类型不能为空', trigger: 'blur' }
|
||||
],
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -299,15 +305,15 @@ export default {
|
||||
formstruc.getHeader('st_ivt_iostorinv').then(res => {
|
||||
this.cols = res
|
||||
res.forEach(a => {
|
||||
this.form.form_data[a.value,'']
|
||||
this.form.form_data[a.value, '']
|
||||
})
|
||||
})
|
||||
formstruc.getHeader('st_ivt_iostorinvdtl').then(res => {
|
||||
this.dtlCols = res
|
||||
}),
|
||||
measureunit.getSelect().then(res => {
|
||||
this.unitDict = res.content
|
||||
})
|
||||
measureunit.getSelect().then(res => {
|
||||
this.unitDict = res.content
|
||||
})
|
||||
if (this.id !== '' && this.id !== null && this.id !== undefined) {
|
||||
crudProductIn.getIosInvDtl(this.id).then(res => {
|
||||
this.tableData = res
|
||||
@@ -319,7 +325,6 @@ export default {
|
||||
this.$emit('AddChanged')
|
||||
},
|
||||
|
||||
|
||||
insertEvent(row) {
|
||||
this.materShow = true
|
||||
},
|
||||
@@ -332,9 +337,9 @@ export default {
|
||||
this.materShow = true
|
||||
},
|
||||
|
||||
areaChange(val){
|
||||
if (this.tableData.length>0) {
|
||||
this.tableData.forEach(a=>{
|
||||
areaChange(val) {
|
||||
if (this.tableData.length > 0) {
|
||||
this.tableData.forEach(a => {
|
||||
this.$set(a.form_data, 'product_area', val)
|
||||
})
|
||||
}
|
||||
@@ -355,7 +360,7 @@ export default {
|
||||
return false
|
||||
}
|
||||
for (let i = 0; i < this.tableData.length; i++) {
|
||||
let itemDtl = this.tableData[i];
|
||||
const itemDtl = this.tableData[i]
|
||||
if (!itemDtl.unit_id) {
|
||||
this.crud.notify('单位不能为空', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return false
|
||||
@@ -382,7 +387,7 @@ export default {
|
||||
|
||||
tableDtlMaterial(rows) {
|
||||
rows.forEach((row) => {
|
||||
const data = {}
|
||||
const data = {}
|
||||
data.material_name = row.material_name
|
||||
data.material_code = row.material_code
|
||||
data.material_id = row.material_id
|
||||
@@ -392,34 +397,34 @@ export default {
|
||||
data.source_form_id = ''
|
||||
data.unit_id = row.unit_id
|
||||
data.form_data = {}
|
||||
this.dtlCols.forEach(a=>{
|
||||
this.dtlCols.forEach(a => {
|
||||
let item = ''
|
||||
if (a.value in data) {
|
||||
item = data[a.value];
|
||||
item = data[a.value]
|
||||
}
|
||||
this.$set(data.form_data,a.value,item)
|
||||
this.$set(data.form_data, a.value, item)
|
||||
})
|
||||
this.$set(data.form_data,'product_area',this.form.form_data.product_area)
|
||||
this.$set(data.form_data, 'product_area', this.form.form_data.product_area)
|
||||
this.tableData.splice(-1, 0, data)
|
||||
})
|
||||
},
|
||||
tableDtlMaterial2(data) {
|
||||
let mst = data['t'];
|
||||
let rows = [];
|
||||
const mst = data['t']
|
||||
let rows = []
|
||||
this.form.source_form_type = mst.form_type
|
||||
this.form.source_form_id = mst.id
|
||||
let mst_form_data = mst.form_data;
|
||||
if (data['item'] ==null || data['item'].length == 0){
|
||||
const mst_form_data = mst.form_data
|
||||
if (data['item'] == null || data['item'].length == 0) {
|
||||
rows.push(mst)
|
||||
}else {
|
||||
} else {
|
||||
rows = data['item']
|
||||
}
|
||||
this.cols.forEach(a=>{
|
||||
this.cols.forEach(a => {
|
||||
let item = ''
|
||||
if (a.value in mst_form_data) {
|
||||
item = mst_form_data[a.value];
|
||||
item = mst_form_data[a.value]
|
||||
}
|
||||
this.$set(this.form.form_data,a.value,item)
|
||||
this.$set(this.form.form_data, a.value, item)
|
||||
})
|
||||
rows.forEach((row) => {
|
||||
const data = {}
|
||||
@@ -430,16 +435,18 @@ export default {
|
||||
data.single_weight = row.single_weight
|
||||
data.source_form_type = row.form_type
|
||||
data.source_form_id = row.id
|
||||
data.pcsn = row.pcsn
|
||||
data.qty = row.qty
|
||||
data.unit_id = row.unit_id
|
||||
data.form_data = {}
|
||||
let fowFormData = row.form_data;
|
||||
let row_form_data = {...fowFormData,...data};
|
||||
this.dtlCols.forEach(a=>{
|
||||
const fowFormData = row.form_data
|
||||
const row_form_data = { ...fowFormData, ...data }
|
||||
this.dtlCols.forEach(a => {
|
||||
let item = ''
|
||||
if (a.value in row_form_data) {
|
||||
item = row_form_data[a.value];
|
||||
item = row_form_data[a.value]
|
||||
}
|
||||
this.$set(data.form_data,a.value,item)
|
||||
this.$set(data.form_data, a.value, item)
|
||||
})
|
||||
this.tableData.splice(-1, 0, data)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user