跳转首页 注册报错
This commit is contained in:
@@ -120,7 +120,7 @@
|
||||
import { computed, defineComponent, onMounted, reactive, ref } from "vue";
|
||||
import LoginTab from "@/components/login/LoginTab.vue";
|
||||
import NavTop from "@/components/NavTop.vue"
|
||||
import { checksmscode, getquhaolist, getwebvideolist, loginpass, sendsms } from '@/api';
|
||||
import { checksmscode, checkuser, getquhaolist, getwebvideolist, loginpass, sendsms } from '@/api';
|
||||
import { message } from 'ant-design-vue';
|
||||
import router from '@/router';
|
||||
import { useI18n } from '@/utils/i18n';
|
||||
@@ -181,7 +181,7 @@ export default defineComponent({
|
||||
* 点击获取验证码 触发倒计时
|
||||
*/
|
||||
let lock=false
|
||||
const getcode: () => void = () => {
|
||||
async function getcode() {
|
||||
console.log(phone.value);
|
||||
if (lock) {
|
||||
console.log("lock")
|
||||
@@ -191,6 +191,13 @@ export default defineComponent({
|
||||
message.error(lan.$t('shoujihaoweikong'));
|
||||
return;
|
||||
}
|
||||
const iszc: any = await checkuser({phone: phone.value})
|
||||
if(iszc.data){
|
||||
if(iszc.data.type == 0){
|
||||
message.error(lan.$t("yizhucexuesheng"))
|
||||
}
|
||||
return ;
|
||||
}
|
||||
lock = true;
|
||||
console.log(myquhao.value,"quhao")
|
||||
sendsms(myquhao.value, phone.value);
|
||||
@@ -207,7 +214,7 @@ export default defineComponent({
|
||||
clearInterval(timestep);
|
||||
}
|
||||
}, 1000);
|
||||
};
|
||||
}
|
||||
function getquhao(e?: any){
|
||||
console.log(e)
|
||||
myquhao.value = e.toString()
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
<template>
|
||||
<div class="rank-list">
|
||||
<div class="list-thead">
|
||||
<div class="ranking-number">排名</div>
|
||||
<div class="user-info">姓名</div>
|
||||
<div class="hits">视频点击量</div>
|
||||
<div class="ranking-number">{{lan.$t('paiming')}}</div>
|
||||
<div class="user-info">{{lan.$t("xingming")}}</div>
|
||||
<div class="hits">{{lan.$t("shipindianjiliang")}}</div>
|
||||
</div>
|
||||
<div class="list-body">
|
||||
<div class="rank-item" v-for="(item,index) in newList" :key="index" :class="{'mine-item': item.isme }">
|
||||
<div class="other-rank" :class="{'mine-rank': item.isme }">
|
||||
<div class="ranking-number">
|
||||
<span v-if="item.isme" class="mine">我的成绩</span>
|
||||
<span v-if="item.isme" class="mine">{{lan.$t("wo")}}</span>
|
||||
<div v-else>
|
||||
<img src="@/static/images/rank_first.png" class="rank-img" v-if="index === 0" />
|
||||
<img src="@/static/images/rank_second.png" class="rank-img" v-else-if="index === 1" />
|
||||
@@ -39,6 +39,7 @@
|
||||
<script lang="ts">
|
||||
import { defineComponent, ref } from 'vue';
|
||||
import { UserOutlined } from '@ant-design/icons-vue';
|
||||
import { useI18n } from '@/utils/i18n';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'RankList',
|
||||
@@ -53,6 +54,7 @@ export default defineComponent({
|
||||
setup(props) {
|
||||
const deadLine = ref(4); // 写死的合格线
|
||||
const list = ref(props.list);
|
||||
const lan = useI18n()
|
||||
let mineRank = 0; // 自己的排名
|
||||
list.value!.forEach((element: any) => {
|
||||
if(element.isme) {
|
||||
@@ -67,6 +69,7 @@ export default defineComponent({
|
||||
return {
|
||||
newList,
|
||||
deadLine,
|
||||
lan
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user