李林
2024-03-22 21ac6eaa16c46edfe331627c59fc1974f78003fb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
<style scoped>
    .title {
        height: 60px;
        line-height: 60px;
    }
 
    .search {
        width: 100%;
        margin-bottom: 10px;
        height: 140px;
        background-color: #fff;
        border-radius: 3px;
    }
 
    .search .form-inline {
        height: 50px;
        padding-top: 20px;
        padding-left: 50px;
    }
 
    .center {
        width: calc(100% - 40px);
        height: calc(100% - 60px - 80px - 40px);
        background-color: #fff;
        border-radius: 3px;
        padding: 20px;
    }
</style>
<style>
    .el-form-item__label{
        color: #000;
    }
  .el-drawer__header::before {
    content: "";
    display: inline-block;
    width: 4px;
    height: 30.24px;
    background: #3A7BFA;
    border-radius: 10px;
    margin-left: 32px;
    margin-right: 8.5px;
  }
  .el-drawer__header{
    color: #303133;
  }
</style>
<template>
    <div>
        <el-row class="title">
                    <el-col :span="12" style="padding-left: 20px;">样品详情</el-col>
                    <el-col :span="12" style="text-align: right;">
                        <el-button size="small" type="primary" @click="sampleVisible=true">样品切换</el-button>
            <el-button size="small" type="primary" @click="taskVisible=true">任务切换</el-button>
            <el-button size="small" @click="$emit('goback')">返回</el-button>
                    </el-col>
                </el-row>
        <div class="search">
            <el-form :inline="true" :model="searchForm" class="form-inline">
                <el-form-item label="委托编号:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
                <el-form-item label="样品编号:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="样品名称:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="样品数量:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="下发时间:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="紧急程度:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="约定时间:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
        <el-form-item label="当前样品数:">
                    <el-input clearable v-model="searchForm.sampleName" disabled size="small" placeholder="请输入"></el-input>
                </el-form-item>
            </el-form>
        </div>
        <div class="center">
        </div>
    <el-drawer
      title="样品切换"
      :visible.sync="sampleVisible"
      :destroy-on-close="true"
      size="55%">
      <el-table class="el-table" ref="productTable" :data="productList" height="100%" tooltip-effect="dark" border highlight-current-row @row-click="handleChangeSample">
                <el-table-column type="index" align="center" label="序号" width="70" :key="Math.random()">
                </el-table-column>
                <el-table-column prop="inspectionItemSubclass" label="样品编号" min-width="100"
                    show-overflow-tooltip></el-table-column>
                <el-table-column prop="sonLaboratory" label="检测状态" min-width="100" show-overflow-tooltip></el-table-column>
                <el-table-column prop="method" label="检测人" min-min-width="100" show-overflow-tooltip></el-table-column>
                <el-table-column prop="unit" label="是否留样" min-width="100" show-overflow-tooltip></el-table-column>
            </el-table>
    </el-drawer>
    <el-drawer
      title="任务切换"
      :visible.sync="taskVisible"
      :destroy-on-close="true"
      size="55%">
      <el-table class="el-table" ref="productTable" :data="productList" height="100%" tooltip-effect="dark" border highlight-current-row @row-click="handleChangeTask">
                <el-table-column prop="inspectionItemSubclass" label="委托编号" min-width="100"
                    show-overflow-tooltip></el-table-column>
                <el-table-column prop="sonLaboratory" label="样品编号" min-width="100" show-overflow-tooltip></el-table-column>
                <el-table-column prop="method" label="样品名称" min-min-width="100" show-overflow-tooltip></el-table-column>
                <el-table-column prop="unit" label="紧急程度" min-width="100" show-overflow-tooltip>
          <template slot-scope="scope">
            <el-tag
              :type="scope.row.type" size="medium">{{scope.row.label}}</el-tag>
                    </template>
        </el-table-column>
        <el-table-column prop="unit" label="状态" min-width="100" show-overflow-tooltip>
          <template slot-scope="scope">
            <el-tag
              :type="scope.row.type" size="medium">{{scope.row.label}}</el-tag>
                    </template>
        </el-table-column>
        <el-table-column prop="method" label="约定时间" min-min-width="100" show-overflow-tooltip></el-table-column>
        <el-table-column prop="method" label="下发时间" min-min-width="100" show-overflow-tooltip></el-table-column>
            </el-table>
    </el-drawer>
    </div>
</template>
 
<script>
    export default {
        props: ['orderId'],
        data() {
            return {
        sampleVisible:false,
        taskVisible:false,
                searchForm: {
                    sampleName: null,
                    state: null
                },
        productList:[],
                id: 0
            }
        },
        created() {
            this.id = this.orderId
        },
        mounted() {
            
        },
        methods: {
      handleChangeSample(row){
        console.log(1111111111,row)
        this.sampleVisible = false;
      },
      handleChangeTask(row){
        console.log(222222222,row)
        this.taskVisible = false;
      }
        }
    }
</script>