Merge branch 'xie1023'
This commit is contained in:
4
main.js
4
main.js
@@ -10,7 +10,9 @@ Vue.prototype.$bgm = bgm
|
|||||||
// Vue.prototype.$baseUrl = "http://192.168.110.100:9100/pb/"
|
// Vue.prototype.$baseUrl = "http://192.168.110.100:9100/pb/"
|
||||||
// Vue.prototype.$baseUrl = "http://59.110.212.44:9100/pb/"
|
// Vue.prototype.$baseUrl = "http://59.110.212.44:9100/pb/"
|
||||||
Vue.prototype.$baseUrl = "https://api.nuttyreading.com/"
|
Vue.prototype.$baseUrl = "https://api.nuttyreading.com/"
|
||||||
|
// 安卓安卓包下载地址
|
||||||
|
// Vue.prototype.$apkUrl = "https://www.nuttyreading.com/nuttyreading.apk"
|
||||||
|
Vue.prototype.$apkUrl = "https://www.nuttyreading.com/nuttyreading.apk"
|
||||||
|
|
||||||
|
|
||||||
// uView组件库
|
// uView组件库
|
||||||
|
|||||||
@@ -66,6 +66,10 @@
|
|||||||
mode="aspectFit"></image>
|
mode="aspectFit"></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="txt" v-if="taskInfo.content" v-html="taskInfo.content"></view>
|
<view class="txt" v-if="taskInfo.content" v-html="taskInfo.content"></view>
|
||||||
|
<view class="share flexbox" @click="newOnShare()" v-if="isAndorid">
|
||||||
|
<text>分享</text>
|
||||||
|
<image src="/static/share.png" class="per_mes_img" style="width: 40rpx; height: 40rpx; "></image>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-else>
|
<view v-else>
|
||||||
<u-divider text="今天未发布打卡任务"></u-divider>
|
<u-divider text="今天未发布打卡任务"></u-divider>
|
||||||
@@ -176,6 +180,10 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
<!-- 分享弹窗 -->
|
||||||
|
<uni-popup ref="share" type="share" safeArea backgroundColor="#fff">
|
||||||
|
<uni-popup-share @select="haveSelected"></uni-popup-share>
|
||||||
|
</uni-popup>
|
||||||
<!-- 回复评论弹窗 -->
|
<!-- 回复评论弹窗 -->
|
||||||
<u-popup mode="bottom" :show="pinglunShow" :round="10" @close="pinglunShow=false">
|
<u-popup mode="bottom" :show="pinglunShow" :round="10" @close="pinglunShow=false">
|
||||||
<view class="tanchu">
|
<view class="tanchu">
|
||||||
@@ -273,6 +281,7 @@
|
|||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
isAndorid:true,
|
||||||
opPinglun: {}, // 针对的评论对象
|
opPinglun: {}, // 针对的评论对象
|
||||||
pinglunShow: false,
|
pinglunShow: false,
|
||||||
placeholder: '开始输入...',
|
placeholder: '开始输入...',
|
||||||
@@ -343,6 +352,7 @@
|
|||||||
onLoad(e) {
|
onLoad(e) {
|
||||||
this.bookid = e.bookid
|
this.bookid = e.bookid
|
||||||
this.windowWidth = uni.getSystemInfoSync().windowWidth;
|
this.windowWidth = uni.getSystemInfoSync().windowWidth;
|
||||||
|
this.getOS()
|
||||||
},
|
},
|
||||||
onPullDownRefresh() {
|
onPullDownRefresh() {
|
||||||
console.log('下拉刷新了')
|
console.log('下拉刷新了')
|
||||||
@@ -365,11 +375,66 @@
|
|||||||
...mapState(['userInfo'])
|
...mapState(['userInfo'])
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 获得操作系统
|
||||||
|
getOS(){
|
||||||
|
let oprateOs = ''
|
||||||
|
oprateOs = uni.getSystemInfoSync().platform
|
||||||
|
// console.log(oprateOs)
|
||||||
|
if(oprateOs == 'android'){
|
||||||
|
this.isAndorid = true
|
||||||
|
}else{
|
||||||
|
this.isAndorid = false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
haveSelected(data){
|
||||||
|
let image = ''
|
||||||
|
this.taskInfo.image && this.taskInfo.image != '' ? image = this.taskInfo.image : image = 'static/fengziIcon.jpg'
|
||||||
|
console.log(data,' 选择的是')
|
||||||
|
if(data.index == 0){
|
||||||
|
// 分享到好友
|
||||||
|
uni.share({
|
||||||
|
provider: "weixin",
|
||||||
|
scene: "WXSceneSession",
|
||||||
|
type: 0,
|
||||||
|
href: this.$apkUrl,
|
||||||
|
title: `我正在参与疯子读书读书打卡:${this.taskInfo.title}`,
|
||||||
|
summary: `${this.taskInfo.content}`,
|
||||||
|
imageUrl: image,
|
||||||
|
success: function (res) {
|
||||||
|
console.log("success:" + JSON.stringify(res));
|
||||||
|
},
|
||||||
|
fail: function (err) {
|
||||||
|
console.log("fail:" + JSON.stringify(err));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}else if(data.index == 1){
|
||||||
|
// 分享到朋友圈
|
||||||
|
uni.share({
|
||||||
|
provider: "weixin",
|
||||||
|
scene: "WXSceneTimeline",
|
||||||
|
type: 0,
|
||||||
|
href: this.$apkUrl,
|
||||||
|
title: `我正在参与疯子读书读书打卡:${this.taskInfo.title}`,
|
||||||
|
summary: `${this.taskInfo.content}`,
|
||||||
|
imageUrl: image,
|
||||||
|
success: function (res) {
|
||||||
|
console.log("success:" + JSON.stringify(res));
|
||||||
|
},
|
||||||
|
fail: function (err) {
|
||||||
|
console.log("fail:" + JSON.stringify(err));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 新写分享
|
||||||
|
newOnShare(){
|
||||||
|
this.$refs.share.open()
|
||||||
|
},
|
||||||
showPingLun(item) {
|
showPingLun(item) {
|
||||||
// 回复评论
|
// 回复评论
|
||||||
this.opPinglun = item
|
this.opPinglun = item
|
||||||
this.pinglunShow = true
|
this.pinglunShow = true
|
||||||
console.log('item45456', this.opPinglun)
|
// console.log('item45456', this.opPinglun)
|
||||||
},
|
},
|
||||||
onEditorReady() {
|
onEditorReady() {
|
||||||
// #ifdef MP-BAIDU
|
// #ifdef MP-BAIDU
|
||||||
@@ -918,6 +983,9 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
.share{font-size: 28rpx; float: right; padding-bottom:20rpx ;
|
||||||
|
.per_mes_img{width: 40rpx; height: 40rpx; margin-left: 10rpx;}
|
||||||
|
}
|
||||||
.pingjiaBox {
|
.pingjiaBox {
|
||||||
margin-bottom: 20rpx;
|
margin-bottom: 20rpx;
|
||||||
}
|
}
|
||||||
@@ -1332,7 +1400,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.txt {
|
.txt {
|
||||||
font-size: 24rpx;
|
font-size: 28rpx;
|
||||||
margin-top: 30rpx;
|
margin-top: 30rpx;
|
||||||
color: #666;
|
color: #666;
|
||||||
line-height: 50rpx;
|
line-height: 50rpx;
|
||||||
|
|||||||
@@ -179,7 +179,7 @@
|
|||||||
provider: "weixin",
|
provider: "weixin",
|
||||||
scene: "WXSceneSession",
|
scene: "WXSceneSession",
|
||||||
type: 0,
|
type: 0,
|
||||||
href: "https://www.nuttyreading.com/nuttyreading.apk",
|
href: this.$apkUrl,
|
||||||
title: "疯子读书",
|
title: "疯子读书",
|
||||||
summary: "我正在使用疯子读书提升自己,赶紧跟我一起来体验吧!",
|
summary: "我正在使用疯子读书提升自己,赶紧跟我一起来体验吧!",
|
||||||
imageUrl: "static/fengziIcon.jpg",
|
imageUrl: "static/fengziIcon.jpg",
|
||||||
@@ -196,7 +196,7 @@
|
|||||||
provider: "weixin",
|
provider: "weixin",
|
||||||
scene: "WXSceneTimeline",
|
scene: "WXSceneTimeline",
|
||||||
type: 0,
|
type: 0,
|
||||||
href: "https://www.nuttyreading.com/nuttyreading.apk",
|
href: this.$apkUrl,
|
||||||
title: "疯子读书",
|
title: "疯子读书",
|
||||||
summary: "我正在使用疯子读书提升自己,赶紧跟我一起来体验吧!",
|
summary: "我正在使用疯子读书提升自己,赶紧跟我一起来体验吧!",
|
||||||
imageUrl: "static/fengziIcon.jpg",
|
imageUrl: "static/fengziIcon.jpg",
|
||||||
|
|||||||
BIN
static/b (1).png
Normal file
BIN
static/b (1).png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.5 KiB |
BIN
static/share.png
Normal file
BIN
static/share.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.9 KiB |
BIN
static/z (1).png
Normal file
BIN
static/z (1).png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.2 KiB |
Reference in New Issue
Block a user