|
|
@ -71,9 +71,9 @@ |
|
|
|
<!-- --> |
|
|
|
<!-- --> |
|
|
|
<view class="invite-popup" v-if="isPopup"> |
|
|
|
<view class="invite-popup" v-if="isPopup"> |
|
|
|
<view class="popup"> |
|
|
|
<view class="popup"> |
|
|
|
<image class="bg" show-menu-by-longpress src="https://www.royaum.com.cn/static/3@2x.png"></image> |
|
|
|
<image class="bg" show-menu-by-longpress :src="qrcode1"></image> |
|
|
|
<image class="code" show-menu-by-longpress :src="qrcode"></image> |
|
|
|
<!-- <image class="code" show-menu-by-longpress :src="qrcode"></image> |
|
|
|
<view class="qrcode">{{userInfo.user_id}}</view> |
|
|
|
<view class="qrcode">{{userInfo.user_id}}</view> --> |
|
|
|
<view class="tips"> |
|
|
|
<view class="tips"> |
|
|
|
<view class="cancle" @click="download(1)">取消</view> |
|
|
|
<view class="cancle" @click="download(1)">取消</view> |
|
|
|
<view class="sure" @click="download(2)">保存到相册</view> |
|
|
|
<view class="sure" @click="download(2)">保存到相册</view> |
|
|
@ -95,6 +95,7 @@ |
|
|
|
export default { |
|
|
|
export default { |
|
|
|
data() { |
|
|
|
data() { |
|
|
|
return { |
|
|
|
return { |
|
|
|
|
|
|
|
qrcode1: "", |
|
|
|
qrcode: "", |
|
|
|
qrcode: "", |
|
|
|
userInfo: {}, |
|
|
|
userInfo: {}, |
|
|
|
backgroundBg: { |
|
|
|
backgroundBg: { |
|
|
@ -161,21 +162,24 @@ |
|
|
|
success: function(res) { |
|
|
|
success: function(res) { |
|
|
|
// 在H5平台下,tempFilePath 为 base64 |
|
|
|
// 在H5平台下,tempFilePath 为 base64 |
|
|
|
console.log(res.tempFilePath) |
|
|
|
console.log(res.tempFilePath) |
|
|
|
uni.saveImageToPhotosAlbum({ |
|
|
|
that.qrcode1 = res.tempFilePath; |
|
|
|
filePath: res.tempFilePath, |
|
|
|
that.isPopup = true; |
|
|
|
success(data) { |
|
|
|
ctx.clearRect(0,0,702,1248); |
|
|
|
that.$success('保存成功') |
|
|
|
// uni.saveImageToPhotosAlbum({ |
|
|
|
}, |
|
|
|
// filePath: res.tempFilePath, |
|
|
|
fail(err) { |
|
|
|
// success(data) { |
|
|
|
if (err.errMsg === |
|
|
|
// that.$success('保存成功') |
|
|
|
'saveImageToPhotosAlbum:fail auth deny' |
|
|
|
// }, |
|
|
|
) { |
|
|
|
// fail(err) { |
|
|
|
that.$toast( |
|
|
|
// if (err.errMsg === |
|
|
|
'请允许访问相册后重试 (右上角菜单 - 设置 - 相册)', |
|
|
|
// 'saveImageToPhotosAlbum:fail auth deny' |
|
|
|
3000) |
|
|
|
// ) { |
|
|
|
} |
|
|
|
// that.$toast( |
|
|
|
} |
|
|
|
// '请允许访问相册后重试 (右上角菜单 - 设置 - 相册)', |
|
|
|
}) |
|
|
|
// 3000) |
|
|
|
|
|
|
|
// } |
|
|
|
|
|
|
|
// } |
|
|
|
|
|
|
|
// }) |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
@ -230,8 +234,8 @@ |
|
|
|
} = await newFunApi.InviteUserPoster({}); |
|
|
|
} = await newFunApi.InviteUserPoster({}); |
|
|
|
if (status == 200) { |
|
|
|
if (status == 200) { |
|
|
|
console.log(data) |
|
|
|
console.log(data) |
|
|
|
this.isPopup = true; |
|
|
|
this.qrcode = data.imageUrl; |
|
|
|
this.qrcode = data.imageUrl |
|
|
|
this.createImge(); |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
download(type) { |
|
|
|
download(type) { |
|
|
@ -243,7 +247,8 @@ |
|
|
|
uni.showLoading({ |
|
|
|
uni.showLoading({ |
|
|
|
title: '加载中' |
|
|
|
title: '加载中' |
|
|
|
}) |
|
|
|
}) |
|
|
|
this.createImge(); |
|
|
|
app.onSaveImage(app.qrcode1) |
|
|
|
|
|
|
|
// this.createImge(); |
|
|
|
} |
|
|
|
} |
|
|
|
return; |
|
|
|
return; |
|
|
|
uni.showLoading({ |
|
|
|
uni.showLoading({ |
|
|
@ -331,7 +336,12 @@ |
|
|
|
url: "/pages/news/user/withdrawal?balance=" + this.userInfo.withdrawal_money |
|
|
|
url: "/pages/news/user/withdrawal?balance=" + this.userInfo.withdrawal_money |
|
|
|
}) |
|
|
|
}) |
|
|
|
} else if (index == 3) { |
|
|
|
} else if (index == 3) { |
|
|
|
|
|
|
|
if(!this.qrcode1){ |
|
|
|
this.InviteUserPoster(); |
|
|
|
this.InviteUserPoster(); |
|
|
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
this.isPopup = true; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} else if (index == 4) { |
|
|
|
} else if (index == 4) { |
|
|
|
uni.navigateTo({ |
|
|
|
uni.navigateTo({ |
|
|
|
url: "/pages/invite/rule" |
|
|
|
url: "/pages/invite/rule" |
|
|
|