安徽博创起重uniapp
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.
 
 
 
 

117 lines
2.5 KiB

<template>
<view>
<view class="news-details">
<view class="header">
<product-swiper :imgUrls="swiperList" ></product-swiper>
<view class="title xxl m-t-20">{{ articleDetail.name }}</view>
<view class="row-between">
<view class="flex" style="justify-content: space-between;">
<view class="xs lighter">公司名称{{ articleDetail.company }}</view>
<view class="flex">
<image class="icon-sm" src="/static/images/icon_see.png"></image>
<view class="m-l-10 xs muted">{{ articleDetail.visit }}人浏览</view>
</view>
</view>
<view class="xs lighter m-t-10">地区{{ articleDetail.address }}</view>
<view class="xs lighter m-t-10">联系方式{{ articleDetail.contact }}</view>
</view>
<!-- <view class="row-between">
</view> -->
<!-- <view class="flex row-between">
</view> -->
</view>
<view class="main">
简介{{ articleDetail.intro }}
<u-parse class='m-t-10' :html="article_content" />
</view>
<!-- <view class="main">
</view> -->
</view>
<loading-view v-if="showLoading"></loading-view>
</view>
</template>
<script>
import { getTeamOrganDetail } from '@/api/community.js';
export default {
data() {
return {
showLoading: true,
articleDetail: {},
article_content: "",
swiperList:[]
};
},
components: {
},
props: {},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.type = Number(options.type) || '';
this.id = options.id;
if (this.type) {
uni.setNavigationBarTitle({
title: '专家详情'
});
} else {
uni.setNavigationBarTitle({
title: '机构详情'
});
}
this.getArticleDetailFun();
},
methods: {
getArticleDetailFun() {
getTeamOrganDetail({
id: this.id
}).then(res => {
if (res.code == 1) {
this.articleDetail = res.data
this.swiperList = [{id: res.data.id,uri: res.data.image}];
setTimeout(() => {
this.article_content = res.data.content;
}, 200);
setTimeout(() => {
this.showLoading = false
}, 300);
}
});
}
}
};
</script>
<style lang="scss">
page {
background-color: #fff;
}
.news-details .header{
padding: 20rpx 15px;
border-bottom: $-solid-border;
}
.row-between{
padding: 20rpx 14rpx;
}
.news-details .main {
padding: 40rpx 15px;
}
</style>