Explorar o código

讲义埋点/三方登陆

canghailong hai 5 meses
pai
achega
4f4afc5f24

+ 10 - 7
src/router/index.js

@@ -1,4 +1,3 @@
- 
 import { createRouter, createWebHistory } from 'vue-router'
 import { notification } from 'ant-design-vue'
 import NProgress from 'nprogress'
@@ -13,6 +12,7 @@ import userRoutes from '@/config/route'
 import tool from '@/utils/tool'
 import fullPageTool from './fullPageTool'
 import { cloneDeep } from 'lodash-es'
+import { afterLogin } from './unilLogin'
 const modules = import.meta.glob('/src/views/**/**.vue')
 import { globalStore, searchStore } from '@/store'
 
@@ -28,7 +28,7 @@ const routes_404 = [
 	}
 ]
 // 系统路由
-const routes = [...systemRouter, ...whiteListRouters, ...routes_404,...forum,...student]
+const routes = [...systemRouter, ...whiteListRouters, ...routes_404, ...forum, ...student]
 
 const router = createRouter({
 	history: createWebHistory(),
@@ -65,7 +65,6 @@ router.beforeEach(async (to, from, next) => {
 		// NProgress.done()
 		return false
 	}
-
 	const token = tool.data.get('TOKEN')
 	if (to.path === '/slogin') {
 		// 当用户输入了login路由,将其跳转首页即可
@@ -81,11 +80,15 @@ router.beforeEach(async (to, from, next) => {
 		next()
 		return false
 	} else {
-		if (token) {
-			// 有token的时候才保存登录之前要访问的页面
-			tool.data.set('LAST_VIEWS_PATH', to.fullPath)
+		if (to.query.token) {
+			afterLogin(to.query.token)
+		} else {
+			if (token) {
+				// 有token的时候才保存登录之前要访问的页面
+				tool.data.set('LAST_VIEWS_PATH', to.fullPath)
+			}
+			fullPageTool.check(to)
 		}
-		fullPageTool.check(to)
 	}
 	if (!token) {
 		next({

+ 0 - 4
src/views/tlogin/util.js → src/router/unilLogin.js

@@ -49,8 +49,4 @@ export const afterLogin = async (loginToken) => {
 		// 设置字典到store中
 		tool.data.set('DICT_TYPE_TREE_DATA', data)
 	})
-	await router.replace({
-		path: "portal"
-	})
-	location.reload()
 }

+ 4 - 11
src/views/student/classCentre/handouts.vue

@@ -78,18 +78,11 @@
 		link.click()
 		document.body.removeChild(link)
 		message.success('开始下载文件')
-		addClassPlan()
+		addScrollPlan(2)
 	}
 	const nowTimesStr = Date.now()
 	const outNowTimesStr = ref()
-	const addClassPlan = () => {
-		classCentre.classPlanAdd({
-			hourId: props.hourId,
-			type: 2,
-			funcType: 2
-		})
-	}
-	const addScrollPlan = () => {
+	const addScrollPlan = (type) => {
 		const el = pdfRef.value?.$el
 		if (el && el.clientHeight == el.scrollHeight) {
 			maxStr.value = 100
@@ -98,7 +91,7 @@
 			progress: showPdf.value ? maxStr.value : 0,
 			hourId: props.hourId,
 			stayTime: outNowTimesStr.value - nowTimesStr,
-			type: 1,
+			type: type,
 			funcType: 2,
 			startTime: parseFloat(props.videoObj?.initialtime ?? 0),
 			endTime: Math.round(props.videoObj.currentTime * 1000),
@@ -110,7 +103,7 @@
 	}
 	onBeforeUnmount(() => {
 		outNowTimesStr.value = Date.now()
-		addScrollPlan()
+		addScrollPlan(1)
 	})
 </script>
 <style scoped lang="less">

+ 16 - 14
src/views/student/classCentre/index.vue

@@ -71,7 +71,7 @@
 						@videoSpeed="videoSpeed"
 						@videoStopTime="videoStopTime"
 						:videoObj="videoObj"
-						:classDetailParams="classDetailParams"
+						:classDetailParams="classDetailParams(2)"
 					></rightMenu>
 				</a-card>
 				<a-card :bordered="false" class="mt-3">
@@ -380,7 +380,7 @@
 				stayTime: outNowTimesStr.value - nowTimesStr,
 				type: type,
 				funcType: 1,
-				...classDetailParams.value
+				...classDetailParams.value(1)
 			})
 		}
 	}
@@ -399,23 +399,25 @@
 			})
 	}
 	const classDetailParams = computed(() => {
-		return {
-			hourName: classHourData.value?.name,
-			chapterName: classHourData.value?.name,
-			courseName: classDetail.value?.courseName,
-			hourId: classHourData.value?.id,
-			chapterId: selectedKeys.value[0],
-			courseId: classDetail.value?.courseId,
-			fileId: classHourData.value?.courseRelates.find((r) => r.funcType == 1)?.relateId,
-			fileName: classHourData.value?.courseRelates.find((r) => r.funcType == 1)?.name,
-			filePath: classHourData.value?.courseRelates.find((r) => r.funcType == 1)?.url,
-			extendName: classHourData.value?.courseRelates.find((r) => r.funcType == 1)?.extendName,
+		return (funcType)=>{
+			return {
+				hourName: classHourData.value?.name,
+				chapterName: classHourData.value?.name,
+				courseName: classDetail.value?.courseName,
+				hourId: classHourData.value?.id,
+				chapterId: selectedKeys.value[0],
+				courseId: classDetail.value?.courseId,
+				fileId: classHourData.value?.courseRelates.find((r) => r.funcType == funcType)?.relateId,
+				fileName: classHourData.value?.courseRelates.find((r) => r.funcType == funcType)?.name,
+				filePath: classHourData.value?.courseRelates.find((r) => r.funcType == funcType)?.url,
+				extendName: classHourData.value?.courseRelates.find((r) => r.funcType == funcType)?.extendName,
+			}
 		}
 	})
 	//足迹
 	const footprintClassAdd = () => {
 		classCentre.footprintClassAdd({
-			...classDetailParams.value
+			...classDetailParams.value(1)
 		})
 	}
 	// 监听消息

+ 0 - 77
src/views/tlogin/callback.vue

@@ -1,77 +0,0 @@
-<template>
-	<div class="login_background">
-		<div class="login_background_front"></div>
-		<div class="login_main">
-			<div class="login-form">
-				<a-card>
-					<div class="login-header">
-						<h2>三方登录</h2>
-					</div>
-					<a-spin tip="正在登录中...">
-						<div class="h-[300px]">
-							<a-skeleton />
-						</div>
-					</a-spin>
-				</a-card>
-			</div>
-		</div>
-	</div>
-</template>
-
-<script setup name="loginCallback">
-	import { message } from 'ant-design-vue'
-	import tool from '@/utils/tool'
-	import router from '@/router'
-	import thirdApi from '@/api/auth/thirdApi'
-	import loginApi from '@/api/auth/loginApi'
-	import userCenterApi from '@/api/sys/userCenterApi'
-	import dictApi from '@/api/dev/dictApi'
-	import { onMounted } from 'vue'
-
-	onMounted(() => {
-		// 获取当前url
-		const url = new URL(window.location.href)
-		let argLength = 0
-		const params = {}
-		url.searchParams.forEach((value, key) => {
-			argLength += 1
-			params[key] = value
-		})
-		// 当然了,不可能只有一个参数
-		if (argLength < 2) {
-			window.location.href = '/login'
-			return
-		}
-
-		thirdApi
-			.thirdCallback(params)
-			.then((data) => {
-				tool.data.set('TOKEN', data)
-				// 获取登录的用户信息
-				loginApi.getLoginUser().then((loginUser) => {
-					tool.data.set('USER_INFO', loginUser)
-				})
-				userCenterApi.userLoginMenu().then((menu) => {
-					const indexMenu = menu[0].children[0].path
-					tool.data.set('MENU', menu)
-					// 重置系统默认应用
-					tool.data.set('SNOWY_MENU_MODULE_ID', menu[0].id)
-					router.replace({
-						path: indexMenu
-					})
-					message.success('登录成功')
-					dictApi.dictTree().then((dictData) => {
-						// 设置字典到store中
-						tool.data.set('DICT_TYPE_TREE_DATA', dictData)
-					})
-				})
-			})
-			.catch(() => {
-				window.location.href = '/login'
-			})
-	})
-</script>
-
-<style lang="less" scoped>
-	@import 'login';
-</style>

+ 0 - 152
src/views/tlogin/login.less

@@ -1,152 +0,0 @@
-.login-icon-gray {
-  color: rgba(0, 0, 0, 0.25);
-}
-.login-validCode-img {
-  border: 1px solid var(--border-color-split);
-  cursor: pointer;
-  width: 100%;
-  height: 40px;
-}
-.login_background {
-  width: 100%;
-	min-height: 100vh;
-  overflow: hidden;
-  background-size: cover;
-  background-position: center;
-  background-image: url(/img/login_background.png);
-}
-.login_background_front {
-  width: 450px;
-  height: 450px;
-  margin-left: 100px;
-  margin-top: 15%;
-  overflow: hidden;
-  /*position: relative;*/
-  background-size: cover;
-  background-position: center;
-  background-image: url(/img/login_background_front.png);
-  animation-name: myfirst;
-  animation-duration: 5s;
-  animation-timing-function: linear;
-  animation-delay: 1s;
-  animation-iteration-count: infinite;
-  animation-direction: alternate;
-  animation-play-state: running;
-}
-@keyframes myfirst {
-  0% {
-    left: 0px;
-    top: 0px;
-  }
-  50% {
-    left: 50px;
-    top: 0px;
-  }
-  100% {
-    left: 0px;
-    top: 0px;
-  }
-}
-@-webkit-keyframes myfirst /* Safari and Chrome */ {
-  0% {
-    left: 0px;
-    top: 0px;
-  }
-  50% {
-    left: 50px;
-    top: 0px;
-  }
-  100% {
-    left: 0px;
-    top: 0px;
-  }
-}
-.login_adv__title h2 {
-  font-size: 40px;
-}
-.login_adv__title h4 {
-  font-size: 18px;
-  margin-top: 10px;
-  font-weight: normal;
-}
-.login_adv__title p {
-  font-size: 14px;
-  margin-top: 10px;
-  line-height: 1.8;
-  color: rgba(255, 255, 255, 0.6);
-}
-.login_adv__title div {
-  margin-top: 10px;
-  display: flex;
-  align-items: center;
-}
-.login_adv__title div span {
-  margin-right: 15px;
-}
-.login_adv__title div i {
-  font-size: 40px;
-}
-.login_adv__title div i.add {
-  font-size: 20px;
-  color: rgba(255, 255, 255, 0.6);
-}
-/*background-image:linear-gradient(transparent, #000);*/
-.login_main {
-  flex: 1;
-  overflow: auto;
-  display: flex;
-}
-.login-form {
-  top: 15%;
-  right: 15%;
-  position: absolute;
-  width: 450px;
-  margin-left: 10%;
-  margin-top: 20px;
-  padding: 10px 0;
-}
-.login-header {
-  margin-bottom: 20px;
-}
-.login-header .logo {
-  display: flex;
-  align-items: center;
-}
-.login-header .logo img {
-  width: 35px;
-  height: 35px;
-  vertical-align: bottom;
-  margin-right: 10px;
-}
-.login-header .logo label {
-  font-size: 24px;
-}
-.login-header h2 {
-  font-size: 24px;
-  font-weight: bold;
-  margin-top: 40px;
-}
-.login_config {
-  position: absolute;
-  top: 20px;
-  right: 20px;
-}
-@media (max-width: 1200px) {
-  .login-form {
-    width: 340px;
-  }
-}
-@media (max-width: 1000px) {
-  .login_main {
-    display: block;
-  }
-  .login_background_front {
-    display: none;
-  }
-  .login-form {
-    width: 100%;
-    padding: 20px 40px;
-    right: 0 !important;
-    top: 0 !important;
-  }
-}

+ 0 - 203
src/views/tlogin/login.vue

@@ -1,203 +0,0 @@
-<template>
-	<div class="login_background">
-		<div style="display: flex;width: 100%; height: 100%; justify-content: center; align-items: center">
-				<a-card>
-					<div style="margin-bottom: 20px">
-						<span style="font-size: 20px;">教师登录</span>
-					</div>
-
-					<a-form ref="loginForm" :model="ruleForm" :rules="rules">
-						<a-form-item name="account">
-							<a-input
-								v-model:value="ruleForm.account"
-								:placeholder="$t('login.accountPlaceholder')"
-								size="large"
-								@keyup.enter="login"
-							>
-								<template #prefix>
-									<UserOutlined class="login-icon-gray" />
-								</template>
-							</a-input>
-						</a-form-item>
-						<a-form-item name="password">
-							<a-input-password
-								v-model:value="ruleForm.password"
-								:placeholder="$t('login.PWPlaceholder')"
-								size="large"
-								autocomplete="off"
-								@keyup.enter="login"
-							>
-								<template #prefix>
-									<LockOutlined class="login-icon-gray" />
-								</template>
-							</a-input-password>
-						</a-form-item>
-						<a-form-item name="validCode" v-if="captchaOpen === 'true'">
-							<a-row :gutter="8">
-								<a-col :span="17">
-									<a-input
-										v-model:value="ruleForm.validCode"
-										:placeholder="$t('login.validLaceholder')"
-										size="large"
-										@keyup.enter="login"
-									>
-										<template #prefix>
-											<verified-outlined class="login-icon-gray" />
-										</template>
-									</a-input>
-								</a-col>
-								<a-col :span="7">
-									<img :src="validCodeBase64" class="login-validCode-img" @click="loginCaptcha" />
-								</a-col>
-							</a-row>
-						</a-form-item>
-
-						<a-form-item>
-							<a-button style="position: absolute; width: 100%; buttom:0px   " type="primary"  :loading="loading" round size="large" @click="login"
-							>{{ $t('login.signIn') }}
-							</a-button>
-						</a-form-item>
-					</a-form>
-				</a-card>
-		</div>
-	</div>
-</template>
-
-<script>
-	import loginApi from '@/api/auth/loginApi'
-	import phoneLoginForm from './phoneLoginForm.vue'
-	import threeLogin from './threeLogin.vue'
-	import smCrypto from '@/utils/smCrypto'
-	import { required } from '@/utils/formRules'
-	import { afterLogin } from './util'
-	import config from '@/config'
-	import configApi from '@/api/dev/configApi'
-	import tool from '@/utils/tool'
-	import { globalStore, iframeStore, keepAliveStore, viewTagsStore } from '@/store'
-	import { mapActions, mapState } from 'pinia'
-
-	export default {
-		name: 'Login',
-		components: {
-			phoneLoginForm,
-			threeLogin
-		},
-		data() {
-			return {
-				activeKey: 'userAccount',
-				captchaOpen: config.SYS_BASE_CONFIG.SNOWY_SYS_DEFAULT_CAPTCHA_OPEN,
-				validCodeBase64: '',
-				ruleForm: {
-					account: 'superAdmin',
-					password: '123456',
-					validCode: '',
-					validCodeReqNo: '',
-					autologin: false
-				},
-				rules: {
-					account: [required(this.$t('login.accountError'), 'blur')],
-					password: [required(this.$t('login.PWError'), 'blur')]
-				},
-				loading: false,
-				config: {
-					lang: tool.data.get('APP_LANG') || this.$CONFIG.LANG,
-					theme: tool.data.get('APP_THEME') || 'default'
-				},
-				lang: [
-					{
-						name: '简体中文',
-						value: 'zh-cn'
-					},
-					{
-						name: 'English',
-						value: 'en'
-					}
-				]
-			}
-		},
-		computed: {
-			...mapState(globalStore, ['sysBaseConfig']),
-		},
-		watch: {
-			'config.theme': function (val) {
-				document.body.setAttribute('data-theme', val)
-			},
-			'config.lang': function (val) {
-				this.$i18n.locale = val
-				tool.data.set('APP_LANG', val)
-			}
-		},
-		created() {
-			this.clearViewTags()
-			this.clearKeepLive()
-			this.clearIframeList()
-		},
-		mounted() {
-			let formData = ref(config.SYS_BASE_CONFIG)
-			configApi.configSysBaseList().then((data) => {
-				if (data) {
-					data.forEach((item) => {
-						formData.value[item.configKey] = item.configValue
-					})
-					this.captchaOpen = formData.value.SNOWY_SYS_DEFAULT_CAPTCHA_OPEN
-					tool.data.set('SNOWY_SYS_BASE_CONFIG', formData.value)
-					this.setSysBaseConfig(formData.value)
-					this.refreshSwitch()
-				}
-			})
-		},
-		methods: {
-			...mapActions(keepAliveStore, ['clearKeepLive']),
-			...mapActions(viewTagsStore, ['clearViewTags']),
-			...mapActions(iframeStore, ['clearIframeList']),
-			...mapActions(globalStore, ['setSysBaseConfig']),
-			// 通过开关加载内容
-			refreshSwitch() {
-				// 判断是否开启验证码
-				if (this.captchaOpen === 'true') {
-					// 加载验证码
-					this.loginCaptcha()
-					// 加入校验
-					this.rules.validCode = [required(this.$t('login.validError'), 'blur')]
-				}
-			},
-			// 获取验证码
-			loginCaptcha() {
-				loginApi.getPicCaptcha().then((data) => {
-					this.validCodeBase64 = data.validCodeBase64
-					this.ruleForm.validCodeReqNo = data.validCodeReqNo
-				})
-			},
-			// 用户名密码登录
-			async login() {
-				this.$refs.loginForm.validate().then(async () => {
-					this.loading = true
-					const loginData = {
-						account: this.ruleForm.account,
-						// 密码进行SM2加密,传输过程中看到的只有密文,后端存储使用hash
-						password: smCrypto.doSm2Encrypt(this.ruleForm.password),
-						validCode: this.ruleForm.validCode,
-						validCodeReqNo: this.ruleForm.validCodeReqNo,
-						//根据平台不同传不同参0后台(管理员)1老师2学生
-						eduIdentity : 1
-					}
-					// 获取token
-					try {
-						const loginToken = await loginApi.login(loginData)
-						afterLogin(loginToken)
-					} catch (err) {
-						this.loading = false
-						this.loginCaptcha()
-					}
-				})
-			},
-			configLang(key) {
-				this.config.lang = key
-			}
-		}
-	}
-</script>
-
-<style lang="less">
-	@import 'login';
-</style>

+ 0 - 168
src/views/tlogin/phoneLoginForm.vue

@@ -1,168 +0,0 @@
-<template>
-	<a-form ref="phoneLoginFormRef" :model="phoneFormData" :rules="formRules">
-		<a-form-item name="phone">
-			<a-input v-model:value="phoneFormData.phone" :placeholder="$t('login.phonePlaceholder')" size="large">
-				<template #prefix>
-					<mobile-outlined class="text-black text-opacity-25" />
-				</template>
-			</a-input>
-		</a-form-item>
-		<a-form-item name="phoneValidCode">
-			<a-row :gutter="8">
-				<a-col :span="17">
-					<a-input
-						v-model:value="phoneFormData.phoneValidCode"
-						:placeholder="$t('login.smsCodePlaceholder')"
-						size="large"
-					>
-						<template #prefix>
-							<mail-outlined class="text-black text-opacity-25" />
-						</template>
-					</a-input>
-				</a-col>
-				<a-col :span="7">
-					<a-button size="large" style="width: 100%" @click="getPhoneValidCode" :disabled="state.smsSendBtn">
-						{{ (!state.smsSendBtn && $t('login.getSmsCode')) || state.time + ' s' }}
-					</a-button>
-				</a-col>
-			</a-row>
-		</a-form-item>
-		<a-form-item>
-			<a-button type="primary" style="width: 100%" :loading="loading" round size="large" @click="submitLogin">
-				{{ $t('login.signIn') }}
-			</a-button>
-		</a-form-item>
-	</a-form>
-	<a-modal
-		v-model:visible="visible"
-		:width="400"
-		:title="$t('login.machineValidation')"
-		@cancel="handleCancel"
-		@ok="handleOk"
-	>
-		<a-form ref="phoneLoginFormModalRef" :model="phoneFormModalData" :rules="formModalRules">
-			<a-form-item name="validCode">
-				<a-row :gutter="8">
-					<a-col :span="17">
-						<a-input
-							v-model:value="phoneFormModalData.validCode"
-							:placeholder="$t('login.validLaceholder')"
-							size="large"
-						>
-							<template #prefix>
-								<verified-outlined class="text-black text-opacity-25" />
-							</template>
-						</a-input>
-					</a-col>
-					<a-col :span="7">
-						<img
-							:src="validCodeBase64"
-							style="border: 1px solid var(--border-color-split); cursor: pointer; width: 100%; height: 40px"
-							@click="getPhonePicCaptcha"
-						/>
-					</a-col>
-				</a-row>
-			</a-form-item>
-		</a-form>
-	</a-modal>
-</template>
-
-<script setup name="smsLoginForm">
-	import { message } from 'ant-design-vue'
-	import { required, rules } from '@/utils/formRules'
-	import loginApi from '@/api/auth/loginApi'
-	import { afterLogin } from './util'
-
-	const phoneLoginFormRef = ref()
-	const phoneFormData = ref({})
-	const loading = ref(false)
-	let state = ref({
-		time: 60,
-		smsSendBtn: false
-	})
-	let formRules = ref({})
-	const phoneValidCodeReqNo = ref('')
-
-	// 点击获取短信验证码
-	const getPhoneValidCode = () => {
-		formRules.value.phone = [required('请输入11位手机号'), rules.phone]
-		delete formRules.value.phoneValidCode
-		phoneLoginFormRef.value.validate().then(() => {
-			// 显示弹框
-			visible.value = true
-			// 获取内部图片验证码
-			getPhonePicCaptcha()
-		})
-	}
-	// 点击登录按钮
-	const submitLogin = async () => {
-		formRules.value.phone = [required('请输入11位手机号'), rules.phone]
-		formRules.value.phoneValidCode = [required('请输入短信验证码'), rules.number]
-
-		const validate = await phoneLoginFormRef.value.validate().catch(() => {})
-		if (!validate) return false
-
-		phoneFormData.value.validCode = phoneFormData.value.phoneValidCode
-		// delete phoneFormData.value.phoneValidCode
-		phoneFormData.value.validCodeReqNo = phoneValidCodeReqNo.value
-
-		loading.value = true
-		try {
-			const token = await loginApi.loginByPhone(phoneFormData.value)
-			afterLogin(token)
-		} catch (err) {
-			loading.value = false
-		}
-	}
-
-	// 弹框的
-	const visible = ref(false)
-	const phoneLoginFormModalRef = ref()
-	const phoneFormModalData = ref({})
-	const validCodeBase64 = ref('')
-	const validCodeReqNo = ref('')
-	const formModalRules = {
-		validCode: [required('请输入图形验证码'), rules.lettersNum]
-	}
-	const getPhonePicCaptcha = () => {
-		loginApi.getPicCaptcha().then((data) => {
-			validCodeBase64.value = data.validCodeBase64
-			phoneFormModalData.value.validCodeReqNo = data.validCodeReqNo
-		})
-	}
-	const handleCancel = () => {
-		visible.value = false
-	}
-	const handleOk = () => {
-		// 获取到里面的验证码,并发送短信
-		phoneLoginFormModalRef.value.validate().then(() => {
-			visible.value = false
-			// 发送短信,首先拿到刚刚输入的手机号
-			phoneFormModalData.value.phone = phoneFormData.value.phone
-			// 禁用发送按钮,并设置为倒计时
-			state.value.smsSendBtn = true
-			const interval = window.setInterval(() => {
-				if (state.value.time-- <= 0) {
-					state.value.time = 60
-					state.value.smsSendBtn = false
-					window.clearInterval(interval)
-				}
-			}, 1000)
-			const hide = message.loading('验证码发送中..', 0)
-
-			loginApi
-				.getPhoneValidCode(phoneFormModalData.value)
-				.then((data) => {
-					phoneValidCodeReqNo.value = data
-					visible.value = false
-					setTimeout(hide, 500)
-					phoneFormModalData.value.validCode = ''
-				})
-				.catch(() => {
-					setTimeout(hide, 100)
-					clearInterval(interval)
-					state.value.smsSendBtn = false
-				})
-		})
-	}
-</script>

+ 0 - 24
src/views/tlogin/threeLogin.vue

@@ -1,24 +0,0 @@
-<template>
-	<a-divider>{{ $t('login.signInOther') }}</a-divider>
-	<div class="login-oauth layout-center">
-		<a-space align="start">
-			<a @click="getLoginRenderUrl('gitee')"><GiteeIcon /></a>
-			<a-button type="primary" shape="circle">
-				<wechat-filled />
-			</a-button>
-		</a-space>
-	</div>
-</template>
-
-<script setup name="threeLogin">
-	import thirdApi from '@/api/auth/thirdApi'
-
-	const getLoginRenderUrl = (platform) => {
-		const param = {
-			platform: platform
-		}
-		thirdApi.thirdRender(param).then((data) => {
-			window.location.href = data.authorizeUrl
-		})
-	}
-</script>