171 lines
3.5 KiB
Vue
171 lines
3.5 KiB
Vue
<template>
|
|
<view class="detail-container">
|
|
<uni-section title="保养基本信息" type="line">
|
|
<view style="background: white;padding: 0px 20px 20px 20px;">
|
|
<u--form labelPosition="left" :model="equipCanceInfo" label-width="100px">
|
|
<u-form-item label="报废单号:" prop="" borderBottom>
|
|
{{equipCanceInfo.scrappingRecordNum}}
|
|
</u-form-item>
|
|
<u-form-item label="报废设备:" prop="" borderBottom>
|
|
{{equipCanceInfo.equipName}}
|
|
</u-form-item>
|
|
<u-form-item label="报废时间:" prop="" borderBottom>
|
|
{{equipCanceInfo.scrappingTime}}
|
|
</u-form-item>
|
|
<u-form-item label="报废记录人:" prop="" borderBottom>
|
|
{{equipCanceInfo.creatorName}}
|
|
</u-form-item>
|
|
<u-form-item label="报废处理人:" prop="" borderBottom>
|
|
{{equipCanceInfo.handlerName}}
|
|
</u-form-item>
|
|
<u-form-item label="报废原因:" prop="" borderBottom>
|
|
{{equipCanceInfo.scrappingReason}}
|
|
</u-form-item>
|
|
<u-form-item label="报废处理方式:" prop="" borderBottom>
|
|
{{equipCanceInfo.scrappingTreatment}}
|
|
</u-form-item>
|
|
<u-form-item label="备注:" prop="" borderBottom>
|
|
{{equipCanceInfo.remark}}
|
|
</u-form-item>
|
|
<u-form-item label="照片:" prop="" borderBottom>
|
|
<u--image :showLoading="true" :src="equipCanceInfo.equipPicPath" width="80px" height="80px"
|
|
@click="lookImage(equipCanceInfo.equipPicPath)"></u--image>
|
|
</u-form-item>
|
|
</u--form>
|
|
</view>
|
|
</uni-section>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
|
|
import {
|
|
getEquipCancelById
|
|
} from "@/api/equipCancel/equipCancel.js"
|
|
|
|
import config from '@/config'
|
|
const baseUrl = config.baseUrl
|
|
|
|
export default {
|
|
data() {
|
|
return {
|
|
id: null,
|
|
equipCanceInfo:{},
|
|
}
|
|
},
|
|
onLoad(opts) {
|
|
this.id = opts.id;
|
|
},
|
|
created() {
|
|
this.getEquipCanceInfo();
|
|
},
|
|
methods: {
|
|
lookImage(url) {
|
|
// 预览图片
|
|
let urls = [];
|
|
urls.push(url)
|
|
uni.previewImage({
|
|
urls: urls
|
|
});
|
|
},
|
|
getEquipCanceInfo() {
|
|
getEquipCancelById(this.id).then((res) => {
|
|
this.equipCanceInfo = res.data
|
|
let equipPicPath = this.equipCanceInfo.equipPicPath;
|
|
if (equipPicPath != null && equipPicPath != '') {
|
|
this.equipCanceInfo.equipPicPath = baseUrl + equipPicPath;
|
|
}
|
|
})
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style>
|
|
/* #ifndef APP-NVUE */
|
|
page {
|
|
display: flex;
|
|
flex-direction: column;
|
|
box-sizing: border-box;
|
|
background-color: #fff;
|
|
min-height: 100%;
|
|
height: auto;
|
|
}
|
|
|
|
view {
|
|
font-size: 14px;
|
|
line-height: inherit;
|
|
}
|
|
|
|
/* #endif */
|
|
|
|
.text {
|
|
text-align: center;
|
|
font-size: 26rpx;
|
|
margin-top: 10rpx;
|
|
}
|
|
|
|
.grid-item-box {
|
|
flex: 1;
|
|
/* #ifndef APP-NVUE */
|
|
display: flex;
|
|
/* #endif */
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 15px 0;
|
|
}
|
|
|
|
.uni-margin-wrap {
|
|
width: 690rpx;
|
|
width: 100%;
|
|
;
|
|
}
|
|
|
|
.swiper {
|
|
height: 300rpx;
|
|
}
|
|
|
|
.swiper-box {
|
|
height: 150px;
|
|
}
|
|
|
|
.swiper-item {
|
|
/* #ifndef APP-NVUE */
|
|
display: flex;
|
|
/* #endif */
|
|
flex-direction: column;
|
|
justify-content: center;
|
|
align-items: center;
|
|
color: #fff;
|
|
height: 300rpx;
|
|
line-height: 300rpx;
|
|
}
|
|
|
|
@media screen and (min-width: 500px) {
|
|
.uni-swiper-dot-box {
|
|
width: 400px;
|
|
/* #ifndef APP-NVUE */
|
|
margin: 0 auto;
|
|
/* #endif */
|
|
margin-top: 8px;
|
|
}
|
|
|
|
.image {
|
|
width: 100%;
|
|
}
|
|
}
|
|
|
|
.detail-container {
|
|
padding: 12px;
|
|
background: #f1f1f1;
|
|
|
|
//设置按钮的样式,靠右
|
|
.worker-button {
|
|
float: right;
|
|
/* margin-right: 24px; */
|
|
margin-top: 10px;
|
|
}
|
|
}
|
|
</style>
|