yangfeng
2023-08-30 38b5988fc107d74b4f3183734daa41dd08239b1a
src/views/supplierManage/supplier/AddNewProduct.vue
@@ -60,7 +60,10 @@
      productId: 1,
      isNoProduct: true,
      supplierId: this.addCommonConfig.infomation.supplierId,
      detailEnter: true
      detailEnter: true,
      deliveryTime: this.addCommonConfig.infomation.deliveryTime, // 供货时长
      shippingDuration: this.addCommonConfig.infomation.shippingDuration, // 物流时长
      purchasePrice: this.addCommonConfig.infomation.purchasePrice // 采购价格
    }
  },
  created() {
@@ -114,7 +117,7 @@
    saveParams() {
      let data = this.editConfig.infomation
      let params = {
        deliveryTime: data.deliveryTime || 0,
        deliveryTime: this.deliveryTime || 0,
        id: data.ID || 0,
        maximumStock: data.maximumStock || 0,
        minimumStock: data.minimumStock || 0,
@@ -122,9 +125,9 @@
        name: data.name || "",
        number: data.number || "",
        productType: data.productType || "",
        purchasePrice: data.purchasePrice || 0,
        purchasePrice: this.purchasePrice || 0,
        remark: data.remark || "",
        shippingDuration: data.shippingDuration || 0,
        shippingDuration: this.shippingDuration || 0,
        specifications: data.specifications || "",
        supplierId: this.supplierId || 0,
        unit: data.unit || ""
@@ -167,10 +170,16 @@
    // 产品列表输入
    inputContent(val, prop, row) {
      this.productId = row.productId
      this.deliveryTime = row.deliveryTime
      this.shippingDuration = row.shippingDuration
      this.purchasePrice = row.purchasePrice
      this.tableData.map((item) => {
        if (item.productId === row.productId) {
          item[prop] = val
          item.supplierId = this.supplierId
          item.deliveryTime = this.deliveryTime
          item.shippingDuration = this.shippingDuration
          item.purchasePrice = this.purchasePrice
        }
      })
    },
@@ -184,8 +193,10 @@
        desc: "",
        name: "",
        number: "",
        price: 0,
        purchasePrice: 0,
        total: 0,
        deliveryTime: 0,
        shippingDuration: 0,
        supplierId: this.supplierId
      })
    },
@@ -200,8 +211,10 @@
          desc: "",
          name: "",
          number: "",
          price: 0,
          purchasePrice: 0,
          total: 0,
          deliveryTime: 0,
          shippingDuration: 0,
          supplierId: this.supplierId
        }
      ]