松鼠短视频系统如何添加 精准添加openistall的注册统计部分...
松鼠短视频系统如何添加 精准添加openistall的注册统计部分的代码
首先是register.vue文件的29行;
改为:
- <button class="login-btn" @tap="register" v-on:click="Registertj" >同意规则并普通注册</button>
复制代码
另 普通用户名密码注册页面 也需要改 login-user-pass.vue26行
- <span style="white-space:pre"> </span><button class="register-btn" @tap="register" v-on:click="Registertj" >注册账号</button>
复制代码
openinstall引入插件代码 加在
353行
方法部分 注册成功 后面执行
- this.$api.userRegister({username:this.username,password:this.password,mail:this.mail,vcode:this.vcode,invitecode:this.inviteCode}).then(res=>{
- if (res.data.code == 1) {
- uni.showToast({
- title: '注册失败,' + res.data.msg,
- icon:'none'
- });
- return;
- }
-
-
-
-
-
- uni.showToast({
- title: '注册成功',
- icon: 'none',
- duration: 1000,
- complete: () => {
- uni.navigateBack({
- delta: 1
- });
-
-
-
-
-
- }
- });
- //增加openinstall 统计
-
- Registertj:function(even){
- // console.log('button click')
- const openinstall = uni.requireNativePlugin('openinstall-plugin');
- openinstall.reportRegister();
- },
-
复制代码
|
|
|
|
|