合并代码
This commit is contained in:
parent
f868a2eada
commit
c91f0f45b5
|
@ -100,7 +100,7 @@ const api = {
|
|||
},
|
||||
|
||||
/**
|
||||
* 获取未读消息数量
|
||||
* 获取app版本信息
|
||||
* @param {Object} param
|
||||
*/
|
||||
getAppVersion() {
|
||||
|
|
|
@ -52,6 +52,18 @@ const video = {
|
|||
})
|
||||
},
|
||||
|
||||
/**
|
||||
* 不喜欢视频
|
||||
* @param {Object} param
|
||||
*/
|
||||
disLike(param) {
|
||||
return util.request({
|
||||
url: `/video/videoDislike/disLike`,
|
||||
data: param.data,
|
||||
method: 'POST',
|
||||
})
|
||||
},
|
||||
|
||||
/**
|
||||
* 观看视频记录接口
|
||||
* @param {Object} param
|
||||
|
|
|
@ -6,9 +6,9 @@ const config = {
|
|||
// host: 'h5api',
|
||||
// #endif
|
||||
// #ifndef H5
|
||||
host: 'http://91f.xyz:8080',
|
||||
// host: 'http://liuyd.cpolar.top',
|
||||
// host: 'http://4fr983.natappfree.cc',
|
||||
// host: 'http://91f.xyz:8080',
|
||||
host: 'https://1e2a734e.r24.cpolar.top',
|
||||
// host: 'http://puys83.natappfree.cc',
|
||||
// #endif
|
||||
// 是否vivo显示
|
||||
showVivo: true,
|
||||
|
|
|
@ -631,12 +631,15 @@
|
|||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 分享 -->
|
||||
<!-- 更多 -->
|
||||
<view class="item" @click="handleShareFirend">
|
||||
<view class="col">
|
||||
<image class="wh50" src="@/static/indexShare.png" mode="aspectFit" />
|
||||
<view class="wh50 fmid tac">
|
||||
<uni-icons type="more-filled" color="#d8d8d8" size="64rpx" />
|
||||
<!-- <image class="wh50" src="@/static/indexShare.png" mode="aspectFit" /> -->
|
||||
</view>
|
||||
<view class="txt mt10">
|
||||
<text class="text">分享</text>
|
||||
<text class="text">更多</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
|
|
@ -24,11 +24,15 @@
|
|||
// 视频详情
|
||||
const videoItem = reactive({})
|
||||
// 用户信息
|
||||
const userinfo = computed(() => {
|
||||
let result = uni.$store.state.userinfo
|
||||
return result
|
||||
})
|
||||
const userinfo = computed(() => uni.$store.state.userinfo)
|
||||
|
||||
const props = defineProps({
|
||||
// 是否我自己 0不是 1是
|
||||
isMine: {
|
||||
type: [String, Number],
|
||||
default: 0,
|
||||
},
|
||||
})
|
||||
onMounted(() => {
|
||||
util.isLogin(() => {
|
||||
// 获取好友列表
|
||||
|
@ -121,6 +125,29 @@
|
|||
})
|
||||
}
|
||||
|
||||
// 不喜欢视频
|
||||
function handleDislike() {
|
||||
api.video.disLike({
|
||||
data: {
|
||||
// 视频id
|
||||
videoId: videoItem.id,
|
||||
// 用户昵称
|
||||
userId: userinfo.value.id || '',
|
||||
// 是否不喜欢
|
||||
isDislike: 0,
|
||||
}
|
||||
}).then(rs => {
|
||||
if (rs.code == 200) {
|
||||
util.alert(rs.msg)
|
||||
return
|
||||
}
|
||||
util.alert({
|
||||
content: rs.msg,
|
||||
showCancel: false,
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
//
|
||||
defineExpose({
|
||||
open,
|
||||
|
@ -131,7 +158,7 @@
|
|||
<template>
|
||||
<!-- 分享给朋友 -->
|
||||
<uni-popup ref="firend" type="bottom">
|
||||
<view class="shareBox popBot df fdc plr20 bfff">
|
||||
<view class="shareBox popBot df fdc plr20 pb20 bfff">
|
||||
<view class="header rows fdr">
|
||||
<view class="title mt40">
|
||||
<text class="f40">分享给朋友</text>
|
||||
|
@ -142,7 +169,7 @@
|
|||
</view>
|
||||
</view>
|
||||
|
||||
<view class="firendBox f1 df fdc mb30">
|
||||
<view class="firendBox f1 df fdc">
|
||||
<scroll-view scroll-y="true" class="scroll f1" :show-scrollbar="false">
|
||||
<view class="list df fdr" v-if="userList[0]">
|
||||
<view class="item aic" v-for="(item,index) in userList" :key="index" @click="handleShare(item)">
|
||||
|
@ -158,6 +185,13 @@
|
|||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
|
||||
<view class="menu df fdr mt20" v-if="userinfo.id">
|
||||
<view class="item mlr30" @click="handleDislike">
|
||||
<image class="icon wh100 cir" src="/static/dislike.png" mode="aspectFit" />
|
||||
<text class="text mt10 tac f24">不喜欢</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</template>
|
||||
|
@ -165,14 +199,12 @@
|
|||
<style lang="scss" scoped>
|
||||
// 分享盒子
|
||||
.shareBox {
|
||||
height: 600rpx;
|
||||
|
||||
//
|
||||
.firendBox {
|
||||
height: 100%;
|
||||
|
||||
.scroll {
|
||||
height: 500rpx;
|
||||
height: 450rpx;
|
||||
|
||||
//
|
||||
.list {
|
||||
|
@ -186,5 +218,15 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 菜单
|
||||
.menu {
|
||||
.item {
|
||||
|
||||
.text {
|
||||
//
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -33,7 +33,12 @@
|
|||
isMine: {
|
||||
type: [String, Number],
|
||||
default: 0,
|
||||
}
|
||||
},
|
||||
// 是否显示统计 0不显示 1显示
|
||||
statistic: {
|
||||
type: [String, Number],
|
||||
default: 0,
|
||||
},
|
||||
})
|
||||
// 子触发父
|
||||
const emit = defineEmits(['item'])
|
||||
|
@ -71,6 +76,7 @@
|
|||
url: util.setUrl('/pages/index/videoDetail', {
|
||||
videoId: item.id,
|
||||
isMine: props.isMine,
|
||||
statistic: props.statistic,
|
||||
})
|
||||
})
|
||||
// videoUrl.value = item.format_videoUrl
|
||||
|
|
|
@ -230,7 +230,7 @@
|
|||
})
|
||||
|
||||
onHide(() => {
|
||||
// 上一个视频的id
|
||||
// 当前视频
|
||||
const videoItem = tabCurrent.value.listData()[current[tabIndex.value]]
|
||||
|
||||
// 暂停视频
|
||||
|
@ -559,8 +559,10 @@
|
|||
*/
|
||||
function handleShowCommentAlt(item) {
|
||||
proxy.$refs.commentRef.open(item)
|
||||
// 当前视频
|
||||
const videoItem = tabCurrent.value.listData()[current[tabIndex.value]]
|
||||
// 暂停当前视频
|
||||
currentVideoRef.value.pause()
|
||||
proxy.$refs[`videoRef${videoItem.id}`][0].pause()
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -42,7 +42,7 @@
|
|||
// 是否是自己
|
||||
const isMine = ref(false)
|
||||
// 显示统计
|
||||
const statistic = ref('0')
|
||||
const statistic = ref(0)
|
||||
// 用户信息
|
||||
const userinfo = computed(() => uni.$store.state.userinfo)
|
||||
|
||||
|
@ -299,7 +299,7 @@
|
|||
<!-- 评论弹窗 -->
|
||||
<commentAlt ref="commentRef" />
|
||||
<!-- 收藏弹窗 -->
|
||||
<collectAlt ref="collectRef" />
|
||||
<collectAlt ref="collectRef" :isMine="isMine" />
|
||||
<!-- 分享到好友弹窗 -->
|
||||
<shareFirendAlt ref="shareFirendRef" />
|
||||
<!-- 产品详情弹窗 -->
|
||||
|
|
|
@ -30,14 +30,14 @@
|
|||
return handleAlipayPay(event)
|
||||
}
|
||||
},
|
||||
// {
|
||||
// img: '/static/shop-weixin-pay.png',
|
||||
// name: '微信支付',
|
||||
// provider: 'wxpay',
|
||||
// apiRequest: (event) => {
|
||||
// return handleWeChat(event)
|
||||
// }
|
||||
// },
|
||||
{
|
||||
img: '/static/shop-weixin-pay.png',
|
||||
name: '微信支付',
|
||||
provider: 'wxpay',
|
||||
apiRequest: (event) => {
|
||||
return handleWeChat(event)
|
||||
}
|
||||
},
|
||||
])
|
||||
// 支付列表下标
|
||||
const paymentIndex = ref(0)
|
||||
|
@ -103,11 +103,12 @@
|
|||
...form,
|
||||
},
|
||||
}).then(rs => {
|
||||
console.log('wechatPay', rs)
|
||||
// 唤起支付
|
||||
callPayment({
|
||||
response: rs,
|
||||
paymentParams: {
|
||||
...rs.data.msg,
|
||||
orderInfo: rs.data,
|
||||
},
|
||||
})
|
||||
})
|
||||
|
@ -119,6 +120,10 @@
|
|||
*/
|
||||
function callPayment(params = {}) {
|
||||
if (params.response.code == 200) {
|
||||
console.log('requestPayment', {
|
||||
provider: payment.value.provider,
|
||||
...params.paymentParams,
|
||||
})
|
||||
uni.requestPayment({
|
||||
provider: payment.value.provider,
|
||||
...params.paymentParams,
|
||||
|
@ -143,7 +148,6 @@
|
|||
<view class="appbw">
|
||||
<!-- -->
|
||||
<view class="form mtb30 mlr30">
|
||||
|
||||
<view class="line ptb20">
|
||||
<view class="key f36">充值金额</view>
|
||||
<view class="value mt10">
|
||||
|
@ -166,7 +170,6 @@
|
|||
</picker>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="footer plr30 shadow bfff">
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 3.7 KiB |
|
@ -3,9 +3,9 @@ import {
|
|||
} from 'vite';
|
||||
import uni from '@dcloudio/vite-plugin-uni';
|
||||
|
||||
let target = 'http://91f.xyz:8080'
|
||||
// let target = 'http://liuyd.cpolar.top'
|
||||
// let target = 'http://4fr983.natappfree.cc'
|
||||
// let target = 'http://91f.xyz:8080'
|
||||
let target = 'https://1e2a734e.r24.cpolar.top'
|
||||
// let target = 'http://192.168.31.61:8080'
|
||||
|
||||
export default defineConfig({
|
||||
plugins: [uni()],
|
||||
|
|
Loading…
Reference in New Issue