yyt
2024-06-26 0cceb649e1dc443c2a91d26d81eacb0867c96db3
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
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
<template>
  <div class="app-container">
    <div style="height: 100%;width: 100%">
      <el-card class="box-card" >
        <el-form :model="queryParams.orderNo" ref="queryForm" :inline="true" >
          <el-form-item label="工单编号:" prop="orderNo" >
            <el-input
              style="width: 160px"
              v-model="queryParams.orderNo"
              placeholder="请输入工单编号"
              clearable
              @keyup.enter.native="handleQuery"
            />
          </el-form-item>
          <el-form-item style="margin-left: 1%">
            <el-button type="primary" icon="el-icon-refresh" @click="handleQuery">查询</el-button>
          </el-form-item>
          <el-form-item style="margin-left: 5%">
            <el-checkbox-group v-model="queryParams.isRepairFlag">
              <el-checkbox @change="cleanFlag" name="type"></el-checkbox>
            </el-checkbox-group>
          </el-form-item>
          <el-form-item  label="返修发动机号:" prop="repairEngineNo" >
 
            <el-input
              style="width: 160px"
              :disabled="!queryParams.isRepairFlag"
              v-model="queryParams.repairEngineNo"
              clearable
              @keyup.enter.native="handleQuery"
            />
          </el-form-item>
 
 
        </el-form>
      </el-card>
      <el-row :gutter="0">
        <el-col :span="20">
          <div style="height: 490px;">
            <el-card style="margin-top: 10px; height: 490px; width: 100%" class="box-card">
              <el-table border v-loading="loading" :data="dataList" height="460"
                        style="width: 100%" v-if="dataList.length > 0">
 
                <el-table-column :show-overflow-tooltip='true' label="工单编号"  align="center" prop="orderNo">
                </el-table-column>
                <el-table-column  :show-overflow-tooltip='true' label="产品小系列"  align="center" prop="model">
                </el-table-column>
                <el-table-column :show-overflow-tooltip='true' label="SN流水号"  align="center" prop="engineNo">
                </el-table-column>
                <el-table-column label="状态" width="80" align="center" prop="productionStatus">
                  <!--                <template slot-scope="scope">-->
                  <!--                  <span v-if="scope.row.productionStatus === '1'">是</span>-->
                  <!--                  <span v-if="scope.row.productionStatus === '0'">否</span>-->
                  <!--                </template>-->
                  <template slot-scope="scope">
                    <dict-tag :options="dict.type.order_scheduling_produce_status" :value="scope.row.productionStatus"/>
                  </template>
                </el-table-column>
                <el-table-column label="是否打印" width="80"  align="center" prop="whetherOrPrint">
 
                  <template slot-scope="scope">
                    <dict-tag :options="dict.type.print_status" :value="scope.row.whetherOrPrint"/>
                  </template>
 
                </el-table-column>
                <el-table-column label="打印时间" align="center" prop="null">
                </el-table-column>
              </el-table>
              <el-empty v-else>
                <span slot="description">暂无数据</span>
              </el-empty>
            </el-card>
          </div>
 
        </el-col>
        <el-col :span="4">
 
          <el-card style="margin-top: 10px; min-height: 490px" class="box-card">
            <div >
              <el-row class="centerImg" style="min-width: 80%;min-height: 90%">
                <vue-qr
                  v-if="qrCode !==''"
                  ref="qrCode"
                  :text="qrCode"
                  width="100%"
                  height="100%"
                ></vue-qr>
              </el-row>
              <el-row class="centerImg">
                <el-button type="success" style="margin-top: 80%; width: 100%">系统设置</el-button>
              </el-row>
 
 
 
            </div>
          </el-card>
        </el-col>
      </el-row>
    </div>
 
 
 
  </div>
</template>
 
<script>
import {listOrderScheduling2} from "@/api/main/bs/orderScheduling/orderScheduling";
import VueQr from 'vue-qr'
export default {
  name: "index",
  dicts: ['sys_normal_disable','order_scheduling_produce_status','print_status'],
  components: {
    VueQr,
  },
  data(){
    return{
      qrCode: '',
      // 查询参数
      queryParams: {
        orderNo: '',
        isRepairFlag: '',
        repairEngineNo: ''
      },
      dataList: []
    }
  },
  methods:{
    /** 搜索按钮操作 */
    handleQuery() {
      this.getList();
    },
    getList(){
      listOrderScheduling2(this.queryParams).then(response => {
        console.log("--------------------"+response.rows)
        this.dataList = response.rows
        if (this.queryParams.orderNo === '' || this.queryParams.orderNo === null){
          this.qrCode = ''
        }else {
          if (this.dataList.length > 0){
            this.qrCode = this.queryParams.orderNo
          }else {
            this.qrCode = ''
          }
        }
        console.log("qrcode",this.qrCode)
 
      });
    },
    filterTag(value, row) {
      return row.tag === value;
    },
    cleanFlag(){
      if (this.queryParams.isRepairFlag === false){
        this.queryParams.repairEngineNo = ''
      }
    },
    filterHandler(value, row, column) {
      const property = column['property'];
      return row[property] === value;
    },
 
  },
  mounted() {
    this.getList()
  }
}
</script>
 
<style scoped>
::v-deep .el-form-item__label{
  font-size: large;
}
::v-deep .el-card__body{
  padding: 15px 20px 0px 20px;
}
::v-deep .el-input .el-input--medium .el-input--suffix{
  width: 200px;
}
.centerImg{
  display: flex;
  justify-content: center;
  align-items: center;
}
</style>