From ea28be2f5f65afd8406540c27cfc48425e020e4e Mon Sep 17 00:00:00 2001 From: caoqianming Date: Wed, 23 Sep 2020 08:40:13 +0800 Subject: [PATCH] msg --- client/src/App.vue | 15 + client/src/api/msg.js | 9 + client/src/api/user.js | 9 + client/src/components/Pagination/index.vue | 4 +- client/src/store/modules/user.js | 18 +- client/src/styles/index.scss | 40 ++- client/src/utils/request.js | 28 +- client/src/views/login/index.vue | 316 +++++++++++++----- server/apps/system/migrations/0004_message.py | 28 ++ server/apps/system/models.py | 6 +- server/apps/system/serializers.py | 1 + server/apps/system/urls.py | 3 +- server/apps/system/views.py | 69 +++- server/db.sqlite3 | Bin 44654592 -> 44654592 bytes server/server/urls.py | 3 +- 15 files changed, 444 insertions(+), 105 deletions(-) create mode 100644 client/src/api/msg.js create mode 100644 server/apps/system/migrations/0004_message.py diff --git a/client/src/App.vue b/client/src/App.vue index ec9032c..2d9191c 100644 --- a/client/src/App.vue +++ b/client/src/App.vue @@ -9,3 +9,18 @@ export default { name: 'App' } + \ No newline at end of file diff --git a/client/src/api/msg.js b/client/src/api/msg.js new file mode 100644 index 0000000..bc20ece --- /dev/null +++ b/client/src/api/msg.js @@ -0,0 +1,9 @@ +import request from '@/utils/request' + +export function sendMsg(data) { + return request({ + url: '/system/sendmsg/', + method: 'post', + data + }) + } \ No newline at end of file diff --git a/client/src/api/user.js b/client/src/api/user.js index 2712ba4..3bf3700 100644 --- a/client/src/api/user.js +++ b/client/src/api/user.js @@ -8,6 +8,15 @@ export function login(data) { }) } +export function login2(data) { + //验证码登陆 + return request({ + url: '/token2/', + method: 'post', + data + }) +} + export function logout() { return request({ url: '/token/black/', diff --git a/client/src/components/Pagination/index.vue b/client/src/components/Pagination/index.vue index c815e13..c5ace71 100644 --- a/client/src/components/Pagination/index.vue +++ b/client/src/components/Pagination/index.vue @@ -90,10 +90,10 @@ export default { } -