فهرست منبع

修改上次提交

single 10 ماه پیش
والد
کامیت
bba66570a2
1فایلهای تغییر یافته به همراه6 افزوده شده و 8 حذف شده
  1. 6 8
      src/pages/affairs/transaction.vue

+ 6 - 8
src/pages/affairs/transaction.vue

@@ -2,7 +2,7 @@
  * @Author: PoJun
  * @Date: 2023-10-13 10:35:43
  * @LastEditors: XuanJi
- * @LastEditTime: 2024-05-08 21:04:39
+ * @LastEditTime: 2024-05-08 21:14:46
  * @Message: 事务处理中心
 -->
 <template>
@@ -38,11 +38,7 @@
                         <common-card-item label="联系方式" :text="detailItem?.data.phone" :span="24"></common-card-item>
                         <common-card-item label="地址" :text="detailItem?.data.address" :span="24"></common-card-item>
                         <common-card-item label="企业简介" :text="detailItem?.data.intro" :span="24"></common-card-item>
-                        <common-card-item
-                            label="产品"
-                            :text="detailItem?.data.productName"
-                            :span="24"
-                        ></common-card-item>
+                        <common-card-item label="产品" :text="productName" :span="24"></common-card-item>
                         <common-card-item
                             label="优势产品"
                             :text="detailItem?.data.superiorProduct"
@@ -140,6 +136,7 @@ export default {
             showModal: false,
             detailItem: null,
             currentKey: "todo",
+            productName: "",
         };
     },
     created() {},
@@ -180,11 +177,11 @@ export default {
         async getProductName(idArray) {
             try {
                 // console.log(idArray);
-                const data = await getProductsInfoFromIds({ ids: idArray.join(",") });
+                const data = await getProductsInfoFromIds({ ids: idArray.join("") });
                 const productName = data.map(item => {
                     return item.name;
                 });
-                this.detailItem.productName = productName.join(",");
+                this.productName = productName.join(",");
             } catch (error) {
                 console.log(error);
             }
@@ -195,6 +192,7 @@ export default {
             handler: function (val) {
                 if (!val) {
                     this.detailItem = null;
+                    this.productName = "";
                 }
             },
         },