Browse Source

检验指引单按钮显示问题 2024/8/6

hella_vue3
王志国 1 month ago
parent
commit
43c8627cae
  1. 15
      src/pages/pointPutawayJob/index.vue
  2. 1
      src/pages/purchaseReceipt/job/receiptDetail.vue

15
src/pages/pointPutawayJob/index.vue

@ -1,11 +1,11 @@
<template> <template>
<!-- 采购上架对应的采购收货打印页面--> <!-- 采购上架对应的采购收货打印页面-->
<view class="content" style="padding:0rpx 20rpx 100rpx;min-height: calc(100vh - 120rpx);"> <view class="content" style="padding:0rpx 20rpx 100rpx;min-height: calc(100vh - 120rpx);">
<view class="tabs-box" v-if="isHave"> <view class="tabs-box" v-if="isHaveOn">
<view @click="tabIndex = 1" :class="tabIndex == 1?'active1' :''" style="padding: 10rpx 0px;">检验指引单</view> <view @click="tabIndex = 1" :class="tabIndex == 1?'active1' :''" style="padding: 10rpx 0px;">检验指引单</view>
<view @click="tabIndex = 2" :class="tabIndex == 2?'active1' :''" style="padding: 10rpx 0px;">上架指引单</view> <view @click="tabIndex = 2" :class="tabIndex == 2?'active1' :''" style="padding: 10rpx 0px;">上架指引单</view>
</view> </view>
<view class="" :style="{'paddingTop':isHave?'100rpx': '30rpx'}"> <view class="" :style="{'paddingTop':isHaveOn?'100rpx': '30rpx'}">
<view class="box" style="page-break-before:always;" v-if="tabIndex == 1"> <view class="box" style="page-break-before:always;" v-if="tabIndex == 1">
<view class=""> <view class="">
<table border='1'> <table border='1'>
@ -59,10 +59,10 @@
</view> </view>
<view class="" style="position: fixed;width: 100%;bottom: 0rpx;left: 0px;"> <view class="" style="position: fixed;width: 100%;bottom: 0rpx;left: 0px;">
<button @click="printImage" v-if="tabIndex == 1 && data1.inspectDTOList && data1.inspectDTOList.length>0" <button @click="printImage" v-if="tabIndex == 1 && isHaveInspect && data1.inspectDTOList && data1.inspectDTOList.length>0"
style='background:rgb(60, 156, 255) !important ;color: white;margin-top: 80rpx;'> 打印检验指引单 style='background:rgb(60, 156, 255) !important ;color: white;margin-top: 80rpx;'> 打印检验指引单
</button> </button>
<button @click="printImage" v-if="tabIndex == 2&&isHave && data.sublist && data.sublist.length>0" <button @click="printImage" v-if="tabIndex == 2&&isHaveOn && data.sublist && data.sublist.length>0"
style='background:rgb(60, 156, 255) !important ;color: white;margin-top: 80rpx;'> 打印上架指引单 style='background:rgb(60, 156, 255) !important ;color: white;margin-top: 80rpx;'> 打印上架指引单
</button> </button>
</view> </view>
@ -110,7 +110,8 @@ export default {
currentPage1: 1, currentPage1: 1,
pageSize1: 20, pageSize1: 20,
number:'', number:'',
isHave:false isHaveOn: false,//
isHaveInspect:false,//
} }
}, },
@ -271,13 +272,14 @@ export default {
onLoad(option) { onLoad(option) {
if (option.data) { if (option.data) {
this.data = JSON.parse(decodeURIComponent(option.data)); this.data = JSON.parse(decodeURIComponent(option.data));
this.isHave = true this.isHaveOn = true
} }
if (option.number) { if (option.number) {
this.number = option.number; this.number = option.number;
} }
}, },
async onShow() { async onShow() {
//
await getJimuPutawayJobDetail({ await getJimuPutawayJobDetail({
masterIds: this.data.ids masterIds: this.data.ids
}).then(res => { }).then(res => {
@ -290,6 +292,7 @@ export default {
}).then(async res1 => { }).then(async res1 => {
this.data1 = res1.data this.data1 = res1.data
this.getTableInspectDTOList() this.getTableInspectDTOList()
this.isHaveInspect = this.data1.inspectDTOList.some(item=>item.sampleQty>0)
}) })
this.getPointPutawayJobHtml() this.getPointPutawayJobHtml()
this.getPurchaseReceiptJobHtml() this.getPurchaseReceiptJobHtml()

1
src/pages/purchaseReceipt/job/receiptDetail.vue

@ -446,6 +446,7 @@ const submitJob = () => {
ids: res1.data.list.map((item) => item.masterId).join(',') ids: res1.data.list.map((item) => item.masterId).join(',')
} }
console.log(dataParams) console.log(dataParams)
uni.hideLoading()
uni.redirectTo({ uni.redirectTo({
uurl: '/pages/pointPutawayJob/index?number='+jobContent.value.number+'&data=' + uurl: '/pages/pointPutawayJob/index?number='+jobContent.value.number+'&data=' +
encodeURIComponent(JSON.stringify(dataParams)) encodeURIComponent(JSON.stringify(dataParams))

Loading…
Cancel
Save