调整区块链电商App兼容优化
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<swiper class="code-swiper" previous-margin="70rpx" next-margin="70rpx" @change="swiperChange">
|
||||
<swiper-item v-for="(item, index) in inviteData" :key="index">
|
||||
<view class="code-item">
|
||||
<view class="code-lay"></view>
|
||||
<view class="code-lay" @click="coverCode"></view>
|
||||
<image class="code-back-image" :src="item.cover" mode="aspectFill"></image>
|
||||
<view class="codDate">
|
||||
<view class="codDate-year">
|
||||
@@ -39,7 +39,7 @@
|
||||
<view class="title">邀请码 : {{inviteData[0].invite}}</view>
|
||||
<view class="value" @click="copyCenter(inviteData[0].invite)">复制邀请码</view>
|
||||
</view>
|
||||
<view class="button" @click="coverCode">生成分享海报</view>
|
||||
<!-- <view class="button" @click="coverCode">生成分享海报</view> -->
|
||||
</view>
|
||||
<canvas class="my-canvas" canvas-id="myCanvas" id="myCanvas"/>
|
||||
<view v-if="posterShow">
|
||||
@@ -49,8 +49,8 @@
|
||||
<image class="img" :src="posterImg" mode="widthFix" />
|
||||
</view>
|
||||
<view class="poster-btn">
|
||||
<view class="operate">长按图片保存</view>
|
||||
<view class="operate operate-cancel" @tap="posterShow = false">取消</view>
|
||||
<view class="operate operate-cancel" @click="saveImage">保存图片至相册</view>
|
||||
<view class="operate" @tap="posterShow = false">取消</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -61,7 +61,6 @@
|
||||
import { userInvite } from '@/apis/interfaces/user'
|
||||
import { saveImageToPhotosAlbum, showToast, downloadFile } from '@/uni_modules/sakura-canvas/js_sdk/util'
|
||||
import Draw from '@/uni_modules/sakura-canvas/js_sdk/draw'
|
||||
import h5Copy from '@/js_sdk/junyi-h5-copy/junyi-h5-copy/junyi-h5-copy'
|
||||
let draw = null
|
||||
export default {
|
||||
data() {
|
||||
@@ -264,24 +263,21 @@
|
||||
let { posterImg } = this
|
||||
let res = await saveImageToPhotosAlbum(posterImg)
|
||||
if (!res.success) return
|
||||
showToast('保存成功')
|
||||
showToast('保存成功,去相册分享给朋友吧')
|
||||
this.posterShow = false
|
||||
},
|
||||
|
||||
// 复制邀请码
|
||||
copyCenter(e) {
|
||||
let copyNo = e
|
||||
const result = h5Copy(copyNo)
|
||||
if (result === false) {
|
||||
uni.showToast({
|
||||
title:'不支持',
|
||||
})
|
||||
} else {
|
||||
uni.showToast({
|
||||
title:'复制成功',
|
||||
icon:'none'
|
||||
})
|
||||
}
|
||||
uni.setClipboardData({
|
||||
data: e,
|
||||
success(){
|
||||
uni.showToast({
|
||||
title: '邀请码已复制',
|
||||
icon : 'none'
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
// 切换海报背景index
|
||||
|
||||
@@ -31,13 +31,6 @@
|
||||
<view class="ios-top"></view>
|
||||
<!-- header -->
|
||||
<view class="header">
|
||||
<!-- 工具 -->
|
||||
<view class="user-tool">
|
||||
<image class="user-tool-icon" src="/static/user/user-top-00.png" mode="aspectFill"
|
||||
@click="$Router.push({name: 'setting'})"></image>
|
||||
<image class="user-tool-icon" src="/static/user/user-top-01.png" mode="aspectFill"
|
||||
@click="$Router.push({name: 'news'})"></image>
|
||||
</view>
|
||||
<!-- 用户信息 -->
|
||||
<view class="user-info">
|
||||
<view class="user-portrait">
|
||||
@@ -195,7 +188,7 @@
|
||||
</view>
|
||||
<view class="tool-label" @click="$Router.push({name: 'shopLists'})">
|
||||
<image class="tool-label-img" src="/static/user/userTool-04.png" mode=""></image>
|
||||
<view class="tool-label-name">部门门店</view>
|
||||
<view class="tool-label-name">门店管理</view>
|
||||
</view>
|
||||
<view class="tool-label" @click="$Router.push({name: 'employeesList'})">
|
||||
<image class="tool-label-img" src="/static/user/userTool-05.png" mode=""></image>
|
||||
@@ -280,7 +273,7 @@
|
||||
this.animatedShow = false
|
||||
},
|
||||
onPageScroll(e) {
|
||||
if (e.scrollTop <= 0 && !this.shoeCardType) {
|
||||
if (e.scrollTop <= -60 && !this.shoeCardType) {
|
||||
this.shoeCardType = true
|
||||
return
|
||||
}
|
||||
@@ -288,6 +281,16 @@
|
||||
this.shoeCardType = false
|
||||
}
|
||||
},
|
||||
onNavigationBarButtonTap(e){
|
||||
switch(e.index){
|
||||
case 0:
|
||||
this.$Router.push({name: 'news'})
|
||||
break
|
||||
case 1:
|
||||
this.$Router.push({name: 'setting'})
|
||||
break
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 开通VIP
|
||||
openVip(identityId) {
|
||||
@@ -374,18 +377,6 @@
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
// const result = h5Copy(copyNo)
|
||||
// if (result === false) {
|
||||
// uni.showToast({
|
||||
// title:'不支持',
|
||||
// })
|
||||
// } else {
|
||||
// uni.showToast({
|
||||
// title:'复制成功',
|
||||
// icon:'none'
|
||||
// })
|
||||
// }
|
||||
},
|
||||
// 友情提示信息
|
||||
showHelp(type) {
|
||||
@@ -666,36 +657,15 @@
|
||||
left: 0;
|
||||
width: 100%;
|
||||
background-image: linear-gradient(to right, #7c52fc, #976dff);
|
||||
|
||||
// user工具
|
||||
.user-tool {
|
||||
text-align: right;
|
||||
line-height: 40px;
|
||||
@extend .ios-top;
|
||||
|
||||
.user-tool-name {
|
||||
flex: 1;
|
||||
line-height: 40px;
|
||||
text-align: left;
|
||||
color: #fff;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
|
||||
.user-tool-icon {
|
||||
padding-right: $padding;
|
||||
margin-top: 10px;
|
||||
width: $uni-img-size-sm;
|
||||
height: $uni-img-size-sm;
|
||||
vertical-align: top;
|
||||
}
|
||||
}
|
||||
|
||||
overflow: hidden;
|
||||
@extend .ios-top;
|
||||
// 用户信息
|
||||
.user-info {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 70px;
|
||||
box-sizing: border-box;
|
||||
margin-top: 40px;
|
||||
padding-left: $padding;
|
||||
padding-right: $padding;
|
||||
color: $uni-text-color-inverse;
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user