惠企通
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

130 lines
3.2 KiB

<template>
<u-navbar :title="titleData.special_id_name ? '“' + titleData.special_id_name + '”' + '专题' : ''" placeholder="true"
bg-color="#F1F3F9" :auto-back="true"></u-navbar>
<view class="container" :style="{height: titleData.form?'calc(100vh - 350rpx)': 'calc(100vh - 150rpx)'}">
<view class="titlepart">
<image style="width: 8rpx; height: 1em" src="@/static/img/Fill1.png" mode=""></image>
<image style="width: 8rpx; height: 1em; margin-left: 6rpx" src="@/static/img/Fill2.png" mode=""></image>
<text class="title">{{ titleData.title }}</text>
</view>
<!-- <image style="width: 100%;height: 436rpx;margin-top: 48rpx;" src="@/static/img/Bitmap.png" mode=""></image> -->
<uvparse :content="titleData.content"></uvparse>
<!-- <rich-text class="richt" :nodes="titleData.content"></rich-text> -->
<view class="fbtime">{{ titleData.create_time }}</view>
</view>
<view class="baombut" v-if="titleData.form">
<view class="buttt" @click="gotij(titleData.id, titleData.form)">
立即报名
</view>
</view>
</template>
<script setup>
import {
onLoad
} from '@dcloudio/uni-app'
import {
ref
} from 'vue'
import {
specialListInfo,
bannerInfo
} from '@/api/index'
import uvparse from '@/uni_modules/uv-parse/components/uv-parse/uv-parse.vue'
const titleData = ref([])
const gotij = (id, item) => {
uni.navigateTo({
url: '/pages/index/subform?form=' + JSON.stringify(item) + '&id=' + id + '&type=' + 'zt'
})
}
onLoad(async (param) => {
if (param.type === 'zt') {
const res = await specialListInfo(param.id)
if (res.code === 1) {
titleData.value = res.data
}
} else {
const res = await bannerInfo(param.id)
if (res.code === 1) {
console.log(res)
titleData.value = res.data
}
}
titleData.value.content.replace(/<img/g,
'<img style="width: 100%; max-width: 100%; height: auto;"')
})
</script>
<style scoped lang="scss">
.container {
background-color: #ffffff;
height: calc(100vh - 350rpx);
width: 100%;
padding: 48rpx;
box-sizing: border-box;
overflow-y: auto;
.titlepart {
display: flex;
align-items: baseline;
margin-bottom: 40rpx;
.title {
font-family: Source Han Sans;
font-weight: 550;
font-size: 36rpx;
color: #0c092a;
margin-left: 20rpx;
}
}
.text {
margin-top: 32rpx;
font-family: Source Han Sans;
font-size: 32rpx;
font-weight: 300;
line-height: 60rpx;
letter-spacing: normal;
color: #3d3d3d;
}
.fbtime {
font-family: Roboto;
font-size: 28rpx;
font-weight: normal;
line-height: 142rpx;
letter-spacing: normal;
/* 外部/SCMP Grey/nobel */
/* 样式描述:06 Small Grey txt */
color: #a1a1a1;
}
}
.baombut {
width: 100%;
padding: 36rpx 0;
display: flex;
align-items: center;
justify-content: center;
box-shadow: 0rpx 0rpx 20rpx 0rpx rgba(0, 0, 0, 0.3);
background: #FFFFFF;
position: fixed;
bottom: 0;
.buttt {
width: 574rpx;
height: 96rpx;
border-radius: 248rpx;
background: linear-gradient(90deg, #007FFF 0%, #99CCFF 100%);
font-family: Source Han Sans;
font-size: 36rpx;
color: #FFFFFF;
display: flex;
align-items: center;
justify-content: center;
}
}
</style>