Added totp/mail otp, split up dto and api into multiple files
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<script setup lang="ts">
|
||||
import { defineProps, defineExpose, ref } from 'vue';
|
||||
import { isErrorResponse, upload_file } from '@/api';
|
||||
import { isErrorResponse, FS } from '@/api';
|
||||
import { NProgress } from 'naive-ui';
|
||||
import filesize from 'filesize';
|
||||
|
||||
@@ -14,7 +14,7 @@ const err = ref('');
|
||||
const status = ref('info');
|
||||
|
||||
async function startUpload(parent: number, token: string) {
|
||||
const resp = await upload_file(token, parent, props.file, (e) => {
|
||||
const resp = await FS.upload_file(token, parent, props.file, (e) => {
|
||||
progress.value = e.loaded;
|
||||
percentage.value = (e.loaded / e.total) * 100;
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user