提交 fe8217ae authored 作者: ling's avatar ling

Add app download link

上级 8e59ca0b
...@@ -53,10 +53,8 @@ ...@@ -53,10 +53,8 @@
<div> <div>
<div class="install_btn_wrap"> <div class="install_btn_wrap">
<div class="process_box"></div> <div class="process_box"></div>
<a <span class="down_btn" @click="handleDownload()"
class="down_btn" >立即下载</span
href="/d50232e4a3e846cabcd0877c05678902.mobileprovision"
>立即下载</a
> >
</div> </div>
</div> </div>
...@@ -87,10 +85,8 @@ ...@@ -87,10 +85,8 @@
<div v-else> <div v-else>
<div style="display: flex; justify-content: space-evenly"> <div style="display: flex; justify-content: space-evenly">
<div class="install_btn_wrap" style="width: 10.8rem"> <div class="install_btn_wrap" style="width: 10.8rem">
<a <span class="down_btn" @click="handleDownload()"
class="down_btn" >立即下载</span
href="/d50232e4a3e846cabcd0877c05678902.mobileprovision"
>立即下载</a
> >
</div> </div>
<div class="open_h5_wrap" style="width: 8rem"> <div class="open_h5_wrap" style="width: 8rem">
...@@ -159,12 +155,29 @@ export default { ...@@ -159,12 +155,29 @@ export default {
isiOS: null, isiOS: null,
}; };
}, },
created() {
ShareTrace.init({
appkey: "a4a9e45dc76e096a",
success: function () {
console.log("init success...");
},
error: function (msg) {
console.log(msg);
},
});
},
mounted() { mounted() {
const u = navigator.userAgent; const u = navigator.userAgent;
const isAndroid = u.indexOf("Android") > -1 || u.indexOf("Adr") > -1; //android终端 const isAndroid = u.indexOf("Android") > -1 || u.indexOf("Adr") > -1; //android终端
const isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端 const isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端
this.isiOS = isiOS; this.isiOS = isiOS;
}, },
methods: {
handleDownload() {
// 请在用户点击下载按钮时,触发此函数
ShareTrace.download();
},
},
}; };
</script> </script>
<style scoped> <style scoped>
......
...@@ -22,9 +22,12 @@ export default { ...@@ -22,9 +22,12 @@ export default {
{ hid: 'description', name: 'description', content: '' }, { hid: 'description', name: 'description', content: '' },
{ name: 'format-detection', content: 'telephone=no' } { name: 'format-detection', content: 'telephone=no' }
], ],
script: [{
src: 'https://res.sharetrace.com/sharetrace.min.js'
}],
link: [ link: [
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' } { rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
] ],
}, },
// Global CSS: https://go.nuxtjs.dev/config-css // Global CSS: https://go.nuxtjs.dev/config-css
......
...@@ -18,7 +18,12 @@ export default { ...@@ -18,7 +18,12 @@ export default {
data() { data() {
return { return {
isPc: true, isPc: true,
code: "",
}; };
}, },
mounted() {
this.code = location.href.split("?")[1].split("=")[1];
console.log(this.code)
},
}; };
</script> </script>
\ No newline at end of file
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论