xinelu-applet-ui/pagesB/customerservice/customerservice.vue

84 lines
1.6 KiB
Vue
Raw Normal View History

2023-09-22 11:08:14 +08:00
<template>
<view class="app">
<view class="title">
长按识别二维码
</view>
<image :src="img" mode="" :show-menu-by-longpress="true"></image>
</view>
</template>
<script>
import baseurl from '@/api/baseurl.js'
export default {
data() {
return {
img: '',
};
},
onShow() {
this.img = baseurl + '/profile/appletPicture/customer.jpg'
},
methods: {
previewImage(e) {
uni.previewImage({
// 需要预览的图片链接列表。若无需预览可以注释urls
urls: this.img,
// 为当前显示图片的链接/索引值
current: 0,
2023-09-22 11:45:09 +08:00
// 图片指示器样式
2023-09-22 11:08:14 +08:00
indicator: 'default',
// 是否可循环预览
loop: false,
// 长按图片显示操作菜单,如不填默认为保存相册
// longPressActions:{
// itemList:[this.l('发送给朋友'),this.l]
// },
success: res => {},
fail: err => {}
});
},
},
//1.分享给朋友
onShareAppMessage(res) {
let pages = getCurrentPages();
let url = pages[pages.length - 1].$page.fullPath
return {
2023-09-22 11:45:09 +08:00
title: '新医路健康服务平台',
2023-09-22 11:08:14 +08:00
path: url,
}
},
//2.分享到朋友圈
onShareTimeline(res) {
let pages = getCurrentPages();
let url = pages[pages.length - 1].$page.fullPath
return {
2023-09-22 11:45:09 +08:00
title: '新医路健康服务平台',
2023-09-22 11:08:14 +08:00
path: url,
}
},
}
</script>
<style lang="scss">
.app {
width: 100%;
height: 100vh;
padding: 0;
background-color: #000000;
position: relative;
.title {
color: #fff;
width: 100%;
text-align: center;
position: absolute;
top: 50rpx;
}
image {
width: 100%;
height: 1300rpx;
}
}
</style>