feat:下载分享检查
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
import { recordShareSuccess } from '../../utils/shareGuide';
|
||||
|
||||
Component({
|
||||
options: {},
|
||||
/**
|
||||
* 组件的属性列表
|
||||
*/
|
||||
properties: {
|
||||
show: {
|
||||
type: Boolean,
|
||||
value: false,
|
||||
},
|
||||
},
|
||||
/**
|
||||
* 组件的初始数据
|
||||
*/
|
||||
data: {},
|
||||
/**
|
||||
* 组件的方法列表
|
||||
*/
|
||||
methods: {
|
||||
/** 关闭弹窗 */
|
||||
onClose() {
|
||||
this.triggerEvent('onClose');
|
||||
},
|
||||
|
||||
/** 点击遮罩层关闭 */
|
||||
onOverlayClick() {
|
||||
this.onClose();
|
||||
},
|
||||
|
||||
/** 点击分享按钮 */
|
||||
onShare() {
|
||||
// 记录分享成功(用户点击了分享按钮,视为已分享)
|
||||
recordShareSuccess();
|
||||
// 关闭弹窗并通知父组件分享成功(不触发下载,用户需要重新点击下载按钮)
|
||||
this.triggerEvent('onShareSuccess');
|
||||
},
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user