生箔工序打印
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row jccenter mgt20">
|
||||
<button class="zd-col-7 btn-submit btn-success" :class="{'btn-info': !val1}" :disabled="val1 && type === '2' && disabled2" style="margin-right: 15px" @tap="handleConfirm1('2')">{{$t('button.upper-axis')}}</button>
|
||||
<button class="zd-col-7 btn-submit btn-success" :class="{'btn-info': !val1}" :disabled="val1 && type === '2' && disabled2" @tap="handleConfirm1('2')">{{$t('button.upper-axis')}}</button>
|
||||
<button class="zd-col-7 btn-submit btn-success" :class="{'btn-info': !val1}" :disabled="val1 && type === '4' && disabled2" @tap="handleConfirm1('4')">{{$t('button.lower-axis')}}</button>
|
||||
<button class="zd-col-7 btn-submit btn-success" :class="{'btn-info': !val1}" :disabled="disabled1" @tap="handleConfirm2('5')">{{$t('button.ready-to-go')}}</button>
|
||||
</view>
|
||||
@@ -34,6 +34,7 @@
|
||||
</view>
|
||||
<view class="zd-row jccenter mgt20">
|
||||
<button class="zd-col-7 btn-submit btn-success" :class="{'btn-info': !val1 || !val2}" :disabled="disabled1" @tap="handleConfirm2('6')">{{$t('button.add-order')}}</button>
|
||||
<button class="zd-col-7 btn-submit btn-success" :class="{'btn-info': !val2}" :disabled="disabled1" @tap="handleConfirm2('7')">打印</button>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd_wrapper grid-wraper">
|
||||
@@ -89,7 +90,7 @@
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
import UpTop from '@/components/upTop.vue'
|
||||
import { confirmAction } from '@/utils/utils.js'
|
||||
import {queryProductArea, queryRawFoilList, createOrder, confirmBlanking, rawScrollDowm} from '@/utils/getData1.js'
|
||||
import {queryProductArea, queryRawFoilList, createOrder, rawPrint, confirmBlanking, rawScrollDowm} from '@/utils/getData1.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
@@ -179,6 +180,9 @@
|
||||
if ((!this.val1 || !this.val2) && type === '6') {
|
||||
return
|
||||
}
|
||||
if (!this.val2 && type === '7') {
|
||||
return
|
||||
}
|
||||
const isConfirmed = await confirmAction("确认操作", "确定要执行此操作吗?")
|
||||
if (isConfirmed) {
|
||||
if (type === '5') {
|
||||
@@ -187,6 +191,9 @@
|
||||
if (type === '6') {
|
||||
this._createOrder()
|
||||
}
|
||||
if (type === '7') {
|
||||
this._rawPrint()
|
||||
}
|
||||
}
|
||||
},
|
||||
async _confirmBlanking () {
|
||||
@@ -221,6 +228,22 @@
|
||||
this.disabled1 = false
|
||||
}
|
||||
},
|
||||
async _rawPrint () {
|
||||
this.disabled1 = true
|
||||
try {
|
||||
let res = await rawPrint(this.val2)
|
||||
this.disabled1 = false
|
||||
this.pkId = ''
|
||||
this.pkObj = {}
|
||||
this.searchList()
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
icon: 'none'
|
||||
})
|
||||
} catch (e) {
|
||||
this.disabled1 = false
|
||||
}
|
||||
},
|
||||
async handleConfirm1(type) {
|
||||
this.type = type
|
||||
if (!this.pkId && (type === '1' || type === '3')) {
|
||||
|
||||
@@ -50,6 +50,13 @@ export const createOrder = (code, name) => request({
|
||||
container_name: name
|
||||
}
|
||||
})
|
||||
// 打印
|
||||
export const rawPrint = (name) => request({
|
||||
url: 'api/pda/raw/print',
|
||||
data: {
|
||||
container_name: name
|
||||
}
|
||||
})
|
||||
// 确认下卷-改为:准备就绪
|
||||
export const confirmBlanking = (code) => request({
|
||||
url: 'api/pda/raw/confirmBlanking',
|
||||
|
||||
Reference in New Issue
Block a user