提交
This commit is contained in:
parent
1745b5bb5f
commit
9c01660ceb
8
.idea/.gitignore
generated
vendored
Normal file
8
.idea/.gitignore
generated
vendored
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
# 默认忽略的文件
|
||||||
|
/shelf/
|
||||||
|
/workspace.xml
|
||||||
|
# 基于编辑器的 HTTP 客户端请求
|
||||||
|
/httpRequests/
|
||||||
|
# Datasource local storage ignored files
|
||||||
|
/dataSources/
|
||||||
|
/dataSources.local.xml
|
10
.idea/AugmentWebviewStateStore.xml
generated
Normal file
10
.idea/AugmentWebviewStateStore.xml
generated
Normal file
File diff suppressed because one or more lines are too long
8
.idea/modules.xml
generated
Normal file
8
.idea/modules.xml
generated
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectModuleManager">
|
||||||
|
<modules>
|
||||||
|
<module fileurl="file://$PROJECT_DIR$/.idea/国职.iml" filepath="$PROJECT_DIR$/.idea/国职.iml" />
|
||||||
|
</modules>
|
||||||
|
</component>
|
||||||
|
</project>
|
6
.idea/vcs.xml
generated
Normal file
6
.idea/vcs.xml
generated
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="VcsDirectoryMappings">
|
||||||
|
<mapping directory="" vcs="Git" />
|
||||||
|
</component>
|
||||||
|
</project>
|
12
.idea/国职.iml
generated
Normal file
12
.idea/国职.iml
generated
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<module type="WEB_MODULE" version="4">
|
||||||
|
<component name="NewModuleRootManager">
|
||||||
|
<content url="file://$MODULE_DIR$">
|
||||||
|
<excludeFolder url="file://$MODULE_DIR$/.tmp" />
|
||||||
|
<excludeFolder url="file://$MODULE_DIR$/temp" />
|
||||||
|
<excludeFolder url="file://$MODULE_DIR$/tmp" />
|
||||||
|
</content>
|
||||||
|
<orderEntry type="inheritedJdk" />
|
||||||
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
</component>
|
||||||
|
</module>
|
@ -62,4 +62,11 @@ module.exports = {
|
|||||||
userViedoFind(handler, data = {}) {
|
userViedoFind(handler, data = {}) {
|
||||||
return utils.http(handler, 'viedo/jilufind', data)
|
return utils.http(handler, 'viedo/jilufind', data)
|
||||||
},
|
},
|
||||||
|
/**
|
||||||
|
* 查询是否是会员
|
||||||
|
* @returns {Promise<*>}
|
||||||
|
*/
|
||||||
|
ifUserMember(handler, data = {}) {
|
||||||
|
return utils.http(handler, 'viedo/ifUserMember', data)
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
@ -241,14 +241,14 @@ module.exports = {
|
|||||||
// 过滤掉一些接口code为0的报错不提示,默认所有接口code为0时提示报错
|
// 过滤掉一些接口code为0的报错不提示,默认所有接口code为0时提示报错
|
||||||
// 不需要报错提示,自行到isShowTip方法里面的filterList数组添加不需要提示的接口名
|
// 不需要报错提示,自行到isShowTip方法里面的filterList数组添加不需要提示的接口名
|
||||||
let isShowTip = this.isShowTip(path)
|
let isShowTip = this.isShowTip(path)
|
||||||
if(res.data.code == 0){
|
// if(res.data.code == 0){
|
||||||
if(isShowTip){
|
// if(isShowTip){
|
||||||
uni.showToast({
|
// uni.showToast({
|
||||||
title: res.data.msg,
|
// title: res.data.msg,
|
||||||
icon: 'none'
|
// icon: 'none'
|
||||||
})
|
// })
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
resolve(res.data)
|
resolve(res.data)
|
||||||
} else {
|
} else {
|
||||||
console.log('http statusCode', res.statusCode)
|
console.log('http statusCode', res.statusCode)
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -25,15 +25,15 @@
|
|||||||
class="tn-color-wallpaper tn-text-xl tn-text-bold">{{ userInfo.nickname }}</text>
|
class="tn-color-wallpaper tn-text-xl tn-text-bold">{{ userInfo.nickname }}</text>
|
||||||
<text class=" tn-round tn-text-xs tn-bg-red tn-color-white tn-margin-left-sm"
|
<text class=" tn-round tn-text-xs tn-bg-red tn-color-white tn-margin-left-sm"
|
||||||
style="padding: 10rpx 20rpx;"
|
style="padding: 10rpx 20rpx;"
|
||||||
v-if="userInfo.info && userInfo.info.type_text">{{userInfo.info.type_text}}</text>
|
v-if="userInfo.info">{{userInfo.info.status==1?'平台会员':'普通用户'}}</text>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
<view
|
<!-- <view
|
||||||
class="tn-padding-right tn-padding-top-xs tn-padding-left-sm tn-text-ellipsis tn-text-sm"
|
class="tn-padding-right tn-padding-top-xs tn-padding-left-sm tn-text-ellipsis tn-text-sm"
|
||||||
@click="goTo('/pages/score/score-log')">
|
@click="goTo('/pages/score/score-log')">
|
||||||
<text class="tn-color-gray">积分: {{userInfo ? userInfo.info.score : 0}}分</text>
|
<text class="tn-color-gray">积分: {{userInfo ? userInfo.info.score : 0}}分</text>
|
||||||
<text class="tn-color-blue--disabled tn-padding-left-xs tn-icon-share-square"></text>
|
<text class="tn-color-blue--disabled tn-padding-left-xs tn-icon-share-square"></text>
|
||||||
</view>
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
@ -55,7 +55,7 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="tn-margin-top-xl">
|
<!-- <view class="tn-margin-top-xl">
|
||||||
<view class="button-number tn-flex tn-flex-row-between tn-flex-col-center tn-shadow-blur"
|
<view class="button-number tn-flex tn-flex-row-between tn-flex-col-center tn-shadow-blur"
|
||||||
style="background: linear-gradient(-120deg, #3E445A, #31374A, #2B3042, #262B3C);">
|
style="background: linear-gradient(-120deg, #3E445A, #31374A, #2B3042, #262B3C);">
|
||||||
|
|
||||||
@ -69,7 +69,6 @@
|
|||||||
<view class="tn-margin-right">
|
<view class="tn-margin-right">
|
||||||
<tn-button shape="round" backgroundColor="#F1C68E" fontColor="#634738" padding="10rpx 0"
|
<tn-button shape="round" backgroundColor="#F1C68E" fontColor="#634738" padding="10rpx 0"
|
||||||
width="160rpx" shadow @click="goTo('member-center')">
|
width="160rpx" shadow @click="goTo('member-center')">
|
||||||
<!-- <text class="tn-icon-vip tn-padding-right-sm tn-text-lg"></text> -->
|
|
||||||
<text class="tn-text-bold">权 益</text>
|
<text class="tn-text-bold">权 益</text>
|
||||||
</tn-button>
|
</tn-button>
|
||||||
</view>
|
</view>
|
||||||
@ -93,7 +92,7 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view> -->
|
||||||
|
|
||||||
|
|
||||||
<!-- 更多信息-->
|
<!-- 更多信息-->
|
||||||
@ -117,7 +116,7 @@
|
|||||||
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
<view
|
<view
|
||||||
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
||||||
<view class="tn-color-wallpaper tn-icon-close-circle"></view>
|
<view class="tn-color-wallpaper tn-icon-star"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="tn-text-center" style="font-size: 28rpx;">
|
<view class="tn-text-center" style="font-size: 28rpx;">
|
||||||
<text class="tn-text-ellipsis">题目收藏</text>
|
<text class="tn-text-ellipsis">题目收藏</text>
|
||||||
@ -125,7 +124,7 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/room/signup-index')">
|
<!-- <view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/room/signup-index')">
|
||||||
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
<view
|
<view
|
||||||
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
||||||
@ -136,8 +135,8 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
-->
|
||||||
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/room/grade')">
|
<!-- <view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/room/grade')">
|
||||||
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
<view
|
<view
|
||||||
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
||||||
@ -147,12 +146,34 @@
|
|||||||
<text class="tn-text-ellipsis">考场成绩</text>
|
<text class="tn-text-ellipsis">考场成绩</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
</view> -->
|
||||||
|
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/paper/grade')">
|
||||||
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
|
<view
|
||||||
|
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
||||||
|
<view class="tn-color-wallpaper tn-icon-order"></view>
|
||||||
|
</view>
|
||||||
|
<view class="tn-text-center" style="font-size: 28rpx;">
|
||||||
|
<text class="tn-text-ellipsis">考试成绩</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pagesSubject/video/user')">
|
||||||
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
|
<view
|
||||||
|
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
||||||
|
<view class="tn-color-wallpaper tn-icon-honor"></view>
|
||||||
|
</view>
|
||||||
|
<view class="tn-text-center" style="font-size: 28rpx;">
|
||||||
|
<text class="tn-text-ellipsis">学习记录</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 方式12 end-->
|
<!-- 方式12 end-->
|
||||||
|
|
||||||
<!-- 方式12 start-->
|
<!-- 方式12 start-->
|
||||||
<view class="tn-flex tn-flex-row-center tn-radius tn-padding-top">
|
<!-- <view class="tn-flex tn-flex-row-center tn-radius tn-padding-top">
|
||||||
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/paper/grade')">
|
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/paper/grade')">
|
||||||
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
<view
|
<view
|
||||||
@ -167,7 +188,7 @@
|
|||||||
|
|
||||||
<block v-if="userInfo">
|
<block v-if="userInfo">
|
||||||
|
|
||||||
<!-- <view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/cert/list')">
|
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pages/cert/list')">
|
||||||
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
<view
|
<view
|
||||||
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
||||||
@ -177,7 +198,7 @@
|
|||||||
<text class="tn-text-ellipsis">荣誉证书</text>
|
<text class="tn-text-ellipsis">荣誉证书</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view> -->
|
</view>
|
||||||
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pagesSubject/video/user')">
|
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pagesSubject/video/user')">
|
||||||
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
<view
|
<view
|
||||||
@ -185,7 +206,7 @@
|
|||||||
<view class="tn-color-wallpaper tn-icon-honor"></view>
|
<view class="tn-color-wallpaper tn-icon-honor"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="tn-text-center" style="font-size: 28rpx;">
|
<view class="tn-text-center" style="font-size: 28rpx;">
|
||||||
<text class="tn-text-ellipsis">我的上传</text>
|
<text class="tn-text-ellipsis">学习记录</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -196,12 +217,12 @@
|
|||||||
<view class="tn-color-wallpaper tn-icon-star"></view>
|
<view class="tn-color-wallpaper tn-icon-star"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="tn-text-center" style="font-size: 28rpx;">
|
<view class="tn-text-center" style="font-size: 28rpx;">
|
||||||
<text class="tn-text-ellipsis">常用分类</text>
|
<text class="tn-text-ellipsis">常用题库</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="tn-padding-sm tn-margin-xs tn-radius"
|
||||||
<view class="tn-padding-sm tn-margin-xs tn-radius" @click="goTo('/pagesSubject/index?type=onlySubject')">
|
@click="goTo('/pagesSubject/index?type=onlySubject')">
|
||||||
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
<view
|
<view
|
||||||
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
class="icon12__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-bg-blue--light">
|
||||||
@ -213,7 +234,7 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view> -->
|
||||||
<!-- 方式12 end-->
|
<!-- 方式12 end-->
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -296,7 +317,7 @@
|
|||||||
|
|
||||||
<!-- 更多信息 -->
|
<!-- 更多信息 -->
|
||||||
<view class="wallpaper-shadow tn-margin-top-lg tn-margin-bottom-lg tn-padding-top-sm tn-padding-bottom-sm">
|
<view class="wallpaper-shadow tn-margin-top-lg tn-margin-bottom-lg tn-padding-top-sm tn-padding-bottom-sm">
|
||||||
<tn-list-cell :hover="true" :unlined="true" :radius="true" :fontSize="30"
|
<!-- <tn-list-cell :hover="true" :unlined="true" :radius="true" :fontSize="30"
|
||||||
@click="goTo('member-protocol')">
|
@click="goTo('member-protocol')">
|
||||||
<view class="tn-flex tn-flex-col-center">
|
<view class="tn-flex tn-flex-col-center">
|
||||||
<view class="icon1__item--icon tn-flex tn-flex-row-center tn-flex-col-center"
|
<view class="icon1__item--icon tn-flex tn-flex-row-center tn-flex-col-center"
|
||||||
@ -308,9 +329,9 @@
|
|||||||
class="tn-margin-left-sm tn-color-wallpaper tn-text-sm tn-padding-left-xs tn-padding-right-xs tn-bg-gray--light tn-round">
|
class="tn-margin-left-sm tn-color-wallpaper tn-text-sm tn-padding-left-xs tn-padding-right-xs tn-bg-gray--light tn-round">
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</tn-list-cell>
|
</tn-list-cell> -->
|
||||||
|
|
||||||
<tn-list-cell :hover="true" :unlined="true" :radius="true" :fontSize="30" @click="clickFollow()"
|
<!-- <tn-list-cell :hover="true" :unlined="true" :radius="true" :fontSize="30" @click="clickFollow()"
|
||||||
v-show="showFollowBtn">
|
v-show="showFollowBtn">
|
||||||
<view class="tn-flex tn-flex-col-center">
|
<view class="tn-flex tn-flex-col-center">
|
||||||
<view class="icon1__item--icon tn-flex tn-flex-row-center tn-flex-col-center"
|
<view class="icon1__item--icon tn-flex tn-flex-row-center tn-flex-col-center"
|
||||||
@ -322,11 +343,10 @@
|
|||||||
class="tn-margin-left-sm tn-color-wallpaper tn-text-sm tn-padding-left-xs tn-padding-right-xs tn-bg-gray--light tn-round">
|
class="tn-margin-left-sm tn-color-wallpaper tn-text-sm tn-padding-left-xs tn-padding-right-xs tn-bg-gray--light tn-round">
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</tn-list-cell>
|
</tn-list-cell> -->
|
||||||
|
|
||||||
<!-- #ifdef MP-WEIXIN -->
|
|
||||||
<tn-list-cell :hover="true" :unlined="true" :radius="true" :fontSize="30">
|
<tn-list-cell :hover="true" :unlined="true" :radius="true" :fontSize="30">
|
||||||
<button class="tn-flex tn-flex-col-center tn-button--clear-style" open-type="contact">
|
<button class="tn-flex tn-flex-col-center tn-button--clear-style" @click="openPhone()">
|
||||||
<view class="icon1__item--icon tn-flex tn-flex-row-center tn-flex-col-center"
|
<view class="icon1__item--icon tn-flex tn-flex-row-center tn-flex-col-center"
|
||||||
style="color: #7C8191;">
|
style="color: #7C8191;">
|
||||||
<view class="tn-icon-service-fill"></view>
|
<view class="tn-icon-service-fill"></view>
|
||||||
@ -337,7 +357,6 @@
|
|||||||
</view>
|
</view>
|
||||||
</button>
|
</button>
|
||||||
</tn-list-cell>
|
</tn-list-cell>
|
||||||
<!-- #endif -->
|
|
||||||
|
|
||||||
<tn-list-cell :hover="true" :unlined="true" :radius="true" :fontSize="30" @click="clearStorage()">
|
<tn-list-cell :hover="true" :unlined="true" :radius="true" :fontSize="30" @click="clearStorage()">
|
||||||
<view class="tn-flex tn-flex-col-center">
|
<view class="tn-flex tn-flex-col-center">
|
||||||
@ -354,9 +373,8 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- #ifdef MP-WEIXIN -->
|
|
||||||
<!-- 友情链接 -->
|
<!-- 友情链接 -->
|
||||||
<view class="about-shadow tn-margin-top tn-margin-bottom-lg tn-padding-top-sm tn-padding-bottom-sm"
|
<!-- <view class="about-shadow tn-margin-top tn-margin-bottom-lg tn-padding-top-sm tn-padding-bottom-sm"
|
||||||
v-show="friendApps.length > 0">
|
v-show="friendApps.length > 0">
|
||||||
<view class="tn-flex tn-flex-row-between tn-padding">
|
<view class="tn-flex tn-flex-row-between tn-padding">
|
||||||
<view class="justify-content-item tn-text-bold tn-text-lg">
|
<view class="justify-content-item tn-text-bold tn-text-lg">
|
||||||
@ -365,13 +383,11 @@
|
|||||||
</view>
|
</view>
|
||||||
<tn-scroll-list :indicator="false">
|
<tn-scroll-list :indicator="false">
|
||||||
<view class="tn-flex tn-margin-left-sm tn-margin-right-sm tn-margin-top">
|
<view class="tn-flex tn-margin-left-sm tn-margin-right-sm tn-margin-top">
|
||||||
<navigator target="miniProgram" :app-id="item.wx_app_id" :path="item.path ? item.path : '/pages/index/index'" version="release"
|
<navigator target="miniProgram" :app-id="item.wx_app_id"
|
||||||
hover-class="none" v-for="(item, index) in friendApps" :key="index">
|
:path="item.path ? item.path : '/pages/index/index'" version="release" hover-class="none"
|
||||||
|
v-for="(item, index) in friendApps" :key="index">
|
||||||
<view class="tn-flex-1 tn-padding-sm tn-radius">
|
<view class="tn-flex-1 tn-padding-sm tn-radius">
|
||||||
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
<view class="tn-flex tn-flex-direction-column tn-flex-row-center tn-flex-col-center">
|
||||||
<!-- <view class="icon5__item--icon tn-flex tn-flex-row-center tn-flex-col-center tn-shadow-blur"
|
|
||||||
:style="'background-image:url('+ item.image + ');background-size:100% 100%;'">
|
|
||||||
</view> -->
|
|
||||||
<image :src="item.image" mode="scaleToFill" style="width: 150rpx; height: 150rpx;">
|
<image :src="item.image" mode="scaleToFill" style="width: 150rpx; height: 150rpx;">
|
||||||
</image>
|
</image>
|
||||||
<view class="tn-color-black tn-text-df tn-text-center tn-margin-top-sm">
|
<view class="tn-color-black tn-text-df tn-text-center tn-margin-top-sm">
|
||||||
@ -382,8 +398,7 @@
|
|||||||
</navigator>
|
</navigator>
|
||||||
</view>
|
</view>
|
||||||
</tn-scroll-list>
|
</tn-scroll-list>
|
||||||
</view>
|
</view> -->
|
||||||
<!-- #endif -->
|
|
||||||
|
|
||||||
|
|
||||||
<!-- 关注我们 -->
|
<!-- 关注我们 -->
|
||||||
@ -502,20 +517,17 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
openPhone(){
|
||||||
|
uni.makePhoneCall({
|
||||||
|
phoneNumber: '18903795988' //仅为示例
|
||||||
|
});
|
||||||
|
},
|
||||||
// 跳转
|
// 跳转
|
||||||
tn(e) {
|
tn(e) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: e,
|
url: e,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
// 跳转到图鸟UI
|
|
||||||
navTuniaoUI() {
|
|
||||||
uni.navigateToMiniProgram({
|
|
||||||
appId: 'wxf3d81a452b88ff4b'
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
// 收货地址
|
// 收货地址
|
||||||
navAddress() {
|
navAddress() {
|
||||||
uni.chooseAddress({})
|
uni.chooseAddress({})
|
||||||
@ -526,28 +538,6 @@
|
|||||||
wx.vibrateShort();
|
wx.vibrateShort();
|
||||||
},
|
},
|
||||||
|
|
||||||
//拨打固定电话
|
|
||||||
callPhoneNumber() {
|
|
||||||
uni.makePhoneCall({
|
|
||||||
phoneNumber: "18219128888",
|
|
||||||
});
|
|
||||||
},
|
|
||||||
// 复制id
|
|
||||||
copyUid() {
|
|
||||||
wx.vibrateShort();
|
|
||||||
uni.setClipboardData({
|
|
||||||
data: "10262008",
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 复制开源地址
|
|
||||||
copySource() {
|
|
||||||
wx.vibrateShort();
|
|
||||||
uni.setClipboardData({
|
|
||||||
data: "https://ext.dcloud.net.cn/publisher?id=356088",
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
|
|
||||||
login() {
|
login() {
|
||||||
this.$emit('login')
|
this.$emit('login')
|
||||||
},
|
},
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -130,6 +130,7 @@
|
|||||||
.btns {
|
.btns {
|
||||||
margin-top: 48rpx;
|
margin-top: 48rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btns .item {
|
.btns .item {
|
||||||
|
@ -115,14 +115,14 @@
|
|||||||
path: '/pages/paper/index',
|
path: '/pages/paper/index',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: '学习动态',
|
name: '关于我们',
|
||||||
icon: 'tn-icon-inventory',
|
icon: 'tn-icon-inventory',
|
||||||
path: '/pages/index/news-list',
|
path: '/pages/index/news-list',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: '考场列表',
|
name: '考试公示',
|
||||||
icon: 'tn-icon-menu-list',
|
icon: 'tn-icon-menu-list',
|
||||||
path: '/pages/room/index',
|
path: '/pages/index/notice-list',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: '我的',
|
name: '我的',
|
||||||
|
@ -503,7 +503,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.tui-header-item {
|
.tui-header-item {
|
||||||
max-width: 240rpx;
|
max-width: 350rpx;
|
||||||
padding: 15rpx 30rpx;
|
padding: 15rpx 30rpx;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
|
30
pages.json
30
pages.json
@ -9,13 +9,13 @@
|
|||||||
{
|
{
|
||||||
"path": "pages/index/index",
|
"path": "pages/index/index",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "答题考试",
|
"navigationBarTitleText": "名扬体育学苑",
|
||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/paper/index",
|
"path": "pages/paper/index",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "试卷列表",
|
"navigationBarTitleText": "模拟考试",
|
||||||
"enablePullDownRefresh": false,
|
"enablePullDownRefresh": false,
|
||||||
// 距离底部50px时,触发onReachBottom事件
|
// 距离底部50px时,触发onReachBottom事件
|
||||||
"onReachBottonDistance": 50
|
"onReachBottonDistance": 50
|
||||||
@ -26,7 +26,11 @@
|
|||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "考试试卷",
|
"navigationBarTitleText": "考试试卷",
|
||||||
"enablePullDownRefresh": false,
|
"enablePullDownRefresh": false,
|
||||||
"autoBackButton": false
|
"autoBackButton": false,
|
||||||
|
"navigationStyle": "custom",
|
||||||
|
"app-plus": {
|
||||||
|
"popGesture": "none"
|
||||||
|
}
|
||||||
// "navigationBarBackgroundColor": "#FFFFFF",
|
// "navigationBarBackgroundColor": "#FFFFFF",
|
||||||
// "navigationBarTextStyle": "black",
|
// "navigationBarTextStyle": "black",
|
||||||
// "titleNView": false,
|
// "titleNView": false,
|
||||||
@ -84,14 +88,14 @@
|
|||||||
}, {
|
}, {
|
||||||
"path": "pages/train/train",
|
"path": "pages/train/train",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "",
|
"navigationBarTitleText": "答题",
|
||||||
"enablePullDownRefresh": false
|
"enablePullDownRefresh": false
|
||||||
}
|
}
|
||||||
|
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/train/index",
|
"path": "pages/train/index",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "",
|
"navigationBarTitleText": "题目选择",
|
||||||
"enablePullDownRefresh": false
|
"enablePullDownRefresh": false
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -112,7 +116,7 @@
|
|||||||
}, {
|
}, {
|
||||||
"path": "pages/index/notice-list",
|
"path": "pages/index/notice-list",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "公告列表",
|
"navigationBarTitleText": "考试公示",
|
||||||
"enablePullDownRefresh": false,
|
"enablePullDownRefresh": false,
|
||||||
// 距离底部50px时,触发onReachBottom事件
|
// 距离底部50px时,触发onReachBottom事件
|
||||||
"onReachBottonDistance": 50
|
"onReachBottonDistance": 50
|
||||||
@ -123,13 +127,13 @@
|
|||||||
}, {
|
}, {
|
||||||
"path": "pages/index/notice-detail",
|
"path": "pages/index/notice-detail",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "",
|
"navigationBarTitleText": "详情",
|
||||||
"enablePullDownRefresh": false
|
"enablePullDownRefresh": false
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/index/news-list",
|
"path": "pages/index/news-list",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "学习动态列表",
|
"navigationBarTitleText": "关于我们",
|
||||||
"enablePullDownRefresh": false,
|
"enablePullDownRefresh": false,
|
||||||
// 距离底部50px时,触发onReachBottom事件
|
// 距离底部50px时,触发onReachBottom事件
|
||||||
"onReachBottonDistance": 50
|
"onReachBottonDistance": 50
|
||||||
@ -138,7 +142,7 @@
|
|||||||
}, {
|
}, {
|
||||||
"path": "pages/index/news-detail",
|
"path": "pages/index/news-detail",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "",
|
"navigationBarTitleText": "详情",
|
||||||
"enablePullDownRefresh": false
|
"enablePullDownRefresh": false
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
@ -219,13 +223,13 @@
|
|||||||
{
|
{
|
||||||
"path": "video/index",
|
"path": "video/index",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "视频教学"
|
"navigationBarTitleText": "课程中心"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"path": "video/list",
|
"path": "video/list",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "视频教学"
|
"navigationBarTitleText": "课程中心"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -237,7 +241,7 @@
|
|||||||
{
|
{
|
||||||
"path": "video/user",
|
"path": "video/user",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "我上传的"
|
"navigationBarTitleText": "学习记录"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -367,7 +371,7 @@
|
|||||||
},
|
},
|
||||||
// "navigationBarBackgroundColor": "#0081ff",
|
// "navigationBarBackgroundColor": "#0081ff",
|
||||||
|
|
||||||
"navigationBarTitleText": "在线考试",
|
"navigationBarTitleText": "名扬体育学院",
|
||||||
"navigationBarBackgroundColor": "#1A73E8",
|
"navigationBarBackgroundColor": "#1A73E8",
|
||||||
"navigationBarTextStyle": "white"
|
"navigationBarTextStyle": "white"
|
||||||
// #ifdef H5
|
// #ifdef H5
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<view>
|
<view>
|
||||||
<!-- 答题组件 -->
|
<!-- 答题组件 -->
|
||||||
<kz-question mode="TRAINING" title="收藏试题" :questions="list" v-show="!showNodata"></kz-question>
|
<kz-question mode="TRAINING" title="收藏试题" :questions="list" v-show="!showNodata" v-on:refresh="refresh"></kz-question>
|
||||||
|
|
||||||
<!-- 暂无数据 -->
|
<!-- 暂无数据 -->
|
||||||
<tui-no-data imgUrl="/static/img/img_noorder_3x.png" v-if="showNodata">暂无数据</tui-no-data>
|
<tui-no-data imgUrl="/static/img/img_noorder_3x.png" v-if="showNodata">暂无数据</tui-no-data>
|
||||||
@ -25,6 +25,11 @@
|
|||||||
this.ajax()
|
this.ajax()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
refresh(){
|
||||||
|
this.page = 1
|
||||||
|
this.list = []
|
||||||
|
this.ajax()
|
||||||
|
},
|
||||||
ajax() {
|
ajax() {
|
||||||
this.http('question/collectList', {page:this.page}, 'get').then(res => {
|
this.http('question/collectList', {page:this.page}, 'get').then(res => {
|
||||||
this.total = res.data.total;
|
this.total = res.data.total;
|
||||||
|
@ -56,7 +56,7 @@
|
|||||||
<!-- <kz-page-index-simple :banners="banners" v-if="pageStyle == 'simple'"></kz-page-index-simple> -->
|
<!-- <kz-page-index-simple :banners="banners" v-if="pageStyle == 'simple'"></kz-page-index-simple> -->
|
||||||
|
|
||||||
<!-- 悬浮组件 -->
|
<!-- 悬浮组件 -->
|
||||||
<tui-scroll-top
|
<!-- <tui-scroll-top
|
||||||
:scrollTop="scrollTop"
|
:scrollTop="scrollTop"
|
||||||
:isIndex="false"
|
:isIndex="false"
|
||||||
:isHideAd="showAdBtn"
|
:isHideAd="showAdBtn"
|
||||||
@ -68,7 +68,7 @@
|
|||||||
}
|
}
|
||||||
"
|
"
|
||||||
@goNotice="goNoticeList"
|
@goNotice="goNoticeList"
|
||||||
></tui-scroll-top>
|
></tui-scroll-top> -->
|
||||||
|
|
||||||
<!-- 流量主组件 -->
|
<!-- 流量主组件 -->
|
||||||
<!-- #ifdef MP-WEIXIN -->
|
<!-- #ifdef MP-WEIXIN -->
|
||||||
@ -103,8 +103,8 @@
|
|||||||
<!-- 底部导航栏组件 -->
|
<!-- 底部导航栏组件 -->
|
||||||
<tabbar :theme="tabbarStyle" :tabbar="tabbar"></tabbar>
|
<tabbar :theme="tabbarStyle" :tabbar="tabbar"></tabbar>
|
||||||
|
|
||||||
<view class="margin-bottom-xl">
|
<view style="padding-bottom: 300rpx;">
|
||||||
<tn-load-more class="tn-margin-top" status="nomore" dot></tn-load-more>
|
<tn-load-more class="tn-margin-top" :loadText="loadText" status="nomore"></tn-load-more>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
@ -123,6 +123,11 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
loadText: {
|
||||||
|
loadmore: '灵睿网络',
|
||||||
|
loading: '灵睿网络',
|
||||||
|
nomore: '灵睿网络'
|
||||||
|
},
|
||||||
focusOnTip: "点击「添加小程序」,下次访问更便捷",
|
focusOnTip: "点击「添加小程序」,下次访问更便捷",
|
||||||
imgUrl: this.imgUrl,
|
imgUrl: this.imgUrl,
|
||||||
banners: [],
|
banners: [],
|
||||||
@ -147,7 +152,7 @@ export default {
|
|||||||
userInfo: {},
|
userInfo: {},
|
||||||
subjectId: 0,
|
subjectId: 0,
|
||||||
subjectName: "请选择科目",
|
subjectName: "请选择科目",
|
||||||
title: "答题考试系统",
|
title: "名扬体育学苑",
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
onLoad(e) {
|
onLoad(e) {
|
||||||
@ -208,15 +213,15 @@ export default {
|
|||||||
|
|
||||||
// 积分提示
|
// 积分提示
|
||||||
let point = res.data.point;
|
let point = res.data.point;
|
||||||
if (point?.get_point) {
|
// if (point?.get_point) {
|
||||||
this.$refs.toast.show({
|
// this.$refs.toast.show({
|
||||||
title: "积分+" + point.get_point,
|
// title: "积分+" + point.get_point,
|
||||||
content: point.type,
|
// content: point.type,
|
||||||
imgUrl: "/static/toast/info-circle.png",
|
// imgUrl: "/static/toast/info-circle.png",
|
||||||
icon: true,
|
// icon: true,
|
||||||
duration: 4000,
|
// duration: 4000,
|
||||||
});
|
// });
|
||||||
}
|
// }
|
||||||
|
|
||||||
// 公告
|
// 公告
|
||||||
this.notices = res.data.notices;
|
this.notices = res.data.notices;
|
||||||
|
@ -1,43 +1,29 @@
|
|||||||
<!-- 新闻 详情 -->
|
<!-- 新闻 详情 -->
|
||||||
<template>
|
<template>
|
||||||
<view class="container">
|
<view class="container">
|
||||||
|
<view>
|
||||||
|
<view style="background-color: #FFFFFF;padding: 30rpx 30rpx 30rpx 30rpx;">
|
||||||
|
<view class="titleBox text-xl text-black text-bold">{{ newsData.name }}</view>
|
||||||
|
|
||||||
<!-- #ifdef H5 -->
|
<view class="flex justify-between text-df text-gray margin-top-sm margin-bottom-sm">
|
||||||
<!-- 顶部自定义导航 -->
|
<text>{{ newsData.create_time_text }}</text>
|
||||||
<tn-nav-bar fixed :bottomShadow="false" backTitle=" ">
|
<!-- <text>{{newsData.type | typeF}}</text> -->
|
||||||
<view class="">
|
</view>
|
||||||
<text class="tn-text-lg">学习动态</text>
|
<!-- <image mode="widthFix" :src="newsData.cover_image" @click="previewImage(0)"></image> -->
|
||||||
<text class="tn-text-xl tn-padding-left-sm tn-icon-group-circle"></text>
|
|
||||||
</view>
|
|
||||||
</tn-nav-bar>
|
|
||||||
<!-- #endif -->
|
|
||||||
|
|
||||||
<view>
|
<!-- 中间文章区域 -->
|
||||||
<view style="background-color: #FFFFFF;padding: 30rpx 30rpx 30rpx 30rpx;">
|
<view class="contentBox text-lg text-black margin-top-sm margin-tb-lg">
|
||||||
<view class="titleBox text-xl text-black text-bold">{{ newsData.name }}</view>
|
<mp-html :tag-style="tagStyle" :scroll-table="true" :content="newsData.contents" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
<view class="flex justify-between text-df text-gray margin-top-sm margin-bottom-sm">
|
<!-- <view class="cu-bar justify-left bg-white margin-top-sm">
|
||||||
<text>{{ newsData.create_time_text }}</text>
|
|
||||||
<!-- <text>{{newsData.type | typeF}}</text> -->
|
|
||||||
</view>
|
|
||||||
<!-- <image mode="widthFix" :src="newsData.cover_image" @click="previewImage(0)"></image> -->
|
|
||||||
|
|
||||||
<!-- 中间文章区域 -->
|
|
||||||
<view class="contentBox text-lg text-black margin-top-sm margin-tb-lg">
|
|
||||||
<view class="margin-top-sm" v-html="newsData.contents">
|
|
||||||
</view>
|
|
||||||
<!-- <view class="margin-top-sm" v-for="(item, index) in newsData.content.split('&')" v-html="item">
|
|
||||||
</view> -->
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<!-- <view class="cu-bar justify-left bg-white margin-top-sm">
|
|
||||||
<view class="action border-title">
|
<view class="action border-title">
|
||||||
<text class="text-lg text-bold text-blue">图片展示</text>
|
<text class="text-lg text-bold text-blue">图片展示</text>
|
||||||
<text class="bg-gradual-blue" style="width:3rem"></text>
|
<text class="bg-gradual-blue" style="width:3rem"></text>
|
||||||
</view>
|
</view>
|
||||||
</view> -->
|
</view> -->
|
||||||
<!-- <view style="background-color: #FFFFFF;padding: 0rpx 30rpx 30rpx 30rpx;">
|
<!-- <view style="background-color: #FFFFFF;padding: 0rpx 30rpx 30rpx 30rpx;">
|
||||||
|
|
||||||
<image @click="previewImage(index)" v-for="(item, index) in newsData.images" :key="index"
|
<image @click="previewImage(index)" v-for="(item, index) in newsData.images" :key="index"
|
||||||
mode="widthFix" :src="item"></image>
|
mode="widthFix" :src="item"></image>
|
||||||
@ -51,9 +37,9 @@
|
|||||||
<text class="text-df" style="margin-top: 2rpx;">{{newsData.commentNum}}</text>
|
<text class="text-df" style="margin-top: 2rpx;">{{newsData.commentNum}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view> -->
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="cu-bar bg-white tabbar border shop bottomBox">
|
<!-- <view class="cu-bar bg-white tabbar border shop bottomBox">
|
||||||
<view class="btn-group">
|
<view class="btn-group">
|
||||||
<tn-button shape="round" backgroundColor="#1A73E8" padding="30rpx 0" width="200rpx" shadow @click="handleBack()"
|
<tn-button shape="round" backgroundColor="#1A73E8" padding="30rpx 0" width="200rpx" shadow @click="handleBack()"
|
||||||
fontBold plain>
|
fontBold plain>
|
||||||
@ -65,86 +51,93 @@
|
|||||||
<text class="tn-color-white">点击前往</text>
|
<text class="tn-color-white">点击前往</text>
|
||||||
</tn-button>
|
</tn-button>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view> -->
|
||||||
<view class="safe-area-inset-bottom"></view>
|
<view class="safe-area-inset-bottom"></view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import newsApi from "@/common/api/news.js"
|
import newsApi from "@/common/api/news.js"
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
newsData: [],
|
newsData: [],
|
||||||
requestStatus: false // 事件防抖
|
requestStatus: false, // 事件防抖
|
||||||
}
|
tagStyle: {
|
||||||
},
|
table: 'border: 1px solid gray;border-collapse:collapse',
|
||||||
onLoad(option) {
|
th: 'border: 1px solid gray;',
|
||||||
console.log(option)
|
td: 'border: 1px solid gray;'
|
||||||
this.getData(option.id);
|
}
|
||||||
},
|
}
|
||||||
methods: {
|
},
|
||||||
// 获取数据
|
onLoad(option) {
|
||||||
getData(id) {
|
console.log(option)
|
||||||
console.log(id);
|
this.getData(option.id);
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
// 获取数据
|
||||||
|
getData(id) {
|
||||||
|
console.log(id);
|
||||||
|
|
||||||
newsApi.getNewsDetail(this, {id: id}).then(res => {
|
newsApi.getNewsDetail(this, {
|
||||||
if (res && res.data) {
|
id: id
|
||||||
this.newsData = res.data
|
}).then(res => {
|
||||||
}
|
if (res && res.data) {
|
||||||
})
|
this.newsData = res.data
|
||||||
},
|
}
|
||||||
handleBack() {
|
})
|
||||||
this.utils.goto('news-list')
|
},
|
||||||
},
|
handleBack() {
|
||||||
handleGo() {
|
this.utils.goto('news-list')
|
||||||
if (this.newsData && this.newsData.front_info) {
|
},
|
||||||
this.utils.goto(this.newsData.front_info.full_url)
|
handleGo() {
|
||||||
}
|
if (this.newsData && this.newsData.front_info) {
|
||||||
},
|
this.utils.goto(this.newsData.front_info.full_url)
|
||||||
previewImage(index) {
|
}
|
||||||
// 预览功能需要数组格式,具体查看uniapp文档:previewImage
|
},
|
||||||
const seeImgList = this.newsData.images
|
previewImage(index) {
|
||||||
uni.previewImage({
|
// 预览功能需要数组格式,具体查看uniapp文档:previewImage
|
||||||
current: index, //预览图片的下标
|
const seeImgList = this.newsData.images
|
||||||
urls: seeImgList //预览图片的地址,必须要数组形式,如果不是数组形式就转换成数组形式就可以
|
uni.previewImage({
|
||||||
})
|
current: index, //预览图片的下标
|
||||||
},
|
urls: seeImgList //预览图片的地址,必须要数组形式,如果不是数组形式就转换成数组形式就可以
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
button::after {
|
button::after {
|
||||||
border: none;
|
border: none;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
uni-button {
|
uni-button {
|
||||||
background: transparent;
|
background: transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
.container {
|
.container {
|
||||||
background-color: #f2f2f2;
|
background-color: #f2f2f2;
|
||||||
width: 750rpx;
|
width: 750rpx;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.solid {
|
.solid {
|
||||||
border-radius: 50rpx;
|
border-radius: 50rpx;
|
||||||
text-indent: 12rpx;
|
text-indent: 12rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
image {
|
image {
|
||||||
width: 750rpx;
|
width: 750rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.bottomBox {
|
.bottomBox {
|
||||||
width: 750rpx;
|
width: 750rpx;
|
||||||
position: fixed;
|
position: fixed;
|
||||||
left: 0;
|
left: 0;
|
||||||
bottom: 0rpx;
|
bottom: 0rpx;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
@ -1,217 +1,199 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="message tn-safe-area-inset-bottom">
|
<view class="message tn-safe-area-inset-bottom">
|
||||||
|
<view v-if="list.length > 0">
|
||||||
|
|
||||||
<!-- #ifdef H5 -->
|
<view class="wallpaper-shadow tn-margin tn-padding" v-for="(item, index) in list" :key="index"
|
||||||
<!-- 顶部自定义导航 -->
|
@click="goDetail(item.id)">
|
||||||
<tn-nav-bar fixed :bottomShadow="false" backTitle=" ">
|
<view class="tn-flex tn-flex-col-top">
|
||||||
<view class="">
|
<!-- 这个是图片形式,自己看需要去使用 -->
|
||||||
<text class="tn-text-lg">学习动态列表</text>
|
<view class="" v-if="item.images">
|
||||||
<text class="tn-text-xl tn-padding-left-sm tn-icon-group-circle"></text>
|
<view class="logo-pic">
|
||||||
</view>
|
<view class="logo-image">
|
||||||
</tn-nav-bar>
|
<!-- <view class="" style="width: 100%;height: 100%;;background-size: cover;"
|
||||||
<!-- #endif -->
|
:style="{backgroundImage:'url('+item.images+')'}">
|
||||||
|
</view> -->
|
||||||
|
<image :src="item.images" style="width: 100%;height: 100%;object-fit: cover"></image>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="tn-padding-left-sm" style="width: 100%;height: 200rpx;;position: relative;">
|
||||||
|
<view class="tn-flex tn-flex-row-between tn-flex-col-between">
|
||||||
|
<view class="justify-content-item">
|
||||||
|
<text class="tn-color-wallpaper tn-text-lg tn-text-bold">{{ item.name }}</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="tn-padding-top-xs" style="position: absolute;bottom: 0;">
|
||||||
|
<view class="justify-content-item tn-color-gray tn-color-gray">
|
||||||
|
<text class="tn-icon-time tn-padding-right-xs tn-text-df"></text>
|
||||||
|
<text class="tn-text-sm">{{ item.create_time_text }}</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
<view v-if="list.length > 0">
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
<view class="wallpaper-shadow tn-margin tn-padding" v-for="(item, index) in list" :key="index"
|
</view>
|
||||||
@click="goDetail(item.id)">
|
|
||||||
<view class="tn-flex tn-flex-col-top">
|
|
||||||
<!-- 这个是图片形式,自己看需要去使用 -->
|
|
||||||
<view class="" v-if="item.cover_image">
|
|
||||||
<view class="logo-pic">
|
|
||||||
<view class="logo-image">
|
|
||||||
<view class="" style="width: 100rpx;height: 100rpx;background-size: cover;"
|
|
||||||
:style="{backgroundImage:'url('+item.cover_image+')'}">
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="tn-padding-left-sm" style="width: 100%;">
|
|
||||||
<view class="tn-flex tn-flex-row-between tn-flex-col-between">
|
|
||||||
<view class="justify-content-item">
|
|
||||||
<text class="tn-color-wallpaper tn-text-lg tn-text-bold">{{ item.name }}</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class=" tn-padding-top-xs tn-text-ellipsis-2">
|
|
||||||
<!-- <text class="tn-color-gray">副标题</text> -->
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="tn-flex tn-flex-row-between tn-flex-col-between tn-margin-top-sm">
|
|
||||||
<view class="justify-content-item tn-color-gray tn-text-center tn-color-gray">
|
|
||||||
<text class="tn-icon-time tn-padding-right-xs tn-padding-left-xs tn-text-df"></text>
|
|
||||||
<text class="tn-text-sm">{{ item.create_time_text }}</text>
|
|
||||||
</view>
|
|
||||||
<!-- <view class="justify-content-item tn-round tn-text-xs tn-bg-blue--light tn-color-blue"
|
|
||||||
style="padding: 5rpx 15rpx;">
|
|
||||||
<text class="tn-padding-right-xs">#</text> 官 方
|
|
||||||
</view> -->
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
</view>
|
<view v-else>
|
||||||
|
<tui-no-data imgUrl="/static/img/img_noorder_3x.png">暂无数据</tui-no-data>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view class="tn-tabbar-height"></view>
|
||||||
|
|
||||||
|
<!-- 底部导航栏组件 -->
|
||||||
|
<tabbar :theme="tabbarStyle"></tabbar>
|
||||||
|
|
||||||
<view v-else>
|
|
||||||
<tui-no-data imgUrl="/static/img/img_noorder_3x.png" >暂无数据</tui-no-data>
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="tn-tabbar-height"></view>
|
|
||||||
|
|
||||||
<!-- 底部导航栏组件 -->
|
|
||||||
<tabbar :theme="tabbarStyle"></tabbar>
|
|
||||||
|
|
||||||
</view>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import newsApi from "@/common/api/news.js"
|
import newsApi from "@/common/api/news.js"
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Message',
|
name: 'Message',
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
list: [],
|
list: [],
|
||||||
hasMore: false,
|
hasMore: false,
|
||||||
currentPage: 1,
|
currentPage: 1,
|
||||||
loadFlag: 'loading',
|
loadFlag: 'loading',
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
this.getData()
|
this.getData()
|
||||||
},
|
},
|
||||||
async onReachBottom() {
|
async onReachBottom() {
|
||||||
console.log("onReachBottom")
|
console.log("onReachBottom")
|
||||||
if (this.hasMore) {
|
if (this.hasMore) {
|
||||||
this.currentPage++
|
this.currentPage++
|
||||||
this.getData()
|
this.getData()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getData() {
|
getData() {
|
||||||
this.loadFlag = 'loading'
|
this.loadFlag = 'loading'
|
||||||
|
|
||||||
let params = {
|
let params = {
|
||||||
page: this.current_page
|
page: this.current_page
|
||||||
}
|
}
|
||||||
|
|
||||||
newsApi.getNewsList(this, params).then(res => {
|
newsApi.getNewsList(this, params).then(res => {
|
||||||
if (res && res.data) {
|
if (res && res.data) {
|
||||||
this.list = this.list.concat(res.data.list.data)
|
this.list = this.list.concat(res.data.list.data)
|
||||||
this.hasMore = res.data.list.has_more
|
this.hasMore = res.data.list.has_more
|
||||||
this.currentPage = res.data.list.current_page
|
this.currentPage = res.data.list.current_page
|
||||||
this.loadFlag = 'over'
|
this.loadFlag = 'over'
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 跳转详情
|
// 跳转详情
|
||||||
goDetail(id) {
|
goDetail(id) {
|
||||||
this.utils.goto('news-detail?id=' + id)
|
this.utils.goto('news-detail?id=' + id)
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
page {
|
page {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.message {
|
.message {
|
||||||
max-height: 100vh;
|
max-height: 100vh;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 自定义导航栏内容 start */
|
/* 自定义导航栏内容 start */
|
||||||
.custom-nav {
|
.custom-nav {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
|
||||||
&__back {
|
&__back {
|
||||||
margin: auto 30rpx;
|
margin: auto 30rpx;
|
||||||
font-size: 40rpx;
|
font-size: 40rpx;
|
||||||
margin-right: 10rpx;
|
margin-right: 10rpx;
|
||||||
flex-basis: 5%;
|
flex-basis: 5%;
|
||||||
width: 100rpx;
|
width: 100rpx;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 自定义导航栏内容 end */
|
/* 自定义导航栏内容 end */
|
||||||
|
|
||||||
/* 底部安全边距 start*/
|
/* 底部安全边距 start*/
|
||||||
.tn-tabbar-height {
|
.tn-tabbar-height {
|
||||||
min-height: 20rpx;
|
min-height: 20rpx;
|
||||||
height: calc(40rpx + env(safe-area-inset-bottom) / 2);
|
height: calc(40rpx + env(safe-area-inset-bottom) / 2);
|
||||||
height: calc(40rpx + constant(safe-area-inset-bottom));
|
height: calc(40rpx + constant(safe-area-inset-bottom));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.tn-color-wallpaper {
|
.tn-color-wallpaper {
|
||||||
color: #1D2541;
|
color: #1D2541;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 页面阴影 start*/
|
/* 页面阴影 start*/
|
||||||
.wallpaper-shadow {
|
.wallpaper-shadow {
|
||||||
border-radius: 15rpx;
|
border-radius: 15rpx;
|
||||||
box-shadow: 0rpx 0rpx 50rpx 0rpx rgba(0, 0, 0, 0.07);
|
box-shadow: 0rpx 0rpx 50rpx 0rpx rgba(0, 0, 0, 0.07);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* 图标容器15 start */
|
/* 图标容器15 start */
|
||||||
.icon15 {
|
.icon15 {
|
||||||
&__item {
|
&__item {
|
||||||
width: 30%;
|
width: 30%;
|
||||||
background-color: #FFFFFF;
|
background-color: #FFFFFF;
|
||||||
border-radius: 10rpx;
|
border-radius: 10rpx;
|
||||||
padding: 30rpx;
|
padding: 30rpx;
|
||||||
margin: 20rpx 10rpx;
|
margin: 20rpx 10rpx;
|
||||||
transform: scale(1);
|
transform: scale(1);
|
||||||
transition: transform 0.3s linear;
|
transition: transform 0.3s linear;
|
||||||
transform-origin: center center;
|
transform-origin: center center;
|
||||||
|
|
||||||
&--icon {
|
&--icon {
|
||||||
width: 105rpx;
|
width: 105rpx;
|
||||||
height: 105rpx;
|
height: 105rpx;
|
||||||
font-size: 60rpx;
|
font-size: 60rpx;
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
margin-bottom: 18rpx;
|
margin-bottom: 18rpx;
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
|
||||||
&::after {
|
&::after {
|
||||||
content: " ";
|
content: " ";
|
||||||
position: absolute;
|
position: absolute;
|
||||||
z-index: -1;
|
z-index: -1;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
left: 0;
|
left: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
border-radius: inherit;
|
border-radius: inherit;
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
transform: scale(1, 1);
|
transform: scale(1, 1);
|
||||||
background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 用户头像 start */
|
/* 用户头像 start */
|
||||||
.logo-image {
|
.logo-image {
|
||||||
width: 100rpx;
|
width: 300rpx;
|
||||||
height: 100rpx;
|
height: 200rpx;
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.logo-pic {
|
.logo-pic {
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
// background-attachment:fixed;
|
// background-attachment:fixed;
|
||||||
background-position: top;
|
background-position: top;
|
||||||
border: 1rpx solid rgba(255, 255, 255, 0.05);
|
border: 1rpx solid rgba(255, 255, 255, 0.05);
|
||||||
box-shadow: 0rpx 0rpx 80rpx 0rpx rgba(0, 0, 0, 0.05);
|
box-shadow: 0rpx 0rpx 80rpx 0rpx rgba(0, 0, 0, 0.05);
|
||||||
border-radius: 50%;
|
overflow: hidden;
|
||||||
overflow: hidden;
|
// background-color: #FFFFFF;
|
||||||
// background-color: #FFFFFF;
|
}
|
||||||
}
|
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
@ -1,17 +1,6 @@
|
|||||||
<!-- 新闻 详情 -->
|
<!-- 新闻 详情 -->
|
||||||
<template>
|
<template>
|
||||||
<view class="container">
|
<view class="container">
|
||||||
|
|
||||||
<!-- #ifdef H5 -->
|
|
||||||
<!-- 顶部自定义导航 -->
|
|
||||||
<tn-nav-bar fixed :bottomShadow="false" backTitle=" ">
|
|
||||||
<view class="">
|
|
||||||
<text class="tn-text-lg">公告</text>
|
|
||||||
<text class="tn-text-xl tn-padding-left-sm tn-icon-group-circle"></text>
|
|
||||||
</view>
|
|
||||||
</tn-nav-bar>
|
|
||||||
<!-- #endif -->
|
|
||||||
|
|
||||||
<view>
|
<view>
|
||||||
<view style="background-color: #FFFFFF;padding: 30rpx 30rpx 30rpx 30rpx;">
|
<view style="background-color: #FFFFFF;padding: 30rpx 30rpx 30rpx 30rpx;">
|
||||||
<view class="titleBox text-xl text-black text-bold">{{newsData.name}}</view>
|
<view class="titleBox text-xl text-black text-bold">{{newsData.name}}</view>
|
||||||
@ -24,16 +13,16 @@
|
|||||||
|
|
||||||
<!-- 中间文章区域 -->
|
<!-- 中间文章区域 -->
|
||||||
<view class="contentBox text-lg text-black margin-top-sm margin-tb-lg">
|
<view class="contentBox text-lg text-black margin-top-sm margin-tb-lg">
|
||||||
<view class="margin-top-sm" v-html="newsData.contents">
|
<!-- <view class="margin-top-sm" v-html="newsData.contents">
|
||||||
</view>
|
</view> -->
|
||||||
|
<mp-html :tag-style="tagStyle" :scroll-table="true" :content="newsData.contents" />
|
||||||
<!-- <view class="margin-top-sm" v-for="(item, index) in newsData.contents.split('&')" v-html="item">
|
<!-- <view class="margin-top-sm" v-for="(item, index) in newsData.contents.split('&')" v-html="item">
|
||||||
</view> -->
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="cu-bar bg-white tabbar border shop bottomBox">
|
<!-- <view class="cu-bar bg-white tabbar border shop bottomBox"> -->
|
||||||
<!-- <button class="action" open-type="share">
|
<!-- <button class="action" open-type="share">
|
||||||
<view class="cuIcon-share text-green">
|
<view class="cuIcon-share text-green">
|
||||||
<view class="cu-tag badge">{{newsData.commentNum}}</view>
|
<view class="cu-tag badge">{{newsData.commentNum}}</view>
|
||||||
@ -46,12 +35,12 @@
|
|||||||
</view>
|
</view>
|
||||||
联系我们
|
联系我们
|
||||||
</button> -->
|
</button> -->
|
||||||
<view class="btn-group">
|
<!-- <view class="btn-group">
|
||||||
<!-- <button style="width: 80%;height: 70rpx;" @click="handleClick()"
|
<button style="width: 80%;height: 70rpx;" @click="handleClick()"
|
||||||
class="cu-btn bg-gradual-blue round shadow-blur">
|
class="cu-btn bg-gradual-blue round shadow-blur">
|
||||||
<view class="cuIcon-appreciatefill text-white margin-right-xs"></view>
|
<view class="cuIcon-appreciatefill text-white margin-right-xs"></view>
|
||||||
前往
|
前往
|
||||||
</button> -->
|
</button>
|
||||||
|
|
||||||
<tn-button shape="round" backgroundColor="#1A73E8" padding="30rpx 0" width="200rpx" shadow @click="handleBack()" fontBold plain>
|
<tn-button shape="round" backgroundColor="#1A73E8" padding="30rpx 0" width="200rpx" shadow @click="handleBack()" fontBold plain>
|
||||||
<text class="primary-color">返回列表</text>
|
<text class="primary-color">返回列表</text>
|
||||||
@ -60,8 +49,8 @@
|
|||||||
<tn-button shape="round" backgroundColor="#1A73E8" padding="30rpx 0" width="200rpx" shadow @click="handleGo()" v-if="newsData && newsData.front_info" fontBold>
|
<tn-button shape="round" backgroundColor="#1A73E8" padding="30rpx 0" width="200rpx" shadow @click="handleGo()" v-if="newsData && newsData.front_info" fontBold>
|
||||||
<text class="tn-color-white">点击前往</text>
|
<text class="tn-color-white">点击前往</text>
|
||||||
</tn-button>
|
</tn-button>
|
||||||
</view>
|
</view> -->
|
||||||
</view>
|
<!-- </view> -->
|
||||||
<view class="safe-area-inset-bottom"></view>
|
<view class="safe-area-inset-bottom"></view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
@ -72,7 +61,12 @@
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
newsData: [],
|
newsData: [],
|
||||||
requestStatus: false // 事件防抖
|
requestStatus: false, // 事件防抖
|
||||||
|
tagStyle: {
|
||||||
|
table: 'border: 1px solid gray;border-collapse:collapse',
|
||||||
|
th: 'border: 1px solid gray;',
|
||||||
|
td: 'border: 1px solid gray;'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(option) {
|
onLoad(option) {
|
||||||
@ -86,6 +80,7 @@
|
|||||||
|
|
||||||
noticeApi.getNoticeDetail(this, {id: id}).then(res => {
|
noticeApi.getNoticeDetail(this, {id: id}).then(res => {
|
||||||
if (res && res.data) {
|
if (res && res.data) {
|
||||||
|
//res.data.contents = res.data.contents.replace(/<table/g, '<table border="1"')
|
||||||
this.newsData = res.data
|
this.newsData = res.data
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
@ -1,16 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="message tn-safe-area-inset-bottom">
|
<view class="message tn-safe-area-inset-bottom">
|
||||||
|
|
||||||
<!-- #ifdef H5 -->
|
|
||||||
<!-- 顶部自定义导航 -->
|
|
||||||
<tn-nav-bar fixed :bottomShadow="false" backTitle=" ">
|
|
||||||
<view class="">
|
|
||||||
<text class="tn-text-lg">公告</text>
|
|
||||||
<text class="tn-text-xl tn-padding-left-sm tn-icon-group-circle"></text>
|
|
||||||
</view>
|
|
||||||
</tn-nav-bar>
|
|
||||||
<!-- #endif -->
|
|
||||||
|
|
||||||
<view v-if="list.length > 0">
|
<view v-if="list.length > 0">
|
||||||
|
|
||||||
<view class="wallpaper-shadow tn-margin tn-padding" v-for="(item, index) in list" :key="index" @click="goDetail(item.id)">
|
<view class="wallpaper-shadow tn-margin tn-padding" v-for="(item, index) in list" :key="index" @click="goDetail(item.id)">
|
||||||
@ -54,7 +43,7 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="tn-tabbar-height"></view>
|
<view class="tn-tabbar-height"></view>
|
||||||
|
<tabbar :theme="tabbarStyle" :tabbar="tabbar"></tabbar>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -42,7 +42,7 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 加载状态条 -->
|
<!-- 加载状态条 -->
|
||||||
<view class="cu-load bg-grey" :class="loadFlag" v-show="has_more || loadFlag == 'over'"></view>
|
<!-- <view class="cu-load bg-grey" :class="loadFlag" v-show="has_more || loadFlag == 'over'"></view> -->
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<tui-loading v-if="showLoading"></tui-loading>
|
<tui-loading v-if="showLoading"></tui-loading>
|
||||||
@ -63,7 +63,7 @@
|
|||||||
>
|
>
|
||||||
</tn-action-sheet>
|
</tn-action-sheet>
|
||||||
|
|
||||||
<tabbar></tabbar>
|
<!-- <tabbar></tabbar> -->
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -131,9 +131,7 @@
|
|||||||
this.gradeItem = item
|
this.gradeItem = item
|
||||||
this.tipsAction = {text: item.paper?.title}
|
this.tipsAction = {text: item.paper?.title}
|
||||||
|
|
||||||
let listAction = [
|
let listAction = []
|
||||||
{text: '查看排行榜'}
|
|
||||||
]
|
|
||||||
if (item.error_ids) {
|
if (item.error_ids) {
|
||||||
listAction.unshift({text: '查看错题'})
|
listAction.unshift({text: '查看错题'})
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
<view class="tn-text-lg tn-text-bold clamp-text-1 tn-text-justify tn-flex-basic-lg">
|
<view class="tn-text-lg tn-text-bold clamp-text-1 tn-text-justify tn-flex-basic-lg">
|
||||||
<text class="">{{ item.title }}</text>
|
<text class="">{{ item.title }}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="tn-flex-basic-sm text-right">
|
<!-- <view class="tn-flex-basic-sm text-right">
|
||||||
<view
|
<view
|
||||||
style="transform: translate(0rpx,6rpx);"
|
style="transform: translate(0rpx,6rpx);"
|
||||||
class="justify-content-item tn-tag-content__item tn-margin-right-xs tn-round tn-text-sm tn-text-bold tn-bg-blue--light tn-color-blue"
|
class="justify-content-item tn-tag-content__item tn-margin-right-xs tn-round tn-text-sm tn-text-bold tn-bg-blue--light tn-color-blue"
|
||||||
@ -22,7 +22,7 @@
|
|||||||
<text class="tn-tag-content__item--prefix">#</text>
|
<text class="tn-tag-content__item--prefix">#</text>
|
||||||
{{ item.cates.name }}
|
{{ item.cates.name }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
<view class="tn-padding-top-xs" style="min-height: 90rpx;">
|
<view class="tn-padding-top-xs" style="min-height: 90rpx;">
|
||||||
<text class=" tn-color-gray clamp-text-2 tn-text-justify">考试限时:{{ item.limit_time | format_second }}</text>
|
<text class=" tn-color-gray clamp-text-2 tn-text-justify">考试限时:{{ item.limit_time | format_second }}</text>
|
||||||
|
@ -2,10 +2,21 @@
|
|||||||
<view class="container">
|
<view class="container">
|
||||||
<!-- 顶部导航 -->
|
<!-- 顶部导航 -->
|
||||||
<!-- <topbar :title="paper_name" :scrollTop="scrollTop"></topbar> -->
|
<!-- <topbar :title="paper_name" :scrollTop="scrollTop"></topbar> -->
|
||||||
|
<tn-nav-bar backgroundColor="#1A73E8" customBack :bottomShadow="false" fontColor="#FFFFFF">
|
||||||
<!-- <tui-navigation-bar splitLine @init="initNavigation" @change="opacityChange" :scrollTop="scrollTop" title="NavBar自定义导航栏" backgroundColor="#fff" color="#333">
|
<view class="custom-nav tn-flex tn-flex-col-center tn-flex-row-center">
|
||||||
<view class="tui-header-icon" :style="{ marginTop: top + 'px' }"><tui-icon name="arrowleft" :color="opacity > 0.85 ? '#333' : '#fff'" @click="back"></tui-icon></view>
|
<view style="color: #ffffff;;text-align: left;font-size: 30rpx;">
|
||||||
</tui-navigation-bar> -->
|
<text>考试试卷</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view slot="back" @click="goToBack" style="padding-top: 10rpx;">
|
||||||
|
<text class='tn-icon tn-icon-left' style="font-size: 40rpx;"></text>
|
||||||
|
</view>
|
||||||
|
</tn-nav-bar>
|
||||||
|
<!-- <tui-navigation-bar splitLine @init="initNavigation" @change="opacityChange" :scrollTop="scrollTop"
|
||||||
|
title="NavBar自定义导航栏" backgroundColor="#fff" color="#333">
|
||||||
|
<view class="tui-header-icon" :style="{ marginTop: top + 'px' }"><tui-icon name="arrowleft"
|
||||||
|
:color="opacity > 0.85 ? '#333' : '#fff'" @click="back"></tui-icon></view>
|
||||||
|
</tui-navigation-bar> -->
|
||||||
<!-- <view class="tui-header-bg"><image src="/static/componentBg.png" class="tui-header-img"></image></view> -->
|
<!-- <view class="tui-header-bg"><image src="/static/componentBg.png" class="tui-header-img"></image></view> -->
|
||||||
<!-- <tui-navigation-bar @init="initNavigation" :title="paper_name" @change="opacityChange" :scrollTop="scrollTop" :isOpacity="false" backgroundColor="#fff" color="#333">
|
<!-- <tui-navigation-bar @init="initNavigation" :title="paper_name" @change="opacityChange" :scrollTop="scrollTop" :isOpacity="false" backgroundColor="#fff" color="#333">
|
||||||
<view class="tui-header-icon" :style="{ marginTop: top + 'px' }"><tui-icon name="arrowleft" color="#333" @click="back"></tui-icon></view>
|
<view class="tui-header-icon" :style="{ marginTop: top + 'px' }"><tui-icon name="arrowleft" color="#333" @click="back"></tui-icon></view>
|
||||||
@ -15,18 +26,13 @@
|
|||||||
<!-- <tui-countdown :time="limit_time" borderColor="transparent" :isColon="false" @end="endOfTime"></tui-countdown> -->
|
<!-- <tui-countdown :time="limit_time" borderColor="transparent" :isColon="false" @end="endOfTime"></tui-countdown> -->
|
||||||
|
|
||||||
<!-- 答题组件 -->
|
<!-- 答题组件 -->
|
||||||
<kz-question v-show="result == null"
|
<view style="padding-top: 180rpx;">
|
||||||
ref="comQuestion"
|
<kz-question v-show="result == null" ref="comQuestion" mode="EXAM" :questionMode="paper ? paper.mode : 'RANDOM'"
|
||||||
mode="EXAM"
|
:title="paper_name" :questions="questions" :configs="configs" :limit_time="limit_time"
|
||||||
:questionMode="paper ? paper.mode : 'RANDOM'"
|
:isPreventSwitchScreen="isPreventSwitchScreen" :switchScreenCount="switchScreenCount"
|
||||||
:title="paper_name"
|
@submitQuestion="submitQuestion">
|
||||||
:questions="questions"
|
</kz-question>
|
||||||
:configs="configs"
|
</view>
|
||||||
:limit_time="limit_time"
|
|
||||||
:isPreventSwitchScreen="isPreventSwitchScreen"
|
|
||||||
:switchScreenCount="switchScreenCount"
|
|
||||||
@submitQuestion="submitQuestion">
|
|
||||||
</kz-question>
|
|
||||||
|
|
||||||
<!-- 成绩组件 -->
|
<!-- 成绩组件 -->
|
||||||
<kz-grade-result v-show="result != null" :score="score" :gradeResult="result" ref="gradeResult"
|
<kz-grade-result v-show="result != null" :score="score" :gradeResult="result" ref="gradeResult"
|
||||||
@ -70,15 +76,9 @@
|
|||||||
</tui-modal>
|
</tui-modal>
|
||||||
|
|
||||||
<!-- 题库支付、激活弹窗组件 -->
|
<!-- 题库支付、激活弹窗组件 -->
|
||||||
<kz-cate-pay ref="cate_pay"
|
<kz-cate-pay ref="cate_pay" :cateId="cateId" :catePrice="catePrice" :showCateConfirm="showCateConfirm"
|
||||||
:cateId="cateId"
|
:confirmCateContent="confirmCateContent" v-on:paySuccess="cateSuccess()" v-on:codeSuccess="cateSuccess()"
|
||||||
:catePrice="catePrice"
|
v-on:cancel="closeCateDialog">
|
||||||
:showCateConfirm="showCateConfirm"
|
|
||||||
:confirmCateContent="confirmCateContent"
|
|
||||||
v-on:paySuccess="cateSuccess()"
|
|
||||||
v-on:codeSuccess="cateSuccess()"
|
|
||||||
v-on:cancel="closeCateDialog"
|
|
||||||
>
|
|
||||||
</kz-cate-pay>
|
</kz-cate-pay>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
@ -155,6 +155,7 @@
|
|||||||
switchScreenTimestamp: 0,
|
switchScreenTimestamp: 0,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onShow() {
|
onShow() {
|
||||||
if (this.isFirstShow) {
|
if (this.isFirstShow) {
|
||||||
this.isFirstShow = false
|
this.isFirstShow = false
|
||||||
@ -177,6 +178,21 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
console.log('onShow', this.curretSwitchScreenCount)
|
console.log('onShow', this.curretSwitchScreenCount)
|
||||||
|
|
||||||
|
// 禁用iOS右划返回手势 - 方法3:onShow中补充设置,处理页面恢复情况
|
||||||
|
// #ifdef APP-PLUS
|
||||||
|
if (!this.isFirstShow) {
|
||||||
|
try {
|
||||||
|
let pages = getCurrentPages();
|
||||||
|
let page = pages[pages.length - 1];
|
||||||
|
let currentWebview = page.$getAppWebview();
|
||||||
|
currentWebview.setStyle({ popGesture: 'none' });
|
||||||
|
console.log('onShow: iOS右划手势禁用补充设置完成')
|
||||||
|
} catch (e) {
|
||||||
|
console.log('onShow: iOS右划手势禁用补充设置失败', e)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// #endif
|
||||||
},
|
},
|
||||||
onHide() {
|
onHide() {
|
||||||
if (this.isPreventSwitchScreen) {
|
if (this.isPreventSwitchScreen) {
|
||||||
@ -194,6 +210,43 @@
|
|||||||
if (this.room_id) {
|
if (this.room_id) {
|
||||||
this.getQuestion()
|
this.getQuestion()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 禁用iOS右划返回手势 - 方法1:onLoad中设置
|
||||||
|
// #ifdef APP-PLUS
|
||||||
|
try {
|
||||||
|
plus.webview.currentWebview().setStyle({'popGesture': 'none'})
|
||||||
|
console.log('onLoad: iOS右划手势禁用设置完成')
|
||||||
|
} catch (e) {
|
||||||
|
console.log('onLoad: iOS右划手势禁用设置失败', e)
|
||||||
|
}
|
||||||
|
// #endif
|
||||||
|
},
|
||||||
|
onReady() {
|
||||||
|
// 禁用iOS右划返回手势 - 方法2:onReady中使用getCurrentPages方式设置
|
||||||
|
// #ifdef APP-PLUS
|
||||||
|
try {
|
||||||
|
let pages = getCurrentPages();
|
||||||
|
let page = pages[pages.length - 1];
|
||||||
|
let currentWebview = page.$getAppWebview();
|
||||||
|
currentWebview.setStyle({ popGesture: 'none' });
|
||||||
|
console.log('onReady: iOS右划手势禁用设置完成')
|
||||||
|
} catch (e) {
|
||||||
|
console.log('onReady: iOS右划手势禁用设置失败', e)
|
||||||
|
}
|
||||||
|
|
||||||
|
// 延迟再次设置,确保webview完全初始化
|
||||||
|
setTimeout(() => {
|
||||||
|
try {
|
||||||
|
let pages = getCurrentPages();
|
||||||
|
let page = pages[pages.length - 1];
|
||||||
|
let currentWebview = page.$getAppWebview();
|
||||||
|
currentWebview.setStyle({ popGesture: 'none' });
|
||||||
|
console.log('onReady延迟: iOS右划手势禁用设置完成')
|
||||||
|
} catch (e) {
|
||||||
|
console.log('onReady延迟: iOS右划手势禁用设置失败', e)
|
||||||
|
}
|
||||||
|
}, 500);
|
||||||
|
// #endif
|
||||||
},
|
},
|
||||||
onBackPress(e) {
|
onBackPress(e) {
|
||||||
console.log('onBackPress e', e)
|
console.log('onBackPress e', e)
|
||||||
@ -224,6 +277,22 @@
|
|||||||
this.scrollTop = e.scrollTop
|
this.scrollTop = e.scrollTop
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
goToBack() {
|
||||||
|
if (!this.isSubmit) {
|
||||||
|
let message = '当前正在模拟考试,是否确认退出?'
|
||||||
|
uni.showModal({
|
||||||
|
title: '提示',
|
||||||
|
content: message,
|
||||||
|
success: (res) => {
|
||||||
|
if (res.confirm) {
|
||||||
|
uni.navigateBack({
|
||||||
|
delta: 1
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
// 请求数据
|
// 请求数据
|
||||||
ajax() {
|
ajax() {
|
||||||
paperApi.checkPay(this, {
|
paperApi.checkPay(this, {
|
||||||
@ -300,14 +369,22 @@
|
|||||||
// 1:可以参加,2:需要支付
|
// 1:可以参加,2:需要支付
|
||||||
switch (res.data.status) {
|
switch (res.data.status) {
|
||||||
case 0:
|
case 0:
|
||||||
this.utils.toast(res.data.msg ? res.data.msg : '未知错误')
|
//this.utils.toast(res.data.msg ? res.data.msg : '未知错误')
|
||||||
setTimeout(() => {
|
uni.showModal({
|
||||||
if (res.data.url) {
|
title: '提示',
|
||||||
this.utils.goto(res.data.url)
|
content: res.data.msg,
|
||||||
} else {
|
confirmText: '联系客服',
|
||||||
this.goBack()
|
success: (res) => {
|
||||||
|
if (res.confirm) {
|
||||||
|
//this.utils.goto('/pages/user/member-center?from_train=1')
|
||||||
|
uni.makePhoneCall({
|
||||||
|
phoneNumber: '18903795988' //仅为示例
|
||||||
|
});
|
||||||
|
} else if (res.cancel) {
|
||||||
|
this.utils.goback()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}, 3000)
|
});
|
||||||
break
|
break
|
||||||
case 1:
|
case 1:
|
||||||
this.getQuestion()
|
this.getQuestion()
|
||||||
@ -368,7 +445,8 @@
|
|||||||
for (let i in questions) {
|
for (let i in questions) {
|
||||||
questions[i]['code2'] = false
|
questions[i]['code2'] = false
|
||||||
console.log('questions[i][score]', questions[i]['score'])
|
console.log('questions[i][score]', questions[i]['score'])
|
||||||
questions[i]['score'] = this.getSingleScore(questions[i])//, questions[i].kind, questions[i].difficulty
|
questions[i]['score'] = this.getSingleScore(questions[
|
||||||
|
i]) //, questions[i].kind, questions[i].difficulty
|
||||||
console.log('questions[i][score]', questions[i]['score'])
|
console.log('questions[i][score]', questions[i]['score'])
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -377,7 +455,8 @@
|
|||||||
this.configs = this.paper.configs
|
this.configs = this.paper.configs
|
||||||
|
|
||||||
// 防切屏
|
// 防切屏
|
||||||
if (this.paper.is_prevent_switch_screen && this.paper.switch_screen_count && this.paper.switch_screen_second) {
|
if (this.paper.is_prevent_switch_screen && this.paper.switch_screen_count && this.paper
|
||||||
|
.switch_screen_second) {
|
||||||
this.isPreventSwitchScreen = true
|
this.isPreventSwitchScreen = true
|
||||||
this.switchScreenCount = this.paper.switch_screen_count
|
this.switchScreenCount = this.paper.switch_screen_count
|
||||||
this.switchScreenSecond = this.paper.switch_screen_second
|
this.switchScreenSecond = this.paper.switch_screen_second
|
||||||
|
@ -1,13 +1,11 @@
|
|||||||
<template>
|
<template>
|
||||||
<view>
|
<view>
|
||||||
<view class="card-view">
|
<!-- <view class="card-view">
|
||||||
<image :src="bannerImage" mode="aspectFill" style="width: 100%; height: 200rpx;"></image>
|
<image :src="bannerImage" mode="aspectFill" style="width: 100%; height: 200rpx;"></image>
|
||||||
</view>
|
</view> -->
|
||||||
|
<view style="height:99vh">
|
||||||
<view style="height: calc(99vh - 200px);">
|
<view class="card-view" style="height: 85%;">
|
||||||
<view class="card-view">
|
<!-- <tui-divider width="80%" gradual>选择要练习的题目类型</tui-divider>
|
||||||
<!-- <tui-divider width="80%" gradual>选择要练习的题目类型</tui-divider> -->
|
|
||||||
|
|
||||||
<view class="margin">
|
<view class="margin">
|
||||||
<tn-radio-group activeColor="#1A73E8" v-model="mode">
|
<tn-radio-group activeColor="#1A73E8" v-model="mode">
|
||||||
<tn-radio name="normal">正常模式</tn-radio>
|
<tn-radio name="normal">正常模式</tn-radio>
|
||||||
@ -20,9 +18,9 @@
|
|||||||
<view v-if="mode == 'normal'">* 按顺序出题,不记忆当前做题题标</view>
|
<view v-if="mode == 'normal'">* 按顺序出题,不记忆当前做题题标</view>
|
||||||
<view v-if="mode == 'memory'">* 按顺序出题,记忆当前做题题标,下次进入直接跳至题标</view>
|
<view v-if="mode == 'memory'">* 按顺序出题,记忆当前做题题标,下次进入直接跳至题标</view>
|
||||||
<view v-if="mode == 'random'">* 随机出题,不记忆当前做题题标</view>
|
<view v-if="mode == 'random'">* 随机出题,不记忆当前做题题标</view>
|
||||||
</view>
|
</view> -->
|
||||||
|
|
||||||
<tui-cascade-selection height="800rpx" :itemList="cateList" @complete="complete" text="请选择题库"
|
<tui-cascade-selection height="75vh" :itemList="cateList" @complete="complete" text="请选择题库"
|
||||||
:defaultItemList="defaultCateList"></tui-cascade-selection>
|
:defaultItemList="defaultCateList"></tui-cascade-selection>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -199,7 +197,7 @@
|
|||||||
if (res.code == 1) {
|
if (res.code == 1) {
|
||||||
this.questionCount = res.data.total
|
this.questionCount = res.data.total
|
||||||
if (this.questionCount) {
|
if (this.questionCount) {
|
||||||
this.btnText = '开始练习(' + this.questionCount + '题)'
|
this.btnText = '开始练习'
|
||||||
} else {
|
} else {
|
||||||
this.btnText = '当前分类无试题'
|
this.btnText = '当前分类无试题'
|
||||||
}
|
}
|
||||||
@ -228,10 +226,13 @@
|
|||||||
uni.showModal({
|
uni.showModal({
|
||||||
title: '提示',
|
title: '提示',
|
||||||
content: res.msg,
|
content: res.msg,
|
||||||
confirmText: '前往开通',
|
confirmText: '联系客服',
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
if (res.confirm) {
|
if (res.confirm) {
|
||||||
this.utils.goto('/pages/user/member-center?from_train=1')
|
//this.utils.goto('/pages/user/member-center?from_train=1')
|
||||||
|
uni.makePhoneCall({
|
||||||
|
phoneNumber: '18903795988' //仅为示例
|
||||||
|
});
|
||||||
} else if (res.cancel) {
|
} else if (res.cancel) {
|
||||||
this.utils.goback()
|
this.utils.goback()
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<view>
|
<view>
|
||||||
<view class="card-view">
|
<!-- <view class="card-view">
|
||||||
<image src="../../static/img/train-banner2.png" mode="aspectFill" style="width: 100%;"></image>
|
<image src="../../static/img/train-banner2.png" mode="aspectFill" style="width: 100%;"></image>
|
||||||
</view>
|
</view> -->
|
||||||
|
|
||||||
<view class="card-view">
|
<view class="card-view">
|
||||||
<!-- <tui-divider width="80%" gradual>选择要常用的题库</tui-divider> -->
|
<!-- <tui-divider width="80%" gradual>选择要常用的题库</tui-divider> -->
|
||||||
|
@ -12,9 +12,9 @@
|
|||||||
<view class="tn-flex tn-flex-row-between tn-strip-bottom-min tn-padding">
|
<view class="tn-flex tn-flex-row-between tn-strip-bottom-min tn-padding">
|
||||||
<view class="justify-content-item">
|
<view class="justify-content-item">
|
||||||
<view class="tn-text-bold tn-text-lg"> 用户头像 </view>
|
<view class="tn-text-bold tn-text-lg"> 用户头像 </view>
|
||||||
<view class="tn-color-gray tn-padding-top-xs">
|
<!-- <view class="tn-color-gray tn-padding-top-xs">
|
||||||
有趣的头像,百里挑一
|
有趣的头像,百里挑一
|
||||||
</view>
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
<button
|
<button
|
||||||
class="avatar-wrapper"
|
class="avatar-wrapper"
|
||||||
@ -82,7 +82,7 @@
|
|||||||
<view class="tn-icon-right tn-padding-top"></view>
|
<view class="tn-icon-right tn-padding-top"></view>
|
||||||
</view>
|
</view>
|
||||||
</view> -->
|
</view> -->
|
||||||
<picker
|
<!-- <picker
|
||||||
@change="bindGenderChange"
|
@change="bindGenderChange"
|
||||||
:value="indexGender"
|
:value="indexGender"
|
||||||
:range="arrayGender"
|
:range="arrayGender"
|
||||||
@ -121,7 +121,7 @@
|
|||||||
<view class="tn-icon-right tn-padding-top"></view>
|
<view class="tn-icon-right tn-padding-top"></view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</picker>
|
</picker> -->
|
||||||
<!-- <picker @change="bindPickerChange1" :value="index1" :range="array1">
|
<!-- <picker @change="bindPickerChange1" :value="index1" :range="array1">
|
||||||
<view class="tn-flex tn-flex-row-between tn-strip-bottom-min tn-padding">
|
<view class="tn-flex tn-flex-row-between tn-strip-bottom-min tn-padding">
|
||||||
<view class="justify-content-item">
|
<view class="justify-content-item">
|
||||||
|
@ -20,6 +20,8 @@
|
|||||||
<view v-if="info!=''" @click="updateVideo"
|
<view v-if="info!=''" @click="updateVideo"
|
||||||
style="position: fixed;left:0;right:0;border-radius:10rpx;bottom: 40rpx;;color: #ffffff;height: 80rpx;line-height: 80rpx;text-align: center;background-color: #1A73E8;width: 80%;margin: 0 auto">
|
style="position: fixed;left:0;right:0;border-radius:10rpx;bottom: 40rpx;;color: #ffffff;height: 80rpx;line-height: 80rpx;text-align: center;background-color: #1A73E8;width: 80%;margin: 0 auto">
|
||||||
上传学习成果</view>
|
上传学习成果</view>
|
||||||
|
<!-- 登录组件 -->
|
||||||
|
<login ref="login" v-on:succ="ajax()"></login>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -35,6 +37,25 @@
|
|||||||
onLoad(op) {
|
onLoad(op) {
|
||||||
this.id = op.id;
|
this.id = op.id;
|
||||||
this.getList();
|
this.getList();
|
||||||
|
|
||||||
|
},
|
||||||
|
onShow() {
|
||||||
|
uni.$on("login_success", (data) => {
|
||||||
|
console.log("login_success", data);
|
||||||
|
//this.user = data.user;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
if (!uni.getStorageSync("token")) {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
//console.log(this.$refs.login);
|
||||||
|
this.$refs.login.modal = true;
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onHide() {
|
||||||
|
uni.$off("login_success");
|
||||||
},
|
},
|
||||||
onShareAppMessage() {
|
onShareAppMessage() {
|
||||||
return {
|
return {
|
||||||
@ -43,8 +64,15 @@
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
ajax() {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
updateVideo() {
|
updateVideo() {
|
||||||
|
if (!uni.getStorageSync("token")) {
|
||||||
|
this.$refs.login.modal = true;
|
||||||
|
return;
|
||||||
|
}
|
||||||
var that = this;
|
var that = this;
|
||||||
uni.chooseMedia({
|
uni.chooseMedia({
|
||||||
count: 1,
|
count: 1,
|
||||||
@ -94,6 +122,7 @@
|
|||||||
id: this.id
|
id: this.id
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
console.log(res);
|
console.log(res);
|
||||||
|
|
||||||
this.info = res.data;
|
this.info = res.data;
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -6,17 +6,20 @@
|
|||||||
<view style="padding: 30rpx;background-color: #ffffff;">
|
<view style="padding: 30rpx;background-color: #ffffff;">
|
||||||
<view style="display: flex;justify-content: space-between;align-items: center;">
|
<view style="display: flex;justify-content: space-between;align-items: center;">
|
||||||
<view style="font-size: 34rpx;font-weight: 600">{{info.mulu.mulu_name}}</view>
|
<view style="font-size: 34rpx;font-weight: 600">{{info.mulu.mulu_name}}</view>
|
||||||
<view style="font-size: 24rpx;color: #999999">转发</view>
|
<view>
|
||||||
|
<button open-type="share" style="font-size: 24rpx;color: #999999">转发</button>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view style="margin-top: 15rpx;padding: 30rpx;background-color: #ffffff;">
|
<view style="margin-top: 15rpx;padding: 30rpx;background-color: #ffffff;">
|
||||||
<tn-tabs :list="list" :isScroll="false" :current="current" name="name" :bold="true" activeColor="#1A73E8" inactiveColor="#999999" :fontSize="36" @change="change"></tn-tabs>
|
<tn-tabs :list="list" :isScroll="false" :current="current" name="name" :bold="true" activeColor="#1A73E8"
|
||||||
|
inactiveColor="#999999" :fontSize="36" @change="change"></tn-tabs>
|
||||||
<view style="height: 1px;background-color: #eeeeee;width: 100%;margin: 30rpx 0rpx;"></view>
|
<view style="height: 1px;background-color: #eeeeee;width: 100%;margin: 30rpx 0rpx;"></view>
|
||||||
<view v-if="current==0">
|
<view v-if="current==0">
|
||||||
<view v-html="info.mulu.mulu_content"></view>
|
<view v-html="info.mulu.mulu_content"></view>
|
||||||
</view>
|
</view>
|
||||||
<view v-for="(item,index) in info.viedo" v-if="current==1">
|
<view v-for="(item,index) in info.viedo" v-if="current==1" @click="openUrl(item)">
|
||||||
<view style="display: flex;" @click="openUrl(item.id)">
|
<view style="display: flex;">
|
||||||
<view style="font-size: 32rpx;font-weight: 600;color: #999999;">{{index<9?0:''}}{{index+1}}</view>
|
<view style="font-size: 32rpx;font-weight: 600;color: #999999;">{{index<9?0:''}}{{index+1}}</view>
|
||||||
<view style="width: 100%;padding-left: 20rpx;">
|
<view style="width: 100%;padding-left: 20rpx;">
|
||||||
<view style="display: flex;align-items: center;justify-content: space-between;">
|
<view style="display: flex;align-items: center;justify-content: space-between;">
|
||||||
@ -50,15 +53,30 @@
|
|||||||
current: 0,
|
current: 0,
|
||||||
info: {},
|
info: {},
|
||||||
id: 0,
|
id: 0,
|
||||||
|
vip: 0,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(op) {
|
onLoad(op) {
|
||||||
this.id = op.id;
|
this.id = op.id;
|
||||||
this.getList();
|
this.getList();
|
||||||
|
this.getIsUser();
|
||||||
|
},
|
||||||
|
onShareAppMessage() {
|
||||||
|
return {
|
||||||
|
title: this.info.mulu.mulu_name,
|
||||||
|
path: '/pagesSubject/video/list?id=' + this.id,
|
||||||
|
};
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
change(d){
|
getIsUser() {
|
||||||
this.current=d;
|
newsApi.ifUserMember(this, {}).then(res => {
|
||||||
|
//0 不是会员
|
||||||
|
console.log(res);
|
||||||
|
this.vip = res.code;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
change(d) {
|
||||||
|
this.current = d;
|
||||||
},
|
},
|
||||||
getList() {
|
getList() {
|
||||||
newsApi.getViedoInfo(this, {
|
newsApi.getViedoInfo(this, {
|
||||||
@ -68,9 +86,25 @@
|
|||||||
this.info = res.data;
|
this.info = res.data;
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
openUrl(id) {
|
openUrl(item) {
|
||||||
|
console.log(this.vip);
|
||||||
|
if (this.vip == 0 && item.status == 1) {
|
||||||
|
uni.showModal({
|
||||||
|
title: '提示',
|
||||||
|
content: '请联系客服,购买会员!',
|
||||||
|
confirmText: '联系客服',
|
||||||
|
success: (res) => {
|
||||||
|
if (res.confirm) {
|
||||||
|
uni.makePhoneCall({
|
||||||
|
phoneNumber: '18903795988' //仅为示例
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: "/pagesSubject/video/info?id=" + id
|
url: "/pagesSubject/video/info?id=" + item.id
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -78,5 +112,13 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
button,
|
||||||
|
button::after {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
border: none;
|
||||||
|
outline: none;
|
||||||
|
border-radius: 0;
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
BIN
static/img/1.png
Normal file
BIN
static/img/1.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 5.1 KiB |
BIN
static/img/2.png
Normal file
BIN
static/img/2.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 5.3 KiB |
BIN
static/img/3.png
Normal file
BIN
static/img/3.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 6.9 KiB |
BIN
static/img/4.png
Normal file
BIN
static/img/4.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 5.2 KiB |
@ -10,7 +10,7 @@
|
|||||||
- 丰富的插件(关键词搜索、内容编辑、`latex` 公式等)
|
- 丰富的插件(关键词搜索、内容编辑、`latex` 公式等)
|
||||||
- 效率高、容错性强且轻量化
|
- 效率高、容错性强且轻量化
|
||||||
|
|
||||||
查看 [功能介绍](https://jin-yufeng.gitee.io/mp-html/#/overview/feature) 了解更多
|
查看 [功能介绍](https://jin-yufeng.github.io/mp-html/#/overview/feature) 了解更多
|
||||||
|
|
||||||
## 使用方法
|
## 使用方法
|
||||||
- `uni_modules` 方式
|
- `uni_modules` 方式
|
||||||
@ -84,13 +84,13 @@
|
|||||||
使用 *cli* 方式运行的项目,通过 *npm* 方式引入时,需要在 *vue.config.js* 中配置 *transpileDependencies*,详情可见 [#330](https://github.com/jin-yufeng/mp-html/issues/330#issuecomment-913617687)
|
使用 *cli* 方式运行的项目,通过 *npm* 方式引入时,需要在 *vue.config.js* 中配置 *transpileDependencies*,详情可见 [#330](https://github.com/jin-yufeng/mp-html/issues/330#issuecomment-913617687)
|
||||||
如果在 **nvue** 中使用还要将 `dist/uni-app/static` 目录下的内容拷贝到项目的 `static` 目录下,否则无法运行
|
如果在 **nvue** 中使用还要将 `dist/uni-app/static` 目录下的内容拷贝到项目的 `static` 目录下,否则无法运行
|
||||||
|
|
||||||
查看 [快速开始](https://jin-yufeng.gitee.io/mp-html/#/overview/quickstart) 了解更多
|
查看 [快速开始](https://jin-yufeng.github.io/mp-html/#/overview/quickstart) 了解更多
|
||||||
|
|
||||||
## 组件属性
|
## 组件属性
|
||||||
|
|
||||||
| 属性 | 类型 | 默认值 | 说明 |
|
| 属性 | 类型 | 默认值 | 说明 |
|
||||||
|:---:|:---:|:---:|---|
|
|:---:|:---:|:---:|---|
|
||||||
| container-style | String | | 容器的样式([2.1.0+](https://jin-yufeng.gitee.io/mp-html/#/changelog/changelog#v210)) |
|
| container-style | String | | 容器的样式([2.1.0+](https://jin-yufeng.github.io/mp-html/#/changelog/changelog#v210)) |
|
||||||
| content | String | | 用于渲染的 html 字符串 |
|
| content | String | | 用于渲染的 html 字符串 |
|
||||||
| copy-link | Boolean | true | 是否允许外部链接被点击时自动复制 |
|
| copy-link | Boolean | true | 是否允许外部链接被点击时自动复制 |
|
||||||
| domain | String | | 主域名(用于链接拼接) |
|
| domain | String | | 主域名(用于链接拼接) |
|
||||||
@ -106,7 +106,7 @@
|
|||||||
| tag-style | Object | | 设置标签的默认样式 |
|
| tag-style | Object | | 设置标签的默认样式 |
|
||||||
| use-anchor | Boolean | false | 是否使用锚点链接 |
|
| use-anchor | Boolean | false | 是否使用锚点链接 |
|
||||||
|
|
||||||
查看 [属性](https://jin-yufeng.gitee.io/mp-html/#/basic/prop) 了解更多
|
查看 [属性](https://jin-yufeng.github.io/mp-html/#/basic/prop) 了解更多
|
||||||
|
|
||||||
## 组件事件
|
## 组件事件
|
||||||
|
|
||||||
@ -119,7 +119,7 @@
|
|||||||
| linktap | 链接被点击时 |
|
| linktap | 链接被点击时 |
|
||||||
| play | 音视频播放时 |
|
| play | 音视频播放时 |
|
||||||
|
|
||||||
查看 [事件](https://jin-yufeng.gitee.io/mp-html/#/basic/event) 了解更多
|
查看 [事件](https://jin-yufeng.github.io/mp-html/#/basic/event) 了解更多
|
||||||
|
|
||||||
## api
|
## api
|
||||||
组件实例上提供了一些 `api` 方法可供调用
|
组件实例上提供了一些 `api` 方法可供调用
|
||||||
@ -132,10 +132,10 @@
|
|||||||
| getRect | 获取富文本内容的位置和大小 |
|
| getRect | 获取富文本内容的位置和大小 |
|
||||||
| setContent | 设置富文本内容 |
|
| setContent | 设置富文本内容 |
|
||||||
| imgList | 获取所有图片的数组 |
|
| imgList | 获取所有图片的数组 |
|
||||||
| pauseMedia | 暂停播放音视频([2.2.2+](https://jin-yufeng.gitee.io/mp-html/#/changelog/changelog#v222)) |
|
| pauseMedia | 暂停播放音视频([2.2.2+](https://jin-yufeng.github.io/mp-html/#/changelog/changelog#v222)) |
|
||||||
| setPlaybackRate | 设置音视频播放速率([2.4.0+](https://jin-yufeng.gitee.io/mp-html/#/changelog/changelog#v240)) |
|
| setPlaybackRate | 设置音视频播放速率([2.4.0+](https://jin-yufeng.github.io/mp-html/#/changelog/changelog#v240)) |
|
||||||
|
|
||||||
查看 [api](https://jin-yufeng.gitee.io/mp-html/#/advanced/api) 了解更多
|
查看 [api](https://jin-yufeng.github.io/mp-html/#/advanced/api) 了解更多
|
||||||
|
|
||||||
## 插件扩展
|
## 插件扩展
|
||||||
除基本功能外,本组件还提供了丰富的扩展,可按照需要选用
|
除基本功能外,本组件还提供了丰富的扩展,可按照需要选用
|
||||||
@ -167,7 +167,7 @@
|
|||||||
```
|
```
|
||||||
4. 拷贝 `dist/uni-app` 中的内容到项目根目录
|
4. 拷贝 `dist/uni-app` 中的内容到项目根目录
|
||||||
|
|
||||||
查看 [插件](https://jin-yufeng.gitee.io/mp-html/#/advanced/plugin) 了解更多
|
查看 [插件](https://jin-yufeng.github.io/mp-html/#/advanced/plugin) 了解更多
|
||||||
|
|
||||||
## 关于 nvue
|
## 关于 nvue
|
||||||
`nvue` 使用原生渲染,不支持部分 `css` 样式,为实现和 `html` 相同的效果,组件内部通过 `web-view` 进行渲染,性能上差于原生,根据 `weex` 官方建议,`web` 标签仅应用在非常规的降级场景。因此,如果通过原生的方式(如 `richtext`)能够满足需要,则不建议使用本组件,如果有较多的富文本内容,则可以直接使用 `vue` 页面
|
`nvue` 使用原生渲染,不支持部分 `css` 样式,为实现和 `html` 相同的效果,组件内部通过 `web-view` 进行渲染,性能上差于原生,根据 `weex` 官方建议,`web` 标签仅应用在非常规的降级场景。因此,如果通过原生的方式(如 `richtext`)能够满足需要,则不建议使用本组件,如果有较多的富文本内容,则可以直接使用 `vue` 页面
|
||||||
@ -178,11 +178,9 @@
|
|||||||
|
|
||||||
纯 `nvue` 模式下,[此问题](https://ask.dcloud.net.cn/question/119678) 修复前,不支持通过 `uni_modules` 引入,需要本地引入(将 [dist/uni-app](https://github.com/jin-yufeng/mp-html/tree/master/dist/uni-app) 中的内容拷贝到项目根目录下)
|
纯 `nvue` 模式下,[此问题](https://ask.dcloud.net.cn/question/119678) 修复前,不支持通过 `uni_modules` 引入,需要本地引入(将 [dist/uni-app](https://github.com/jin-yufeng/mp-html/tree/master/dist/uni-app) 中的内容拷贝到项目根目录下)
|
||||||
|
|
||||||
## 立即体验
|
|
||||||

|
|
||||||
|
|
||||||
## 问题反馈
|
## 问题反馈
|
||||||
遇到问题时,请先查阅 [常见问题](https://jin-yufeng.gitee.io/mp-html/#/question/faq) 和 [issue](https://github.com/jin-yufeng/mp-html/issues) 中是否已有相同的问题
|
遇到问题时,请先查阅 [常见问题](https://jin-yufeng.github.io/mp-html/#/question/faq) 和 [issue](https://github.com/jin-yufeng/mp-html/issues) 中是否已有相同的问题
|
||||||
可通过 [issue](https://github.com/jin-yufeng/mp-html/issues/new/choose) 、插件问答或发送邮件到 [mp_html@126.com](mailto:mp_html@126.com) 提问,不建议在评论区提问(不方便回复)
|
可通过 [issue](https://github.com/jin-yufeng/mp-html/issues/new/choose) 、插件问答或发送邮件到 [mp_html@126.com](mailto:mp_html@126.com) 提问,不建议在评论区提问(不方便回复)
|
||||||
提问请严格按照 [issue 模板](https://github.com/jin-yufeng/mp-html/issues/new/choose) ,描述清楚使用环境、`html` 内容或可复现的 `demo` 项目以及复现方式,对于 **描述不清**、**无法复现** 或重复的问题将不予回复
|
提问请严格按照 [issue 模板](https://github.com/jin-yufeng/mp-html/issues/new/choose) ,描述清楚使用环境、`html` 内容或可复现的 `demo` 项目以及复现方式,对于 **描述不清**、**无法复现** 或重复的问题将不予回复
|
||||||
|
|
||||||
@ -191,4 +189,4 @@
|
|||||||
群2(已满):`778239129`
|
群2(已满):`778239129`
|
||||||
群3:`960265313`
|
群3:`960265313`
|
||||||
|
|
||||||
查看 [问题反馈](https://jin-yufeng.gitee.io/mp-html/#/question/feedback) 了解更多
|
查看 [问题反馈](https://jin-yufeng.github.io/mp-html/#/question/feedback) 了解更多
|
||||||
|
@ -1,3 +1,9 @@
|
|||||||
|
## v2.5.1(2025-04-20)
|
||||||
|
1. `U` 适配鸿蒙 `APP` [详细](https://github.com/jin-yufeng/mp-html/issues/615)
|
||||||
|
2. `U` 微信小程序替换废弃 `api` `getSystemInfoSync` [详细](https://github.com/jin-yufeng/mp-html/issues/613)
|
||||||
|
3. `F` 修复了 `app` 端播放视频可能报错的问题 [详细](https://github.com/jin-yufeng/mp-html/issues/617)
|
||||||
|
4. `F` 修复了 `latex` 插件可能出现 `xxx can be used only in display mode` 的问题 [详细](https://github.com/jin-yufeng/mp-html/issues/632)
|
||||||
|
5. `F` 修复了 `uni-app` 包 `latex` 公式可能不显示的问题 [#599](https://github.com/jin-yufeng/mp-html/issues/599)、[#627](https://github.com/jin-yufeng/mp-html/issues/627)
|
||||||
## v2.5.0(2024-04-22)
|
## v2.5.0(2024-04-22)
|
||||||
1. `U` `play` 事件增加返回 `src` 等信息 [详细](https://github.com/jin-yufeng/mp-html/issues/526)
|
1. `U` `play` 事件增加返回 `src` 等信息 [详细](https://github.com/jin-yufeng/mp-html/issues/526)
|
||||||
2. `U` `preview-img` 属性支持设置为 `all` 开启 `base64` 图片预览 [详细](https://github.com/jin-yufeng/mp-html/issues/536)
|
2. `U` `preview-img` 属性支持设置为 `all` 开启 `base64` 图片预览 [详细](https://github.com/jin-yufeng/mp-html/issues/536)
|
||||||
|
@ -5,14 +5,14 @@
|
|||||||
<node v-else :childs="nodes" :opts="[lazyLoad,loadingImg,errorImg,showImgMenu,selectable]" name="span" />
|
<node v-else :childs="nodes" :opts="[lazyLoad,loadingImg,errorImg,showImgMenu,selectable]" name="span" />
|
||||||
<!-- #endif -->
|
<!-- #endif -->
|
||||||
<!-- #ifdef APP-PLUS-NVUE -->
|
<!-- #ifdef APP-PLUS-NVUE -->
|
||||||
<web-view ref="web" src="/static/app-plus/mp-html/local.html" :style="'margin-top:-2px;height:' + height + 'px'" @onPostMessage="_onMessage" />
|
<web-view ref="web" src="/uni_modules/mp-html/static/app-plus/mp-html/local.html" :style="'margin-top:-2px;height:' + height + 'px'" @onPostMessage="_onMessage" />
|
||||||
<!-- #endif -->
|
<!-- #endif -->
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
/**
|
/**
|
||||||
* mp-html v2.5.0
|
* mp-html v2.5.1
|
||||||
* @description 富文本组件
|
* @description 富文本组件
|
||||||
* @tutorial https://github.com/jin-yufeng/mp-html
|
* @tutorial https://github.com/jin-yufeng/mp-html
|
||||||
* @property {String} container-style 容器的样式
|
* @property {String} container-style 容器的样式
|
||||||
@ -41,8 +41,7 @@
|
|||||||
import node from './node/node'
|
import node from './node/node'
|
||||||
// #endif
|
// #endif
|
||||||
import Parser from './parser'
|
import Parser from './parser'
|
||||||
import latex from './latex/index.js'
|
const plugins=[]
|
||||||
const plugins=[latex,]
|
|
||||||
// #ifdef APP-PLUS-NVUE
|
// #ifdef APP-PLUS-NVUE
|
||||||
const dom = weex.requireModule('dom')
|
const dom = weex.requireModule('dom')
|
||||||
// #endif
|
// #endif
|
||||||
|
File diff suppressed because one or more lines are too long
@ -76,12 +76,19 @@ const config = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
const tagSelector={}
|
const tagSelector={}
|
||||||
const {
|
let windowWidth, system
|
||||||
windowWidth,
|
// #ifdef MP-WEIXIN
|
||||||
|
if (uni.canIUse('getWindowInfo')) {
|
||||||
|
windowWidth = uni.getWindowInfo().windowWidth
|
||||||
|
system = uni.getDeviceInfo().system
|
||||||
|
} else {
|
||||||
|
// #endif
|
||||||
|
const systemInfo = uni.getSystemInfoSync()
|
||||||
|
windowWidth = systemInfo.windowWidth
|
||||||
// #ifdef MP-WEIXIN
|
// #ifdef MP-WEIXIN
|
||||||
system
|
system = systemInfo.system
|
||||||
// #endif
|
}
|
||||||
} = uni.getSystemInfoSync()
|
// #endif
|
||||||
const blankChar = makeMap(' ,\r,\n,\t,\f')
|
const blankChar = makeMap(' ,\r,\n,\t,\f')
|
||||||
let idIndex = 0
|
let idIndex = 0
|
||||||
|
|
||||||
|
@ -1,76 +1,99 @@
|
|||||||
{
|
{
|
||||||
"id": "mp-html",
|
"id": "mp-html",
|
||||||
"displayName": "mp-html 富文本组件【全端支持,支持编辑、latex等扩展】",
|
"displayName": "mp-html 富文本组件【全端支持,支持编辑、latex等扩展】",
|
||||||
"version": "v2.5.0",
|
"version": "v2.5.1",
|
||||||
"description": "一个强大的富文本组件,高效轻量,功能丰富",
|
"description": "一个强大的富文本组件,高效轻量,功能丰富",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"富文本",
|
"富文本",
|
||||||
"编辑器",
|
"编辑器",
|
||||||
"html",
|
"html",
|
||||||
"rich-text",
|
"rich-text",
|
||||||
"editor"
|
"editor"
|
||||||
],
|
],
|
||||||
"repository": "https://github.com/jin-yufeng/mp-html",
|
"repository": "https://github.com/jin-yufeng/mp-html",
|
||||||
"dcloudext": {
|
"dcloudext": {
|
||||||
"sale": {
|
"sale": {
|
||||||
"regular": {
|
"regular": {
|
||||||
"price": "0.00"
|
"price": "0.00"
|
||||||
},
|
},
|
||||||
"sourcecode": {
|
"sourcecode": {
|
||||||
"price": "0.00"
|
"price": "0.00"
|
||||||
}
|
}
|
||||||
},
|
|
||||||
"contact": {
|
|
||||||
"qq": ""
|
|
||||||
},
|
|
||||||
"declaration": {
|
|
||||||
"ads": "无",
|
|
||||||
"data": "无",
|
|
||||||
"permissions": "无"
|
|
||||||
},
|
|
||||||
"npmurl": "https://www.npmjs.com/package/mp-html",
|
|
||||||
"type": "component-vue"
|
|
||||||
},
|
},
|
||||||
"uni_modules": {
|
"contact": {
|
||||||
"platforms": {
|
"qq": ""
|
||||||
"cloud": {
|
},
|
||||||
"tcb": "y",
|
"declaration": {
|
||||||
"aliyun": "y"
|
"ads": "无",
|
||||||
},
|
"data": "无",
|
||||||
"client": {
|
"permissions": "无"
|
||||||
"App": {
|
},
|
||||||
"app-vue": "y",
|
"npmurl": "https://www.npmjs.com/package/mp-html",
|
||||||
"app-nvue": "y"
|
"type": "component-vue",
|
||||||
},
|
"darkmode": "-",
|
||||||
"H5-mobile": {
|
"i18n": "-",
|
||||||
"Safari": "y",
|
"widescreen": "-"
|
||||||
"Android Browser": "y",
|
},
|
||||||
"微信浏览器(Android)": "y",
|
"uni_modules": {
|
||||||
"QQ浏览器(Android)": "y"
|
"platforms": {
|
||||||
},
|
"cloud": {
|
||||||
"H5-pc": {
|
"tcb": "√",
|
||||||
"Chrome": "y",
|
"aliyun": "√",
|
||||||
"IE": "u",
|
"alipay": "x"
|
||||||
"Edge": "y",
|
},
|
||||||
"Firefox": "y",
|
"client": {
|
||||||
"Safari": "y"
|
"uni-app": {
|
||||||
},
|
"vue": {
|
||||||
"小程序": {
|
"vue2": "-",
|
||||||
"微信": "y",
|
"vue3": "-"
|
||||||
"阿里": "y",
|
},
|
||||||
"百度": "y",
|
"web": {
|
||||||
"字节跳动": "y",
|
"safari": "-",
|
||||||
"QQ": "y"
|
"chrome": "-"
|
||||||
},
|
},
|
||||||
"快应用": {
|
"app": {
|
||||||
"华为": "y",
|
"vue": "-",
|
||||||
"联盟": "y"
|
"nvue": "-",
|
||||||
},
|
"android": "-",
|
||||||
"Vue": {
|
"ios": "-",
|
||||||
"vue2": "y",
|
"harmony": "-"
|
||||||
"vue3": "y"
|
},
|
||||||
}
|
"mp": {
|
||||||
}
|
"weixin": "-",
|
||||||
|
"alipay": "-",
|
||||||
|
"toutiao": "-",
|
||||||
|
"baidu": "-",
|
||||||
|
"kuaishou": "-",
|
||||||
|
"jd": "-",
|
||||||
|
"harmony": "-",
|
||||||
|
"qq": "-",
|
||||||
|
"lark": "-"
|
||||||
|
},
|
||||||
|
"quickapp": {
|
||||||
|
"huawei": "-",
|
||||||
|
"union": "-"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"uni-app-x": {
|
||||||
|
"web": {
|
||||||
|
"safari": "-",
|
||||||
|
"chrome": "-"
|
||||||
|
},
|
||||||
|
"app": {
|
||||||
|
"android": "-",
|
||||||
|
"ios": "-",
|
||||||
|
"harmony": "-"
|
||||||
|
},
|
||||||
|
"mp": {
|
||||||
|
"weixin": "-"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"HBuilderX": "^3.1.0",
|
||||||
|
"uni-app": "^3.1.0",
|
||||||
|
"uni-app-x": "^3.1.0"
|
||||||
|
}
|
||||||
}
|
}
|
@ -1 +1 @@
|
|||||||
"use strict";function t(t){for(var e=Object.create(null),n=t.attributes.length;n--;)e[t.attributes[n].name]=t.attributes[n].value;return e}function e(){a[1]&&(this.src=a[1],this.onerror=null),this.onclick=null,this.ontouchstart=null,uni.postMessage({data:{action:"onError",source:"img",attrs:t(this)}})}function n(){window.unloadimgs-=1,0===window.unloadimgs&&uni.postMessage({data:{action:"onReady"}})}function o(r,s,c){for(var d=0;d<r.length;d++)!function(){var u,l=r[d];if(l.type&&"node"!==l.type)u=document.createTextNode(l.text.replace(/&/g,"&"));else{var g=l.name;"svg"===g&&(c="http://www.w3.org/2000/svg"),"html"!==g&&"body"!==g||(g="div"),u=c?document.createElementNS(c,g):document.createElement(g);for(var p in l.attrs)u.setAttribute(p,l.attrs[p]);if(l.children&&o(l.children,u,c),"img"===g){if(window.unloadimgs+=1,u.onload=n,u.onerror=n,!u.src&&u.getAttribute("data-src")&&(u.src=u.getAttribute("data-src")),l.attrs.ignore||(u.onclick=function(e){e.stopPropagation(),uni.postMessage({data:{action:"onImgTap",attrs:t(this)}})}),a[2]){var h=new Image;h.src=u.src,u.src=a[2],h.onload=function(){u.src=this.src},h.onerror=function(){u.onerror()}}u.onerror=e}else if("a"===g)u.addEventListener("click",function(e){e.stopPropagation(),e.preventDefault();var n,o=this.getAttribute("href");o&&"#"===o[0]&&(n=(document.getElementById(o.substr(1))||{}).offsetTop),uni.postMessage({data:{action:"onLinkTap",attrs:t(this),offset:n}})},!0);else if("video"===g||"audio"===g)i.push(u),l.attrs.autoplay||l.attrs.controls||u.setAttribute("controls","true"),u.onplay=function(){if(uni.postMessage({data:{action:"onPlay"}}),a[3])for(var t=0;t<i.length;t++)i[t]!==this&&i[t].pause()},u.onerror=function(){uni.postMessage({data:{action:"onError",source:g,attrs:t(this)}})};else if("table"===g&&a[4]&&!u.style.cssText.includes("inline")){var f=document.createElement("div");f.style.overflow="auto",f.appendChild(u),u=f}else"svg"===g&&(c=void 0)}s.appendChild(u)}()}document.addEventListener("UniAppJSBridgeReady",function(){document.body.onclick=function(){return uni.postMessage({data:{action:"onClick"}})},uni.postMessage({data:{action:"onJSBridgeReady"}})});var a,i=[];window.setContent=function(t,e,n){var r=document.getElementById("content");e[0]&&(document.body.style.cssText=e[0]),e[5]||(r.style.userSelect="none"),n||(r.innerHTML="",i=[]),a=e,window.unloadimgs=0;var s=document.createDocumentFragment();o(t,s),r.appendChild(s);var c=r.scrollHeight;uni.postMessage({data:{action:"onLoad",height:c}}),window.unloadimgs||uni.postMessage({data:{action:"onReady",height:c}}),clearInterval(window.timer),window.timer=setInterval(function(){r.scrollHeight!==c&&(c=r.scrollHeight,uni.postMessage({data:{action:"onHeightChange",height:c}}))},350)},window.onunload=function(){clearInterval(window.timer)};
|
"use strict";function t(t){for(var e=Object.create(null),n=t.attributes.length;n--;)e[t.attributes[n].name]=t.attributes[n].value;return e}function e(){a[1]&&(this.src=a[1],this.onerror=null),this.onclick=null,this.ontouchstart=null,uni.postMessage({data:{action:"onError",source:"img",attrs:t(this)}})}function n(){window.unloadimgs-=1,0===window.unloadimgs&&uni.postMessage({data:{action:"onReady"}})}function o(r,s,c){for(var d=0;d<r.length;d++)!function(d){var u=r[d],l=void 0;if(u.type&&"node"!==u.type)l=document.createTextNode(u.text.replace(/&/g,"&"));else{var g=u.name;"svg"===g&&(c="http://www.w3.org/2000/svg"),"html"!==g&&"body"!==g||(g="div"),l=c?document.createElementNS(c,g):document.createElement(g);for(var p in u.attrs)l.setAttribute(p,u.attrs[p]);if(u.children&&o(u.children,l,c),"img"===g){if(window.unloadimgs+=1,l.onload=n,l.onerror=n,!l.src&&l.getAttribute("data-src")&&(l.src=l.getAttribute("data-src")),u.attrs.ignore||(l.onclick=function(e){e.stopPropagation(),uni.postMessage({data:{action:"onImgTap",attrs:t(this)}})}),a[2]){var h=new Image;h.src=l.src,l.src=a[2],h.onload=function(){l.src=this.src},h.onerror=function(){l.onerror()}}l.onerror=e}else if("a"===g)l.addEventListener("click",function(e){e.stopPropagation(),e.preventDefault();var n,o=this.getAttribute("href");o&&"#"===o[0]&&(n=(document.getElementById(o.substr(1))||{}).offsetTop),uni.postMessage({data:{action:"onLinkTap",attrs:t(this),offset:n}})},!0);else if("video"===g||"audio"===g)i.push(l),u.attrs.autoplay||u.attrs.controls||l.setAttribute("controls","true"),l.onplay=function(){if(uni.postMessage({data:{action:"onPlay"}}),a[3])for(var t=0;t<i.length;t++)i[t]!==this&&i[t].pause()},l.onerror=function(){uni.postMessage({data:{action:"onError",source:g,attrs:t(this)}})};else if("table"===g&&a[4]&&!l.style.cssText.includes("inline")){var f=document.createElement("div");f.style.overflow="auto",f.appendChild(l),l=f}else"svg"===g&&(c=void 0)}s.appendChild(l)}(d)}document.addEventListener("UniAppJSBridgeReady",function(){document.body.onclick=function(){return uni.postMessage({data:{action:"onClick"}})},uni.postMessage({data:{action:"onJSBridgeReady"}})});var a,i=[];window.setContent=function(t,e,n){var r=document.getElementById("content");e[0]&&(document.body.style.cssText=e[0]),e[5]||(r.style.userSelect="none"),n||(r.innerHTML="",i=[]),a=e,window.unloadimgs=0;var s=document.createDocumentFragment();o(t,s),r.appendChild(s);var c=r.scrollHeight;uni.postMessage({data:{action:"onLoad",height:c}}),window.unloadimgs||uni.postMessage({data:{action:"onReady",height:c}}),clearInterval(window.timer),window.timer=setInterval(function(){r.scrollHeight!==c&&(c=r.scrollHeight,uni.postMessage({data:{action:"onHeightChange",height:c}}))},350)},window.onunload=function(){clearInterval(window.timer)};
|
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user