Parcourir la source

fix: 支持工单列表产品线从动态表单获取

liuyaqi il y a 2 ans
Parent
commit
5533f2b813
1 fichiers modifiés avec 11 ajouts et 1 suppressions
  1. 11 1
      src/views/work/order/index.vue

+ 11 - 1
src/views/work/order/index.vue

@@ -60,7 +60,7 @@
             {{ selectDictLabel(orderStatusOptions, row.orderStatus) }}
           </span>
           <span v-else-if="item.prop === 'productLine'">
-            {{ selectDictLabel(productLineOptions, row.productLine) }}
+            {{ row.productLineName ? row.productLineName : selectDictLabel(productLineOptions, row.productLine) }}
           </span>
           <span v-else-if="item.prop === 'createdTime'">
             {{ parseTime(row.createdTime, '{y}-{m}-{d}') }}
@@ -224,6 +224,16 @@
         const params = { ...this.queryForm }
         const [err, res] = await to(api.getList(params))
         if (err) return (this.listLoading = false)
+        if (res.data.list) {
+          res.data.list.filter((i) => {
+            let idata = JSON.parse(i.formData)
+            idata.filter((field) => {
+              if (field.name == '产品线') {
+                i.productLineName = field.value
+              }
+            })
+          })
+        }
         this.list = res.data.list || []
         this.total = res.data.total
         this.listLoading = false