diff --git a/jiuyi2/api/mine.js b/jiuyi2/api/mine.js index 62888e9c..04213df0 100644 --- a/jiuyi2/api/mine.js +++ b/jiuyi2/api/mine.js @@ -213,7 +213,6 @@ const mine = { * @param {Object} param */ alipayPay(param) { - console.log('alipayPay',param) return util.request({ url: '/user/alipay/recharge', query: param.query, diff --git a/jiuyi2/api/video.js b/jiuyi2/api/video.js index 3ed33e3c..778dda36 100644 --- a/jiuyi2/api/video.js +++ b/jiuyi2/api/video.js @@ -474,8 +474,9 @@ const video = { */ videoShare(param) { return util.request({ - url: `/home/videoShare`, + url: `/user/chat/single/sendVideo`, query: param.query, + data: param.data, method: 'POST', }) }, diff --git a/jiuyi2/common/js/config.js b/jiuyi2/common/js/config.js index 36cfa819..042767f3 100644 --- a/jiuyi2/common/js/config.js +++ b/jiuyi2/common/js/config.js @@ -7,6 +7,7 @@ const config = { // #endif // #ifndef H5 host: 'http://91f.xyz:8080', + // host: 'http://96w3gq.natappfree.cc', // #endif // 是否vivo显示 showVivo: true, diff --git a/jiuyi2/components/index/collectList.vue b/jiuyi2/components/index/collectList.vue index 705b19d8..69edcf10 100644 --- a/jiuyi2/components/index/collectList.vue +++ b/jiuyi2/components/index/collectList.vue @@ -29,7 +29,7 @@ // 数据 data: [], // 条数 - pageSize: 10, + pageSize: 20, // 页码 pageNum: 1, // 总数 @@ -190,6 +190,7 @@ // defineExpose({ + listProperty, getList, getMoreList, refrshList, diff --git a/jiuyi2/manifest.json b/jiuyi2/manifest.json index f1d688fc..058e5ea3 100644 --- a/jiuyi2/manifest.json +++ b/jiuyi2/manifest.json @@ -2,8 +2,8 @@ "name" : "九亿", "appid" : "__UNI__08B31BC", "description" : "", - "versionName" : "1.0.16", - "versionCode" : 1016, + "versionName" : "1.0.17", + "versionCode" : 1017, "transformPx" : false, /* 5+App特有相关 */ "app-plus" : { diff --git a/jiuyi2/pages/index/dataCenter/pushVideoCollects.vue b/jiuyi2/pages/index/dataCenter/pushVideoCollects.vue index d16e1ec7..0520cab1 100644 --- a/jiuyi2/pages/index/dataCenter/pushVideoCollects.vue +++ b/jiuyi2/pages/index/dataCenter/pushVideoCollects.vue @@ -66,9 +66,9 @@ // 获取收藏夹下的视频 function getList() { // - api.video.getCollectVideoList({ + api.video.getFavoriteVideo({ query: { - collectId: collects.value.id, + folderId: collects.value.id, } }).then(rs => { if (rs.code == 200) { @@ -100,7 +100,7 @@ - + diff --git a/jiuyi2/pages/index/index.nvue b/jiuyi2/pages/index/index.nvue index 7ef7415a..d306c799 100644 --- a/jiuyi2/pages/index/index.nvue +++ b/jiuyi2/pages/index/index.nvue @@ -231,12 +231,12 @@ onHide(() => { // 上一个视频的id - const videoId = tabCurrent.value.listData()[current[tabIndex.value]].id + const videoItem = tabCurrent.value.listData()[current[tabIndex.value]] // 暂停视频 - if (videoId) { + if (videoItem && videoItem.id) { // 视频组件 - const VideoRef = proxy.$refs[`videoRef${videoId}`][0] + const VideoRef = proxy.$refs[`videoRef${videoItem.id}`][0] VideoRef.pause() // videoRefList[current[tabIndex.value]].pause() } diff --git a/jiuyi2/pages/index/wallet/topUp.vue b/jiuyi2/pages/index/wallet/topUp.vue index 9e34e5e7..c703dadf 100644 --- a/jiuyi2/pages/index/wallet/topUp.vue +++ b/jiuyi2/pages/index/wallet/topUp.vue @@ -27,17 +27,17 @@ name: '支付宝', provider: 'alipay', apiRequest: (event) => { - return api.mine.alipayPay(event) - } - }, - { - img: '/static/shop-weixin-pay.png', - name: '微信支付', - provider: 'wxpay', - apiRequest: (event) => { - return api.mine.wechatPay(event) + return handleAlipayPay(event) } }, + // { + // img: '/static/shop-weixin-pay.png', + // name: '微信支付', + // provider: 'wxpay', + // apiRequest: (event) => { + // return handleWeChat(event) + // } + // }, ]) // 支付列表下标 const paymentIndex = ref(0) @@ -70,44 +70,74 @@ // 调用支付 function handlePayment() { - const data = { - ...form - } - - if (!data.totalAmount) { + if (!form.totalAmount) { util.alert('金额不正确') return } // 调用支付方式 - payment.value.apiRequest({ + payment.value.apiRequest() + } + + // 支付宝支付 + function handleAlipayPay() { + api.mine.alipayPay({ query: { - ...data, + ...form, }, }).then(rs => { - console.log('payment rs', rs) - if (rs.code == 200) { - uni.requestPayment({ - provider: payment.value.provider, - // orderInfo: rs.data, - package: `prepay_id=${rs.data.prepayId}`, - success: rs => { - console.log('requestPayment', rs) - util.getPurse() - uni.navigateBack() - }, - fail: err => { - console.log('fail err', err) - } - }) - return - } - util.alert({ - content: rs.msg, - showCancel: false, + // 唤起支付 + callPayment({ + response: rs, + paymentParams: { + orderInfo: rs.msg, + }, }) }) } + + // 微信支付 + function handleWeChat() { + api.mine.wechatPay({ + query: { + ...form, + }, + }).then(rs => { + // 唤起支付 + callPayment({ + response: rs, + paymentParams: { + ...rs.data.msg, + }, + }) + }) + } + + /** + * 唤起支付 + * @param {Object} params + */ + function callPayment(params = {}) { + if (params.response.code == 200) { + uni.requestPayment({ + provider: payment.value.provider, + ...params.paymentParams, + success: rs => { + util.getPurse() + uni.navigateBack() + }, + fail: err => { + console.log('fail err', err) + } + }) + return + } + util.alert({ + content: params.response.msg, + showCancel: false, + }) + + }