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
| <template>
| <view>
| <uni-card v-for="item in inspections" @click="gotoInfo(item)" class="card-box" >
| <u-row customStyle="margin-bottom: 10px">
| <u-col span="2">
| <label>点检计划单:</label>
| </u-col>
| <u-col span="4">
| <label>{{item.PLAN_NO}}</label>
| </u-col>
| </u-row>
| <u-row customStyle="margin-bottom: 10px">
| <u-col span="2">
| <label>计划点检时间:</label>
| </u-col>
| <u-col span="4">
| <label>{{item.PLAN_DATE}}</label>
| </u-col>
| </u-row>
| <u-row customStyle="margin-bottom: 10px">
| <u-col span="2">
| <label>点检设备:</label>
| </u-col>
| <u-col>
| <label>{{item.EQ_NO}} - - - {{item.EQ_NAME}}</label>
| </u-col>
| </u-row>
| <u-row customStyle="margin-bottom: 10px">
| <u-col span="2">
| <label>设备型号:</label>
| </u-col>
| <u-col>
| <label>{{item.EQ_MODEL}}</label>
| </u-col>
| </u-row>
| <u-row customStyle="margin-bottom: 10px">
| <u-col span="2">
| <label>放置地点:</label>
| </u-col>
| <u-col>
| <label>{{item.DEPARTMENT}} - - - {{item.PLACE}}</label>
| </u-col>
| </u-row>
| <u-row>
| <u-col span="2">
| <label>点检方案:</label>
| </u-col>
| <u-col span="4">
| <label>{{item.WAYS}}</label>
| </u-col>
| </u-row>
|
| </uni-card>
| <u-toast ref="uToast" />
| </view>
| </template>
| <script>
| import {
| getEqSpotCheckItem,
| } from '../../api/spotCheck'
|
| export default {
| data() {
| return {
| inspections: [],
| moduleKey:0
| }
| },
| onLoad() {
| this.getEqSpotCheck()
| },
| onPullDownRefresh() {
| this.getEqSpotCheck()
| setTimeout(function () {
| uni.stopPullDownRefresh();
| }, 1000);
| },
| //onShow:function(){
| // this.getInspections()
| //},
| methods: {
| getEqSpotCheck() {
| getEqSpotCheckItem().then(res => {
| console.log(res)
| if(!res.result) {
| this.$refs.uToast.show({
| message: res.msg,
| type: 'error'
| })
| return
| }
| this.inspections = res.data
| })
| },
| gotoInfo(e) {
| console.log(e)
| uni.navigateTo({
| url:'/pages/eqSpotCheck/eqSpotCheckInfo?item='+ encodeURIComponent(JSON.stringify(e).replace(/\%/g, '%25').replace(/\ /g,'%20').replace(/\?/g,'%3F').replace(/\+/g,'%2B').replace(/\&/g,'%26')) ,
| })
| },
| reload(){
| this.$nextTick(()=>{
| this.$refs.uToast.show({
| message: "提交成功",
| type: 'success'
| })
| this.getEqSpotCheck()
| })
| },
|
| }
| }
| </script>
|
| <style>
|
| </style>
|
|