2025.02.28 工作代码提交
This commit is contained in:
parent
ff3913769c
commit
1fb340263b
|
@ -142,8 +142,6 @@ const getReadNum = () => {
|
||||||
getNoReadNum()
|
getNoReadNum()
|
||||||
}
|
}
|
||||||
|
|
||||||
defineExpose({ getReadNum })
|
|
||||||
|
|
||||||
// 加载完成之后
|
// 加载完成之后
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
// 开启监听
|
// 开启监听
|
||||||
|
@ -154,15 +152,13 @@ onMounted(() => {
|
||||||
uni.getSystemInfo().then(rs => {
|
uni.getSystemInfo().then(rs => {
|
||||||
safeHeight.value = rs.safeArea + 'px'
|
safeHeight.value = rs.safeArea + 'px'
|
||||||
})
|
})
|
||||||
|
// 获取未读消息数量
|
||||||
|
getNoReadNum()
|
||||||
|
|
||||||
//
|
//
|
||||||
// proxy.$refs.alert.open()
|
// proxy.$refs.alert.open()
|
||||||
|
|
||||||
})
|
})
|
||||||
onLoad(() => {
|
|
||||||
// 获取未读消息数量
|
|
||||||
getNoReadNum()
|
|
||||||
})
|
|
||||||
|
|
||||||
// 卸载
|
// 卸载
|
||||||
onUnmounted(() => {
|
onUnmounted(() => {
|
||||||
|
@ -240,6 +236,10 @@ function getNoReadNum() {
|
||||||
// #endif
|
// #endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
getReadNum
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -252,9 +252,10 @@ function getNoReadNum() {
|
||||||
|
|
||||||
<view class="option" :class="{ active: item.page === page }" v-if="item.type == 'option'">
|
<view class="option" :class="{ active: item.page === page }" v-if="item.type == 'option'">
|
||||||
<text class="text">{{ item.name }}</text>
|
<text class="text">{{ item.name }}</text>
|
||||||
<view class="pot" v-if="item.page == 'news' && noReadNum != 0">{{ noReadNum }}</view>
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
<text class="pot" v-if="item.page == 'news' && noReadNum != 0">{{ noReadNum }}</text>
|
||||||
|
|
||||||
<view class="middle" v-else-if="item.type === 'middle'">
|
<view class="middle" v-else-if="item.type === 'middle'">
|
||||||
<image class="img" src="/static/footerMenuPlus.png" mode="aspectFit" v-if="subject == 'dark'" />
|
<image class="img" src="/static/footerMenuPlus.png" mode="aspectFit" v-if="subject == 'dark'" />
|
||||||
<image class="img" src="/static/footerMenuPlus1.png" mode="aspectFit"
|
<image class="img" src="/static/footerMenuPlus1.png" mode="aspectFit"
|
||||||
|
@ -320,6 +321,7 @@ $boderSize: 2rpx;
|
||||||
|
|
||||||
.item {
|
.item {
|
||||||
/* #ifndef APP-NVUE */
|
/* #ifndef APP-NVUE */
|
||||||
|
position: relative;
|
||||||
display: flex;
|
display: flex;
|
||||||
/* #endif */
|
/* #endif */
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
@ -363,25 +365,32 @@ $boderSize: 2rpx;
|
||||||
.option {
|
.option {
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 消息气泡
|
||||||
.pot {
|
.pot {
|
||||||
position: absolute;
|
|
||||||
top: -16rpx;
|
|
||||||
right: -30rpx;
|
|
||||||
height: 24rpx;
|
|
||||||
/* #ifndef APP-NVUE */
|
/* #ifndef APP-NVUE */
|
||||||
min-width: 24rpx;
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
box-sizing: border-box;
|
||||||
/* #endif */
|
/* #endif */
|
||||||
line-height: 24rpx;
|
/* #ifdef APP-NVUE */
|
||||||
border-radius: 24rpx;
|
line-height: 28rpx;
|
||||||
|
/* #endif */
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
position: absolute;
|
||||||
|
top: 5rpx;
|
||||||
|
right: 5rpx;
|
||||||
|
width: 28rpx;
|
||||||
|
height: 28rpx;
|
||||||
|
border-radius: 100rpx;
|
||||||
background: #FF6B17;
|
background: #FF6B17;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
font-size: 20rpx;
|
font-size: 20rpx;
|
||||||
padding: 4rpx;
|
|
||||||
text-align: center;
|
text-align: center;
|
||||||
z-index: 11;
|
z-index: 11;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
.middle {
|
.middle {
|
||||||
.img {
|
.img {
|
||||||
|
|
|
@ -130,13 +130,11 @@
|
||||||
userId: userinfo.value.id,
|
userId: userinfo.value.id,
|
||||||
// 评论的父id
|
// 评论的父id
|
||||||
childrenParentId: reply.id || 0,
|
childrenParentId: reply.id || 0,
|
||||||
|
|
||||||
}
|
}
|
||||||
}).then(rs => {
|
}).then(rs => {
|
||||||
console.log('saveComment', rs)
|
console.log('saveComment', rs)
|
||||||
if (rs.code == 200) {
|
if (rs.code == 200) {
|
||||||
proxy.$refs.comment.close()
|
proxy.$refs.comment.close()
|
||||||
detail.comment++
|
|
||||||
// 刷新列表
|
// 刷新列表
|
||||||
refreshList()
|
refreshList()
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
|
@ -144,7 +142,10 @@
|
||||||
content.value = ''
|
content.value = ''
|
||||||
}, 500)
|
}, 500)
|
||||||
// 修改被评论的视频数据
|
// 修改被评论的视频数据
|
||||||
uni.$emit('updateVideo', detail)
|
uni.$emit('updateVideo', {
|
||||||
|
...detail,
|
||||||
|
...rs.data,
|
||||||
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
util.alert({
|
util.alert({
|
||||||
|
|
|
@ -474,7 +474,7 @@
|
||||||
if (isLong.value) return
|
if (isLong.value) return
|
||||||
play()
|
play()
|
||||||
isLong.value = true
|
isLong.value = true
|
||||||
videoCtx.value.playbackRate(2)
|
videoCtx.value.playbackRate(1.5)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 前往数据中心
|
// 前往数据中心
|
||||||
|
@ -509,6 +509,7 @@
|
||||||
<view class="main f1">
|
<view class="main f1">
|
||||||
<view class="videoBox f1" @touchmove.stop="" @touchstart="onTouchStart" @touchend="onTouchEnd"
|
<view class="videoBox f1" @touchmove.stop="" @touchstart="onTouchStart" @touchend="onTouchEnd"
|
||||||
@touchcancel="onTouchCancel" @longpress="longtap">
|
@touchcancel="onTouchCancel" @longpress="longtap">
|
||||||
|
|
||||||
<statusBar />
|
<statusBar />
|
||||||
|
|
||||||
<!-- 视频 增加判断防止重复加载 -->
|
<!-- 视频 增加判断防止重复加载 -->
|
||||||
|
@ -530,7 +531,7 @@
|
||||||
<!-- 倍速播放提示 -->
|
<!-- 倍速播放提示 -->
|
||||||
<view class="speedBox" v-if="isLong">
|
<view class="speedBox" v-if="isLong">
|
||||||
<view class="speed ptb5 plr10">
|
<view class="speed ptb5 plr10">
|
||||||
<text class="f22 cfff">2倍速播放中...</text>
|
<text class="f22 cfff">1.5倍速播放中...</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
@ -587,7 +588,8 @@
|
||||||
|
|
||||||
<!-- 只有公开赞显示点赞数 -->
|
<!-- 只有公开赞显示点赞数 -->
|
||||||
<view class="txt mt10">
|
<view class="txt mt10">
|
||||||
<text class="text" v-if="item.isLike == 0 && item.likeType == 0">{{ item.likeCount }}</text>
|
<text class="text"
|
||||||
|
v-if="item.isLike == 0 && item.likeType == 0">{{ item.likeCount }}</text>
|
||||||
<text class="text" v-else-if="item.isLike == 0 && item.likeType == 1">隐私赞</text>
|
<text class="text" v-else-if="item.isLike == 0 && item.likeType == 1">隐私赞</text>
|
||||||
<text class="text" v-else>点赞</text>
|
<text class="text" v-else>点赞</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -53,7 +53,7 @@
|
||||||
function getDetail() {
|
function getDetail() {
|
||||||
api.shop.productDetail({
|
api.shop.productDetail({
|
||||||
query: {
|
query: {
|
||||||
userId: userinfo.value.id,
|
userId: userinfo.value.id || '',
|
||||||
// 产品id
|
// 产品id
|
||||||
productionId: proId.value
|
productionId: proId.value
|
||||||
}
|
}
|
||||||
|
|
|
@ -360,7 +360,7 @@ function handleDate(timestamp) {
|
||||||
<view class="mark pa t0 r0 cfff f22 cir" v-if="item.unreadCount">{{ item.unreadCount }}
|
<view class="mark pa t0 r0 cfff f22 cir" v-if="item.unreadCount">{{ item.unreadCount }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="col f1 ml20">
|
<view class="col oh f1 ml20">
|
||||||
<view class="rows">
|
<view class="rows">
|
||||||
<view class="name f1 thd c333 f32">{{ item.name }}</view>
|
<view class="name f1 thd c333 f32">{{ item.name }}</view>
|
||||||
<view class="datetime c999 f22">
|
<view class="datetime c999 f22">
|
||||||
|
|
|
@ -228,8 +228,8 @@
|
||||||
const videoRefList = proxy.$refs[`videoRef${tabIndex.value}`]
|
const videoRefList = proxy.$refs[`videoRef${tabIndex.value}`]
|
||||||
// 暂停视频
|
// 暂停视频
|
||||||
if (videoRefList) {
|
if (videoRefList) {
|
||||||
// videoRefList[videoRefList.length - 2].pause()
|
videoRefList[videoRefList.length - 2].pause()
|
||||||
videoRefList[current[tabIndex.value]].pause()
|
// videoRefList[current[tabIndex.value]].pause()
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -806,7 +806,7 @@
|
||||||
@touchend="onTouchend($event,index)" @loadmore="item.getMoreList">
|
@touchend="onTouchend($event,index)" @loadmore="item.getMoreList">
|
||||||
<cell class="cell" :style="[{height: viewSize.height + 'px'}]" :ref="`cellRef` + index"
|
<cell class="cell" :style="[{height: viewSize.height + 'px'}]" :ref="`cellRef` + index"
|
||||||
v-for="(secItem,secIndex) in item.listData()" :key="secItem.id" @click.stop>
|
v-for="(secItem,secIndex) in item.listData()" :key="secItem.id" @click.stop>
|
||||||
<!-- <template v-if="current[tabIndex] < secIndex + 2 && current[tabIndex] > secIndex - 2"> -->
|
<template v-if="current[tabIndex] < secIndex + 2 && current[tabIndex] > secIndex - 2">
|
||||||
<!-- 视频 -->
|
<!-- 视频 -->
|
||||||
<indexVideo :ref="'videoRef' + index" :tabIndex="index" :current="current[tabIndex]"
|
<indexVideo :ref="'videoRef' + index" :tabIndex="index" :current="current[tabIndex]"
|
||||||
:width="viewSize.width" :height="viewSize.height" :item="secItem" :index="secIndex"
|
:width="viewSize.width" :height="viewSize.height" :item="secItem" :index="secIndex"
|
||||||
|
@ -815,7 +815,7 @@
|
||||||
@onPlay="handleVideoOnPlay" @onPause="handleVideoOnPause" @like="videoLike"
|
@onPlay="handleVideoOnPlay" @onPause="handleVideoOnPause" @like="videoLike"
|
||||||
@longtap="$refs.moreMenuRef.open(secItem)" @showFastCollect="handleShowFastCollect"
|
@longtap="$refs.moreMenuRef.open(secItem)" @showFastCollect="handleShowFastCollect"
|
||||||
@showProduct="handleShowProduct" @proBuy="handleProBuy" />
|
@showProduct="handleShowProduct" @proBuy="handleProBuy" />
|
||||||
<!-- </template> -->
|
</template>
|
||||||
</cell>
|
</cell>
|
||||||
</list>
|
</list>
|
||||||
</view>
|
</view>
|
||||||
|
|
Loading…
Reference in New Issue