Explorar el Código

feat: 过滤批次号列表以移除无效项并添加调试日志

xieyong hace 1 mes
padre
commit
7d93ff17b8
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      src/views/firstCheck/index.vue

+ 2 - 1
src/views/firstCheck/index.vue

@@ -325,7 +325,8 @@ export default {
       const product = this.productList.find(
         (p) => p.productCode === productCode
       );
-      this.batchNoList = product?.batchNos || [];
+      this.batchNoList = (product?.batchNos || []).filter(Boolean);
+      console.log(this.batchNoList);
       // 已选批次号若不在新批次号列表中则清空
       if (
         this.searchForm.batchNo &&