From d50bb56965dc110d448cc5107d69cd443944d11b Mon Sep 17 00:00:00 2001
From: zhongrj <646384940@qq.com>
Date: Sun, 28 Apr 2024 15:10:45 +0800
Subject: [PATCH] 开放sso测试
---
src/config/website.js | 12 ++++++------
src/page/login/index.vue | 10 +++++-----
vue.config.js | 4 ++--
src/api/user.js | 8 ++++----
4 files changed, 17 insertions(+), 17 deletions(-)
diff --git a/src/api/user.js b/src/api/user.js
index 0b31017..1969867 100644
--- a/src/api/user.js
+++ b/src/api/user.js
@@ -2,7 +2,7 @@
import website from "@/config/website";
export const loginByUsername = (tenantId, deptId, roleId, username, password, type, key, code) => request({
- url: '/api/blade-auth/oauth/token',
+ url: '/api/oauth/token',
method: 'post',
headers: {
'Tenant-Id': tenantId,
@@ -24,7 +24,7 @@
});
export const loginBySocial = (tenantId, source, code, state) => request({
- url: '/api/blade-auth/oauth/token',
+ url: '/api/oauth/token',
method: 'post',
headers: {
'Tenant-Id': tenantId
@@ -40,7 +40,7 @@
})
export const loginBySso = (state, code) => request({
- url: '/api/blade-auth/oauth/token',
+ url: '/api/oauth/token',
method: 'post',
headers: {
'Tenant-Id': state
@@ -55,7 +55,7 @@
})
export const refreshToken = (refresh_token, tenantId, deptId, roleId) => request({
- url: '/api/blade-auth/oauth/token',
+ url: '/api/oauth/token',
method: 'post',
headers: {
'Tenant-Id': tenantId,
diff --git a/src/config/website.js b/src/config/website.js
index 52c2033..9233279 100644
--- a/src/config/website.js
+++ b/src/config/website.js
@@ -2,12 +2,12 @@
* 全局配置文件
*/
export default {
- title: "jczz",
+ title: "sword",
logo: "J",
- key: "jczz", //配置主键,目前用于存储
+ key: "sword", //配置主键,目前用于存储
indexTitle: "基层智治综合协同平台",
- clientId: "jczz", // 客户端id
- clientSecret: "jczz_secret_FaXfddsafRsfjlsdf2A12412", // 客户端密钥
+ clientId: "sword", // 客户端id
+ clientSecret: "sword_secret", // 客户端密钥
tenantMode: true, // 是否开启租户模式
tenantId: "000000", // 管理组租户编号
captchaMode: true, // 是否开启验证码模式
@@ -49,10 +49,10 @@
// reportUrl: 'http://localhost:9528/ureport',
// 单点登录系统认证(blade-auth服务的地)
ssoUrl:
- "http://localhost:8100/oauth/authorize?client_id=saber&response_type=code&redirect_uri=",
+ "http://localhost:8100/oauth/authorize?client_id=sword&response_type=code&redirect_uri=",
// 单点登录回调地址(Saber服务的地址)
redirectUri: "http://localhost:1888",
- // redirectUri:'http://192.168.0.102:9528',
+ // redirectUri:'http://192.168.1.50:8100',
// minio 基础路径
minioUrl: "https://srgdjczzxtpt.com:2080/gminio/jczz/",
};
diff --git a/src/page/login/index.vue b/src/page/login/index.vue
index 9b235e1..2dc2bd4 100644
--- a/src/page/login/index.vue
+++ b/src/page/login/index.vue
@@ -20,12 +20,12 @@
</h4>
<userLogin v-if="activeName === 'user'"></userLogin>
<!-- <codeLogin v-else-if="activeName==='code'"></codeLogin> -->
- <!-- <thirdLogin v-else-if="activeName==='third'"></thirdLogin> -->
+ <thirdLogin v-else-if="activeName==='third'"></thirdLogin>
<div class="login-menu">
- <!-- <a href="#" @click.stop="activeName='user'">{{ $t('login.userLogin') }}</a> -->
- <!--<a href="#" @click.stop="activeName='code'">{{ $t('login.phoneLogin') }}</a>-->
- <!-- <a href="#" @click.stop="activeName='third'">{{ $t('login.thirdLogin') }}</a> -->
- <!-- <a :href="website.ssoUrl + website.redirectUri">{{ $t('login.ssoLogin') }}</a> -->
+ <a href="#" @click.stop="activeName='user'">{{ $t('login.userLogin') }}</a>
+ <a href="#" @click.stop="activeName='code'">{{ $t('login.phoneLogin') }}</a>
+ <a href="#" @click.stop="activeName='third'">{{ $t('login.thirdLogin') }}</a>
+ <a :href="website.ssoUrl + website.redirectUri">{{ $t('login.ssoLogin') }}</a>
</div>
</div>
diff --git a/vue.config.js b/vue.config.js
index c139fe5..ba231d1 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -38,8 +38,8 @@
proxy: {
"/api": {
//本地服务接口地址
- // target:"http://192.168.1.50:9528",
- target: "https://srgdjczzxtpt.com:2080/api",
+ target:"http://192.168.1.50:8110/",
+ // target: "https://srgdjczzxtpt.com:2080/api",
// target: "https://kt39592615.goho.co",
// target: "http://z4042833u6.wicp.vip",
// target: "http://localhost:9528",
--
Gitblit v1.9.3