enhance: file upload and filter

This commit is contained in:
zerosoul
2022-04-02 16:26:13 +08:00
parent c4953a0838
commit ca4ca6cd3d
12 changed files with 130 additions and 40 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
// const BASE_URL = `${location.origin}/api`;
const BASE_URL = `https://dev.rustchat.com/api`;
export const CACHE_VERSION = `0.3`;
export const CACHE_VERSION = `0.3.1`;
// const BASE_URL = `https://rustchat.net/api`;
export const ContentTypes = {
text: "text/plain",
+2 -1
View File
@@ -39,9 +39,10 @@ export const messageApi = createApi({
}),
}),
prepareUploadFile: builder.mutation({
query: () => ({
query: (meta = {}) => ({
url: `/resource/file/prepare`,
method: "POST",
body: meta,
}),
}),
uploadFile: builder.mutation({