组盘管理

This commit is contained in:
2026-02-24 16:47:47 +08:00
parent f351d6e02f
commit 2426e2a2a0
3 changed files with 20 additions and 36 deletions

View File

@@ -3,26 +3,15 @@
<!-- 来料入库 --> <!-- 来料入库 -->
<nav-bar :title="title"></nav-bar> <nav-bar :title="title"></nav-bar>
<view class="zd_content"> <view class="zd_content">
<view class="zd_wrapper"> <!-- <view class="zd_wrapper">
<view class="zd-row border-bottom"> <view class="zd-row">
<view class="zd-col-7">
<span class="filter_label">托盘/点位码</span>
</view>
<view class="zd-col-17">
<search-box
v-model="val1"
@handleChange="handleChange"
/>
</view>
</view>
<!-- <view class="zd-row">
<view class="zd-col-19"> <view class="zd-col-19">
</view> </view>
<view class="zd-col-4"> <view class="zd-col-4">
<button class="mini-btn" size="mini" style="display: block; margin-top: 9px;" type="primary" @tap="handleAdd">添加</button> <button class="mini-btn" size="mini" style="display: block; margin-top: 9px;" type="primary" @tap="handleAdd">添加</button>
</view> </view>
</view> --> </view>
</view> </view> -->
<view class="zd_wrapper" v-if="flag"> <view class="zd_wrapper" v-if="flag">
<view class="zd-row border-bottom"> <view class="zd-row border-bottom">
<view class="zd-col-7"> <view class="zd-col-7">
@@ -70,7 +59,7 @@
<table> <table>
<thead> <thead>
<tr> <tr>
<th>删除选择</th> <th>选择</th>
<th>点位码</th> <th>点位码</th>
<th>托盘码</th> <th>托盘码</th>
<th>批次号</th> <th>批次号</th>
@@ -98,8 +87,7 @@
</view> </view>
</view> </view>
<view class="zd-row submit-bar"> <view class="zd-row submit-bar">
<button class="zd-col-11 button-primary" :class="{'button-info': !checkedArr.length}" @tap="toDel()">删除选中行</button> <button class="zd-col-22 button-primary" :class="{'button-info': !checkedArr.length}" @tap="_zwConfirmIn">提交</button>
<button class="zd-col-11 button-primary" :class="{'button-info': !dataList.length}" @tap="_zwConfirmIn">全部提交</button>
</view> </view>
</view> </view>
</template> </template>
@@ -107,7 +95,7 @@
<script> <script>
import NavBar from '@/components/NavBar.vue' import NavBar from '@/components/NavBar.vue'
import SearchBox from '@/components/SearchBox.vue' import SearchBox from '@/components/SearchBox.vue'
import {getFormDataList, getPlate, inCheck, zwConfirmIn} from '@/utils/getData4.js' import {getFormDataList, getPlate, getInBillList, zwConfirmIn} from '@/utils/getData4.js'
export default { export default {
components: { components: {
NavBar, NavBar,
@@ -115,11 +103,9 @@
}, },
data() { data() {
return { return {
singleDate: '',
title: '', title: '',
id: '', id: '',
code: '', code: '',
val1: '',
pkId: '', pkId: '',
pkObj: {}, pkObj: {},
dataList: [], dataList: [],
@@ -146,17 +132,10 @@
} }
}, },
created () { created () {
this._getInBillList()
}, },
methods: { methods: {
handleChange (e) {
if (e) {
this._inCheck()
}
},
handleAdd () { handleAdd () {
if (!this.val1) {
return
}
this.dataList.map(el => { this.dataList.map(el => {
this.$set(el, 'checked', false) this.$set(el, 'checked', false)
}) })
@@ -181,9 +160,6 @@
// } catch (e) { // } catch (e) {
// } // }
// }, // },
toDel () {
this.dataList = this.dataList.filter(el => el.checked === false)
},
toChek (e) { toChek (e) {
this.pkId = this.pkId === e.site_code ? '' : e.site_code this.pkId = this.pkId === e.site_code ? '' : e.site_code
this.pkObj = this.pkId === e.site_code ? e : {} this.pkObj = this.pkId === e.site_code ? e : {}
@@ -202,9 +178,9 @@
this.dataList = [] this.dataList = []
this.checkedArr = [] this.checkedArr = []
}, },
async _inCheck () { async _getInBillList () {
try { try {
let res = await inCheck(this.val1) let res = await getInBillList()
if (res.code === '200') { if (res.code === '200') {
this.dataList = [...this.dataList, ...res.data] this.dataList = [...this.dataList, ...res.data]
this.handleAdd() this.handleAdd()
@@ -219,12 +195,12 @@
}, },
async _zwConfirmIn () { async _zwConfirmIn () {
this.disabled = true this.disabled = true
if (!this.dataList.length) { if (!this.checkedArr.length) {
this.disabled = false this.disabled = false
return return
} }
try { try {
let res = await zwConfirmIn(this.dataList) let res = await zwConfirmIn(this.checkedArr)
if (res.code === '200') { if (res.code === '200') {
uni.showToast({ uni.showToast({
title: res.message, title: res.message,

View File

@@ -225,6 +225,9 @@
title: res.message, title: res.message,
icon: 'none' icon: 'none'
}) })
this.val1 = ''
this.val2 = ''
this.currentData = {}
this.disabled = false this.disabled = false
} catch (e) { } catch (e) {
this.disabled = false this.disabled = false

View File

@@ -238,6 +238,11 @@ export const inCheck = (svcode) => request({
url:'api/pda/iosIn/inCheck', url:'api/pda/iosIn/inCheck',
data: {site_vehicle_code: svcode} data: {site_vehicle_code: svcode}
}) })
// 查询来料入库清单
export const getInBillList = () => request({
url:'api/pda/iosIn/getInBillList',
data: {}
})
// 空载具出入库 // 空载具出入库
// 载具编码下拉框 // 载具编码下拉框