合并代码

This commit is contained in:
sx 2025-01-02 00:59:24 +08:00
parent 849661cf00
commit 42ab006a83
9 changed files with 226 additions and 1166 deletions

View File

@ -225,7 +225,7 @@ const video = {
*/
publishVideo(param) {
return util.request({
url: `/homecommon/publishVideo`,
url: `/video/video/add`,
data: param.data,
method: 'POST',
})

View File

@ -60,7 +60,9 @@
},
})
//
const emit = defineEmits(['showTime', 'showComment', 'showCollect', 'showFastCollect', 'showShareFirend', 'onPlay', 'onPause', 'like', 'detailMenu', 'onEnd', 'longtap'])
const emit = defineEmits(['showTime', 'showComment', 'showCollect', 'showFastCollect', 'showShareFirend', 'onPlay',
'onPause', 'like', 'detailMenu', 'onEnd', 'longtap'
])
//
const videoCtx = ref(null)
@ -414,10 +416,15 @@
<view class="container f1 pr" ref="videoBoxRef">
<!-- 视频层 -->
<view class="main f1">
<view class="videoBox f1" @longpress="longtap" @touchmove.stop="" @touchstart="onTouchStart" @touchend="onTouchEnd" @touchcancel="onTouchEnd">
<view class="videoBox f1" @longpress="longtap" @touchmove.stop="" @touchstart="onTouchStart"
@touchend="onTouchEnd" @touchcancel="onTouchEnd">
<statusBar />
<video class="video f1" :id="'video' + tabIndex + index" :src="item.format_videoUrl" :poster="item.format_imageUrl" :http-cache="false" :show-fullscreen-btn="false" :enable-progress-gesture="false" :controls="false" @play="onVideoPlay" @pause="onVideoPause" :show-center-play-btn="false" @timeupdate="handleTimeupdate" @waiting="handleWaiting" :play-strategy="2" :initial-time="0" :loop="true" />
<video class="video f1" :id="'video' + tabIndex + index" :src="item.format_videoUrl"
:poster="item.format_imageUrl" :http-cache="false" :show-fullscreen-btn="false"
:enable-progress-gesture="false" :controls="false" @play="onVideoPlay" @pause="onVideoPause"
:show-center-play-btn="false" @timeupdate="handleTimeupdate" @waiting="handleWaiting"
:play-strategy="2" :loop="true" />
</view>
<!-- 视频进度条 -->
@ -454,10 +461,13 @@
<view class="item">
<view class="col">
<view class="pr">
<image class="wh50" src="/static/indexLike.png" mode="aspectFit" v-if="item.isLike == 0" @click="handleLike(index, 0)" @longpress="handlePrivateLike(index)" />
<image class="wh50" src="/static/indexLike1.png" mode="aspectFit" v-else-if="item.isLike == 1" @click="handleLike(index, 1)" />
<image class="wh50" src="/static/indexLike.png" mode="aspectFit" v-if="item.isLike == 0"
@click="handleLike(index, 0)" @longpress="handlePrivateLike(index)" />
<image class="wh50" src="/static/indexLike1.png" mode="aspectFit"
v-else-if="item.isLike == 1" @click="handleLike(index, 1)" />
<!-- 私密赞的图标 -->
<image class="wh50" src="/static/privateLike.png" mode="aspectFit" v-else-if="item.isLike == 3" @click="handleLike(index, 1)" />
<image class="wh50" src="/static/privateLike.png" mode="aspectFit"
v-else-if="item.isLike == 3" @click="handleLike(index, 1)" />
</view>
<view class="txt mt10">
<text class="text">{{ item.likes }}</text>
@ -478,7 +488,8 @@
<!-- 收藏 -->
<view class="item df fdr">
<view class="col" @touchstart="handleCollectStar" @touchend="handleCollectEnd" ref="collectBtn">
<image class="wh50" src="@/static/indexCollect1.png" mode="aspectFit" v-if="item.isCollect" />
<image class="wh50" src="@/static/indexCollect1.png" mode="aspectFit"
v-if="item.isCollect" />
<image class="wh50" src="@/static/indexCollect.png" mode="aspectFit" v-else />
<view class="txt mt10">
<text class="text">{{ item.collect }}</text>

View File

@ -1,185 +1,184 @@
{
"name" : "九亿",
"appid" : "__UNI__08B31BC",
"description" : "",
"versionName" : "1.0.2",
"versionCode" : 1002,
"transformPx" : false,
/* 5+App */
"app-plus" : {
"usingComponents" : true,
"nvueStyleCompiler" : "uni-app",
"compilerVersion" : 3,
"splashscreen" : {
"alwaysShowBeforeRender" : true,
"waiting" : true,
"autoclose" : true,
"delay" : 0
},
/* */
"modules" : {
"Camera" : {},
"Payment" : {},
"Share" : {},
"VideoPlayer" : {},
"Barcode" : {},
"Record" : {}
},
/* */
"distribute" : {
/* android */
"android" : {
"plugins" : [
{
"type" : "module",
"name" : "Agora-RTC-EngineModule",
"class" : "io.agora.rtc.uni.AgoraRtcEngineModule"
},
{
"type" : "module",
"name" : "Agora-RTC-ChannelModule",
"class" : "io.agora.rtc.uni.AgoraRtcChannelModule"
},
{
"type" : "component",
"name" : "Agora-RTC-SurfaceView",
"class" : "io.agora.rtc.uni.AgoraRtcSurfaceView"
},
{
"type" : "component",
"name" : "Agora-RTC-TextureView",
"class" : "io.agora.rtc.uni.AgoraRtcTextureView"
}
],
"permissions" : [
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
"<uses-feature android:name=\"android.hardware.camera\"/>",
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>",
"<uses-permission android:name=\"android.permission.RECORD_AUDIO\"/>"
],
"abiFilters" : [ "arm64-v8a" ],
"minSdkVersion" : 27,
"targetSdkVersion" : 31
},
/* ios */
"ios" : {
"dSYMs" : false,
"idfa" : false
},
/* SDK */
"sdkConfigs" : {
"payment" : {
"alipay" : {
"__platform__" : [ "ios", "android" ]
}
},
"share" : {},
"ad" : {},
"geolocation" : {},
"oauth" : {},
"push" : {},
"maps" : {}
},
"icons" : {
"android" : {
"hdpi" : "unpackage/res/icons/72x72.png",
"xhdpi" : "unpackage/res/icons/96x96.png",
"xxhdpi" : "unpackage/res/icons/144x144.png",
"xxxhdpi" : "unpackage/res/icons/192x192.png"
},
"ios" : {
"appstore" : "unpackage/res/icons/1024x1024.png",
"ipad" : {
"app" : "unpackage/res/icons/76x76.png",
"app@2x" : "unpackage/res/icons/152x152.png",
"notification" : "unpackage/res/icons/20x20.png",
"notification@2x" : "unpackage/res/icons/40x40.png",
"proapp@2x" : "unpackage/res/icons/167x167.png",
"settings" : "unpackage/res/icons/29x29.png",
"settings@2x" : "unpackage/res/icons/58x58.png",
"spotlight" : "unpackage/res/icons/40x40.png",
"spotlight@2x" : "unpackage/res/icons/80x80.png"
},
"iphone" : {
"app@2x" : "unpackage/res/icons/120x120.png",
"app@3x" : "unpackage/res/icons/180x180.png",
"notification@2x" : "unpackage/res/icons/40x40.png",
"notification@3x" : "unpackage/res/icons/60x60.png",
"settings@2x" : "unpackage/res/icons/58x58.png",
"settings@3x" : "unpackage/res/icons/87x87.png",
"spotlight@2x" : "unpackage/res/icons/80x80.png",
"spotlight@3x" : "unpackage/res/icons/120x120.png"
}
}
},
"splashscreen" : {
"useOriginalMsgbox" : true
}
},
"nativePlugins" : {
"HisignFaceLivePlugin" : {
"__plugin_info__" : {
"name" : "HisignFaceLive",
"description" : "鑫模态人脸活体检测移动版",
"platforms" : "Android,iOS",
"url" : "",
"android_package_name" : "",
"ios_bundle_id" : "",
"isCloud" : false,
"bought" : -1,
"pid" : "",
"parameters" : {}
}
},
"TencentCloud-TUICallKit" : {
"__plugin_info__" : {
"name" : "【官方】腾讯云音视频通话插件TencentCloud-TUICallKit",
"description" : "TUICallKit 是腾讯云官方推出的音视频通话插件,支持 1v1 通话和群组通话,并提供“类微信\"的 UI 交互,开发者仅需三个 API 就可实现。",
"platforms" : "Android,iOS",
"url" : "https://ext.dcloud.net.cn/plugin?id=9035",
"android_package_name" : "",
"ios_bundle_id" : "",
"isCloud" : true,
"bought" : 1,
"pid" : "9035",
"parameters" : {}
}
}
}
},
/* */
"quickapp" : {},
/* */
"mp-weixin" : {
"appid" : "",
"setting" : {
"urlCheck" : false
},
"usingComponents" : true
},
"mp-alipay" : {
"usingComponents" : true
},
"mp-baidu" : {
"usingComponents" : true
},
"mp-toutiao" : {
"usingComponents" : true
},
"uniStatistics" : {
"enable" : false
},
"vueVersion" : "3"
}
"name": "九亿",
"appid": "__UNI__08B31BC",
"description": "",
"versionName": "1.0.2",
"versionCode": 1002,
"transformPx": false,
/* 5+App */
"app-plus": {
"usingComponents": true,
"nvueStyleCompiler": "uni-app",
"compilerVersion": 3,
"splashscreen": {
"alwaysShowBeforeRender": true,
"waiting": true,
"autoclose": true,
"delay": 0
},
/* */
"modules": {
"Camera": {},
"Payment": {},
"Share": {},
"VideoPlayer": {},
"Barcode": {},
"Record": {}
},
/* */
"distribute": {
/* android */
"android": {
"plugins": [{
"type": "module",
"name": "Agora-RTC-EngineModule",
"class": "io.agora.rtc.uni.AgoraRtcEngineModule"
},
{
"type": "module",
"name": "Agora-RTC-ChannelModule",
"class": "io.agora.rtc.uni.AgoraRtcChannelModule"
},
{
"type": "component",
"name": "Agora-RTC-SurfaceView",
"class": "io.agora.rtc.uni.AgoraRtcSurfaceView"
},
{
"type": "component",
"name": "Agora-RTC-TextureView",
"class": "io.agora.rtc.uni.AgoraRtcTextureView"
}
],
"permissions": [
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
"<uses-feature android:name=\"android.hardware.camera\"/>",
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>",
"<uses-permission android:name=\"android.permission.RECORD_AUDIO\"/>"
],
"abiFilters": ["arm64-v8a"],
"minSdkVersion": 27,
"targetSdkVersion": 31
},
/* ios */
"ios": {
"dSYMs": false,
"idfa": false
},
/* SDK */
"sdkConfigs": {
"payment": {
"alipay": {
"__platform__": ["ios", "android"]
}
},
"share": {},
"ad": {},
"geolocation": {},
"oauth": {},
"push": {},
"maps": {}
},
"icons": {
"android": {
"hdpi": "unpackage/res/icons/72x72.png",
"xhdpi": "unpackage/res/icons/96x96.png",
"xxhdpi": "unpackage/res/icons/144x144.png",
"xxxhdpi": "unpackage/res/icons/192x192.png"
},
"ios": {
"appstore": "unpackage/res/icons/1024x1024.png",
"ipad": {
"app": "unpackage/res/icons/76x76.png",
"app@2x": "unpackage/res/icons/152x152.png",
"notification": "unpackage/res/icons/20x20.png",
"notification@2x": "unpackage/res/icons/40x40.png",
"proapp@2x": "unpackage/res/icons/167x167.png",
"settings": "unpackage/res/icons/29x29.png",
"settings@2x": "unpackage/res/icons/58x58.png",
"spotlight": "unpackage/res/icons/40x40.png",
"spotlight@2x": "unpackage/res/icons/80x80.png"
},
"iphone": {
"app@2x": "unpackage/res/icons/120x120.png",
"app@3x": "unpackage/res/icons/180x180.png",
"notification@2x": "unpackage/res/icons/40x40.png",
"notification@3x": "unpackage/res/icons/60x60.png",
"settings@2x": "unpackage/res/icons/58x58.png",
"settings@3x": "unpackage/res/icons/87x87.png",
"spotlight@2x": "unpackage/res/icons/80x80.png",
"spotlight@3x": "unpackage/res/icons/120x120.png"
}
}
},
"splashscreen": {
"useOriginalMsgbox": true
}
},
"nativePlugins": {
"HisignFaceLivePlugin": {
"__plugin_info__": {
"name": "HisignFaceLive",
"description": "鑫模态人脸活体检测移动版",
"platforms": "Android,iOS",
"url": "",
"android_package_name": "",
"ios_bundle_id": "",
"isCloud": false,
"bought": -1,
"pid": "",
"parameters": {}
}
},
"TencentCloud-TUICallKit": {
"__plugin_info__": {
"name": "【官方】腾讯云音视频通话插件TencentCloud-TUICallKit",
"description": "TUICallKit 是腾讯云官方推出的音视频通话插件,支持 1v1 通话和群组通话,并提供“类微信\"的 UI 交互,开发者仅需三个 API 就可实现。",
"platforms": "Android,iOS",
"url": "https://ext.dcloud.net.cn/plugin?id=9035",
"android_package_name": "",
"ios_bundle_id": "",
"isCloud": true,
"bought": 1,
"pid": "9035",
"parameters": {}
}
}
}
},
/* */
"quickapp": {},
/* */
"mp-weixin": {
"appid": "",
"setting": {
"urlCheck": false
},
"usingComponents": true
},
"mp-alipay": {
"usingComponents": true
},
"mp-baidu": {
"usingComponents": true
},
"mp-toutiao": {
"usingComponents": true
},
"uniStatistics": {
"enable": false
},
"vueVersion": "3"
}

View File

@ -329,7 +329,7 @@
function getRecList() {
Promise.all([getHomeVideo(), getShopVideo(), getOtherVideo()]).then(rs => {
// 列表
const list = rs.reduce((last, now) => last.concat(now.rows), []).sort(() => Math.random() - 0.5)
const list = rs.rows.sort(() => Math.random() - 0.5)
// 总数
recList.total = rs.reduce((last, now) => last + now.total, 0)
// 第一页
@ -352,7 +352,8 @@
const pages = getCurrentPages()
// 判断是否当前页
if (pages[pages.length - 1].route == 'pages/index/index') {
proxy.$refs[`videoRef${tabIndex.value}`][current[tabIndex.value]].playState.value = true
proxy.$refs[`videoRef${tabIndex.value}`][current[tabIndex.value]].playState.value =
true
proxy.$refs[`videoRef${tabIndex.value}`][current[tabIndex.value]].play()
}
}, 50)
@ -542,7 +543,8 @@
}
tabIndex.value = index
// 根据是否加载过判断 播放还是获取
if (tabCurrent.value.load && proxy.$refs[`videoRef${index}`]) proxy.$refs[`videoRef${index}`][current[index]].play()
if (tabCurrent.value.load && proxy.$refs[`videoRef${index}`]) proxy.$refs[`videoRef${index}`][current[index]]
.play()
else tabCurrent.value.getList()
// 已加载
tab[tabIndex.value].load = true
@ -729,7 +731,8 @@
<view class="f1">
<view class="tab fdr jcc" :key="tabIndex">
<view class="list" v-for="(item,index) in tab" :key="index" :class="[{'active': index === tabIndex}]" @click.stop="handle_tab(index)">
<view class="list" v-for="(item,index) in tab" :key="index"
:class="[{'active': index === tabIndex}]" @click.stop="handle_tab(index)">
<view class="txt">
<text class="text">{{item.name}}</text>
</view>
@ -752,10 +755,17 @@
<template v-for="(item, index) in tab" :key="index">
<view class="f1" v-if="tabIndex == index" ref="containerRef">
<!-- 主要内容区域 -->
<list class="container f1" :show-scrollbar="false" @touchstart="onTouchstart($event,index)" @touchend="onTouchend($event,index)" @loadmore="item.getMoreList">
<cell class="cell" :style="[{height: viewHeight + 'px'}]" :ref="`cellRef` + index" v-for="(secItem,secIndex) in item.listData()" :key="secIndex" @click.stop>
<list class="container f1" :show-scrollbar="false" @touchstart="onTouchstart($event,index)"
@touchend="onTouchend($event,index)" @loadmore="item.getMoreList">
<cell class="cell" :style="[{height: viewHeight + 'px'}]" :ref="`cellRef` + index"
v-for="(secItem,secIndex) in item.listData()" :key="secIndex" @click.stop>
<!-- 视频 -->
<indexVideo :ref="'videoRef' + index" :tabIndex="index" :current="current[index]" :item="secItem" :index="secIndex" @showTime="handleShowTime" @showComment="handleShowCommentAlt" @showCollect="handleShowCollectAlt" @showShareFirend="handleShowShareFirend" @onPlay="handleVideoOnPlay" @onPause="handleVideoOnPause" @like="videoLike" @longtap="$refs.moreMenuRef.open(secItem)" @showFastCollect="handleShowFastCollect" :viewWidth="viewWidth" />
<indexVideo :ref="'videoRef' + index" :tabIndex="index" :current="current[index]"
:item="secItem" :index="secIndex" @showTime="handleShowTime"
@showComment="handleShowCommentAlt" @showCollect="handleShowCollectAlt"
@showShareFirend="handleShowShareFirend" @onPlay="handleVideoOnPlay"
@onPause="handleVideoOnPause" @like="videoLike" @longtap="$refs.moreMenuRef.open(secItem)"
@showFastCollect="handleShowFastCollect" :viewWidth="viewWidth" />
</cell>
</list>
</view>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 47 KiB

BIN
jiuyi/static/statistics.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 473 B

View File

@ -1,37 +1,31 @@
{
"hash": "32d96953",
"configHash": "aa34cf93",
"hash": "37e93c97",
"configHash": "b5581361",
"lockfileHash": "6e88141a",
"browserHash": "f6042447",
"browserHash": "b2bb18f7",
"optimized": {
"@tencentcloud/chat": {
"src": "../../../../../node_modules/@tencentcloud/chat/index.js",
"file": "@tencentcloud_chat.js",
"fileHash": "b18fad8a",
"fileHash": "b054b652",
"needsInterop": true
},
"@tencentcloud/chat/modules/group-module.js": {
"src": "../../../../../node_modules/@tencentcloud/chat/modules/group-module.js",
"file": "@tencentcloud_chat_modules_group-module__js.js",
"fileHash": "70eaae39",
"fileHash": "bbe780a6",
"needsInterop": false
},
"tim-upload-plugin": {
"src": "../../../../../node_modules/tim-upload-plugin/index.js",
"file": "tim-upload-plugin.js",
"fileHash": "665b8e2f",
"fileHash": "11d142d1",
"needsInterop": true
},
"crypto-js": {
"src": "../../../../../node_modules/crypto-js/index.js",
"file": "crypto-js.js",
"fileHash": "f77d7150",
"needsInterop": true
},
"js-pinyin": {
"src": "../../../../../node_modules/js-pinyin/index.js",
"file": "js-pinyin.js",
"fileHash": "a2c07873",
"fileHash": "3cc1bed2",
"needsInterop": true
}
},

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long