Compare commits

...

50 Commits
dev ... preview

Author SHA1 Message Date
opensnail
bb2c79afa5 Merge branch 'master' into preview 2025-03-31 23:10:31 +08:00
xlsea
441227d88e feat: 整合giee一键登录 2025-03-14 10:30:34 +08:00
xlsea
770afc88c5 Merge branch 'refs/heads/1.4.0-beta2' into preview 2025-03-12 16:58:24 +08:00
xlsea
2fbee6e2a5 merge(preview): 合并 1.4.0-beta1 2025-03-03 13:41:10 +08:00
xlsea
85dd3efdf6 Merge branch 'master' into preview 2025-01-24 09:44:49 +08:00
xlsea
e0886599ba Merge branch '1.3.0-beta1' into preview 2025-01-04 17:14:24 +08:00
xlsea
58900a3dd3 fix(1.3.0-beta1): 修复双层水印问题 2025-01-04 17:12:17 +08:00
xlsea
e7b46301fe Merge branch '1.3.0-beta1' into preview 2025-01-04 16:22:28 +08:00
xlsea
32c324df5f Merge branch 'master' into preview 2024-11-18 09:30:13 +08:00
xlsea
d4b115af8f feat: 登录新增验证码校验 2024-10-25 11:44:11 +08:00
xlsea
1e2974a7d8 Merge branch '1.2.0-beta2' into preview 2024-10-25 10:30:27 +08:00
xlsea
75599c41df Merge branch '1.2.0-beta2' into preview 2024-09-23 14:07:29 +08:00
xlsea
664797ca46 feat: 新增广告 2024-09-22 18:56:28 +08:00
xlsea
b4d0b576f3 Merge branch '1.2.0-beta2' into preview
# Conflicts:
#	.env
#	src/views/job/task/modules/job-task-operate-drawer.vue
2024-09-21 14:35:49 +08:00
xlsea
5b9eb83e7b Merge branch '1.2.0-beta1' into preview
# Conflicts:
#	src/views/_builtin/login/modules/pwd-login.vue
#	src/views/home/modules/header-banner.vue
2024-09-09 11:29:56 +08:00
xlsea
401babb43a fix(sj_1.2.0-beta1): 优化 Http 执行器 2024-09-09 11:22:38 +08:00
xlsea
513bd914b8 refactor(preview): 移除强制star检测 2024-09-09 11:12:08 +08:00
xlsea
52bf92caa1 chore: 优化 start 提示 2024-08-09 11:59:47 +08:00
xlsea
5b506339e6 fix: 修复gitee授权逻辑 2024-08-08 10:16:49 +08:00
xlsea
9d4de15a89 Merge branch 'refs/heads/1.2.0-beta1' into preview 2024-08-03 21:35:47 +08:00
xlsea
7609658921 feat(preview): 登录新增校验 start 功能 2024-08-03 13:23:30 +08:00
xlsea
1dc974baf1 Merge branch 'refs/heads/1.2.0-beta1' into preview 2024-07-19 10:21:20 +08:00
xlsea
c88acc2ced Merge branch 'refs/heads/1.1.0-beta3' into preview 2024-07-14 22:01:04 +08:00
xlsea
30470d2508 Merge branch 'refs/heads/1.1.0-beta3' into preview 2024-07-13 11:34:07 +08:00
xlsea
eed4d14096 Merge branch 'refs/heads/1.1.0-beta3' into preview 2024-07-11 15:58:09 +08:00
xlsea
1a08735cfb Merge branch 'refs/heads/1.1.0-beta3' into preview 2024-07-11 11:51:29 +08:00
xlsea
495cbd5fb0 merge(sj_preview): 合并 dev_1.1.0-beta3 2024-07-11 09:23:20 +08:00
xlsea
3ec4b5fe6c Merge branch 'refs/heads/1.1.0-beta3' into preview 2024-07-08 17:53:46 +08:00
xlsea
87d20bea22 Merge branch 'refs/heads/dev_map_reduce' into preview 2024-07-08 09:22:49 +08:00
xlsea
02f905ecb5 feat(sj_preview): 体验站新增B站官方账号 2024-07-04 12:06:58 +08:00
xlsea
48cc17b4a5 feat(sj_preview): 体验站新增B站官方账号 2024-07-04 11:59:05 +08:00
xlsea
8c621dbbf0 merge(sj_preview): 合并 dev_map_reduce 2024-07-04 09:14:52 +08:00
xlsea
e6b4f3bd6f Merge branch 'refs/heads/master' into preview 2024-06-24 09:09:45 +08:00
xlsea
de9cba9df3 merge(sj_preview): 合并 1.0.0 2024-06-11 09:11:14 +08:00
xlsea
0c37ec7480 fix(sj_1.0.0_beta4): 修复广告位显示问题 2024-06-07 14:42:54 +08:00
xlsea
4ad85ad942 Merge branch 'refs/heads/dev_1.0.0_beta4' into preview 2024-06-07 14:23:31 +08:00
xlsea
45318141bc merge(preview): 合并 dev_1.0.0_beta4 2024-06-07 11:50:21 +08:00
xlsea
6a2103cb13 Merge branch 'refs/heads/dev_1.0.0_beta4' into preview 2024-06-04 15:47:24 +08:00
xlsea
f06d0c6e56 Merge branch 'refs/heads/dev_1.0.0_beta4' into preview 2024-06-03 19:57:51 +08:00
xlsea
084e6617cb Merge branch 'refs/heads/dev_1.0.0_beta4' into preview 2024-06-03 09:49:20 +08:00
xlsea
af6dc365b8 merge(sj_preview): 合并 sj_1.0.0_beta3 2024-06-03 09:23:15 +08:00
xlsea
f246cd1efa merge(preview): 合并 sj_1.0.0_beta3 2024-05-31 11:19:36 +08:00
xlsea
56754b1ac2 config: 修改打包配置 2024-05-25 11:00:02 +08:00
xlsea
902b559f32 style: 修复折叠按钮样式 2024-05-25 10:41:05 +08:00
xlsea
d551686723 feat: 合并开发分支 2024-05-24 14:35:20 +08:00
xlsea
ff4adf34cd style: 优化广告位 2024-05-23 15:21:27 +08:00
xlsea
c798d92197 Merge branch 'refs/heads/dev_1.0.0_beta2' into preview 2024-05-23 09:47:11 +08:00
xlsea
95f817692b style: 优化样式 2024-05-16 09:24:16 +08:00
xlsea
f1a6a27487 style: 优化样式 2024-05-15 23:38:36 +08:00
xlsea
9adb1c37f9 feat: 新增体验站 2024-05-15 23:05:42 +08:00
16 changed files with 473 additions and 23 deletions

12
.env
View File

@ -30,7 +30,7 @@ VITE_MENU_ICON=mdi:menu
VITE_HTTP_PROXY=Y
# vue-router mode: hash | history | memory
VITE_ROUTER_HISTORY_MODE=hash
VITE_ROUTER_HISTORY_MODE=history
# success code of backend service, when the code is received, the request is successful
VITE_SERVICE_SUCCESS_CODE=1
@ -45,19 +45,17 @@ VITE_SERVICE_MODAL_LOGOUT_CODES=5001
VITE_SERVICE_EXPIRED_TOKEN_CODES=9999,9998,3333
# when the route mode is static, the defined super role
VITE_STATIC_SUPER_ROLE=R_SUPER
VITE_STATIC_SUPER_ROLE=R_ADMIN
# sourcemap
VITE_SOURCE_MAP=N
# Used to differentiate storage across different domains
VITE_STORAGE_PREFIX=
VITE_STORAGE_PREFIX=sj_
# used to control whether the program automatically detects updates
VITE_AUTOMATICALLY_DETECT_UPDATE=Y
VITE_ICONIFY_URL=/iconify
VITE_UPDATE_NOTIFY=Y
VITE_UPDATE_NOTIFY=N
VITE_LOGIN_CODE=N
VITE_LOGIN_CODE=Y

View File

@ -1,6 +1,8 @@
VITE_BASE_URL=/snail-job
VITE_ICONIFY_URL=/snail-job/iconify
VITE_BASE_URL=/
# backend service base url, prod environment
VITE_SERVICE_BASE_URL=/snail-job
VITE_OTHER_SERVICE_BASE_URL= `{
"api": "/api"
}`

View File

@ -1,4 +1,8 @@
VITE_BASE_URL=/
# backend service base url, test environment
VITE_SERVICE_BASE_URL=http://localhost:8080/snail-job
VITE_SERVICE_BASE_URL=https://preview.snailjob.opensnail.com/snail-job
VITE_OTHER_SERVICE_BASE_URL= `{
"api": "http://localhost:3000/api"
}`

BIN
public/ad-ali-1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 186 KiB

BIN
public/ad-ali-2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 244 KiB

BIN
public/ad-tencent-1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 MiB

BIN
public/ad-tencent-2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 903 KiB

BIN
public/code.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

@ -0,0 +1 @@
<svg width="18" height="18" viewBox="0 0 18 18" fill="none" xmlns="http://www.w3.org/2000/svg" class="zhuzhan-icon"><path fill-rule="evenodd" clip-rule="evenodd" d="M3.73252 2.67094C3.33229 2.28484 3.33229 1.64373 3.73252 1.25764C4.11291 0.890684 4.71552 0.890684 5.09591 1.25764L7.21723 3.30403C7.27749 3.36218 7.32869 3.4261 7.37081 3.49407H10.5789C10.6211 3.4261 10.6723 3.36218 10.7325 3.30403L12.8538 1.25764C13.2342 0.890684 13.8368 0.890684 14.2172 1.25764C14.6175 1.64373 14.6175 2.28484 14.2172 2.67094L13.364 3.49407H14C16.2091 3.49407 18 5.28493 18 7.49407V12.9996C18 15.2087 16.2091 16.9996 14 16.9996H4C1.79086 16.9996 0 15.2087 0 12.9996V7.49406C0 5.28492 1.79086 3.49407 4 3.49407H4.58579L3.73252 2.67094ZM4 5.42343C2.89543 5.42343 2 6.31886 2 7.42343V13.0702C2 14.1748 2.89543 15.0702 4 15.0702H14C15.1046 15.0702 16 14.1748 16 13.0702V7.42343C16 6.31886 15.1046 5.42343 14 5.42343H4ZM5 9.31747C5 8.76519 5.44772 8.31747 6 8.31747C6.55228 8.31747 7 8.76519 7 9.31747V10.2115C7 10.7638 6.55228 11.2115 6 11.2115C5.44772 11.2115 5 10.7638 5 10.2115V9.31747ZM12 8.31747C11.4477 8.31747 11 8.76519 11 9.31747V10.2115C11 10.7638 11.4477 11.2115 12 11.2115C12.5523 11.2115 13 10.7638 13 10.2115V9.31747C13 8.76519 12.5523 8.31747 12 8.31747Z" fill="currentColor"></path></svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@ -0,0 +1,200 @@
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="2500.000000pt" height="2500.000000pt" viewBox="0 0 2500.000000 2500.000000"
preserveAspectRatio="xMidYMid meet">
<g transform="translate(0.000000,2500.000000) scale(0.100000,-0.100000)"
fill="#e83f37" stroke="none">
<path d="M12120 22851 c0 -5 -37 -11 -82 -14 -263 -12 -839 -64 -1003 -89 -38
-5 -122 -16 -185 -23 -63 -7 -146 -18 -185 -25 -172 -28 -367 -63 -447 -81
-48 -10 -96 -19 -107 -19 -11 0 -60 -9 -108 -20 -48 -12 -131 -30 -183 -41
-52 -12 -126 -30 -165 -40 -38 -11 -80 -19 -93 -19 -13 0 -35 -6 -50 -14 -15
-7 -45 -16 -67 -20 -38 -7 -87 -20 -245 -67 -36 -11 -74 -19 -85 -19 -11 0
-29 -6 -40 -14 -11 -7 -36 -17 -55 -20 -19 -4 -51 -13 -70 -21 -19 -8 -82 -28
-140 -45 -58 -18 -119 -38 -137 -46 -17 -8 -39 -14 -48 -14 -9 0 -31 -7 -48
-15 -18 -8 -52 -21 -77 -29 -65 -21 -221 -79 -340 -126 -30 -12 -68 -26 -85
-31 -16 -5 -43 -15 -60 -23 -16 -8 -55 -24 -85 -37 -113 -46 -209 -89 -328
-145 -50 -24 -97 -44 -103 -44 -5 0 -27 -9 -47 -20 -20 -11 -152 -76 -292
-145 -140 -70 -268 -134 -285 -144 -16 -10 -61 -35 -100 -56 -216 -118 -605
-349 -690 -409 -16 -11 -37 -25 -46 -31 -70 -41 -156 -98 -221 -145 -42 -30
-140 -100 -218 -155 -201 -142 -231 -165 -470 -354 -121 -96 -328 -270 -400
-335 -31 -28 -69 -62 -85 -75 -149 -121 -627 -598 -823 -821 -75 -85 -155
-175 -178 -200 -79 -85 -337 -404 -429 -528 -11 -15 -54 -72 -95 -127 -41 -55
-91 -125 -112 -155 -20 -30 -68 -100 -107 -155 -38 -55 -93 -138 -122 -185
-29 -47 -78 -123 -108 -170 -31 -47 -59 -92 -63 -102 -4 -9 -31 -54 -61 -100
-30 -45 -71 -114 -91 -153 -21 -38 -49 -90 -63 -115 -61 -109 -118 -218 -209
-400 -160 -323 -220 -454 -295 -645 -13 -33 -27 -65 -31 -71 -5 -6 -17 -35
-27 -65 -10 -30 -26 -67 -35 -84 -9 -16 -16 -38 -16 -48 0 -11 -6 -31 -14 -45
-7 -15 -22 -52 -33 -82 -29 -83 -51 -145 -69 -197 -10 -27 -25 -66 -35 -89
-11 -23 -19 -52 -19 -65 0 -14 -6 -33 -14 -44 -7 -11 -16 -33 -20 -50 -6 -30
-32 -118 -61 -210 -9 -27 -22 -75 -30 -105 -7 -30 -20 -73 -29 -95 -8 -22 -15
-53 -16 -68 0 -15 -7 -43 -15 -63 -8 -19 -19 -63 -25 -97 -6 -34 -17 -80 -25
-102 -7 -22 -16 -63 -20 -92 -3 -29 -12 -71 -20 -94 -8 -23 -15 -53 -15 -66 0
-14 -11 -71 -24 -127 -13 -55 -27 -128 -31 -161 -3 -33 -12 -80 -20 -105 -7
-25 -16 -81 -20 -125 -4 -44 -12 -105 -20 -135 -7 -30 -16 -95 -19 -145 -3
-49 -12 -135 -20 -190 -8 -55 -20 -183 -26 -285 -6 -102 -18 -216 -26 -253 -8
-38 -14 -95 -14 -128 0 -33 -4 -59 -10 -59 -6 0 -10 -130 -10 -370 0 -240 4
-370 10 -370 6 0 10 -25 10 -55 0 -31 7 -88 15 -128 8 -40 19 -155 25 -257 6
-102 18 -230 26 -285 8 -55 17 -140 20 -190 3 -49 12 -115 19 -145 7 -30 17
-93 20 -140 4 -46 13 -100 20 -120 7 -19 16 -65 20 -100 4 -36 15 -99 25 -140
10 -41 22 -97 25 -125 4 -27 15 -84 25 -125 10 -41 28 -120 40 -175 13 -55 31
-129 40 -165 10 -36 21 -83 25 -105 4 -21 13 -51 20 -65 7 -14 16 -45 20 -70
4 -25 12 -54 17 -64 11 -21 54 -167 68 -234 5 -24 16 -53 25 -65 8 -12 15 -33
15 -47 0 -14 7 -38 15 -54 16 -30 54 -132 80 -216 24 -76 52 -152 85 -230 17
-41 38 -95 46 -119 8 -24 18 -49 23 -55 5 -6 12 -22 16 -36 4 -14 13 -38 20
-55 8 -16 28 -64 45 -105 34 -82 41 -98 93 -210 19 -41 49 -106 67 -145 17
-38 36 -77 41 -85 4 -8 30 -58 57 -110 144 -278 175 -338 196 -375 24 -41 34
-58 101 -180 21 -38 41 -72 44 -75 4 -3 20 -27 36 -55 17 -27 34 -57 40 -66 5
-9 18 -30 28 -47 18 -33 214 -334 267 -412 109 -158 239 -338 342 -470 26 -34
49 -66 51 -73 2 -7 7 -9 11 -6 4 4 -9 62 -29 130 -70 242 -88 321 -151 689 -8
47 -14 108 -14 135 0 28 -7 100 -15 160 -20 151 -20 609 0 770 8 66 15 146 15
178 0 32 6 88 14 125 8 37 17 96 21 130 3 35 10 75 15 88 5 13 14 56 19 96 6
40 15 93 22 118 6 25 18 72 26 105 8 33 23 90 34 126 10 36 19 72 19 80 0 22
118 380 135 411 8 14 15 33 15 42 0 15 12 46 51 132 11 23 19 46 19 52 0 6 6
23 14 39 7 15 21 46 31 68 36 85 84 193 107 245 79 177 283 561 393 738 6 10
21 35 33 57 12 22 30 52 40 67 9 14 38 62 65 105 26 43 88 137 138 208 50 72
98 141 107 155 9 14 20 30 25 35 4 6 63 82 129 170 67 88 138 181 157 206 80
103 155 195 165 204 6 6 38 42 71 80 33 39 81 93 106 120 26 28 61 68 80 90
77 92 406 427 609 620 103 98 234 217 366 331 33 28 97 84 145 125 47 41 105
90 130 110 288 237 411 332 674 528 163 121 234 172 305 221 28 19 57 40 63
45 13 12 178 124 205 140 9 6 71 47 137 91 101 68 184 120 283 179 9 6 44 28
77 50 64 42 63 41 150 95 32 19 68 42 80 50 31 20 288 179 330 205 18 11 77
47 130 80 52 33 103 65 113 70 20 12 30 18 185 119 163 105 159 117 -18 57
-49 -17 -115 -39 -145 -47 -30 -9 -71 -22 -90 -29 -19 -7 -51 -18 -70 -24 -19
-7 -53 -17 -75 -22 -21 -6 -44 -14 -50 -18 -5 -5 -26 -12 -45 -16 -19 -4 -41
-11 -50 -16 -8 -4 -49 -17 -90 -29 -41 -12 -88 -28 -103 -36 -16 -8 -39 -14
-51 -14 -12 0 -30 -6 -41 -14 -11 -7 -33 -16 -50 -19 -26 -4 -84 -23 -150 -48
-26 -10 -118 -38 -175 -54 -25 -7 -117 -34 -205 -59 -88 -25 -185 -52 -215
-60 -30 -8 -75 -19 -100 -26 -25 -6 -66 -15 -92 -20 -26 -5 -56 -13 -67 -19
-11 -6 -30 -11 -43 -11 -13 0 -43 -6 -68 -14 -25 -8 -67 -20 -95 -26 -121 -29
-164 -40 -225 -55 -36 -9 -87 -21 -115 -27 -27 -6 -67 -17 -88 -24 -20 -8 -51
-14 -67 -14 -16 0 -47 -6 -67 -14 -21 -8 -59 -17 -85 -21 -26 -3 -50 -10 -53
-16 -4 -5 -16 -9 -28 -9 -13 0 -50 -7 -82 -16 -79 -21 -142 -35 -390 -89 -33
-7 -123 -27 -200 -44 -77 -17 -174 -38 -215 -47 -41 -9 -98 -22 -126 -30 -28
-8 -64 -14 -81 -14 -17 0 -50 -7 -73 -15 -23 -8 -57 -15 -75 -15 -18 0 -52 -7
-75 -15 -23 -8 -56 -15 -73 -15 -17 0 -56 -6 -86 -14 -69 -18 -148 -33 -266
-51 -49 -8 -117 -19 -150 -24 -76 -14 -507 -14 -600 0 -38 5 -117 16 -175 24
-117 15 -210 35 -253 53 -16 7 -32 12 -36 12 -9 0 -80 33 -120 55 -55 31 -140
126 -172 192 -39 84 -50 175 -25 224 9 18 19 50 22 71 4 21 13 43 20 49 8 6
14 20 14 30 0 21 86 138 139 189 162 155 408 351 581 464 41 26 86 56 100 65
14 10 32 20 40 24 8 4 29 16 45 27 17 11 39 24 50 30 11 6 38 21 60 33 173
101 411 219 740 367 39 17 85 38 102 46 18 8 47 21 65 29 18 7 56 23 83 35 48
21 76 33 147 65 76 33 211 88 353 141 22 9 53 22 68 30 16 8 36 14 46 14 9 0
26 7 37 15 10 8 28 15 39 15 11 0 29 6 40 14 11 7 31 16 45 19 28 6 104 32
135 47 11 5 56 21 100 35 44 15 84 31 90 36 5 5 21 9 35 9 14 0 31 5 37 11 6
6 26 14 44 19 41 10 118 37 139 48 8 5 143 50 300 101 157 52 301 99 320 106
19 7 62 20 95 30 33 9 75 23 93 31 18 8 43 14 55 14 12 1 33 7 47 15 14 8 34
14 45 15 11 0 33 7 49 15 15 8 38 15 50 15 11 1 39 9 61 20 22 11 51 20 65 20
14 0 34 7 44 15 11 8 30 15 43 15 12 0 37 6 55 14 67 28 269 89 310 93 24 2
63 0 88 -4 64 -12 63 -33 -4 -130 -31 -43 -61 -86 -68 -96 -39 -57 -65 -89
-132 -162 -165 -182 -193 -215 -228 -275 -77 -131 -59 -259 49 -350 72 -60
196 -86 283 -59 19 5 58 14 85 19 47 8 124 31 170 50 38 16 289 97 570 185 66
20 138 43 160 50 22 7 55 16 72 20 18 4 35 11 38 16 4 5 18 9 32 9 14 0 39 6
56 14 18 7 66 23 107 36 41 12 89 28 107 36 17 8 39 14 50 14 10 1 29 7 43 15
14 8 36 15 50 15 14 0 34 7 44 15 11 8 28 15 38 15 9 0 32 6 50 14 18 7 65 23
103 35 39 13 86 28 105 36 19 7 157 52 305 100 149 48 286 93 305 100 19 7 51
18 70 24 19 7 53 17 75 22 22 6 44 14 49 20 6 5 19 9 29 9 10 0 33 6 50 13 18
8 66 24 107 37 41 12 87 29 102 36 14 8 37 14 50 14 13 0 33 7 44 15 10 8 27
15 37 15 11 0 33 6 50 14 18 8 178 62 357 121 179 59 341 113 360 120 88 31
107 37 140 45 33 8 63 17 140 46 19 7 87 29 150 50 63 20 123 40 132 45 10 5
34 13 55 18 36 9 59 16 143 46 97 35 513 165 680 212 30 9 73 22 95 29 23 8
52 14 65 14 14 1 36 7 50 15 14 8 38 14 53 15 16 0 38 5 50 12 12 6 40 15 62
19 22 4 54 11 70 17 43 15 170 46 295 73 30 6 69 18 87 25 17 8 45 14 63 14
18 0 53 6 79 14 25 8 73 20 106 26 33 7 89 18 125 25 522 103 988 154 1484
162 448 8 917 -29 1376 -108 360 -63 574 -154 738 -316 79 -78 112 -130 148
-234 24 -68 26 -84 22 -204 -4 -126 -14 -179 -55 -290 -32 -85 -107 -233 -154
-303 -27 -41 -49 -77 -49 -82 0 -4 -7 -13 -15 -20 -8 -7 -15 -20 -15 -30 0
-10 -7 -23 -15 -30 -8 -7 -15 -22 -15 -35 0 -40 131 -48 765 -47 452 0 580 3
665 16 58 9 141 16 184 16 44 0 121 6 170 14 50 8 136 20 191 26 111 11 196
23 330 45 148 24 327 56 370 65 22 5 99 20 170 35 130 25 205 42 300 65 28 7
68 16 90 21 55 11 121 28 176 45 26 8 55 14 65 14 11 0 39 6 64 14 124 38 148
45 183 51 20 4 39 11 42 15 3 5 24 11 48 15 23 4 54 14 69 21 15 8 37 14 50
14 13 0 36 7 52 15 15 8 37 15 48 15 11 0 29 5 41 11 11 7 42 18 67 24 81 23
465 156 474 165 9 9 6 20 -24 65 -11 17 -26 44 -35 60 -8 17 -25 48 -38 70
-13 22 -33 57 -45 77 -11 20 -33 56 -49 80 -15 24 -34 55 -43 70 -8 15 -35 59
-60 98 -25 39 -49 79 -55 88 -33 56 -236 356 -272 402 -24 30 -43 59 -43 63 0
7 -63 94 -95 130 -8 9 -32 41 -52 70 -21 28 -72 95 -113 147 -42 52 -104 131
-138 175 -72 93 -136 168 -236 279 -76 84 -83 93 -149 171 -66 79 -458 479
-632 644 -148 140 -512 456 -630 546 -97 74 -264 206 -277 218 -21 20 -305
223 -398 284 -30 20 -73 51 -96 70 -23 18 -44 33 -48 33 -4 0 -19 9 -34 19
-33 24 -245 160 -289 187 -18 10 -85 51 -150 90 -65 39 -138 83 -163 96 -67
38 -173 98 -190 109 -8 5 -28 16 -45 24 -16 9 -52 29 -80 45 -54 31 -518 263
-600 300 -118 52 -162 72 -197 91 -20 10 -43 19 -51 19 -8 0 -20 7 -27 15 -7
8 -19 15 -27 15 -8 0 -38 10 -66 23 -29 13 -77 34 -107 47 -30 12 -73 31 -96
41 -23 11 -46 19 -52 19 -6 0 -26 6 -44 14 -34 15 -145 58 -208 81 -59 21
-182 66 -235 85 -27 9 -84 27 -125 39 -41 13 -86 28 -100 35 -14 8 -50 19 -80
26 -30 7 -64 17 -75 23 -11 6 -42 16 -70 23 -27 7 -63 17 -80 23 -16 6 -61 19
-100 30 -38 10 -101 28 -140 40 -38 11 -88 23 -110 27 -22 4 -51 12 -65 19
-14 7 -47 15 -74 19 -26 3 -69 12 -95 20 -49 16 -153 40 -261 61 -133 26 -187
37 -275 55 -81 17 -258 48 -450 80 -38 7 -119 18 -180 25 -60 7 -146 17 -190
24 -207 28 -764 77 -1007 88 -49 3 -88 9 -88 14 0 5 -160 9 -400 9 -239 0
-400 -4 -400 -9z"/>
<path d="M23403 15138 c-67 -85 -354 -389 -438 -463 -184 -163 -425 -316 -632
-402 -18 -7 -48 -20 -65 -28 -99 -44 -321 -106 -501 -139 -125 -23 -955 -86
-1127 -86 -52 0 -176 -7 -275 -15 -99 -8 -252 -15 -340 -15 -88 0 -277 -7
-420 -15 -143 -8 -438 -15 -655 -15 -217 0 -503 -5 -635 -10 -132 -6 -386 -15
-565 -20 -179 -5 -356 -14 -395 -20 -38 -5 -117 -10 -175 -10 -58 -1 -143 -5
-190 -10 -47 -6 -168 -17 -270 -25 -102 -8 -210 -19 -240 -24 -30 -5 -86 -10
-125 -11 -38 0 -99 -7 -135 -15 -36 -8 -94 -14 -130 -15 -36 0 -101 -6 -145
-15 -74 -13 -117 -19 -315 -45 -41 -6 -113 -17 -160 -24 -47 -8 -130 -22 -185
-31 -142 -23 -469 -84 -600 -111 -38 -8 -104 -22 -145 -30 -41 -8 -93 -20
-115 -25 -22 -6 -63 -14 -91 -19 -28 -4 -61 -13 -72 -19 -11 -6 -35 -11 -52
-11 -17 0 -47 -7 -67 -15 -19 -8 -45 -15 -57 -15 -11 0 -41 -6 -66 -14 -51
-16 -110 -32 -191 -50 -30 -8 -65 -18 -77 -25 -11 -6 -33 -11 -47 -11 -14 0
-36 -5 -48 -12 -12 -6 -38 -15 -57 -19 -19 -4 -48 -12 -65 -18 -16 -6 -64 -20
-105 -32 -60 -17 -351 -113 -640 -210 -19 -6 -47 -18 -62 -25 -14 -8 -35 -14
-45 -14 -11 0 -28 -7 -39 -15 -10 -8 -27 -15 -36 -15 -17 0 -67 -19 -121 -46
-16 -8 -34 -14 -40 -14 -7 -1 -30 -9 -52 -20 -22 -11 -45 -19 -52 -20 -6 0
-24 -6 -40 -14 -39 -19 -88 -40 -153 -65 -30 -12 -64 -26 -75 -31 -11 -5 -69
-30 -130 -55 -60 -26 -119 -50 -130 -55 -11 -5 -42 -18 -70 -30 -27 -12 -65
-28 -82 -36 -30 -14 -49 -21 -135 -59 -158 -67 -622 -294 -898 -439 -58 -30
-127 -66 -155 -80 -27 -14 -77 -41 -110 -60 -33 -20 -73 -42 -90 -51 -16 -8
-39 -21 -50 -28 -11 -7 -76 -45 -145 -85 -114 -67 -232 -137 -270 -162 -8 -5
-35 -21 -60 -36 -123 -74 -356 -229 -629 -419 -74 -52 -289 -213 -410 -308
-64 -50 -145 -113 -181 -141 -36 -28 -67 -53 -70 -56 -3 -3 -34 -30 -70 -60
-36 -30 -83 -71 -105 -91 -22 -21 -63 -57 -91 -81 -167 -142 -307 -274 -524
-495 -135 -136 -258 -264 -274 -283 -16 -19 -50 -57 -75 -85 -25 -27 -68 -77
-96 -110 -27 -32 -66 -77 -86 -100 -34 -38 -183 -232 -204 -266 -5 -9 -40 -60
-76 -115 -87 -131 -172 -272 -205 -339 -8 -16 -18 -37 -23 -45 -9 -17 -76
-158 -97 -205 -32 -75 -73 -187 -85 -238 -5 -21 -13 -45 -18 -55 -20 -39 -65
-240 -98 -442 -25 -151 -25 -550 0 -710 26 -169 68 -338 103 -418 8 -18 14
-40 14 -48 0 -9 6 -28 14 -42 8 -15 24 -52 36 -82 21 -53 52 -119 70 -150 5
-8 25 -44 46 -80 202 -352 561 -731 959 -1015 146 -105 311 -216 335 -228 8
-4 29 -16 45 -27 17 -11 39 -24 50 -30 11 -6 34 -18 50 -28 30 -18 111 -63
215 -119 99 -53 214 -111 265 -133 28 -12 79 -35 115 -52 70 -33 97 -45 175
-78 28 -12 64 -28 82 -36 17 -8 38 -14 46 -14 9 0 18 -4 22 -9 3 -5 20 -13 37
-17 18 -3 39 -10 48 -15 17 -10 88 -36 135 -49 17 -5 89 -29 160 -54 113 -38
249 -82 415 -131 25 -8 75 -23 111 -34 36 -12 75 -21 86 -21 11 0 34 -7 49
-15 16 -8 45 -15 64 -15 19 -1 46 -7 60 -15 14 -8 37 -14 52 -15 15 0 45 -6
65 -14 21 -7 63 -19 93 -25 139 -30 189 -40 245 -51 33 -6 75 -16 93 -22 19
-5 57 -14 85 -18 29 -4 79 -13 112 -20 286 -56 317 -62 650 -114 231 -36 369
-56 463 -66 46 -5 116 -14 155 -19 99 -14 247 -29 474 -45 106 -8 198 -18 204
-21 6 -4 124 -11 262 -16 139 -5 317 -13 397 -18 192 -13 1001 -13 1160 -1 69
6 244 15 390 20 146 5 294 14 330 19 36 5 128 12 205 16 77 3 163 10 190 16
28 5 111 13 185 19 134 9 208 17 430 45 63 8 142 17 175 20 33 3 105 12 160
20 55 8 168 23 250 34 83 12 195 28 250 36 209 33 282 44 350 55 39 7 86 14
105 16 19 3 73 11 120 19 47 8 128 21 180 30 98 16 149 25 305 50 50 8 108 19
130 24 22 6 58 11 80 11 22 0 62 7 89 15 27 8 65 15 83 15 19 0 62 6 96 14 34
8 94 20 132 26 264 44 332 55 410 71 28 6 77 14 110 19 33 5 112 18 175 29 63
11 156 27 205 36 194 33 274 47 360 61 198 33 231 44 287 93 222 198 708 687
849 856 18 22 58 67 89 101 83 90 240 281 342 414 24 30 61 78 83 105 22 28
46 62 54 76 7 14 28 42 47 63 19 20 34 41 34 46 0 5 6 13 13 17 7 4 44 53 82
108 38 55 89 127 112 160 24 33 46 67 50 75 3 8 36 60 73 115 82 123 142 217
197 310 7 11 30 49 51 85 97 162 150 255 220 390 42 80 88 168 104 195 15 28
31 57 34 65 4 8 26 56 50 105 23 50 48 102 53 115 6 14 15 32 21 40 8 13 49
103 70 155 4 11 22 50 39 86 17 37 31 71 31 77 0 6 11 32 25 58 14 26 25 55
25 65 0 10 4 20 9 24 5 3 17 29 27 58 9 28 23 61 30 72 8 11 14 28 14 38 0 11
7 33 15 50 14 32 25 60 71 191 14 38 28 74 33 80 4 6 11 27 15 46 3 19 12 49
20 65 8 17 26 71 41 120 14 50 35 113 45 140 10 28 22 68 26 90 4 22 10 45 14
50 5 6 13 30 19 55 6 25 18 68 26 95 19 65 44 167 57 230 6 28 18 79 28 115
10 36 22 88 28 115 20 101 44 212 59 275 9 36 19 97 23 135 5 39 16 97 24 130
9 32 16 78 16 102 0 23 9 88 19 145 11 57 24 159 30 228 7 69 18 159 26 200 7
41 16 147 20 235 3 88 10 180 15 205 5 25 9 78 10 118 0 41 4 72 10 72 7 0 10
140 10 400 0 260 -3 400 -10 400 -6 0 -10 28 -10 63 -1 34 -5 82 -10 107 -5
25 -12 117 -15 205 -4 88 -13 194 -20 235 -8 41 -19 131 -26 200 -6 69 -19
171 -30 228 -10 57 -19 122 -19 146 0 24 -7 65 -15 92 -8 27 -18 81 -21 119
-3 39 -12 90 -19 115 -8 25 -19 74 -25 110 -6 36 -19 101 -30 145 -26 113 -40
173 -52 230 -5 28 -19 78 -30 112 -10 35 -23 84 -28 110 -13 69 -48 195 -59
214 -5 9 -13 34 -16 55 -4 22 -15 62 -25 89 -11 28 -22 62 -25 78 -3 15 -9 27
-14 27 -5 0 -31 -28 -58 -62z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 14 KiB

View File

@ -46,3 +46,11 @@ export function fetchRefreshToken(refreshToken: string) {
export function fetchCustomBackendError(code: string, msg: string) {
return request({ url: '/auth/error', params: { code, msg } });
}
export function fetchAuthLoginToken(token: string) {
return request<Api.Auth.LoginToken>({
url: '/auth/login/token',
method: 'post',
data: { token }
});
}

View File

@ -4,7 +4,7 @@ import { defineStore } from 'pinia';
import { useLoading } from '@sa/hooks';
import { SetupStoreId } from '@/enum';
import { useRouterPush } from '@/hooks/common/router';
import { fetchGetUserInfo, fetchLogin, fetchVersion } from '@/service/api';
import { fetchAuthLoginToken, fetchGetUserInfo, fetchLogin, fetchVersion } from '@/service/api';
import { localStg } from '@/utils/storage';
import { $t } from '@/locales';
import { roleTypeRecord } from '@/constants/business';
@ -97,6 +97,36 @@ export const useAuthStore = defineStore(SetupStoreId.Auth, () => {
endLoading();
}
/**
* Login
*
* @param authToken token
* @param [redirect=true] Whether to redirect after login. Default is `true`
*/
async function loginByAuthToken(authToken: string, redirect = true) {
startLoading();
const { data: loginToken, error } = await fetchAuthLoginToken(authToken);
if (!error) {
const pass = await loginByToken(loginToken);
if (pass) {
await redirectFromLogin(redirect);
window.$notification?.success({
title: $t('page.login.common.loginSuccess'),
content: $t('page.login.common.welcomeBack', { userName: userInfo.userName }),
duration: 4500
});
}
} else {
resetStore();
}
endLoading();
}
async function loginByToken(loginToken: Api.Auth.LoginToken) {
// 1. stored in the localStorage, the later requests need it in headers
localStg.set('token', loginToken.token);
@ -190,6 +220,7 @@ export const useAuthStore = defineStore(SetupStoreId.Auth, () => {
loginLoading,
resetStore,
login,
loginByAuthToken,
getUserInfo,
initUserInfo,
initAppVersion,

View File

@ -73,5 +73,5 @@ function createProxyPattern(key?: App.Service.OtherBaseURLKey) {
return '/snail-job';
}
return `/proxy-${key}`;
return `/${key}`;
}

View File

@ -1,6 +1,7 @@
<script setup lang="ts">
import { reactive, ref } from 'vue';
import Vcode from 'vue3-puzzle-vcode';
import { onMounted, reactive, ref } from 'vue';
import type { FormInst } from 'naive-ui';
import { useRoute } from 'vue-router';
import { md5 } from '@/utils/common';
import { $t } from '@/locales';
import { useFormRules, useNaiveForm } from '@/hooks/common/form';
@ -10,8 +11,6 @@ defineOptions({
name: 'PwdLogin'
});
const devMode = import.meta.env.DEV;
const authStore = useAuthStore();
const { formRef, validate } = useNaiveForm();
const { defaultRequiredRule } = useFormRules();
@ -22,8 +21,8 @@ interface FormModel {
}
const model: FormModel = reactive({
userName: devMode ? 'admin' : '',
password: devMode ? 'admin' : ''
userName: 'developer',
password: '123456'
});
type RuleKey = Extract<keyof FormModel, 'userName' | 'password'>;
@ -33,6 +32,10 @@ const rules: Record<RuleKey, App.Global.FormRule> = {
password: defaultRequiredRule
};
const codeRules: Record<string, App.Global.FormRule> = {
code: defaultRequiredRule
};
async function handleSubmit() {
const password = md5(model.password);
await authStore.login(model.userName, password);
@ -54,13 +57,34 @@ const onClose = () => {
codeShow.value = false;
};
const onSuccess = () => {
const codeForm = ref({ code: '' });
const codeFormRef = ref<FormInst>();
const onSuccess = async () => {
await codeFormRef.value?.validate();
const { code } = codeForm.value;
const codes: string[] = import.meta.env.VITE_LOGIN_CODES;
if (!codes.includes(String(code))) {
window.$message?.warning('验证码错误');
return;
}
handleSubmit();
};
const codePopoverStytle = {
padding: 0
};
function handleGiteeLogin() {
window.location.href = `${import.meta.env.VITE_GITEE_REDIRECT_URL}&t=${Date.now()}`;
}
onMounted(async () => {
const route = useRoute();
const token = route.query.token;
if (!token) return;
await authStore.loginByAuthToken(String(token));
});
</script>
<template>
@ -79,11 +103,11 @@ const codePopoverStytle = {
<NSpace vertical :size="24">
<NPopover :show="codeShow" row :style="codePopoverStytle">
<template #trigger>
<NButton type="primary" size="large" round block :loading="authStore.loginLoading" @click="validateCode">
<NButton type="primary" size="large" block :loading="authStore.loginLoading" @click="validateCode">
{{ $t('page.login.common.login') }}
</NButton>
</template>
<NCard :title="$t('page.login.common.codeTip')" :header-style="{ padding: '10px 24px' }">
<NCard title="仅需 1 步即可完成" content-class="max-w-300px" :header-style="{ padding: '10px 24px' }">
<template #header-extra>
<NButton text @click="onClose">
<template #icon>
@ -91,9 +115,33 @@ const codePopoverStytle = {
</template>
</NButton>
</template>
<Vcode type="inside" show @success="onSuccess" @close="onClose" />
<NP>扫码下方二维码回复验证码即可获得验证码</NP>
<img src="/code.png" />
<NForm :model="codeFormRef" :rules="codeRules" label-placement="left" require-mark-placement="left">
<NGrid>
<NFormItemGi class="mr-16px" span="18" path="code" label="验证码">
<NInput v-model:value="codeForm.code" placeholder="请输入验证码" />
</NFormItemGi>
<NGridItem span="6">
<NButton type="primary" block @click="onSuccess">确定</NButton>
</NGridItem>
</NGrid>
</NForm>
</NCard>
</NPopover>
<NButton
type="primary"
size="large"
class="h-42px"
block
:loading="authStore.loginLoading"
@click="handleGiteeLogin"
>
<template #icon>
<icon-simple-icons:gitee />
</template>
使用 Gitee 账号 Star 免密登录
</NButton>
</NSpace>
</NForm>
</template>

View File

@ -1,8 +1,10 @@
<script setup lang="ts">
import { ref } from 'vue';
import { fetchCardCount } from '@/service/api';
// import HeaderBanner from './modules/header-banner.vue';
import CardData from './modules/card-data.vue';
import TaskTab from './modules/task-tab.vue';
import AdCarousel from './modules/ad-carousel.vue';
const cardCount = ref<Api.Dashboard.CardCount>();
@ -18,6 +20,7 @@ getCardData();
<template>
<NSpace vertical :size="16" class="home-main">
<AdCarousel />
<CardData v-model="cardCount!" />
<NCard :bordered="false" class="card-wrapper p-t-136px 2xl:p-t-0 lg:p-t-36px md:p-t-90px">
<TaskTab v-model="cardCount!" />

View File

@ -0,0 +1,155 @@
<script setup lang="ts">
import { computed } from 'vue';
import { useAppStore } from '@/store/modules/app';
defineOptions({
name: 'AdCarousel'
});
const appStore = useAppStore();
const gap = computed(() => (appStore.isMobile ? 0 : 16));
const href = (url: string) => {
window.open(url, '_blank');
};
</script>
<template>
<NGrid :x-gap="gap" :y-gap="16" responsive="screen" item-responsive>
<NGi class="flex-center" span="24 l:12">
<NCard title="广告" :bordered="false" class="w-1000px card-wrapper">
<template #header-extra> 开源不易敬请谅解 </template>
<NGrid :x-gap="gap" :y-gap="16" responsive="screen" item-responsive>
<NGi class="flex-center" span="24 s:9">
<NCarousel
autoplay
direction="vertical"
dot-type="line"
dot-placement="left"
class="h-130px w-260px"
:interval="3000"
mousewheel
>
<NCarouselItem>
<NA href="https://curl.qcloud.com/2j1RuHbf" target="_blank" rel="noopener noreferrer">
<img class="carousel-img" src="/ad-tencent-1.png" />
</NA>
</NCarouselItem>
<NCarouselItem>
<NA href="https://curl.qcloud.com/HvUPpDGE" target="_blank" rel="noopener noreferrer">
<img class="carousel-img" src="/ad-tencent-2.png" />
</NA>
</NCarouselItem>
</NCarousel>
</NGi>
<NGi class="flex-center" span="24 s:15">
<NCarousel
autoplay
direction="vertical"
dot-type="line"
dot-placement="left"
class="h-130px w-500px"
:interval="3000"
mousewheel
>
<NCarouselItem>
<NA
href="https://www.aliyun.com/daily-act/ecs/activity_selection?userCode=4rntegyg"
target="_blank"
rel="noopener noreferrer"
>
<img class="carousel-img" src="/ad-ali-1.png" />
</NA>
</NCarouselItem>
<NCarouselItem>
<NA
href="https://www.aliyun.com/daily-act/ecs/ecs_trial_benefits?userCode=4rntegyg"
target="_blank"
rel="noopener noreferrer"
>
<img class="carousel-img" src="/ad-ali-2.png" />
</NA>
</NCarouselItem>
</NCarousel>
</NGi>
</NGrid>
</NCard>
</NGi>
<NGi class="flex-center" span="24 l:12">
<NCard title="赞助商" :bordered="false" class="card-wrapper">
<template #header-extra>
&nbsp;
<NButton text @click="href('https://snailjob.opensnail.com/docs/sponsor.html')">成为赞助商</NButton>
&nbsp;
</template>
<NGrid :x-gap="gap" :y-gap="16" responsive="screen" item-responsive>
<NGi class="h-130px w-250px flex-center" span="24 s:12">
<div class="float-right max-w-250px w-full flex flex-col-reverse">
<div class="order-9999 m-6px max-w-240px text-13px color-gray">
<span>官号</span>
</div>
<NButton quaternary class="h-full" @click="href('https://space.bilibili.com/3493144058399579')">
<NThing class="max-w-full flex-center">
<template #avatar>
<SvgIcon class="text-66px color-#00aeec" local-icon="bilibili" />
</template>
<template #header>
<div class="bilibili-title color-#00aeec font-semibold">Open Snail</div>
<div class="flow-long-title ml-3px font-semibold">bilibili 官方账号</div>
</template>
</NThing>
</NButton>
</div>
</NGi>
<NGi class="h-130px w-250px flex-center" span="24 s:12">
<div class="float-right max-w-250px w-full flex flex-col-reverse">
<div class="order-9999 m-6px max-w-240px text-13px color-gray">
<span>赞助商</span>
</div>
<NButton quaternary class="h-full" @click="href('https://doc.flowlong.com/?from=snail-job')">
<NThing class="max-w-full flex-center">
<template #avatar>
<SvgIcon class="text-66px" local-icon="flowlong" />
</template>
<template #header>
<div class="flow-long-title-color font-semibold">FlowLong</div>
<div class="flow-long-title font-semibold">飞龙工作流引擎</div>
</template>
</NThing>
</NButton>
</div>
</NGi>
</NGrid>
</NCard>
</NGi>
</NGrid>
</template>
<style scoped>
.carousel-img {
height: 130px;
object-fit: cover;
}
.flow-long-title-color {
text-align: left;
line-height: 36px;
font-size: 28px;
background: -webkit-linear-gradient(120deg, #bd34fe 30%, #41d1ff);
background-clip: text;
-webkit-text-fill-color: transparent;
}
.flow-long-title {
text-align: left;
line-height: 22px;
font-size: 20px;
}
.bilibili-title {
text-align: cneter;
line-height: 36px;
font-size: 26px;
}
</style>