小牛集卡web 客户端
chenwei
2021-06-07 bc06fc0e98ed22b45638d5c2c9635283837104fd
src/components/agopage/comment/InfoDialog.vue
@@ -54,7 +54,7 @@
        </el-form-item>
        <el-form-item
          label="重量"
          :prop="'moreBox.' + index + '.BoxSeal'"
          :prop="'moreBox.' + index + '.Weight'"
          :rules="{
            required: true,
            message: '请填写重量',
@@ -62,7 +62,7 @@
          }"
        >
          <el-input
            v-model="item.BoxSeal"
            v-model="item.Weight"
            type="number"
            placeholder="请输入数字"
          ></el-input>
@@ -125,30 +125,34 @@
            console.log("多个箱子");
            this.ruleForm.moreBox = [];
            for (var i = 0; i < val.TempOrderContainer.length; i++) {
              this.ruleForm.moreBox.push({ ContainerNo: "", BoxSeal: "" });
              this.ruleForm.moreBox.push({ ContainerNo: "", BoxSeal: "" ,Weight:""});
            }
            for (var j = 0; j < this.ruleForm.moreBox.length; j++) {
              this.ruleForm.moreBox[j].ContainerNo =
                val.TempOrderContainer[j].ContainerNo;
              this.ruleForm.moreBox[j].BoxSeal =
                val.TempOrderContainer[j].BoxSeal;
                 this.ruleForm.moreBox[j].Weight =
                val.TempOrderContainer[j].Weight;
            }
          } else {
            console.log("单个箱子");
            this.ruleForm.moreBox = [{ ContainerNo: "", BoxSeal: "" }];
            this.ruleForm.moreBox = [{ ContainerNo: "", BoxSeal: "",Weight:"" }];
            this.ruleForm.moreBox[0].ContainerNo =
              val.TempOrderContainer[0].ContainerNo;
            this.ruleForm.moreBox[0].BoxSeal =
              val.TempOrderContainer[0].BoxSeal;
              his.ruleForm.moreBox[0].Weight =
              val.TempOrderContainer[0].Weight;
          }
          console.log(this.ruleForm);
        } else {
          if (val.ContainerNub == 1) {
            this.ruleForm.moreBox = [{ ContainerNo: "", BoxSeal: "" }];
          if ((val.ContainerNub)*(val.Container.CnterNub) == 1) {
            this.ruleForm.moreBox = [{ ContainerNo: "", BoxSeal: "",Weight:""  }];
          } else {
            this.ruleForm.moreBox = [];
            for (var i = 0; i < val.ContainerNub; i++) {
              this.ruleForm.moreBox.push({ ContainerNo: "", BoxSeal: "" });
            for (var i = 0; i < (val.ContainerNub)*(val.Container.CnterNub); i++) {
              this.ruleForm.moreBox.push({ ContainerNo: "", BoxSeal: "",Weight:""  });
            }
          }
        }
@@ -218,6 +222,7 @@
            .then(() => {
              this.ruleForm.id = this.temId;
              this.$emit("info", this.ruleForm);
            })
            .catch(() => {});
          console.log(this.ruleForm);