zss
2023-11-17 103b4575556d8c18a5707c162099070b82640554
src/views/plan/manufacturingorder/productorder-form.vue
@@ -501,7 +501,7 @@
                          @refreshTestStandardInfo="refreshTestStandardInfo"
                        ></testStandardTable>
                      </el-tab-pane>
                      <el-tab-pane
                      <!-- <el-tab-pane
                        label="抽检规则"
                        key="tb2"
                        id="tb2"
@@ -587,7 +587,7 @@
                            </el-table>
                          </div>
                        </div>
                      </el-tab-pane>
                      </el-tab-pane> -->
                    </el-tabs>
                  </el-col>
                </el-row>
@@ -638,17 +638,11 @@
                </el-row>
                <el-row>
                  <el-table
                    default-expand-all
                    :data="components"
                    :data="components[0]"
                    @selection-change="structSelectionChange"
                    row-key="id"
                    border
                    :tree-props="{
                      children: 'children'
                    }"
                    style="width: 100%"
                    height="400px"
                    :default-sort="{ prop: 'index' }"
                  >
                    <el-table-column type="selection" width="40" fixed="left" />
                    <el-table-column
@@ -759,7 +753,7 @@
                    </el-table-column>
                  </el-table>
                </el-row>
                <el-row>
                <!-- <el-row>
                  <el-col :span="24"
                    ><div style="margin-top:5px;">
                      <span style="font-size:12px;">外协发料表</span>
@@ -851,7 +845,7 @@
                      </el-table-column>
                    </el-table>
                  </el-col>
                </el-row>
                </el-row> -->
              </el-tab-pane>
              <el-tab-pane label="客户订单" id="ta3" key="ta3" name="ta3">
                <CustomerOrder :orderId="dataForm.id" />
@@ -1071,6 +1065,7 @@
  data() {
    return {
      componentsTable:[],
      typeOptions: [],
      paramTemplateSelArr: [],
      paramTemplateSelCol: 'operationTemplateNo',
@@ -1232,6 +1227,7 @@
    this.getBomTypeDbOptions()
    this.getManufactureAttrs('manufacture_attr_type')
    this.getSysParam(sysParam.IS_REPORT_OPERATION)
    // console.log(this.components);
  },
  watch: {
    'dataForm.partId'(newValue, oldValue) {
@@ -1245,7 +1241,11 @@
        }
      }
    },
    components(newVal,oldVal){
      console.log("新",newVal);
      console.log("老",oldVal);
      console.log(this.components);
    },
    currentRouting(newValue, oldValue) {
      if (newValue && newValue.id) {
        if (this.dataForm.id != null && this.dataForm.id !== 0) {
@@ -1295,7 +1295,8 @@
      if (newValue && newValue.id) {
        // 查询产品结构对应的组件
        getBom(newValue.id).then((response) => {
          this.components = [response.data.data.tree]
          console.log("查",this.components);
          // this.components = [response.data.data.tree]
        })
      }
    },
@@ -1397,6 +1398,7 @@
    },
    // 查询当前车间订单信息
    getOrderInfo() {
      let that=this
      getManufacturingOrder(this.dataForm.id).then((response) => {
        this.dataForm = response.data.data
        // 把工艺挂上去
@@ -1416,7 +1418,7 @@
        }
        // 把产品结构组件挂上去
        if (this.dataForm.bomRoot) {
          this.components = [this.dataForm.bomRoot]
          that.components = [this.dataForm.bomRoot]
        }
      })
    },