rev:回温库存报表出库按钮功能修改;

opt:查询更新母托盘组盘代码优化;手持组盘解绑功能优化;回温出库任务完成优化
This commit is contained in:
DESKTOP-5DIJMF9\admin
2024-09-02 17:38:01 +08:00
parent 602d84758d
commit 166dd99b76
22 changed files with 248 additions and 88 deletions

View File

@@ -107,16 +107,7 @@
<!--如果想在工具栏加入更多按钮可以使用插槽方式 slot = 'left' or 'right'-->
<crudOperation :permission="permission" />
<!--表格渲染-->
<el-table ref="table" v-loading="crud.loading" :data="crud.data" size="mini" style="width: 100%;" height="300" @selection-change="crud.selectionChangeHandler">
<el-table-column v-permission="[]" label="操作" width="80px" align="center" fixed="right">
<template slot-scope="scope">
<el-button
type="text"
icon="el-icon-add"
@click="handleButtonClick(scope.row)"
>回温出库</el-button>
</template>
</el-table-column>
<el-table ref="table" v-loading="crud.loading" :data="crud.data" size="mini" style="width: 100%;" height="300" @selection-change="crud.selectionChangeHandler">
<el-table-column prop="pointCode" label="点位编码" :min-width="flexWidth('pointCode',crud.data,'点位编码')" />
<el-table-column prop="regionName" label="区域名称" :min-width="flexWidth('regionName',crud.data,'区域名称')" />
<el-table-column prop="subTray" label="子托编码" :min-width="flexWidth('subTray',crud.data,'子托编码')" />
@@ -134,10 +125,35 @@
<span>{{ scope.row.standingTime > scope.row.usedTime ? '未完成' : '已完成' }}</span>
</template>
</el-table-column>
<el-table-column label="操作" width="95" fixed="right">
<template slot-scope="scope">
<el-button
class="filter-item"
type="success"
size="mini"
v-if="showButton1(scope.row)"
>
正在出库
</el-button>
<el-button
class="filter-item"
type="warning"
size="mini"
v-if="showButton2(scope.row)"
@click="handleButtonClick(scope.row)"
>
回温出库
</el-button>
</template>
</el-table-column>
</el-table>
<el-dialog
:visible.sync="dialogVisible"
:lock-scroll="false"
width="30%"
title="选择点位"
:before-close="handleClose"
>
<el-form ref="form" :model="form">
<el-form-item label="点位列表">
@@ -152,7 +168,7 @@
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取消</el-button>
<el-button @click="handleCancle">取消</el-button>
<el-button type="primary" @click="submitSelectedPoint">确认</el-button>
</div>
</el-dialog>
@@ -164,14 +180,12 @@
<script>
import crudMaterial from './detail'
import CRUD, { crud, form, header, presenter } from '@crud/crud'
import CRUD, { crud, header, presenter } from '@crud/crud'
import rrOperation from '@crud/RR.operation'
import crudOperation from '@crud/CRUD.operation'
import udOperation from '@crud/UD.operation'
import pagination from '@crud/Pagination'
import crudMdBaseWorkShop from '@/views/wms/basedata/workshop/mdBaseWorkshop'
import crudSchBasePoint from '@/views/wms/sch/point/schBasePoint'
import crudSchBaseRegion from '@/views/wms/sch/region/schBaseRegion'
export default {
name: 'HwDetail',
@@ -218,7 +232,6 @@ export default {
this.getPointList()
this.getSupplierNameList()
this.getIngotBatchList()
this.fetchPoints()
this.getProductDescriptionList()
},
methods: {
@@ -246,6 +259,28 @@ export default {
this.ingotBatchList = res.content
})
},
handleClose(done){
this.form.selectedPoint = null
done();
},
handleCancle(){
this.dialogVisible = false
this.form.selectedPoint = null
},
showButton1(row){
if(typeof row.ing_task_code === 'undefined' || row.ing_task_code == null || row.ing_task_code === ''){
return false;
}else{
return true;
}
},
showButton2(row){
if(typeof row.ing_task_code === 'undefined' || row.ing_task_code == null || row.ing_task_code === ''){
return true;
}else{
return false;
}
},
handleButtonClick(row) {
this.selectedRow = row
this.dialogVisible = true
@@ -263,12 +298,13 @@ export default {
return
}
// Submit the selected point to the backend
this.$axios.post('/api/pda/task', {
this.$axios.post('/api/report/hwtask', {
start_point: this.selectedRow.pointCode,
next_point: selectedPoint
}).then(response => {
this.$message.success('提交成功')
this.dialogVisible = false
this.crud.toQuery()
}).catch(error => {
this.$message.error('提交失败')
})

View File

@@ -179,9 +179,6 @@
<!--表单组件-->
<el-dialog :close-on-click-modal="false" :before-close="crud.cancelCU" :visible.sync="crud.status.cu > 0" :title="crud.status.title" width="540px">
<el-form ref="form" :model="form" :rules="rules" size="mini" label-width="110px" style="border: 1px solid #cfe0df;margin-top: 10px;padding-top: 10px;">
<el-form-item v-if="false" label="点位标识" prop="point_id">
<el-input v-model="form.point_id" style="width: 370px;" />
</el-form-item>
<el-form-item label="所属车间">
<el-select
v-model="form.workshop_code"
@@ -206,6 +203,7 @@
v-for="item in regionList"
:label="item.region_name"
:value="item.region_code"
@click.native="regionChange(item)"
/>
</el-select>
</el-form-item>
@@ -504,6 +502,10 @@ export default {
}
})
},
regionChange(item){
//console.log('当前选中', item)
this.form.region_name = item.region_name
},
changeUsed(data, flag) { // 更改启用状态
const param = {}
param.data = data
@@ -565,7 +567,7 @@ export default {
.post('/api/schBasePoint/outbound', data)
.then(response => {
// 处理后端返回的数据
console.log('提交成功', response)
//console.log('提交成功', response)
this.$message.success('提交成功')
this.closeReasonDialog()
})

View File

@@ -47,9 +47,9 @@ export function getPointsByRegionCodes(data) {
})
}
export function getCBPointList(data) {
data = { region_code: 'CB' }
data = { region_code: 'CB', vehicle_qty: 0 }
return request({
url: 'api/schBasePoint/getPointList',
url: 'api/schBasePoint/getPointListByPda',
method: 'post',
data
})