From 8771da2ccf6f7c3fd2a8c89a1a0e230c6386db7f Mon Sep 17 00:00:00 2001
From: 石广澎 <shiguangpeng@163.com>
Date: 星期一, 17 十一月 2025 15:40:48 +0800
Subject: [PATCH] feat(api): 新增多个API接口并优化配置

---
 pages/pay/login.vue |   42 ++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 42 insertions(+), 0 deletions(-)

diff --git a/pages/pay/login.vue b/pages/pay/login.vue
new file mode 100644
index 0000000..b2c943d
--- /dev/null
+++ b/pages/pay/login.vue
@@ -0,0 +1,42 @@
+<template>
+	<view>
+
+	</view>
+</template>
+
+<script>
+	import {
+		config,
+		ACCESSTOKEN
+	} from '@/common/config.js';
+	export default {
+		data() {
+			return {
+				platform: this.$utils.getPlat()
+			};
+		},
+		onLoad(opt) {
+			uni.clearStorage()
+			const redirect_uri = encodeURIComponent(`${config.webURL}/pages/pay/scanpay?cid=${opt.cid}`)
+			if (this.platform == 2) {
+				window.location.href =
+					`https://open.weixin.qq.com/connect/oauth2/authorize?appid=${config.wx_appid}&redirect_uri=${redirect_uri}&response_type=code&scope=snsapi_userinfo&state=STATE#wechat_redirect`
+			} else if (this.platform == 5) {
+				window.location.href =
+					`https://openauth.alipay.com/oauth2/publicAppAuthorize.htm?app_id=${config.ali_appid}&scope=auth_base&redirect_uri=${redirect_uri}&state=STATE`
+			} else if (this.platform == 15) {
+				window.location.href =
+					`https://qr.95516.com/qrcGtwWeb-web/api/userAuth?version=1.0.0&redirectUrl=${redirect_uri}`
+			} else {
+				uni.reLaunch({
+					url: `/pages/pay/scanpay?cid=${opt.cid}`
+				})
+			}
+
+		}
+	}
+</script>
+
+<style lang="scss">
+
+</style>
\ No newline at end of file

--
Gitblit v1.9.1