From d2e867966539004b6b5a73ae3566a659ac6f8b6d Mon Sep 17 00:00:00 2001
From: zouyu <2723363702@qq.com>
Date: 星期四, 30 十月 2025 11:55:34 +0800
Subject: [PATCH] 检验任务数据分类查询问题修复
---
src/views/business/productOrder/components/addInspectionDia.vue | 33 +++++++++++----------------------
1 files changed, 11 insertions(+), 22 deletions(-)
diff --git a/src/views/business/productOrder/components/addInspectionDia.vue b/src/views/business/productOrder/components/addInspectionDia.vue
index 3872bff..b689ac4 100644
--- a/src/views/business/productOrder/components/addInspectionDia.vue
+++ b/src/views/business/productOrder/components/addInspectionDia.vue
@@ -7,6 +7,7 @@
title="娣诲姞妫�楠岄」"
width="80%">
<el-table ref="sampleTable" :data="sampleList" border class="el-table sampleTable" highlight-current-row
+ :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }"
max-height="400px" tooltip-effect="dark">
<el-table-column align="center" label="搴忓彿" type="index" width="65"></el-table-column>
<el-table-column align="center" label="鏍峰搧鍚嶇О" min-width="100" prop="sample">
@@ -26,9 +27,9 @@
size="small"></el-input>
</template>
</el-table-column>
- <el-table-column align="center" label="妫�楠屾爣鍑�" min-width="100" prop="standardMethodListId">
+ <el-table-column align="center" label="妫�楠屾爣鍑�" min-width="100" prop="standardMethodName">
<template slot-scope="scope">
- <el-input v-model="scope.row.standardMethodListId" clearable disabled placeholder="涓嶅~鍐欏垯绯荤粺鑷姩鐢熸垚"
+ <el-input v-model="scope.row.standardMethodName" clearable disabled placeholder="涓嶅~鍐欏垯绯荤粺鑷姩鐢熸垚"
size="small"></el-input>
</template>
</el-table-column>
@@ -46,8 +47,8 @@
title="娣诲姞妫�楠岄」"
width="90%">
<el-table ref="productTable" v-loading="getProductLoad" :data="productList" :row-class-name="tableRowClassName" border class="el-table"
- max-height="700px" style="margin-bottom: 10px;" tooltip-effect="dark"
- @selection-change="selectProduct">
+ :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }"
+ max-height="580px" tooltip-effect="dark" @selection-change="selectProduct">
<el-table-column type="selection" width="65"></el-table-column>
<el-table-column label="妫�楠岄」鍒嗙被" min-width="140" prop="inspectionItemClass" show-overflow-tooltip></el-table-column>
<el-table-column label="妫�楠岄」" min-width="140" prop="inspectionItem" show-overflow-tooltip></el-table-column>
@@ -105,6 +106,8 @@
</template>
<script>
+import {addOmitOrderProduct, getProductTreeBySampleId, getSampleByOrderId} from "@/api/business/productOrder";
+
export default {
name: "addInspectionDia",
// import 寮曞叆鐨勭粍浠堕渶瑕佹敞鍏ュ埌瀵硅薄涓墠鑳戒娇鐢�
@@ -132,10 +135,7 @@
methods: {
getDataList(row) {
this.dialogVisible = true
- this.$axios.get(this.$api.insOrder.getSampleByOrderId + '?insOrderId=' + row.id).then(res => {
- if (res.code === 201) {
- return
- }
+ getSampleByOrderId({insOrderId: row.id}).then(res => {
this.sampleList = res.data
})
},
@@ -143,11 +143,8 @@
this.itemDialogVisible = true
this.getProductLoad = true
this.id=row.id
- this.$axios.get(this.$api.insOrder.getProductTreeBySampleId + '?insSampleId=' + row.id).then(res => {
+ getProductTreeBySampleId({insSampleId: row.id}).then(res => {
this.getProductLoad = false
- if (res.code === 201) {
- return
- }
this.productList = res.data
}).catch(err => {
this.getProductLoad = false
@@ -170,16 +167,8 @@
type: 'warning'
}).then(() => {
this.upLoad = true
- this.$axios.post(this.$api.insOrder.addOmitOrderProduct,{insProductBindingList:this.productListSelected,insSampleId:this.id}, {
- headers: {
- "Content-Type": "application/json"
- },
- noQs: true
- } ).then(res => {
+ addOmitOrderProduct({insProductBindingList:this.productListSelected,insSampleId:this.id}).then(res => {
this.upLoad = false
- if (res.code === 201) {
- return
- }
this.$message.success('娣诲姞鎴愬姛锛�')
this.itemDialogVisible = false
}).catch(err => {
@@ -188,7 +177,7 @@
}).catch(() => {
this.$message({
type: 'info',
- message: '宸插彇娑堝垹闄�'
+ message: '宸插彇娑堟坊鍔�'
});
});
},
--
Gitblit v1.9.3