Browse Source

Add upload experiment page

pull/1310/head
Hironsan 3 years ago
parent
commit
ad29f888ef
1 changed files with 48 additions and 0 deletions
  1. 48
      frontend/pages/projects/_id/upload/index.vue

48
frontend/pages/projects/_id/upload/index.vue

@ -0,0 +1,48 @@
<template>
<file-pond
ref="pond"
label-idle="Drop files here..."
:allow-multiple="true"
:server="server"
:files="myFiles"
@init="handleFilePondInit"
/>
</template>
<script>
import Cookies from 'js-cookie'
import vueFilePond from "vue-filepond"
import "filepond/dist/filepond.min.css"
const FilePond = vueFilePond()
export default {
layout: 'project',
components: {
FilePond,
},
data() {
return {
myFiles: [],
server: {
url: '/v1/fp',
headers: {
'X-CSRFToken': Cookies.get('csrftoken'),
},
process: '/process/',
revert: '/revert/',
restore: '/restore/',
load: '/load/',
fetch: '/fetch/'
}
}
},
methods: {
handleFilePondInit() {
console.log("FilePond has initialized");
},
},
};
</script>
Loading…
Cancel
Save