独墅湖高教创新区危化品智慧管控平台(新危化品)
zhouwx
2025-04-17 a8593f5ca77a934b31bbdd3b919d8e41796cb920
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
<template>
  <div class="query">
    <div style="margin-top:20px;margin-left: 20px">
      <el-form :inline="true" style="display: flex;align-items: center;flex-wrap: wrap;" >
        <el-form-item label="二维码编号:" >
          <el-input v-model="data.form.code" placeholder="请输入二维码编号进行搜索"></el-input>
        </el-form-item>
        <el-form-item >
          <el-button
              type="primary"
              @click="getList"
          >查询</el-button>
          <el-button
              @click="reset"
          >重置</el-button>
        </el-form-item>
 
      </el-form>
      <div style="display: flex;justify-content: center;margin-top: 20px">
        <el-card :style="{ height: '650px' ,overflow: 'auto'}">
          <div  class="content">
            <flow-deail ref="flowRef" v-if="data.showData"></flow-deail>
            <el-empty description="暂无数据" style="margin-top: 10%" v-else></el-empty>
          </div>
        </el-card>
      </div>
    </div>
  </div>
 
</template>
<script setup>
import {nextTick, reactive, ref} from "vue";
import flowDeail from '../../components/flowDetail.vue'
import {getFlowByCode, getProFlow} from "@/api/hazardousChemicals/productRecord";
import {ElMessage} from "element-plus";
 
const flowRef = ref();
const data = reactive({
  queryParams: {
    name: '',
    productSn: ''
  },
  form: {
    code: ''
  },
  dataList: [],
  showData:false
});
const getList = async () => {
  if(data.form.code!=''){
    data.showData = true
    await nextTick(() => {
      flowRef.value.openDialog('code',data.form.code)
    })
  }else {
    ElMessage.warning('请先输入二维码编号')
  }
 
 
 
}
const reset = () =>{
  data.form.code = ''
  data.showData = false
}
</script>
 
<style scoped lang="scss">
.query{
  .content{
    width: 650px;
    //height: 650px;
    //border: 1px solid #c2bfbf;
 
  }
}
</style>