|
|
@ -1,15 +1,9 @@ |
|
|
<template> |
|
|
<template> |
|
|
<view> |
|
|
<view> |
|
|
<view class="swiper-container"> |
|
|
<view class="swiper-container"> |
|
|
<swiper |
|
|
|
|
|
:indicator-dots="true" |
|
|
|
|
|
:autoplay="true" |
|
|
|
|
|
:interval="3000" |
|
|
|
|
|
:duration="1000" |
|
|
|
|
|
indicatorActiveColor="#FFAA48" |
|
|
|
|
|
:indicatorStyle="{bottom: '150rpx'}" |
|
|
|
|
|
indicatorInactiveColor="#fff" |
|
|
|
|
|
style="height: 412rpx;"> |
|
|
|
|
|
|
|
|
<swiper :indicator-dots="true" :autoplay="true" :interval="3000" :duration="1000" |
|
|
|
|
|
indicatorActiveColor="#FFAA48" :indicatorStyle="{bottom: '150rpx'}" indicatorInactiveColor="#fff" |
|
|
|
|
|
style="height: 412rpx;"> |
|
|
<swiper-item class="w-100 h-100" v-for="item in state.banner" :key="item.id"> |
|
|
<swiper-item class="w-100 h-100" v-for="item in state.banner" :key="item.id"> |
|
|
<image class="w-100 h-100" :src="item.image" mode=""></image> |
|
|
<image class="w-100 h-100" :src="item.image" mode=""></image> |
|
|
</swiper-item> |
|
|
</swiper-item> |
|
|
@ -23,9 +17,8 @@ |
|
|
<view class="explain"> |
|
|
<view class="explain"> |
|
|
<view class="explain-text"> |
|
|
<view class="explain-text"> |
|
|
<text>{{ configList?.partner_work_statement?.paramValueText }}</text> |
|
|
<text>{{ configList?.partner_work_statement?.paramValueText }}</text> |
|
|
<view class="font24 add-but col-white join" |
|
|
|
|
|
style="background-color: #999;color: #fff;" |
|
|
|
|
|
@click="">暂未开放 ></view> |
|
|
|
|
|
|
|
|
<view class="font24 add-but col-white join" style="background-color: #999;color: #fff;" |
|
|
|
|
|
@click="">暂未开放 ></view> |
|
|
<!-- <view class="font24 add-but col-white join" @click="handleJoin(1)">申请加入 ></view> --> |
|
|
<!-- <view class="font24 add-but col-white join" @click="handleJoin(1)">申请加入 ></view> --> |
|
|
</view> |
|
|
</view> |
|
|
<image class="explain-img" :src="configList?.partner_work_statement?.paramValueImage" |
|
|
<image class="explain-img" :src="configList?.partner_work_statement?.paramValueImage" |
|
|
@ -49,7 +42,7 @@ |
|
|
<view class="explain"> |
|
|
<view class="explain"> |
|
|
<view class="explain-text"> |
|
|
<view class="explain-text"> |
|
|
<text>{{ configList?.pet_teacher_statement?.paramValueText }}</text> |
|
|
<text>{{ configList?.pet_teacher_statement?.paramValueText }}</text> |
|
|
<view class="font24 add-but col-white join" @click="handleJoin(2)" |
|
|
|
|
|
|
|
|
<view class="font24 add-but col-white join" @click="handleBc" |
|
|
style="background: #FF7935">申请加入 ></view> |
|
|
style="background: #FF7935">申请加入 ></view> |
|
|
</view> |
|
|
</view> |
|
|
<image class="explain-img" :src="configList?.pet_teacher_statement?.paramValueImage" |
|
|
<image class="explain-img" :src="configList?.pet_teacher_statement?.paramValueImage" |
|
|
@ -57,13 +50,13 @@ |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
<!-- 申请之后 --> |
|
|
<!-- 申请之后 --> |
|
|
<view class="flex-rowl flex-wrap" v-if="userInfo.userBcs == 1" > |
|
|
|
|
|
|
|
|
<view class="flex-rowl flex-wrap" v-if="userInfo.userBcs == 1"> |
|
|
<view class="icon-list" v-for="item in iconState.list2" :key="item.id" @click="handleGoto(item)"> |
|
|
<view class="icon-list" v-for="item in iconState.list2" :key="item.id" @click="handleGoto(item)"> |
|
|
<up-image class="mb20" :show-loading="true" :src="item.image" width="68rpx" |
|
|
<up-image class="mb20" :show-loading="true" :src="item.image" width="68rpx" |
|
|
height="68rpx"></up-image> |
|
|
height="68rpx"></up-image> |
|
|
<view>{{ item.name }}</view> |
|
|
<view>{{ item.name }}</view> |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- <view class="icon-list"@click="handleGoto1()"> |
|
|
<!-- <view class="icon-list"@click="handleGoto1()"> |
|
|
<up-image class="mb20" :show-loading="true" width="68rpx" |
|
|
<up-image class="mb20" :show-loading="true" width="68rpx" |
|
|
height="68rpx"></up-image> |
|
|
height="68rpx"></up-image> |
|
|
@ -105,8 +98,14 @@ |
|
|
useStore |
|
|
useStore |
|
|
} from "vuex" |
|
|
} from "vuex" |
|
|
import configPopup from '@/components/configPopup.vue' |
|
|
import configPopup from '@/components/configPopup.vue' |
|
|
import { answeBaseIsFinish, answeTrainIsFinish } from '@/api/examination' |
|
|
|
|
|
import { code } from "../../uni_modules/uview-plus/libs/function/test"; |
|
|
|
|
|
|
|
|
import { |
|
|
|
|
|
answeBaseIsFinish, |
|
|
|
|
|
answeTrainIsFinish |
|
|
|
|
|
} from '@/api/examination' |
|
|
|
|
|
import { insertUser, udpateUser, getUserOne } from '@/api/userTeacher' |
|
|
|
|
|
import { |
|
|
|
|
|
code |
|
|
|
|
|
} from "../../uni_modules/uview-plus/libs/function/test"; |
|
|
const configPopupRef = ref(null) |
|
|
const configPopupRef = ref(null) |
|
|
|
|
|
|
|
|
const store = useStore(); |
|
|
const store = useStore(); |
|
|
@ -118,12 +117,12 @@ import { code } from "../../uni_modules/uview-plus/libs/function/test"; |
|
|
getpz() |
|
|
getpz() |
|
|
}) |
|
|
}) |
|
|
const userInfo = computed(() => { |
|
|
const userInfo = computed(() => { |
|
|
return store.getters.userInfo |
|
|
|
|
|
|
|
|
return store.state.user.userInfo |
|
|
}) |
|
|
}) |
|
|
const configList = computed(() => { |
|
|
const configList = computed(() => { |
|
|
return store.getters.configList |
|
|
return store.getters.configList |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 获取轮播图 |
|
|
// 获取轮播图 |
|
|
const getBanner = async () => { |
|
|
const getBanner = async () => { |
|
|
const res = await banner() |
|
|
const res = await banner() |
|
|
@ -197,13 +196,13 @@ import { code } from "../../uni_modules/uview-plus/libs/function/test"; |
|
|
const show = ref(true) |
|
|
const show = ref(true) |
|
|
const hhShow = ref(true) |
|
|
const hhShow = ref(true) |
|
|
const handleGoto = (item) => { |
|
|
const handleGoto = (item) => { |
|
|
|
|
|
|
|
|
if(item.name == '平台手册'){ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (item.name == '平台手册') { |
|
|
// pet_platform_introduction |
|
|
// pet_platform_introduction |
|
|
return configPopupRef.value.open('pet_platform_introduction') |
|
|
return configPopupRef.value.open('pet_platform_introduction') |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if(item.url) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (item.url) { |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
url: item.url |
|
|
url: item.url |
|
|
}) |
|
|
}) |
|
|
@ -230,35 +229,70 @@ import { code } from "../../uni_modules/uview-plus/libs/function/test"; |
|
|
show.value = false |
|
|
show.value = false |
|
|
} |
|
|
} |
|
|
const handleBc = async () => { |
|
|
const handleBc = async () => { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(!userInfo.value || !userInfo.value.userId){ |
|
|
|
|
|
|
|
|
if (!userInfo.value || !userInfo.value.userId) { |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
url: "/otherPages/authentication/list/index" |
|
|
url: "/otherPages/authentication/list/index" |
|
|
}) |
|
|
}) |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
uni.showLoading({ |
|
|
uni.showLoading({ |
|
|
title: '加载中...' |
|
|
title: '加载中...' |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
|
|
|
|
const data = await getUserOne(userInfo.value.userId) |
|
|
|
|
|
|
|
|
|
|
|
if(!data || !data.id){ |
|
|
|
|
|
|
|
|
|
|
|
uni.navigateTo({ |
|
|
|
|
|
url: "/otherPages/authentication/list/index" |
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
try{ |
|
|
|
|
|
let code1 = await answeBaseIsFinish({userId : userInfo.value.userId}) |
|
|
|
|
|
let code2 = await answeTrainIsFinish({userId : userInfo.value.userId}) |
|
|
|
|
|
if(code1 && code2){ |
|
|
|
|
|
|
|
|
if ([1, 2].includes(data.status)) { // status: 0-审核中 1-通过 2-不通过 |
|
|
|
|
|
uni.navigateTo({ |
|
|
|
|
|
url: `/otherPages/authentication/examination/trainCompleted/index?status=${data.status}` |
|
|
|
|
|
}) |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
let code1 = await answeBaseIsFinish({ |
|
|
|
|
|
userId: userInfo.value.userId |
|
|
|
|
|
}) |
|
|
|
|
|
let code2 = await answeTrainIsFinish({ |
|
|
|
|
|
userId: userInfo.value.userId |
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (code1 && code2) { |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
url: `/otherPages/authentication/examination/trainCompleted/index?status=0` |
|
|
url: `/otherPages/authentication/examination/trainCompleted/index?status=0` |
|
|
}) |
|
|
}) |
|
|
|
|
|
} else if(code1){ |
|
|
|
|
|
uni.navigateTo({ |
|
|
|
|
|
url: "/otherPages/authentication/examination/train" |
|
|
|
|
|
}) |
|
|
}else{ |
|
|
}else{ |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
url: "/otherPages/authentication/list/index" |
|
|
|
|
|
|
|
|
url: "/otherPages/authentication/examination/base" |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
|
}catch(e){ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} catch (e) { |
|
|
|
|
|
console.log(e); |
|
|
|
|
|
|
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
url: "/otherPages/authentication/list/index" |
|
|
url: "/otherPages/authentication/list/index" |
|
|
}) |
|
|
}) |
|
|
}finally{ |
|
|
|
|
|
|
|
|
} finally { |
|
|
uni.hideLoading() |
|
|
uni.hideLoading() |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|