From 90f83588fd2e609448f727aac1ed907e11c8b75d Mon Sep 17 00:00:00 2001 From: aaron <> Date: Sun, 23 Feb 2025 17:32:41 +0800 Subject: [PATCH] update --- src/api/community.js | 11 +- src/config/env.js | 4 +- src/views/community/CommunityList.vue | 175 +++++++++++++++++++++----- 3 files changed, 154 insertions(+), 36 deletions(-) diff --git a/src/api/community.js b/src/api/community.js index c5d571f..f6b7a63 100644 --- a/src/api/community.js +++ b/src/api/community.js @@ -52,4 +52,13 @@ export function updateCommunity(id, data) { method: 'put', data }) -} \ No newline at end of file +} + +// 上传图片 +export function uploadImage(data) { + return request({ + url: '/api/upload/image', + method: 'post', + data + }) +} \ No newline at end of file diff --git a/src/config/env.js b/src/config/env.js index cd34479..35c6fcd 100644 --- a/src/config/env.js +++ b/src/config/env.js @@ -1,12 +1,12 @@ const env = { development: { - API_URL: 'http://localhost:8080' + API_URL: 'http://localhost:8000' }, testing: { API_URL: process.env.VUE_APP_API_URL || 'https://api-dev.beefast.co' }, production: { - API_URL: process.env.VUE_APP_API_URL || 'http://api.example.com' + API_URL: process.env.VUE_APP_API_URL || 'http://api.beefast.co' } } diff --git a/src/views/community/CommunityList.vue b/src/views/community/CommunityList.vue index 0b77661..4bbb776 100644 --- a/src/views/community/CommunityList.vue +++ b/src/views/community/CommunityList.vue @@ -52,6 +52,7 @@ + - -
- -
上传
-
-
+
+ +
+ +
上传
+
+
+ + + + + +
@@ -120,13 +135,13 @@