Files
2026-09-20 15:46:34 +08:00

153 lines
5.5 KiB
Vue

<template>
<div style="padding-bottom: 20px;">
<van-form readonly input-align="right">
<div class="van-cell-group__title">
<div class="van-sidebar-item van-sidebar-item--select">
申请信息
</div>
</div>
<van-cell-group >
<van-field readonly :value="viewData.manager_name" label="申请人" ></van-field>
<van-field readonly :value="viewData.apply_time" label="申请时间" ></van-field>
<van-field readonly :value="viewData.be_username" label="慰问对象" ></van-field>
<van-field readonly name="type" :value="viewData.typename" label="慰问类型" ></van-field>
<van-field readonly name="way" :value="viewData.way" label="慰问方式" ></van-field>
<van-field readonly :value="viewData.money" type="number" label="慰问金额" ></van-field>
<van-field readonly :value="viewData.apply_time" type="number" label="申请时间" ></van-field>
<van-field readonly :value="viewData.hospital_stay" type="number" label="住院时间"
v-if="viewData.starting_time"></van-field>
<van-field readonly :value="viewData.the_hospital" type="number" label="所在医院"
v-if="viewData.starting_time"></van-field>
<van-field readonly :value="viewData.occur_time" type="number" label="慰问时间" ></van-field>
<van-field readonly :value="viewData.remark" label="申请事由"
input-align="left"
style="flex-flow: column"
rows="2" maxlength="200" type="textarea" show-word-limit autosize></van-field>
<van-field label="附件" style="flex-flow: column" input-align="left">
<template #label>
<div class="mb10">附&emsp;&emsp;件</div>
</template>
<template #input>
<vant-file-upload :files.sync="viewData.files" view :del="false"
v-if="viewData.files&&viewData.files.length"></vant-file-upload>
<span v-else>暂无</span>
</template>
</van-field>
<van-field name="sign" label="签字">
<template #input>
<van-image width="200" height="100" :src="viewData.manager_sign" v-if="viewData.manager_sign"/>
<span v-else>暂无</span>
</template>
</van-field>
</van-cell-group>
</van-form>
<template v-if="viewData.ucr">
<div class="van-cell-group__title">
<div class="van-sidebar-item van-sidebar-item--select">
分工会审核信息
</div>
</div>
<van-cell-group class="mt20">
<div style="padding-left: 16px">
<van-field label="审&ensp;核&ensp;人" :value="viewData.ucr.username" left-icon="contact" readonly></van-field>
<van-field label="审核时间" :value="viewData.ucr.time" left-icon="clock-o"
readonly></van-field>
<van-field label="审核意见" left-icon="chat-o" :value="viewData.ucr.opinion ? viewData.ucr.opinion : '暂无'"
readonly></van-field>
<van-field name="sign" label="签字">
<template #input>
<van-image width="200" height="100" :src="viewData.ucr.sign" v-if="viewData.ucr.sign"/>
<span v-else>暂无</span>
</template>
</van-field>
</div>
</van-cell-group>
</template>
<template v-if="viewData.vcr">
<div class="van-cell-group__title">
<div class="van-sidebar-item van-sidebar-item--select">
校工会审核信息
</div>
</div>
<van-cell-group class="mt20">
<div style="padding-left: 16px">
<van-field label="审&ensp;核&ensp;人" :value="viewData.vcr.username" left-icon="contact" readonly></van-field>
<van-field label="审核时间" :value="viewData.vcr.time" left-icon="clock-o"
readonly></van-field>
<van-field label="审核意见" left-icon="chat-o" :value="viewData.vcr.opinion ? viewData.vcr.opinion : '暂无'"
readonly></van-field>
<van-field name="sign" label="签字">
<template #input>
<van-image width="200" height="100" :src="viewData.vcr.sign" v-if="viewData.vcr.sign"/>
<span v-else>暂无</span>
</template>
</van-field>
</div>
</van-cell-group>
</template>
<template v-if="handle">
<slot name="handle"></slot>
</template>
</div>
</template>
<script>
module.exports = {
props: {
handle: {
type: Boolean,
default: false,
},
title: {
type: String,
default: '审核'
},
id: {
type: String,
default: ''
},
},
data() {
return {
viewData: {},
}
},
components: {
'vant-file-upload': httpVueLoader('/components/plugins/VantFileUpload.vue')
},
methods: {
async getInfo(id) {
const {data, code, msg} = await $.get("/platform/fw/condolence/findOne", {id})
if (data) {
condolence.toFormData(data)
this.viewData = data
this.viewData.hospital_stay = data.starting_time + "-" + data.end_time
} else {
this.viewData = {}
this.$toast.fail('获取信息失败');
}
},
},
async created() {
await this.getInfo(this.id)
}
}
</script>
<style>
.van-cell-group__title{
padding-left: 0!important;
}
.van-sidebar-item{
font-size: 16px!important;
text-indent: 4px!important;
}
.van-sidebar-item--select::before{
left: 5px!important;
}
</style>