虚拟出库父页
This commit is contained in:
@@ -51,7 +51,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="submit-bar">
|
||||
<button class="submit-button" :class="{'btn-disabled': !pkId}" :disabled="disabled1" @tap="_stoutConfirm">出库确认</button>
|
||||
<button class="submit-button" :class="{'btn-disabled': !dataList.length}" :disabled="disabled1" @tap="_stoutConfirm">出库确认</button>
|
||||
<button class="submit-button" @tap="_queryRawFoilList">查询</button>
|
||||
</view>
|
||||
</view>
|
||||
@@ -60,7 +60,7 @@
|
||||
<script>
|
||||
import NavBar from '@/components/NavBar.vue'
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
import {ivtQuery, stoutConfirm, stoutPrint} from '@/utils/getData1.js'
|
||||
import {stivtQuery, stoutConfirm, stoutPrint} from '@/utils/getData1.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
@@ -70,8 +70,6 @@
|
||||
return {
|
||||
val1: '',
|
||||
val2: '',
|
||||
options: [],
|
||||
index: '',
|
||||
dataList: [],
|
||||
pkId: '',
|
||||
pkObj: {},
|
||||
@@ -79,25 +77,20 @@
|
||||
};
|
||||
},
|
||||
created () {
|
||||
this._ivtQuery()
|
||||
},
|
||||
methods: {
|
||||
handleChange (e) {
|
||||
// console.log(e)
|
||||
},
|
||||
/** 初始化查询 */
|
||||
async _ivtQuery () {
|
||||
let res = await ivtQuery(this.val1, this.val2, '0')
|
||||
async _stivtQuery () {
|
||||
let res = await stivtQuery(this.val1, this.val2)
|
||||
this.dataList = [...res.data]
|
||||
},
|
||||
async _stoutConfirm () {
|
||||
this.disabled1 = true
|
||||
if (!this.pkId) {
|
||||
this.disabled1 = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await stoutConfirm(this.pkObj, '0')
|
||||
let res = await stoutConfirm(this.dataList, this.val1)
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
icon: 'none'
|
||||
@@ -105,7 +98,7 @@
|
||||
this.disabled1 = false
|
||||
this.pkId = ''
|
||||
this.pkObj = {}
|
||||
this._ivtQuery()
|
||||
this._stivtQuery()
|
||||
} catch (e) {
|
||||
this.disabled1 = false
|
||||
}
|
||||
@@ -125,7 +118,7 @@
|
||||
this.disabled1 = false
|
||||
this.pkId = ''
|
||||
this.pkObj = {}
|
||||
this._ivtQuery()
|
||||
this._stivtQuery()
|
||||
} catch (e) {
|
||||
this.disabled1 = false
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user