132 lines
3.9 KiB
Vue
132 lines
3.9 KiB
Vue
<template>
|
|
<el-dialog
|
|
title="自营询价详情"
|
|
:visible.sync="dialogVisible"
|
|
width="60%"
|
|
:before-close="handleClose">
|
|
|
|
<el-descriptions border size="small" :column="2">
|
|
<el-descriptions-item label="询价区域">
|
|
<span>{{ info.province.name }}{{ info.city.name }} </span>
|
|
</el-descriptions-item>
|
|
<el-descriptions-item label="联系人">
|
|
<span>{{ info.name }}</span>
|
|
</el-descriptions-item>
|
|
<el-descriptions-item label="联系方式">
|
|
<span>{{ info.phone }}</span>
|
|
</el-descriptions-item>
|
|
<el-descriptions-item label="用户名称">
|
|
<span>{{ info.company }}</span>
|
|
</el-descriptions-item>
|
|
<el-descriptions-item label="询价单附件">
|
|
<view class="mt-15 mr-15" v-for="(file, fileIndex) in info.files" :key="fileIndex">
|
|
<file-type :item="file" @click.native="openDownload(file)"/>
|
|
</view>
|
|
</el-descriptions-item>
|
|
<template v-if="info.quoteList && info.status === 1">
|
|
<el-descriptions-item label="报价列表">
|
|
<div class="py-20 border-bottom" v-for="(item, index) in info.quoteList" :key="index">
|
|
<p>公司:{{ item.user.company.companyName }}</p>
|
|
<template v-if="item.amount">
|
|
<p>报价:¥{{ item.amount }}</p>
|
|
<span v-if="item.remark">备注:{{ item.remark }}</span>
|
|
<view class="mt-15 mr-15" v-for="(file, fileIndex) in item.files" :key="fileIndex">
|
|
<file-type :item="file" @click.native="openDownload(file)"/>
|
|
</view>
|
|
</template>
|
|
<p v-else>未报价</p>
|
|
</div>
|
|
</el-descriptions-item>
|
|
</template>
|
|
<template v-if="info.quoteList && info.status === 2">
|
|
<el-descriptions-item label="报价公司">
|
|
<div class="py-20 border-bottom" v-for="(item, index) in info.quoteList.filter(q => q.status === 1)"
|
|
:key="index">
|
|
<p>{{ item.user.company.companyName }}</p>
|
|
</div>
|
|
</el-descriptions-item>
|
|
</template>
|
|
<template v-if="info.quote">
|
|
<el-descriptions-item label="报价">
|
|
<span>¥{{ info.quote.amount }}</span>
|
|
</el-descriptions-item>
|
|
<el-descriptions-item label="备注">
|
|
<span>{{ info.quote.remark }}</span>
|
|
</el-descriptions-item>
|
|
<el-descriptions-item label="报价单附件">
|
|
<view class="mt-15 mr-15" v-for="(file, fileIndex) in info.quote.files" :key="fileIndex">
|
|
<file-type :item="file" @click.native="openDownload(file)"/>
|
|
</view>
|
|
</el-descriptions-item>
|
|
</template>
|
|
</el-descriptions>
|
|
</el-dialog>
|
|
</template>
|
|
|
|
<script>
|
|
import provinces from "@/uni_modules/vk-uview-ui/libs/address/provinces.json";
|
|
import citys from "@/uni_modules/vk-uview-ui/libs/address/citys.json";
|
|
import areas from "@/uni_modules/vk-uview-ui/libs/address/areas.json";
|
|
import FileType from "../../../components/file-type/file-type.vue";
|
|
|
|
export default {
|
|
name: "selfSupportModal",
|
|
components: {FileType},
|
|
data() {
|
|
return {
|
|
provinceData: provinces,
|
|
cityData: citys,
|
|
areaData: areas,
|
|
id: null,
|
|
info: null,
|
|
dialogVisible: false,
|
|
quoteList: [],
|
|
status: 0,
|
|
quote: null,
|
|
}
|
|
},
|
|
methods: {
|
|
open(info) {
|
|
this.info = info
|
|
this.dialogVisible = true
|
|
},
|
|
handleClose() {
|
|
this.dialogVisible = false
|
|
},
|
|
openDownload(url) {
|
|
window.open(url)
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
.request-header {
|
|
border: 1px solid #EDEDED;
|
|
background-color: #FFF8F1;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 15px;
|
|
margin-top: 30px;
|
|
|
|
text {
|
|
text-align: center;
|
|
}
|
|
}
|
|
|
|
.quote {
|
|
border-left: 1px solid #EDEDED;
|
|
border-right: 1px solid #EDEDED;
|
|
border-bottom: 1px solid #EDEDED;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 15px;
|
|
|
|
text {
|
|
text-align: center;
|
|
}
|
|
}
|
|
</style> |