冯诚 %!s(int64=3) %!d(string=hai) anos
pai
achega
7fa6a652f8
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      src/pages/fill-order/index.vue

+ 3 - 1
src/pages/fill-order/index.vue

@@ -36,7 +36,9 @@ if (id) {
   renewal === 'true' && (state.form.renewal = +id)
   getCurrentOrder(id).then(() => {
     const order = rootState.currentOrder
-    state.form.product_id = +order.product_id
+    if (state.productList.some(item => item.id === +order.product_id)) {
+      state.form.product_id = +order.product_id
+    }
     state.form.subscribe_type = +order.subscribe_type === 1 ? 'month' : 'year'
     state.form.brand_id = +order.brand_id
     state.form.phone_id = +order.phone_id