Compare commits

...

4 Commits

Author SHA1 Message Date
lr 0e9104f253 客服 2025-02-28 22:22:37 +08:00
lr d4f75ca431 客服 2025-02-28 22:20:00 +08:00
sx 1fb340263b 2025.02.28 工作代码提交 2025-02-28 19:19:35 +08:00
sx ff3913769c 合并代码 2025-02-28 14:57:12 +08:00
14 changed files with 444 additions and 405 deletions

View File

@ -64,7 +64,7 @@ export const durian = {
},
/**
* 交易榴莲果
* 榴莲果挂买挂卖
* @param {Object} param
*/
consume(param) {
@ -96,5 +96,29 @@ export const durian = {
data: param.data,
})
},
/**
* 获取榴莲果交易列表
* @param {Object} param
*/
getOrderList(param) {
return util.request({
url: `/coreplay/app/durian/consume`,
method: 'POST',
data: param.data,
load: true,
})
},
/**
* 交易榴莲果
* @param {Object} param
*/
orderSale(param) {
return util.request({
url: `/coreplay/app/durian/consume`,
method: 'POST',
data: param.data,
load: true,
})
},
}
export default durian

View File

@ -6,7 +6,12 @@ const config = {
// host: 'h5api',
// #endif
// #ifndef H5
<<<<<<< HEAD
host: 'http://91f.xyz:8080',
// host: 'http://g8rbs6.natappfree.cc',
=======
host: 'http://91f.xyz:8080',
>>>>>>> 1fb340263bba19031e365ab883932f3f4c4806e3
// #endif
// 支付方式配置
payType: {

View File

@ -1,12 +1,12 @@
<script setup>
/**
/**
* 底部导航的规则
* 视频端显示
* 视频 商城 消息 我的(视频我的)
* 商城端显示
* 视频 商城 消息 个人中心(商城我的)
*/
import {
import {
ref,
computed,
onMounted,
@ -14,17 +14,17 @@ import {
getCurrentInstance,
reactive,
watch,
} from 'vue'
import {
} from 'vue'
import {
onLoad,
} from "@dcloudio/uni-app"
//
import util from '@/common/js/util';
const {
} from "@dcloudio/uni-app"
//
import util from '@/common/js/util';
const {
proxy
} = getCurrentInstance()
//
const props = defineProps({
} = getCurrentInstance()
//
const props = defineProps({
page: {
type: String,
},
@ -33,16 +33,16 @@ const props = defineProps({
type: String,
default: 'light',
},
})
//
const userinfo = computed(() => {
})
//
const userinfo = computed(() => {
let resuilt = uni.$store.state.userinfo
return resuilt
})
// shop default
const mode = computed(() => uni.$store.state.tabbarMode)
//
const menu = computed(() => {
})
// shop default
const mode = computed(() => uni.$store.state.tabbarMode)
//
const menu = computed(() => {
let arr = [{
page: 'index',
type: 'option',
@ -96,12 +96,12 @@ const menu = computed(() => {
break;
}
return arr
})
//
let safeHeight = ref(0)
})
//
let safeHeight = ref(0)
//
const showMenu = computed(() => {
//
const showMenu = computed(() => {
let result = []
//
@ -133,19 +133,17 @@ const showMenu = computed(() => {
// name: '',
// })
return result
})
})
//
const noReadNum = ref(0)
//
const noReadNum = ref(0)
const getReadNum = () => {
const getReadNum = () => {
getNoReadNum()
}
}
defineExpose({ getReadNum })
//
onMounted(() => {
//
onMounted(() => {
//
addListener()
// tabbar
@ -154,23 +152,21 @@ onMounted(() => {
uni.getSystemInfo().then(rs => {
safeHeight.value = rs.safeArea + 'px'
})
//
getNoReadNum()
//
// proxy.$refs.alert.open()
})
onLoad(() => {
//
getNoReadNum()
})
})
//
onUnmounted(() => {
//
onUnmounted(() => {
uni.$off('changeMine')
})
})
//
function addListener() {
//
function addListener() {
//
uni.$on('changeMine', (value) => {
uni.$store.commit('setState', {
@ -178,13 +174,13 @@ function addListener() {
value,
})
})
}
}
/**
/**
* 点击菜单
* @param {Object} item 当前点击的菜单项
*/
function handleMenu(item) {
function handleMenu(item) {
if (item.type != 'middle') {
//
if (item.page) uni.switchTab({
@ -198,13 +194,13 @@ function handleMenu(item) {
}
//
proxy.$refs.alert.open()
}
}
/**
/**
* 内容
* @param {Object} ev
*/
function handleAlert(ev) {
function handleAlert(ev) {
const index = ev.detail.index
const item = showMenu.value[index]
//
@ -220,15 +216,15 @@ function handleAlert(ev) {
})
//
proxy.$refs.alert.close()
}
}
//
function getNoReadNum() {
//
function getNoReadNum() {
if (userinfo.value.isRealName) {
// sdk
let isReady = uni.$chat.isReady();
if (!isReady) {
setTimeout(function () {
setTimeout(function() {
getNoReadNum();
}, 800);
return
@ -239,7 +235,11 @@ function getNoReadNum() {
noReadNum.value = +unreadCount > 99 ? '99+' : unreadCount;
// #endif
}
}
}
defineExpose({
getReadNum
})
</script>
<template>
@ -252,9 +252,10 @@ function getNoReadNum() {
<view class="option" :class="{ active: item.page === page }" v-if="item.type == 'option'">
<text class="text">{{ item.name }}</text>
<view class="pot" v-if="item.page == 'news' && noReadNum != 0">{{ noReadNum }}</view>
</view>
<text class="pot" v-if="item.page == 'news' && noReadNum != 0">{{ noReadNum }}</text>
<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/footerMenuPlus1.png" mode="aspectFit"
@ -290,15 +291,15 @@ function getNoReadNum() {
</template>
<style lang="scss">
$boderSize: 2rpx;
$boderSize: 2rpx;
//
.ghost {
//
.ghost {
height: 120rpx;
}
}
//
.menuBox {
//
.menuBox {
position: fixed;
left: 0;
right: 0;
@ -320,6 +321,7 @@ $boderSize: 2rpx;
.item {
/* #ifndef APP-NVUE */
position: relative;
display: flex;
/* #endif */
align-items: center;
@ -363,25 +365,32 @@ $boderSize: 2rpx;
.option {
position: relative;
z-index: 1;
}
//
.pot {
position: absolute;
top: -16rpx;
right: -30rpx;
height: 24rpx;
/* #ifndef APP-NVUE */
min-width: 24rpx;
display: flex;
flex-direction: column;
box-sizing: border-box;
/* #endif */
line-height: 24rpx;
border-radius: 24rpx;
/* #ifdef APP-NVUE */
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;
color: #fff;
font-size: 20rpx;
padding: 4rpx;
text-align: center;
z-index: 11;
}
}
.middle {
.img {
@ -389,10 +398,10 @@ $boderSize: 2rpx;
height: 80rpx;
}
}
}
}
//
.alert {
//
.alert {
margin-bottom: 120rpx;
background-color: #f8f8f8;
border-radius: 30rpx;
@ -406,5 +415,5 @@ $boderSize: 2rpx;
.itemBox {
// padding: 30rpx;
}
}
}
</style>

View File

@ -130,13 +130,11 @@
userId: userinfo.value.id,
// id
childrenParentId: reply.id || 0,
}
}).then(rs => {
console.log('saveComment', rs)
if (rs.code == 200) {
proxy.$refs.comment.close()
detail.comment++
//
refreshList()
setTimeout(() => {
@ -144,7 +142,10 @@
content.value = ''
}, 500)
//
uni.$emit('updateVideo', detail)
uni.$emit('updateVideo', {
...detail,
...rs.data,
})
return
}
util.alert({

View File

@ -474,7 +474,7 @@
if (isLong.value) return
play()
isLong.value = true
videoCtx.value.playbackRate(2)
videoCtx.value.playbackRate(1.5)
}
//
@ -509,6 +509,7 @@
<view class="main f1">
<view class="videoBox f1" @touchmove.stop="" @touchstart="onTouchStart" @touchend="onTouchEnd"
@touchcancel="onTouchCancel" @longpress="longtap">
<statusBar />
<!-- 视频 增加判断防止重复加载 -->
@ -530,7 +531,7 @@
<!-- 倍速播放提示 -->
<view class="speedBox" v-if="isLong">
<view class="speed ptb5 plr10">
<text class="f22 cfff">2倍速播放中...</text>
<text class="f22 cfff">1.5倍速播放中...</text>
</view>
</view>
@ -587,7 +588,8 @@
<!-- 只有公开赞显示点赞数 -->
<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>点赞</text>
</view>

View File

@ -53,7 +53,7 @@
function getDetail() {
api.shop.productDetail({
query: {
userId: userinfo.value.id,
userId: userinfo.value.id || '',
// id
productionId: proId.value
}

View File

@ -360,7 +360,7 @@ function handleDate(timestamp) {
<view class="mark pa t0 r0 cfff f22 cir" v-if="item.unreadCount">{{ item.unreadCount }}
</view>
</view>
<view class="col f1 ml20">
<view class="col oh f1 ml20">
<view class="rows">
<view class="name f1 thd c333 f32">{{ item.name }}</view>
<view class="datetime c999 f22">

View File

@ -228,8 +228,8 @@
const videoRefList = proxy.$refs[`videoRef${tabIndex.value}`]
// 暂停视频
if (videoRefList) {
// videoRefList[videoRefList.length - 2].pause()
videoRefList[current[tabIndex.value]].pause()
videoRefList[videoRefList.length - 2].pause()
// videoRefList[current[tabIndex.value]].pause()
}
})
@ -806,7 +806,7 @@
@touchend="onTouchend($event,index)" @loadmore="item.getMoreList">
<cell class="cell" :style="[{height: viewSize.height + 'px'}]" :ref="`cellRef` + index"
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]"
:width="viewSize.width" :height="viewSize.height" :item="secItem" :index="secIndex"
@ -815,7 +815,7 @@
@onPlay="handleVideoOnPlay" @onPause="handleVideoOnPause" @like="videoLike"
@longtap="$refs.moreMenuRef.open(secItem)" @showFastCollect="handleShowFastCollect"
@showProduct="handleShowProduct" @proBuy="handleProBuy" />
<!-- </template> -->
</template>
</cell>
</list>
</view>

View File

@ -55,21 +55,16 @@
})
//
const typeList = reactive([{
id: 1,
id: 9,
name: '挂买',
},
{
id: 2,
id: 8,
name: '挂卖',
}
])
//
const typeIndex = ref(0)
//
class Form {
sellNum = ''
totalPrice = ''
}
//
const form = reactive({
sellNum: '',
@ -206,11 +201,11 @@
//
function release() {
//
if (!form.fruitAmount) {
if (!form.sellNum) {
util.alert('请输入榴莲果数量')
return
}
if (!form.fruitAmount) {
if (!form.totalPrice) {
util.alert('请输入总价')
return
}
@ -240,9 +235,11 @@
// id
targetUserId: config[type].targetUserId,
//
transactionType: 10,
transactionType: typeList[typeIndex].id,
//
fruitAmount: form.fruitAmount,
fruitAmount: form.sellNum,
//
totalPrice:form.totalPrice,
//
name: `${form.first}${form.name}`,
//
@ -252,7 +249,6 @@
}
}).then(rs => {
if (rs.code === 200) {
//
util.getPurse()
return
}
@ -334,8 +330,8 @@
<view class="footer rows plr30 shadow bfff">
<view class="f28">我的资产</view>
<view class="f28 c666">
<text class="wsn">积分:{{purse.score}}</text>
<text class="wsn ml40">榴莲果:{{purse.fruit}}</text>
<text class="wsn">积分:{{(purse.score).toFixed(2)}}</text>
<text class="wsn ml40">榴莲果:{{(purse.fruit).toFixed(2)}}</text>
</view>
</view>

View File

@ -152,24 +152,24 @@ function handleReport() {
//
function handleBlack() {
// let text = detail.isBlock ? '' : ''
// util.alert({
// content: `${text}${detail.userNickname}`,
// }).then(rs => {
// let obj = {
// blockUserId: detail.id,
// status: detail.isBlock ? 1 : 0
// }
// api.mine.blockUser(obj).then(res => {
// if (res.code == 200) {
// util.alert('')
// getUserinfo()
let text = detail.isBlock ? '取消拉黑' : '拉黑'
util.alert({
content: `确认要${text}用户${detail.userNickname}吗?`,
}).then(rs => {
let obj = {
blockUserId: detail.id,
status: detail.isBlock ? 1 : 0
}
api.mine.blockUser(obj).then(res => {
if (res.code == 200) {
util.alert('操作成功!')
getUserinfo()
// //
// proxy.$refs.menuRef.close()
// }
// })
// })
//
proxy.$refs.menuRef.close()
}
})
})
}
//

View File

@ -59,15 +59,9 @@
//
const releasedLst = ref([])
//
const userinfo = computed(() => {
let result = store.state.userinfo || {}
return result
})
const userinfo = computed(() => store.state.userinfo || {})
//
const wallet = computed(() => {
let result = store.state.purse || {}
return result
})
const wallet = computed(() => store.state.purse || {})
onLoad(() => {
//
@ -190,7 +184,7 @@
<uni-icons type="right" color="" />
</view>
<view class="rows mtb30 ptb20 plr30 cfff f34 b000 br10">
<view class="rows mtb30 ptb20 plr30 cfff f34 b000 br10" v-if="userinfo.isShop == 1">
<text>商家明细</text>
<uni-icons type="right" c1olor="" />
</view>

View File

@ -50,17 +50,20 @@ function link(url) {
})
}
function toCustomer() {
let param = {};
param.type = 'C2C'
param.name = `${props.detail.merName}`
param.msgId = `${rs.data.serviceId}`
param.isCustomer = true
util.toChat(param)
uni.navigateTo({
url: util.setUrl('/pages/news/chat/chat', param)
url: util.setUrl('/pages/mine/setting/feedback')
})
// let param = {};
// param.type = 'C2C'
// param.name = `${props.detail.merName}`
// param.msgId = `${rs.data.serviceId}`
// param.isCustomer = true
// util.toChat(param)
// uni.navigateTo({
// url: util.setUrl('/pages/news/chat/chat', param)
// })
}
</script>

View File

@ -236,7 +236,7 @@ defineExpose({
</view>
<!-- 按钮区 -->
<view class="btns w150">
<view class="btns w180">
<view>
<view @click="handleCollectStore" class="btn sm warm fmid fdr plr30">
<uni-icons class="mr10" color="#fff" type="plusempty" size="13" v-if="detail.isFollow != 1" />

View File

@ -4,6 +4,11 @@ import {
import uni from '@dcloudio/vite-plugin-uni';
let target = 'http://91f.xyz:8080'
<<<<<<< HEAD
// let target = 'http://g8rbs6.natappfree.cc'
=======
>>>>>>> 1fb340263bba19031e365ab883932f3f4c4806e3
export default defineConfig({
plugins: [uni()],