Commit 1d858492 by suwenbiao

add msg

parent 6ba3955f
<script>
export default {
onLaunch() {
if (window.location.href.slice(window.location.href.indexOf('/', 10) + 1, 9999).length > 5 && window.location
if (window.location.href.slice(window.location.href.indexOf('/', 10) + 1, 9999).length > 35 && window.location
.href.slice(window.location.href.indexOf('/', 10) + 1, 9999).length < 55) {
var room_id = window.location.href.slice(window.location.href.indexOf('/', 10) + 1, 9999)
var reg1 = new RegExp("/", "g")
......@@ -10,7 +10,6 @@
room_id = room_id.replace(reg2, "")
uni.setStorageSync('room_id', room_id)
window.location.replace(window.location.href.slice(0, window.location.href.indexOf('/',10)))
}
},
onShow() {
......
......@@ -84,7 +84,7 @@
}
.font-14 {
font-size: 14rpx;
font-size: 28rpx;
}
.my-2 {
......
......@@ -12,12 +12,11 @@
<!-- <u-button style="margin: 0 0 0 20rpx;width: 20%;height: 70%;" text="发送" type="success" v-show="!inputFalg" touchend.prevent="send">
</u-button> -->
<button class="btn_send" text="发送" v-show="!inputFalg" @touchend.prevent="send">
发送</button>
发送</button>
<view class="icon" v-show="inputFalg">
<image v-for="(item,index) in imageList" :key="index+''" :src="item.url" style="width:68rpx" mode="widthFix"
@click="iconbtn(item.title)"></image>
</view>
<view class="icon-right" v-show="inputFalg">
<image class="iconright" v-for="(item,index) in imageListRight" :key="index+''" :src="item.url"
style="width:68rpx" mode="widthFix" @click="iconbtn(item.title)"></image>
......@@ -25,6 +24,7 @@
<!-- icontab -->
<component class="absolute" :is="currentTabComponent" @onClose="onClose" :show="show"
@specialShow="specialShow"></component>
<view class="exepress"></view>
</view>
</template>
......@@ -37,8 +37,8 @@
import shoplist from "./shopList/shoplist.vue"
import msg from "@/components/chat/chat.vue"
export default {
name: "foot",
components: {
......@@ -50,7 +50,7 @@
shoplist
},
created() {
},
data() {
return {
......@@ -95,7 +95,8 @@
title: "签到",
url: "../../static/images/签到@2x.png"
},
]
],
bqheight: 0,
};
},
methods: {
......@@ -105,17 +106,17 @@
type: 1,
sendText: this.value
}
this.$emit("sendmsg",obj)
this.$emit("sendmsg", obj)
this.value = ""
},
// 输入框聚焦事件
inputFocus() {
this.inputFalg = false
uni.onKeyboardHeightChange(res => {
console.log(res.height)
this.bqheight = res.height * 2
})
},
inputblur() {
inputblur() {
this.inputFalg = true
},
// 图标按钮点击事件
......@@ -154,6 +155,7 @@
specialShow(url) {
this.$emit("specialShow", url)
}
}
}
</script>
......@@ -163,6 +165,11 @@
position: absolute;
}
.exepress {
height: 200rpx;
background-color: #19be6b;
}
.content {
width: 100%;
display: flex;
......@@ -173,7 +180,8 @@
// width: 294rpx;
flex: 1;
}
.btn_send{
.btn_send {
margin: 0 0 0 20rpx;
width: 20%;
height: 70%;
......@@ -183,6 +191,7 @@
color: #fff;
outline: none;
}
.icon {
flex: 1;
text-align: right;
......
<template>
<u-overlay :show="show" class="flex">
<u-notify ref="uNotify" message=""></u-notify>
<view class="box flex flex-col">
<u-icon name="close" @click="close" class="icon" color="white" size="50"></u-icon>
<view class="content">
<view class="x-between flex">
<text class="money" v-for="item in moneyList" :key="item">{{item}}</text>
</view>
<u--input class="mt-2" inputAlign="center" style="background-color: white;" placeholder="请输入其他金额" border="surround" v-model="value" @change="change"></u--input>
<u--input class="mt-2" inputAlign="center" style="background-color: white;" placeholder="请输入其他金额"
border="surround" v-model="value"></u--input>
</view>
<text class="font-pay">支付</text>
<text class="font-pay" @click="pay_reward">支付</text>
</view>
</u-overlay>
</template>
......@@ -20,24 +22,81 @@
data() {
return {
moneyList: ["1元", "2元", "3元"],
value:""
value: ""
};
},
methods: {
close() {
this.$emit("onClose")
}
},
pay_reward() {
this.$api.createwxorder(this.value,'').then(res => {
console.log(res);
if (res.data.data.url) {
var num = res.data.data.orderNum
var parms = res.data.data.url
var jWeixin = require('jweixin-module')
jWeixin.config({
debug: false,
appId: parms.jsapiAppid,
timestamp: parms
.timeStamp, // 支付签名时间戳,注意微信 jssdk 中的所有使用 timestamp 字段均为小写。但最新版的支付后台生成签名使用的 timeStamp 字段名需大写其中的 S 字符
nonceStr: parms.nonceStr, // 支付签名随机串,不长于 32 位
package: parms.jsapipackage, // 统一支付接口返回的prepay_id参数值,提交格式如:prepay_id=\*\*\*)
signType: parms.signType, // 微信支付V3的传入 RSA ,微信支付V2的传入格式与V2统一下单的签名格式保持一致
paySign: parms.paySign, // 支付签名
});
jWeixin.chooseWXPay({
appId: parms.jsapiAppid,
timestamp: parms
.timeStamp, // 支付签名时间戳,注意微信 jssdk 中的所有使用 timestamp 字段均为小写。但最新版的支付后台生成签名使用的 timeStamp 字段名需大写其中的 S 字符
nonceStr: parms.nonceStr, // 支付签名随机串,不长于 32 位
package: parms.jsapipackage, // 统一支付接口返回的prepay_id参数值,提交格式如:prepay_id=\*\*\*)
signType: parms.signType, // 微信支付V3的传入 RSA ,微信支付V2的传入格式与V2统一下单的签名格式保持一致
paySign: parms.paySign, // 支付签名
success: function(e) {
that.$refs.uNotify.show({
top: 30,
type: 'success',
message: '支付成功',
duration: 1000 * 3,
fontSize: 20,
safeAreaInsetTop: true
})
that.$api.roomwatchytypeverifyPay(num).then(res => {
console.log(res);
})
setTimeout(() => {
location.reload()
}, 1500);
},
fail: function() {
that.$refs.uNotify.show({
top: 30,
type: 'error',
message: '支付失败',
duration: 1000 * 3,
fontSize: 20,
safeAreaInsetTop: true
})
},
});
}
})
},
}
}
</script>
<style lang="scss" scoped>
.mt-2{
.mt-2 {
margin-top: 24rpx;
}
.mt-5{
.mt-5 {
margin-top: 50rpx;
}
.flex {
display: flex;
justify-content: center;
......@@ -51,11 +110,13 @@
.x-between {
justify-content: space-between;
}
.icon{
.icon {
position: absolute;
top: 380rpx;
right: 150rpx;
}
.money {
display: inline-block;
width: 112rpx;
......@@ -66,12 +127,14 @@
border-radius: 10rpx;
text-align: center;
}
.font-pay{
.font-pay {
color: white;
font-size: 26rpx;
font-weight: bold;
transform: translate(0,50rpx);
transform: translate(0, 50rpx);
}
.box {
width: 560rpx;
height: 678rpx;
......
......@@ -145,8 +145,8 @@
title: "登录成功"
})
setTimeout(() => {
location.reload();
}, 1800);
window.location.reload();
}, 2000);
uni.setStorageSync("user_name", res.data.data.account);
uni.setStorageSync("user_headimg", res.data.data.avatar);
uni.setStorageSync("user_token", res.data.data.token);
......@@ -213,10 +213,6 @@
})
},
start() {},
//判断是否微信登录成功
wx_loginok() {
},
//发起登录
go_login() {
var local = window.location.href;
......
......@@ -3,7 +3,8 @@
{
"path": "pages/index/index",
"style": {
"navigationBarTitleText": "欧畅直播"
"navigationBarTitleText": "欧畅直播",
"app-plus":{"bounce":"none"}
}
}
],
......
......@@ -2,4 +2,4 @@
.supports('top: constant(a)'))
document.write(
'<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' +
(coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/static/index.2772579d.css><script src="http://pv.sohu.com/cityjson?ie=utf-8"></script><script src=https://static.oclive.cn/live.player_commons_5.2.js></script><link rel=stylesheet href=https://g.alicdn.com/de/prismplayer/2.9.19/skins/default/aliplayer-min.css><link href=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/tcplayer.min.css rel=stylesheet><script src=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/libs/TXLivePlayer-1.2.3.min.js></script><script src=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/libs/hls.min.1.1.5.js></script><script src=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/libs/flv.min.1.6.3.js></script><script src=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/tcplayer.v4.5.4.min.js></script><script src=//unpkg.byted-static.com/xgplayer/2.31.6/browser/index.js charset=utf-8></script><script src=//unpkg.byted-static.com/xgplayer-hls/2.5.2/dist/index.min.js charset=utf-8></script></head><body><div id=app></div><script src=/static/js/chunk-vendors.eceae362.js></script><script src=/static/js/index.0be919bd.js></script></body></html>
\ No newline at end of file
(coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/static/index.2772579d.css><script src="http://pv.sohu.com/cityjson?ie=utf-8"></script><script src=https://static.oclive.cn/live.player_commons_5.2.js></script><link rel=stylesheet href=https://g.alicdn.com/de/prismplayer/2.9.19/skins/default/aliplayer-min.css><link href=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/tcplayer.min.css rel=stylesheet><script src=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/libs/TXLivePlayer-1.2.3.min.js></script><script src=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/libs/hls.min.1.1.5.js></script><script src=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/libs/flv.min.1.6.3.js></script><script src=https://web.sdk.qcloud.com/player/tcplayer/release/v4.5.4/tcplayer.v4.5.4.min.js></script><script src=//unpkg.byted-static.com/xgplayer/2.31.6/browser/index.js charset=utf-8></script><script src=//unpkg.byted-static.com/xgplayer-hls/2.5.2/dist/index.min.js charset=utf-8></script></head><body><div id=app></div><script src=/static/js/chunk-vendors.eceae362.js></script><script src=/static/js/index.cdc6bf4e.js></script></body></html>
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment