Merge branch 'master' of https://gitea.hmily.club/haitu/aigc-h5
commit
4d04cbf9a1
|
|
@ -4,7 +4,7 @@
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<link rel="icon" href="/favicon.ico">
|
<link rel="icon" href="/favicon.ico">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, viewport-fit=cover" />
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, viewport-fit=cover" />
|
||||||
<title>aigc</title>
|
<title>海兔AIGC</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id="app"></div>
|
<div id="app"></div>
|
||||||
|
|
|
||||||
|
|
@ -158,7 +158,7 @@ const reRenderEmailGetcodebtn = () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
const validate = () => {
|
const validate = () => {
|
||||||
if (loginType == 'tel') {
|
if (loginType.value == 'tel') {
|
||||||
if (!telReg.test(tel.value)) {
|
if (!telReg.test(tel.value)) {
|
||||||
showToast('请输入正确的手机号码!');
|
showToast('请输入正确的手机号码!');
|
||||||
return false;
|
return false;
|
||||||
|
|
@ -168,7 +168,7 @@ const validate = () => {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (loginType == 'email') {
|
if (loginType.value == 'email') {
|
||||||
if (!emailReg.test(email.value)) {
|
if (!emailReg.test(email.value)) {
|
||||||
showToast('请输入正确的邮箱地址!');
|
showToast('请输入正确的邮箱地址!');
|
||||||
return false;
|
return false;
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,7 @@ import { localCache } from './cache';
|
||||||
import router from "@/router";
|
import router from "@/router";
|
||||||
import { showToast } from 'vant';
|
import { showToast } from 'vant';
|
||||||
import { useAuthModal } from '@/stores/authModal';
|
import { useAuthModal } from '@/stores/authModal';
|
||||||
|
import { useUserInfo } from '@/stores/userInfo';
|
||||||
import hostAPI from '@/config/host.config'
|
import hostAPI from '@/config/host.config'
|
||||||
|
|
||||||
export default function () {
|
export default function () {
|
||||||
|
|
@ -16,6 +17,7 @@ export default function () {
|
||||||
let requestCount = 0;//请求数量
|
let requestCount = 0;//请求数量
|
||||||
|
|
||||||
const authModal = useAuthModal();
|
const authModal = useAuthModal();
|
||||||
|
const userInfo = useUserInfo();
|
||||||
|
|
||||||
const showLoading = ()=>{
|
const showLoading = ()=>{
|
||||||
if (requestCount === 0) {
|
if (requestCount === 0) {
|
||||||
|
|
@ -77,6 +79,7 @@ export default function () {
|
||||||
showToast('账号过期或异地登录, 请重新登录');
|
showToast('账号过期或异地登录, 请重新登录');
|
||||||
localCache.remove('auth');
|
localCache.remove('auth');
|
||||||
localCache.remove('userInfo');
|
localCache.remove('userInfo');
|
||||||
|
userInfo.updateUserInfo({});
|
||||||
authModal.setAuthModalType('login');
|
authModal.setAuthModalType('login');
|
||||||
authModal.showAuthModal();
|
authModal.showAuthModal();
|
||||||
// router.replace({name: 'Home', params: {auth: 'over'}});
|
// router.replace({name: 'Home', params: {auth: 'over'}});
|
||||||
|
|
@ -97,6 +100,7 @@ export default function () {
|
||||||
showToast('账号过期或异地登录, 请重新登录');
|
showToast('账号过期或异地登录, 请重新登录');
|
||||||
localCache.remove('auth');
|
localCache.remove('auth');
|
||||||
localCache.remove('userInfo');
|
localCache.remove('userInfo');
|
||||||
|
userInfo.updateUserInfo({});
|
||||||
authModal.setAuthModalType('login');
|
authModal.setAuthModalType('login');
|
||||||
authModal.showAuthModal();
|
authModal.showAuthModal();
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import { localCache } from '@/io/cache'
|
||||||
import { showToast } from 'vant'
|
import { showToast } from 'vant'
|
||||||
|
|
||||||
import { useAuthModal } from '@/stores/authModal';
|
import { useAuthModal } from '@/stores/authModal';
|
||||||
|
import { useUserInfo } from '@/stores/userInfo';
|
||||||
|
|
||||||
|
|
||||||
const service = axios.create({
|
const service = axios.create({
|
||||||
|
|
@ -38,6 +38,7 @@ service.interceptors.response.use(
|
||||||
const { requestBaseUrl } = response.config
|
const { requestBaseUrl } = response.config
|
||||||
const res = response.data
|
const res = response.data
|
||||||
const authModal = useAuthModal();
|
const authModal = useAuthModal();
|
||||||
|
const userInfo = useUserInfo();
|
||||||
if (requestBaseUrl == 'chat') {
|
if (requestBaseUrl == 'chat') {
|
||||||
return res
|
return res
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -45,6 +46,7 @@ service.interceptors.response.use(
|
||||||
if (res.status == 401) {
|
if (res.status == 401) {
|
||||||
authModal.setAuthModalType('login');
|
authModal.setAuthModalType('login');
|
||||||
authModal.showAuthModal();
|
authModal.showAuthModal();
|
||||||
|
userInfo.updateUserInfo({});
|
||||||
localCache.remove('auth');
|
localCache.remove('auth');
|
||||||
localCache.remove('userInfo');
|
localCache.remove('userInfo');
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -58,6 +60,7 @@ service.interceptors.response.use(
|
||||||
},
|
},
|
||||||
error => {
|
error => {
|
||||||
const authModal = useAuthModal();
|
const authModal = useAuthModal();
|
||||||
|
const userInfo = useUserInfo();
|
||||||
|
|
||||||
if (error.message == 'canceled') return Promise.reject(error)
|
if (error.message == 'canceled') return Promise.reject(error)
|
||||||
const res = error.response?.data
|
const res = error.response?.data
|
||||||
|
|
@ -67,6 +70,7 @@ service.interceptors.response.use(
|
||||||
if (res.errcode == 401) {
|
if (res.errcode == 401) {
|
||||||
authModal.setAuthModalType('login');
|
authModal.setAuthModalType('login');
|
||||||
authModal.showAuthModal();
|
authModal.showAuthModal();
|
||||||
|
userInfo.updateUserInfo({});
|
||||||
localCache.remove('auth');
|
localCache.remove('auth');
|
||||||
localCache.remove('userInfo');
|
localCache.remove('userInfo');
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
|
|
@ -185,15 +185,17 @@ const router = createRouter({
|
||||||
path: "training",
|
path: "training",
|
||||||
name: "Training",
|
name: "Training",
|
||||||
meta: {
|
meta: {
|
||||||
title: "AI培训",
|
title: "AI培训",
|
||||||
|
group: 'training'
|
||||||
},
|
},
|
||||||
component: () => import("@/views/training/index.vue"),
|
component: () => import("@/views/training/home.vue"),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "vip",
|
path: "vip",
|
||||||
name: "Vip",
|
name: "Vip",
|
||||||
meta: {
|
meta: {
|
||||||
title: "会员专区",
|
title: "会员专区",
|
||||||
|
group: 'vip'
|
||||||
},
|
},
|
||||||
component: () => import("@/views/vip/index.vue"),
|
component: () => import("@/views/vip/index.vue"),
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="h-full flex items-center">
|
<div class="flex py-60px">
|
||||||
<div class="px-59px relative">
|
<div class="px-59px relative">
|
||||||
<div class="absolute h-120px w-160px z-0 left-40px -top-30px">
|
<div class="absolute h-120px w-160px z-0 left-40px -top-30px">
|
||||||
<div
|
<div
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<Layout>
|
<Layout path="/communication">
|
||||||
<div class="h-full flex flex-col justify-center text-white">
|
<div class="h-full flex flex-col justify-center text-white">
|
||||||
<TitleComp title="AI传播" :src="TitleSrc"></TitleComp>
|
<TitleComp title="AI传播" :src="TitleSrc"></TitleComp>
|
||||||
<div class="mt-34px text-27px font-bold">AI虚拟人直播</div>
|
<div class="mt-34px text-27px font-bold">AI虚拟人直播</div>
|
||||||
|
|
|
||||||
|
|
@ -1,23 +0,0 @@
|
||||||
<template>
|
|
||||||
<Layout>
|
|
||||||
<div class="h-full flex flex-col justify-center text-white">
|
|
||||||
<TitleComp title="AI培训" :src="TitleSrc"></TitleComp>
|
|
||||||
<div class="mt-38px text-27px font-bold">AI培训课程</div>
|
|
||||||
<div class="text-22px mt-36px text-[#C2C5CA] leading-29px">
|
|
||||||
在AI助理板块,用户可以上传文件给AI翻阅并帮助您解决问题,您可以自己输入关键字或者使用自带的prompt模板在AI助理板块,用户可以上传文件给AI翻阅并帮助您解决问题,您可以自己输入关键字或者使用自带的prompt模板在AI
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="mt-69px">
|
|
||||||
<img
|
|
||||||
class="w-670px mx-auto inline-block"
|
|
||||||
src="@/assets/images/ai_stream_01.png"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</Layout>
|
|
||||||
</template>
|
|
||||||
<script setup>
|
|
||||||
import TitleComp from '@/views/home/components/title.vue'
|
|
||||||
import TitleSrc from '@/assets/images/AISTREAM.png'
|
|
||||||
import Layout from '@/views/home/components/layout.vue'
|
|
||||||
</script>
|
|
||||||
|
|
@ -58,7 +58,7 @@
|
||||||
import Assistant from '@/views/assistant/index.vue'
|
import Assistant from '@/views/assistant/index.vue'
|
||||||
import Business from '@/views/business/index.vue'
|
import Business from '@/views/business/index.vue'
|
||||||
import Stream from '@/views/communication/index.vue'
|
import Stream from '@/views/communication/index.vue'
|
||||||
import Course from '@/views/course/index.vue'
|
import Training from '@/views/training/index.vue'
|
||||||
|
|
||||||
import { Swiper, SwiperSlide } from 'swiper/vue'
|
import { Swiper, SwiperSlide } from 'swiper/vue'
|
||||||
import { Mousewheel, Pagination } from 'swiper/modules'
|
import { Mousewheel, Pagination } from 'swiper/modules'
|
||||||
|
|
@ -83,7 +83,7 @@ const list = [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'AI培训',
|
title: 'AI培训',
|
||||||
component: Course,
|
component: Training,
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,23 @@
|
||||||
|
<template>
|
||||||
|
<div class="pageContainer">
|
||||||
|
<div class="tips">敬请期待~</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.pageContainer{
|
||||||
|
.tips{
|
||||||
|
width: 100%;
|
||||||
|
height: 50vh;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 30px;
|
||||||
|
color: #FFF;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
@ -1,23 +1,23 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="pageContainer">
|
<Layout path="/training">
|
||||||
<div class="tips">敬请期待~</div>
|
<div class="h-full flex flex-col justify-center text-white">
|
||||||
|
<TitleComp title="AI培训" :src="TitleSrc"></TitleComp>
|
||||||
|
<div class="mt-38px text-27px font-bold">AI培训课程</div>
|
||||||
|
<div class="text-22px mt-36px text-[#C2C5CA] leading-29px">
|
||||||
|
在AI助理板块,用户可以上传文件给AI翻阅并帮助您解决问题,您可以自己输入关键字或者使用自带的prompt模板在AI助理板块,用户可以上传文件给AI翻阅并帮助您解决问题,您可以自己输入关键字或者使用自带的prompt模板在AI
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="mt-69px">
|
||||||
|
<img
|
||||||
|
class="w-670px mx-auto inline-block"
|
||||||
|
src="@/assets/images/ai_stream_01.png"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</Layout>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
|
import TitleComp from '@/views/home/components/title.vue'
|
||||||
|
import TitleSrc from '@/assets/images/AISTREAM.png'
|
||||||
|
import Layout from '@/views/home/components/layout.vue'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.pageContainer{
|
|
||||||
.tips{
|
|
||||||
width: 100%;
|
|
||||||
height: 50vh;
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
|
||||||
font-size: 30px;
|
|
||||||
color: #FFF;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
Loading…
Reference in New Issue