rev:流程引擎维护;todo:节点功能开发
This commit is contained in:
92
wms_pro/qd/src/views/wms/md_manage/group_dick/Dialog.vue
Normal file
92
wms_pro/qd/src/views/wms/md_manage/group_dick/Dialog.vue
Normal file
@@ -0,0 +1,92 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
title="发货单导入"
|
||||
append-to-body
|
||||
:visible.sync="dialogVisible"
|
||||
destroy-on-close
|
||||
:show-close="true"
|
||||
width="500px"
|
||||
v-loading.fullscreen.lock="fullscreenLoading"
|
||||
@close="close"
|
||||
>
|
||||
<div class="head-container">
|
||||
<div>
|
||||
<!-- 搜索 -->
|
||||
<el-form ref="form" :model="form1" :rules="rules" size="mini" label-width="110px">
|
||||
<el-form-item label="日期区间:" prop="createTime">
|
||||
<el-date-picker
|
||||
v-model="form.createTime"
|
||||
type="daterange"
|
||||
value-format="yyyy-MM-dd"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="发货单号:" prop="bill_code">
|
||||
<el-input v-model="form.bill_code" style="width: 350px;"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-button class="filter-item" size="mini" type="success" icon="el-icon-search" @click="queryStruct">确认
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import CRUD, {header, presenter} from '@crud/crud'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import pagination from '@crud/Pagination'
|
||||
|
||||
|
||||
export default {
|
||||
name: 'ImportOrder',
|
||||
components: {rrOperation, pagination},
|
||||
cruds() {
|
||||
},
|
||||
mixins: [presenter(), header()],
|
||||
props: {
|
||||
dialogShow: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
fullscreenLoading: false,
|
||||
dialogVisible: false,
|
||||
form: {}
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
dialogShow: {
|
||||
handler(newValue, oldValue) {
|
||||
this.dialogVisible = newValue
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
close() {
|
||||
this.form = {}
|
||||
this.$emit('update:dialogShow', false)
|
||||
this.$emit('tableChanged', this.rows)
|
||||
},
|
||||
queryStruct() {
|
||||
|
||||
this.fullscreenLoading = true
|
||||
if (this.form.createTime) {
|
||||
this.form.date_begin = this.form.createTime[0]
|
||||
this.form.date_end = this.form.createTime[1]
|
||||
}
|
||||
crudSap.getDeliveryNote(this.form).then(res => {
|
||||
this.crud.notify(res.message, CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.fullscreenLoading = false
|
||||
}).catch(() => {
|
||||
this.fullscreenLoading = false
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -0,0 +1,192 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
title="物料选择"
|
||||
append-to-body
|
||||
:visible.sync="dialogVisible"
|
||||
destroy-on-close
|
||||
width="1000px"
|
||||
@close="close"
|
||||
@open="open"
|
||||
>
|
||||
<el-form
|
||||
:inline="true"
|
||||
class="demo-form-inline"
|
||||
label-position="right"
|
||||
label-width="80px"
|
||||
label-suffix=":"
|
||||
>
|
||||
<el-form-item label="物料编码">
|
||||
<el-input
|
||||
v-model="query.material_code"
|
||||
size="mini"
|
||||
:disabled="true"
|
||||
@keyup.enter.native="crud.toQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="载具搜索">
|
||||
<el-input
|
||||
v-model="query.vehicle_code"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="载具编码"
|
||||
@keyup.enter.native="crud.toQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="批次号">
|
||||
<el-input
|
||||
v-model="query.pcsn"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="载具编码"
|
||||
@keyup.enter.native="crud.toQuery"
|
||||
/>
|
||||
</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-input v-model="query.form_query[col.value]" :value="col.value" clearable style="width: 210px" />
|
||||
</el-form-item>
|
||||
</template>
|
||||
<dev>
|
||||
<el-button
|
||||
class="filter-item"
|
||||
size="mini"
|
||||
type="success"
|
||||
icon="el-icon-refresh"
|
||||
@click="selectQuery"
|
||||
>查询</el-button>
|
||||
</dev>
|
||||
</el-form>
|
||||
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="table"
|
||||
v-loading="crud.loading"
|
||||
:data="crud.data"
|
||||
style="width: 100%;"
|
||||
size="mini"
|
||||
border
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
>
|
||||
<el-table-column v-if="!isSingle" type="selection" width="55" />
|
||||
<el-table-column v-if="isSingle" label="选择" width="55">
|
||||
<template slot-scope="scope">
|
||||
<el-radio v-model="tableRadio" :label="scope.row"><i /></el-radio>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="parent_vehicle_code" label="父载具" min-width="150" show-overflow-tooltip />
|
||||
<el-table-column prop="vehicle_code" label="载具编码" min-width="150" show-overflow-tooltip />
|
||||
<el-table-column prop="material_code" label="物料编码" min-width="150" show-overflow-tooltip />
|
||||
<el-table-column prop="material_spec" label="规格" show-overflow-tooltip />
|
||||
<el-table-column prop="pcsn" label="批次" show-overflow-tooltip />
|
||||
<el-table-column prop="qty" label="数量" show-overflow-tooltip />
|
||||
<el-table-column prop="qty_unit_name" label="单位" show-overflow-tooltip />
|
||||
<el-table-column prop="status" label="状态" show-overflow-tooltip />
|
||||
<el-table-column v-for="(item, index) in cols" :key="item.value" :label="item.lable" >
|
||||
<template slot-scope="scope">{{scope.row.form_data[item.value]}}</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<pagination />
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogVisible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="submit">确 定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import crudGroupDick from '@/views/wms/md_manage/group_dick/GroupVehicleDialog'
|
||||
import formstruc from '@/views/wms/config_manage/formStruc/formstruc'
|
||||
|
||||
import crudMaterialbase from '@/views/wms/base_manage/material/material'
|
||||
import CRUD, { header, presenter } from '@crud/crud'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import pagination from '@crud/Pagination'
|
||||
import Treeselect, { LOAD_CHILDREN_OPTIONS } from '@riophae/vue-treeselect'
|
||||
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
|
||||
import crudClassstandard from '@/views/wms/base_manage/class_standard/classstandard'
|
||||
|
||||
export default {
|
||||
name: 'GroupDick',
|
||||
components: {formstruc, crudGroupDick, rrOperation, pagination, Treeselect },
|
||||
cruds() {
|
||||
return CRUD({ title: '物料', url: 'api/mdGruopDick', crudMethod: { ...crudMaterialbase }, optShow: {}})
|
||||
},
|
||||
mixins: [presenter(), header()],
|
||||
dicts: ['product_series'],
|
||||
props: {
|
||||
dialogShow: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
isSingle: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
materOptCode: {
|
||||
type: String,
|
||||
default: '00'
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
cols: [],
|
||||
dialogVisible: false,
|
||||
tableRadio: null,
|
||||
rows: []
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
dialogShow: {
|
||||
handler(newValue) {
|
||||
this.dialogVisible = newValue
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
open() {},
|
||||
close() {
|
||||
this.tableRadio = null
|
||||
this.rows = []
|
||||
this.dialogVisible = false
|
||||
},
|
||||
setForm(row) {
|
||||
formstruc.getHeader('GROUP_DICK').then(res => {
|
||||
this.cols = res
|
||||
})
|
||||
console.log(row)
|
||||
this.dialogVisible = true
|
||||
this.query.material_code = row.material_code
|
||||
this.$set(this.query, 'form_query', {})
|
||||
this.crud.toQuery()
|
||||
},
|
||||
selectQuery(){
|
||||
this.crud.toQuery()
|
||||
},
|
||||
submit() {
|
||||
// 处理单选
|
||||
if (this.isSingle && this.tableRadio) {
|
||||
this.dialogVisible = false
|
||||
this.$emit('update:dialogShow', false)
|
||||
this.$emit('setMaterValue', this.tableRadio)
|
||||
return
|
||||
}
|
||||
this.rows = this.$refs.table.selection
|
||||
if (this.rows.length <= 0) {
|
||||
this.$message('请先勾选物料')
|
||||
return
|
||||
}
|
||||
this.crud.resetQuery(false)
|
||||
this.dialogVisible = false
|
||||
this.$emit('update:dialogShow', false)
|
||||
this.$emit('setMaterValue', this.rows)
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style rel="stylesheet/scss" lang="scss" scoped>
|
||||
::v-deep .el-dialog__body {
|
||||
padding-top: 0px;
|
||||
}
|
||||
</style>
|
||||
|
||||
116
wms_pro/qd/src/views/wms/md_manage/group_dick/UploadDialog.vue
Normal file
116
wms_pro/qd/src/views/wms/md_manage/group_dick/UploadDialog.vue
Normal file
@@ -0,0 +1,116 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
title="导入Excel文件"
|
||||
append-to-body
|
||||
:visible.sync="dialogVisible"
|
||||
destroy-on-close
|
||||
width="400px"
|
||||
:show-close="true"
|
||||
@close="close"
|
||||
@open="open"
|
||||
>
|
||||
<el-upload
|
||||
ref="upload"
|
||||
class="upload-demo"
|
||||
action=""
|
||||
drag
|
||||
:on-exceed="is_one"
|
||||
:limit="1"
|
||||
:auto-upload="false"
|
||||
:multiple="false"
|
||||
:show-file-list="true"
|
||||
:on-change="uploadByJsqd"
|
||||
:file-list="fileList"
|
||||
accept=".xlsx,.xls"
|
||||
>
|
||||
<i class="el-icon-upload" />
|
||||
<div class="el-upload__text">
|
||||
将文件拖到此处,或
|
||||
<em>点击上传</em>
|
||||
</div>
|
||||
<div slot="tip" class="el-upload__tip">只能上传Excel文件,且不超过10MB</div>
|
||||
</el-upload>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogVisible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="submit">确 定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import crudbucketrecord from '@/views/wms/md_manage/group_dick/groupdick'
|
||||
import CRUD, { crud } from '@crud/crud'
|
||||
|
||||
export default {
|
||||
name: 'UploadDialog',
|
||||
mixins: [crud()],
|
||||
components: {},
|
||||
props: {
|
||||
dialogShow: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
openParam: {
|
||||
type: String
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
dialogVisible: false,
|
||||
fileList: [],
|
||||
file1: ''
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
dialogShow: {
|
||||
handler(newValue, oldValue) {
|
||||
this.dialogVisible = newValue
|
||||
}
|
||||
},
|
||||
openParam: {
|
||||
handler(newValue, oldValue) {
|
||||
this.opendtlParam = newValue
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
open() {
|
||||
},
|
||||
close() {
|
||||
this.$emit('update:dialogShow', false)
|
||||
},
|
||||
is_one() {
|
||||
this.crud.notify('只能上传一个excel文件!', CRUD.NOTIFICATION_TYPE.WARNING)
|
||||
},
|
||||
// 文件校验方法
|
||||
beforeAvatarUpload(file) {
|
||||
// 不能导入大小超过2Mb的文件
|
||||
if (file.size > 10 * 1024 * 1024) {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
},
|
||||
// 文件发生改变就会触发的事件
|
||||
uploadByJsqd(file) {
|
||||
this.file1 = file
|
||||
},
|
||||
submit() {
|
||||
if (this.beforeAvatarUpload(this.file1)) {
|
||||
this.fileList.name = this.file1.name
|
||||
this.fileList.url = ''
|
||||
var formdata = new FormData()
|
||||
formdata.append('file', this.file1.raw)
|
||||
crudbucketrecord.excelImport(formdata).then((res) => {
|
||||
|
||||
this.crud.notify('导入成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.$emit('tableChanged3', '')
|
||||
this.$emit('update:dialogShow', false)
|
||||
})
|
||||
} else {
|
||||
this.crud.notify('文件过大,请上传小于10MB的文件〜', CRUD.NOTIFICATION_TYPE.WARNING)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
82
wms_pro/qd/src/views/wms/md_manage/group_dick/groupdick.js
Normal file
82
wms_pro/qd/src/views/wms/md_manage/group_dick/groupdick.js
Normal file
@@ -0,0 +1,82 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
export function add(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function del(ids) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick/',
|
||||
method: 'delete',
|
||||
data: ids
|
||||
})
|
||||
}
|
||||
|
||||
export function edit(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick',
|
||||
method: 'put',
|
||||
data
|
||||
})
|
||||
}
|
||||
export function updategroup(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick/updategroup',
|
||||
method: 'put',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function addPersons(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick/addPersons',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function getHeader(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick/getHeader',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function getDeviceIdByUserId(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick/getDeviceIdByUserId',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function addDevices(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick/addDevices',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function deleteRow(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick/deleteRow',
|
||||
method: 'delete',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function excelImport(data) {
|
||||
return request({
|
||||
url: '/api/mdGruopDick/excelImport',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del, addPersons, getHeader, deleteRow, addDevices,excelImport,updategroup }
|
||||
257
wms_pro/qd/src/views/wms/md_manage/group_dick/index.vue
Normal file
257
wms_pro/qd/src/views/wms/md_manage/group_dick/index.vue
Normal file
@@ -0,0 +1,257 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<!--工具栏-->
|
||||
<div class="head-container">
|
||||
<div v-if="crud.props.searchToggle">
|
||||
<!-- 搜索 -->
|
||||
<el-form
|
||||
:inline="true"
|
||||
class="demo-form-inline"
|
||||
label-position="right"
|
||||
label-width="80px"
|
||||
label-suffix=":"
|
||||
>
|
||||
<el-form-item label="订单号">
|
||||
<el-input v-model="query.sale_code" clearable placeholder="订单号" style="width: 200px;"
|
||||
class="filter-item"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="托盘号">
|
||||
<el-input v-model="query.storagevehicle_code" clearable placeholder="托盘号" style="width: 200px;"
|
||||
class="filter-item"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="组盘日期">
|
||||
<el-date-picker
|
||||
v-model="query.create_time"
|
||||
:default-time="['00:00:00','23:59:59']"
|
||||
end-placeholder="结束日期"
|
||||
start-placeholder="开始日期"
|
||||
type="daterange"
|
||||
value-format="yyyy-MM-dd"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label=" 组盘状态">
|
||||
<el-select
|
||||
v-model="query.status"
|
||||
class="filter-item"
|
||||
clearable
|
||||
placeholder="请选择"
|
||||
style="width: 200px"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in dict.BOX_STATUS"
|
||||
:key="item.id"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<rrOperation :crud="crud"/>
|
||||
</el-form>
|
||||
|
||||
</div>
|
||||
<!--如果想在工具栏加入更多按钮,可以使用插槽方式, slot = 'left' or 'right'-->
|
||||
<crudOperation :permission="permission">
|
||||
<el-button
|
||||
slot="right"
|
||||
class="filter-item"
|
||||
type="warning"
|
||||
icon="el-icon-upload2"
|
||||
size="mini"
|
||||
@click="uploadShow = true"
|
||||
>
|
||||
导入
|
||||
</el-button>
|
||||
</crudOperation>
|
||||
<!--表单组件-->
|
||||
<el-dialog :close-on-click-modal="false" :before-close="crud.cancelCU" :visible.sync="crud.status.cu > 0"
|
||||
title="新增组盘信息">
|
||||
<el-form
|
||||
ref="form"
|
||||
:inline="true"
|
||||
:model="form"
|
||||
label-width="160px"
|
||||
style="border: 1px solid #cfe0df;margin-top: 10px;padding-top: 10px;"
|
||||
>
|
||||
<el-form-item label="托盘号" prop="vehicle_code">
|
||||
</el-form-item>
|
||||
<el-form-item label="物料规格" prop="material_spec">
|
||||
</el-form-item>
|
||||
<el-form-item label="数量" prop="qty">
|
||||
</el-form-item>
|
||||
<el-form-item label="计量单位" prop="qty_unit_name">
|
||||
</el-form-item>
|
||||
<el-form-item label="组盘时间" prop="create_time">
|
||||
<el-input v-model="form.create_time" style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-select v-model="form.status" placeholder="" style="width: 200px">
|
||||
<el-option
|
||||
v-for="item in dict.BOX_STATUS"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-form ref="form" :model="form" :rules="rules" size="mini" label-width="80px"></el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="text" @click="crud.cancelCU">取消</el-button>
|
||||
<el-button :loading="crud.cu === 2" type="primary" @click="crud.submitCU">确认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog width ="250" :close-on-click-modal="false" :visible.sync="statusEdit" title="编辑托盘状态">
|
||||
<el-form
|
||||
ref="form"
|
||||
:inline="true"
|
||||
:model="editForm"
|
||||
label-width="100px"
|
||||
style="border: 1px solid #cfe0df;margin-top: 10px;padding-top: 10px;"
|
||||
>
|
||||
<el-form-item label="托盘号" prop="deliver_code">
|
||||
<el-input v-model="editForm.storagevehicle_code" style="width: 160px;" />
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-select v-model="editForm.status" placeholder="" style="width: 120px">
|
||||
<el-option
|
||||
v-for="item in dict.BOX_STATUS"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitStatus">确认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<!--表格渲染-->
|
||||
<el-table ref="table" v-loading="crud.loading" :data="crud.data" size="mini" style="width: 100%;"
|
||||
@selection-change="crud.selectionChangeHandler">
|
||||
<el-table-column type="selection" width="55"/>
|
||||
<el-table-column prop="storagevehicle_code" label="托盘号">
|
||||
<template slot-scope="scope">
|
||||
<el-link type="warning" @click="vechile(scope.row.vehicle_code)">{{ scope.row.vehicle_code }}</el-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="parent_vehicle_code" label="父托盘" show-overflow-tooltip/>
|
||||
<el-table-column prop="material_code" label="物料编码" show-overflow-tooltip/>
|
||||
<el-table-column prop="material_specs" label="物料规格" show-overflow-tooltip/>
|
||||
<el-table-column prop="qty" label="总数量"/>
|
||||
<el-table-column prop="qty_unit_name" label="计量单位"/>
|
||||
<el-table-column prop="status" label="状态">
|
||||
<template slot-scope="scope">
|
||||
{{ dict.label.BOX_STATUS[scope.row.status] }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="update_time" label="组盘时间"/>
|
||||
<el-table-column v-for="(item, index) in cols" :key="item.value" :label="item.lable" >
|
||||
<template slot-scope="scope">{{scope.row.form_data[item.value]}}</template>
|
||||
</el-table-column>
|
||||
<el-table-column v-permission="[]" label="操作" width="120px" align="center" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="warning" size="mini" @click="editStatus(scope.row)">编辑状态</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!--分页组件-->
|
||||
<pagination/>
|
||||
</div>
|
||||
<UploadDialog
|
||||
:dialog-show.sync="uploadShow"
|
||||
@tableChanged3="tableChanged3"
|
||||
/>
|
||||
<vechileViewDialog ref="vechileViewDialog" :dialog-show.sync="vachileView" />
|
||||
<Dialog :dialog-show.sync="dialogShow" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import crudbucketrecord from '@/views/wms/md_manage/group_dick/groupdick'
|
||||
import CRUD, {presenter, header, form, crud} from '@crud/crud'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import crudOperation from '@crud/CRUD.operation'
|
||||
import udOperation from '@crud/UD.operation'
|
||||
import UploadDialog from '@/views/wms/md_manage/group_dick/UploadDialog'
|
||||
import Dialog from '@/views/wms/md_manage/group_dick/Dialog'
|
||||
import vechileViewDialog from '@/views/wms/md_manage/group_dick/vechileViewDialog'
|
||||
import pagination from '@crud/Pagination'
|
||||
import Treeselect, {LOAD_CHILDREN_OPTIONS} from '@riophae/vue-treeselect'
|
||||
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
|
||||
import formstruc from '@/views/wms/config_manage/formStruc/formstruc'
|
||||
|
||||
|
||||
const defaultForm = {
|
||||
deliver_id: null,
|
||||
deliver_code: null,
|
||||
seq_no: null,
|
||||
deliver_type: null,
|
||||
material_id: null,
|
||||
status: null,
|
||||
delivery_qty: null,
|
||||
cust_id: null,
|
||||
qty_unit_id: null,
|
||||
sale_id: null,
|
||||
sale_code: null,
|
||||
sale_seq_no: null,
|
||||
create_id: null,
|
||||
create_name: null,
|
||||
create_time: null,
|
||||
update_optid: null,
|
||||
update_optname: null,
|
||||
update_time: null,
|
||||
cust_code: null,
|
||||
cust_name: null
|
||||
}
|
||||
export default {
|
||||
name: 'DeliveryOrder',
|
||||
dicts: ['PCS_DELIVER_TYPE', 'BOX_STATUS'],
|
||||
components: {formstruc, vechileViewDialog,pagination, crudOperation, rrOperation, udOperation, Treeselect, Dialog, UploadDialog},
|
||||
mixins: [presenter(), header(), form(defaultForm), crud()],
|
||||
cruds() {
|
||||
return CRUD({
|
||||
title: '发货单', url: '/api/mdGruopDick', idField: 'bucket_record_id', sort: 'storagevehicle_code,desc',
|
||||
optShow: {
|
||||
add: true,
|
||||
edit: false,
|
||||
del: true,
|
||||
reset: true,
|
||||
download: false
|
||||
},
|
||||
crudMethod: {...crudbucketrecord}
|
||||
})
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
cols:[],
|
||||
GroupShow: false,
|
||||
statusEdit:false,
|
||||
vachileView:false,
|
||||
editForm:{},
|
||||
classes3: [],
|
||||
uploadShow: false,
|
||||
dialogShow: false,
|
||||
permission: {},
|
||||
rules: {},
|
||||
unit_list: [{ value: 16, label: '个\\只' }],
|
||||
queryTypeOptions: [
|
||||
{key: 'deliver_code', display_name: '发货单号'}
|
||||
]
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
[CRUD.HOOK.beforeRefresh]() {
|
||||
formstruc.getHeader('GROUP_DICK').then(res => {
|
||||
this.cols = res
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
@@ -0,0 +1,79 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
title="托盘明细"
|
||||
append-to-body
|
||||
:visible.sync="dialogVisible"
|
||||
destroy-on-close
|
||||
width="80%"
|
||||
>
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="table"
|
||||
v-loading="crud.loading"
|
||||
:data="crud.data"
|
||||
size="mini"
|
||||
style="width: 100%;"
|
||||
>
|
||||
<el-table-column type="index" fixed width="80" label="序号" />
|
||||
<el-table-column prop="storagevehicle_code" fixed width="120" label="托盘号" />
|
||||
<el-table-column prop="sale_code" width="120" label="销售单号" />
|
||||
<el-table-column prop="seq_no" label="销售单明细" width="100" />
|
||||
<el-table-column prop="material_spec" label="物料规格" width="150" />
|
||||
<el-table-column prop="storage_qty" label="数量" width="150" />
|
||||
<el-table-column prop="qty_unit_name" label="单位" width="150" />
|
||||
<el-table-column prop="create_time" label="组盘时间" width="150" />
|
||||
<el-table-column prop="status" label="状态">
|
||||
<template slot-scope="scope">
|
||||
{{ dict.label.BOX_STATUS[scope.row.status] }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!--分页组件-->
|
||||
<pagination />
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submit">确 定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import bucketrecord from '@/views/wms/md_manage/group_dick/groupdick'
|
||||
import CRUD, { header, presenter } from '@crud/crud'
|
||||
import pagination from '@crud/Pagination'
|
||||
|
||||
export default {
|
||||
name: 'vechileViewDialog',
|
||||
components: {pagination },
|
||||
cruds() {
|
||||
return CRUD({ title: '组盘明细', url: '/api/mdPbBucketrecord/vechile_code', crudMethod: { ...bucketrecord }, optShow: {}})
|
||||
},
|
||||
mixins: [presenter(), header()],
|
||||
dicts: ['BOX_STATUS'],
|
||||
props: {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
dialogVisible: false,
|
||||
tableRadio: null,
|
||||
checkrow: null,
|
||||
rows: [],
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
openQ(query) {
|
||||
this.crud.query.storagevehicle_code = query
|
||||
this.dialogVisible = true
|
||||
this.crud.toQuery()
|
||||
},
|
||||
submit() {
|
||||
this.dialogVisible = false
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style rel="stylesheet/scss" lang="scss" scoped>
|
||||
::v-deep .el-dialog__body {
|
||||
padding-top: 0px;
|
||||
}
|
||||
</style>
|
||||
|
||||
687
wms_pro/qd/src/views/wms/stor_manage/in/DivDialog.vue
Normal file
687
wms_pro/qd/src/views/wms/stor_manage/in/DivDialog.vue
Normal file
@@ -0,0 +1,687 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
append-to-body
|
||||
:visible.sync="dialogVisible"
|
||||
destroy-on-close
|
||||
:show-close="false"
|
||||
fullscreen
|
||||
@close="close"
|
||||
@open="open"
|
||||
>
|
||||
|
||||
<span slot="title" class="dialog-footer">
|
||||
<div class="crud-opts2">
|
||||
<span class="el-dialog__title2">入库分配</span>
|
||||
<span class="crud-opts-right2">
|
||||
<!--左侧插槽-->
|
||||
<slot name="left" />
|
||||
<el-button slot="left" type="info" @click="dialogVisible = false">关闭</el-button>
|
||||
</span>
|
||||
</div>
|
||||
</span>
|
||||
<div class="crud-opts2">
|
||||
<span class="role-span">入库明细项</span>
|
||||
</div>
|
||||
<el-card class="box-card" shadow="never" :body-style="{padding:'0'}">
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="dtl_table"
|
||||
:data="this.openParam"
|
||||
style="width: 100%;"
|
||||
max-height="300"
|
||||
border
|
||||
highlight-current-row
|
||||
:row-class-name="tableRowClassName"
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
@row-click="clcikRow"
|
||||
>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="bill_status" label="状态" align="center" width="110px">
|
||||
<template slot-scope="scope">
|
||||
<el-select
|
||||
v-model="scope.row.bill_status"
|
||||
class="filter-item"
|
||||
:disabled="true"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in dict.IO_BILL_STATUS"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_spec" label="物料规格" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="plan_qty" :formatter="crud.formatNum3" label="数量" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="assign_qty" :formatter="crud.formatNum3" label="已分配数量" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="unassign_qty" :formatter="crud.formatNum3" label="未分配数量" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="qty_unit_name" label="单位" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="base_bill_type" label="源单类型" :formatter="formatBaseType" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="base_bill_code" label="源单号" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="base_bill_table" label="源单行号" align="center" />
|
||||
|
||||
</el-table>
|
||||
</el-card>
|
||||
<el-card class="box-card" shadow="never" :body-style="{padding:'20px 20px 0 20px'}">
|
||||
<el-form ref="form2" :inline="true" :model="form" :rules="rules" size="mini">
|
||||
<el-form-item label="载具号:" prop="vehicle_code">
|
||||
<el-input v-model="form.vehicle_code" style="width: 200px" size="mini" clearable placeholder="载具号">
|
||||
<el-button slot="append" @click="vehicleCheck" >生成</el-button>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="箱号:" prop="pageBox_code">
|
||||
<el-input v-model="form.bucketunique" size="mini" style="width: 200px" disabled placeholder="箱号">
|
||||
<el-button slot="append" icon="el-icon-plus" @click="queryBox" />
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="放入数量:" prop="storage_qty">
|
||||
<el-input-number
|
||||
v-model="form.storage_qty"
|
||||
style="width: 200px"
|
||||
size="mini"
|
||||
:controls="false"
|
||||
precision="3"
|
||||
:min="0"
|
||||
@change="changeQty"
|
||||
placeholder="数量"
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="入库点:" prop="point_code">
|
||||
<el-select
|
||||
v-model="form.point_code"
|
||||
size="mini"
|
||||
clearable
|
||||
placeholder="请选择"
|
||||
class="filter-item"
|
||||
style="width: 200px;"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in pointlist"
|
||||
:key="item.point_code"
|
||||
:label="item.point_name"
|
||||
:value="item.point_code"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="载具超限类型:" prop="vehicle_overstruct_type">
|
||||
<el-select
|
||||
v-model="form.vehicle_overstruct_type"
|
||||
size="mini"
|
||||
placeholder="请选择"
|
||||
class="filter-item"
|
||||
style="width: 200px;"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in dict.VEHICLE_OVER_TYPE"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
</el-form>
|
||||
</el-card>
|
||||
<div class="crud-opts2">
|
||||
<span class="role-span">载具物料明细</span>
|
||||
<div class="crud-opts-form">
|
||||
<el-form ref="form" :inline="true" :model="form" size="mini">
|
||||
<el-form-item label="库区:" prop="gender5">
|
||||
<el-cascader
|
||||
placeholder="请选择"
|
||||
:options="sects"
|
||||
v-model="defaultList"
|
||||
:props="{ checkStrictly: true }"
|
||||
clearable
|
||||
@change="sectQueryChange"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item prop="checked">
|
||||
<el-checkbox v-model="form.checked">自动分配货位</el-checkbox>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
<span class="crud-opts-right2">
|
||||
<!--左侧插槽-->
|
||||
<slot name="left" />
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="pushVehicle()"
|
||||
>
|
||||
装入托盘
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="confirmvehicle()"
|
||||
>
|
||||
组盘确认
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="cancelConfirmvehicle()"
|
||||
>
|
||||
取消组盘
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="left"
|
||||
:loading="divBtn"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="divStruct()"
|
||||
>
|
||||
分配货位
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="unDivStruct()"
|
||||
>
|
||||
取消分配
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-delete"
|
||||
size="mini"
|
||||
@click="divPoint()"
|
||||
>
|
||||
设置起点
|
||||
</el-button>
|
||||
</span>
|
||||
</div>
|
||||
<el-card class="box-card" shadow="never" :body-style="{padding:'0'}">
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="dis_table"
|
||||
:data="form.tableMater"
|
||||
style="width: 100%;"
|
||||
max-height="300"
|
||||
border
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
@row-click="clcikRowDis"
|
||||
>
|
||||
<el-table-column show-overflow-tooltip type="index" label="序号" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_spec" label="物料规格" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="storagevehicle_code" label="托盘号" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="bucketunique" label="箱号" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="qty" :formatter="crud.formatNum3" label="数量" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="struct_code" label="货位" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="point_code" label="入库点" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="task_code" label="任务号" align="center" />
|
||||
<el-table-column align="center" label="操作" width="170" fixed="right">
|
||||
<template scope="scope">
|
||||
<el-button
|
||||
type="danger"
|
||||
class="filter-item"
|
||||
size="mini"
|
||||
:disabled="disabledIos(scope.row)"
|
||||
icon="el-icon-delete"
|
||||
@click.native.prevent="deleteRow(scope.$index, form.tableMater)"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-card>
|
||||
|
||||
<!-- <StructDiv ref="child" :stor-id="storId" :dialog-show.sync="structShow" :sect-prop="sectProp" @tableChanged="tableChanged" />-->
|
||||
<!-- <AddBox ref="child" :dialog-show.sync="addBoxShow" :add-box-param="boxParam" @tableChanged2="tableChanged2" />-->
|
||||
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import CRUD, { crud } from '@crud/crud'
|
||||
// import StructDiv from '@/views/wms/storage_manage/product/productIn/StructDiv'
|
||||
// import AddBox from '@/views/wms/storage_manage/product/productIn/AddBox'
|
||||
|
||||
import crudProductIn from '@/views/wms/stor_manage/in/storinvin'
|
||||
import crudPoint from '@/views/wms/stor_manage/in/storinvin'
|
||||
import crudSectattr from '@/api/wms/basedata/st/sectattr'
|
||||
|
||||
export default {
|
||||
name: 'DivDialog',
|
||||
components: { },
|
||||
mixins: [crud()],
|
||||
dicts: ['IO_BILL_STATUS', 'VEHICLE_OVER_TYPE', 'PCS_SAL_TYPE'],
|
||||
props: {
|
||||
dialogShow: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
openParam: {
|
||||
type: Array,
|
||||
default: () => {
|
||||
return []
|
||||
}
|
||||
},
|
||||
storId: {
|
||||
type: String,
|
||||
default: null
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
dialogVisible: false,
|
||||
stor_id: '1528627995269533696',
|
||||
sect_id: '1528631043496742912',
|
||||
sectProp: null,
|
||||
structShow: false,
|
||||
bucketObj: null,
|
||||
divBtn: false,
|
||||
bucketShow: false,
|
||||
addBoxShow: false,
|
||||
bucketuniqueObj: null,
|
||||
sects: [],
|
||||
defaultList: ['1528627995269533696', '1528631043496742912'],
|
||||
dis_row: null,
|
||||
form: {
|
||||
dtl_row: null,
|
||||
storage_qty: '',
|
||||
sect_id: '',
|
||||
stor_id: '',
|
||||
point_code: null,
|
||||
vehicle_code: '',
|
||||
bucketunique: '',
|
||||
checked: true,
|
||||
vehicle_overstruct_type: '00',
|
||||
tableMater: []
|
||||
},
|
||||
storlist: [],
|
||||
pointlist: [],
|
||||
rules: {},
|
||||
boxParam: {}
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
dialogShow: {
|
||||
handler(newValue, oldValue) {
|
||||
this.dialogVisible = newValue
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
disabledIos(row) {
|
||||
if (row.iostorinvdis_id === undefined) {
|
||||
return false
|
||||
} else {
|
||||
return true
|
||||
}
|
||||
},
|
||||
open() {
|
||||
crudSectattr.getSect({ 'stor_id': this.storId }).then(res => {
|
||||
this.sects = res.content
|
||||
})
|
||||
const area_type = 'A1_CPRK01'
|
||||
crudPoint.getPoint({ 'area_type': area_type }).then(res => {
|
||||
this.pointlist = res
|
||||
})
|
||||
},
|
||||
toDelete(data) {
|
||||
data.pop = true
|
||||
},
|
||||
close() {
|
||||
this.form.tableMater = []
|
||||
this.form.dtl_row = null
|
||||
this.form.bucketunique = null
|
||||
this.sectProp = null
|
||||
this.$emit('update:dialogShow', false)
|
||||
this.$emit('AddChanged')
|
||||
this.crud.refresh()
|
||||
this.$refs['form2'].resetFields()
|
||||
},
|
||||
clcikRow(row, column, event) {
|
||||
this.form.dtl_row = row
|
||||
this.form.storage_qty = this.form.dtl_row.plan_qty
|
||||
crudProductIn.getIosInvDis({ 'iostorinv_id': row.iostorinv_id, 'iostorinvdtl_id': row.iostorinvdtl_id }).then(res => {
|
||||
|
||||
if (res.length !== 0) {
|
||||
this.form.tableMater = res
|
||||
}
|
||||
})
|
||||
},
|
||||
clcikRowDis(row, column, event) {
|
||||
this.dis_row = row
|
||||
},
|
||||
vehicleCheck() {
|
||||
// 生成托盘
|
||||
crudProductIn.vehicleCheck().then(res => {
|
||||
this.form.tableMater = []
|
||||
this.form.vehicle_code = res.vehicle_code
|
||||
this.crud.notify('生成成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
}).catch(() => {
|
||||
|
||||
})
|
||||
},
|
||||
changeQty(val) {
|
||||
|
||||
if (parseFloat(this.form.dtl_row.plan_qty) < parseFloat(val)) {
|
||||
this.crud.notify('放入数量不能大于明细数量!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
this.$set(this.form, 'storage_qty', parseFloat(this.form.dtl_row.plan_qty))
|
||||
}
|
||||
},
|
||||
queryBox() {
|
||||
// 校验载具是否为空
|
||||
if (!this.form.vehicle_code) {
|
||||
this.crud.notify('请先填写载具号!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
if (!this.form.dtl_row) {
|
||||
this.crud.notify('请选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
this.boxParam = {
|
||||
'material_id': this.form.dtl_row.material_id,
|
||||
'pcsn': this.form.dtl_row.pcsn
|
||||
}
|
||||
this.addBoxShow = true
|
||||
},
|
||||
pushVehicle() {
|
||||
// 校验载具是否为空
|
||||
if (!this.form.vehicle_code) {
|
||||
this.crud.notify('载具号不能为空!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
// 校验明细不能为空
|
||||
if (!this.form.dtl_row) {
|
||||
this.crud.notify('请选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
// 有箱号
|
||||
if (this.form.bucketunique) {
|
||||
let fla = true
|
||||
this.form.tableMater.forEach(item => {
|
||||
if (item.bucketunique === this.bucketuniqueObj.bucketunique) {
|
||||
fla = false
|
||||
}
|
||||
})
|
||||
|
||||
if (fla) {
|
||||
this.bucketuniqueObj.iostorinvdtl_id = this.form.dtl_row.iostorinvdtl_id
|
||||
this.form.tableMater.splice(-1, 0, this.bucketuniqueObj)
|
||||
this.form.bucketunique = ''
|
||||
}
|
||||
} else {
|
||||
// 无箱号
|
||||
if (!this.form.storage_qty) {
|
||||
this.crud.notify('数量不能为0!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
const item = {
|
||||
'storagevehicle_code': this.form.vehicle_code,
|
||||
'iostorinvdtl_id': this.form.dtl_row.iostorinvdtl_id,
|
||||
'material_id': this.form.dtl_row.material_id,
|
||||
'material_code': this.form.dtl_row.material_code,
|
||||
'material_spec': this.form.dtl_row.material_spec,
|
||||
'material_name': this.form.dtl_row.material_name,
|
||||
'qty': this.form.storage_qty
|
||||
}
|
||||
|
||||
let fla2 = true
|
||||
this.form.tableMater.forEach(res => {
|
||||
if (res.iostorinvdtl_id === item.iostorinvdtl_id && res.storagevehicle_code === item.storagevehicle_code) {
|
||||
fla2 = false
|
||||
}
|
||||
})
|
||||
|
||||
if (fla2) {
|
||||
this.form.tableMater.splice(-1, 0, item)
|
||||
}
|
||||
}
|
||||
},
|
||||
deleteRow(index, rows) {
|
||||
rows.splice(index, 1)
|
||||
},
|
||||
tableRowClassName({ row, rowIndex }) {
|
||||
row.index = rowIndex
|
||||
},
|
||||
insertvehicle() {
|
||||
if (!this.form.dtl_row) {
|
||||
this.crud.notify('请选择一条入库明细', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
if (!this.form.storagevehicle_code) {
|
||||
this.crud.notify('请输入托盘号', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
// 判断是否选择了桶号
|
||||
if (this.bucketObj) {
|
||||
if (!(this.bucketObj.status === '01')) {
|
||||
this.crud.notify('请校验桶状态!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
const dis_dtl = JSON.parse(JSON.stringify(this.bucketObj))
|
||||
// 判断选择的桶是否已经被选过
|
||||
const flag = this.form.tableMater.some(mater => mater.bucketunique === dis_dtl.bucketunique)
|
||||
if (!flag) {
|
||||
const flag = this.form.tableMater.some(mater => mater.storagevehicle_code !== this.form.storagevehicle_code)
|
||||
if (flag) {
|
||||
this.crud.notify('存在不同载具号', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
dis_dtl.storagevehicle_code = this.form.storagevehicle_code
|
||||
dis_dtl.pop = false
|
||||
this.form.tableMater.splice(this.form.tableMater.length, 0, dis_dtl)
|
||||
if (this.form.dtl_row.assign_qty) {
|
||||
this.form.dtl_row.assign_qty = parseFloat(this.form.dtl_row.assign_qty) + parseFloat(this.form.storage_qty)
|
||||
} else {
|
||||
this.form.dtl_row.assign_qty = parseFloat(this.form.storage_qty)
|
||||
}
|
||||
if (parseFloat(this.form.dtl_row.unassign_qty) - parseFloat(this.form.storage_qty) > 0) {
|
||||
this.form.dtl_row.unassign_qty = parseFloat(this.form.dtl_row.unassign_qty) - parseFloat(this.form.storage_qty)
|
||||
} else {
|
||||
this.form.dtl_row.unassign_qty = 0
|
||||
}
|
||||
this.openParam.splice(this.form.dtl_row.index, 1, this.form.dtl_row)
|
||||
}
|
||||
if (flag) {
|
||||
this.crud.notify('该桶已被加入明细中', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
}
|
||||
} else {
|
||||
this.crud.notify('请选择桶号', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
},
|
||||
confirmvehicle() {
|
||||
if (!this.form.dtl_row) {
|
||||
this.crud.notify('请选择一条明细', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
if (this.form.tableMater.length === 0) {
|
||||
this.crud.notify('请先装入托盘!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
crudProductIn.confirmvehicle(this.form).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.form.dtl_row.iostorinv_id }).then(res => {
|
||||
this.form.vehicle_code = ''
|
||||
this.form.bucketunique = ''
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('组盘成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
})
|
||||
},
|
||||
cancelConfirmvehicle() {
|
||||
if (!this.dis_row) {
|
||||
this.crud.notify('请选择一条分配明细', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
crudProductIn.cancelConfirmvehicle(this.dis_row).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.form.dtl_row.iostorinv_id }).then(res => {
|
||||
this.form.vehicle_code = ''
|
||||
this.form.bucketunique = ''
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('取消成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
})
|
||||
},
|
||||
sectQueryChange(val) {
|
||||
|
||||
this.sectProp = val
|
||||
if (val.length === 1) {
|
||||
this.stor_id = val[0]
|
||||
this.sect_id = ''
|
||||
}
|
||||
if (val.length === 0) {
|
||||
this.sect_id = ''
|
||||
this.stor_id = ''
|
||||
}
|
||||
if (val.length === 2) {
|
||||
this.stor_id = val[0]
|
||||
this.sect_id = val[1]
|
||||
}
|
||||
},
|
||||
tableChanged(row) {
|
||||
this.form.sect_id = this.sect_id
|
||||
this.form.stor_id = this.stor_id
|
||||
this.dis_row.struct_id = row.struct_id
|
||||
this.divBtn = true
|
||||
crudProductIn.divStruct(this.dis_row).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.dis_row.iostorinv_id }).then(res => {
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('分配成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
}).finally(() => {
|
||||
this.divBtn = false
|
||||
})
|
||||
},
|
||||
tableChanged2(row) {
|
||||
this.form.bucketunique = row.bucketunique
|
||||
row.storagevehicle_code = this.form.vehicle_code
|
||||
row.qty = row.storage_qty
|
||||
this.bucketuniqueObj = row
|
||||
},
|
||||
divStruct() {
|
||||
if (this.dis_row === null) {
|
||||
this.crud.notify('请先选择一条分配明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
// 如果勾选了,直接跳后台
|
||||
if (this.form.checked) {
|
||||
if (!this.sect_id) {
|
||||
this.crud.notify('请先选择区域!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
this.divBtn = true
|
||||
|
||||
this.dis_row.stor_id = this.stor_id.toString()
|
||||
this.dis_row.sect_id = this.sect_id.toString()
|
||||
this.dis_row.vehicle_overstruct_type = this.form.vehicle_overstruct_type
|
||||
crudProductIn.divStruct(this.dis_row).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.dis_row.iostorinv_id }).then(res => {
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('分配成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
}).finally(() => {
|
||||
this.divBtn = false
|
||||
})
|
||||
} else {
|
||||
if (!this.stor_id) {
|
||||
this.crud.notify('请先选择仓库!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
this.structShow = true
|
||||
this.$refs.child.getMsg(false)
|
||||
}
|
||||
},
|
||||
unDivStruct() {
|
||||
if (this.dis_row === null) {
|
||||
this.crud.notify('请先选择一条分配明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
|
||||
this.dis_row.vehicle_overstruct_type = this.form.vehicle_overstruct_type
|
||||
crudProductIn.unDivStruct(this.dis_row).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.dis_row.iostorinv_id }).then(res => {
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('取消成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
})
|
||||
},
|
||||
divPoint() {
|
||||
if (!this.form.point_code) {
|
||||
this.crud.notify('请选择入库点', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
if (this.dis_row === null) {
|
||||
this.crud.notify('请先选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
this.dis_row.point_code = this.form.point_code
|
||||
crudProductIn.setPoint(this.dis_row).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.dis_row.iostorinv_id }).then(res => {
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('操作成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
})
|
||||
},
|
||||
formatBaseType(row) {
|
||||
return this.dict.label.PCS_SAL_TYPE[row.base_bill_type]
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.crud-opts2 {
|
||||
padding: 0;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.crud-opts2 .el-dialog__title2 {
|
||||
line-height: 24px;
|
||||
font-size: 20px;
|
||||
color: #303133;
|
||||
}
|
||||
|
||||
.crud-opts2 .role-span {
|
||||
padding: 10px 0px 10px 0px;
|
||||
}
|
||||
|
||||
.crud-opts2 .crud-opts-form {
|
||||
padding: 10px 0px 0px 20px;
|
||||
}
|
||||
|
||||
.input-with-select {
|
||||
background-color: #fff;
|
||||
}
|
||||
</style>
|
||||
317
wms_pro/qd/src/views/wms/stor_manage/in/GroupDickDialog.vue
Normal file
317
wms_pro/qd/src/views/wms/stor_manage/in/GroupDickDialog.vue
Normal file
@@ -0,0 +1,317 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
append-to-body
|
||||
:visible.sync="dialogVisible"
|
||||
destroy-on-close
|
||||
:show-close="false"
|
||||
fullscreen
|
||||
@open="open"
|
||||
>
|
||||
<span slot="title" class="dialog-footer">
|
||||
<div class="crud-opts2">
|
||||
<span class="el-dialog__title2">入库组盘分配</span>
|
||||
<span class="crud-opts-right2">
|
||||
<!--左侧插槽-->
|
||||
<slot name="left" />
|
||||
<el-button slot="left" type="info" @click="dialogVisible = false">关闭</el-button>
|
||||
</span>
|
||||
</div>
|
||||
</span>
|
||||
<div class="crud-opts2">
|
||||
<span class="role-span">入库明细项</span>
|
||||
</div>
|
||||
<el-card class="box-card" shadow="never" :body-style="{padding:'0'}">
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="dtl_table"
|
||||
:data="this.form"
|
||||
style="width: 100%;"
|
||||
max-height="300"
|
||||
border
|
||||
highlight-current-row
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
@row-click="clickRow"
|
||||
>
|
||||
<el-table-column type="index" label="序号" width="50" align="center" />
|
||||
<el-table-column prop="bill_status" label="状态" align="center" width="110px">
|
||||
<template slot-scope="scope">
|
||||
<el-select
|
||||
v-model="scope.row.bill_status"
|
||||
class="filter-item"
|
||||
:disabled="true"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in dict.IO_BILL_STATUS"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_spec" label="物料规格" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="plan_qty" :formatter="crud.formatNum3" label="数量" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="assign_qty" :formatter="crud.formatNum3" label="已分配数量" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="unassign_qty" :formatter="crud.formatNum3" label="未分配数量" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="qty_unit_name" label="单位" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="base_bill_code" label="源单号" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="base_bill_table" label="源单行号" align="center" />
|
||||
</el-table>
|
||||
</el-card>
|
||||
<!-- <el-card class="box-card" shadow="never" :body-style="{padding:'20px 20px 0 20px'}">-->
|
||||
<!-- <el-form ref="form2" :inline="true" :model="form" :rules="rules" size="mini">-->
|
||||
<!-- <el-form-item label="载具号:" prop="vehicle_code">-->
|
||||
<!-- <el-input v-model="form.vehicle_code" style="width: 200px" size="mini" clearable placeholder="载具号">-->
|
||||
<!-- <el-button slot="append" @click="" >生成</el-button>-->
|
||||
<!-- </el-input>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="箱号:" prop="pageBox_code">-->
|
||||
<!-- <el-input v-model="form.bucketunique" size="mini" style="width: 200px" disabled placeholder="箱号">-->
|
||||
<!-- <el-button slot="append" icon="el-icon-plus" @click="" />-->
|
||||
<!-- </el-input>-->
|
||||
<!-- </el-form-item>-->
|
||||
|
||||
<!-- <el-form-item label="放入数量:" prop="storage_qty">-->
|
||||
<!-- <el-input-number-->
|
||||
<!-- v-model="form.storage_qty"-->
|
||||
<!-- style="width: 200px"-->
|
||||
<!-- size="mini"-->
|
||||
<!-- :controls="false"-->
|
||||
<!-- precision="3"-->
|
||||
<!-- :min="0"-->
|
||||
<!-- placeholder="数量"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
|
||||
<!-- <el-form-item label="入库点:" prop="point_code">-->
|
||||
<!-- <el-select-->
|
||||
<!-- v-model="form.point_code"-->
|
||||
<!-- size="mini"-->
|
||||
<!-- clearable-->
|
||||
<!-- placeholder="请选择"-->
|
||||
<!-- class="filter-item"-->
|
||||
<!-- style="width: 200px;"-->
|
||||
<!-- >-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in pointlist"-->
|
||||
<!-- :key="item.point_code"-->
|
||||
<!-- :label="item.point_name"-->
|
||||
<!-- :value="item.point_code"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
|
||||
<!-- <el-form-item label="载具超限类型:" prop="vehicle_overstruct_type">-->
|
||||
<!-- <el-select-->
|
||||
<!-- v-model="form.vehicle_overstruct_type"-->
|
||||
<!-- size="mini"-->
|
||||
<!-- placeholder="请选择"-->
|
||||
<!-- class="filter-item"-->
|
||||
<!-- style="width: 200px;"-->
|
||||
<!-- >-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in dict.VEHICLE_OVER_TYPE"-->
|
||||
<!-- :key="item.value"-->
|
||||
<!-- :label="item.label"-->
|
||||
<!-- :value="item.value"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- </el-form>-->
|
||||
<!-- </el-card>-->
|
||||
<div class="crud-opts2">
|
||||
<span class="role-span">载具物料明细</span>
|
||||
<div class="crud-opts-form">
|
||||
<el-form ref="form" :inline="true" :model="form" size="mini">
|
||||
<el-form-item label="库区:" prop="gender5">
|
||||
<el-cascader
|
||||
placeholder="请选择"
|
||||
:options="sects"
|
||||
v-model="defaultList"
|
||||
:props="{ checkStrictly: true }"
|
||||
clearable
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item prop="checked">
|
||||
<el-checkbox v-model="form.checked">自动分配货位</el-checkbox>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
<span class="crud-opts-right2">
|
||||
<!--左侧插槽-->
|
||||
<slot name="left" />
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="groupConfim((crud.selections[0]))"
|
||||
>
|
||||
组盘确认
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="left"
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
>
|
||||
取消组盘
|
||||
</el-button>
|
||||
</span>
|
||||
</div>
|
||||
<el-card class="box-card" shadow="never" :body-style="{padding:'0'}">
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="dis_table"
|
||||
:data="form.tableMater"
|
||||
style="width: 100%;"
|
||||
max-height="300"
|
||||
border
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
>
|
||||
<el-table-column show-overflow-tooltip type="index" label="序号" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_spec" label="物料规格" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="storagevehicle_code" label="托盘号" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="bucketunique" label="箱号" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="qty" :formatter="crud.formatNum3" label="数量" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="struct_code" label="货位" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="point_code" label="入库点" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="task_code" label="任务号" align="center" />
|
||||
<el-table-column align="center" label="操作" width="170" fixed="right">
|
||||
<template scope="scope">
|
||||
<el-button
|
||||
type="danger"
|
||||
class="filter-item"
|
||||
size="mini"
|
||||
icon="el-icon-delete"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-card>
|
||||
|
||||
<!-- <StructDiv ref="child" :stor-id="storId" :dialog-show.sync="structShow" :sect-prop="sectProp" @tableChanged="tableChanged" />-->
|
||||
<!-- <AddBox ref="child" :dialog-show.sync="addBoxShow" :add-box-param="boxParam" @tableChanged2="tableChanged2" />-->
|
||||
<GroupVehicleDialog
|
||||
ref="groupVehicle"
|
||||
@setMaterValue="setTableDis"
|
||||
/>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import CRUD, { crud } from '@crud/crud'
|
||||
import GroupVehicleDialog from '@/views/wms/md_manage/group_dick/GroupVehicleDialog'
|
||||
import formstruc from '@/views/wms/config_manage/formStruc/formstruc'
|
||||
|
||||
// import StructDiv from '@/views/wms/storage_manage/product/productIn/StructDiv'
|
||||
import crudProductIn from '@/views/wms/stor_manage/in/storinvin'
|
||||
import crudPoint from '@/views/wms/stor_manage/in/storinvin'
|
||||
// import AddBox from '@/views/wms/storage_manage/product/productIn/AddBox'
|
||||
import crudSectattr from '@/api/wms/basedata/st/sectattr'
|
||||
|
||||
|
||||
export default {
|
||||
name: 'GroupDialog',
|
||||
components: { formstruc, GroupVehicleDialog, crudProductIn },
|
||||
mixins: [crud()],
|
||||
dicts: ['IO_BILL_STATUS', 'VEHICLE_OVER_TYPE', 'PCS_SAL_TYPE'],
|
||||
props: {
|
||||
dialogShow: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
openParam: {
|
||||
type: Array,
|
||||
default: () => {
|
||||
return []
|
||||
}
|
||||
},
|
||||
storId: {
|
||||
type: String,
|
||||
default: null
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
dialogVisible: false,
|
||||
GroupShow: false,
|
||||
click_Row: {},
|
||||
stor_id: '1528627995269533696',
|
||||
sect_id: '1528631043496742912',
|
||||
sectProp: null,
|
||||
structShow: false,
|
||||
bucketObj: null,
|
||||
divBtn: false,
|
||||
bucketShow: false,
|
||||
addBoxShow: false,
|
||||
bucketuniqueObj: null,
|
||||
sects: [],
|
||||
defaultList: ['1528627995269533696', '1528631043496742912'],
|
||||
dis_row: null,
|
||||
form: [],
|
||||
storlist: [],
|
||||
pointlist: [],
|
||||
rules: {},
|
||||
boxParam: {}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
open() {
|
||||
// formstruc.getHeader('STOR_IN').then(res => {
|
||||
// this.cols = res
|
||||
// })
|
||||
},
|
||||
setForm(row) {
|
||||
this.dialogVisible = true
|
||||
crudProductIn.getIosInvDtl(row.id).then(res => {
|
||||
this.form = res
|
||||
})
|
||||
},
|
||||
clickRow(row) {
|
||||
this.click_Row = row
|
||||
},
|
||||
groupConfim(){
|
||||
if (this.click_Row !== null) {
|
||||
this.$refs.groupVehicle.setForm(this.click_Row)
|
||||
}
|
||||
},
|
||||
setTableDis(row){
|
||||
console.log(row)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.crud-opts2 {
|
||||
padding: 0;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.crud-opts2 .el-dialog__title2 {
|
||||
line-height: 24px;
|
||||
font-size: 20px;
|
||||
color: #303133;
|
||||
}
|
||||
|
||||
.crud-opts2 .role-span {
|
||||
padding: 10px 0px 10px 0px;
|
||||
}
|
||||
|
||||
.crud-opts2 .crud-opts-form {
|
||||
padding: 10px 0px 0px 20px;
|
||||
}
|
||||
|
||||
.input-with-select {
|
||||
background-color: #fff;
|
||||
}
|
||||
</style>
|
||||
@@ -112,28 +112,6 @@
|
||||
</div>
|
||||
<!--如果想在工具栏加入更多按钮,可以使用插槽方式, slot = 'left' or 'right'-->
|
||||
<crudOperation :permission="permission">
|
||||
<el-button
|
||||
slot="right"
|
||||
class="filter-item"
|
||||
type="success"
|
||||
:disabled="dis_flag"
|
||||
icon="el-icon-position"
|
||||
size="mini"
|
||||
@click="divOpen"
|
||||
>
|
||||
分配
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="right"
|
||||
class="filter-item"
|
||||
type="success"
|
||||
icon="el-icon-position"
|
||||
size="mini"
|
||||
:disabled="task_flag"
|
||||
@click="taskOpen"
|
||||
>
|
||||
作业任务
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="right"
|
||||
class="filter-item"
|
||||
@@ -170,14 +148,9 @@
|
||||
<el-table-column show-overflow-tooltip prop="form_type" min-width="120" label="单据类型" />
|
||||
<el-table-column show-overflow-tooltip prop="biz_code" label="仓库" min-width="120" />
|
||||
<el-table-column show-overflow-tooltip min-width="120" prop="biz_date" label="业务日期" />
|
||||
|
||||
<el-table-column v-for="(item, index) in cols" :key="item.value" :label="item.lable" >
|
||||
<template slot-scope="scope">{{scope.row.form_data[item.value]}}</template>
|
||||
</el-table-column>
|
||||
|
||||
<!-- <template v-for="(col,index) in cols">-->
|
||||
<!-- <el-table-column :prop="col.value" :label="col.lable" width="120px" show-overflow-tooltip />-->
|
||||
<!-- </template>-->
|
||||
<el-table-column label="备注" align="center" prop="remark" />
|
||||
<el-table-column label="创建人" align="center" prop="create_id" />
|
||||
<el-table-column label="创建时间" align="center" prop="create_time" width="150" />
|
||||
@@ -189,6 +162,9 @@
|
||||
:disabled-edit="canUd(scope.row)"
|
||||
:disabled-dle="canUd(scope.row)"
|
||||
/>
|
||||
<el-button slot="right" size="mini" type="text" icon="el-icon-circle-plus-outline" @click="groupOpen(scope.row)">组盘</el-button>
|
||||
<el-button slot="right" size="mini" type="text" icon="el-icon-circle-plus-outline" @click="groupOpen(scope.row)">分配</el-button>
|
||||
<el-button slot="right" size="mini" type="text" icon="el-icon-circle-plus-outline" @click="groupOpen(scope.row)">任务</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -197,7 +173,7 @@
|
||||
</div>
|
||||
<AddDialog @AddChanged="querytable" />
|
||||
<ViewDialog ref="itemview"/>
|
||||
<!-- <DivDialog :dialog-show.sync="divShow" :stor-id="storId" :open-param="openParam" @AddChanged="querytable" />-->
|
||||
<GroupDialog ref="groupview" />
|
||||
<!-- <TaskDialog :dialog-show.sync="taskShow" :open-param="taskOpenParam" />-->
|
||||
</div>
|
||||
</template>
|
||||
@@ -211,13 +187,13 @@ import crudOperation from '@crud/CRUD.operation'
|
||||
import udOperation from '@crud/UD.operation'
|
||||
import pagination from '@crud/Pagination'
|
||||
import AddDialog from '@/views/wms/stor_manage/in/AddDialog'
|
||||
// import DivDialog from '@/views/wms/storage_manage/product/productIn/DivDialog'
|
||||
import GroupDialog from '@/views/wms/stor_manage/in/GroupDickDialog'
|
||||
import ViewDialog from '@/views/wms/stor_manage/in/ViewDialog'
|
||||
import { mapGetters } from 'vuex'
|
||||
|
||||
export default {
|
||||
name: 'ProductIn',
|
||||
components: { AddDialog, ViewDialog, formstruc, crudProductIn, crudOperation, rrOperation, udOperation, pagination },
|
||||
components: { GroupDialog, AddDialog, ViewDialog, formstruc, crudProductIn, crudOperation, rrOperation, udOperation, pagination },
|
||||
cruds() {
|
||||
return CRUD({
|
||||
title: '',
|
||||
@@ -275,6 +251,45 @@ export default {
|
||||
this.cols = res
|
||||
})
|
||||
},
|
||||
|
||||
toView(row) {
|
||||
if (row !== null) {
|
||||
this.$refs.itemview.setForm(row)
|
||||
}
|
||||
},
|
||||
groupOpen(row) {
|
||||
if (row !== null) {
|
||||
this.$refs.groupview.setForm(row)
|
||||
}
|
||||
},
|
||||
confirm() {
|
||||
if (!this.currentRow) {
|
||||
this.crud.notify('请选择一条单据', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
crudProductIn.confirm({ 'iostorinv_id': this.currentRow.iostorinv_id }).then(res => {
|
||||
this.crud.notify('单据确认成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.toQuery()
|
||||
})
|
||||
},
|
||||
stateFormat(row, column) {
|
||||
return this.dict.label.IO_BILL_STATUS[row.bill_status]
|
||||
},
|
||||
divOpen() {
|
||||
crudProductIn.getIosInvDtl({ 'bill_code': this.currentRow.bill_code }).then(res => {
|
||||
this.openParam = res
|
||||
this.storId = this.currentRow.stor_id
|
||||
this.billType = this.currentRow.bill_type
|
||||
this.divShow = true
|
||||
})
|
||||
},
|
||||
|
||||
taskOpen() {
|
||||
crudProductIn.getIosInvDtl({ 'bill_code': this.currentRow.bill_code }).then(res => {
|
||||
this.taskOpenParam = res
|
||||
})
|
||||
this.taskShow = true
|
||||
},
|
||||
fun(val) {
|
||||
return Number(val).toFixed(3)
|
||||
},
|
||||
@@ -327,38 +342,6 @@ export default {
|
||||
bill_typeFormat(row, column) {
|
||||
return this.dict.label.ST_INV_CP_IN_TYPE[row.bill_type]
|
||||
},
|
||||
toView(row) {
|
||||
if (row !== null) {
|
||||
this.$refs.itemview.setForm(row)
|
||||
}
|
||||
},
|
||||
confirm() {
|
||||
if (!this.currentRow) {
|
||||
this.crud.notify('请选择一条单据', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
crudProductIn.confirm({ 'iostorinv_id': this.currentRow.iostorinv_id }).then(res => {
|
||||
this.crud.notify('单据确认成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.toQuery()
|
||||
})
|
||||
},
|
||||
stateFormat(row, column) {
|
||||
return this.dict.label.IO_BILL_STATUS[row.bill_status]
|
||||
},
|
||||
divOpen() {
|
||||
crudProductIn.getIosInvDtl({ 'bill_code': this.currentRow.bill_code }).then(res => {
|
||||
this.openParam = res
|
||||
this.storId = this.currentRow.stor_id
|
||||
this.billType = this.currentRow.bill_type
|
||||
this.divShow = true
|
||||
})
|
||||
},
|
||||
taskOpen() {
|
||||
crudProductIn.getIosInvDtl({ 'bill_code': this.currentRow.bill_code }).then(res => {
|
||||
this.taskOpenParam = res
|
||||
})
|
||||
this.taskShow = true
|
||||
},
|
||||
querytable() {
|
||||
this.onSelectAll()
|
||||
this.crud.toQuery()
|
||||
|
||||
@@ -31,6 +31,13 @@ export function getIosInvDtl(data) {
|
||||
data
|
||||
})
|
||||
}
|
||||
export function getPoint(data) {
|
||||
return request({
|
||||
url: '/api/stIvtIostorinvIn/getIosInvDtl',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
export function getIosInvDis(data) {
|
||||
return request({
|
||||
url: '/api/stIvtIostorinvIn/getIosInvDis',
|
||||
@@ -134,6 +141,7 @@ export default {
|
||||
getIosInvDtl,
|
||||
vehicleCheck,
|
||||
confirmvehicle,
|
||||
getPoint,
|
||||
getSect,
|
||||
divStruct,
|
||||
unDivStruct,
|
||||
|
||||
Reference in New Issue
Block a user