diff --git a/src/components/ElectronicSeal/index.vue b/src/components/ElectronicSeal/index.vue
index 5b6a21a..2e9f822 100644
--- a/src/components/ElectronicSeal/index.vue
+++ b/src/components/ElectronicSeal/index.vue
@@ -241,15 +241,19 @@ const props = defineProps({
type: String,
default: '',
},
+ maId: {
+ type: [String, Number],
+ default: '',
+ },
})
-// 监听 props.maCode 值变化
+// 监听 props.maId 值变化
watch(
- () => props.maCode,
+ () => props.maId,
(newValue) => {
console.log('newValue', newValue)
if (newValue) {
- maCodeTwo.value = newValue
+ maCodeTwo.value = props.maCode
changeTag()
}
},
@@ -265,7 +269,7 @@ const changeTag = async () => {
if (!maCodeTwo.value) return
try {
- const response = await getListTag({ maCode: maCodeTwo.value })
+ const response = await getListTag({ maCode: maCodeTwo.value, maId: props.maId })
if (response.data && response.data.length !== 0) {
tagInfo.value = response.data[0]
isJj.value = tagInfo.value.isJj
@@ -282,6 +286,9 @@ const changeTag = async () => {
drawStamp(stampText, companyName, canvasId)
})
+ } else {
+ console.log('未找到标签信息')
+ isJj.value = null
}
} catch (error) {
console.error('获取标签信息失败', error)
diff --git a/src/pages/devicesSearch/codeSearch.vue b/src/pages/devicesSearch/codeSearch.vue
index f3f04e2..cfc352a 100644
--- a/src/pages/devicesSearch/codeSearch.vue
+++ b/src/pages/devicesSearch/codeSearch.vue
@@ -101,7 +101,7 @@
-