Commit 0f4def94 authored by mengqr's avatar mengqr

Merge branch 'master' of http://git.douniu8.com/mengqr/newlive

parents 3ccc9839 6706a7b8
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -4,7 +4,7 @@
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<meta name=”viewport” content=”width=device-width, initial-scale=1, maximum-scale=1″>
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
<script src="./static/js/mqttws31.js" type="text/javascript"></script>
<title>斗牛财经</title>
......
......@@ -76,7 +76,34 @@ live: {
},
buy_code:function(data){
return service.post('/wx/code', data)
}
},
//我的用户反馈文本
feedback:function(data){
return service.post('/feedback/text', data)
},
deal:function(data){
return service.post('/feedback/deal', data)
},
userCenter:function(data){
return service.post('/douniu/userCenter', data)
},
sigurature:function(data){
return service.post('/upload/sigurature/'+11, data)
},
followAnchor:function(data){
return service.post('/app/live/followAnchor', data)
},
getLiveHistory:function(data){
return service.post('/app/live/getLiveHistory', data)
},
getFollowAnchor:function(data){
return service.post('/app/live/getFollowAnchor', data)
},
......
......@@ -11,6 +11,12 @@ import VideoPlayer from 'vue-video-player'
import 'vue-video-player/src/custom-theme.css'
import common from '../static/js/common.js' //公共方法
import 'video.js/dist/video-js.css'
import VueClipboard from "vue-clipboard2";
//引入 hls,视频直播(m3u8)必须引入的
import 'videojs-contrib-hls'
......
......@@ -756,9 +756,12 @@ this.pten = false
this.ifFollow=res.data.data.followAnchor//关注主播状态
// res.data.data.seeDuration
localStorage.setItem('lvrUbId',this.lvrUbId);
let timer=res.data.data.seeDuration
console.log("萨芬", this.lvrUbId)
console.log(this.lvrUbId,'主播')
console.log("token",token)
console.log("头像",img)
if(token&&img){
......
......@@ -2,8 +2,10 @@
<div class="videoPlayer">
<!-- //分享卡片 -->
<share-card style=" z-index:99;" :headPortrait='udPhotoFileid' :udNickname='udNickname' :lvrName='lvrName' :lvrImgLargeUrl='lvrImgLargeUrl'> </share-card>
<!-- <img src="../assets/left.png" alt="" class="Lent_p" @click="go"> -->
<!-- <LivePlayer :videoUrl="url" /> -->
<div class='demo'>
<video-player class="video-player vjs-custom-skin"
ref="videoPlayer"
:playsinline="true"
......@@ -169,7 +171,7 @@
<div class="ov" :class="n==1?'active':''">
<div>
<img src="../assets/niu.png" alt="">
<span>金牛(账户余额:20金牛)</span>
<span>金牛(账户余额:{{dfNiubi}}金牛)</span>
</div>
<!--未选中-->
<img src="../assets/noxuanzhong.png" alt="" class="Ig" v-show="n != 1" @click="slect_one(1)">
......@@ -214,6 +216,7 @@
</div>
<div class="gr"><img src="../assets/login.png" alt="" class="Pl" @click="login_t"></div>
<img :src="'data:image/png;base64,'+ qrcodeSrc" alt="" >
</div>
......@@ -338,11 +341,14 @@ export default {
currentIndex:0,
isMobile: false,
wechatInfo:'',
ispay:'',
aliInfo:'',
//is_show_p:false //默认选中按钮隐藏
// orderType : 4, //pc浏览器环境
// orderType : 3, //h5环境
wxOrderType: this.common.isMobile() && this.common.isWX() ? 2 : (this.common.isMobile() ? 3 : 4),
zfbOrderType: this.common.isMobile() && this.common.isWX() ? 2 : (this.common.isMobile() ? 3 : 4),
};
},
......@@ -418,6 +424,10 @@ export default {
console.log('销毁成功')
},
methods: {
// go:function(){
// this.$router.push({name:'mine'})
// },
clickOpen(i){
if(i==1){
this.ifcli=true
......@@ -722,11 +732,12 @@ let temp=this.qs.stringify({
pmAppVersion: 868,
// applicationType: 3,
goodsType:3,
goodsId:429,//285
goodsId:285,//285 429
})
this.server.live.payinfo(temp).then(res=>{
this.udRealname=res.data.data.udRealname
this.text=res.data.data.text,
this.dfNiubi = res.data.data.dfNiubi,
this.Listfor =res.data.data.fees
// this.lvrStatus=res.data.data.lvrStatus
......@@ -738,7 +749,7 @@ let temp=this.qs.stringify({
// 订单
payorder(){
let temp=this.qs.stringify({
goodsId:429,
goodsId:285,
goodsType:3,
sxUbId:26,
pmoType:0,
......@@ -765,8 +776,105 @@ let temp=this.qs.stringify({
}else{
}
if(this.n ==1 ){
this.niubi()
}
if(this.n ==2 ){
this.paybuy()
}
if(this.n == 3){
this.z_pay()
}
}
})
},
niubi(){
//判断在微信内置浏览器jsapi支付
//jsapi
let temp=this.qs.stringify({
orderId:this.pmoId,
orderNo:this.pmoOrder,
payType:0,
orderType: this.zfbOrderType,
pmoType:0,
goodsType:3,
aliOrderType:1
})
this.server.live.buy(temp).then(res=>{
if(res.data.data.businessCode == 10){
alert('支付成功')
// window.location.href="/live"
}if(res.data.data.businessCode == 30){
alert('您已经购买,请查看')
}
this.aliInfo=res.data.data.aliInfo;
// this.wechatInfo=res.data.data.wechatInfo
//微信内置jsapi
if(this.wxOrderType == 2){
this.onBridgeReady();
}
//二维码
if(this.wxOrderType == 4){
//弹窗展示二维码
this.qrcodeSrc=res.data.data.wechatInfo.base64Img;
}
//移动端外部浏览器
if(this.wxOrderType == 3){
//跳转h5支付链接00 ll
// window.location.href=res.data.data.aliInfo;
}
})
},
//支付宝
z_pay(){
//判断在微信内置浏览器jsapi支付
//jsapi
let temp=this.qs.stringify({
orderId:this.pmoId,
orderNo:this.pmoOrder,
payType:2,
orderType: this.zfbOrderType,
pmoType:0,
goodsType:3,
aliOrderType:1
})
this.server.live.buy(temp).then(res=>{
this.aliInfo=res.data.data.aliInfo;
// this.wechatInfo=res.data.data.wechatInfo
//微信内置jsapi
if(this.wxOrderType == 2){
this.onBridgeReady();
}
//二维码
if(this.wxOrderType == 4){
//弹窗展示二维码
this.qrcodeSrc=res.data.data.wechatInfo.base64Img;
}
//移动端外部浏览器
if(this.wxOrderType == 3){
//跳转h5支付链接00 ll
window.location.href=res.data.data.aliInfo;
}
})
},
......@@ -793,6 +901,7 @@ let temp=this.qs.stringify({
this.qrcodeSrc=res.data.data.wechatInfo.base64Img;
this.wechatInfo=res.data.data.wechatInfo
//微信内置jsapi
if(this.wxOrderType == 2){
this.onBridgeReady();
......@@ -806,11 +915,13 @@ let temp=this.qs.stringify({
}
//移动端外部浏览器
if(this.wxOrderType == 3){
//跳转h5支付链接
//跳转h5支付链接00 ll
window.location.href=res.data.data.wechatInfo.payUrl
}
})
},
......@@ -857,6 +968,7 @@ let temp=this.qs.stringify({
},
slect_one(val){
this.n = val
},
pay_p(){
this.pten = true
......
<template>
<div class="abont">
<div>关于我们</div>
<img src="../../assets/left.png" alt="" class="Lent_p" @click="go">
<div class="abt">关于我们</div>
<img src="../../assets/about.png" alt="">
</div>
</template>
......@@ -16,6 +18,10 @@ export default {
this.beforeCreate()
},
methods: {
go:function(){
this.$router.push({name:'mine'})
},
beforeCreate () {
document.querySelector('body').setAttribute('style', 'background-color:rgba(247, 247, 247, 1);')
},
......@@ -37,5 +43,18 @@ export default {
font-weight: 600;
color: #222222;
line-height: 22px;
position: relative;
}
.Lent_p{
width: 5.93333vw;
height: 5.33333vw;
position: absolute;
top: 1.06667vw;
left: 10px;
}
.abt{
margin-bottom: 20px;
}
</style>
<template>
<div class="cont">
<div class="biggestBox">
<img src="../../assets/left.png" alt="" class="Lent_p" @click="go">
<div class="brow">我的浏览</div>
<div class="time">一天之内</div>
<div class="Flor">
<div><img src="../../assets/let.png" alt="" class="Pong"></div>
<div class="name">
<div>行业时间</div>
<div class="Ti">林秋平</div>
<div class="Ti">今天:9:30</div>
<ul>
<!-- data-type=0 隐藏删除按钮 data-type=1 显示删除按钮 -->
<li class="li_vessel" v-for="(item,index) in lists " data-type="0" :key="index">
<!-- "touchstart" 当手指触摸屏幕时候触发 "touchend" 当手指从屏幕上离开的时候触发 "capture" 用于事件捕获-->
<div @touchstart.capture="touchStart" @touchend.capture="touchEnd" @click="oneself">
<div class="contant">
<img class="image" :src="item.lvrImgSmallUrl" alt />
<div class="rightBox">
<div class="titl">{{item.lvrUbName}}</div>
<div class="name">{{item.lvrName}}</div>
<div> </div>
<div class="Time">{{item.updateTime}}</div>
</div>
</div>
<div class="timetwo">更早</div>
<div class="Flor">
<div><img src="../../assets/let.png" alt="" class="Pong"></div>
<div class="name">
<div>行业时间</div>
<div class="Ti">林秋平</div>
<div class="Ti">今天:9:30</div>
</div>
<div class="removeBtn" @click="remove" :data-index="index">删除</div>
</li>
</ul>
<!-- 更早 -->
<ul v-if="updateTime">
<div class="timetwo">更早</div>
<li class="li_vessel" v-for="(item,index) in lists " data-type="0" :key="index">
<!-- "touchstart" 当手指触摸屏幕时候触发 "touchend" 当手指从屏幕上离开的时候触发 "capture" 用于事件捕获-->
<div @touchstart.capture="touchStart" @touchend.capture="touchEnd" @click="oneself">
<div class="contant">
<img class="image" :src="item.lvrImgSmallUrl" alt />
<div class="rightBox">
<div class="titl">{{item.lvrUbName}}</div>
<div class="name">{{item.lvrName}}</div>
<div> </div>
<div class="Time">{{item.updateTime}}</div>
</div>
<div class="Flor">
<div><img src="../../assets/let.png" alt="" class="Pong"></div>
<div class="name">
<div>行业时间</div>
<div class="Ti">林秋平</div>
<div class="Ti">今天:9:30</div>
</div>
</div>
<div class="removeBtn" @click="remove" :data-index="index">删除</div>
</li>
</ul>
</div>
</template>
<script type="text/ecmascript-6">
export default {
data () {
return {}
data() {
return {
lists: [
],
startX: 0, //滑动开始
endX: 0, //滑动结束
updateTime:''
};
},
created () { },
mounted () {
this.beforeCreate()
this.getLiveHistory()
},
methods: {
go:function(){
this.$router.push({name:'mine'})
},
beforeCreate () {
document.querySelector('body').setAttribute('style', 'background-color:rgba(247, 247, 247, 1);')
},
beforeDestroy () {
document.querySelector('body').removeAttribute('style')
},
getLiveHistory(){
let token=sessionStorage.getItem("token")
let temp=this.qs.stringify({
token:token,
applicationType:4
})
this.server.live.getLiveHistory(temp).then(res=>{
this.lists =res.data.data.list
this.listtwo=res.data.data.list
this.updateTime=res.data.data.list.updateTime
console.log(this.lvrUbId,'-=----------------')
})
},
// 向左滑动出现删除按钮时,点击商品信息区域取消删除
oneself() {
if (this.checkSlide()) {
this.restSlide();
} else {
// 点击商品信息弹出弹框
console.log("点击当前商品触发事件...");
}
},
//滑动开始
touchStart(e) {
// 记录初始位置
this.startX = e.touches[0].clientX;
},
//滑动结束
touchEnd(e) {
// 当前滑动的父级元素
let parentElement = e.currentTarget.parentElement;
// 记录结束位置
this.endX = e.changedTouches[0].clientX;
// 左滑大于30距离删除出现
if (parentElement.dataset.type == 0 && this.startX - this.endX > 30) {
this.restSlide();
parentElement.dataset.type = 1;
}
// 右滑
if (parentElement.dataset.type == 1 && this.startX - this.endX < -30) {
this.restSlide();
parentElement.dataset.type = 0;
}
this.startX = 0;
this.endX = 0;
},
//判断当前是否有滑块处于滑动状态
checkSlide() {
let listItems = document.querySelectorAll(".li_vessel");
for (let i = 0; i < listItems.length; i++) {
if (listItems[i].dataset.type == 1) {
return true;
}
}
return false;
},
//复位滑动状态
restSlide() {
let listItems = document.querySelectorAll(".li_vessel");
// 复位
for (let i = 0; i < listItems.length; i++) {
listItems[i].dataset.type = 0;
}
},
//删除数据信息
remove(e) {
// 当前索引值
let index = e.currentTarget.dataset.index;
// 复位
this.restSlide();
// 删除数组lists中一个数据
this.lists.splice(index, 1);
},
},
}
......@@ -56,13 +159,72 @@ export default {
<style scoped>
body{
width: 100%;
height: 100%;
background-color: #9c8888;
position: fixed;
}
.Lent_p{
width: 5.93333vw;
height: 5.33333vw;
position: absolute;
top: 3.06667vw;
left: 7px;
}
.time{
font-size: 4.26667vw;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 600;
color: #2C2C2C;
line-height: 5.86667vw;
margin-left: 20px;
}
.sent{
display: flex;
}
.Lent_p{
width: 5.93333vw;
height: 5.33333vw;
position: absolute;
top: 3.06667vw;
left: 7px;
}
.titl{
font-size: 16px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
color: #2C2C2C;
margin-bottom: 7px;
}
.name{
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #666666;
margin-bottom: 6px;
}
.Time{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
}
.brow{
text-align:center;
margin-top: 10px;
font-size: 16px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
color: #222222;
line-height: 22px;
margin-bottom: 20px;
}
.brow{
text-align:center;
margin-top: 10px;
......@@ -71,6 +233,7 @@ export default {
font-weight: 600;
color: #222222;
line-height: 22px;
margin-bottom: 20px;
}
.time{
font-size: 4.26667vw;
......@@ -120,4 +283,131 @@ export default {
color: #666666;
line-height: 20px;
}
.removeBtn {
width: 14.06667vw;
height: 31.46667vw;
background: #ff4949;
font-size: 4.26667vw;
color: #fff;
text-align: center;
line-height: 5.86667vw;
position: absolute;
top: 84px;
right: -14.06667vw;
line-height: 27.46667vw;
text-align: center;
border-radius: 0.53333vw;
}
* {
/* 消除默认内外边距 */
margin: 0;
padding: 0;
}
body {
background: rgb(246, 245, 250);
}
.biggestBox {
overflow: hidden;
/*超出部分隐藏*/
}
ul {
/* 消除 ul 默认样式 */
list-style: none;
padding: 0;
margin: 0;
}
.li_vessel {
/* 全部样式 0.2秒 缓动*/
transition: all 0.2s;
}
/* =0隐藏 */
.li_vessel[data-type="0"] {
transform: translate3d(0, 0, 0);
}
/* =1显示 */
.li_vessel[data-type="1"] {
/* -64px 设置的越大可以左滑的距离越远,最好与下面删除按钮的宽度以及定位的距离设置一样的值*/
transform: translate3d(-64px, 0, 0);
}
/* 删除按钮 */
.li_vessel .removeBtn {
width: 64px;
height: 103px;
background: #ff4949;
font-size: 16px;
color: #fff;
text-align: center;
line-height: 22px;
position: absolute;
top: 0px;
right: -64px;
line-height: 103px;
text-align: center;
border-radius: 2px;
}
/* 左边的图片样式 */
.contant {
overflow: hidden;
margin-left: 10px;
margin-right: 10px;
/*消除图片带来的浮动*/
padding: 10px;
background: #ffffff;
margin-bottom: 20px;
}
.contant .image {
width: 149px;
height: 74px;
border-radius: 4px;
float: left;
}
/* 右边的文字信息样式 */
.rightBox {
overflow: hidden;
padding-left: 8px;
}
.rightBox div:first-child {
font-weight: bold;
}
.rightBox div:nth-child(2) {
margin-top: 4px;
font-size: 14px;
}
/* .rightBox div:nth-child(3) {
width: 36px;
background: rgb(219, 91, 113);
color: white;
font-size: 12px;
text-align: center;
padding: 2px 4px 2px 4px;
margin-left: auto;
} */
.rightBox div:last-child {
/* color: red;
font-size: 14px;
font-weight: bold; */
}
.timetwo{
font-size: 4.26667vw;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 600;
color: #2C2C2C;
line-height: 5.86667vw;
margin-left: 5.33333vw;
margin-top: 20px;
}
</style>
<template>
<div class="flow">
<div class="sent">我的关注</div>
<div class="cont">
<div class="Img_p">
<img src="../../assets/toux.png" alt="">
<img src="../../assets/y.png" alt="" class="Y_p">
<img src="../../assets/left.png" alt="" class="Lent_p" @click="go">
<div class="brow">我的关注</div>
<div class="Pelo">
<div>林秋平</div>
<div class="wen">这是一段文字</div>
</div>
</div>
<div>
<img src="../../assets/vit.png" alt="" class="Y_two">
<div class="Flor" v-for="(item,index) in List_p" :key="index">
<div style="display:flex">
<img :src="item.udPhotoFileidNew" alt="" class="Pong">
<div class="name">
<div>{{item.udNickname}}</div>
<div class="Ti">{{item.udSxMemo}}</div>
</div>
</div>
<div class="cont">
<div class="Img_p">
<img src="../../assets/toux.png" alt="">
<img src="../../assets/y.png" alt="" class="Y_p">
<div class="J_go">
<div class="Pelo">
<div>林秋平</div>
<div class="wen">这是一段文字</div>
<img v-if='item.ifFllow==true' src="../../assets/vit.png" alt="" class="Img_s" @click="fotwo(index)" >
<img v-if='item.ifFllow==false' src="../../assets/follow.png" alt="" class="Img_s" @click="fo(index)" >
</div>
</div>
<div>
<img src="../../assets/vit.png" alt="" class="Y_two">
</div>
</div>
</div>
</template>
<script type="text/ecmascript-6">
import { shallowReactive } from 'vue'
export default {
data () {
return {}
return {
isactive:false,
isactiveTwo:true,
List_p:[],
lvrUbId :''
}
},
created () { },
mounted () {
this.beforeCreate()
this.getFollowAnchor()
// this.beforeCreate()
},
methods: {
fotwo:function(e){
this.List_p[e].ifFllow=false
this.isactiveTwo = false;
this.isactive = true;
this.followAnchor()
},
fo:function(e){
this.List_p[e].ifFllow=true
this.isactiveTwo = true;
this.isactive = false;
this.followAnchor()
},
go:function(){
this.$router.push({name:'mine'})
},
followAnchor(){
this.lvrUbId=localStorage.getItem('lvrUbId');//直播id
console.log(this.lvrUbId,'-=----------------')
let temp=this.qs.stringify({
lvrUbId:this.lvrUbId,
type:1,
applicationType:4
})
this.server.live.followAnchor(temp).then(res=>{
})
},
getFollowAnchor(){
let temp=this.qs.stringify({
// lvrUbId:26,
// type:1,
// applicationType:4
})
this.server.live.getFollowAnchor(temp).then(res=>{
let list=res.data.data.list
list.forEach(i => {
i.ifFllow=true
});
this.List_p= list
console.log(this.lvrUbId,'-=----------------')
})
},
beforeCreate () {
document.querySelector('body').setAttribute('style', 'background-color:#F7F7F7;')
document.querySelector('body').setAttribute('style', 'background-color:rgba(247, 247, 247, 1);')
},
beforeDestroy () {
document.querySelector('body').removeAttribute('style')
}
},
components: {}
}
}
</script>
<style scoped>
.flow .sent{
text-align: center;
margin-top: 5.33333vw;
font-size: 4.26667vw;
body{
width: 100%;
height: 100%;
background-color: #9c8888;
position: fixed;
}
.J_go{
line-height: 90px;
}
.Img_s{
width: 64px;
height: 23px;
margin-right: 15px;
}
.Lent_p{
width: 5.93333vw;
height: 5.33333vw;
position: absolute;
top: 6.06667vw;
}
.brow{
text-align:center;
margin-top: 10px;
font-size: 16px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
position: relative;
color: #222222;
justify-content: space-around;
}
.cont .Img_p img{
line-height: 22px;
}
.time{
font-size: 4.26667vw;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 600;
color: #2C2C2C;
line-height: 5.86667vw;
margin-left: 20px;
}
.timetwo{
font-size: 4.26667vw;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 600;
color: #2C2C2C;
line-height: 5.86667vw;
margin-left: 5.33333vw;
margin-top: 20px;
}
.Pong{
width: 64px;
padding-right: 10px;
height: 64px;
padding-top: 12px;
}
.cont{
}
.Flor{
display: flex;
justify-content: space-around;
margin-top: 9.33333vw;
justify-content:space-between;
margin-left: 8.26667vw;
margin-top: 8.26667vw;
background: #FFFFFF;
width: 90.4vw;
height: 26.66667vw;
padding-top: 5.33333vw;
margin: 0 auto;
margin-top: 5.33333vw;
background: #ffffff;
}
.cont .Img_p .Y_p{
width: 11.73333vw;
height: 5.6vw;
position: absolute;
left: 2.2vw;
top: 14.4vw;
padding-left: 5.33333vw;
margin-top: 8.66667vw;
}
.Img_p{
display: flex;
position: relative;
}
.cont .Y_two{
width: 64px;
height: 23px;
margin-top: 9vw;
}
.Pelo{
margin-top: 5.66667vw;
margin-left: 10px;
.name div{
height: 22px;
font-size: 16px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
color: #2C2C2C;
}
.Pelo .wen{
margin-top: 10px;
font-size: 12px;
.name .Ti{
font-size: 3.73333vw;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #656565;
line-height: 17px;
}
color: #666666;
line-height: 5.33333vw;
overflow: hidden;
height: 61px;
/* color: #999999; */
font-size: 24rpx;
text-overflow: ellipsis;
z-index: -1;
display: -webkit-box;
word-break: break-all;
-webkit-box-orient: vertical;
-webkit-line-clamp: 3;
}
</style>
......@@ -3,7 +3,7 @@
<div>
<div class="Plog">
<div>
<img class="portait-not" src="../../assets/title_logo.png" alt="">
<img class="portait-not" :src="avatar" alt="">
</div>
<div class="Login">
<span>登录</span><span>/注册</span>
......@@ -16,15 +16,15 @@
<div class="grounp_p">
<div class="grounp">
<span>*****</span>
<span>{{todayJifen}}</span>
<div>今日积分</div>
</div>
<div class="grounp">
<span>*****</span>
<span>{{totalJifen}} </span>
<div>累计积分</div>
</div>
<div class="grounp">
<span>*****</span>
<span>{{totalNiubi}}</span>
<div>我的金牛</div>
</div>
......@@ -84,14 +84,51 @@
export default {
data () {
return {
url:'https://activity.douniu8.com/yinsizhengce/html/privacy.html'
url:'https://activity.douniu8.com/yinsizhengce/html/privacy.html',
totalNiubi:'',
totalJifen:'',
todayJifen:'',
userInfo:'',
avatar:''
}
},
created () { },
mounted () {
this.beforeCreate()
// 调用判断ios与安卓方法
// this.appDown();
this.userCenter()
},
methods: {
// 判断是安卓还是ios
// appDown() {
// var u = navigator.userAgent;
// var isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/);
// var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Adr') > -1; //android终端
// if(isiOS){
// this.isApple = true
// window.location.href="https://itunes.apple.com/cn/app/%E6%96%97%E7%89%9B%E8%B4%...8F/id1262900139?mt=8"
// }else if(isAndroid){
// this.isApple = false
// }
// },
userCenter(){
let temp=this.qs.stringify({
})
this.server.live.userCenter(temp).then(res=>{
if(res.code=200){
console.log(res.data.data.totalNiubi,'ppp')
this.totalNiubi = res.data.data.totalNiubi
// this.totalJifen = res.data.data.totalJifen
// this.todayJifen = res.data.data.todayJifen
this.avatar = res.data.data.userInfo.avatar
}
})
},
beforeCreate () {
document.querySelector('body').setAttribute('style', 'background-color:rgba(247, 247, 247, 1);')
},
......
<template>
<div class="cont">
<img src="../../assets/left.png" alt="" class="Lent_p" @click="go">
<div class="aft">投诉与建议</div>
<div class="grup">
<img src="../../assets/fu.png" alt="" class="Lent">
<span>遇到问题了?点击拨打<span style="color:red">客服热线</span>为您解决</span>
<span>遇到问题了?点击拨打<a style="color:red">客服热线</a>为您解决</span>
</div>
<div class="grup_p">您的问题或者建议</div>
<div class="plead">
<div>请填写你的遇到的问题或者功能建议,感谢支持(必填)</div>
<textarea cols="40" rows="20" placeholder="请填写你的遇到的问题或者功能建议,感谢支持(必填)请填写你的遇到的问题或者功能建议,感谢支持(必填"></textarea>
</div>
<div class="In_img">图片(选填,提供问题截图)</div>
<div class="Pon">
<div></div>
<el-upload
id="upload"
action="#"
list-type="picture-card"
:auto-upload="false">
<i slot="default" class="el-icon-camera-solid"></i>
<div slot="file" slot-scope="{file}">
<img
class="el-upload-list__item-thumbnail"
:src="file.url" alt=""
>
<span class="el-upload-list__item-actions">
<span
class="el-upload-list__item-preview"
@click="handlePictureCardPreview(file)"
>
<i class="el-icon-zoom-in"></i>
</span>
<span
v-if="!disabled"
class="el-upload-list__item-delete"
@click="handleDownload(file)"
>
<i class="el-icon-download"></i>
</span>
<span
v-if="!disabled"
class="el-upload-list__item-delete"
@click="handleRemove(file)"
>
<i class="el-icon-delete"></i>
</span>
</span>
</div>
</el-upload>
<el-dialog :visible.sync="dialogVisible">
<img width="100%" :src="dialogImageUrl" alt="">
</el-dialog>
</div>
<div class="line">联系方式</div>
<div class="ba_c">
<div>留下联系方式,更方便解决问题</div>
<input type="number" placeholder="留下联系方式,更方便解决问题 ">
</div>
<div class="log_t">
<img src="../../assets/login_t.png" alt="">
<img src="../../assets/login_t.png" alt="" @click="login_in">
</div>
</div>
</template>
<script type="text/javascript" src="https://gosspublic.alicdn.com/aliyun-oss-sdk-6.16.0.min.js"></script>
<script type="text/javascript">
const client = new OSS({
// yourRegion填写Bucket所在地域。以华东1(杭州)为例,yourRegion填写为oss-cn-hangzhou。
region: 'yourRegion',
// 从STS服务获取的临时访问密钥(AccessKey ID和AccessKey Secret)。
accessKeyId: res.data.data.assumeRoleResponse.accessKeyId,
accessKeySecret: 'yourAccessKeySecret',
// 从STS服务获取的安全令牌(SecurityToken)。
stsToken: 'yourSecurityToken',
// 填写Bucket名称。
bucket: 'examplebucket'
});
// 从输入框获取file对象,例如<input type="file" id="file" />
let data;
// 创建并填写Blob数据。
//const data = new Blob(['Hello OSS']);
// 创建并填写OSS Buffer内容。
//const data = new OSS.Buffer(['Hello OSS']);
const upload = document.getElementById("upload");
const headers = {
// 指定该Object被下载时网页的缓存行为。
// 'Cache-Control': 'no-cache',
// 指定该Object被下载时的名称。
// 'Content-Disposition': 'oss_download.txt',
// 指定该Object被下载时的内容编码格式。
// 'Content-Encoding': 'UTF-8',
// 指定过期时间。
// 'Expires': 'Wed, 08 Jul 2022 16:57:01 GMT',
// 指定Object的存储类型。
// 'x-oss-storage-class': 'Standard',
// 指定Object的访问权限。
// 'x-oss-object-acl': 'private',
// 设置Object的标签,可同时设置多个标签。
// 'x-oss-tagging': 'Tag1=1&Tag2=2',
// 指定CopyObject操作时是否覆盖同名目标Object。此处设置为true,表示禁止覆盖同名Object。
// 'x-oss-forbid-overwrite': 'true',
};
async function putObject (data) {
try {
// 填写Object完整路径。Object完整路径中不能包含Bucket名称。
// 您可以通过自定义文件名(例如exampleobject.txt)或文件完整路径(例如exampledir/exampleobject.txt)的形式实现将数据上传到当前Bucket或Bucket中的指定目录。
// data对象可以自定义为file对象、Blob数据或者OSS Buffer。
const result = await client.put(
"exampledir/exampleobject.txt",
data
//{headers}
);
console.log(result);
} catch (e) {
console.log(e);
}
}
upload.addEventListener("click", () => {
data = document.getElementById("file").files[0];
putObject(data);
});
</script>
<script type="text/ecmascript-6">
export default {
data () {
return {}
return {
dialogImageUrl: '',
dialogVisible: false,
disabled: false,
region: 'oss-cn-hangzhou',
bucket: 'buket名称',
id: 'upload',
percentage: 0,
url:'',
urls:[],
getToken:{
sign:'',
}
}
},
created () {
this.sigurature()
// this.doUpload()
},
created () { },
mounted () {
this.feedback()
this.beforeCreate()
},
methods: {
login_in:function(){
this.deal()
},
flod:function(){
// this.sigurature()
},
go:function(){
this.$router.push({name:'mine'})
},
handleRemove(file) {
console.log(file);
},
handlePictureCardPreview(file) {
this.dialogImageUrl = file.url;
this.dialogVisible = true;
},
handleDownload(file) {
console.log(file);
},
beforeCreate () {
document.querySelector('body').setAttribute('style', 'background-color:#F7F7F7;')
},
beforeDestroy () {
document.querySelector('body').removeAttribute('style')
},
feedback(){
let temp=this.qs.stringify({
})
this.server.live.feedback(temp).then(res=>{
if(res.code=200){
phoneText= res.data.data.phoneText
}
})
},
//签名
sigurature(){
let token=sessionStorage.getItem("token")
console.log(token,'----')
let temp=this.qs.stringify({
flag:11,
token:token
})
this.server.live.sigurature(temp).then(res=>{
if(res.code=200){
this.assumeRoleResponse = res.data.data.assumeRoleResponse.accessKeyId;
console.log(this.assumeRoleResponse,'===')
this.accessKeySecret = res.data.data.assumeRoleResponse.accessKeySecret;
this.expiration = res.data.data.assumeRoleResponse.expiration;
this.securityToken = res.data.data.assumeRoleResponse.securityToken;
}
})
},
deal(){
let temp=this.qs.stringify({
// fbContext:,
// fbPhone:,
// imgs:,
})
this.server.live.deal(temp).then(res=>{
if(res.code=200){
}
})
},
//准备上传
},
components: {}
}
......@@ -66,6 +262,30 @@ export default {
height: 13px;
}
.cont{
position: relative;
}
.Lent_p{
width: 5.93333vw;
height: 5.33333vw;
position: absolute;
top: 34px;
}
.plead textarea{
margin: 0px;
font-size: 14px;
height: 37.26667vw;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
line-height: 20px;
width: 109px;
border:none;
width: 305px;
outline: none;
}
.grup{
margin-left:34px;
margin-top:10px;
......@@ -134,7 +354,6 @@ export default {
}
.Pon{
width: 89.6vw;
height: 21.33333vw;
background: #FFFFFF;
border-radius: 2.13333vw;
margin: 0 quto;
......@@ -156,4 +375,54 @@ export default {
/* padding-left: 4vw; */
margin-right: 12px;
}
/deep/.el-upload--picture-card{
background-color: #fbfdff;
border: 1px dashed #c0ccda;
border-radius: 1.6vw;
box-sizing: border-box;
width: 22.46667vw;
height: 21.46667vw;
cursor: pointer;
line-height: 23.93333vw;
vertical-align: top;
}
/deep/.el-upload-list--picture-card .el-upload-list__item {
overflow: hidden;
background-color: #fff;
border: 1px solid #c0ccda;
border-radius: 1.6vw;
box-sizing: border-box;
width: 22.46667vw;
height: 21.46667vw;
margin: 0 2.13333vw 2.13333vw 0;
display: inline-block;
}
.ba_c input{
width: 340px;
height: 45px;
border: none;
padding-left: 10px;
}
input {
outline: none;
background: transparent;
border: none;
outline: medium;
width: 100%;
height: 50px;
}
input:focus {
outline: none;
background-color: transparent;
}
::selection {
background: transparent;
}
::-moz-selection {
background: rgb(241, 241, 241);
}
</style>
......@@ -162,6 +162,14 @@ export default {
this.go_get()
},
// // 通过域名返回对应接口路径
// getPath() {
// if (window.location.host.split('.')[0] == 'localhost:8080') {
// return 'web'
// } else {
// return window.location.host.split('.')[0];
// }
// },
getLive(){
let temp=this.qs.stringify({
pmAppVersion:884,
......@@ -203,19 +211,15 @@ export default {
})
},
go_get(){
let temp=this.qs.stringify({
let temp=this.qs.stringify({
urlTag:'nh5'
})
this.server.live.buy_code(temp).then(res=>{
//order成功判断内置浏览器,在微信就授权,内置微信还是浏览器 微信jsapi 浏览器h5
if(res.code=200){
//判断是否为在微信内置浏览器支付
if(this.common.isWX()){
}else{
}
// window.location.href=''
}
})
......
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