From e697c9e82fd1dd39dd5b14e2726a4239d84299b0 Mon Sep 17 00:00:00 2001 From: xiongxiaoyang <773861846@qq.com> Date: Sun, 29 May 2022 16:33:46 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=A2=9E=E5=8A=A0=E4=BD=9C=E5=AE=B6?= =?UTF-8?q?=E5=B0=8F=E8=AF=B4=E5=8F=91=E5=B8=83=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 3 +- .env.production | 3 +- src/api/author.js | 4 + src/components/author/Header.vue | 17 + src/views/Book.vue | 3 +- src/views/UserSetup.vue | 8 +- src/views/author/BookList.vue | 1005 +++++++++++++++++++++--------- 7 files changed, 722 insertions(+), 321 deletions(-) create mode 100644 src/components/author/Header.vue diff --git a/.env.development b/.env.development index 1fea89a..b395ead 100644 --- a/.env.development +++ b/.env.development @@ -2,7 +2,6 @@ ENV = 'development' VUE_APP_BASE_API_URL = 'http://127.0.0.1:8888/api' -VUE_APP_BASE_IMG_URL = 'http://47.106.243.172:8888' -VUE_APP_BASE_UPLOAD_IMG_URL = 'http://127.0.0.1:8888' +VUE_APP_BASE_IMG_URL = 'http://127.0.0.1:8888' diff --git a/.env.production b/.env.production index 6eaf4c3..6c9ea06 100644 --- a/.env.production +++ b/.env.production @@ -2,5 +2,4 @@ ENV = 'production' VUE_APP_BASE_API_URL = 'http://47.106.243.172:8888/api/front' -VUE_APP_BASE_IMG_URL = 'http://47.106.243.172:8888' -VUE_APP_BASE_UPLOAD_IMG_URL = 'http://127.0.0.1:8888' +VUE_APP_BASE_IMG_URL = 'http://127.0.0.1:8888' diff --git a/src/api/author.js b/src/api/author.js index 784f1ac..6759e56 100644 --- a/src/api/author.js +++ b/src/api/author.js @@ -6,4 +6,8 @@ export function getAuthorStatus() { export function register(params) { return request.post('/author/register', params); +} + +export function listBooks() { + return request.get('/author/books'); } \ No newline at end of file diff --git a/src/components/author/Header.vue b/src/components/author/Header.vue new file mode 100644 index 0000000..4bb2c8c --- /dev/null +++ b/src/components/author/Header.vue @@ -0,0 +1,17 @@ + + + \ No newline at end of file diff --git a/src/views/Book.vue b/src/views/Book.vue index c9083de..97f797d 100644 --- a/src/views/Book.vue +++ b/src/views/Book.vue @@ -158,7 +158,7 @@ 我的头像 @@ -32,7 +32,7 @@ id="imgLogo" class="user_img" alt="我的头像" - :src="userPhoto ? (uploadImgBaseUrl + userPhoto) : man" + :src="userPhoto ? (imgBaseUrl + userPhoto) : man" /> { diff --git a/src/views/author/BookList.vue b/src/views/author/BookList.vue index b0ea502..02bc8db 100644 --- a/src/views/author/BookList.vue +++ b/src/views/author/BookList.vue @@ -1,360 +1,161 @@