From 863490a56ebc6675587d163faacf2bf4ef03fa50 Mon Sep 17 00:00:00 2001
From: 曹睿 <360930172@qq.com>
Date: 星期三, 23 四月 2025 10:20:43 +0800
Subject: [PATCH] feat: 完成单丝编号展示

---
 src/pages/production/twist/receive/monofil.vue        |    9 +--------
 src/pages/production/twist/components/MonofilCard.vue |   31 ++++++++++---------------------
 2 files changed, 11 insertions(+), 29 deletions(-)

diff --git a/src/pages/production/twist/components/MonofilCard.vue b/src/pages/production/twist/components/MonofilCard.vue
index 38921d1..e5e5ada 100644
--- a/src/pages/production/twist/components/MonofilCard.vue
+++ b/src/pages/production/twist/components/MonofilCard.vue
@@ -1,30 +1,19 @@
 <template>
   <wd-card>
-    <wd-form :model="model">
-      <wd-cell-group :border="true">
-        <wd-input
-          v-model="model.monofilamentNumber"
-          label="鍗曚笣缂栧彿"
-          label-width="100px"
-          prop="no"
-          clearable
-          placeholder="璇疯緭鍏ュ崟涓濈紪鍙�"
-        />
-        <wd-input
-          v-model="model.oneLength"
-          label="闀垮害"
-          label-width="100px"
-          prop="length"
-          clearable
-          placeholder="璇疯緭鍏ラ暱搴�"
-        />
-      </wd-cell-group>
-    </wd-form>
+    <wd-cell-group :border="true">
+      <wd-cell title="鍗曚笣缂栧彿" :value="data.monofilamentNumber" />
+      <wd-cell title="闀垮害" :value="data.oneLength" />
+    </wd-cell-group>
   </wd-card>
 </template>
 
 <script setup lang="ts">
-const model: any = defineModel("value");
+defineProps({
+  data: {
+    type: Object,
+    default: () => {},
+  },
+});
 </script>
 
 <style lang="scss" scoped></style>
diff --git a/src/pages/production/twist/receive/monofil.vue b/src/pages/production/twist/receive/monofil.vue
index b7c31b8..d6b769c 100644
--- a/src/pages/production/twist/receive/monofil.vue
+++ b/src/pages/production/twist/receive/monofil.vue
@@ -14,7 +14,7 @@
           </template>
         </CardTitle>
       </template>
-      <MonofilCard v-for="(item, index) in cardList" v-model:value="item" :key="index" />
+      <MonofilCard v-for="(item, index) in cardList" :key="index" :data="item" />
       <template #bottom>
         <view class="flex justify-center items-center">
           <wd-button block>
@@ -35,7 +35,6 @@
 import ManageApi from "@/api/product/manage";
 import TwistApi from "@/api/product/twist";
 import zPaging from "@/components/z-paging/z-paging.vue";
-import { useMessage } from "wot-design-uni";
 // import { useZebraScan } from "@/hooks/useZebraScan";
 // const { init, start, stop, triggerScan } = useZebraScan();
 
@@ -43,7 +42,6 @@
 const pagingRef = ref();
 const scanRef = ref();
 const cardList = ref<any[]>([]);
-const message = useMessage();
 
 const getScanCode = async (code: any) => {
   console.log("鑷畾涔夋壂鎻忕殑缁撴灉鍥炶皟鍑芥暟:", code);
@@ -53,11 +51,6 @@
   const { data } = await TwistApi.getScarn({
     outPutId: codeArr[1],
   });
-  // console.log("鍗曚笣缂栧彿", data);
-  // message.alert({
-  //   title: "鍗曚笣缂栧彿",
-  //   msg: JSON.stringify(data),
-  // });
   pagingRef.value.complete([data]);
 };
 

--
Gitblit v1.9.3