瀏覽代碼

行李报文过滤条件修改

zhongxiaoyu 2 年之前
父節點
當前提交
f7ef47a88c
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/views/baggageManagement/components/baggage/index.vue

+ 1 - 1
src/views/baggageManagement/components/baggage/index.vue

@@ -894,7 +894,7 @@ export default {
         const messageList = result.reduce((list, message, currentIndex, arr) => {
           const messageObject = typeof message === 'string' ? JSON.parse(message) : message
           // 确保是当前行李的报文
-          const isCorrectBaggage = messageObject.dataContent.includes(bagSN.slice(0, 7))
+          const isCorrectBaggage = messageObject.dataContent.match(/\.N\/([0-9]{10})/)?.[1] === bagSN
           // 相同报文去重
           const index = arr.findIndex(testMessage => {
             const testMessageObject = typeof testMessage === 'string' ? JSON.parse(testMessage) : testMessage