init
This commit is contained in:
115
pages/modules/SemifinishedOutStore.vue
Normal file
115
pages/modules/SemifinishedOutStore.vue
Normal file
@@ -0,0 +1,115 @@
|
||||
<template>
|
||||
<view class="zd_container">
|
||||
<nav-bar title="半成品出库"></nav-bar>
|
||||
<view class="zd_content">
|
||||
<view class="zd_wrapper">
|
||||
<view class="filter_item">
|
||||
<view class="filter_label_wraper">
|
||||
<span class="filter_label">物料规格</span>
|
||||
</view>
|
||||
<view class="filter_input_wraper">
|
||||
<search-box
|
||||
v-model="val1"
|
||||
@handleChange="handleChange"
|
||||
/>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd_wrapper grid-wraper">
|
||||
<view class="slide_new">
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>序号</th>
|
||||
<th>选择</th>
|
||||
<th>货位</th>
|
||||
<th>物料规格</th>
|
||||
<th>物料编码</th>
|
||||
<th>物料名称</th>
|
||||
<th>载具号</th>
|
||||
<th>数量</th>
|
||||
<th>所属工序</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(e, i) in dataList" :key="i" :class="{'checked': e.checked}">
|
||||
<td>{{Number(i) + 1}}</td>
|
||||
<td><span class="iconfont icon_unchecked" :class="{'icon_checked': e.checked}" @tap="toCheck(e)"></span></td>
|
||||
<td>{{e.struct_code}}</td>
|
||||
<td>{{e.material_spec}}</td>
|
||||
<td>{{e.material_code}}</td>
|
||||
<td>{{e.material_name}}</td>
|
||||
<td>{{e.storagevehicle_code}}</td>
|
||||
<td>{{e.canuse_qty}}</td>
|
||||
<td>{{e.workprocedure_name}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="submit-bar">
|
||||
<button class="submit-button" :class="{'btn-disabled': !val1}" :disabled="disabled" @tap="toSure">出库确认</button>
|
||||
<button class="submit-button" @tap="_iosOutgetIvt(val1)">查询</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import NavBar from '@/components/NavBar.vue'
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
import {iosOutgetIvt, iosOutconfirm} from '@/utils/getData1.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
SearchBox
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
val1: '',
|
||||
dataList: [],
|
||||
checkArr: [],
|
||||
disabled: false
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
handleChange (e) {
|
||||
this._iosOutgetIvt(e)
|
||||
},
|
||||
/** grid查询 */
|
||||
async _iosOutgetIvt (e) {
|
||||
let res = await iosOutgetIvt(e)
|
||||
res.data.map(el => {
|
||||
this.$set(el, 'checked', false)
|
||||
})
|
||||
this.dataList = [...res.data]
|
||||
},
|
||||
toCheck (e) {
|
||||
e.checked = !e.checked
|
||||
this.checkArr = this.dataList.filter(i => { return i.checked === true })
|
||||
},
|
||||
/** 确认 */
|
||||
async toSure () {
|
||||
this.disabled = true
|
||||
if (!this.val1) {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await iosOutconfirm(this.checkArr)
|
||||
this.disabled = false
|
||||
this.val1 = ''
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
icon: 'none'
|
||||
})
|
||||
} catch (e) {
|
||||
this.disabled = false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="stylus">
|
||||
</style>
|
||||
Reference in New Issue
Block a user