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 @@