浏览代码

Merge remote-tracking branch 'origin/gzb' into wzl

gzb
wangzhonglu 9 个月前
父节点
当前提交
04ced65f81

+ 12149
- 27
package-lock.json
文件差异内容过多而无法显示
查看文件


+ 1
- 3
public/config.js 查看文件

@@ -3,10 +3,9 @@ window._config = window.isTest
3 3
   ? {
4 4
       // 测试环境
5 5
       webUrl: "https://xhbitest.xhkjedu.com/",
6
-      baseUrl: "https://xhbiapitest.xhkjedu.com/",
6
+      baseUrl: "http://49.4.26.249:8331/",
7 7
       baseImageUrl: "https://xhbifiletest.xhkjedu.com/",
8 8
       showImageUrl: "https://xhbistatictest.xhkjedu.com/",
9
-      useMicroservice: true, // 是否使用微服务
10 9
       axiosApiTimeout: 60, // 接口超时时间 单位秒
11 10
       axiosFileTimeout: 120, // 上传文件超时时间 单位秒
12 11
       // 开发者
@@ -22,7 +21,6 @@ window._config = window.isTest
22 21
       baseUrl: "https://xhbiapi.xhkjedu.com/",
23 22
       baseImageUrl: "https://xhbifile.xhkjedu.com/",
24 23
       showImageUrl: "https://xhbistatic.xhkjedu.com/",
25
-      useMicroservice: true, // 是否使用微服务
26 24
       axiosApiTimeout: 20, // 接口超时时间 单位秒
27 25
       axiosFileTimeout: 30, // 上传文件超时时间 单位秒
28 26
       // 开发者

+ 10
- 0
src/api/admin.js 查看文件

@@ -0,0 +1,10 @@
1
+import { admin_url } from "@/utils/httpRequest";
2
+
3
+/**
4
+ * 1.0.1管理员--账号登录
5
+ */
6
+export const login = (data) => admin_url("admin/login", data);
7
+/**
8
+ * 1.0.4管理员--生成图片验证码
9
+ */
10
+export const img_code = (data) => admin_url("admin/img_code", data);

+ 6
- 0
src/api/appgroup.js 查看文件

@@ -0,0 +1,6 @@
1
+import { appgroup_url } from "@/utils/httpRequest";
2
+
3
+/**
4
+ * 1.0.1管理员--账号登录
5
+ */
6
+export const admin_login = (data) => appgroup_url("admin/login", data);

+ 6
- 0
src/api/region.js 查看文件

@@ -0,0 +1,6 @@
1
+import { region_url } from "@/utils/httpRequest";
2
+
3
+/**
4
+ * 1.0.1管理员--账号登录
5
+ */
6
+export const admin_login = (data) => region_url("admin/login", data);

+ 0
- 279
src/api/system.js 查看文件

@@ -1,279 +0,0 @@
1
-import { ssystem_url } from "@/utils/httpRequest";
2
-
3
-/**
4
- * 用户登录
5
- */
6
-export const login_login = (data) => ssystem_url("login/login", data);
7
-/**
8
- * 用户退出/断开连接
9
- */
10
-export const login_out = (data) => ssystem_url("login/out", data);
11
-/**
12
- *1.2.6分组--用户列表(分享用)
13
- */
14
-export const group_list_gu = (data) => ssystem_url("group/list_gu", data);
15
-/**
16
- * 1.3.1角色--选择列表(分享用)
17
- */
18
-export const role_list_sel = (data) => ssystem_url("role/list_sel", data);
19
-/**
20
- * 4.1.2参数--保存
21
- */
22
-export const dict_add_dict = (data) => ssystem_url("dict/add_dict", data);
23
-/**
24
- * 4.1.3参数--详情
25
- */
26
-export const dict_detail = (data) => ssystem_url("dict/detail", data);
27
-/**
28
- * 4.1.3.2参数--属性
29
- */
30
-export const dict_property = (data) => ssystem_url("dict/property", data);
31
-/**
32
- * 4.1.3.3参数--更新
33
- */
34
-export const dict_edit = (data) => ssystem_url("dict/edit", data);
35
-/**
36
- * 4.1.2.2参数--保存参数详情
37
- */
38
-export const dict_add_detail = (data) => ssystem_url("dict/add_detail", data);
39
-/**
40
- * 4.1.1参数--列表
41
- */
42
-export const dict_list_sel = (data) => ssystem_url("dict/list_sel", data);
43
-/**
44
- * 4.1.4参数--数据列表
45
- */
46
-export const dict_list_data = (data) => ssystem_url("dict/list_data", data);
47
-/**
48
- * 4.1.6参数--分页列表
49
- */
50
-export const dict_list = (data) => ssystem_url("dict/list", data);
51
-/**
52
- * 4.1.7参数--删除
53
- */
54
-export const dict_delete = (data) => ssystem_url("dict/delete", data);
55
-/**
56
- * 4.1.8参数--移动
57
- */
58
-export const dict_move = (data) => ssystem_url("dict/move", data);
59
-/**
60
- * 4.2.3地区--根据名称获取编码
61
- */
62
-export const areazone_get_code = (data) =>
63
-  ssystem_url("areazone/get_code", data);
64
-/**
65
- * 1.1.1用户--列表
66
- */
67
-export const user_list = (data) => ssystem_url("user/list", data);
68
-/**
69
- * 1.1.2用户--添加
70
- */
71
-export const user_add = (data) => ssystem_url("user/add", data);
72
-/**
73
- * 1.1.3用户--更新
74
- */
75
-export const user_edit = (data) => ssystem_url("user/edit", data);
76
-/**
77
- * 1.1.3.2用户--改头像
78
- */
79
-export const user_edit_userpic = (data) =>
80
-  ssystem_url("user/edit_userpic", data);
81
-/**
82
- * 1.1.4用户--删除
83
- */
84
-export const user_delete = (data) => ssystem_url("user/delete", data);
85
-/**
86
- * 1.1.5用户--移除分组
87
- */
88
-export const user_remove_group = (data) =>
89
-  ssystem_url("user/remove_group", data);
90
-/**
91
- * 1.1.5.2用户--分组列表
92
- */
93
-export const user_list_group = (data) => ssystem_url("user/list_group", data);
94
-/**
95
- * 1.1.6.2用户--角色列表
96
- */
97
-export const user_list_role = (data) => ssystem_url("user/list_role", data);
98
-/**
99
- * 1.1.7用户--修改手机号
100
- */
101
-export const user_edit_phone = (data) => ssystem_url("user/edit_phone", data);
102
-/**
103
- * 1.1.8用户--修改密码
104
- */
105
-export const user_edit_pwd = (data) => ssystem_url("user/edit_pwd", data);
106
-/**
107
- * 1.1.9用户--获取验证码
108
- */
109
-export const user_get_code = (data) => ssystem_url("user/get_code", data);
110
-/**
111
- * 1.1.10用户--功能菜单
112
- */
113
-export const power_list_user = (data) => ssystem_url("power/list_user", data);
114
-/**
115
- * 1.2.1分组--列表
116
- */
117
-export const group_list = (data) => ssystem_url("group/list", data);
118
-/**
119
- * 1.2.2分组--添加
120
- */
121
-export const group_add = (data) => ssystem_url("group/add", data);
122
-/**
123
- * 1.2.3分组--更新
124
- */
125
-export const group_edit = (data) => ssystem_url("group/edit", data);
126
-/**
127
- * 1.2.4分组--删除
128
- */
129
-export const group_delete = (data) => ssystem_url("group/delete", data);
130
-/**
131
- * 1.3.1角色--列表
132
- */
133
-export const role_list = (data) => ssystem_url("role/list", data);
134
-/**
135
- * 1.3.2角色--添加
136
- */
137
-export const role_add = (data) => ssystem_url("role/add", data);
138
-/**
139
- * 1.3.2.2角色--添加角色分组用户
140
- */
141
-export const role_add_group_user = (data) =>
142
-  ssystem_url("role/add_group_user", data);
143
-/**
144
- * 1.3.2.3角色--获取角色分组用户
145
- */
146
-export const role_list_gu = (data) => ssystem_url("role/list_gu", data);
147
-/**
148
- * 1.3.2.4角色--角色分组用户选择列表
149
- */
150
-export const role_list_gu_sel = (data) => ssystem_url("role/list_gu_sel", data);
151
-/**
152
- * 1.3.2.5角色--权限选择列表
153
- */
154
-export const power_list_sel = (data) => ssystem_url("power/list_sel", data);
155
-/**
156
- * 1.3.2.6角色--角色权限列表
157
- */
158
-export const role_list_power = (data) => ssystem_url("role/list_power", data);
159
-/**
160
- * 1.3.2.7角色--保存角色权限
161
- */
162
-export const role_add_power = (data) => ssystem_url("role/add_power", data);
163
-/**
164
- * 1.3.2.9 角色--角色资源保存
165
- */
166
-export const roletree_add = (data) => ssystem_url("roletree/add", data);
167
-/**
168
- * 1.3.2.10 角色--角色资源
169
- */
170
-export const roletree_list_role = (data) =>
171
-  ssystem_url("roletree/list_role", data);
172
-/**
173
- * 1.3.3角色--更新
174
- */
175
-export const role_edit = (data) => ssystem_url("role/edit", data);
176
-/**
177
- * 1.3.4角色--删除
178
- */
179
-export const role_delete = (data) => ssystem_url("role/delete", data);
180
-/**
181
- * 1.3.5角色--添加分组
182
- */
183
-export const role_add_group = (data) => ssystem_url("role/add_group", data);
184
-/**
185
- * 1.3.6角色--添加用户
186
- */
187
-export const role_add_user = (data) => ssystem_url("role/add_user", data);
188
-/**
189
- * 1.4.0会话--列表
190
- */
191
-export const user_session_list = (data) =>
192
-  ssystem_url("user_session/list", data);
193
-/**
194
- * 1.4.1会话--单独断开
195
- */
196
-export const user_login_out = (data) => ssystem_url("login/out", data);
197
-/**
198
- * 1.4.2会话--批量断开
199
- */
200
-export const user_session_batch_out = (data) =>
201
-  ssystem_url("user_session/batch_out", data);
202
-/**
203
- * 1.4.3用户--校验用户登录状态
204
- */
205
-export const user_check_login = (data) => ssystem_url("user/check_login", data);
206
-/**
207
- * 1.4.4消息推送--列表
208
- */
209
-export const notice_list = (data) => ssystem_url("notice/list", data);
210
-/**
211
- * 1.4.5消息推送--发送
212
- */
213
-export const notice_send = (data) => ssystem_url("notice/send", data);
214
-/**
215
- * 1.4.6消息推送--删除
216
- */
217
-export const notice_delete = (data) => ssystem_url("notice/delete", data);
218
-/**
219
- * 1.4.7消息推送--置顶
220
- */
221
-export const notice_toped = (data) => ssystem_url("notice/toped", data);
222
-/**
223
- * 1.4.8消息推送--取消置顶
224
- */
225
-export const notice_untoped = (data) => ssystem_url("notice/untoped", data);
226
-/**
227
- * 1.4.9消息推送--批量删除
228
- */
229
-export const notice_deletebatch = (data) =>
230
-  ssystem_url("notice/deletebatch", data);
231
-/**
232
- * 1.4.9消息推送--新增
233
- */
234
-export const notice_add = (data) => ssystem_url("notice/add", data);
235
-/**
236
- * 1.4.10消息推送--编辑
237
- */
238
-export const notice_edit = (data) => ssystem_url("notice/edit", data);
239
-/**
240
- * 1.4.11消息推送--详情
241
- */
242
-export const notice_detail = (data) => ssystem_url("notice/detail", data);
243
-/**
244
- * 1.4.12消息推送--用户列表
245
- */
246
-export const notice_list_user = (data) => ssystem_url("notice/list_user", data);
247
-/**
248
- * 1.4.13消息推送--用户详情
249
- */
250
-export const notice_detail_user = (data) =>
251
-  ssystem_url("notice/detail_user", data);
252
-/**
253
- * 9.1.1 脱敏规则--列表
254
- */
255
-export const tm_list = (data) => ssystem_url("tm/list", data);
256
-/**
257
- * 9.1.2 脱敏规则--添加
258
- */
259
-export const tm_add = (data) => ssystem_url("tm/add", data);
260
-/**
261
- * 9.1.3 脱敏规则--修改
262
- */
263
-export const tm_edit = (data) => ssystem_url("tm/edit", data);
264
-/**
265
- * 9.1.4 脱敏规则--删除
266
- */
267
-export const tm_delete = (data) => ssystem_url("tm/delete", data);
268
-/**
269
- * 9.1.5 脱敏规则--详情
270
- */
271
-export const tm_detail = (data) => ssystem_url("tm/detail", data);
272
-/**
273
- * 9.1.6 脱敏规则--移动
274
- */
275
-export const tm_move = (data) => ssystem_url("tm/move", data);
276
-/**
277
- * 9.1.7 脱敏规则--属性
278
- */
279
-export const tm_attr = (data) => ssystem_url("tm/attr", data);

二进制
src/assets/img/login/bj.png 查看文件


+ 2
- 0
src/assets/img/login/close.svg 查看文件

@@ -0,0 +1,2 @@
1
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1651715334338" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6028" width="600" height="600" xmlns:xlink="http://www.w3.org/1999/xlink"><defs><style type="text/css">@font-face { font-family: feedback-iconfont; src: url("//at.alicdn.com/t/font_1031158_u69w8yhxdu.woff2?t=1630033759944") format("woff2"), url("//at.alicdn.com/t/font_1031158_u69w8yhxdu.woff?t=1630033759944") format("woff"), url("//at.alicdn.com/t/font_1031158_u69w8yhxdu.ttf?t=1630033759944") format("truetype"); }
2
+</style></defs><path d="M512.022187 546.417778c-184.177778 0-368.071111-55.921778-499.114667-167.537778a37.575111 37.575111 0 0 1-3.498667-53.162667 37.944889 37.944889 0 0 1 53.418667-3.470222c231.082667 198.826667 668.302222 198.826667 898.389333 0a37.944889 37.944889 0 0 1 53.418667 3.470222c13.767111 15.644444 12.231111 39.452444-3.498667 53.191111C880.093298 490.496 696.199964 546.417778 512.022187 546.417778z m-136.760889 164.522666a30.833778 30.833778 0 0 1-6.741334 0c-10.325333-1.422222-19.626667-7.111111-25.543111-15.644444-5.944889-8.561778-7.964444-19.228444-5.632-29.354667l24.945778-146.631111a37.973333 37.973333 0 0 1 43.918222-30.805333 37.831111 37.831111 0 0 1 30.947556 43.747555l-24.945778 146.602667a37.376 37.376 0 0 1-36.949333 32.085333z m561.009778-74.581333c-9.955556 0-19.512889-4.039111-26.453334-11.178667l-123.022222-124.245333a37.176889 37.176889 0 0 1 16.042667-64.455111 37.546667 37.546667 0 0 1 37.091555 12.259556l123.050667 124.245333c14.592 14.563556 14.592 38.144 0 52.707555-7.224889 6.826667-16.782222 10.638222-26.737778 10.666667z m-848.497778 0a38.997333 38.997333 0 0 1-24.945778-10.666667 37.176889 37.176889 0 0 1 0-52.707555l123.022222-124.245333a37.518222 37.518222 0 0 1 67.470222 14.136888 37.205333 37.205333 0 0 1-15.815111 38.058667l-123.022222 124.245333a37.006222 37.006222 0 0 1-26.709333 11.178667z m562.744889 74.581333a37.376 37.376 0 0 1-36.693334-30.833777l-24.945777-146.631111a37.176889 37.176889 0 0 1 9.756444-38.826667 37.546667 37.546667 0 0 1 39.424-7.68c13.539556 5.319111 22.755556 17.92 23.694222 32.341333l24.945778 146.631111c1.820444 9.728-0.341333 19.768889-6.030222 27.904-5.688889 8.135111-14.364444 13.653333-24.177778 15.36a30.805333 30.805333 0 0 1-5.973333 1.706667z" p-id="6029" fill="#999999"></path></svg>

二进制
src/assets/img/login/code.png 查看文件


二进制
src/assets/img/login/logo.png 查看文件


+ 2
- 0
src/assets/img/login/open.svg 查看文件

@@ -0,0 +1,2 @@
1
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1651715361431" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6231" xmlns:xlink="http://www.w3.org/1999/xlink" width="600" height="600"><defs><style type="text/css">@font-face { font-family: feedback-iconfont; src: url("//at.alicdn.com/t/font_1031158_u69w8yhxdu.woff2?t=1630033759944") format("woff2"), url("//at.alicdn.com/t/font_1031158_u69w8yhxdu.woff?t=1630033759944") format("woff"), url("//at.alicdn.com/t/font_1031158_u69w8yhxdu.ttf?t=1630033759944") format("truetype"); }
2
+</style></defs><path d="M1018.737778 480.711111s-4.266667-12.8-8.533334-17.066667l-21.333333-42.666666c-21.333333-34.133333-51.2-76.8-93.866667-123.733334C813.937778 207.644444 685.937778 113.777778 511.004444 113.777778s-302.933333 93.866667-384 183.466666c-42.666667 46.933333-72.533333 89.6-93.866666 123.733334-8.533333 17.066667-17.066667 29.866667-21.333334 42.666666-4.266667 4.266667-8.533333 17.066667-8.533333 17.066667-4.266667 12.8-4.266667 25.6 0 34.133333 0 0 4.266667 12.8 8.533333 17.066667l21.333334 42.666667c21.333333 34.133333 51.2 76.8 93.866666 123.733333 81.066667 89.6 209.066667 183.466667 384 183.466667s302.933333-93.866667 384-183.466667c42.666667-46.933333 72.533333-89.6 93.866667-123.733333 8.533333-17.066667 17.066667-29.866667 21.333333-42.666667 4.266667-4.266667 8.533333-17.066667 8.533334-17.066667 4.266667-12.8 4.266667-21.333333 0-34.133333z m-102.4 46.933333c-17.066667 29.866667-46.933333 72.533333-81.066667 110.933334-76.8 81.066667-183.466667 157.866667-324.266667 157.866666s-247.466667-76.8-324.266666-157.866666c-38.4-38.4-64-81.066667-81.066667-110.933334-8.533333-12.8-12.8-21.333333-17.066667-29.866666 4.266667-8.533333 8.533333-17.066667 17.066667-29.866667 21.333333-29.866667 46.933333-72.533333 81.066667-110.933333C263.537778 275.911111 370.204444 199.111111 511.004444 199.111111s247.466667 76.8 324.266667 157.866667c38.4 38.4 64 81.066667 81.066667 110.933333 8.533333 12.8 12.8 21.333333 17.066666 29.866667-4.266667 8.533333-12.8 17.066667-17.066666 29.866666z" p-id="6232" fill="#999999"></path><path d="M511.004444 344.177778c-76.8 0-145.066667 68.266667-145.066666 153.6 0 85.333333 68.266667 153.6 145.066666 153.6 76.8 0 145.066667-68.266667 145.066667-153.6 0-85.333333-68.266667-153.6-145.066667-153.6z m-230.4 153.6c0-128 102.4-238.933333 230.4-238.933334s230.4 110.933333 230.4 238.933334-102.4 238.933333-230.4 238.933333-230.4-110.933333-230.4-238.933333z" p-id="6233" fill="#999999"></path></svg>

二进制
src/assets/img/login/pw.png 查看文件


二进制
src/assets/img/login/user.png 查看文件


+ 34
- 3
src/store/index.js 查看文件

@@ -1,9 +1,40 @@
1 1
 import Vue from "vue";
2 2
 import Vuex from "vuex";
3
+import { login } from "../api/admin";
4
+import { clearStore, setStore } from "../utils/store";
3 5
 Vue.use(Vuex);
4 6
 
5 7
 export default new Vuex.Store({
6
-  state: {},
7
-  mutations: {},
8
-  actions: {}
8
+  state: {
9
+    userInfo: {}
10
+  },
11
+  mutations: {
12
+    // 设置个人信息
13
+    SET_USERIFNO: (state, userInfo) => {
14
+      state.userInfo = userInfo;
15
+      setStore({ name: "xh-control-userInfo", content: userInfo });
16
+    }
17
+  },
18
+  actions: {
19
+    // 登陆
20
+    login_username({ commit }, userInfo) {
21
+      return new Promise((resolve, reject) => {
22
+        login(userInfo).then((res) => {
23
+          if (res.code == 0) {
24
+            const userInfo = res.obj;
25
+            commit("SET_USERIFNO", userInfo);
26
+          }
27
+          resolve(res);
28
+        });
29
+      });
30
+    },
31
+    // 登出
32
+    loginOut({ commit }) {
33
+      return new Promise((resolve, reject) => {
34
+        commit("SET_USERIFNO", []);
35
+        clearStore();
36
+        resolve("请重新登录!");
37
+      });
38
+    }
39
+  }
9 40
 });

+ 10
- 36
src/utils/httpRequest.js 查看文件

@@ -101,64 +101,38 @@ http.interceptors.response.use(
101 101
   }
102 102
 );
103 103
 /**
104
- * @param {*} prefix 微服务前缀
105 104
  * @param {*} url 不带前缀的url
106 105
  * @param {*} data 传参
107 106
  * @returns Promise
108 107
  */
109
-const setRequest = ({ prefix, url, data }) =>
108
+const setRequest = ({ url, data }) =>
110 109
   http({
111
-    url: `${window._config.baseUrl}${
112
-      window._config.useMicroservice ? prefix : ""
113
-    }${url}`,
110
+    url: `${window._config.baseUrl}${url}`,
114 111
     method: "post",
115 112
     data: data || {}
116 113
   });
117 114
 /**
118
- * 微服务前缀 sdatasource/
119 115
  * @param {*} url 不带前缀的url
120 116
  * @param {*} data 传参
121 117
  * @returns Promise
122 118
  */
123
-export const sdatasource_url = (url, data) =>
119
+//管理员
120
+export const admin_url = (url, data) =>
124 121
   setRequest({
125
-    prefix: "sdatasource/",
126 122
     url,
127 123
     data
128 124
   });
129
-/**
130
- * 微服务前缀 ssystem/
131
- * @param {*} url 不带前缀的url
132
- * @param {*} data 传参
133
- * @returns Promise
134
- */
135
-export const ssystem_url = (url, data) =>
136
-  setRequest({
137
-    prefix: "ssystem/",
138
-    url,
139
-    data
140
-  });
141
-/**
142
- * 微服务前缀 sdataintegration/
143
- * @param {*} url 不带前缀的url
144
- * @param {*} data 传参
145
- * @returns Promise
146
- */
147
-export const sdataintegration_url = (url, data) =>
125
+
126
+//区域
127
+export const region_url = (url, data) =>
148 128
   setRequest({
149
-    prefix: "sdataintegration/",
150 129
     url,
151 130
     data
152 131
   });
153
-/**
154
- * 微服务前缀 sanalysis/
155
- * @param {*} url 不带前缀的url
156
- * @param {*} data 传参
157
- * @returns Promise
158
- */
159
-export const sanalysis_url = (url, data) =>
132
+
133
+//应用
134
+export const appgroup_url = (url, data) =>
160 135
   setRequest({
161
-    prefix: "sanalysis/",
162 136
     url,
163 137
     data
164 138
   });

+ 99
- 0
src/utils/store.js 查看文件

@@ -0,0 +1,99 @@
1
+import { validatenull } from "@/utils/validate";
2
+
3
+/**
4
+ * 存储localStorage
5
+ */
6
+export const setStore = (params = {}) => {
7
+  let { name, content, type } = params;
8
+  let obj = {
9
+    dataType: typeof content,
10
+    content: content,
11
+    type: type,
12
+    datetime: new Date().getTime()
13
+  };
14
+  if (type) window.sessionStorage.setItem(name, JSON.stringify(obj));
15
+  else window.localStorage.setItem(name, JSON.stringify(obj));
16
+};
17
+
18
+/**
19
+ * 获取localStorage
20
+ */
21
+export const getStore = (params = {}) => {
22
+  let { name, debug } = params;
23
+  let obj = {};
24
+  let content;
25
+  obj = window.sessionStorage.getItem(name);
26
+  if (validatenull(obj)) obj = window.localStorage.getItem(name);
27
+  if (validatenull(obj)) return;
28
+  try {
29
+    obj = JSON.parse(obj);
30
+  } catch {
31
+    return obj;
32
+  }
33
+  if (debug) {
34
+    return obj;
35
+  }
36
+  if (obj.dataType === "string") {
37
+    content = obj.content;
38
+  } else if (obj.dataType === "number") {
39
+    content = Number(obj.content);
40
+  } else if (obj.dataType === "boolean") {
41
+    content = this.eval(obj.content);
42
+  } else if (obj.dataType === "object") {
43
+    content = obj.content;
44
+  }
45
+  return content;
46
+};
47
+
48
+/**
49
+ * 删除localStorage
50
+ */
51
+export const removeStore = (params = {}) => {
52
+  let { name, type } = params;
53
+  if (type) {
54
+    window.sessionStorage.removeItem(name);
55
+  } else {
56
+    window.localStorage.removeItem(name);
57
+  }
58
+};
59
+
60
+/**
61
+ * 获取全部localStorage
62
+ */
63
+export const getAllStore = (params = {}) => {
64
+  let list = [];
65
+  let { type } = params;
66
+  if (type) {
67
+    for (let i = 0; i <= window.sessionStorage.length; i++) {
68
+      list.push({
69
+        name: window.sessionStorage.key(i),
70
+        content: getStore({
71
+          name: window.sessionStorage.key(i),
72
+          type: "session"
73
+        })
74
+      });
75
+    }
76
+  } else {
77
+    for (let i = 0; i <= window.localStorage.length; i++) {
78
+      list.push({
79
+        name: window.localStorage.key(i),
80
+        content: getStore({
81
+          name: window.localStorage.key(i)
82
+        })
83
+      });
84
+    }
85
+  }
86
+  return list;
87
+};
88
+
89
+/**
90
+ * 清空全部localStorage
91
+ */
92
+export const clearStore = (params = {}) => {
93
+  let { type } = params;
94
+  if (type) {
95
+    window.sessionStorage.clear();
96
+  } else {
97
+    window.localStorage.clear();
98
+  }
99
+};

+ 304
- 0
src/utils/validate.js 查看文件

@@ -0,0 +1,304 @@
1
+/**
2
+ * Created by jiachenpan on 16/11/18.
3
+ */
4
+
5
+export function isvalidUsername(str) {
6
+  const validMap = ["admin", "editor"];
7
+  return validMap.indexOf(str.trim()) >= 0;
8
+}
9
+
10
+/* 合法uri */
11
+export function validateURL(textval) {
12
+  const urlregex =
13
+    /^(https?|ftp):\/\/([a-zA-Z0-9.-]+(:[a-zA-Z0-9.&%$-]+)*@)*((25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]?)(\.(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9]?[0-9])){3}|([a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+\.(com|edu|gov|int|mil|net|org|biz|arpa|info|name|pro|aero|coop|museum|[a-zA-Z]{2}))(:[0-9]+)*(\/($|[a-zA-Z0-9.,?'\\+&%$#=~_-]+))*$/;
14
+  return urlregex.test(textval);
15
+}
16
+/**
17
+ * 邮箱
18
+ * @param {*} s
19
+ */
20
+export function isEmail(s) {
21
+  return /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+((.[a-zA-Z0-9_-]{2,3}){1,2})$/.test(
22
+    s
23
+  );
24
+}
25
+
26
+/**
27
+ * 手机号码
28
+ * @param {*} s
29
+ */
30
+export function isMobile(s) {
31
+  return /^1[0-9]{10}$/.test(s);
32
+}
33
+
34
+/**
35
+ * 电话号码
36
+ * @param {*} s
37
+ */
38
+export function isPhone(s) {
39
+  return /^([0-9]{3,4}-)?[0-9]{7,8}$/.test(s);
40
+}
41
+
42
+/**
43
+ * URL地址
44
+ * @param {*} s
45
+ */
46
+export function isURL(s) {
47
+  return /^http[s]?:\/\/.*/.test(s);
48
+}
49
+
50
+/* 小写字母 */
51
+export function validateLowerCase(str) {
52
+  const reg = /^[a-z]+$/;
53
+  return reg.test(str);
54
+}
55
+
56
+/* 大写字母 */
57
+export function validateUpperCase(str) {
58
+  const reg = /^[A-Z]+$/;
59
+  return reg.test(str);
60
+}
61
+
62
+/* 大小写字母 */
63
+export function validatAlphabets(str) {
64
+  const reg = /^[A-Za-z]+$/;
65
+  return reg.test(str);
66
+}
67
+/* 验证pad还是pc */
68
+export const vaildatePc = function () {
69
+  const userAgentInfo = navigator.userAgent;
70
+  const Agents = [
71
+    "Android",
72
+    "iPhone",
73
+    "SymbianOS",
74
+    "Windows Phone",
75
+    "iPad",
76
+    "iPod"
77
+  ];
78
+  let flag = true;
79
+  for (var v = 0; v < Agents.length; v++) {
80
+    if (userAgentInfo.indexOf(Agents[v]) > 0) {
81
+      flag = false;
82
+      break;
83
+    }
84
+  }
85
+  return flag;
86
+};
87
+/**
88
+ * validate email
89
+ * @param email
90
+ * @returns {boolean}
91
+ */
92
+export function validateEmail(email) {
93
+  const re =
94
+    /^(([^<>()\\[\]\\.,;:\s@"]+(\.[^<>()\\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
95
+  return re.test(email);
96
+}
97
+
98
+/**
99
+ * 判断身份证号码
100
+ */
101
+export function cardid(code) {
102
+  let list = [];
103
+  let result = true;
104
+  let msg = "";
105
+  var city = {
106
+    11: "北京",
107
+    12: "天津",
108
+    13: "河北",
109
+    14: "山西",
110
+    15: "内蒙古",
111
+    21: "辽宁",
112
+    22: "吉林",
113
+    23: "黑龙江 ",
114
+    31: "上海",
115
+    32: "江苏",
116
+    33: "浙江",
117
+    34: "安徽",
118
+    35: "福建",
119
+    36: "江西",
120
+    37: "山东",
121
+    41: "河南",
122
+    42: "湖北 ",
123
+    43: "湖南",
124
+    44: "广东",
125
+    45: "广西",
126
+    46: "海南",
127
+    50: "重庆",
128
+    51: "四川",
129
+    52: "贵州",
130
+    53: "云南",
131
+    54: "西藏 ",
132
+    61: "陕西",
133
+    62: "甘肃",
134
+    63: "青海",
135
+    64: "宁夏",
136
+    65: "新疆",
137
+    71: "台湾",
138
+    81: "香港",
139
+    82: "澳门",
140
+    91: "国外 "
141
+  };
142
+  if (!validatenull(code)) {
143
+    if (code.length === 18) {
144
+      if (!code || !/(^\d{18}$)|(^\d{17}(\d|X|x)$)/.test(code)) {
145
+        msg = "证件号码格式错误";
146
+      } else if (!city[code.substr(0, 2)]) {
147
+        msg = "地址编码错误";
148
+      } else {
149
+        // 18位身份证需要验证最后一位校验位
150
+        code = code.split("");
151
+        // ∑(ai×Wi)(mod 11)
152
+        // 加权因子
153
+        var factor = [7, 9, 10, 5, 8, 4, 2, 1, 6, 3, 7, 9, 10, 5, 8, 4, 2];
154
+        // 校验位
155
+        var parity = [1, 0, "X", 9, 8, 7, 6, 5, 4, 3, 2, "x"];
156
+        var sum = 0;
157
+        var ai = 0;
158
+        var wi = 0;
159
+        for (var i = 0; i < 17; i++) {
160
+          ai = code[i];
161
+          wi = factor[i];
162
+          sum += ai * wi;
163
+        }
164
+        if (parity[sum % 11] !== code[17]) {
165
+          msg = "证件号码校验位错误";
166
+        } else {
167
+          result = false;
168
+        }
169
+      }
170
+    } else {
171
+      msg = "证件号码长度不为18位";
172
+    }
173
+  } else {
174
+    msg = "证件号码不能为空";
175
+  }
176
+  list.push(result);
177
+  list.push(msg);
178
+  return list;
179
+}
180
+/**
181
+ * 判断手机号码是否正确
182
+ */
183
+export function isvalidatemobile(phone) {
184
+  let list = [];
185
+  let result = true;
186
+  let msg = "";
187
+  var isPhone = /^0\d{2,3}-?\d{7,8}$/;
188
+  // 增加134 减少|1349[0-9]{7},增加181,增加145,增加17[678]
189
+  if (!validatenull(phone)) {
190
+    if (phone.length === 11) {
191
+      if (isPhone.test(phone)) {
192
+        msg = "手机号码格式不正确";
193
+      } else {
194
+        result = false;
195
+      }
196
+    } else {
197
+      msg = "手机号码格式不正确";
198
+    }
199
+  } else {
200
+    msg = "手机号码不能为空";
201
+  }
202
+  list.push(result);
203
+  list.push(msg);
204
+  return list;
205
+}
206
+/**
207
+ * 判断手机号码是否正确 不是必填
208
+ */
209
+export function check_phone(phone) {
210
+  let list = [];
211
+  let result = true;
212
+  let msg = "";
213
+  var isPhone = /^[1][3,4,5,6,7,8,9][0-9]{9}$/;
214
+  if (!validatenull(phone)) {
215
+    if (phone.length === 11) {
216
+      if (!isPhone.test(phone)) {
217
+        msg = "手机号码格式不正确";
218
+      } else {
219
+        result = false;
220
+      }
221
+    } else {
222
+      msg = "手机号码格式不正确";
223
+    }
224
+  } else {
225
+    result = false;
226
+  }
227
+  list.push(result);
228
+  list.push(msg);
229
+  return list;
230
+}
231
+/**
232
+ * 判断姓名是否正确
233
+ */
234
+export function validatename(name) {
235
+  var regName = /^[\u4e00-\u9fa5]{2,4}$/;
236
+  if (!regName.test(name)) return false;
237
+  return true;
238
+}
239
+/**
240
+ * 判断是否为整数
241
+ */
242
+export function validatenum(num, type) {
243
+  let regName = /[^\d.]/g;
244
+  if (type === 1) {
245
+    if (!regName.test(num)) return false;
246
+  } else if (type === 2) {
247
+    regName = /[^\d]/g;
248
+    if (!regName.test(num)) return false;
249
+  }
250
+  return true;
251
+}
252
+/**
253
+ * 判断是否为小数
254
+ */
255
+export function validatenumord(num, type) {
256
+  let regName = /[^\d.]/g;
257
+  if (type === 1) {
258
+    if (!regName.test(num)) return false;
259
+  } else if (type === 2) {
260
+    regName = /[^\d.]/g;
261
+    if (!regName.test(num)) return false;
262
+  }
263
+  return true;
264
+}
265
+/**
266
+ * 判断是否为空
267
+ */
268
+export function validatenull(val) {
269
+  if (typeof val === "boolean") {
270
+    return false;
271
+  }
272
+  if (typeof val === "number") {
273
+    return false;
274
+  }
275
+  if (val instanceof Array) {
276
+    if (val.length === 0) return true;
277
+  } else if (val instanceof Object) {
278
+    if (JSON.stringify(val) === "{}") return true;
279
+  } else {
280
+    if (
281
+      val === "null" ||
282
+      val === null ||
283
+      val === "undefined" ||
284
+      val === undefined ||
285
+      val === ""
286
+    )
287
+      return true;
288
+    return false;
289
+  }
290
+  return false;
291
+}
292
+// 密码必须是6-16位的英文字母、数字组合
293
+export function isLoginPwd(val) {
294
+  const passRegex = new RegExp("^(?![0-9]+$)(?![a-zA-Z]+$)[0-9A-Za-z]{6,16}$");
295
+  return passRegex.test(val);
296
+}
297
+// 修改密码功能改为: 密码必须是8-16位大小写英文字母、数字组合 。
298
+export function isValidPassword(password) {
299
+  const reg = /^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)[a-zA-Z\d]{8,16}$/;
300
+  return {
301
+    is: reg.test(password),
302
+    msg: "密码必须是8-16位大小写英文字母、数字组合"
303
+  };
304
+}

+ 490
- 4
src/views/login/login.vue 查看文件

@@ -1,14 +1,500 @@
1 1
 <template>
2
-  <div></div>
2
+  <div class="wrap">
3
+    <div class="logo">
4
+      <img class="logo_img" src="../../assets/img/login/logo.png" />
5
+      <span class="logo_title">星火云鸽管控平台</span>
6
+    </div>
7
+    <div class="loginInner">
8
+      <div class="welcome">欢迎登录</div>
9
+      <!--      <div class="login_type">-->
10
+      <!--        <div @click="usertype = 1" :class="[usertype == 1 ? 'active' : '']">-->
11
+      <!--          账号登录-->
12
+      <!--        </div>-->
13
+      <!--        <div @click="usertype = 2" :class="[usertype == 2 ? 'active' : '']">-->
14
+      <!--          验证码登录-->
15
+      <!--        </div>-->
16
+      <!--      </div>-->
17
+      <Form ref="loginForm" :model="loginForm" :rules="formRules">
18
+        <FormItem prop="loginname">
19
+          <img class="img" src="../../assets/img/login/user.png" alt="" />
20
+          <Input
21
+            v-model="loginForm.loginname"
22
+            clearable
23
+            @keyup.enter.native="login_by_username('loginForm')"
24
+            placeholder="请输入账号"
25
+          />
26
+        </FormItem>
27
+        <FormItem prop="loginpwd">
28
+          <img class="img" src="../../assets/img/login/pw.png" alt="" />
29
+          <Input
30
+            type="password"
31
+            class="show_input"
32
+            oncopy="return false"
33
+            onpaste="return false"
34
+            oncut="return false"
35
+            v-model="loginForm.loginpwd"
36
+            @keyup.enter.native="login_by_username('loginForm')"
37
+            placeholder="请输入密码"
38
+          />
39
+          <div class="pwd">
40
+            <img
41
+              v-if="show_pw"
42
+              @click="togglePw"
43
+              src="../../assets/img/login/open.svg"
44
+              alt=""
45
+            />
46
+            <img
47
+              v-else
48
+              @click="togglePw"
49
+              src="../../assets/img/login/close.svg"
50
+              alt=""
51
+            />
52
+          </div>
53
+        </FormItem>
54
+        <FormItem prop="msgcode" class="changecode">
55
+          <img class="img" src="../../assets/img/login/code.png" alt="" />
56
+          <Input
57
+            v-model="loginForm.msgcode"
58
+            class="input"
59
+            @keyup.enter.native="login_by_username('loginForm')"
60
+            v-noFill
61
+            readonly
62
+            placeholder="请输入验证码"
63
+          />
64
+          <img
65
+            v-if="code_info.base64Str"
66
+            class="code_img"
67
+            :src="code_info.base64Str"
68
+            @click="getCodeImg()"
69
+            title="点击刷新验证码"
70
+          />
71
+          <span class="emit_code" v-else @click="getCodeImg()">获取验证码</span>
72
+        </FormItem>
73
+        <FormItem class="btn_bottom">
74
+          <Checkbox v-model="pwd">记住密码</Checkbox>
75
+        </FormItem>
76
+      </Form>
77
+      <Button
78
+        :loading="wait_flag"
79
+        type="primary"
80
+        @click.enter="login_by_username('loginForm')"
81
+        >登&nbsp;录</Button
82
+      >
83
+    </div>
84
+  </div>
3 85
 </template>
4 86
 
5 87
 <script>
88
+import { img_code } from "@/api/admin";
89
+
90
+const Base64 = require("js-base64").Base64;
6 91
 export default {
7 92
   data() {
8
-    return {};
93
+    // 手机号验证
94
+    const phoneCheck = async (rule, value, callback) => {
95
+      var filter = /^[1][3,4,5,6,7,8,9][0-9]{9}$/;
96
+      this.isemit = false;
97
+      if (!value) {
98
+        return callback(new Error("手机号码不能为空"));
99
+      }
100
+      let blnTest = filter.test(value);
101
+      if (!blnTest) {
102
+        return callback(new Error("手机号码格式不正确"));
103
+      } else {
104
+        this.isemit = true;
105
+      }
106
+    };
107
+    return {
108
+      code_info: {
109
+        base64Str: "",
110
+        code: ""
111
+      },
112
+      usertype: 1,
113
+      time1: null,
114
+      isemit: false,
115
+      userInfo: {},
116
+      wait_flag: false,
117
+      loginForm: {
118
+        loginname: "",
119
+        loginpwd: "",
120
+        msgcode: "",
121
+        phone: ""
122
+      },
123
+      formRules: {
124
+        loginname: [
125
+          { required: true, message: "账号不能为空", trigger: "blur" },
126
+          {
127
+            min: 4,
128
+            max: 18,
129
+            message: "账号长度为4~18个字符"
130
+          }
131
+        ],
132
+        loginpwd: [
133
+          { required: true, message: "密码不能为空", trigger: "blur" },
134
+          {
135
+            min: 6,
136
+            max: 16,
137
+            message: "密码长度为6~16个字符"
138
+          }
139
+        ],
140
+        phone: [{ required: true, validator: phoneCheck, trigger: "blur" }],
141
+        msgcode: [
142
+          { required: true, message: "短信验证码不能为空", trigger: "blur" }
143
+        ]
144
+      },
145
+      pwd: false,
146
+      show_pw: false,
147
+      time: 0
148
+    };
149
+  },
150
+  directives: {
151
+    // 防止input输入框自动填充
152
+    noFill: {
153
+      inserted: (el) => {
154
+        let inputEl = el.getElementsByTagName("input")[0];
155
+        if (inputEl) {
156
+          inputEl.addEventListener("focus", () => {
157
+            inputEl.removeAttribute("readonly");
158
+          });
159
+          inputEl.addEventListener("blur", () => {
160
+            inputEl.setAttribute("readonly", "readonly");
161
+          });
162
+        }
163
+      }
164
+    }
165
+  },
166
+  created() {
167
+    // this.$removeEncodeStorage("userInfo");
168
+    // 在页面加载时从cookie获取登录信息
169
+    let loginname = this.getCookie("loginname");
170
+    let loginpwd = Base64.decode(this.getCookie("loginpwd"));
171
+    // 如果存在赋值给表单,并且将记住密码勾选
172
+    if (loginname) {
173
+      this.loginForm.loginname = loginname;
174
+      this.loginForm.loginpwd = loginpwd;
175
+      this.pwd = true;
176
+    }
177
+  },
178
+  watch: {
179
+    time() {
180
+      if (this.time == 0) {
181
+        if (this.time1) {
182
+          clearInterval(this.time1);
183
+        }
184
+      }
185
+    }
186
+  },
187
+  mounted() {
188
+    window.addEventListener("copy", this.inputHandle);
189
+    window.addEventListener("paste", this.inputHandle);
190
+    window.addEventListener("cut", this.inputHandle);
191
+  },
192
+  beforeDestroy() {
193
+    window.removeEventListener("copy", this.inputHandle);
194
+    window.removeEventListener("paste", this.inputHandle);
195
+    window.removeEventListener("cut", this.inputHandle);
196
+    clearInterval(this.time1);
9 197
   },
10
-  methods: {}
198
+  methods: {
199
+    //获取验证码
200
+    getCodeImg() {
201
+      if (!this.loginForm.loginname) {
202
+        this.$Message.error("请输入账号");
203
+        return;
204
+      }
205
+      img_code({
206
+        loginname: this.loginForm.loginname
207
+      }).then((data) => {
208
+        if (data.code === 0) {
209
+          this.code_info = data.obj;
210
+        } else {
211
+          this.$Message.error(data.msg);
212
+        }
213
+      });
214
+    },
215
+    inputHandle() {
216
+      let edit = document.querySelector(".show_input");
217
+      edit.oncopy = function () {
218
+        return false;
219
+      };
220
+      edit.onpaste = function () {
221
+        return false;
222
+      };
223
+      edit.oncut = function () {
224
+        return false;
225
+      };
226
+    },
227
+    //切换眼睛
228
+    togglePw() {
229
+      this.show_pw = !this.show_pw;
230
+      let input = document.querySelector(".show_input input");
231
+      if (this.show_pw) {
232
+        input.setAttribute("type", "text");
233
+      } else {
234
+        input.setAttribute("type", "password");
235
+      }
236
+    },
237
+    //登录
238
+    login_by_username(name) {
239
+      let that = this;
240
+      console.log(name);
241
+      this.$refs[name].validate((valid) => {
242
+        if (valid) {
243
+          if (
244
+            that.loginForm.msgcode.toLowerCase() !==
245
+            that.code_info.code.toLowerCase()
246
+          ) {
247
+            this.$Message.error("验证码不正确");
248
+            return;
249
+          }
250
+          that.wait_flag = true;
251
+          let loginForm = that.loginForm;
252
+          that.$store.dispatch("login_username", loginForm).then((res) => {
253
+            that.wait_flag = false;
254
+            if (res.code == 0) {
255
+              that.$Message.success(res.msg);
256
+              //1平台管理员2区域管理员3学校管理员
257
+              console.log(res.obj);
258
+              let atype = res.obj.atype;
259
+              atype = 2;
260
+              if (atype === 1) {
261
+              } else if (atype === 2) {
262
+                this.$router.replace({ name: "region" });
263
+              } else if (atype === 3) {
264
+              }
265
+              that.set_userInfo();
266
+            } else {
267
+              that.$Message.error(res.msg);
268
+              that.wait_flag = false;
269
+            }
270
+          });
271
+        }
272
+      });
273
+    },
274
+    // 记住密码功能
275
+    set_userInfo() {
276
+      if (this.pwd) {
277
+        this.setCookie("loginname", this.loginForm.loginname, 86400);
278
+        this.setCookie("usertype", this.loginForm.usertype, 86400);
279
+        // base64加密密码
280
+        let loginpwd = Base64.encode(this.loginForm.loginpwd);
281
+        this.setCookie("loginpwd", loginpwd, 86400);
282
+      } else {
283
+        this.setCookie("loginname", "");
284
+        this.setCookie("loginpwd", "");
285
+      }
286
+    },
287
+    //验证码登录
288
+    go_type() {},
289
+    //忘记密码
290
+    tousecrt() {},
291
+    // 获取cookie
292
+    getCookie: function (key) {
293
+      if (document.cookie.length > 0) {
294
+        var start = document.cookie.indexOf(key + "=");
295
+        if (start !== -1) {
296
+          start = start + key.length + 1;
297
+          var end = document.cookie.indexOf(";", start);
298
+          if (end === -1) end = document.cookie.length;
299
+          return unescape(document.cookie.substring(start, end));
300
+        }
301
+      }
302
+      return "";
303
+    },
304
+    // 保存cookie
305
+    setCookie: function (cName, value, expiredays) {
306
+      var exdate = new Date();
307
+      exdate.setDate(exdate.getDate() + expiredays);
308
+      document.cookie =
309
+        cName +
310
+        "=" +
311
+        decodeURIComponent(value) +
312
+        (expiredays == null ? "" : ";expires=" + exdate.toGMTString());
313
+    }
314
+  }
11 315
 };
12 316
 </script>
13 317
 
14
-<style lang="less" scoped></style>
318
+<style lang="less" scoped>
319
+.wrap {
320
+  height: 100%;
321
+  background: url("../../assets/img/login/bj.png") no-repeat;
322
+  background-size: 100% 100%;
323
+  position: relative;
324
+  .logo {
325
+    position: absolute;
326
+    top: 70px;
327
+    left: 60px;
328
+    width: 300px;
329
+    height: 50px;
330
+    display: flex;
331
+    align-items: center;
332
+    .logo_img {
333
+      width: 45px;
334
+      height: 45px;
335
+      margin-right: 10px;
336
+    }
337
+    .logo_title {
338
+      color: #414354;
339
+      font-size: 20px;
340
+      font-weight: 700;
341
+      font-family: "HarmonyOSSansSC";
342
+    }
343
+  }
344
+  .loginInner {
345
+    width: 400px;
346
+    height: 440px;
347
+    padding: 40px;
348
+    border-radius: 20px;
349
+    opacity: 0.88;
350
+    background: #ffffff;
351
+    box-shadow: 0 0 18px 0 #deeaffe0;
352
+    position: absolute;
353
+    right: 160px;
354
+    bottom: 160px;
355
+    .welcome {
356
+      height: 30px;
357
+      color: #000000;
358
+      font-size: 24px;
359
+      font-family: "AlibabaPuHuiTi";
360
+      text-align: center;
361
+    }
362
+    .login_type {
363
+      height: 40px;
364
+      display: flex;
365
+      justify-content: center;
366
+      align-items: center;
367
+      margin-bottom: 10px;
368
+      div {
369
+        color: #7c8db5;
370
+        font-size: 16px;
371
+        font-family: "SourceHanSansCN";
372
+        cursor: pointer;
373
+        &:first-of-type {
374
+          margin-right: 20px;
375
+        }
376
+      }
377
+      .active {
378
+        color: #253a70;
379
+        position: relative;
380
+        &::after {
381
+          display: block;
382
+          content: "";
383
+          height: 2px;
384
+          width: 30px;
385
+          background-color: #339dff;
386
+          position: absolute;
387
+          top: 24px;
388
+          left: 30%;
389
+        }
390
+      }
391
+    }
392
+    /deep/ .ivu-form {
393
+      .ivu-form-item {
394
+        .ivu-form-item-content {
395
+          position: relative;
396
+          .img {
397
+            position: absolute;
398
+            z-index: 33;
399
+            width: 16px;
400
+            height: 16px;
401
+            top: 12px;
402
+            left: 15px;
403
+          }
404
+          .ivu-input-wrapper {
405
+            width: 100%;
406
+            // height: 47px;
407
+            input {
408
+              &:-moz-placeholder {
409
+                color: #999 !important;
410
+              }
411
+            }
412
+            .ivu-input {
413
+              height: 40px;
414
+              padding-left: 40px;
415
+            }
416
+            .ivu-input-icon {
417
+              line-height: 50px;
418
+            }
419
+            .ivu-input-icon-clear {
420
+              line-height: 50px;
421
+            }
422
+            // padding-left: 20px;
423
+          }
424
+          .ivu-checkbox-wrapper {
425
+            span {
426
+              font-size: 15px;
427
+              font-family: "Microsoft YaHei";
428
+              font-weight: 400;
429
+              color: rgba(136, 136, 136, 1);
430
+              line-height: 17px;
431
+            }
432
+          }
433
+          .pwd {
434
+            position: absolute;
435
+            z-index: 33;
436
+            width: 16px;
437
+            height: 16px;
438
+            top: 12px;
439
+            right: 15px;
440
+          }
441
+          .pwd img {
442
+            width: 16px;
443
+            height: 16px;
444
+            vertical-align: top;
445
+            cursor: pointer;
446
+          }
447
+        }
448
+      }
449
+      .btn_bottom {
450
+        height: 32px;
451
+        .ivu-form-item-content {
452
+          display: flex;
453
+          justify-content: space-between;
454
+          a {
455
+            //color: @theme_color;
456
+          }
457
+        }
458
+      }
459
+    }
460
+    /deep/ .ivu-btn {
461
+      width: 100%;
462
+      height: 40px;
463
+      span {
464
+        font-size: 18px;
465
+        font-family: "Microsoft YaHei";
466
+        font-weight: 400;
467
+        color: rgba(255, 255, 255, 1);
468
+      }
469
+    }
470
+    .changecode {
471
+      display: flex;
472
+      /deep/ .ivu-form-item-content {
473
+        width: 100%;
474
+        .input {
475
+          width: calc(100% - 120px) !important;
476
+          margin-right: 10px;
477
+        }
478
+        .emit_code {
479
+          display: inline-block;
480
+          width: 110px;
481
+          line-height: 40px;
482
+          height: 40px;
483
+          text-align: center;
484
+          border: 1px solid #339dff;
485
+          border-radius: 6px;
486
+          cursor: pointer;
487
+          color: #339dff;
488
+          vertical-align: bottom;
489
+        }
490
+        .code_img {
491
+          width: 110px;
492
+          height: 40px;
493
+          cursor: pointer;
494
+          vertical-align: bottom;
495
+        }
496
+      }
497
+    }
498
+  }
499
+}
500
+</style>

正在加载...
取消
保存