10/31 上货工位增加货位上架功能

20240912_adapter
wangwei 5 months ago
parent f24d422214
commit f82d9ab036

@ -53,6 +53,17 @@ export function getByCode(query) {
}); });
} }
export function printQueueLabel(query) {
return axios({
url: "/udiwms/sysWorkplaceQueue/label/print",
method: "post",
data: query,
headers: {'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8'},
responseType: 'arraybuffer', //一定要设置响应类型否则页面会是空白pdf
});
}

@ -6,7 +6,7 @@
> >
<el-row :gutter="24"> <el-row :gutter="24">
<el-col :span="12" class="el-col"> <el-col :span="12" class="el-col">
<el-form-item label="分格编码:" prop="code" class="query-form-item"> <el-form-item label="货位编码:" prop="code" class="query-form-item">
<el-input <el-input
disabled disabled
v-model="formData.code" style="width: 80%" v-model="formData.code" style="width: 80%"
@ -15,7 +15,7 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12" class="el-col"> <el-col :span="12" class="el-col">
<el-form-item label="分格名称:" class="query-form-item" prop="name" placeholder="请输入分格名称"> <el-form-item label="货位名称:" class="query-form-item" prop="name" placeholder="请输入分格名称">
<el-input <el-input
v-model="formData.name" style="width: 80%" v-model="formData.name" style="width: 80%"
auto-complete="off" auto-complete="off"

@ -136,6 +136,11 @@
<span>{{ workPlaceClasss[scope.row.workPlaceClass] }}</span> <span>{{ workPlaceClasss[scope.row.workPlaceClass] }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="货位上架" prop="queueStatus" width="90">
<template slot-scope="scope">
<span>{{ queueStatusMap[scope.row.queueStatus] }}</span>
</template>
</el-table-column>
<!--<el-table-column label="所属组别" prop="categoryName" width="90"></el-table-column>--> <!--<el-table-column label="所属组别" prop="categoryName" width="90"></el-table-column>-->
<!--<el-table-column label="单据类型编号" prop="busTypeCode" width="100"></el-table-column>--> <!--<el-table-column label="单据类型编号" prop="busTypeCode" width="100"></el-table-column>-->
<!--<el-table-column label="单据类型名称" prop="busTypeName" width="100"></el-table-column>--> <!--<el-table-column label="单据类型名称" prop="busTypeName" width="100"></el-table-column>-->
@ -147,7 +152,7 @@
<el-table-column label="创建时间" prop="createTime" width="140"></el-table-column> <el-table-column label="创建时间" prop="createTime" width="140"></el-table-column>
<el-table-column label="备注" prop="remake" width="140"></el-table-column> <el-table-column label="备注" prop="remake" width="140"></el-table-column>
<el-table-column label="操作" fixed="right" width="160"> <el-table-column label="操作" fixed="right" width="240">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
type="text" type="text"
@ -155,6 +160,12 @@
@click.native.stop="printLabel(scope.row)" @click.native.stop="printLabel(scope.row)"
>工位标签 >工位标签
</el-button> </el-button>
<el-button
type="text"
size="small"
@click.native.stop="printQueueList(scope.row)"
>分格标签
</el-button>
<el-button <el-button
type="text" type="text"
@ -249,14 +260,14 @@
</el-tab-pane> </el-tab-pane>
<el-tab-pane> <el-tab-pane>
<!-- {{ workplaceName }}---> <!-- {{ workplaceName }}--->
<span slot="label">工位分格</span> <span slot="label">货位</span>
<el-form :inline="true" :model="queueQuery" class="query-form" size="mini" <el-form :inline="true" :model="queueQuery" class="query-form" size="mini"
style="margin-bottom: 10px" style="margin-bottom: 10px"
> >
<el-form-item class="query-form-item" label="名称/编号:"> <el-form-item class="query-form-item" label="名称/编号:">
<el-input <el-input
v-model="queueQuery.key" v-model="queueQuery.key"
placeholder="请输入分格名称或分格编号" placeholder="请输入货位名称或货位编号"
clearable clearable
></el-input> ></el-input>
</el-form-item> </el-form-item>
@ -275,7 +286,7 @@
> >
<el-button type="primary" @click="addPlaid" <el-button type="primary" @click="addPlaid"
icon="el-icon-plus" icon="el-icon-plus"
>新增工位分格 >新增货位
</el-button </el-button
> >
<!--<el-button type="primary" @click="choosePlaid"--> <!--<el-button type="primary" @click="choosePlaid"-->
@ -291,8 +302,8 @@
> >
<el-table-column type="index" label="序号"></el-table-column> <el-table-column type="index" label="序号"></el-table-column>
<!-- <el-table-column label="业务类型编码 " prop="documentTypeCode" width="100"></el-table-column>--> <!-- <el-table-column label="业务类型编码 " prop="documentTypeCode" width="100"></el-table-column>-->
<el-table-column label="格子名称" prop="name"></el-table-column> <el-table-column label="货位名称" prop="name"></el-table-column>
<el-table-column label="格子编号 " prop="code"></el-table-column> <el-table-column label="货位编号 " prop="code"></el-table-column>
<el-table-column label="备注" prop="remark"></el-table-column> <el-table-column label="备注" prop="remark"></el-table-column>
<el-table-column label="操作" fixed="right" width="120"> <el-table-column label="操作" fixed="right" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
@ -381,8 +392,8 @@
<el-col :span="12" class="el-col"> <el-col :span="12" class="el-col">
<el-form-item label="工位状态:" prop="workplaceStatus" class="query-form-item"> <el-form-item label="工位状态:" prop="workplaceStatus" class="query-form-item">
<el-select v-model="formData.workplaceStatus" style="width: 80%" placeholder="工位状态"> <el-select v-model="formData.workplaceStatus" style="width: 80%" placeholder="工位状态">
<el-option label="暂停" :value="0"></el-option> <el-option label="暂停" :value=0></el-option>
<el-option label="启用" :value="1"></el-option> <el-option label="启用" :value=1></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
@ -441,6 +452,16 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row :gutter="24">
<el-col :span="12" class="el-col">
<el-form-item label="按货位上架:" prop="queueStatus" class="query-form-item">
<el-select v-model="formData.queueStatus" style="width: 80%" placeholder="货位上架">
<el-option label="关闭" :value="0"></el-option>
<el-option label="启用" :value="1"></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="24"> <el-row :gutter="24">
<el-col :span="12" class="el-col"> <el-col :span="12" class="el-col">
@ -577,7 +598,7 @@ import { addTree, deleteTree, getTree, updateTree } from '@/api/basic/collectPoi
import { delCollect, getBindCollectList } from '@/api/basic/collectPoint/cargowWorkplaceManage' import { delCollect, getBindCollectList } from '@/api/basic/collectPoint/cargowWorkplaceManage'
import addCollectWorkplace from './addCollectWorkplace' import addCollectWorkplace from './addCollectWorkplace'
import addPlaidDialog from './addPlaidDialog' import addPlaidDialog from './addPlaidDialog'
import { deleteQueue, getQueueList } from '@/api/basic/workPlace/SysWorkplaceQueue' import { deleteQueue, getQueueList, printQueueLabel } from '@/api/basic/workPlace/SysWorkplaceQueue'
export default { export default {
components: { addCollectWorkplace, addPlaidDialog }, components: { addCollectWorkplace, addPlaidDialog },
@ -664,6 +685,10 @@ export default {
1: '采集工位', 1: '采集工位',
2: '上货工位' 2: '上货工位'
}, },
queueStatusMap:{
0 : '关闭',
1 : '启用',
},
orderFinishVerifys: { orderFinishVerifys: {
0: '完全赋码', 0: '完全赋码',
1: '部分赋码', 1: '部分赋码',
@ -727,8 +752,8 @@ export default {
collectWorks: [], collectWorks: [],
plaidName: 'add', plaidName: 'add',
plaids: { plaids: {
'add': '新增工位分格', 'add': '新增货位',
'edit': '编辑工位分格' 'edit': '编辑货位'
}, },
fromName: 'add', fromName: 'add',
fromMap: { fromMap: {
@ -752,6 +777,7 @@ export default {
chargeUser: null, chargeUser: null,
constituencies: null, constituencies: null,
invRemindNumber: 0, invRemindNumber: 0,
queueStatus:0,
remake: null remake: null
}, },
fromDeptOptions: [], fromDeptOptions: [],
@ -891,27 +917,7 @@ export default {
} }
}) })
}, },
removeQueue(row) {
this.$confirm('此操作将永久删除该工位分格, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteQueue(row).then(res => {
if (res.code == 20000) {
this.$message.success('删除成功')
this.getQueueList()
} else {
this.$message.error(res.message)
}
})
})
},
updateQueue(row) {
this.queueData = row
this.plaidName = 'edit'
this.plaidDialogVisible = true
},
onCollectList() { onCollectList() {
if (this.rowData.workplaceId == null) { if (this.rowData.workplaceId == null) {
return this.$message.error('请选择上货工位') return this.$message.error('请选择上货工位')
@ -975,13 +981,7 @@ export default {
// this.collectWorks = this.collectWorkPlaceCodes.concat(this.collectBusTypeCodes); // this.collectWorks = this.collectWorkPlaceCodes.concat(this.collectBusTypeCodes);
}, },
addPlaid() {
if (this.rowData.workplaceId == null) {
return this.$message.error('请选择上货工位')
}
this.queueData = null
this.plaidDialogVisible = true
},
removeCollect(row) { removeCollect(row) {
this.$confirm('此操作将永久删除该采集工位, 是否继续?', '提示', { this.$confirm('此操作将永久删除该采集工位, 是否继续?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
@ -1012,10 +1012,7 @@ export default {
this.getCargowBindCollectList() this.getCargowBindCollectList()
this.chooseCollectDialogVisible = false this.chooseCollectDialogVisible = false
}, },
closePlaidDialog() {
this.plaidDialogVisible = false
this.getQueueList()
},
printLabel(row) { printLabel(row) {
row.labelId = 6 row.labelId = 6
printWorkLabel(row).then((response) => { printWorkLabel(row).then((response) => {
@ -1060,6 +1057,7 @@ export default {
chargeUser: null, chargeUser: null,
constituencies: '1001', constituencies: '1001',
invRemindNumber: 0, invRemindNumber: 0,
queueStatus:0,
remake: null remake: null
} }
if (this.groupData != null) { if (this.groupData != null) {
@ -1205,6 +1203,7 @@ export default {
}, },
edit(row) { edit(row) {
this.formData = row this.formData = row
this.formData.queueStatus = Number(row.queueStatus)
// this.formData.invCode = String(row.invCode) // this.formData.invCode = String(row.invCode)
if (row.chargeUser == 0) { if (row.chargeUser == 0) {
this.formData.chargeUser = null this.formData.chargeUser = null
@ -1224,6 +1223,56 @@ export default {
}) })
this.getTree() this.getTree()
this.addWorkplaceDialogVisible = true this.addWorkplaceDialogVisible = true
},
//
addPlaid() {
if (this.rowData.workplaceId == null) {
return this.$message.error('请选择上货工位')
}
this.queueData = null
this.plaidDialogVisible = true
},
removeQueue(row) {
this.$confirm('此操作将永久删除该工位分格, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteQueue(row).then(res => {
if (res.code == 20000) {
this.$message.success('删除成功')
this.getQueueList()
} else {
this.$message.error(res.message)
}
})
})
},
updateQueue(row) {
this.queueData = row
this.plaidName = 'edit'
this.plaidDialogVisible = true
},
closePlaidDialog() {
this.plaidDialogVisible = false
this.getQueueList()
},
printQueue(row) {
row.labelId = 8
printQueueLabel(row).then(res => {
const binaryData = []
binaryData.push(res)
let url = window.URL.createObjectURL(
new Blob(binaryData, { type: 'application/pdf' })
)
this.loading = false
window.open(url)
}).catch(() => {
this.loading = false
})
},
printQueueList(row){
} }
}, },
created() { created() {

File diff suppressed because it is too large Load Diff

@ -149,6 +149,7 @@ export default {
supId: null, supId: null,
unitFk: null, unitFk: null,
invCode: this.invQueryData.invCode, invCode: this.invQueryData.invCode,
productsType:2,
}, },
detailQuery: { detailQuery: {
code: null, code: null,
@ -191,6 +192,7 @@ export default {
supId: null, supId: null,
page: 1, page: 1,
limit: 10, limit: 10,
productsType:2
}; };
this.getList(); this.getList();
}, },

@ -159,7 +159,7 @@
></stockOrderNewSelectProduct> ></stockOrderNewSelectProduct>
</el-dialog> </el-dialog>
<el-dialog <el-dialog
title="库存物资录入" title="库存药品录入"
:visible.sync="selectInvProductVisible" :visible.sync="selectInvProductVisible"
:close-on-click-modal="false" :close-on-click-modal="false"
:close-on-press-escape="false" :close-on-press-escape="false"

Loading…
Cancel
Save