| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677 |
- <template>
- <view class="page flex-col" :style="{'height':height}">
- <!-- #ifdef H5-->
- <uni-nav-bar v-if="!$isWxBrowser()" :fixed="true" background-color="#FFE05C" :border="false" :statusBar="false" left-icon="left" :title="title" @clickLeft="back" />
- <!-- #endif -->
- <scroll-view scroll-y="true" class="scroll-y ">
- <view class="content-box flex-col">
- <!-- <web-view src="http://www.gzqcdj.cn/doc/2.html"></web-view>-->
- <rich-text v-html="name">
- </rich-text>
- </view>
- </scroll-view>
- <!--#ifdef H5-->
- <liu-drag-button v-if="$isWxBrowser()" @clickBtn="back">返回</liu-drag-button>
- <!--#endif-->
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- name: '',
- height: '',
- type:'',
- title:''
- };
- },
- mounted() {
- },
- onLoad(option) {
- this.title = option.name;
- let sysInfo = uni.getSystemInfoSync();
- this.height = sysInfo.windowHeight + 'px';
- console.log("获取到的高度", this.height)
- uni.setNavigationBarTitle({
- title: this.title
- })
- this.type = option.type
- this.aboutByType(this.type)
- },
- methods: {
- back() {
- let pages = getCurrentPages()
- if (pages.length > 1){
- uni.navigateBack({
- delta: 1,
- fail:err=>{
- console.log(err)
- }
- })
- }else {
- uni.switchTab({
- url: '/pages/my/my'
- });
- }
- },
- aboutByType(type) {
- this.$api.service.aboutByType({type:type}).then(res => {
- this.name = res.data.data.aboutContent
- })
- }
- }
- };
- </script>
- <style lang="scss">
- @import './index.rpx.css';
- </style>
|