index.js
1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
import axios from 'axios'
const instance = axios.create({
baseURL: process.env.VUE_APP_API_URL,
});
function registerUser(userData) {
// const url = 'http://localhost:3000/api/signup'
return axios.post('/api/RegistUser', userData);
}
function loginUser(userData) {
// const url = 'http://localhost:3000/api/login'
return axios.post('/api/login', userData);
}
function folder(curData) {
return axios.get('/api/folder/show', {
params: {
id: curData.id,
cur: curData.cur
}
});
}
function makeFolder(folderData) {
return axios.post('/api/folder/makefolder', folderData);
}
<<<<<<< HEAD
function file(userData){
return axios.get('/api/file', userData, {
params: {
user_id: userData.user_id
}
})
}
export { registerUser, loginUser, folder, makeFolder, file};
function dropbox(userData){
return axios.get(`/api/folder/show/${userData}`);
}
// export { registerUser, loginUser, dropbox, makeFolder };
=======
export { registerUser, loginUser, folder, makeFolder };
>>>>>>> ec5658f978ed2a5a94bba39bcb9aecf9edc70c36