修改分享好友页面,增加海报保存按钮
This commit is contained in:
@@ -1,18 +1,25 @@
|
||||
<template>
|
||||
<view style="background: #FFFFFF;">
|
||||
<canvas v-if="!tempFilePath" :canvas-id="CanvasID"
|
||||
:style="{ width: canvasW + 'px', height: canvasH + 'px' }"></canvas>
|
||||
<!-- #ifdef MP-WEIXIN -->
|
||||
<image v-else lazy-load :src="tempFilePath" mode="widthFix" style="width: 100%;" class="is-response"
|
||||
@longpress="saveqrcode"></image>
|
||||
<!-- <button v-if="openSettingBtnHidden" class="purple_btn btn_box" hover-class="none" open-type="openSetting"
|
||||
@opensetting='handleSetting'>请开启保存权限</button> -->
|
||||
<!-- #endif -->
|
||||
<!-- #ifndef MP-WEIXIN -->
|
||||
<image v-else lazy-load :src="tempFilePath" mode="widthFix" style="width: 100%;" class="is-response"
|
||||
@longpress="toSave(tempFilePath)"></image>
|
||||
<!-- #endif -->
|
||||
<view>
|
||||
<view class="u-flex " >
|
||||
<canvas v-if="!tempFilePath" :canvas-id="CanvasID"
|
||||
:style="{ width: canvasW + 'px', height: canvasH + 'px' }"></canvas>
|
||||
<!-- #ifdef MP-WEIXIN -->
|
||||
<image v-else lazy-load :src="tempFilePath" mode="widthFix" style="width: 100%;" class="is-response"
|
||||
@longpress="saveqrcode"></image>
|
||||
<!-- <button v-if="openSettingBtnHidden" class="purple_btn btn_box" hover-class="none" open-type="openSetting"
|
||||
@opensetting='handleSetting'>请开启保存权限</button> -->
|
||||
<!-- #endif -->
|
||||
<!-- #ifndef MP-WEIXIN -->
|
||||
<image v-else lazy-load :src="tempFilePath" mode="widthFix" style="width: 100%;" class="is-response"
|
||||
@longpress="toSave(tempFilePath)"></image>
|
||||
<!-- #endif -->
|
||||
</view>
|
||||
<view class="u-flex u-m-t-20" >
|
||||
<button class="purple_btn btn_box" hover-class="none" open-type="openSetting"
|
||||
@click.stop="toSave(tempFilePath)">保存海报</button>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
@@ -240,7 +247,8 @@
|
||||
//添加二维码
|
||||
_strHeight += uni.upx2px(20);
|
||||
let toTop = uni.upx2px(103);
|
||||
_this.ctx.drawImage(_QrCode.path, r[0] - q[0] + C_P - uni.upx2px(201), _this.canvasH - q[1] - toTop, 71, 71);
|
||||
_this.ctx.drawImage(_QrCode.path, r[0] - q[0] + C_P - uni.upx2px(201), _this.canvasH - q[1] - toTop,
|
||||
71, 71);
|
||||
//添加二维码 end
|
||||
|
||||
//添加推荐人与描述
|
||||
@@ -313,4 +321,13 @@
|
||||
};
|
||||
</script>
|
||||
|
||||
<style></style>
|
||||
<style scoped lang="scss">
|
||||
.btn_box {
|
||||
background: rgb(221, 220, 255);
|
||||
border-radius: 8rpx;
|
||||
color: rgb(69, 68, 255);
|
||||
font-size: 28rpx;
|
||||
font-weight: 700;
|
||||
padding: 10rpx 32rpx;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user