| | |
| | | </el-radio-group> |
| | | </div> |
| | | <div style="display: flex;align-items: center;"> |
| | | <span v-if="casing.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='温度循环检验原始记录'"> 套管:</span> |
| | | <el-select v-model="currentTab" placeholder="请选择" @change="m=>handleChange(m,3)" v-if="casing.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName=='成品缆检验原始记录'" size="small"> |
| | | <span v-if="casing.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName=='成品缆检验原始记录'"> 套管:</span> |
| | | <el-select v-model="currentTab" placeholder="请选择" @change="m=>handleChange(m,3)" v-if="casing.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName=='成品缆检验原始记录'" size="small" :loading="getReportModelLoading" @focus="getReportModel(currentSample.id)"> |
| | | <el-option |
| | | v-for="item in casing" |
| | | :key="item.id" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | <span v-if="fibers.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='温度循环检验原始记录'"> 光纤带:</span> |
| | | <el-select v-model="currentTab" placeholder="请选择" @change="m=>handleChange(m,1)" v-if="fibers.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='温度循环检验原始记录'" size="small"> |
| | | <el-select v-model="currentTab" placeholder="请选择" @change="m=>handleChange(m,1)" v-if="fibers.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='温度循环检验原始记录'" size="small" :loading="getReportModelLoading" @focus="getReportModel(currentSample.id)"> |
| | | <el-option |
| | | v-for="item in fibers" |
| | | :key="item.value" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | <span v-if="fiber.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='温度循环检验原始记录'"> 光纤:</span> |
| | | <el-select v-model="currentTab" placeholder="请选择" @change="m=>handleChange(m,2)" v-if="fiber.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='温度循环检验原始记录'" size="small"> |
| | | <el-select v-model="currentTab" placeholder="请选择" @change="m=>handleChange(m,2)" v-if="fiber.length>0&&tableLists.find(m=>m.templateId==currentTable)&&tableLists.find(m=>m.templateId==currentTable).templateName!='温度循环检验原始记录'" size="small" :loading="getReportModelLoading" @focus="getReportModel(currentSample.id)"> |
| | | <el-option |
| | | v-for="item in fiber" |
| | | :label="item.bushColor+'-'+item.color" |
| | |
| | | requiredUp: [] |
| | | }, |
| | | upIndex: 0, |
| | | getReportModelLoading:false, |
| | | insOrder: {}, |
| | | sampleProduct: [], |
| | | typeList: [], |
| | |
| | | } |
| | | } |
| | | }) |
| | | this.handleCasing() |
| | | if(this.tableLists.find(m=>m.templateId==val1)&&(this.tableLists.find(m=>m.templateId==val1).templateName=='成品缆检验原始记录')){ |
| | | if(this.casing.length>0){ |
| | | this.handleChange(this.casing[0].id,3) |
| | |
| | | this.currentSample = this.HaveJson(row) |
| | | let list = await this.getCurrentProduct(row.id,0) |
| | | this.currentSample.insProduct = this.HaveJson(list) |
| | | this.handleCasing() |
| | | this.currentSample.insProduct.forEach(a => { |
| | | this.param[a.id] = { |
| | | insValue: [], |
| | |
| | | currentTable:this.currentTable |
| | | })); |
| | | }, |
| | | handleCasing(){ |
| | | if(this.tableLists.find(m=>m.templateId==this.currentTable)&&(this.tableLists.find(m=>m.templateId==this.currentTable).templateName!='成品缆检验原始记录')){ |
| | | this.currentSample.insProduct = this.currentSample.insProduct.filter(m=>!m.inspectionItem.includes('松套管')) |
| | | } |
| | | }, |
| | | getReportModel(id){ |
| | | if(this.PROJECT!='检测中心'){ |
| | | return |
| | | } |
| | | this.getReportModelLoading = true |
| | | this.$axios.post(this.$api.insOrderPlan.getReportModel+'?sampleId='+id, {}).then(res => { |
| | | this.getReportModelLoading = false |
| | | this.fibers = res.data['光纤带'] |
| | | this.fiber = res.data['光纤'] |
| | | this.casing = res.data['套管'] |
| | | console.log(this.casing) |
| | | }) |
| | | }, |
| | | async handleChange(m,type){ |
| | |
| | | type: 'saveData', |
| | | tableList:this.tableList, |
| | | param:this.param, |
| | | currentTable:this.currentTable |
| | | currentTable:this.currentTable, |
| | | bushing:m |
| | | })); |
| | | }else{ |
| | | this.tableLists = [] |
| | |
| | | this.currentSample = this.HaveJson(this.sampleProduct[index - 1]) |
| | | let list = await this.getCurrentProduct(this.currentSample.id,0) |
| | | this.currentSample.insProduct = this.HaveJson(list) |
| | | this.handleCasing() |
| | | this.param = {} |
| | | this.currentSample.insProduct.forEach(a => { |
| | | this.param[a.id] = { |