<template>
|
<view class="safety_index">
|
<view class="safety_index_info"></view>
|
<view
|
v-for="item in checkDataList"
|
:key="item.examId"
|
class="check_item">
|
<view class="check_item_li">
|
<u-image
|
width="35px"
|
height="35px"
|
src="https://pipe.thhy-tj.com/group1/M00/00/01/bx5d1GSiWhCAEXQ6AAAHEMPF2H4526.png">
|
</u-image>
|
</view>
|
<view class="check_item_li">
|
<text>{{item.examName}}</text>
|
<text class="time_value">考核日期:{{item.examDate}}</text>
|
</view>
|
<view class="check_item_li">
|
<view class="check_item_button" @click="navigetTo(item)">
|
考核记录
|
</view>
|
</view>
|
</view>
|
</view>
|
</template>
|
|
<script>
|
export default {
|
data() {
|
return {
|
pageNum: 1,
|
pageSize: 10,
|
checkDataList: []
|
}
|
},
|
onShow() {
|
this.searchData();
|
},
|
methods: {
|
// 获取考核信息
|
async getSafetyCheckList() {
|
const { data } = await this.$api.reboSystem.getSafetyCheckList({
|
pageNum: this.pageNum,
|
pageSize: this.pageSize
|
})
|
return data;
|
},
|
// 查询
|
searchData() {
|
this.getSafetyCheckList().then((data) => {
|
this.checkDataList = data.list;
|
})
|
},
|
// 去考核
|
navigetTo(item) {
|
console.log(item);
|
uni.navigateTo({
|
url: './checkRecord?data=' + JSON.stringify(item)
|
})
|
}
|
}
|
}
|
</script>
|
|
<style scoped lang="scss">
|
.safety_index {
|
padding: 10px 10px 0;
|
background: #DBDDDF;
|
height: calc(100vh - 10px);
|
overflow-y: auto;
|
|
.safety_index_info {
|
margin-bottom: 10px;
|
width: 100%;
|
height: 18%;
|
background: url('https://pipe.thhy-tj.com/group1/M00/00/04/bx5d1GR29yOAI0n4AAMYLFxtvVs706.png') no-repeat;
|
background-size: 100% 100%;
|
}
|
|
.check_item {
|
display: flex;
|
padding: 20px 15px;
|
margin: 10px 0;
|
background: #FFFFFF;
|
border-radius: 5px;
|
|
.check_item_li {
|
display: flex;
|
align-items: center;
|
|
&:nth-child(2) {
|
flex: 2;
|
flex-direction: column;
|
align-items: flex-start;
|
margin: 0 10px;
|
font-size: 18px;
|
}
|
|
.time_value {
|
margin-top: 5px;
|
color: #9F9F9F;
|
font-size: 14px;
|
}
|
|
.check_item_button {
|
display: flex;
|
align-items: center;
|
justify-content: center;
|
padding: 6px 12px;
|
color: #FFFFFF;
|
font-size: 12px;
|
background: url('https://pipe.thhy-tj.com/group1/M00/00/04/bx5d1GR38HuAX1LDAAACuUYd2z4415.png') no-repeat;
|
background-size: 100% 100%;
|
|
&:active {
|
opacity: .8;
|
}
|
}
|
}
|
}
|
}
|
</style>
|