Skip to content

Commit 94e572c

Browse files
committed
重构文档结构
1 parent a27ed0c commit 94e572c

File tree

120 files changed

+286
-49
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

120 files changed

+286
-49
lines changed

.gitee/ISSUE_TEMPLATE.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
请在以下地址复制 issue 模板进行提交:
2-
https://sa-token.dev33.cn/doc/index.html#/fun/issue-template
2+
https://sa-token.dev33.cn/doc.html#/fun/issue-template

.github/ISSUE_TEMPLATE.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
请在以下地址复制 issue 模板进行提交:
2-
https://sa-token.dev33.cn/doc/index.html#/fun/issue-template
2+
https://sa-token.dev33.cn/doc.html#/fun/issue-template

README.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<p align="center">
2-
<img alt="logo" src="https://sa-token.dev33.cn/doc/logo.png" width="150" height="150">
2+
<img alt="logo" src="https://sa-token.dev33.cn/logo.png" width="150" height="150">
33
</p>
44
<h1 align="center" style="margin: 30px 0 30px; font-weight: bold;">Sa-Token v1.31.0</h1>
55
<h4 align="center">一个轻量级 Java 权限认证框架,让鉴权变得简单、优雅!</h4>
@@ -115,13 +115,13 @@ Sa-Token-SSO 由简入难划分为三种模式,解决不同架构下的 SSO
115115

116116
| 系统架构 | 采用模式 | 简介 | 文档链接 |
117117
| :-------- | :-------- | :-------- | :-------- |
118-
| 前端同域 + 后端同 Redis | 模式一 | 共享Cookie同步会话 | [文档](http://sa-token.dev33.cn/doc/index.html#/sso/sso-type1)[示例](https://gitee.com/dromara/sa-token/blob/master/sa-token-demo/sa-token-demo-sso1-client) |
119-
| 前端不同域 + 后端同 Redis | 模式二 | URL重定向传播会话 | [文档](http://sa-token.dev33.cn/doc/index.html#/sso/sso-type2)[示例](https://gitee.com/dromara/sa-token/blob/master/sa-token-demo/sa-token-demo-sso2-client) |
120-
| 前端不同域 + 后端 不同Redis | 模式三 | Http请求获取会话 | [文档](http://sa-token.dev33.cn/doc/index.html#/sso/sso-type3)[示例](https://gitee.com/dromara/sa-token/blob/master/sa-token-demo/sa-token-demo-sso3-client) |
118+
| 前端同域 + 后端同 Redis | 模式一 | 共享Cookie同步会话 | [文档](http://sa-token.dev33.cn/doc.html#/sso/sso-type1)[示例](https://gitee.com/dromara/sa-token/blob/master/sa-token-demo/sa-token-demo-sso1-client) |
119+
| 前端不同域 + 后端同 Redis | 模式二 | URL重定向传播会话 | [文档](http://sa-token.dev33.cn/doc.html#/sso/sso-type2)[示例](https://gitee.com/dromara/sa-token/blob/master/sa-token-demo/sa-token-demo-sso2-client) |
120+
| 前端不同域 + 后端 不同Redis | 模式三 | Http请求获取会话 | [文档](http://sa-token.dev33.cn/doc.html#/sso/sso-type3)[示例](https://gitee.com/dromara/sa-token/blob/master/sa-token-demo/sa-token-demo-sso3-client) |
121121

122122

123123
1. 前端同域:就是指多个系统可以部署在同一个主域名之下,比如:`c1.domain.com``c2.domain.com``c3.domain.com`
124-
2. 后端同Redis:就是指多个系统可以连接同一个Redis。PS:这里并不需要把所有项目的数据都放在同一个Redis中,Sa-Token提供了 **`[权限缓存与业务缓存分离]`** 的解决方案,详情戳:[Alone独立Redis插件](http://sa-token.dev33.cn/doc/index.html#/plugin/alone-redis)
124+
2. 后端同Redis:就是指多个系统可以连接同一个Redis。PS:这里并不需要把所有项目的数据都放在同一个Redis中,Sa-Token提供了 **`[权限缓存与业务缓存分离]`** 的解决方案,详情戳:[Alone独立Redis插件](http://sa-token.dev33.cn/doc.html#/plugin/alone-redis)
125125
3. 如果既无法做到前端同域,也无法做到后端同Redis,那么只能走模式三,Http请求获取会话(Sa-Token对SSO提供了完整的封装,你只需要按照示例从文档上复制几段代码便可以轻松集成)
126126

127127
## Sa-Token-OAuth2 授权认证
@@ -134,7 +134,7 @@ Sa-OAuth2 模块分为四种授权模式,解决不同场景下的授权需求
134134
| 密码式(Password) | Client直接拿着用户的账号密码换取授权 Token |
135135
| 客户端凭证(Client Credentials)| Server 端针对 Client 级别的 Token,代表应用自身的资源授权 |
136136

137-
详细参考文档:[http://sa-token.dev33.cn/doc/index.html#/oauth2/readme](http://sa-token.dev33.cn/doc/index.html#/oauth2/readme)
137+
详细参考文档:[http://sa-token.dev33.cn/doc.html#/oauth2/readme](http://sa-token.dev33.cn/doc.html#/oauth2/readme)
138138

139139

140140
## 使用 Sa-Token 的开源项目

sa-token-doc/doc/README.md sa-token-doc/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<p align="center">
2-
<img alt="logo" src="https://sa-token.dev33.cn/doc/logo.png" width="150" height="150">
2+
<img alt="logo" src="https://sa-token.dev33.cn/logo.png" width="150" height="150">
33
</p>
44
<h1 align="center" style="margin: 30px 0 30px; font-weight: bold;">Sa-Token v1.31.0</h1>
55
<h5 align="center">一个轻量级 Java 权限认证框架,让鉴权变得简单、优雅!</h5>

sa-token-doc/doc/_sidebar.md sa-token-doc/_sidebar.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<!-- 这是目录树文件 -->
22

33
- **开始**
4-
- [介绍](/)
4+
- [框架介绍](/)
55
- [在 SpringBoot 环境集成](/start/example)
66
- [在 WebFlux 环境集成](/start/webflux-example)
77
- [其它环境集成示例](/start/download)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

sa-token-doc/doc.html

+220
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,220 @@
1+
<!DOCTYPE html>
2+
<html lang="zh">
3+
<head>
4+
<meta charset="UTF-8">
5+
<title>Sa-Token</title>
6+
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
7+
<meta name="description" content="Sa-Token是一个java权限认证框架,功能全面,上手简单,登录认证、权限认证、Session会话、踢人下线、账号封禁、集成Redis、前后台分离、分布式会话、微服务网关鉴权、单点登录、OAuth2.0、临时Token验证、记住我模式、模拟他人账号、临时身份切换、多账号体系、注解式鉴权、路由拦截式鉴权、花式token、自动续签、同端互斥登录、会话治理、密码加密、jwt集成、Spring集成、WebFlux集成...,有了sa-token,你所有的权限认证问题,都不再是问题">
8+
<meta name="keywords" content="sa-token,sa-token框架,sa-token文档,java权限认证">
9+
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
10+
<link rel="shortcut icon" type="image/x-icon" href="logo.png">
11+
<link rel="stylesheet" href="./static/doc.css">
12+
<link rel="stylesheet" href="./static/vue.css">
13+
<script type="text/javascript" src="https://cdn.wwads.cn/js/makemoney.js" async></script>
14+
</head>
15+
<body>
16+
<div class="doc-header">
17+
<div class="nav-left">
18+
<a href="doc.html">
19+
<div class="logo-box">
20+
<img src="logo.png" title="logo" />
21+
<h1 class="logo-text">Sa-Token</h1>
22+
<sub>v1.31.0</sub>
23+
</div>
24+
</a>
25+
</div>
26+
<nav class="nav-right">
27+
<div class="sear-box p-none" tabindex="-1" >
28+
<!-- 加载中…… -->
29+
</div>
30+
<select class="p-none" onchange="location.href=this.value">
31+
<option value="doc.html">最新版</option>
32+
<option value="v/v1.30.0/doc/index.html">v1.30.0</option>
33+
<option value="v/v1.29.0/doc/index.html">v1.29.0</option>
34+
<option value="v/v1.28.0/doc/index.html">v1.28.0</option>
35+
<option value="v/v1.27.0/doc/index.html">v1.27.0</option>
36+
<option value="v/v1.26.0/doc/index.html">v1.26.0</option>
37+
<option value="v/v1.25.0/doc/index.html">v1.25.0</option>
38+
<option value="v/v1.24.0/doc/index.html">v1.24.0</option>
39+
<option value="v/v1.23.0/doc/index.html">v1.23.0</option>
40+
<option value="v/v1.22.0/doc/index.html">v1.22.0</option>
41+
<option value="v/v1.21.0/doc/index.html">v1.21.0</option>
42+
<option value="v/v1.20.0/doc/index.html">v1.20.0</option>
43+
<option value="v/v1.19.0/doc/index.html">v1.19.0</option>
44+
<option value="v/v1.18.0/doc/index.html">v1.18.0</option>
45+
<option value="v/v1.17.0/doc/index.html">v1.17.0</option>
46+
<option value="v/v1.16.0/doc/index.html">v1.16.0</option>
47+
<option value="v/v1.15.0/doc/index.html">v1.15.0</option>
48+
<option value="v/v1.14.0/doc/index.html">v1.14.0</option>
49+
<option value="v/v1.13.0/doc/index.html">v1.13.0</option>
50+
<option value="v/v1.12.1/doc/index.html">v1.12.1</option>
51+
<option value="v/v1.12.0/doc/index.html">v1.12.0</option>
52+
<option value="v/v1.11.0/doc/index.html">v1.11.0</option>
53+
<option value="v/v1.10.0/doc/index.html">v1.10.0</option>
54+
<option value="v/v1.9.0/doc/index.html">v1.9.0</option>
55+
<option value="v/v1.8.0/doc/index.html">v1.8.0</option>
56+
<option value="v/v1.7.0/doc/index.html">v1.7.0</option>
57+
<option value="v/v1.6.0/doc/index.html">v1.6.0</option>
58+
<option value="v/v1.5.1/doc/index.html">v1.5.1</option>
59+
<option value="v/v1.4.0/doc/index.html">v1.4.0</option>
60+
<option value="v/v1.3.0/doc/index.html">v1.3.0</option>
61+
<option value="v/v1.2.0/doc/index.html">v1.2.0</option>
62+
<option value="v/v1.1.0/doc/index.html">v1.1.0</option>
63+
<option value="v/v1.0.0/doc/index.html">v1.0.0</option>
64+
</select>
65+
<a class="wzi" href="index.html">首页</a>
66+
<a class="wzi" href="doc.html">文档</a>
67+
<a class="p-none wzi" href="#/more/link">案例</a>
68+
<a class="p-none wzi" href="#/more/blog">博客</a>
69+
<a class="p-none wzi" href="#/more/sa-token-donate">赞助</a>
70+
<a class="p-none wzi" href="#/sso/sso-pro">🔥 SSO商业版</a>
71+
<div class="zk-box">
72+
<a class="wzi" href="javascript:;">
73+
<span>相关资源 </span>
74+
<span class="zk-icon"></span>
75+
</a>
76+
<div class="zk-context">
77+
<div>
78+
<!-- <a href="#/more/sa-token-donate">❤️ &nbsp;赞助</a> -->
79+
<a href="#/more/update-log">更新日志</a>
80+
<a href="#/more/common-questions">常见报错</a>
81+
<a href="#/more/tj-gzh">推荐公众号</a>
82+
<div class="zk-fengexian"></div>
83+
<!-- <a href="http://sa-app.dev33.cn/wall.html?name=sa-token" target="_blank">需求墙</a> -->
84+
<a href="#/fun/sa-token-test">在线考试</a>
85+
<a href="#/fun/issue-template">在线提问</a>
86+
<a href="https://wj.qq.com/s2/10852322/0d8b/" target="_blank">需求提交</a>
87+
<a href="https://wj.qq.com/s2/8475114/2f6a/" target="_blank">问卷调查</a>
88+
</div>
89+
</div>
90+
</div>
91+
</nav>
92+
</div>
93+
<!-- <a href="/">
94+
<div class="logo-box">
95+
<img src="logo.png" title="logo" />
96+
<h1 class="logo-text">Sa-Token</h1>
97+
</div>
98+
</a> -->
99+
100+
<div class="main-box">
101+
<div id="app">加载中...</div>
102+
</div>
103+
<div style="position: fixed; right: 0; bottom: 0; z-index: 10000; border: 0px #aaa solid;">
104+
<div class="wwads-cn wwads-vertical" data-id="88" style="max-width:150px"></div>
105+
</div>
106+
107+
<!-- UI逐渐显现 -->
108+
<style type="text/css">
109+
body{opacity: 0.01; transition: opacity 0.5s; background-color: #FFF;}
110+
</style>
111+
<script type="text/javascript">
112+
setTimeout(function() {
113+
document.body.style.opacity = 1;
114+
}, 1);
115+
</script>
116+
117+
<!-- -->
118+
<script src="./static/docsify-plugin.js"></script>
119+
<script>
120+
var saTokenTopVersion = '1.31.0'; // Sa-Token最新版本
121+
var name = '<img style="width: 60px; height: 60px; vertical-align: middle;" src="logo.png" alt="logo" /> ';
122+
name += '<b style="font-size: 28px; vertical-align: middle;">Sa-Token</b> <sub>v' + saTokenTopVersion + '</sub>';
123+
window.$docsify = {
124+
// name: name, // 名字
125+
repo: 'https://github.com/dromara/sa-token', // github地址
126+
// themeColor: '#06A3D7', // 主题颜色
127+
basePath: location.pathname.substr(0, location.pathname.lastIndexOf('/') + 1), // 自动计算项目名字
128+
// basePath: '/sa-token-doc/', // 设置文件加载的父路径, 这在一些带项目名部署的文件中非常有效
129+
auto2top: true, // 是否在切换页面后回到顶部
130+
// coverpage: true, // 开启封面
131+
subMaxLevel: 4, // 标题解析层级, 写几就在目录树中解析到几级标题 ,一般写2吧也就
132+
loadSidebar: true, // 加载自定义侧边栏 , 目录定制在: _sidebar.md 文件 (需要创建 .nojekyll 的空文件,阻止 GitHub Pages 忽略命名是下划线开头的文件)
133+
copyCode: { // 复制插件
134+
buttonText: '复制到剪贴板',
135+
errorText: '错误',
136+
successText: '复制成功'
137+
},
138+
topMargin: 90, // 锚点距离顶部的距离
139+
// sidebarDisplayLevel : 1 , // 设置侧边栏显示级别
140+
// search: 'auto', // 搜索功能
141+
alias: {
142+
// '/sso/_sidebar.md': '/sso/_sidebar.md',
143+
'/.*/_sidebar.md': '/_sidebar.md'
144+
},
145+
// tab选项卡
146+
tabs: {
147+
persist : true, // 是否在刷新页面时重置选项卡
148+
sync : true, // 页面上的多个tab是否同步切换
149+
theme : 'classic', // 主题:'classic', 'material', false
150+
tabComments: true, // 用注释来标注选项卡标题,例如:<!-- tab:SpringBoot -->
151+
tabHeadings: true // 用标题+粗体来定制选项卡
152+
},
153+
// 自定义插件
154+
plugins: [myDocsifyPlugin],
155+
}
156+
</script>
157+
<script src="static/docsify.min.js"></script>
158+
<script src="static/docsify-copy-code.min.js"></script>
159+
<script src="static/prism-java.min.js"></script>
160+
<!-- 搜索框 -->
161+
<script src="static/search.min.js"></script>
162+
<!-- 多 tab 切换 -->
163+
<script src="static/docsify-tabs.min.js"></script>
164+
<!-- img点击放大 -->
165+
<script src="static/zoom-image.min.js"></script>
166+
167+
<!-- sidebar折叠 -->
168+
<!-- <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/docsify-sidebar-collapse/dist/sidebar.min.css" />
169+
<script src="//cdn.jsdelivr.net/npm/docsify-sidebar-collapse/dist/docsify-sidebar-collapse.min.js"></script> -->
170+
171+
<!-- jqeury -->
172+
<script src="static/jquery.min.js"></script>
173+
<script src="static/layer-v3.1.1/layer.js"></script>
174+
175+
<script>
176+
if(window.jQuery === undefined || window.Docsify === undefined) {
177+
var str = 'CDN 加载失败,请打开备用地址:<a href="index-backup.html' + location.hash + '" target="_blank">index-backup.html</a>';
178+
document.querySelector('#app').innerHTML = str;
179+
}
180+
</script>
181+
182+
<!-- 搜索引擎自动提交 -->
183+
<script>
184+
(function() {
185+
var bp = document.createElement('script');
186+
var curProtocol = window.location.protocol.split(':')[0];
187+
if (curProtocol === 'https') {
188+
bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';
189+
} else {
190+
bp.src = 'http://push.zhanzhang.baidu.com/push.js';
191+
}
192+
var s = document.getElementsByTagName("script")[0];
193+
s.parentNode.insertBefore(bp, s);
194+
})();
195+
</script>
196+
197+
<!-- 友盟 -->
198+
<div style="height: 0px; overflow: hidden;">
199+
<script type="text/javascript" src="https://s4.cnzz.com/z_stat.php?id=1279646043&web_id=1279646043"></script>
200+
</div>
201+
<!-- 百度统计 -->
202+
<script>
203+
var _hmt = _hmt || [];
204+
(function() {
205+
var hm = document.createElement("script");
206+
hm.src = "https://hm.baidu.com/hm.js?77d7418dd845f98ba1cfee8596eeee3f";
207+
var s = document.getElementsByTagName("script")[0];
208+
s.parentNode.insertBefore(hm, s);
209+
})();
210+
</script>
211+
212+
<script type="text/javascript">
213+
// 预览版提示
214+
if(location.host === 'rc.sa-token.dev33.cn') {
215+
const newTips = '<b>当前文档为RC预览版文档,仅做学习测试使用,正式项目请使用正式版:<a href="https://sa-token.dev33.cn/" target="_blank">https://sa-token.dev33.cn/</a></b>';
216+
layer.alert(newTips);
217+
}
218+
</script>
219+
</body>
220+
</html>

sa-token-doc/doc/logo-150.png

-2.87 KB
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

sa-token-doc/doc/fun/issue-template.md sa-token-doc/fun/issue-template.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44

55
> 请在新建 issue 时,尽量复制模板格式进行提交
66
>
7-
> 1. 提交之前率先参考 [Sa-Token 常见问题解答](https://sa-token.dev33.cn/doc/index.html#/more/common-questions) 以及善用 Gitee issues 搜索功能,查阅问题是否已有答案,已存在的 issue 就不要再重复提交了。
7+
> 1. 提交之前率先参考 <a href="#/more/common-questions" target="_blank">Sa-Token 常见问题解答</a> 以及善用 Gitee issues 搜索功能,查阅问题是否已有答案,已存在的 issue 就不要再重复提交了。
88
> 2. 问题已得到处理的 issue 请大家及时手动关闭,如果超过24小时没有追问,我们将默认提交者已找到解决方案,关闭issue。
99
> 3. 有时候 issue 提交之后,没有得到及时回复,大家可以加入QQ群@管理员寻求帮助。
10-
> 4. 请大家新建 issue 时删除不必要的模板信息、精简语句、**做好代码排版**,对于不方便描述的业务场景,可参阅 [Sa-Token 名词解释](https://sa-token.dev33.cn/doc/index.html#/more/noun-intro) 方便组织语句,这样有助于减低大家的沟通成本。
10+
> 4. 请大家新建 issue 时删除不必要的模板信息、精简语句、**做好代码排版**,对于不方便描述的业务场景,可参阅 <a href="#/more/noun-intro" target="_blank">Sa-Token 名词解释</a> 方便组织语句,这样有助于减低大家的沟通成本。
1111
> 5. **代码截图要带上行号!报错信息要把异常堆栈截全!页面截图要把地址栏带上!Ajax请求要把请求地址、请求头、请求参数都截全!**
1212
1313

File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)