feat:打印和分析管理
This commit is contained in:
@@ -91,7 +91,7 @@ function handleReturnToStock() {
|
||||
})
|
||||
if (res.isPrint == 1) {
|
||||
// 执行打印
|
||||
nx.$print.getPrintTemplateAndPrint(res.id)
|
||||
nx.$print.print({ ...res, printTemplate: 'returnLabel' })
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
<script setup>
|
||||
import { ref, computed } from 'vue'
|
||||
import { useListData } from '@/nx/hooks/usePageListData'
|
||||
import { onShow } from '@dcloudio/uni-app'
|
||||
import nx from '@/nx'
|
||||
|
||||
const list = ref(['待处理', '已处理'])
|
||||
@@ -53,10 +54,12 @@ const searchParams = computed(() => {
|
||||
})
|
||||
const { listData, scrollToLower, loadStatus, getInitData } = useListData({
|
||||
searchParams,
|
||||
api: nx.$api.sampleWarehouse.querySampleDispatchApply,
|
||||
needInitListData: true
|
||||
api: nx.$api.sampleWarehouse.querySampleDispatchApply
|
||||
})
|
||||
|
||||
onShow(()=>{
|
||||
getInitData()
|
||||
})
|
||||
function handleScrolltolower() {
|
||||
scrollToLower()
|
||||
}
|
||||
|
||||
@@ -124,10 +124,8 @@ async function getSampleDetail() {
|
||||
let btnLoading = ref(false)
|
||||
function handlePrint() {
|
||||
btnLoading.value = true
|
||||
nx.$print.getPrintTemplateAndPrint(sampleData.value.id, () => {
|
||||
uni.showToast({ title: '已打印', icon: 'success' })
|
||||
btnLoading.value = false
|
||||
})
|
||||
nx.$print.print({ ...sampleData.value, printTemplate: 'returnLabel' })
|
||||
btnLoading.value = false
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user