提交 393b0d2e 编写于 作者: guangjun.yang's avatar guangjun.yang

登陆验证等

上级 f9e7dc9c
...@@ -7,30 +7,118 @@ ...@@ -7,30 +7,118 @@
<!-- <Card4></Card4> --> <!-- <Card4></Card4> -->
<!-- <Card5></Card5> --> <!-- <Card5></Card5> -->
<Card6></Card6> <Card6></Card6>
<Loading v-show="showLoading" />
</div> </div>
</template> </template>
<script> <script>
import Card1 from '@/components/annual-summary/card-1' import Loading from "@/components/common/common-loading";
import Card1No from '@/components/annual-summary/card-1-no' import { Progress, Toast } from "vant";
import Card2 from '@/components/annual-summary/card-2'
import Card3 from '@/components/annual-summary/card-3' import Card1 from "@/components/annual-summary/card-1";
import Card4 from '@/components/annual-summary/card-4' import Card1No from "@/components/annual-summary/card-1-no";
import Card5 from '@/components/annual-summary/card-5' import Card2 from "@/components/annual-summary/card-2";
import Card6 from '@/components/annual-summary/card-6' import Card3 from "@/components/annual-summary/card-3";
import Card4 from "@/components/annual-summary/card-4";
import Card5 from "@/components/annual-summary/card-5";
import Card6 from "@/components/annual-summary/card-6";
import { mapGetters, mapActions } from "vuex";
let _this = null;
export default { export default {
components: { components: {
Loading,
Card1, Card1,
Card1No, Card1No,
Card2, Card2,
Card3, Card3,
Card4, Card4,
Card5, Card5,
Card6, Card6
},
data() {
return {
isWeb: window.__isWeb,
isInfresh: false,
showLoading: false
};
},
computed: {
...mapGetters(["userInfo"])
},
created() {
_this = this;
window.__getUserInfoAS = function(param) {
console.log("__getUserInfoAS", param);
_this.token = param.userToken;
_this.userMobile = param.userMobile;
_this.setUserInfo(param);
_this.checkToken();
_this.initData();
};
if (_this.isWeb) {
_this.initData();
} }
} window.__refresh = function() {
_this.isInfresh = true;
_this.getUserInfo();
};
_this.getUserInfo();
},
methods: {
...mapActions(["setUserInfo"]),
// 获取数据
initData() {
let param = {
token: this.token,
setEntry: true
};
// this.showLoading = true;
// this.GET(`portal/titleTest/user/getBrushTitleInfo/${this.secondSubjectId}`, param).then(res => {
// if (res.code == "000000") {
// this.showLoading = false;
// } else {
// this.$toast(res.message);
// }
// });
},
//获取用户信息
getUserInfo() {
rocNative.getUserInfo({
__funcName: "__getUserInfoAS"
});
},
// token是否失效校验
checkToken() {
let param = {
token: this.userInfo.userToken || this.token,
setEntry: true
};
this.GET("campaign/admin/task/checkToken", param).then(res => {
if (res.code !== "000000") {
console.log("跳登录", this.isInfresh);
if (this.isInfresh) {
rocNative.goBack();
} else {
rocNative.gotoLogin();
}
this.isInfresh = false;
} else {
}
});
}
}
};
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.as-swipper-wrapper { .as-swipper-wrapper {
} }
</style> </style>
\ No newline at end of file
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
<img v-show="isSelect" src="~@/images/annual/rect-2.png" alt /> <img v-show="isSelect" src="~@/images/annual/rect-2.png" alt />
<span>我同意云鹊医使用我的历史数据生成《年度个人清单》数据报告</span> <span>我同意云鹊医使用我的历史数据生成《年度个人清单》数据报告</span>
</div> </div>
<div class="b-btn"> <div v-show="isHide" class="b-btn" @click="gotoDetail">
<img src="~@/images/annual/index-btn.png" alt /> <img src="~@/images/annual/index-btn.png" alt />
</div> </div>
</section> </section>
...@@ -47,32 +47,60 @@ ...@@ -47,32 +47,60 @@
</template> </template>
<script> <script>
import Logo from "@/components/annual-summary/logo"; import Logo from "@/components/annual-summary/logo";
let _this = null;
export default { export default {
components: { components: {
Logo Logo
}, },
data() { data() {
return { return {
isSelect: false isSelect: false,
isHide: true,
}; };
}, },
created() { created() {
_this = this;
// 截屏时通知前端 // 截屏时通知前端
window.screenCaptureEvent = function() { window.screenCaptureEvent = function() {
console.log('in screenCaptureEvent'); console.log('in screenCaptureEvent');
this.$sendBuriedData({ _this.$sendBuriedData({
component_tag: '557#557002' component_tag: '557#557002'
}); });
} }
// 保存图片的回调
window.__savePage2Picture = function(param) {
this.isHide = false;
console.log("__savePage2Picture", param);
}
}, },
methods: { methods: {
// 选择协议
selectProt() { selectProt() {
this.isSelect = !this.isSelect; this.isSelect = !this.isSelect;
}, },
// 保存图片
savePage2Picture() { savePage2Picture() {
rocNative.savePage2Picture(); this.isHide = false;
this.$forceUpdate()
this.$nextTick( () => {
rocNative.savePage2Picture({
__funcName: "__savePage2Picture"
});
})
},
// 跳转到详情页面
gotoDetail() {
if(this.isSelect) {
this.$router.push('/as-detail');
} else {
Toast("请勾选我同意后查看");
} }
},
} }
}; };
</script> </script>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册